Forum Discussion
Huh?
This is a very confusing description.
You want to create a state machine, yet you are using a Nios processor so you could write software code to do whatever you need.
You need the state machine to go through all states and get to a particular state. OK, so what are the requirements for the state transitions? Are there inputs that control the state transitions? How do you get to this final state that you need it to get to?
Then I think you are saying that when you get to this final magic state, how do you let the Nios processor know that this has happened? You could create a CSR as part of the state machine (or a separate component) that sets a bit the processor could read over an Avalon interface. Or better yet, the state machine could send an interrupt to the processor directly instead of having to build a register.
I have no idea if any of this is helpful.
- sstrell2 years ago
Super Contributor
CSR= control and status registers, basic access and data passing for any memory-mapped interface. But what you’re now talking about is a custom instruction for Nios. Look up how to create custom instructions and tie them in to the processor’s instruction set to hardware accelerate a function like the division you mention.