Hardware Reference
In-Depth Information
but will also immensely reduce the design effort. The second important decision is to
choose between the corresponding Moore and Mealy architectures. The third and i nal
architectural decision is whether to include or not in the FSM the optional output
register (i gure 3.2b).
4.2.3 Incorrect State Transition Diagram Composition
As seen in section 1.3, the state diagram must obey three fundamental principles:
1) It must include all possible system states.
2) All state transition conditions must be specii ed (unless a transition is uncondi-
tional), and such conditions must be truly complementary.
3) The list of output signals must be exactly the same in all states (standard
architecture).
Failing to comply with requisite 1 above will lead inevitably to an incorrect circuit.
Even though this seems an obvious step, there are situations in which subtle details
are involved, such as the inclusion of wait states to hold until the data to be inspected
is ready (as in i gure 3.25, for example) or to suppress state bypass (as in i gure 4.2,
for example).
Condition 2 above requires that the complete set of transition conditions be neither
under- nor overspecii ed; otherwise, a poor or incorrect circuit will again result. This
is a relatively common error that can be avoided by following the material seen in
section 1.5.
Finally, requisite 3 determines that, for hardware implementations, the list of
outputs must be exactly the same in all states; otherwise, latches will be inferred,
wasting resources and making the time response less predictable. Because this is
by far the most common mistake, an example is provided in i gure 4.1. In i gure 4.1a,
y is not specii ed in state B. If this lack of specii cation is the result of careless
analysis, an incorrect circuit will probably be implemented; otherwise, if the missing
specii cation is because y should keep in state B the same value that it had when
the FSM left state A, then y = y should be entered, as depicted in i gure 4.1b, making
the list of outputs exactly the same in all states and also clarifying what is indeed
wanted for y .
Figure 4.1
(a) State diagram with incomplete output specii cations. (b) Corrected state diagram.
Search WWH ::




Custom Search