Digital System Design

The main objective of this chapter is to study and design various combinational circuits like Verification of Boolean Expression, Multiplexer, Demultiplexer Circuits, Code Converters circuits using LabVIEW tools. This chapter will make the user more comfortable towards learning of Design of Digital Systems. The various types of Boolean Expressions like SOP and POS, Combinational circuits like Adder circuit (Half adder and full adder), Subtractor circuit (Half Subtractor, Full Subtractor), some code converters like Binary to Gray and Gray to Binary, BCD to Gray and Gray to BCD and also Sequential circuits with D flip flop is also being carried out using this LabVIEW.


Introduction
The field of electronics are classified into two broad group namely analog electronics and digital electronics. Analog electronics deals with signals that are continuous with respect to time by nature such as any noise signal, any video streaming etc. and digital electronics deals with signals that are discontinuous or discrete with respect to time. The electronic amplifier such as op-amp circuit helps to amplify the continuous signals and such signals are termed as analog signals and the circuit used for such applications are called analog circuits. On the other hand, the discrete signals are fed as the input to the computer by electronic switches, which as two distinct values such as HIGH level and LOW level [1]. This discrete signals are further converted in to electronic signals with the help of suitable converters. Such discrete signals are called as digital signals and the electronic circuit used for such operation are termed as digital circuits.

Boolean Algebra
In a discrete signals the two distinct values such as HIGH and LOW has equivalent voltage levels such as 5 volts and 0 volts respectively. This two distinct levels are represented as value 1 and value 0 respectively. Any algebraic functions performed with respect to this discrete values are defined as Boolean algebra developed by George Boole. He also developed various suitable theorems associated with this boolean for manipulation and simplification. There are set of basic definitions which are assumed to be true which defines all the information about the system. The following are the basic definition used in boolean algebra.
• NOT: The NOT of a variable is 1 if and only if, the variable itself is 0 and vice versa • AND: The AND of two variables is 1 if and only if both the variables are 1.
• OR: The OR of two variables is 1 if either (or both) of the variables is 1.
• XOR: The Exclusive-OR of two variables is 1 if either of them but not both is 1

Combinational logic circuits
There are two types of circuits exists in the digital system, Combinational Logic Circuits and Sequential Circuits. A combinational logic circuit is a circuit where the output depends on the combination of present input state. The set of operations which these combinational circuits performs logically by a set of Boolean functions. A sequential logic circuit is a circuit where the output depends on the combination of present input state and past input or previous input values. The previous output values are stored in the memory elements.
A combinational circuit consist of variables for input and output, and basic logic gates to perform the boolean function. The output signals are generated according to the inputs as well as the logic circuits employed. Here both the input and outputs are binary values either 1 or 0. Figure 1 shows the simple block diagram of combinational logic circuits with n input variables and m output variables. If there are n number of inputs to the circuit then 2 n possible combinations of input states but each combination can produce only one output state [2]. For instance if the combinational logic circuit has 2 inputs A and B then there can be 4 possible input states. .

Design procedure
The following are the steps considered while designing a combinational logic circuits.
• The first step is the statement of the problem for which this combinational circuit need to be designed • Definition of the input and output variables and the variable name for inputs and outputs.
• Formation and tabulation of truth table which describes the relationship between the input and output.
• The simplified boolean expression is obtained for the output variable with the help of minimization techniques or Karanaugh map. • The logical diagram using logic gates is realized for the simplified expression obtained in the previous step • In practical design and real time implementation one should consider to use minimum number of gates.

Adder circuits
A combinational circuit that performs the addition of two bits is called halfadder. When the augend and addend numbers contain more significant digits, the carry obtained from the addition of two bits is added to the next higher order pair of significant bits. The combinational circuit that performs the addition of three bits is called a full-adder. The full adder can also be obtained by using two half adder circuits.

(i) Design of half-adders
A half adder is a combination logic circuit that uses two inputs (A and B) and two outputs (Sum S and Carry C). Table 1 shows the truth table the various combinations of inputs and its corresponding outputs. The output Sum S and Carry C is obtained and the k-map is used to get the logical equation. The Boolean expressions are Figure 2 shows the design and implementation of half adder circuit in LabVIEW environment, where the front panel that two inputs Input A and Input B, the outputs are Sum and Carry [3]. The block diagram in LabVIEW environment shows the logic gate implementation for the above obtained expression.

(ii) Design of full-adders
A full adder is a combination logic circuit that uses three inputs (A, B and C in ) and two outputs (Sum S and Carry C). Table 2 shows the truth table the various combinations of inputs and its corresponding outputs. The output Sum S and Carry C is obtained and the k-map is used to get the logical equation.   Figure 3 shows the design and implementation of full adder circuit in LabVIEW environment, where the front panel that two inputs Input A, Input B, and Input C in , the outputs are Sum and Carry. The block diagram in LabVIEW environment shows the logic gate implementation for the above obtained expression.

Subtractor circuits
A combinational circuit that performs the difference of two bits is called halfsubtractor. When the first input (minuend) is 0 and the second input(subtrahend) is 1 then there exists a output variable as Borrow. The combinational circuit that determines the difference of three bits is called a full-subtractor.

(i) Design of half-subtractor
A half subtractor is a combination logic circuit that uses two inputs (A and B) and two outputs (Difference D and Borrow B). Table 3 shows the truth table the various combinations of inputs and its corresponding outputs. The output Difference D and Borrow B is obtained and the k-map is used to get the logical equation. Figure 4 shows the design and implementation of half subtractor circuit in LabVIEW environment, where the front panel that two inputs Input A and Input B, the outputs are Difference and Borrow Borrow ¼ AB (6)

(ii) Design of Full-subtractor
A full subtractor is a combination logic circuit that uses three inputs (A, B and B in ) and two outputs (Difference D and Borrow B). Table 4 shows the truth table the various combinations of inputs and its corresponding outputs. The output difference D and Borrow B is obtained and the k-map is used to get the logical equation

Multiplexer and demultiplexer
The most important form of a combinational circuit and which is widely used in the field of communication is Multiplexer and Demultiplexer Circuits. The multiplexer circuit is used to transfer large number of channels carrying information to a smaller number of channels. Such circuit used to transmit digital data or binary information is called as data selector or digital multiplexer. In this data selector, the input line is selected according to the combination of select lines, suppose if there exists 2 n input line then the number of select line is n and there will be only one output line. For example in a 4x1 multiplexer, the number of input lines is 4 (2 2 ) which shows there exists of 2 select lines. In these multiplexer circuits the inputs are named as I0, I1, I2 and I3 and the two select lines are named as S0 and S1. Table 5 shows the various combinations of select line and corresponding input line is selected and obtained as output Y [4]. The boolean expression for the output Y is given below. Figure 6 shows the Front panel and Block Diagram of 4x1 multiplexer. This design can be extended for higher versions like 8x1 and 16x1 types of multiplexer.   The Boolean expressions are

Input Variables Output Variables
The term demultiplex is just a opposite way of multiplexer, here in this combinational circuit there are one input channel and distributes the data over several channels. Therefore if the number of input channel is 1 then the number of output will be 2 n output channels. The combination of select lines control the output channel through which the input data must be transmitted. Table 6 gives the truth table for 1-to-8 demultiplexer, the front panel and block diagram for 1-to-8 demultiplexer is shown in Figure 7.
The selection input line S0, S1, S2 are activated according to the bit combination for each output as given in Eq. (10) to Eq. (17). For instance, if the selection input combination is 010, the input I is transmitted to Y2. The Boolean expressions for each output line is given below

Code converters
For the same discrete elements of information, there are several different codes available, resulting in the use of different codes for different digital systems. It's sometimes necessary to connect two digital blocks that use different coding systems. Hence a conversion digital circuit is designed and implemented between two digital systems to use information of one digital system to another. The input lines must provide the bit combinations of elements as designed by binary code A and the output is generated by the bit combinations of code B. This code converters circuit consisting of logic gates to perform this transformation operations. Some of the few code conversion techniques are discussed below. Table 7 shoes the conversion of 4-bit binary code to its equivalent gray code values. The 4 bit binary code input is defined as B 0 , B 1 , B 2 , B 3 and corresponding

Selection Inputs
Output Channels output 4-bit gray is defined as G 0 , G 2 , G 3 , and G 4 as shown in Figure 8. The corresponding boolean expression for binary to gray code conversion is given below

Gray to binary code converters
Gray code is also called as Reflected Binary Code (RBC), Reflected Binary (RB) or Gray code, Cyclic Code, is defined as an ordering of the binary number system   such that each incremental value can only differ by one bit. The main objective in this code converter is that while traversing from one step to another step, one bit in the code group changes as in Figure 9. This gray code is not applicable for arithmetic operations, but it is applicable in analog to digital converters, as well as error correction techniques in digital communications (Table 8).

Seven segment decoder
A digital decoder IC is a device that converts one digital format into another, and one of the most commonly-used device for doing this is the binary-coded decimal (BCD) to 7-segment display decoder. The 7-segment light emitting diode (LED) provides a convenient way of displaying information or digital data in the form of numbers, letters and alphanumeric characters. Typically, 7-segment displays consist of seven same coloured LEDs (called segments) within a single display package. In order to display the correct character or number, the correct combination of LED segments has to be illuminated. This LabVIEW program demonstrates the illumination of each segment by displaying hex values (0000 through FFFF) in decimal form from 0 through 9 and A through F. The standard 7-segment LED display has eight input connections, one for each LED segment and one that acts as a common terminal or connection for all internal display segments. Some displays also have an additional input pin for displaying a decimal point.

Types of digital display
There are two important types of 7-segment LED displays, namely, common cathode and common anode. In Common cathode display (CCD) display, all cathode connections of the LEDs are joined together to a low logic or ground or 0 [5]. The individual segment is illuminated by the application of high logic or + Vcc or 1 to the individual anode terminal. In Common anode display (CAD) In a CAD, all anode connections of the LEDs are joined together to a high logic or + Vcc and individual segments are illuminated by connecting individual cathode terminals to low logic or ground as shown in Figure 10. The boolean expressions of the outputs.

Conclusion
This chapter brings an overview of design of combinational logic circuits in LabVIEW. This LabVIEW programming tool is a graphical representation tool which helps the designer to simplify the design work. This tool can be further extended for designing sequential circuits as well as PLA and PAL logic design.