Beruflich Dokumente
Kultur Dokumente
Input buffers
and
inverters
x1 x1 xn xn
P1
f1 fm
f1=x1x2+x1x3+x1x2x3 P2
f2=x1x2+x1x2x3+x1x3 P3
P4
AND
plane
f1 f2
P1
f1=x1x2x3+x1x2x3 f1
P2
f2=x1x2+x1x2x3
P3
f2
P4
AND plane
Select
P1 Enable
P2 f1
P3
P4 f2 f1
Flip-flop
D Q
A programmable
multiplexer can be
Clock used to select the
type of output
To AND plane
I/O block
I/O block
PAL-like PAL-like
block block
Interconnection wires
I/O block
I/O block
PAL-like PAL-like
block block
Printed
circuit board
0/1 0
x2
x1
Two-input LUT
Programmed
values 0 1
x1 x2 f
1 0
1
1 1 0
f
1 0 1 1 1
0
0 1 1
0 0
0 0 0 x2
x1
Two-input LUT
Out
Flip-flop
In1
In2 LUT D Q
In3
Clock
x1 0 x2 0
0 f1 1 f2
0 0
f=f1+f2 x2 x2
1
x3
0
f=x1x2+x2x3
f1 0
1 f
1
f2
1
DE3 Board
gates
x3
Gate Array
(ASIC)
Standard Cell High Low High Long
(ASIC)
Design Time
Full Custom
Standard Cell
Gate Array
Programmable
Logic
Microprocessor
Performance
Clk
IE1204 Digital Design, Autumn2016 34
Bottle dispenser
COIN_PRESENT DROP
GT_1_EURO DROP_READY DROP BOTTLE
COIN EQ_1_EURO
SYSTEM
RECEIVER LT_1_EURO CONTROL
DEC_ACC RETURN_10_CENT
CLR_ACC CHANGER_READY COIN RETURN
Eject Return
bottle 10 Cent
Reset Decrease
sum sum
Clk
COIN_PRESENT DA A
D
LT_I_EURO DROP
EQ_I_EURO RETURN_I0_CENT
GT_I_EURO DB B
DROP_READY Next D Output
CHANGER_READY State Decoder CLR_ACC
A
Decoder DEC_ACC
DC C
B D
C
Clk
At next step, we develop the logic for the next state (DA, DB, DC) and outputs
IE1204 Digital Design, Autumn2016 43
Construction of next-state and
output decoders
Next state Output
Input-signals decoder Flip-flops decoder Output-signals
(Combination (Combination
al circuit) al circuit)
Clk
? ?
COIN_PRESENT DA A
D
LT_I_EURO DROP
EQ_I_EURO RETURN_I0_CENT
GT_I_EURO DB B
DROP_READY Next D Output
CHANGER_READY State Decoder CLR_ACC
A
Decoder DEC_ACC
DC C
B D
C
Clk
At next step, we develop the logic for the next state (DA, DB, DC) and outputs
IE1204 Digital Design, Autumn2016 44
Decoder: Next state - DA
COIN_PRESENT
(a) DA AB
000
00 01 11 10
COIN_PRESENT
COIN_PRESENT 0 0 - 1 1
(b) C
001 1 0 (=) + (>) 0 0
COIN_PRESENT
LT_I_EURO (c) (=) : EQ_1_EURO
011 (>) : GT_1_EURO
EQ_I_EURO GT_I_EURO
DROP CHANGER
READY (d) (f) READY
COIN_PRESENT 0 0 - 1 0
(b) C
001 1 CP (=) 0 1
COIN_PRESENT
LT_I_EURO (c) (=) : EQ_1_EURO
011 CP : COIN_PRESENT
EQ_I_EURO GT_I_EURO
DROP CHANGER
READY (d) (f) READY
COIN_PRESENT 0 CP - DR CR
(b) C
001 1 1 0 0 1
COIN_PRESENT
LT_I_EURO (c) CP : COIN_PRESENT
011 DR: DROP_READY
EQ_I_EURO GT_I_EURO
CR: CHANGER_READY
DROP CHANGER
READY (d) (f) READY
Now you can design ”Next State Decoder” and ”Output Decoder” by knowing
the logic function of Da, Db, Dc, and logic funtion of outputs ”Drop”,
”Return_10_Cent”, ”CLR_ACC”, and ”DEC_ACC”.
Clk
• Next-State-Decoder is described as a
process
• Sensitivity list contains all the inputs that
'activate' the process
NEXTSTATE : PROCESS (current_state, coin_present,
gt_1_euro, eq_1_euro, lt_1_euro, drop_ready,
changer_ready) –- Sensitivity List
BEGIN -- PROCESS NEXT_STATE
…
Clk
CLR_ACC DEC_ACC
END IF;
…
WHEN g => next_state <= c;
WHEN OTHERS => next_state <= a;
END CASE;
END PROCESS NEXTSTATE;
Clk
Clk
Clk