1.A state machine is a synchronous sequential circuit with a memory section (flip-flops) to hold the present state of the machine and a control section (gates) to determine the machine’s next state.
2.The number of flip-flops in a state machine’s memory section is the same as the number of state variables.
3.Two main types of state machine are the Moore machine and the Mealy machine.
4.The outputs of a Moore machine are entirely dependent on the states of the machine’s flip-flops. Output changes will always be synchronous with the system clock.
5.The outputs of a Mealy machine depend on the states of the machine’s flip-flops and the gates in the control section. A Mealy machine’s outputs can change asynchronously, relative to the system clock.
6.A state machine can be designed in a classical fashion using the same method as in designing a synchronous counter, as follows:
a.Define the problem and draw a state diagram.
b.Construct a table of present and next states.
c.Use flip-flop excitation tables to determine the flipflop inputs for each state transition.
d.Use Boolean algebra or K-maps to find the simplest Boolean expression for flip-flop inputs (D, T, or JK) in terms of outputs (Q).
e.Draw the logic diagram of the state machine.
7.The state names in a state machine can be named numerically (s0, s1, s2, . . .) or literally (start, idle, read, write), depending on the machine function. State names are independent of the values of the state variables.
8.A state machine can be defined in VHDL by using a CASE statement within a PROCESS to define the progression of
states. The output values can be defined by a separate decoder construct or they can be assigned within each case of the CASE statement.
9.The possible values of the state variables of a machine are defined within an enumerated type definition. An enumerated type is a list of possible values that a port, variable, or signal of that type is allowed to have.
10.Notation for a state diagram includes a series of bubbles (cir-
cles) containing state names and values of state variables in
state_name . the form state_variable(s)
11.The inputs and outputs of a state machine are labeled in1, in2, . . . , inx/out1, out2, . . . ,outx.
12.Transitions between states can be conditional or unconditional. A conditional transition happens only under certain conditions of a control input and is labeled with the relevant input condition. An unconditional transition happens under all conditions of input and is labeled with an X for each input variable.
13.Conditional transitions in a VHDL state machine are described by an IF statement within a particular case of the CASE statement that describes the machine.
14.Mealy machine outputs are susceptible to asynchronous output changes if a combinational input changes out of synchronization with the clock. This can be remedied by clocking each output through a separate synchronizing flip-flop.
15.A maximum of 2n states can be assigned to a state machine
that has n state variables. If the number of states is less than 2n, the unused states must be accounted for. Either they can be treated as don’t care states, or they can be assigned a specific destination state, usually the reset state.
16.In a VHDL implementation of a state machine, any unused states can be covered with an others clause in the CASE statement that defines the machine.