Lecture 44
Lecture 44
Each Logic Block consists of a several Logic elements. The details of the Logic
Element are shown in figure 44.1.
Carry In Programmable
To
Select
Interconnect
Data from Cascade
programmable In
interconnects
Look
Cascade
Up
Logic
Table
Flip-Flop
Clock/Clear/
Preset
Select
Logic
Carry Cascade
Out Out
F = ABC + A BC + ABC
Analogue signals are converted into Digital signals by Analogue to Digital (A/D)
converters. The conversion of the analogue signal into a corresponding digital signals is
done by first sampling the analogue signal and holding it stable for the A/D converter to
convert the signal into a digital value.
45
40
35
30
temperature 0C
25
20
15
10
0
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
time
45
42 41
40
37
35 34 35
30
C
29
0
temperature
25 25 25
23 22
20
18
15
10
7
5 4
1 2
0
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
time
30
temperature 0C
29
25 25 25
23 22
20
18
15
10
7
5 4
1 2
0
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
samples
45
40
35
30
temperature 0C
25
20
15
10
0
1 3 5 7 9 11 13 15
samples
The number of samples that are essential to accurately represent the original
signal is determined by the Nyquist Criteria which requires that the sampling frequency
should be twice the frequency of the sampled signal. Assuming the original signal to have
a frequency of 50 Hz, the sampling which allows accurate reconstruction of the signal
should be carried out at 100 Hz.
30 28
26
25 24
20 20
20
16
15
15
12 12
10 10 10
10 9
7
6
5 5
5 4
3
1
0
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
Quantization
The process of converting the analogue signal into a digital representation (code)
is known as quantization. The number of bits that are used to represent the digital code
determine the accuracy of the digitized signal. An analogue 220 volt signal can be
represented in digital terms by a 2-bit binary number. The four possible digital values 00,
30 30
30 30 28
28
23
23 21
21
16 15 15
16 15 15
10 11
11 8 9
10 9
8
0
0
1 2 3 4 5 6 7 8 9 10 11 12 13 1 2 3 4 5 6 7 8 9 10 11 12 13
Figure 44.4a Analogue Signal Figure 44.4b Sample & Hold Signal
3 3 3 3
2 2 2 2
1 1 1 1
1 2 3 4 5 6 7 8 9 10 11 12 13
0
0
1 2 3 4 5 6 7 8 9 10 11 12 13 1 2 3 4 5 6 7 8 9 10 11 12 13
Figure 44.5a Analogue Signal Figure 44.5b Sample & Hold Signal
15 15
14
12
11
8 8 8
6
5 5
4
1 2 3 4 5 6 7 8 9 10 11 12 13
The Op-Amp is used as an inverting amplifier and as a comparator. When the Op-
Amp is used as an inverting amplifier, the input signal is applied at its Inverted input
through a series resistance Ri. The output of the Op-Amp is connected to the inverted
input through a feedback resistance Rf. Figure 44.6b. The voltage gain of the Inverting
Amplifier is given by the relation
Vout/Vin = - Rf/Ri
When the Op-Amp is used as a comparator two voltages are applied at the
inputs, when these voltages differ by a very small amount the output of the Op-Amp is
driven into one of its two saturated output sates logic high or low depending upon which
of the two input voltages is higher. Figure 44.6c
The analogue input sampled signal is applied at the input of the seven
comparators. The inverted input of each of the seven comparators is connected to voltage
divider circuit made up of eight resistors having the same value R. A reference voltage
+VREF is connected at the top end of the voltage divider circuit and the lower end of the
voltage divider is connected to the ground. The voltage drops across the eight resistors
starting from the top most resistor are VREF, 7/8VREF, 6/8VREF, 5/8VREF, 4/8VREF,
3/8VREF, 2/8VREF and 1/8VREF respectively. If the input sampled voltage input is greater
than the reference input voltage for any comparator, the comparator output is logic 1,
otherwise the output is logic 0. The inputs of an eight-to-three Priority Encoder are
connected to the comparator outputs. The lowest priority input of the Encoder is
grounded. The priority encoder is enabled at each sampled input and a 3-bit code
representing the value of the input sample appears at the output. Consider an example, the
input sample is 4.2 volts. The reference voltage VREF is equal to 8 volts, the seven
reference voltages applied at the inverted inputs of the seven comparators starting from
the first comparator are 7, 6, 5, 4, 3, 2 and 1 volts respectively. With an input of 4.2 volts
the outputs of the first three comparators are set to logic 0 and the outputs of the lower
four comparators are set to logic 1 which sets the encoders first three inputs to inactive-
The 3-bit Flash converter requires seven comparators, a 4-bit Flash converter
requires fifteen converters. A large number of comparators are required to implement a
reasonable-sized converter. The advantage is that the conversion is done in parallel and
the binary equivalent value is available at the output of the converter almost
instantaneously. Flash converters are used for high speed conversion applications such as
conversion of analogue video signals into digital signals. For accurate reproduction of the
digital signal, Flash A/D converters are based on high number of Quantization levels
which requires the use of many Op-Amp based Comparators which makes the Flash
converters expensive and power hungry
Figure 44.8 shows a set of sampled analogue voltage inputs applied at the input of
the Flash converter shown in the figure 44.7. The reference voltage of the Flash converter
is set to 8 volts. At each sampling interval an enable pulse allows the Flash converter to
convert the corresponding analogue input voltage sample to be converted and represented
in its binary form. Figure 44.9.
6 5.6
4.5 4.6
voltage
5
4 3.6
3
2
2 1.7
1 0.4
0
1 2 3 4 5 6 7 8 9 10 11 12
time
Analogue
Input (Vin)
R CLK
Switch
A1
-VREF A2
Counter
R
n
Integrator CLEAR
(ramp generator) Comparator
Control Latches
Logic En
Switch Control
D7 D0
Binary or BCD
Output
Figure 44.10 Dual-Slope A/D Converter
The first Op-Amp is connected as an Integrator. Initially, the counter is reset and
has a zero count. The Input switch is connected to the Analogue input which is to be
converted into equivalent binary value. The counter is reset to count zero by the Control
Logic circuit. It also sets the switch to the Analogue input voltage. The Input analogue
voltage is assumed to be constant for the duration of the conversion process. Due to the
high input impedance of the Integrator, the current from the Analogue Input source flows
through the Resistor R and the Capacitor C. The Capacitor will charge and there will be a
negative-going linear voltage ramp at the output of A1. The non-inverted input of the
Comparator is connected to the ground, therefore as the inverted input of the comparator
becomes negative, the output changes to logic 1. The Logic 1 output triggers the Control
Logic which in turn resets the counter. The logic 1 output enables the AND gate which
allows the clock signal to be applied at the counter clock input which increments the
counter at each clock pulse. The Integrator output remains at negative voltage as the
negative-going linear ramp continues the integration process. As the counter count
reaches its maximum count value (terminal count), it rolls over and sends a signal to the
control Logic circuit which switches the switch to –VREF. The Capacitor which is charged
to a positive input voltage discharges resulting in a positive going slope at the output of
integrator. When the voltage at the inverted input of the comparator reaches zero volt, the
comparator output become logic 0 disabling the AND gate and therefore inhibiting the
counter from counting. The Control Logic circuit sends a pulse which loads the latch with
the count value.
Table 44.2 depicts the working of the Dual-Slope A/D converter. At interval t = 0
the converter is switched to the Vin input which is assumed to remain constant during the
conversion operation. The capacitor starts charging at a constant rate. The output of the
Integrator (voltage output) decreases at constant slope (-V). The output of the comparator
is set to 1 enabling the clock signal and incrementing the counter. The converter remains