PPT Slide
architecture a of control_alt is
-- FFs for Finite State Machine
signal q, d : std_logic_vector(5 downto 0);
constant S0: std_logic_vector(5 downto 0) := "000001";
constant S1: std_logic_vector(5 downto 0) := "000010";
constant S2: std_logic_vector(5 downto 0) := "000100";
constant S3: std_logic_vector(5 downto 0) := "001000";
constant S4: std_logic_vector(5 downto 0) := "010000";
constant S5: std_logic_vector(5 downto 0) := "100000";
stateff: process (clk,reset)
elsif (clk'event and clk='1') then
Will define symbolic names for the states.
To use new state encoding, only have to change definition of symbolic names!
This uses one-hot encoding.