Professional Documents
Culture Documents
Unit 1 Combinational Logic Circuit and Sequential Logic Unit 1 Combinational Logic Circuit and Sequential Logic
Unit 1 Combinational Logic Circuit and Sequential Logic Unit 1 Combinational Logic Circuit and Sequential Logic
Mealy
Output depends only on present state of memory element and external input.
No of states are less in comparison to Moore Model
Output transition occurs only after the clock edge.
Synchronous Sequence Circuits
1) Moore circuit:
The sequential circuit is called as a Moore circuit if the
output depends only on the present state of the flip flops.
2) Mealy circuit:
The circuit is called as a Mealy circuit if the output depends
on the present state of the flip flops and the external
inputs.
A: Designate carry 0
B: Designate carry 1
X = 0110010100......
Y = 0000001010
1) Overlapping
2) Non overlapping
Let us input sequence is = 010
State diagram:
S0= Reset(power-up)
S1= 0
S2= 01
Sequence Detector
Sequence : 1010
Sates are A 00 ; B 01 ; C 10 ; D 11
Contd.
Excitation Table: Sequence Detector for 1010
Sequence Detector: Logic Diagram
LFSR(Linear Feedback Shift Register)
LFSR Types
Standard LFSR
An n-stage standard LFSR. It consists of n D flip-flops and a
selected number of exclusive-OR (XOR) gates.
XOR gates are placed on the external feedback path
standard LFSR is also referred to as an external-XOR LFSR
Modular LFSR
A n-stage modular LFSR with each XOR gate placed between
two adjacent D flip-flops, also known as an internal-XOR LFSR
The modular LFSR runs faster than its corresponding standard
LFSR, because each stage introduces at most one XOR-gate delay.
LFSR
Example LFSR
Design a sequence detector to detect three or more consecutive 1’s
in a string of bits coming through an input line
X= 00111011110.....
Y= 00001000110...... Overlapping
Y= 00001000100.......Non overlapping
States:
S0=Reset
S1=1
S2=11
S3=111
State table:
P.S. X N.S. Y
Qa Qb Qa+ Qb+
0 0 0
0 0 1
0 1 0
0 1 1
1 0 0
1 0 1
1 1 0
1 1 1
Seq. Detection 011 using Mealy
4 bit Ripple/Parallel carry full adder
WAP for 4 bit ripple carry full adder
module fulladder4(Sum, Cout, a,b, Cin);
output [3:0] Sum;
output Cout;
input [3:0] a,b;
input Cin;
wire c1,c2,c3;
Fulladder fa1(Sum[0],c1,a[0],b[0],Cin);
Fulladder fa2Sum[1],c2,a[1],b[1],c1);
Fulladder fa3(Sum[2],c3,a[2],b[2],c2);
Fulladder fa4(Sum[3],Cout,a[3],b[3],c3);
endmodule