Professional Documents
Culture Documents
BJT vs FET
BJT (Bipolar Junction Transistor) FET (Field Effect Transistor)
1. Current controlled device => input current Voltage controlled device => input
IB controls output current IC voltage VGS controls output current ID
2. Bipolar device => Current due to both Unipolar device => Current due to
electrons and holes carriers majority (either electrons and holes)
carriers
3. Output IC changes linearly with change in Output ID changes non- linearly with
input IB change in input VGS
4. Input resistance less than FET Input resistance more than BJT
In range of KΩ In range of MΩ
5. Construction size more than FET Construction size smaller than BJT
7. Highly sensitive to changes in the input Less sensitive to changes in the input
signal signal
8. Effected by radiation Not Effected by radiation
9. Noisy due to carriers crossing two junctions Less noisy since no junction
11. Only Two types=> PNP and NPN Many types => MOSFET, CMOS, FET
etc
Operation:
DE-MOSFET operates in two modes: 1. Depletion mode
2. Enhancement mode
1. When VGS =0: Zero Bias
Electrons of N channel moves towards Drain (+ve) causing current I D to flow between
drain to source.
As VDS increases the channel width at drain reduces due to depletion of electrons
which cause ID to become constant.
This is known as pinch off condition
The voltage known as VP = pinch off voltage and the constant current known as IDSS
Characteristics :
2
VGS
ID = IDSS 1 -
VP
Operation:
In P-channel DE-MOSFET operation:
N-channel Enhancement-MOSFET(E-MOSFET)
Construction:
It consists of a highly doped P-type substrate
Two blocks of heavily doped N+ material forming the source and drain.
No channel between the source(S) and drain (D).
A thin layer of SiO2 dielectric is grown over the entire surface
SiO2 layer results in an extremely high input impedance.
The P-substrate may have an additional terminal connection called SS
Operation:
E-MOSFET works only in enhancement mode
Parameters:
The IDof E- MOSFET is given as:
ID = k (VGS - VT)2
where VT = threshold voltage or voltage at which the MOSFET turns on.
ID(on)
k=
(VGS(ON) - VT)2
Characteristics:
P-channel E-MOSFET
Operation:
The working of P-channel Enhancement mode MOSFET is similar to the n-channel
except that the voltage polarities and current directions are reversed.
When VGS = 0V, ID = 0
When VGS=+ve, ID=0
When VGS = -ve, IDincreases =>enhancement mode
Construction:
N-channel induced on the right MOSFET: has P-well with N+ drain and N+ source
and P+ substrate
P-channel induced on the left MOSFET: has N-well with P+ drain and P+ source and
N+ substrate
CMOS as Inverter:
1. When Vin = 0, logic LOW
P-channel VGS = -ve => Q2 ON
N-channel VGS = 0 => Q1 OFF
Q2 offers low impedance path for VDD and Q1 offers high impedance.
So, Vout = VDD => Logic High
2. When Vin = high voltage, logic HIGH
P-channel VGS = +ve => Q2 OFF
N-channel VGS = -ve => Q1 ON
Q1 offers low impedance path and Q2 offers high impedance.
So, Vout = 0=> Logic Low
Diode as clipper
Series Clipper: (for your reference only, for exam study shunt clippers)
Shunt Clippers:
Diode as Clamper
Negative Clamper:
During +ve input cycle, D = ON, so current flows through the diode giving a path for
C to charge. Capacitor charges to positive peak of Input (Vm). The output across
diode is zero.
During -ve input cycle,
D = OFF, so no current through diode. So the Input flows to output. Since
input potential has changed, capacitor starts discharging from (Vm).
Output voltage α Input voltage + voltage discharged by capacitor
Vo= - Vm + ( - Vm) = -2 Vm
During next +ve input cycle, D = ON,
Since RC >>> t of input signal, capacitor will discharge slowly and stay at peak
value for long time.
So, at positive peak of input => output will be 0
At negative peak of input => output is – 2Vm
Positive Clamper:
During -ve input cycle, D = ON, so current flows through the diode giving a path for
C to charge. Capacitor charges to negative peak of Input ( -Vm). The output across
diode is zero.
During +ve input cycle,
D = OFF, so no current through diode. So the Input flows to output. Since
input potential has changed, capacitor starts discharging from (Vm).
Output voltage α Input voltage + voltage discharged by capacitor
Vo = Vm + Vm = 2 Vm
During next -ve input cycle, D = ON,
Since RC >>> t of input signal, capacitor will discharge slowly and stay at peak
value for long time.
So, at negative peak of input => output will be 0
At positive peak of input => output is 2Vm
Ans:
A multivibrator is an electronic circuit that switches between two states due to
regenerative feedback. It is used to implement a variety of simple two-state systems such
as oscillators, timers and flip-flops. It is characterized by two amplifying devices cross-
coupled by resistors or capacitors. There are three types of multivibrator circuit depending on
the circuit operation:
ASTABLE, in which the circuit is not stable in either state —it continually
switches from one state to the other. It does not require an external trigger pulse.
Also known as free running multivibrator.
MONOSTABLE, in which one of the states is stable, but the other state is quasi
(unstable). A trigger causes the circuit to enter the quasi state. After entering the
quasi state, the circuit will return to the stable state after a set time. Such a circuit is
useful for creating a timing period of fixed duration in response to some external
event. This circuit is also known as a one shot or mono shot.
BISTABLE, in which the circuit has two stable states. The circuit can be flipped
from one state to the other by an external trigger. Also known as flip-flop.
Q. With a circuit diagram, and waveform explain the working of transistor based
Bistable multivibrator circuits.
ANS:
Bistable Multivibrators have TWO stable states and maintain a given output state
indefinitely unless an external trigger is applied.
Switches from one stable state to the other by the application of an external trigger
pulse thus, it requires two external trigger pulses.
Since has two stable states they are more commonly known as Latches and Flip-
flops for use in sequential type circuits.( it "flips" into one logic state, remains there
and then changes or "flops" back into its first original state)
Construction:
Has two NPN transistors Q1 and Q2.
Collector of Q1 coupled to base of Q2 through R1.
Collector of Q2 coupled to base of Q1 through R2.
Operation:
1. Initial condition:
When Vcc is applied both transistor starts conducting.
Since no two transistors have identical characteristics, one transistor will conduct
more as compared to other one.
Assuming Q2 starts conducting more than Q1, Q2 draws more input current as
compared to Q1.
The output current of Q2 will be more than Q1, so as I C2 increases IB1decreases.
Since IB1is coupled to base of Q1, base voltage of Q1 decreases which causes output
of Q1 to decrease further.
As IC1 decreases, IB2 increases which is coupled to base of Q2.
Waveform:
Uses:
1. In timing circuits as frequency divider
2. In counting circuits
3. In computer memory circuits
Ans:
Pin 1: Grounded Terminal: All the voltages are measured with respect to this terminal.
Pin 2: Trigger Terminal: This pin is an inverting input to a comparator that is responsible
for transition of flip-flop from set to reset. The output of the timer depends on the amplitude
of the external trigger pulse applied to this pin. When a negative going pulse of amplitude
greater than 1/3 VCC is applied to this pin, the output of the timer high. The output remains
high as long as the trigger terminal is held at a low voltage.
Pin 4: Reset Terminal: To disable or reset the timer a negative pulse is applied to this pin
due to which it is referred to as reset terminal. When this pin is not to be used for reset
purpose, it should be connected to + VCC.
Pin 5: Control Voltage Terminal: The function of this terminal is to control the threshold
and trigger levels. When this pin is not used, it should be connected to ground through a 0.01
μF capacitor to avoid any noise problem.
Pin 6: Threshold Terminal: This is the non-inverting input terminal of comparator 1, which
compares the voltage applied to the terminal with a reference voltage of 2/3 V CC. When the
voltage at this pin is greater than or equal to the threshold voltage 2/3 VCC, the output of the
timer low.
Pin 7: Discharge Terminal: This pin is connected internally to the collector of transistor and
mostly a capacitor is connected between this terminal and ground. It is called discharge
terminal because when transistor saturates, capacitor discharges through the transistor. When
the transistor is cut-off, the capacitor charges at a rate determined by the external resistor and
capacitor.
Pin 8: Supply Terminal: A supply voltage of + 5 V is applied to this terminal with respect
to ground (pin 1).
Q. Discuss briefly the working operation of Astable multivibrator using IC 555 timer.
Q. With neat figure and relevant wave forms explain the operation of astable
multivibrator using IC 555 timer.
Q. With the aid of circuit pin diagram and waveforms, explain the operation of 555
timer as an ASTABLE multi vibrator to get 50% duty cycle.
Ans:
Working:
Let output VOUT = high, Q =1, Q = 0
Since Q=0, the discharging transistor is cut-off and the capacitor C begins charging
toward VCC through resistances RA and RB.
Because of this, the charging time constant
tc or THIGH = 0.693 (RA + RB) C
As capacitor charges towards +2/3 VCC, the threshold voltage(PIN 6) exceeds +2/3
VCC, the comparator 1 has a high output and triggers the flip-flop, so Q = high and Q
= 0.
VOUT =low
Since Q = high, the discharge transistor saturates and pin 7 grounds so that the
capacitor C discharges through resistance RB.
The discharging time constant,
td or TL0W = 0.693 RB C
With the discharging of capacitor, trigger voltage at inverting input of comparator 2
decreases.
When it drops below 1/3VCC, the output of comparator 2 goes high and this reset the
flip-flop, so Q = low and Q = 1.
VOUT = high.
Since Q=0, the discharging transistor is cut-off and the capacitor C begins charging.
Thus the cycle repeats.
Boolean Algebra
12.A = A
13.A + AB = A
14.A + AB = A + B
15. (A+B)(A+C) = A+BC
DE MORGAN’S THEOREMS
Prepared by Asha Rani Borah, CSE dept., NHCE Page 19
DE-19CSE33
1. AB = A + B
2. A + B = A . B
Logic gates
AND gate
OR gate
NOT gate
NAND gate
NOR gate
SOP
SUM OF PRODUCTS METHOD
• The fundamental products are also called minterms.
Here, we have to locate output 1 in the truth table and write down the minterm.
For instance, the second output 1 appears for an input A=0, B=1. The corresponding
minterm is A'B.
The next output 1 appears for A=1, B=0. The corresponding minterm is AB'.
Y = m1 + m2 + m3
= A’ . B + A . B’ + A . B
Compact form
Y = f(A, B) = Σ m(1, 2, 3)
Example:
Truth table
Y=A'BC+AB'C+ABC'+ABC
Y=F(A,B,C)=∑m(3,5,6,7)
POS
PRODUCT OF SUMS METHOD
• Given a truth table, identify the fundamental sums needed for a logic design.
• Then by ANDing these sums, we get the product-of-sums equation corresponding to the
truth table.
• The fundamental sum produces an output 0 for the corresponding input condition.
In POS, each sum term is called maxterm and is designated by M.
Locate each output 0 in the truth table and write down its fundamental sum.
To get the product-of-sums equation, AND the fundamental sums.
Y= (A+B+C)(A+B'+C')(A'+B'+C)
Y= ∏M (0,3,6)
2. Encircle the octets. (Octet is a group of eight 1s. It eliminates three variables and
their complements.)
3. Encircle the quads. (A quad is a group of four 1s that are horizontally or Vertically
adjacent. It eliminates 2 variables and their complements.)
4. Encircle the pairs.(A pair is a group of two 1s that are horizontally or vertically
adjacent. It eliminates one variable and its complement.)
Y= A
Y= ∑m (2, 6, 7)
BC BC BC BC
BC BC BC BC
A 0 1 3 2
A 0 0 0 11
A 4 5 7 6
A 0 0 11 111
Y = AB + BC
Y=F(A,B,C,D)=∑m(2,6,7,14)
Y = AC
POS Simplification
A B C D Y
0 0 0 0 0
0 0 0 1 1
0 0 1 0 0
0 0 1 1 1
0 1 0 0 0
0 1 0 1 1
0 1 1 0 1
0 1 1 1 1
1 0 0 0 1
1 0 0 1 1
1 0 1 0 0
1 0 1 1 0
1 1 0 0 1
1 1 0 1 1
1 1 1 0 0
1 1 1 1 0
A+B 0 1 3 2
A+B 4 5 7 6
A+B 12 13 15 14
A+B 8 9 11 10
Y = (A + B + D) ( A + C + D) ( A + C)
EXAMPLE 1:
EXAMPLE 2:
Simplify Y = f(A, B, C) =Σ m (1, 2, 3, 5, 6, 7)
EXAMPLE 3:
EXAMPLE 4:
SOP and POS occupy complementary locations in a truth table. One representation
can be obtained by the other by
1. Identifying complementary locations
2. Changing minterm to maxterm or reverse
3. Changing summation by product or reverse
Example:
LIMITATIONS OF KMAP
• The map method depends on the user's ability to identify patterns that gives largest
size.
• The map method becomes difficult to adapt for simplification of 5 or more variables .
• Quine McCluskey method is a systematic approach for logic simplification that does
not have the limitations of K Map and also can easily be implemented in a digital
computer.
• Quine McCluskey method involves preparation of 2 tables:
• In stage 1 of the process, find out all the terms that gives output 1 from truth table
and put them in different groups depending on how many 1 input variable
combinations have.
For example, first group has no 1 in input combination, second group has only one
1,third two1s,fourth three 1s and fifth four 1s. We also write decimal equivalent of
each combination to their right for convenience.
• In stage 2, try to combine first and second group of stage 1,on a member to
member basis.
• The rule is to see if only one binary digit is differing between two members and
mark that position by '-'. This means corresponding variable is not required to
represent those members.
• In stage 3, combine members of different groups of stage 2 in a similar way. Now it
will have two '-'elements in each combination. This means each combination
requires 2 literals to represent it.
• Repeat stage 4 as stage 3 if required. It will have three '-'elements in each
combination. This means each combination requires 1 literal to represent it.
• Next step is to select essential prime implicants and remove redundancy or
duplication among them. For this, prepare a table, along with the row lists all the
prime implicants and along columns lists all minterms.
• The cross-point of a row and column is ticked if the term is covered by
corresponding prime implicants.
Y=A'B'+B'C+AB'+AC
Y=A'B'+B'C+AB or Y=A'B'+AC+AB
Example 2:
Simplify the following function:
Y = f(A, B, C, D) = Σ m(0, 1, 2, 3, 10, 11, 12, 13, 14, 15)
Y = A’B’ + AB + AC
Map rules
1. First Map ‘1’s by considering other variables as 0.
2. Convert ‘1’s to don’t cares (‘X’)
3. Consider one variable and other variables as 0
4. Map LIKE entries
5. Use don’t cares in any manner
6. Ensure to repeat 3&4 for all variable entries
Example 1:
F(A,B,C) = (0,1,2,5)
Step 1: truth table
B’ B
Step 2: reduced
truth table
A’ 1 C’
A C 0
Example 2:
F(A,B,C,D) = M (5, 7, 8, 9, 10, 11, 12, 14)
Step 1: truth table
A B C D Y
0 0 0 0 0
0 0 0 1 0
0 0 1 0 0
0 0 1 1 0
0 1 0 0 0
0 1 0 1 1
0 1 1 0 0
0 1 1 1 1
1 0 0 0 1
1 0 0 1 1
1 0 1 0 1
1 0 1 1 1
1 1 0 0 1
1 1 0 1 0
1 1 1 0 1
Prepared by Asha Rani Borah, CSE dept., NHCE Page 36
DE-19CSE33
1 1 1 1 0
A B C Y
0 0 0 0
0 0 1 0
0 1 0 D
0 1 1 D
1 0 0 1
1 0 1 1
1 1 0 D’
1 1 1 D’
Step 3: K map
Step 4: Simplification
Y= AB’
D as MEV:
Y= AB’ + A’B D
D’ as MEV:
Arithmetic Circuits
Half adder:
INPUTS OUTPUTS
A B S CARRY
0 0 0 0
0 1 1 0
1 0 1 0
1 1 0 1
Sum = A B’ + A’ B = A XOR B Carry = AB
FULL ADDER:
Half Subtractor:
Subtraction rules:
INPUTS OUTPUTS
A B D Borrow
0 0 0 0
0 1 1 1
1 0 1 0
1 1 0 0
FULL SUBTRACTOR:
Prepared by Asha Rani Borah, CSE dept., NHCE Page 40
DE-19CSE33
Parallel Adder
Parallel Adder is a digital circuit capable of finding the arithmetic sum of two
binary numbers by operating on corresponding pairs of bits in parallel.
It consists of full adders connected in a chain where the output carry from
each full adder is connected to the carry input of the next higher order full
adder in the chain.
A n bit parallel adder requires n full adders to perform the operation.
The given figure is 4 bit parallel adder
1. As shown in the figure, firstly the full adder FA0 adds A0 and B0 along with
the carry C0 to generate the sum S0 (the first bit of the output sum) and the
carry C1 which is connected to the next adder in chain.
2. Next, the full adder FA1 uses this carry bit C1 to add with the input bits A1
and B1 to generate the sum S1(the second bit of the output sum) and the
carry C2 which is again further connected to the next adder in chain and so
on.
3. The process continues till the last full adder.
In case of parallel adders, the binary addition of two numbers is initiated when all
the bits of the augend and the addend must be available at the same time to
perform the computation. In a parallel adder circuit, the carry output of each full
adder stage is connected to the carry input of the next higher-order stage, hence
it is also called as ripple adder.
Parallel Adder/Subtractor
The addition and subtraction operations can be done using an Adder-
Subtractor circuit. The figure shows the logic diagram of a 4-bit Adder-
Subtractor circuit.
When M = 0, the output of XOR gate will be Bi ⊕ 0 = Bi.
If the full adders receive the value of B, and the input carry C0 is 0, the circuit
performs A plus B.
’
When M = 1, the output of XOR gate will be Bi ⊕ 1 = Bi .
If the full adders receive the value of B’, and the input carry C 0 is 1, the circuit
performs A plus 1’s complement of B plus 1, which is equal to A minus B.
Propagation Time
In parallel adder circuits, it is not possible to produce the sum and carry outputs of
any stage until the input carry occurs. So there will be a considerable time delay in
the addition process, which is known as carry propagation delay. In any
combinational circuit, signal must propagate through the gates before the correct
output sum is available in the output terminals.
The propagation time is equal to the propagation delay of the typical gate times the
number of gate levels in the circuit. For example, if each full adder stage has a
propagation delay of 20n seconds, then S4 will reach its final correct value after 80n
(20 × 4) seconds.
The following are the methods to get the high speed in the parallel adder to produce
the binary addition.
1. By employing faster gates with reduced delays, we can reduce the
propagation delay. But there will be a capability limit for every physical logic
gate.
2. Another way is to increase the circuit complexity in order to reduce the carry
delay time. There are several methods available to speeding up the parallel
adder, one commonly used method employs the principle of look ahead-carry
addition by eliminating inter stage carry logic.
Pi = Ai ⊕ Bi
Gi = Ai Bi
The sum output and carry output can be expressed as
Si = Pi ⊕ Ci
C i +1 = Gi + Pi Ci
Where Gi is a carry generate which produces the carry
when both Ai, Bi are one regardless of the input carry. Pi
is a carry propagate and it is associate with the
propagation of carry from Ci to Ci +1.
C1 = G0 + P0 Cin
C2 = G1 + P1 C1 = G1 + P1 G0 + P1 P0 Cin
C3 = G2 + P2 C2
= G2 + P2 G1+ P2 P1 G0 + P2 P1 P0 Cin
C4 = G3 + P3 C3
= G3 + P3 G2+ P3 P2 G1 + P3 P2 P1 G0 + P3 P2
P1 P0 Cin
From the above Boolean equations we can observe that C4 does not have to wait for
C3 and C2 to propagate but actually C4 is propagated at the same time as C3 and
C2. Since the Boolean expression for each carry output is the sum of products so
these can be implemented with one level of AND gates followed by an OR gate.
The implementation of three Boolean functions for each carry output (C2, C3 and
C4) for a carry-Lookahead carry generator shown in below figure .
Multiplexer
Multiplex means many into one.
In digital computer networks, multiplexing is a method by which multiple
digital data streams are combined into one signal over a shared medium.
A digital circuit that performs the multiplexing of digital signals is called a
multiplexer (or MUX in short).
Multiplexer is a combinational logic circuit that can select one of many inputs.
Multiplexer is also called a data selector.
4:1 MUX
Multiplexer Logic
Multiplexer can be used to realize a given Boolean equation. Multiplexer is
called universal logic circuit because a 2n-to-1 multiplexer can be used to
design solution for any n-variable truth table.
8:1
MUX
Multiplexer Trees
Design a 4-to-1 multiplexer 2 to 1 multiplexer.
Solve: Design a 32-to-1 multiplexer using two 16:1 and one 2:1 MUX.
Decoders: n: 2n
Prepared by Asha Rani Borah, CSE dept., NHCE Page 48
DE-19CSE33
A decoder is a circuit that changes a code into a set of signals. The basic function of
a decoder is to detect the presence of a specified combination of bits on its inputs
and to indicate that presence by a specified output level. A decoder has n input lines
o handles n bits and from one to 2 noutput lines to indicate the presence of one or
more n – bit combinations..
Let 2 to 4 Decoder has two inputs A1 & A0 and four outputs Y3, Y2, Y1 & Y0.
The block diagram of 2 to 4 decoder is shown in the following figure.
TO SOLVE:
1. Design 5:32 decoder using 4:16 decoder.
2. Design 3:8 decoder using basic gates.
3. Implement Full adder using 3:8 DECODER
4. Implement Full subtractor using 3:8 decoder.
Encoder: 2n : n
Design 4 to 2 Encoder
Let 4 to 2 Encoder has four inputs Y3, Y2, Y1 & Y0 and two outputs A1 & A0.
The block diagram of 4 to 2 Encoder is shown in the following figure.
At any time, only one of these 4 inputs can be ‘1’ in order to get the respective
binary code at the output. The Truth table of 4 to 2 encoder is shown below.
Inputs Outputs
Y3 Y2 Y1 Y0 A1 A0
0 0 0 1 0 0
0 0 1 0 0 1
0 1 0 0 1 0
1 0 0 0 1 1
Priority Encoder
A 4 to 2 priority encoder has four inputs Y3, Y2, Y1 & Y0 and two outputs A1 & A0.
Here, the input, Y3 has the highest priority, whereas the input, Y0 has the lowest
priority. In this case, even if more than one input is ‘1’ at the same time, the output
will be the (binary) code corresponding to the input, which is having higher priority.
Consider one more output, V in order to know, whether the code available at
outputs is valid or not.
If at least one input of the encoder is ‘1’, then the code available at outputs is
a valid one. In this case, the output, V will be equal to 1.
If all the inputs of encoder are ‘0’, then the code available at outputs is not a
valid one. In this case, the output, V will be equal to 0.
The Truth table of 4 to 2 priority encoder is shown below.
Inputs Outputs
Y3 Y2 Y1 Y0 A1 A0 V
0 0 0 0 0 0 0
0 0 0 1 0 0 1
0 0 1 x 0 1 1
0 1 x x 1 0 1
1 x x x 1 1 1
MAGNITUDE COMPARATOR
• It compares two n-bit binary numbers, say X and Y and activates one of these 3
outputs: X=Y, >Yand X<Y
• The logic equations for the outputs can be written as follows, where G, L, E stand
for greater than, less than andequal to respectively.
(X>Y): G=XY'
(X<Y): L=X'Y
(X=Y): E=X'Y'+XY =(XY'+X'Y)'=(G+L)'
INPUTS OUTPUTS
X Y X >Y X=Y X< Y
0 0 0 1 0
0 1 0 0 1
1 0 1 0 0
1 1 0 1 0
In this, the input signals are presented to an array of AND gates while the
outputs are taken from an array of OR gates.
In a PROM, the input AND gate array is fixed and cannot be altered, while the
output OR gate array is fusible linked, and can thus be programmed.
In PAL, the output OR gate array is fixed while the input AND gate array is
fusible linked and thus programmable.
The PLA is much more versatile than the PROM or the PAL, since both its
AND gate array and its OR gate are fusible linked and programmable.
PLA is also more complicated to utilize since the number of fusible links are
doubled.
Flip flop:
A flip-flop is a bistable electronic circuit that has two stable states. The first electronic flip-
flop was invented by British physicists William Eccles and F. W. Jordan in 1918. It was
initially called the Eccles- Jordan trigger circuit.
Construction:
Two NAND gate added to inputs R & S to make RS latch as Flip flop.
Clock is added as input to enable or disable the latch.
Clock can be level or edge triggered
Working:
Since Clk =1, Both Input NAND gate output depends upon S & R inputs
Since Clk =1, Both Input NAND gate output depends upon S & R inputs
5. Clk = 0,
Since Clk =0, Both Input NAND gate output = 0
Input S & R has no control on the latch => S =R =don’t care
Since X=Y=0, SR latch stays in NO change condition
A B Y
0 0 1
0 1 1
1 0 1
1 1 0
Excitation Table of SR flip flop
Qn Qn+1 S R
0 0 0 X
0 1 1 0
1 0 0 1
1 1 X 0
Characteristics Equation
S R Qn Qn+1
0 0 0 0
0 0 1 1
0 1 0 0
0 1 1 0
1 0 0 1
1 0 1 1
1 1 0 X
1 1 1 X
SR FLIP FLOP TRUTH TABLE
K MAP OF Qn+1
Qn+1 =S+RQn
Edge Triggered JK flip flop
Construction:
To avoid the forbidden state of the SR flip flop =>Two AND gate added to inputs SR
Flip flop => this makes JK flip flop
Enable is connected to positive edge triggered clock. Enable can be connected to
negative edge triggered clock also.
Working:
1. At positive edge triggered, J=K=0,
Both Input AND gate output depends upon J&K inputs
input J=0, AND gate output =>S=0
input K=0, AND gate output =>R=0
Since S=0, R =0, according to SR flip flop=>NO change in state
Excitation Table:
Qn Qn+1 J K
0 0 0 X
0 1 1 X
1 0 X 1
1 1 X 0
Characteristics Equation
J K Qn Qn+1
0 0 0 0
0 0 1 1
0 1 0 0
0 1 1 0
1 0 0 1
1 0 1 1
1 1 0 1
1 1 1 0
JK FLIP FLOP TRUTH TABLE
K MAP OF Qn+1
Construction:
NOT gate added from J to K input.
Enable is connected to positive edge triggered clock.
Enable can be connected to negative edge triggered clock also.
Working:
1. At positive edge triggered, D=0,
Since D=0,
J=0 and K =1=> Reset state of JK flip flop =>Q= 0, Q’ = 1
Since D=1,
J=1 and K =0=> Set state of JK flip flop =>Q= 1, Q’ = 0
3. No positive trigger, flip flop is disabled, Output remains as previous state
Excitation Table:
Qn Qn+1 D
0 0 0
0 1 1
1 0 0
1 1 1
Characteristics Equation
D Qn Qn+1
0 0 0
0 1 0
1 0 1
1 1 1
D FLIP FLOP TRUTH TABLE
K MAP OF Qn+1
Qn+1 = D
Edge triggered T flip flop
Clock T Q(n+1)
0 X Qn
0 Qn
1 Qn
Construction:
J connected to K input.
Enable is connected to positive edge triggered clock. Enable can be connected to
negative edge triggered clock also.
Working:
1. At positive edge triggered, T=0,
Since T=0,
J=0 and K =0=>No change state of JK flip flop =>Q= Q, Q’=Q’
2. At positive edge triggered, T=1,
Since T=1,
J=1 and K =1=>Toggle state of JK flip flop =>Q= Q’
3. No positive trigger, flip flop is disabled, Output remains as previous state
Excitation Table:
Qn Qn+1 T
0 0 0
0 1 1
1 0 1
1 1 0
Characteristics Equation
T Qn Qn+1
0 0 0
0 1 1
1 0 1
1 1 0
T FLIP FLOP TRUTH TABLE
K MAP OF Qn+1
T’ T
Qn’ 0 1
Qn 1 0
Qn+1 = Qn T + Qn T= T XOR Qn
Racing Problem in JK Flip Flop
Consider the JK flip flop diagram, when clock is high and J&K=11 then two upper
and lower AND gates are only triggered by the complementary outputs Q and Q’.
In this condition, according to the propagation delay one gate will be enabled and
another gate is disabled.
If upper gate is disabled then it sets the output and in the next lower gate will be
enabled which resets the flip flop output.
This condition is called race around condition.
Master-slave flip flop is designed using two separate flip flops. Out of these, one acts
as the master and the other as a slave.
The output of the master J-K flip flop is fed to the input of the slave J-K flip flop.
The output of the slave J-K flip flop is given as a feedback to the input of the master
J-K flip flop.
The clock pulse [Clk] is given to the master J-K flip flop and it is sent through a NOT
Gate and thus inverted before passing it to the slave J-K flip flop.
Working:
When Clk is positive edge, the master J-K flip flop gets enabled and Slave is disabled.
When Clk is negative edge, Master is disabled.
As Slave is enabled at negative edge. the output of Master reaches to the slave.
So the next Slave output as input to the Master reaches only at next positive edge.
The output changes only after one full cycle which eliminates race around condition.
Conversion of flip flops
1. SR Flip Flop to D Flip Flop
D Qn Qn+1 S R
0 0 0 0 X
0 1 0 0 1
1 0 1 1 0
1 1 1 X 0
J K Qn Qn+1 S R
0 0 0 0 0 X
0 0 1 1 X 0
0 1 0 0 0 X
0 1 1 0 0 1
1 0 0 1 1 0
1 0 1 1 X 0
1 1 0 1 1 0
1 1 1 0 0 1
T Qn Qn+1 J K
0 0 0 0 X
0 1 1 X 0
1 0 1 1 X
1 1 0 X 1
S R Qn Qn+1 D
0 0 0 0 0
0 0 1 1 1
0 1 0 0 0
0 1 1 0 0
1 0 0 1 1
1 0 1 1 1
1 1 0 X X
1 1 1 X X
J K Qn Qn+1 T
0 0 0 0 0
0 0 1 1 0
0 1 0 0 0
0 1 1 0 1
1 0 0 1 1
1 0 1 1 0
1 1 0 1 1
1 1 1 0 1
K – map simplification
T = J Qn’ + K Qn
REGISTERS
• A register is a group of flip-flops used to momentarily store binary-information.
• Each flip-flop can store either 0 or 1.
• The flip-flops used to construct registers are usually edge-triggered JK, SR or D types.
• The register can also be used
→ to accept input-data from an alphanumeric keyboard and then present this data at the
input of a microprocessor-chip.
→ to momentarily store binary-data at the output of a decoder.
→ to perform various arithmetic operations. For ex: multiplication & division.
→ to count number of pulses entering into a system as up-counter, down-counter, ring-
counter or Johnson-counter.
TYPES OF REGISTERS
• Shift-register is a group of flip-flops connected in such a way that a binary-number can be
shifted into or out of the flip-flops.
• The bits in a binary-number can be moved from one place to another in following 2 ways:
1. Serial shifting: Data-bits are shifted one after the other in a serial fashion with one bit
shifted at each clock transition
2. Parallel shifting: Data-bits are shifted simultaneously with a single clock transition.
In this shift register, when the clock signal is applied and the serial data is given; only
one bit will be available at output at a time in the order of the input data.
The use of SISO shift register is to act as temporary data storage device.
The main use of a SISO is to act as a delay element.
CLK Parallel Q3 Q2 Q1 Q0
Input
0 0101 0 0 0 0
1 0 1 0 1
Parallel output
The output of Serial in Parallel out (SIPO) shift register is collected at each flip flop.
The main application of Serial in Parallel out shift register is to convert serial data
into parallel data. Hence they are used in communication lines where demultiplexing
of a data line into several parallel line is required.
1 1 0 0 0 0
2 0 1 0 0 0
3 1 0 1 0 0
4 1 0 1 0
Parallel output
The output of the previous flip flop and parallel data input are connected to the input
of the MUX and the output of MUX is connected to the next flip flop.
A Parallel in Serial out (PISO) shift register converts parallel data to serial data.
Hence they are used in communication lines where a number of data lines are
multiplexed into single serial data line.
2. Johnson Counters
Johnson counters are a variation of standard ring counters, with the inverted output of
the last stage fed back to the input of the first stage.
They are also known as twisted ring counters or switched tail counter.
An n-stage Johnson counter yields a count sequence of length 2n, so it may be
considered to be a mod-2n counter.
Counter:
Types of counters:
1) Asynchronous Counter (Serial Counter)
Each flip-flop is driven by the output of the previous flip-flop i.e. the output of
a flip-flop isused as the clock-input for the next flip-flop
Advantage: It requires less hardware.
Disadvantage: It operates at low speed.
2) Synchronous Counter (Parallel Counter)
All flip-flops change states simultaneously since all clock inputs are driven by
the same clock.i.e. all the flip-flops change states in synchronism.
Advantage: It operates at high speed.
Disadvantage: It requires more hardware.
Mod 128 = COUNT 0 TO 127(111 1111 in binary) => requires 2 7 => 7 flip flop
Q1. Explain a 3-bit binary Ripple UP counter. Also write the block diagram,
truth table and waveform.
ANS:
• Each flip-flop is driven by the output of the previous flip-flop i.e. the output of a flip-
flop is used as the clock-input for the next flip-flop.
Up-Counter:
It can be used to count upward from a 0 to maximum-count.
i.e. it counts in an upward direction. 0 ->1 ->2 ->3->4->5->6->7
With each clock-transition, the content of the counter is increased by 1.
A 3-bit counter can be used to count a maximum of 7 clock-transitions
This can be constructed using clocked JK flip-flops.
All J and K inputs of flip-flops are tied to +Vcc. This means, with each clock-
transition, the flip-flop will change its state (toggle
Working:
The counter outputs are A, B, and C.
The system-clock is used to drive(or trigger) flip-flop A.
The output of flip-flop A is used to drive flip-flop B.
Likewise, the output of flip-flop B is used to drive flip-flop C.
The triggers move through flip-flops like a ripple in water. Hence, it is called
ripple counter.
Flip-flop A toggles with each clock-transition.
Flip-flop B will toggle each time A goes LOW (1 to 0).
Likewise, flip-flop C will toggle each time B goes LOW (1 to 0).
The overall propagation delay time is the sum of the individual delays.
Q2) Explain a 3-bit binary Ripple Down counter. Also write the block diagram,
truth table and waveform.
Each flip-flop is driven by the output of the previous flip-flop i.e. the output of a
flip-flop is used as the clock-input for the next flip-flop.
Down Counter:
It can be used to count downward from a maximum-count to 0
it counts in an downward direction ( 7->6->5->4-> 3 ->2 ->1-> 0).
With each clock-transition, the content of the counter is decreased by 1.
A 3-bit counter can be used to count a maximum of 7 clock-transitions.
This can be constructed using clocked JK flip-flops.
All J and K inputs of flip-flops are tied to +Vcc. This means, with each clock-
transition, the flip-flop will change its state (toggle).
Working:
The counter outputs are A, B, and C.
The system-clock is used to drive(or trigger) flip-flop A.,
But, the complement of A (i.e. A') is used to drive flip-flop B,
Likewise B' is used to drive flip-flop C.
The triggers move through flip-flops like a ripple in water. Hence, it is called
ripple counter.
Flip-flop A toggles with each clock-transition.
But flip-flop B will toggle each time A goes HIGH (0 to 1).
Likewise, flip-flop C will toggle each time B goes HIGH (0 to 1).
The overall propagation delay time is the sum of the individual delays.
Q3. Explain a 3-bit binary Ripple Up-down counter. Also write the
block diagram, truth table and waveform.
Up-down Counter:
It is capable of counting in either an upward or a downward direction.
It is simply a combination of the up counter & down counter.
A 3-bit counter can be used to count a maximum of 7 clock-transitions.
This can be constructed using clocked JK flip-flops.
All J and K inputs of flip-flops are tied to +Vcc. This means, with each clock-
transition, the flip-flop will change its state (toggle).
Working:
1) To operate in the Count-up Mode
If Count-up = high and the Count-down = low, the lower AND gates Y1 and Y2
are disabled.
The clock applied to flip-flop A will be steered into the other flip-flops by AND
gates X1 and X2.
2) To operate in the Count-down Mode
If Count-up = low and the Count-down =high, the upper AND gates X1 and X2
are disabled.
The clock applied to flip-flop A will be steered into the other flip-
flops by AND gates Y1 and Y2.
Drawbacks: The additional gates (AND & OR) introduce additional
delays.
Up Counter:
It can be used to count upward from a 0 to maximum-count.
it counts in an upward direction (e.g. 0 ->1 ->2 ->3->4->5->6->7->0).
With each clock-transition, the content of the counter is increased by 1.
A 3-bit counter can be used to count a maximum of 7 clock-transitions
This can be constructed using clocked JK flip-flops.
All J and K inputs of flip-flops are tied to +Vcc. This means, with each clock-
transition, the flip-flop will change its state (toggle).
Working:
The clock is applied directly to the flip-flop A. As result, with each clock-
transition, flip-flop A will change its state (toggle).
When A is high, hence it makes flip-flop B to toggle.
When A & B are high, AND gate-Y is enabled & hence it makes flip-flop C
toggle.
CLK QA QB QC
1 0 0 0
2 0 0 1
3 0 1 0
4 0 1 1
5 1 0 0
6 1 0 1
7 1 1 0
8 1 1 1
9 0 0 0
STEP 1: K-MAP
SELF-CORRECTING COUNTER
Lock out of a counter means counter getting locked into unused states.
Solution: Use self-correcting counter
Unused states 110 and 111 can no longer be considered as don't
care.
This type of design is called self-correcting as the circuit comes out
on its own from an invalid state to a valid state.
Q6. Design a modulo-4 irregular counter with following counting sequence using D
flip-flop.
00 10 11 01
The first step in a sequential logic synthesis problem is to convert word description or
problem description to State transition diagram or Algorithm State Machine (ASM)
Chart.
State Transition Diagram is done using two type of model: Moore Model or Mealy
Model.
Moore Model:
The output is generated only from the current state variables.
Design sequence detector to detect a serial input sequence of110.
State Transition Diagram using Moore Model for sequence detector 011
Circuit Diagram
Mealy Model
The output depends upon previous state as well as current input
State Transition Diagram using Mealy Model for sequence detector 011
Two methods:
1, Row Elimination Method
2. Implication method
In this method, we first prepare a state table where at any given state the next
state and present output(s) are written for each combination of input(s).
In the present problem there are only two possible values of input X = 0 and X
= I.
For 2 input circuits there will be 22 = 4 such combinations in this table.
Now, two states are considered equivalent if they move to same or equivalent
state for every input combination and also generate same output.
Numerical to solve:
b)
c)
d)