Thermometer-to-Gray-Encoders
Thermometer-to-Gray-Encoders
net/publication/274713910
CITATIONS READS
5 24,942
2 authors:
All content following this page was uploaded by Yogendra Gupta on 15 April 2015.
Mourad Fakhfakh
University of Sfax, Tunisia
Esteban Tlelo-Cuautle
INAOE, Mexico
Copyright © 2015 by IGI Global. All rights reserved. No part of this publication may be reproduced, stored or distributed in
any form or by any means, electronic or mechanical, including photocopying, without written permission from the publisher.
Product or company names used in this set are for identification purposes only. Inclusion of the names of the products or
companies does not indicate a claim of ownership by IGI Global of the trademark or registered trademark.
Library of Congress Cataloging-in-Publication Data
Library of Congress Cataloging-in-Publication Data
This book is published in the IGI Global book series Advances in Computer and Electrical Engineering (ACEE) (ISSN:
2327-039X; eISSN: 2327-0403)
All work contributed to this book is new, previously-unpublished material. The views expressed in this book are those of the
authors, but not necessarily of the publisher.
Chapter 13
Thermometer to Gray Encoders
Yogendra Gupta
The LNM Institute of Information Technology, India
Sandeep Saini
The LNM Institute of Information Technology, India
ABSTRACT
Analog to Digital Converter (ADC) is a key functional block in the design of mixed signal, system on chip,
and signal processing applications. An optimized method for the direct conversion of analog signal to
Gray code representation is presented. This eliminates the need for binary-to-Gray code conversion in
many digital modulation techniques like M-PSK and M-QAM, which uses Gray coding representation to
represent the symbols that are modulated. The authors design a low-power and high-speed Thermometer
to Gray encoder for Flash ADC, as encoders have been widely utilized in high-performance critical
applications which persistently impose special design constraints in terms of high-frequency, low power
consumption, and minimal area. In this chapter, they propose a new circuit that converts the Thermometer
code to Gray code and also yields minimized power.
Copyright © 2015, IGI Global. Copying or distributing in print or electronic forms without written permission of IGI Global is prohibited.
Thermometer to Gray Encoders
low power and high speed Thermometer to Gray posed of a series of resistor. The reference ladder
encoder, as encoders have been widely utilized used to generate 2n equally spaced reference
in high-performance critical applications which voltages. In the second part an array of compara-
persistently impose special design constraints in tor compares the input voltage with the set of
terms of high-frequency, low power consumption increasing reference voltages (Yoo Jincheol,
and minimal area. Kyusun Choi, and Ali Tangel, 2001). If the input
Flash ADC is a type of ADC which offers signal is greater than the reference voltage, the
highest sampling rate (Kanan, Kaess and Declercq, corresponding comparator output is high and
1999). In the Flash ADC an array of comparators denoted as logic “1”. On the other side, if the
compares the input voltage with a set of increasing input signals voltage is lower than the specific
reference voltages. The comparator output rep- reference voltage output is low and denoted as
resents the input signal in digital (Thermometer) logic “0”. Note that comparison of the input sig-
code, which can be easily converted into Gray code. nal with all reference voltage is performed at the
Figure 1 shows the main structure of Flash same time.
ADC. In this figure there are three main parts. As shown in figure the transition of output
The First part is reference ladder network com- code from “1” to “0” denote the input signal
324
Thermometer to Gray Encoders
voltage level because the reference voltage are DSCH v3.5 and simulated using Microwind v3.5
arranged increasingly from the bottom to the top and Xilinx ISE.
of comparators array, the output code will all
be equal to “1” as the reference voltage is lower
than input voltage level and all “0” as reference BACKGROUND
voltage is higher than input voltage level (Pereira
& Fernandes, 2001). Hence all the comparator’s Encoder is a combinational logic function. It
output looks like a Thermometer. Finally the third converts the binary information from one form to
part is Thermometer to Gray encoder. another. It gives a unique combination at the
Gray coding representation that is used output according to the information at the unique
ubiquitously in all applications. In Gray coding, input at one line. A n-bit encoder has 2n input
the adjacent representations (symbols) differ by lines and n output lines (Sall, Vesterbacka and
only one bit. Gray coding, when combined with Andersson, 2004). In this section, Thermometer
Forward Error Correction codes capable of cor- to Gray encoders are introduced.
rective single bit errors, it can aid in correction of
erroneous reception of bits that spills into adjacent
symbols. Digital modulation techniques like M- BUBBLE ERROR EFFECT
PSK and M-QAM use Gray coding representation
to represent the symbols that are modulated. In As mentioned in the previous section, the output of
M-PSK and M-QAM modulation techniques if the comparator array is a set of Thermometer code in
constellation symbols are Gray encoded, and then Flash ADC as shown in Table 1. In general there
the adjacent constellation symbol differs only by will be only one “1” to “0” transition occurs in
one bit. Thus this Gray encoded structure gives Thermometer code indicating the corresponding
a lesser probability of error than natural binary input voltage level. However, in practical circuits
ordering. Gray code is useful because only one there will be more than one “1” to “0” transition
bit changes at a time. When used as encoders for occur in the Thermometer code. When such a
a position sensor, for instance, if the sensor were situation occurs, it looks like bubbles in Ther-
right at the edge of a change boundary, there is mometer. Therefore we refer more than one “1”
uncertainty. to “0” transition to “bubble error” (Chuang, Jen,
A new improved multiplexer based encoder Hung and Da Liu, 2005).
for flash analog-to-digital converter is proposed, Figure 2 Shows two examples 2 (a) is bubble
which converts Thermometer code to Gray code. free Thermometer code and 2 (b) is shows Ther-
Gray codes are mainly used in glitch free fast mometer code with bubble error. Take Figure 2
circuit design, in communication for error cor- (b), for example there will more than single “1”
rection in digital modulation techniques and in to “0” transition is detected in the Thermometer
digital design for data path synchronization. It can code. Consequently, the input voltage level is cor-
be configured to operate on Thermometer code responded to two different output codes defined
with reduced length without any extra overhead by these two transitions (Chuang, Jen, Hung and
which is suitable for adaptive resolution analog to Da Liu, 2005). However, the actual input voltage
digital converters. Simulation results indicate that level should be corresponded to only one output
the proposed encoder results in better performance code. These two transitions will induce some
when compared to the existing encoders in terms unexpected coding errors for Thermometer to
of power, delay, area and figure of merit. All the Gray encoder.
architectures were structurally designed using
325
Thermometer to Gray Encoders
326
Thermometer to Gray Encoders
The operation of Gray ROM encoder can be outputs with turned on PMOS connected to the
separated- into two phases. In phase 1 when the power supply are charged to “1”. That’s how we
clock signal is high, the NMOS on the top of obtain a Gray code representation of correspond-
Gray ROM are turned on and the output nodes ing Thermometer code.
are discharged to a low logic level through the
turned on transistors. In phase 2 when the clock Encoding Scheme
is low, the NMOS are turned off to prevent cur-
rent leakage at the output nodes. At the same time Figure 4 shows the encoding scheme of a 3-bit
PMOS in the enabled row of Gray ROM is turned Gray ROM based encoder. At first the 1-of-N
on by”0”signal at the output of 1-of-N circuit. The circuit detect the transition occurred between T
327
Thermometer to Gray Encoders
G3 = d 0
G2 = d 0 ⊕ ( c0 + c1 )
G1 = ( c0 + c1 ) ⊕ (b0 + b1 + b2 + b3 )
G0 = (b0 + b1 + b2 + b3 )
⊕( a0from
Apart + a1the a2 + athe
+ speed, a4 tree
3 + fat + a5encoder
+ a6 +does
a7 )
not require any clock signal, sense amplifiers, or
pull-up resistors. The fat tree circuit is more noise
tolerant than the ROM circuit. Full static CMOS
implementation of the OR gates eliminates any
static power consumption otherwise necessary
in circuits with pull up resistors. Therefore, the
fat tree circuit is less power consuming than the
ROM circuit.
On the other hand, the layout of the fat tree
[3] and T [4] bit. This “0” at the output of 1-of-N is more difficult to design than the ROM. A tree
circuit is used to enable the corresponding row is considered as a regular structure but it is not
of the Gray ROM. That’s how the Gray output as regular as the ROM. Moreover, the fat tree is
code “110” is obtained according to the input a 3-D structure, challenging to layout on a two
Thermometer code “00001111”. dimensional chip.
The Thermometer to Gray encoding is carried out Wallace tree based encoder is a very straight
in two stages in the fat tree based encoder (Lee, forward approach to convert Thermometer code
Daegyu et al, 2002). Like the ROM encoder the into Gray code (Pereira, Paula, Fernandes and
first stage converting the Thermometer code to Silva, 2001). The Wallace tree method originally
1-of-N code. This code conversion is done by two used to implement high speed multipliers in com-
input AND gate with one input inverted. The sec- puter arithmetic units. This encoding scheme is
ond stage converts the 1-of-N code to Gray code especially devoted to high speed analog to digital
using multiple trees of OR gate. Figure 5 shows converters. It counts the number of 1s present
the example of 4 bit Flash ADC. A 15 bit 1-of-N in the Thermometer code or we can say that the
code is presented at the leaf nodes of the tree and output of comparator array. It does not process
4-bit Gray output code are produced at the root Thermometer code locally around the transition.
nodes of the tree (Akashe, Shyam, Vinod Rajak Figure 6 shows Wallace tree based Thermometer
and Gunakesh Sharma, 2013). An edge count of to Gray encoder (Wallace, Christopher, 1964).
a node increase as the tree height increases so it is The Wallace tree based encoder is built only
named as fat tree. Algorithmically, fat tree circuit with the elementary full adder cell. These “1” bit
328
Thermometer to Gray Encoders
329
Thermometer to Gray Encoders
330
Thermometer to Gray Encoders
331
Thermometer to Gray Encoders
Figure 9. Proposed 7-bit Thermometer to Gray encoder for 3-bit Flash ADC
G4 = T8 xN = ∑ (2 N − y − 1) (3)
y =1
G3 = T 8 .T4 + T8 .T 12
G2 = T 8 (T 4 .T2 + T4 .T 6 ) + T8 (T 12 .T10 + T12 .T 14 ) where y is the number of level y = 1, 2, 3…..N-1.
This encoder can be configured to operate as
G1 = T 8 [T 4 .(T2 .T1 + T2 .T3 ) + T4 (T 6 .T5 + T6 .T7 )]
a 7-bit Thermometer to Gray encoder by making
+T8 [T 12 .(T 10 .T9 + T10 .T 11 ) the MSB bits T8-T15 as logic zero. In this case
+T12 (T 14 .T13 + T14 .T 15 )] only the gray colored 2: 1 multiplexer are work-
332
Thermometer to Gray Encoders
Figure 10. Proposed multiplexer based encoder for 4-bit flash ADC
ing. The 15- bit Thermometer to Gray encoder Table 2. Critical path delay comparison of dif-
can be operated as two 7-bit Thermometer to Gray ferent encoder
encoders by making the T8 signal as logic one
and latching the intermediate outputs of the 7-bit 15-bit Encoder No. of Gates in Critical Path
(for 4-Bit Flash adc)
Thermometer to Gray encoder which has T1-T7
Wallace tree 10
as inputs. This property is unique to the proposed
Fat tree 5
multiplexer based encoder and is not present in
Proposed mux based 3
any of the existing encoder designs.
333
Thermometer to Gray Encoders
the proposed encoder results in better performance Pereira, P., & Fernandes, J. R. (2001). Compara-
when compared to the existing encoders in terms tive study of encoders for parallel-type ADCs.
of power, delay, area, and figure of merit. In Proc. Int. Workshop on ADC Modelling and
Testing (pp. 142-146). Academic Press.
Pereira, P., Jorge, R., & Fernandes, M. S. (2002).
REFERENCES
Wallace tree encoding in folding and interpolation
Agrawal, N., & Roy, P. (2008). An improved ADCs. In Proceedings of Circuits and Systems.
ROM architecture for bubble error suppression in IEEE. doi:10.1109/ISCAS.2002.1009889
high speed flash ADCs. In Proceedings of 2008 Sail, E., & Mark, V. (2004). A multiplexer based
Annual IEEE Conference. IEEE. doi:10.1109/ decoder for flash analog-to-digital convert-
AISPC.2008.4460547 ers. In Proceedings of TENCON 2004. IEEE.
Akashe, S., Vinod, R., & Gunakesh, S. (2013). doi:10.1109/TENCON.2004.1414916
Optimization of fat tree encoder for ultra high Sall, E., Mark, V., & Ola, A. (2004). A study of
speed analog to digital converter using 45 nano- digital decoders in flash analog-to-digital convert-
meter technology. Optik-International Journal for ers. In Proceedings of Circuits and Systems. Aca-
Light and Electron Optics. demic Press. doi:10.1109/ISCAS.2004.1328148
Chuang, Y., Hsin, H. O., & Bin-D, L. (2005). Wallace, C. S. (1964). A suggestion for a fast mul-
A novel bubble tolerant thermometer-to-binary tiplier. IEEE Transactions on Electronic Comput-
encoder for flash A/D converter. In Proceedings ers, 1(1), 14–17. doi:10.1109/PGEC.1964.263830
of VLSI Design, Automation and Test, (pp. 315-
318). VLSI. Yoo, J., Kyusun, C., & Tangel, A. (2001). A
1-GSPS CMOS flash A/D converter for system-
Gupta, Y., et al. (2013). Design of low power on-chip applications. In Proceedings of VLSI, (pp.
and high speed multiplexer based Thermometer 135-139). IEEE.
to Gray Encoder. In Proceedings of Intelligent
Signal Processing and Communications Systems
(ISPACS). IEEE.
ADDITIONAL READING
Hiremath, V., & Ren, S. (2010). An ultra high speed
encoder for 5GSPS Flash ADC. In Proceedings Arpaia, P., Cennamo, F., Daponte, P., & Sch-
of Instrumentation and Measurement Technol- umny, H. (1998), “Modeling and characterization
ogy Conference (I2MTC), (pp. 136-141). IEEE. ofsigma-delta analog-to-digital converters,” in
doi:10.1109/IMTC.2010.5488216 Instrumentation and Measurement Technology
Conference, 1998. IMTC/98. Conference Proceed-
Kanan, R., Kaess, F., & Declercq, M. (1999). A
ings. IEEE, vol. 1, pp. 96–100 vol.1.
640 mW high accuracy 8-bit 1 GHz flash ADC
encoder. In Proceedings of Circuits and Systems. Atmel (2013) Avr 127: Understanding adc param-
IEEE. doi:10.1109/ISCAS.1999.780750 eters. [Online]. Available: www.atmel.in
Lee, D., et al. (2002). Fat tree encoder design Black, B. (1999) Analog-to-digital converter archi-
for ultra-high speed flash A/D converters. In tectures and choices for system design. [Online].
Proceedings of Circuits and Systems, (vol. 2). Available: www.analog.com
Academic Press.
334
Thermometer to Gray Encoders
Deevy, K., & Quinlan, P. (1997), “Rom encoder Li, D., & Chen, C. (2008) “Inverter-based flash
circuit for flash adc’s with transistor sizing to analog-to-digital converter using floating resis-
prevent sparkle errors,” 1997, uS Patent 5,644,312. tor ladder,” 2008, uS Patent 7,315,272. [Online].
[Online]. Available: www.google.com/patents/ Available: http://www.google.co.in/patents/
US5644312 US7315272
Figueiredo, M., Goes, J., & Evans, G. (2013). Vudadha, C., Makkena, G., Nayudu, M., Pha-
“General overview of pipeline analog-to-digital neendra, P., Ahmed, S., Veeramachaneni, S.,
converters,” in Reference-Free CMOS Pipeline et al. (2012), “Low-power self reconfigurable
Analog-to-Digital Converters, ser. Analog Cir- multiplexer based decoder for adaptive resolution
cuits and Signal Processing Springer New York, flash adcs,” in VLSI Design (VLSID), 2012 25th
2013, 5–45. Internationa Conference, pp. 280–285.
Fowler, K. (2003, September). Part 7: Analog-to- Yang, J. (2002) “Bubble and meta-stability error
digital conversion in real-time systems. Instru- immune gray-code encoder for high-speed a/d
mentation Measurement Magazine, IEEE, 6(3), converters,” 2002, uS Patent 6,388,602. [On-
58–64. doi:10.1109/MIM.2003.1238355 line]. Available: http://www.google.com/patents/
US6388602
Hieu, B. V., Beak, S., Choi, S., Seon, J., & Jeong,
T. (2010), “Thermometer-to-binary encoder with
bubble error correction (bec) circuit for flash
analog-to-digital converter (fadc),” in Commu- KEY TERMS AND DEFINITIONS
nications and Electronics (ICCE), 2010 Third
International Conference on, pp. 102–106. Bubble Error: More than 1 to 0 transition
in Thermometer code results Bubble error in
Instruments, N. (2013) Bandwidth, sample rate, Thermometer code.
and nyquist theorem. [Online]. Available: www. Encoder: It converts the binary information
ni.com from one form to another. It gives a unique com-
Le, B., Rondeau, T., Reed, J., & Bostian, C. (2005). bination at the output according to the information
Analog-to-digital converters. Signal Processing at the unique input at one line.
Magazine, IEEE, 22(6), 69–77. doi:10.1109/ Gray Code: The reflected binary code, also
MSP.2005.1550190 known as Gray code is a binary numeral system
where two successive values differ in only one
Lee, D., Yoo, J., Choi, K., & Ghaznavi, J. (2002), bit (binary digit).
“Fat tree encoder design for ultra-high speed flash ROM (Read Only Memory): ROM is basi-
a/d converters,” in Circuits and Systems, 2002. cally a programmable logic device. It is actually
MWSCAS-2002. The 2002 45th Midwest Sympo- a truth table in hardware form.
sium on, vol. 2, Aug 2002, pp. II–87–II–90 vol.2. Thermometer Code: The output of compara-
tors in flash ADC.
335