0% found this document useful (0 votes)
253 views6 pages

Flip-Flop Excitation Table Verification

The document outlines an experiment aimed at verifying the excitation tables of various flip-flops, including S-R, J-K, D, and T flip-flops. It provides theoretical background, circuit diagrams, truth tables, and a C++ code implementation for testing the excitation conditions for each type of flip-flop. The flip-flops are described as bistable multivibrators that maintain a binary state until changed by input signals.

Uploaded by

Sujeet Yadav
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
253 views6 pages

Flip-Flop Excitation Table Verification

The document outlines an experiment aimed at verifying the excitation tables of various flip-flops, including S-R, J-K, D, and T flip-flops. It provides theoretical background, circuit diagrams, truth tables, and a C++ code implementation for testing the excitation conditions for each type of flip-flop. The flip-flops are described as bistable multivibrators that maintain a binary state until changed by input signals.

Uploaded by

Sujeet Yadav
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Experiment – 5

AIM: Verify the excitation table of various FLIP-FLOPS


Theory:

The flip-flop is a circuit that maintains a state until directed by input to change the state. A
basic flip-flop can be constructed using four-NAND or four-NOR gates. Flip-flop is
popularly known as the basic digital memory circuit. It has its two states as logic 1(High)
and logic 0(low) states. A flip flop is a sequential circuit which consist of single binary state
of information or data. The digital circuit is a flip flop which has two outputs and are of
opposite states. It is also known as a Bistable Multivibrator.

S-R Flip Flop


In the flip flop, with the help of preset and clear when the power is switched ON, the states
of the circuit keeps on changing, that is it is uncertain. It may come to set(Q=1) or
reset(Q’=0) state. In many applications, it is desired to initially set or reset the flip flop that
is the initial state of the flip flop that needs to be assigned. This thing is accomplished by
the preset(PR) and the clear(CLR).
Block Diagram of S-R Flip Flop
Given Below is the Block Diagram of S-R Flip Flop

S-R Flip Flop

Circuit Diagram and Truth Table of S-R Flip Flop


Given Below is the Diagram of S-R Flip Flop with its Truth Table
J-K Flip Flop
In JK flip flops, The basic structure of the flip flop which consists of Clock (CLK), Clear
(CLR), Preset (PR).
Block Diagram of J-K Flip Flop
Given Below is Block Diagram of J-K Flip Flop

J-K Flip Flop

Circuit Diagram and Truth Table of J-K Flip Flop


Given Below is the Diagram of J-K Flip Flop with its Truth Table
D Flip Flop
The D Flip Flop Consists a single data input(D), a clock input(CLK),and two outputs: Q and
Q’ (the complement of Q).
Block Diagram of D Flip Flop
Given Below is the Block Diagram of D Flip Flop

D FLIP FLOP

Circuit Diagram and Truth Table of D Flip Flop


Given Below is the Diagram of D Flip Flop with its Truth Table
T Flip Flop
The T Flip Flop consists of data input (T), a clock input (CLK), and two outputs: Q and Q’
(the complement of Q).
Block Diagram of T Flip Flop
Given Below is the Block Diagram of T Flip Flop

T FLIP FLOP

Circuit Diagram and Truth Table of T Flip Flop


Given Below is the Circuit Diagram and Truth Table of T Flip Flop

C++ Code

#include <iostream>
using namespace std;
// Function to verify excitation table for different flip-flops
void verifyExcitationTable(int Q, int Qnext) {
cout << "For Current State Q: " << Q << " and Next State Q+: " << Qnext << endl;

// SR Flip-Flop
int S, R;
if (Q == 0 && Qnext == 0) { S = 0; R = 0; }
else if (Q == 0 && Qnext == 1) { S = 1; R = 0; }
else if (Q == 1 && Qnext == 0) { S = 0; R = 1; }
else { S = 1; R = 1; }
cout << "SR Flip-Flop: S = " << S << ", R = " << R << endl;

// JK Flip-Flop
int J, K;
if (Q == 0 && Qnext == 0) { J = 0; K = 0; }
else if (Q == 0 && Qnext == 1) { J = 1; K = 0; }
else if (Q == 1 && Qnext == 0) { J = 0; K = 1; }
else { J = 1; K = 1; }
cout << "JK Flip-Flop: J = " << J << ", K = " << K << endl;

// D Flip-Flop
int D = Qnext;
cout << "D Flip-Flop: D = " << D << endl;

// T Flip-Flop
int T = (Q == Qnext) ? 0 : 1;
cout << "T Flip-Flop: T = " << T << endl;
cout << "---------------------------" << endl;
}

int main() {
// Test all possible transitions
for (int Q = 0; Q <= 1; Q++) {
for (int Qnext = 0; Qnext <= 1; Qnext++) {
verifyExcitationTable(Q, Qnext);
}
}
return 0;
}

You might also like