Forum Discussion
Altera_Forum
Honored Contributor
13 years agoDid you notice this comment in the Altera Software Handbook about System Verilog state machine coding style?
--- Quote Start --- In Quartus II integrated synthesis, the enumerated type that defines the states for the state machine must be of an unsigned integer type as in Example 10–52. If you do not specify the enumerated type as int unsigned, a signed int type is used by default. In this case, the Quartus II integrated synthesis synthesizes the design, but does not infer or optimize the logic as a state machine. --- Quote End --- Suggested definition is:enum int unsigned { S0 = 0, S1 = 2, S2 = 4, S3 = 8 } state, next_state;