The attached program works fine, but if I change to this:
type state_type is( STATE1, STATE2, STATE3, STATE4, STATE5);
That is, add a 5th state, it wont work anymore. No leds comes on and it doesn't respond to any button presses.
Weather or not I actuelly use the 5th state doesn't change anything, it still wont work.
When I compile the program it compiles fine. No errors but I do get a couple of warnings:
Pruning register bit 0 of Next_State(0 to 4).
Pruning register bit 0 of Present_State(0 to 4).
This is of course to be expected.
I use Lattice ICECube2 and Diamond programmer. And the fpga is ICE40UP5K-SG48ITR.
The board is something I designed myself. Nothing remarkable, just an experimental board with a few leds and buttons, switches and so on.
Any idea or suggestion would be much appreciated.