Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

18csl37-Ade Lab Manual

Download as pdf or txt
Download as pdf or txt
You are on page 1of 41

181/1, 182/1, Hoodi Village, Sonnenahalli, K.R.

Puram,, Bengaluru, Karnataka 560048

DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING

Analog &Digital Electronics Laboratory

As per Choice Based Credit System (CBCS) scheme

18CSL37

Effective from the academic year 2018-2019

Prepared by: Reviewed by: Approved by:


Ms. Smruthi Nair Dr. M .Pauline Dr N.Sengottaiyan
Assistant Professor Head of the Department Principal
Dept. of CSE Dept. of CSE GCEM
GCEM GCEM
18CSL37 ADE Lab Manual

List of Experiments
Hours/Week: 03 Exam Hours: 03
CIE Marks: 40 Total Hours: 36
Semester: 3 SEE Marks: 100

Sl. No. PART A (Analog Electronic Circuits) Page No.


Design an astable multivibrator circuit for three cases of duty cycle 1
1. (50%, <50% and >50%) using NE 555 timer IC. Simulate the same for
any one duty cycle.
2. Using ua 741 Opamp, design a 1 kHz relaxation oscillator with 50% 5
duty cycle. And simulate the same.
3. Using ua 741 Opamp, design window comparator for any given UTP 8
and LTP. And simulate the same.
PART B (Digital Electronic Circuits)
4. Design and implement Half adder, Full Adder, Half Subtractor, Full 10
Subtractor using basic gates. And implement the same in HDL.
5. Given any 4-variable logic expression, simplify it using appropriate 16
technique and realize the simplified logic expression using 8:1
multiplexer IC. And implement the same in HDL.
6. Realize a J-K Master/Slave Flip-Flop using NAND gates and verify 19
its truth table. And implement the same in HDL.
7. Design and implement code converter I) Binary to Gray (II) Gray to 22
Binary Code using basic gates.
8. Design and implement a mod-n (n<8) synchronous up counter using 28
J-K Flip-Flop ICs & demonstrate its working.
9. Design and implement an asynchronous counter using decade counter 32
IC to count up from 0 to n (n<=9) and demonstrate on 7 segment
display (using IC 7447).

Conduct of Practical Examination:


Experiment distribution
 For laboratories having only one part: Students are allowed to pick one
experiment from the lot with equal opportunity.
 For laboratories having PART A and PART B: Students are allowed to pick
one experiment from PART A and one experiment from PART B, with equal
opportunity.
 Change of experiment is allowed only once and marks allotted for procedure
to be made zero of the changed part only.
 Marks Distribution (Subjected to change in accordance with university
regulations)
a) For laboratories having only one part – Procedure + Execution +
Viva-Voce: 15+70+15 = 100 Marks
b) For laboratories having PART A and PART B
i. Part A – Procedure + Execution + Viva = 6 + 28 + 6 = 40
Marks
ii. Part B – Procedure + Execution + Viva = 9 + 42 + 9 = 60
Mark

i 2018-19
18CSL37 ADE Lab Manual

Objectives: This laboratory course enables students to get practical experience in design,
assembly and evaluation/testing of
1. Analog components and circuits including Operational Amplifier, Timer, etc.
2. Combinational logic circuits.
3. Flip - Flops and their operations.
4. Counters and Registers using Flip-flops.
5. Synchronous and Asynchronous Sequential Circuits.
6. A/D and D/A Converters.
Course outcomes: Laboratory Outcomes: The student should be able to:
1. Use appropriate design equations / methods to design the given circuit.
2. Examine and verify the design of both analog and digital circuits using
simulators.
3. Make use of electronic components, ICs, instruments and tools for design and
testing of circuits for the given the appropriate inputs.
4. Compile a laboratory journal which includes; aim,
tool/instruments/software/components used, design equations used and
designs, schematics, program listing, procedure followed, relevant theory,
results as graphs and tables, interpreting and concluding the findings.
18CSL37 ADE Lab Manual

PART A (Analog Electronic Circuits)


Experiment No.1: Design an astable multivibrator circuit for three cases of duty cycle
(50%, <50% and >50%) using NE 555 timer IC. Simulate the same for any one duty
cycle.

Description:
Multivibrator is a form of oscillator, which has a non-sinusoidal output. The output
waveform is rectangular. The multivibrators are classified as
i)Astable or free running multivibrator It alternates automatically between two states (low
and high for a rectangular output) and remains in each state for a time dependent upon the
circuit constants. It is just an oscillator as it requires no external pulse for its operation.
ii)Monostable or one shot multivibrators: It has one stable state and one quasi stable. The
application of an input pulse triggers the circuit time constants and the output goes to the
quazi stable state, after a period of time determined by the time constant, the circuit returns
to its initial stable state. The process is repeated upon the application of each trigger pulse.
iii)Bistable Multivibrators: It has both stable states. It requires the application of an
external triggering pulse to change the output from one state to other. After the output has
changed its state, it remains in that state until the application of next trigger pulse. Flip flop
is an example.

Components Required:
555 Timer IC, Resistors of 3.3KΩ, 6.8KΩ, Capacitors of C=0.1 μF, C’=0.01 μF, digital
trainer kit(used to give +5v power supply to 555 IC),CRO.
Design:
For astable multivibrator
TON= 0.693 (RA+RB) C
TOFF=0.693 RB C
With the diode connected in parallel with RB the effect of RB is shunted during charging of
the capacitor, therefore the equations for TON and TOFF is given by
TON= 0.693 RA C
TOFF=0.693 RB C
Case 1: 50% duty cycle
Let Frequency =1kHz, T=1ms, C=0.1 μF
TON = TOFF=0.5ms
For RA, 0.5ms= 0.693 * RA *0.1 *10-6
RA =7.2 kΩ= RB
Case 2: >50% duty cycle, let Duty cycle be 75%
Let Frequency =1kHz, T=1ms, C=0.1 μF
TON = 0.75ms
TOFF= 0.25ms
For RA, 0.75ms= 0.693 * RA *0.1 *10-6
RA =10 kΩ
For RB, 0.25ms= 0.693 * RA *0.1 *10-6
RB =3.6 kΩ
Case 3: <50% duty cycle, let Duty cycle be 25%
Let Frequency =1kHz, T=1ms, C=0.1 μF
TON = 0.25ms
TOFF= 0.75ms
For RA, 0.25ms= 0.693 * RA *0.1 *10-6
RA =3.6 kΩ

1 2018-19
18CSL37 ADE Lab Manual

For RB, 0.75ms= 0.693 * RA *0.1 *10-6


RB =10 kΩ

Circuit Diagram:

Figure 1: astable mutivibrator


Connect the pin 2 to the CRO to get the capacitor waveform check the amplitude from the
waveform to get the UTP and LTP values.
Connect pin 3 to CRO to get the output. Find out the TH and TL values.
Procedure:
1. Before making the connections, check the components using multimeter.
2. Make the connections as shown in figure and switch on the power supply.
3. Observe the capacitor voltage waveform at 6th pin of 555 timer on CRO.
4. Observe the output waveform at 3rd pin of 555 timer on CRO (shown below).
5. Note down the amplitude levels, time period and hence calculate duty cycle.

The Vcc determines the upper and lower threshold voltages (observed from the capacitor
2 1
voltage waveform) as VUT = VCC VLT = VCC .
3 3

Result:
The frequency of the oscillations = 1KHz.

2 2018-19
18CSL37 ADE Lab Manual

Output Waveforms

Figure 2: astable multivibrator output waveforms

Result:
Note:
Each division in oscilloscope is 0.2
Time=no of div in x-axis x time base
Amplitude= no of div in y-axis x volt/div
Duty cycle= (Ton/Ton +Toff) *100

Duty cycle Duty cycle Ton Toff


Theoretical 50% 0.5ms 0.5ms
75% 0.75ms 0.25ms
25% 0.25ms 0.75ms
Practical 50%
75%
25%

3 2018-19
18CSL37 ADE Lab Manual

Simulation:
Circuit diagram: Astable multivibrator for duty cycle >50%

Figure 3: astable multivibrator

Output waveform:

Type of analysis: TIME DOMAIN (TRANSIENT)


Run to time: 10m
Step size: 0.01m

4 2018-19
18CSL37 ADE Lab Manual

Experiment No.2: Using ua 741 Opamp, design a 1 kHz relaxation oscillator with 50% duty
cycle. And simulate the same.
Description:

Op-Amp Relaxation Oscillator is a simple Square wave generator which is also called as a
Free running oscillator or Astable multivibrator or Relaxation oscillator. In this figure the
op-amp operates in the saturation region. Here, a fraction (R1/ (R1+R2)) of output is fed
back to the noninverting input terminal. Thus reference voltage is (R1/ (R1+R2)) Vo. And
may take values as + (R1/ (R1+R2)) Vsat or - (R1/ (R1+R2)) Vsat. The output is also fed
back to the inverting input terminal after integrating by means of a low-pass RC
combination. Thus whenever the voltage at inverting input terminal just exceeds reference
voltage, switching takes place resulting in a square wave output.

Components Required:
Op-amp μA 741, Resistor of 10KΩ,4.7KΩ, Capacitor of 0.1 μF, digital trainer kit
(+12v & -12v is given to Op amp from this), CRO.

Design:
The period of the output rectangular wave is given as T =2RC ln (1+β/1- β ) 1
Where,
β =R1/R1+ R2 is the feedback fraction
If R1 = R2, then from equation (1) we have T = 2RC ln(3) ------- 2
Design for a frequency of 1 kHz (implies T =1ms)
Let C=0.1μF

Then calculating R as R=T/2 Cln(3) =1*10-3/2*0.1*10-6 * 1.099 = 5*103 = 5K


Select R=4.7KΩ

The voltage across the capacitor has a peak voltage of Vc = (R1/R1+ R2) Vsat

Circuit Diagram:

5 2018-19
18CSL37 ADE Lab Manual

Procedure:
1. Before making the connections check all the components using multimeter.
2. Make the connections as shown in figure and switch on the power supply.
2. Observe the voltage waveform across the capacitor on CRO.
3. Also observe the output waveform on CRO. Measure its amplitude and frequency.

Waveforms

Res
ult:

The
freq
uenc
y of
the
oscil
latio
ns = Hz.

Simulation:
Circuit diagram: Relaxation oscillator

6 2018-19
18CSL37 ADE Lab Manual

Waveforms from simulation T= 1ms f=1khz

Type of analysis: TIME DOMAIN (TRANSIENT)


Run to time: 10m
Step size: 0.01m

7 2018-19
18CSL37 ADE Lab Manual

Experiment No.3: Using ua 741 Opamp, design window comparator for any given UTP and
LTP. And simulate the same.
Description:
A Window Comparator is basically the inverting and the non-inverting comparators
combined into a single comparator stage. The window comparator detects input voltage
levels that are within a specific band or window of voltages, instead of indicating whether a
voltage is greater or less than some preset or fixed voltage reference point.
This time, instead of having just one reference voltage value, a window comparator will have
two reference voltages implemented by a pair of voltage comparators. One which triggers an
op-amp comparator on detection of some upper voltage threshold, VREF(UPPER) and one which
triggers an op-amp comparator on detection of a lower voltage threshold level, VREF(LOWER).
Then the voltage levels between these two upper and lower reference voltages is called the
“window”, hence its name.

Components Required:
Two Op amp IC µ A 741, Two diode 1N4007, Resistor of 1KΩ, DC regulated power Supply,
trainer kit (+12v & -12v is given to Op amp from this), Signal generator, CRO.

Circuit:

Circuit Diagram for Window comparator

Output waveform

8 2018-19
18CSL37 ADE Lab Manual

Simulation:
Components to be placed in the schematic:
Two Op amp IC µ A 741, Two diode 1N4007, Resistor of 1KΩ, DC regulated power Supply,
trainer kit (+12v & -12v is given to Op amp from this).

UTP =3V, LTP = -3V

Output waveform:

Type of analysis: TIME DOMAIN (TRANSIENT)


Run to time: 100m
step size: 0.01m

9 2018-19
18CSL37 ADE Lab Manual

PART B (Digital Electronic Circuits)


Experiment No 4: Design and implement Half adder, Full Adder, Half Subtractor, Full
Subtractor using basic gates. And implement the same using HDL.

Description:
Half-Adder: A combinational logic circuit that performs the addition of two data bits, A and
B, is called a half-adder. Addition will result in two output bits; one of which is the sum bit,
S, and the other is the carry bit, C. The Boolean functions describing the half-adder are:
Sum = 𝐴 ⊕ 𝐵 Cout = A B
Full-Adder: The half-adder does not take the carry bit from its previous stage into account.
This carry bit from its previous stage is called carry-in bit. A combinational logic circuit that
adds two data bits, A and B, and a carry-in bit, Cin , is called a full-adder. The Boolean
functions describing the full-adder are:

Sum = 𝐴 ⊕ 𝐵 ⨁ 𝐶𝑖𝑛 Cout = AB + Cin (𝐴 ⊕ 𝐵)


Half Subtractor: Subtracting a single-bit binary value B from another A (i.e. A –B )
produces a difference bit D and a borrow out bit B-out. This operation is called half
subtraction and the circuit to realize it is called a half subtractor. The Boolean functions
describing the half- Subtractor are:
D =𝐴 ⊕𝐵 Bout = A’ B
Full Subtractor: Subtracting two single-bit binary values, B, Cin from a single-bit value A
produces a difference bit D and a borrow out Br bit. This is called full subtraction. The
Boolean functions describing the full-subtracter are:

D = 𝐴 ⊕ 𝐵 ⨁ 𝐶𝑖𝑛 Br= A’B + A’(Cin) + B(Cin)


Components required:

IC 7400, IC 7408, IC 7486, IC 7432, Patch Cords & IC Trainer Kit.

I) TO REALIZE HALF ADDER

TRUTH TABLE
BOOLEAN EXPRESSIONS:
S=AB+ AB=A ⊕ B
INPUTS OUTPUTS C=A B

A B S C
0 0 0 0
0 1 1 0
1 0 1 0
1 1 0 1

10 2018-19
18CSL37 ADE Lab Manual

Circuit diagram:

Using AND/OR/NOT:

II) FULL ADDER

TRUTH TABLE:
INPUTS OUTPUTS
A B Cin S C
0 0 0 0 0
0 0 1 1 0
0 1 0 1 0
0 1 1 0 1
1 0 0 1 0
1 0 1 0 1
1 1 0 0 1
1 1 1 1 1

BOOLEAN EXPRESSIONS:
S= A ⊕ B ⊕ Cin

C= Cin (A ⊕ B) + AB

11 2018-19
18CSL37 ADE Lab Manual

Circuit diagram:

Using AND/OR/NOT:

III) HALF SUBTRACTOR

TRUTH TABLE BOOLEAN A⊕ B


D =EXPRESSIONS:

INPUTS OUTPUTS Br = A B

A B D Br
0 0 0 0
0 1 1 1
1 0 1 0
1 1 0 0

12 2018-19
18CSL37 ADE Lab Manual

Circuit diagram:

Using AND/OR/NOT:

IV) FULL SUBTRACTOR

TRUTH TABLE BOOLEAN EXPRESSIONS:

D= A ⊕ B ⊕
INPUTS OUTPUTS Cin

A B Cin D Br Br=Cin (A ⊕ B) + AB
0 0 0 0 0
0 0 1 1 1
0 1 0 1 1
0 1 1 0 1
1 0 0 1 0
1 0 1 0 0
1 1 0 0 0
1 1 1 1 1

13 2018-19
18CSL37 ADE Lab Manual

Circuit diagram:

Using AND/OR/NOT:

Procedure:
1. Verify all components & patch chords whether they are in good condition or not.
2. Make connections as shown in the circuit diagram.
3. Give supply to the trainer kit.
4. Provide input data to circuit via switches
5. Verify truth table sequence & observe outputs.

14 2018-19
18CSL37 ADE Lab Manual

Result:
The truth table of above circuits are verified.

Simulation: VHDL code for adder, subtractor

library ieee;
use ieee.std_logic_1164.all;

entity adder is
port(a,b,c: in std_logic;
HAsum, HAcout, FAsum, FAcout, HSdiff, HSborr, FSdiff, FSborr: out std_logic);
end adder;

architecture dataflow of adder is


begin
HAsum<= a xor b;
HAcout <= a and b;
FAsum<= a xor b xor c;
FAcout <= ((a and b)or(b and c) or(a and c));
HSdiff<= a xor b;
HSborr <= (a and (not b));
FSdiff<= a xor b xor c;
FSborr <= ((b xor c) and (not a)) or (b and c);
end dataflow;

Waveform

Note: File name, project name, entity name should be same

15 2018-19
18CSL37 ADE Lab Manual

Experiment No.5: Given any 4-variable logic expression, simplify it using appropriate
technique and realize the simplified logic expression using 8:1 multiplexer IC. And
implement the same in HDL.

Description:
The term multiplex means “many to one”. A multiplexer (MUX) has n inputs. Each line is
used to shift digital data serially. There is a single output line. One of the data stored in the n
input line is transferred to the output based on the valued of control bits. An n to 1
multiplexer requires m control bits where n<= 2m .
To construct an 4 variable function we require a 16(24) to 1 multiplexer, whereas using an
entered variable map method a 4 variable expression can be realized using 8(23) to 1
multiplexer

Components Used:
IC 74 LS151, patch chords, power chords, trainer kit.
Pin Diagrams: IC 74LS151

Entered variable map


Example:
Simplify the following function using EVM technique
f(a,b,c,d)=∑m(2,3,4,5,13,15)+dc(8,9,10,11)

MEV map
Decimal ABCD f Data
entry
0 0000 0
0 Do
1 0001 0
2 0010 1
1 D1
3 0011 1
4 0100 1
1 D2
5 0101 1
6 0110 0
0 D3
7 0111 0
8 1000 X
X D4
9 1001 X
10 1010 X
X D5
11 1011 X
12 1100 0
D D6
13 1101 1
14 1110 0
D D7
15 1111 1

16 2018-19
18CSL37 ADE Lab Manual

Circuit Diagram

Procedure:
1. Verify all components & patch chords whether they are in good condition or not.
2. Make connections as shown in the circuit diagram.
3. Give supply to the trainer kit.
4. Provide input data to circuit via switches
5. Verify truth table sequence & observe outputs.

Result:
The truth table is verify

Simulation: VHDL code for 8:1 MUX

Description:
An 8:1 multiplexer has 8 inputs and one
output. The data stored in one of these 8
input line is transferred serially to the
output based on the value of the selection
bits

Truth table:
INPUTS OUTPUTS
SEL (2) SEL (1) SEL (0) Zout
0 0 0 I(0)
0 0 1 I(1)
0 1 0 I(2)
0 1 1 I(3)

17 2018-19
18CSL37 ADE Lab Manual

1 0 0 I(4)
1 0 1 I(5)
0 1 1 I(6)
1 1 1 I(7)

VHDL code for 8 to 1 MUX (behavioral modeling):


library IEEE;
use IEEE.STD_LOGIC_1164.ALL; // includes the standard library
entity mux1 is
Port ( I : in std_logic_vector(7 downto 0);
sel : in std_logic_vector(2 downto 0); //Input and output is declared as ports
zout : out std_logic);
end mux1;
architecture Behavioral of mux1 is
begin
zout<= I(0) when sel="000" else // Based on the value of selection the value of data
I(1) when sel="001" else //stored in the array I is stored in zout
I(2) when sel="010" else
I(3) when sel="011" else
I(4) when sel="100" else
I(5) when sel="101" else
I(6) when sel="110" else
I(7);
end Behavioral;

Wavefrom:

18 2018-19
18CSL37 ADE Lab Manual

Experiment No.6: Realize a J-K Master/Slave FF using NAND gates and verify its
truth table. And implement the same in HDL.

Description:
A flip-flop is a device very much like a latch in that it is a bistable multivibrator, having two
states and a feedback path that allows it to store a bit of information. The difference between
a latch and a flip-flop is that a latch is asynchronous, and the outputs can change as soon as
the inputs do (or at least after a small propagation delay). A flip-flop, on the other hand,
is edge-triggered and only changes state when a control signal goes from high to low or low
to high.

Master Slave Flip Flop:


The control inputs to a clocked flip flop will be making a transition at approximately the
same times as triggering edge of the clock input occurs. This can lead to unpredictable
triggering.
A JK master flip flop is positive edge triggered, whereas slave is negative edge triggered.
Therefore master first responds to J and K inputs and then slave. If J=0 and K=1, master
resets on arrival of positive clock edge. High output of the master drives the K input of the
slave.
For the trailing edge of the clock pulse the slave is forced to reset. If both the inputs are high,
it changes the state or toggles on the arrival of the positive clock edge and the slave toggles
on the negative clock edge. The slave does exactly what the master does.

Components used: IC 74 LS00, IC 74LS10, patch chords, trainer kit.

Pin Diagrams: 74LS10, 74LS00

Truth table:

Clk J K Q Q bar Comment


0 0 Q0 Q bar No change
0 1 0 1 Reset
1 0 1 0 Set
1 1 Q’ Q’ bar Toggle

19 2018-19
18CSL37 ADE Lab Manual

CIRCUIT DIAGRAM:

Procedure:
1. Verify all components & patch chords whether they are in good condition or
not.
2. Make connections as shown in the circuit diagram.
3. Give supply to the trainer kit.
4. Provide input data to circuit via switches.
5. Verify truth table sequence & observe outputs.

Conclusion:
Truth table is verified

VHDL code for JK master slave Flipflop

library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
entity jkflip is
Port ( J, K, clk : in std_logic;
Q : buffer std_logic);
end jkflip;

architecture Behavioral of jkflip is


begin
process(clk)
begin
if rising_edge(clk) then
Q<= ((J and (not Q)) or ((not K) and Q));
end if;
end process;
end Behavioral;

20 2018-19
18CSL37 ADE Lab Manual

Waveform

21 2018-19
18CSL37 ADE Lab Manual

Experiment No 7: Design and implement code converter I) Binary to Gray II) Gray to
Binary Code using basic gates.

Description:
Gray Code is one of the most important codes. It is a non-weighted code which belongs to a
class of codes called minimum change codes. In this codes while traversing from one step to
another step only one bit in the code group changes. In case of Gray Code two adjacent
code numbers differs from each other by only one bit.
Binary to gray code conversion is a very simple process. There are several steps to do this
types of conversions.
Steps given below elaborate on the idea on this type of conversion.
(1) The M.S.B. of the gray code will be exactly equal to the first bit of the given binary
number.
(2) Now the second bit of the code will be exclusive-or of the first and second bit of the
given binary number, i.e if both the bits are same the result will be 0 and if they are different
the result will be 1.
(3)The third bit of gray code will be equal to the exclusive-or of the second and third bit of
the given binary number. Thus the Binary to gray code conversion goes on. One example
given below can make your idea clear on this type of conversion.

Gray code to binary conversion is again very simple and easy process. Following steps
can make your idea clear on this type of conversions.
(1) The M.S.B of the binary number will be equal to the M.S.B of the given gray code. (2)
Now if the second gray bit is 0 the second binary bit will be same as the previous or the first
bit. If the gray bit is 1 the second binary bit will alter. If it was 1 it will be 0 and if it was 0 it
will be 1.
(3) This step is continued for all the bits to do Gray code to binary conversion. One
example given below will make your idea clear.

Components required:
IC 7486, Patch Cords & digital trainer Kit.

22 2018-19
18CSL37 ADE Lab Manual

I) BINARY TO GRAY CONVERSION


0 0 1 1
0 0 1 1
0 0 1 1
0 0 1 1

0 1 0 1
0 1 0 1
0 1 0 1
0 1 0 1

0 1 1 0
0 1 1 0
1 0 0 1
1 0 0 1

0 0 0 0
1 1 1 1
0 0 0 0
1 1 1 1

BOOLEAN EXPRESSIONS:
G3=B3

G2=B3 ⊕B2

G1=B1 ⊕ B2
G0=B1 ⊕ B0

23 2018-19
18CSL37 ADE Lab Manual

Circuit Diagram: BINARY TO GRAY CODE

TRUTH TABLE:

24 2018-19
18CSL37 ADE Lab Manual

II) GRAY TO BINARY CONVERSION

0 0 1 1
0 0 1 1
0 0 1 1
0 0 1 1 B3 = G3

0 1 0 1
0 1 0 1
0 1 0 1
0 1 0 1 B2=G3 ⊕ G2

0 1 0 1
0 1 0 1
1 0 1 0 B1=G3 ⊕ G2 ⊕ G1
1 0 1 0

0 1 0 1
1 0 1 0
0 1 0 1
1 0 1 0
B0=G3 ⊕G2 ⊕G1 ⊕G0
BOOLEAN EXPRESSIONS:
B3=G3

B2=G3 ⊕ G2

B1=G3 ⊕ G2 ⊕ G1
B0=G3 ⊕ G2 ⊕ G1 ⊕ G0

25 2018-19
18CSL37 ADE Lab Manual

Circuit Diagram: Gray to Binary

TRUTH TABLE:

26 2018-19
18CSL37 ADE Lab Manual

PROCEDURE:
Check all the components for their working.
 Insert the appropriate IC into the IC base.
Make connections as shown in the circuit diagram.
 Verify the Truth Table and observe the outputs.

RESULT: Binary to gray code conversion and vice versa is realized using EX-OR gates

27 2018-19
18CSL37 ADE Lab Manual

Experiment No.8: Design and implement a mod n (n<8) synchronous up counter using
JK Flip Flop ICs and demonstrate its working.

Description:
The ripple counter requires a finite amount of time for each flip flop to change state. This
problem can be solved by using a synchronous parallel counter where every flip flop is
triggered in synchronism with the clock, and all the output which are scheduled to change do
so simultaneously.
The counter progresses counting upwards in a natural binary sequence from count 000 to
count 100 advancing count with every negative clock transition and get back to 000 after this
cycle.

Components Used: IC 74 LS76, IC 74LS08, patch chords, trainer kit.

Pin Diagrams: 74LS76

Synchronous counter design:


To successfully design synchronous counters we may employ the following six basic
steps:
1. Create the state transition diagram.
2. Create a present state-next state table (often referred to as the next state table).
3. Expand the table to form the transition table for each flip-flop in the circuit. The
transition table shows the flip-flop inputs required to make the counter go from
present state to the desired next state. This is also referred to as the excitation table.
4. Determine the logic functions of the J and K inputs as a function of the present states.
5. Analyse the counter to verify the design.
6. Construct and test the counter.

Function Table:

28 2018-19
18CSL37 ADE Lab Manual

Functional Truth Table for J-K Flip Flop:


J K Qn Qn+1
0 0
0 0
1 1
0 0
0 1
1 0
0 1
1 0
1 1
0 1
1 1
1 0

State Synthesis Table for JK Flip Flop

Present state Next state J K


0 0 0 X
0 1 1 X
1 0 X 1
1 1 X 0
Employ these techniques to design a MOD-8 counter to count in the following
sequence: 0, 1, 2, 3, 4, 5, 6, 7.
Step1: Creating state transition diagram.

Step 2: Creating present state-next state table


Present State Next State

Qc Qb Qa Qc Qb Qa
0 0 0 0 0 1

0 0 1 0 1 0

0 1 0 0 1 1

0 1 1 1 0 0

1 0 0 1 0 1

1 0 1 1 1 0

1 1 0 1 1 1

1 1 1 0 0 0

29 2018-19
18CSL37 ADE Lab Manual

Step 3: Expand the present state-next state table to form the transition table.
Present State Next State Present inputs

Q Q Q Q Q Q J K JB K JA KA
c B A C B A C c B

0 0 0 0 0 0 1 0 X 0 X 1 X

1 0 0 1 0 1 0 0 X 1 X X 1

2 0 1 0 0 1 1 0 X X 0 1 X

3 0 1 1 1 0 0 1 X X 1 X 1

4 1 0 0 1 0 1 X 0 0 X 1 X

5 1 0 1 1 1 0 X 0 1 x X 1

6 1 1 0 1 1 1 X 0 X 0 1 X

7 1 1 1 0 0 0 X 1 X 1 X 1

Step 4: Use Karnaugh maps to identify the present state logic functions for each of the input.
‘X’ indicates a "don’t care" condition.

C C
00 01 11 10 00 01 11 10
BA BA
0 0 1 0 x x x x
0 0
X x X x 0 0 1 0
Jc = QbQa Kc=QbQa

C C
00 01 11 10 00 01 11 10
BA BA
0 1 X x x X 1 0
0 0
0 1 X x x X 1 0
Jb = Qa Kb = Qa

C C
00 01 11 10 00 01 11 10
BA BA
1 X X 1 X 1 1 X
0 0
1 X X 1 X 1 1 X
Ja = 1 Ka = 1

Step 5: Trace through indicates circuit should work correctly.

30 2018-19
18CSL37 ADE Lab Manual

Step 6: Constructing Circuit

A three-bit synchronous counter


Note:
Connect preset and clear to high to work on normal operation

Conclusion:
A mod 8 counter was designed using J K Flip Flop and the truth table is verified.

31 2018-19
18CSL37 ADE Lab Manual

Experiment No.9: Design and implement asynchronous counter using decade counter
IC to count up from 0 to n (n≤9) and demonstrate on seven segment display (using IC-
7447).

Description:
Asynchronous counter is a counter in which the clock signal is connected to the clock input
of only first stage flip flop. The clock input of the second stage flip flop is triggered by the
output of the first stage flip flop and so on. This introduces an inherent propagation delay
time through a flip flop. A transition of input clock pulse and a transition of the output of a
flip flop can never occur exactly at the same time. Therefore, the two flip flops are never
simultaneously triggered, which results in asynchronous counter operation.

Components Used:
IC 74 LS90,IC 7447(BCD to seven segment decoder), patch chords, trainer kit.
1.Cp0(pin 14) to be connected to clock
2.Cp1(pin1) to be connected to Q0.( The output of the first flip flop drives the second clock)

Pin Diagram: 74LS90 / 74LS47

Pin Names Description of 7447:


A0–A3 =BCD Inputs
RBI =Ripple Blanking Input (Active LOW)
LT= Lamp Test Input (Active LOW)
RBO =Ripple Blanking Output (Active LOW)
a –g =Segment Outputs (Active LOW)
Pin Names Description of 7490:
R1 and R2-clear all filpflop (high active and low for not active)
S1 and S2- set all flip flop (high active and low for not active)
CLKA-clock pulse to first flip flop
CLKB-clock pulse to second flip flop (output of first flip flop clock for second filp flop)

32 2018-19
18CSL37 ADE Lab Manual

Circuit Diagram:

For mod 9
connect Q0 and Q3 to reset(clear) through an AND gate. Reset should not be connected to
the switch
For mod8
Connect Q3 to reset
For mod7
Connect Q2, Q1,Q0 to reset through an And Gate
For Mod 6
Connect Q2 and Q1 to reset through an AND gate
For mod 5
Connect Q0 and Q2 to reset through an AND gate
For Mod 4
Connect Q2 to reset
For mod 3
Connect Q1 and Q0 to reset through an AND gate
For mod 2
Connect Q1 to reset
Function Table:

Clock Q3 Q2 Q1 Q0
0 0 0 0 0
1 0 0 0 1
2 0 0 1 0
3 0 0 1 1
4 0 1 0 0
5 0 1 0 1
6 0 1 1 0
7 0 1 1 1
8 1 0 0 0
9 1 0 0 1

Procedure:
1. Verify all components & patch chords whether they are in good condition or not.

33 2018-19
18CSL37 ADE Lab Manual

2. Make connections as shown in the circuit diagram.


3. Give supply to the trainer kit.
4. Provide input data to circuit via switches.
5. Verify truth table sequence & observe outputs.

Result:
mod n<=9 counter implemented using the decade counter Ic

34 2018-19
18CSL37 ADE Lab Manual

User Manual – 1
IC Pin Diagrams

IC 74LS86

IC 74LS151

IC 7400 IC 7410

35 2018-19
18CSL37 ADE Lab Manual

IC 74LS76 ( two JK flip flop in one IC)

IC 7490

36 2018-19
18CSL37 ADE Lab Manual

Sample Viva Questions


1. Why operational amplifier is called by its name?
2. Explain the advantages of OPAMP over transistor amplifiers.
3. List the OPAMP ideal characteristics.
4. Give the symbol of OPAMP
5. Explain the various applications of OPAMP
6. Define UTP and LTP
7. Mention the applications of schmitt trigger
8. What is a square wave generator/ Regenerative comparator?
9. Give the hysterisis curve of a schmitt trigger
10. What is a bipolar and unipolar devices? Give examples
11. Define resolution
12. Explain the need of D/A and A/D converters.
13. List the different types of A/D and D/ A converters
14. What is a multivibrators?
15. What is a bistable multivibrators?
16. Give the applications of monostable and astable multivibrators
17. Explain the working of 555 timer as astable and monostable multivibrator
18. Why astable multivibrator is called as free running multivibrato
19. Define duty cycle.
20. List the applications of 555 timer
21. Explain 555 timer as astable multivibrator to generate a rectangular wave of duty cycle of
less than 0.5
22. Define a logic gate.
23. What are basic gates?
24. Why NAND and NOR gates are called as universal gates?
25. State De morgans theorem
26. Give examples for SOP and POS
27. Explain how transistor can be used as NOT gate
28. Realize logic gates using NAND and NOR gates only
29. List the applications of EX-OR and EX~NOR gates
30. What is a half adder?
31. What is a full adder?
32. Differentiate between combinational and sequential circuits. Give examples
33. Give the applications of combinational and sequential circuits
34. Define flip flop
35. What is an excitation table?
36. What is race around condition?
37. How do you eliminate race around condition?
38. What is minterm an d max term?
39. Define multiplexer/ data selector
40. What is a demultiplexer?
41. Give the applications of mux and demux
42. What is a encoder and decoder?
43. Compare mux and encoder
44. Compare demux and decoder
45. What is a priority encoder?
46. What are counters? Give their applications.
47. Compare synchronous and asynchronous counters
48. What is modulus of a number?
37 2018-19
18CSL37 ADE Lab Manual
49. What is a shift register?
50. What does LS stand for, in 74LSOO?
51. What is positive logic and negative logic?
52. What are code converters?
53. What is the necessity of code conversions?
54. What is gray code?
55. Realize the Boolean expressions for
a Binary to gray code conversion
b Gray to binary code conversion
*********************************************************************************

38 2018-19

You might also like