0195136047.pdf

(Joyce) #1

296 DIGITAL BUILDING BLOCKS AND COMPUTER SYSTEMS


large numbers of just a few building blocks, repeated in simple ways. In this section we shall
deal with some common digital system components, such as decoders, encoders, multiplexers,
registers, counters, digital-to-analog (D/A) and analog-to-digital (A/D) converters, memory, and
display devices.

Decoders


Ann-bit binary code is capable of encoding up to 2ndistinct elements of information. A
decoder is a combinational network that decodes (converts) then-bit binary-coded input to
moutputs (m≤ 2 n). The block diagram of a 3-bit to 8-element decoder is shown in Figure
6.2.1(a), wherein the three inputs are decoded into eight outputs, one for each combination
of the input variables. In the truth table shown in Figure 6.2.1(b), observe that for each in-
put combination, there is only one output that is equal to 1 (i.e., each combination selects
only one of the eight outputs). The logic diagram of the 3-to-8 decoder is shown in Figure
6.2.1(c).
Decoding is so common in digital design that decoders are commercially available as MSI
(medium-scale integration) packages in the form of 2-to-4, 3-to-8, and 4-to-10 decoders. Inte-
grated circuits for decoders are available in different forms.

Encoders


Encoding is the process of forming an encoded representation of a set of inputs, and it is the
converse of the decoding operation. An encoder is a combinational network that generates an
n-bit binary code that uniquely identifies the one out ofmactivated inputs (0≤m≤ 2 n−1).
Figure 6.2.2(a) shows the block diagram of an 8-element to 3-bit encoder. The truth table is
given in Figure 6.2.2(b). Notice that only one of the eight inputs is allowed to be activated at any
given time. The logic diagram for the 8-to-3 encoder is shown in Figure 6.2.2(c).

Multiplexers


Amultiplexeris a data selector, whereas ademultiplexeris a data distributor. A multiplexer
is a combinational network that selects one of several possible input signals and directs that
signal to a single output terminal. The selection of a particular input is controlled by a set of
selection variables. A multiplexer withnselection variables can usually select one out of 2ninput
signals.
Figure 6.2.3(a) shows the block diagram of a 4-to-1 multiplexer. The truth table is given in
Figure 6.2.3(b). Notice that each of the four inputs (I 0 ,I 1 ,I 2 , andI 3 ) is selected byS 1 andS 0 ,
and directed to the outputQ. In general, only the input whoseaddressis given by the select lines
is directed to the output. The logic diagram is shown in Figure 6.2.3(c). 2-, 4-, 8-, and 16-to-1
multiplexers are commercially available as MSI packages.

Registers


A register is a collection of flip flops (and some basic combinational gates to perform different
binary arithmetic and logic operations), where each flip-flop is used to store 1 bit of information.
Figure 6.2.4(a) shows the block diagram of a 4-bitshift-right registerthat uses D flip-flops. JKFFs
and SRFFs are also used in shift-register construction. Observe in the timing diagram of Figure
6.2.4(b) that each successive clock pulse transfers (or shifts) the data bit from one flip-flop to the
Free download pdf