DescriptionQ005
Q005DesignDVASIC interview problem
Control a request/acknowledge handshake
TechniquesHandshakeMoore FSMProtocolResponder BFM
DifficultyMedium
TopicFSMs
LanguageSystemVerilog
Requirements4 checkpoints
01
Problem
Design a four-phase controller that accepts start while idle, holds req until ack, drops req, waits for ack to return low, and emits a one-cycle done pulse when ack is sampled. Write a responder bus functional model (BFM) with a configurable delay.

Example input and output
Use this case to check your interpretationInput
cycle 0: req=0, ack=0
cycle 1: req=1, ack=0
cycle 2: req=1, ack=1
cycle 3: req=0, ack=1
cycle 4: req=0, ack=0Output
state: IDLE -> WAIT_ACK -> WAIT_REQ_LOW -> IDLE
done pulses once at cycle 2Explanation
The controller holds the request phase until acknowledge and does not accept a second transaction until both sides return low.
02
Requirements (4)
- Ignore additional start pulses while a transaction is active.
- Keep req asserted continuously until ack is sampled.
- Pulse done only for the req-and-ack handshake and do not return to idle until ack is low.
- Initialize ack low and drive it for exactly one sampled cycle in the BFM.
