Forum Discussion
Altera_Forum
Honored Contributor
13 years agoStoring states between 2 custom instructions with Nios II processor
I need to save states of a finite state machine between two custom instructions. Is there any way of doing it?Thanks for any help you could provide.
Altera_Forum
Honored Contributor
13 years agoProvided you aren't using a combinatorial instruction you can just keep the values in any latch/memory etc. Just make sure the processing is correctly gated by the start (and generated done) signals.
Combinatorial custom instructions don't have an enable/select signal at all, the output value is just fed into a big mux and the result selected (for writeback to rC) if the instruction is actually a custom opcode with the required sub-code. So you can't save any state (except by passing it back in rC).