Digital Logic Gates and Circuits - I

Digital Logic Gates and Circuits - I


Electronics is the engineering study that deals semiconductor devices, where we actually try to achieve the significant output by using micro level inputs by regulating the movement of electrons. Electronics is a branch of Electrical Engineering. What is Digital and Analog Electronics? The digital electronics actually deals with the signals which takes only two forms - high voltage and low voltage. Whereas, the analog electronics deals with continuously variable signal. Why do we have these 2 branches? The Analog electronics may be easy for human computation and understanding, but when it comes to the machines and computer, dealing with digital electronics helps it to receive input and interpret the data easily. So we actually need to convert the analogue data which we have, into digital for the fast and easy interpretation by the machines, which finally needs to deliver us the analog signal after converting the digital output

Analog data (input) ---> Analog to digital converter ----> digital values and interpretation ----> digital output ----> Digital to Analog converter -----> Analog data (output)

Digital Data and Binary System:

In digital electronics, the data corresponding to the high values like high voltage corresponds to number 1 and low values like low voltage corresponds to number 0. So, lets now slowly recall the binary representation of number which we learnt. How can we convert a normal decimal number into binary number?

Lets take a normal decimal number, say 127. Have you ever thought that what these individual digits 1, 2 and 7 contribute in forming the number 127 ? The digits 1, 2 and 7 has its own weights based on their position. The number 1 has weight of 100 and 2 has a weight of 10 and 7 has a weight of 1. So we obtain the number 127 by adding all these digits with corresponding weight values, i.e., 127 = 100*1 + 10*2 + 1*7. So any decimal number can be constructed like this using the weights that is multiple of 10. In decimal representation, the number has a weight of 10^p, where p is the position of digits measured from right. Why can't we construct a number that has weight of 2^p where definition of p remains same. The number system constructed on this basis with weight of 2^p, where p defines the position as measured from right is called binary number system. Through out this post, lets use the notation B-1011010 to show that 1011010 is a binary number and D-101120 to show that 101120 is a decimal number

Q1. Convert the following as mentioned:
i) B-1011010 to D-XXXXX
ii) B-010010 to D-XXXXX
iii) D-56 to B-XXXXX
iv) D-19 to B-XXXXX
v) D-(your birth year) to B-XXXXX

i) B-1011010 is converted into decimal representation as follow
D-[(1*(2^6))+(0*(2^5))+(1*(2^4))+(1*(2^3))+(0*(2^2))+(1*(2^1))+(0*(2^0))]
D-[64+0+16+8+0+2+0]
D-[90]
D-90

iii) 
Solution of Q1.(iii)

Logic Gates

Logic gates are the simple switching circuit that determines the output based on circuital design and input.
Consider two switches A and B in series and in parallel. Switch conducts when closed and does not conduct when open. So lets say that switch in open position corresponds to 0 and closed as 1. When two switches are connected in series and parallel, we get 4 possible combination of switch positions for both the type of connection. 

Switch A

Switch B

Off

Off

Off

On

On

Off

On

On


When 2 switches are connected in series like shown in the figure below, we see the following output


Switch A

Switch B

Output

Off

Off

Off

Off

On

Off

On

Off

Off

On

On

On


Q. Construct a similar gate system when both the switches are connected in parallel. The output truth table for which is given below for your verification.

Switch A

Switch B

Output

Off

Off

Off

Off

On

On

On

Off

On

On

On

On


In the first case, when switches are connected in series, we get AND gate, i.e., when only both A and B has high input, then we get the output. In the second case, when switches are connected in parallel, we get OR gate, i.e., when either A or B is ON, we get the output positive. The output is 0 only if both A and B are off.

AND GATE:

Input A

Input B

Output

0

0

0

0

1

0

1

0

0

1

1

1


OR GATE:

Input A

Input B

Output

0

0

0

0

1

1

1

0

1

1

1

1


In a common emitter transistor, when input is given in base and output drawn from the collector plate, the output is inverse of the given output. This constitute our NOT gate. We will discuss more about the construction of these gates using transistor in another post.

NOT GATE:

Input A

Output

Off

On

On

Off


Input A

Output

0

1

1

0


Lets form some mathematical representation for all these 3 basic gates which we have.
If you notice AND gate, the output is product of input. And in OR gate, the output is sum of the inputs. And in NOT gate, the output is complement of input

AND: Y= A.B
OR: Y= A + B
NOT: Y = A'

Combine NOT and AND gate to form a new NAND gate.
Combine NOT and OR gate to form a new NOR gate

Combination of AND and NOT gives NAND:

NAND: Y = (A.B)'
NOR:  Y = (A + B)'

Now build the truth table using the above Boolean algebra.

NAND GATE:

Input A

Input B

Output

0

0

1

0

1

1

1

0

1

1

1

0


NOR GATE:

Input A

Input B

Output

0

0

1

0

1

0

1

0

0

1

1

0


SYMBOLS OF EACH GATE
The Boolean Algebra that governs each gates are:

AND: Y=A.B
OR: Y=A+B
NAND: Y=(A.B)'
NOR: Y=(A+B)'
NOT: Y=A'
XOR: Y=A.B' + A'.B # denoted by A B
XNOR: Y=A.B + A'.B' # denoted by (A B)'

XOR GATE:

Input A

Input B

Output

0

0

0

0

1

1

1

0

1

1

1

0


XNOR GATE:

Input A

Input B

Output

0

0

1

0

1

0

1

0

0

1

1

1



So far, we have seen the gates which receive 2 input that is total 4 possible combination of inputs. Now try constructing 3 input receiver (A B C) gates, so they have total of 8 possible combination. Now lets construct a truth table for 3 input receiver OR gate system.

OR: Y=A+B+C

Input A

Input B

Input C

Output

0

0

0

0

0

0

1

1

0

1

0

1

0

1

1

1

1

0

0

1

1

0

1

1

1

1

0

1

1

1

1

1

Application:

Q. An aircraft named AEXX02 is designed by the company IAIXX. The plane has 3 gear, two in both the wings, and one in the front portion of fuselage. You are assigned a task to build a circuit board that get signals from each of the gear and send it to the pilot. A green signal should be sent to pilot if all 3 gears are ready for extension, and even if one of the gear is not ready for extension, a red signal should be sent to the pilot. Design the circuit board.

Lets say gears ready for extensions send a high pulse signal, i.e., 1 and those which are not ready send a low pulse signal 0. So, the demanded condition can be achieved using a AND gate with 3 input receiver. 

The circuit board designed is shown below
Now, Run a manual dry-run:




In the next post, lets understand how our digital clock show the number 0,1,2,3...9 on receiving digital input.

Post a Comment

Previous Post Next Post