Forum Discussion
Altera_Forum
Honored Contributor
15 years agohave you tried simulating it? are you sure you're not missing the state change conditions somehow and allowing the counter to freewheel?
When these integers get converted for synthesis their range will be greater than you specified to fit the number of bits, and if you overflow it will have to wait longer before hitting the final conditions. Do you have a testbench for this code?