Unit I - COD - Mano
Unit I - COD - Mano
Organization and
Design (COD)
CO3: Apply the instruction set CO4: Analyse the working and
to make assembly language performance of control unit and
program. memory systems.
Term-project/viva 10
https://slideplayer.com/slide/3254624/
1/28/2025 Manoj Yadav 10
Block Diagram of Computer
Further reading:
https://www.eetimes.com/will-storage-class-memory-disrupt-memory-hierarchy/
o A Computer system is composed of several components. Some of the more common components are
the motherboard, processor, memory and hard drive.
o All components of a computer system are contained in the computer case.
o Types of buses:
i. Control bus – is
used to control
the functional
units
ii. Address bus – is
used to transfer
the address of the
data
iii. D a t a b u s – i s
used to transfer
data to and from
memory.
Timed “States”
1/28/2025 Manoj Yadav 29
Sequential Logic: Concept
• Sequential Logic circuits remember past inputs
and past circuit state.
• Outputs from the system are
“fed back” as new inputs
– With gate delay and wire delay
• The storage elements are circuits that are
capable of storing binary information:
memory.
D F/F T F/F
S R Q(t+1) Comment
0 0 Q(t) No change R-S
0 1 0 Reset Flip
1 0 1 Set Flop
1 1 ? Unpredictable
1/28/2025 Manoj Yadav 36
Manoj Yadav 1/28/2025 37
Excitation Table
• This lists the required input for the given
transition of output state.
Q(t) Q(t+1) J K
0 0 0 X
0 1 1 X J-K
1 0 X 1 Flip
1 1 X 0 Flop
Q(t) Q(t+1) S R
0 0 0 X R-S
0 1 1 X Flip
1 0 0 1 Flop
1/28/2025 1 1 X Manoj Yadav 0 38
1/28/2025 Manoj Yadav 39
Difference between Mealy Machine and Moore Machine.
Mealy Machine Moore Machine
Output depends both upon the Output depends only upon the
present state and the present input present state.
Generally, it has fewer states than Generally, it has more states than
Moore Machine. Mealy Machine.
The value of the output function is a The value of the output function is a
function of the transitions and the function of the current state and the
changes, when the input logic on the changes at the clock edges,
present state is done. whenever state changes occur.
• Input: x(t)
x
• Output: y(t) D Q A
Function?
y
– B(t+1) = A’(t)x(t)
– y(t) = x’(t)(B(t) + A(t)) D Q B
using K-map
y
Output
Input/output
At state a if applied i/p is 0 out will be 0 and system will go to next state a.
1/28/2025 Manoj Yadav 49
Obtain state table from state diagram
Q(t) Q(t+1) T
0 0 0 T Flip
0 1 1 Flop
1 0 1
1 1 0
•Using K-Maps
•A(t + 1) = DA = ∑(3,5,7) = A x + B x
•B(t + 1) = DB = ∑(1,5,7) = A x + B’ x
•y = ∑(6,7) = A B
•Using K-Maps
•A(t + 1) = DA = ∑(3,5,7) = A x + B x
•B(t + 1) = DB = ∑(1,5,7) = A x + B’ x
•y = ∑(6,7) = A B
FSM DESIGN
FSM
using
Design
MUX or
using MUX
Decoder
0 I0 I1 I2 I3
1
X’ 0 2 4 6
2
3 X 1 3 5 7
4 0 X X X
5
I3=X
DA = X. (QA.QB + QA. QB’ + QA’. QB)
I2=X DA DA = X. (QA + QA’.QB)
I1=X
DA = X. (QA + QA’) . (QA + QB)
I0=0 DA = X. (QA + QB)
0 I0 I1 I2 I3
1
2
X’ 0 2 4 6
3 X 1 3 5 7
4
5
X 0 X X
6
7
I3=X
I2=X
DB DB = X. (QA.QB + QA. QB’ + QA’. QB’)
I1=0
DB = X. (QA.QB + QB’)
I0=X DB = X. (QA + QB’) . (QB + QB’)
DB = X. (QA + QB’)
QA QB
1/28/2025 Manoj Yadav 81
MUX – FF/Register – MUX
I3=X
I2=X DA QA
I1=X 0
I0=0 QA Y = X.QA
X
QA QB
I3=X
I2=X DB QB
I1=0
I0=X
QA QB
1/28/2025 Manoj Yadav 82
Decoder – FF/Register – Decoder
QA
QB DA QA
X
QA
X
Y = X.QA
QA
QB DB QB
X
X
Y = X.QA
QA QB
I3=X
I2=X DB QB
I1=0
I0=X
QA QB
X Y
Input 1 1 1 0 0 1 0 0 1 0 0 1 1 0 1 1 0 1 0 1 1 0 1 1 1 1 1 1
Output 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 1 0 0 1 0 0 0 0
OR
• JA = BX’
• KA = BX + B’X’
• DB = X
• Y = ABX’
• JA = BX’
• KA = BX + B’X’
• DB = X
• Y = ABX’
• We choose T-FF
• TA0 = 1
• TA1 = A0
• TA2 = A1A0
Traffic Action
EW only EW Signal green
NS Signal red
NS only NS Signal green
W E
EW Signal red
EW & NS Alternate
No traffic Previous state
S
1/28/2025 Manoj Yadav 106
Example 4 (cont.)
11, 10
00, 01 00, 10
NS / 01 EW / 10
11, 01
INPUTS OUTPUTS
STATES
• Sensors X1, X0 • Light S1, S0
• NS: NS is green X0: car coming on NS S0 : NS is green
• EW: EW is green X1 : car coming on EW S1 : EW is green
E
EX 00 01 11 10 EX 00 01 11 10
AB AB X
00 0 0 0 1 00 x x x x
Y
01 0 0 1 0 01 x x x x
11 x x x x 11 0 0 1 0
JA A
10 x x x x 10 0 0 0 1
C
JA = BEX + B’EX’ KA = BEX + B’EX’ KA A’
EX 00 01 11 10 EX 00 01 11 10 JB B
AB AB
C
00 0 0 1 1 00 x x x x
KB B’
01 x x x x 01 0 0 1 1
11 x x x x 11 0 0 1 1 clock
10 0 0 1 1 10 x x x X
JB = E KB = E
1/28/2025 Manoj Yadav PJF - 111
More Design Examples
S0 = 00 S2 = 10
S1 = 01 S3 = 11
11
00
• It is modulo 3
binary counter
• Counts as
0120
01
• If started from 11
10
resets
automatically to
1/28/2025 Manoj Yadav 00 134
Practice problems
S0
S1
CLK Shift
Register
Clear_b
S1 S0 Reg operation
Data IN (Parallel)
0 0 No change
0 1 Shift right
1 0 Shift left
1 1 Parallel load
1/28/2025 Manoj Yadav 149
Universal Shift Register
State
diagram