Hi,
I'm evaluating a 3359 for an industrial application. I'm trying to figure out how to use the PRU interrupt controller (the interrupt controller described in chapter 6 in am335xPruReferenceGuide). What I would like to do is to have the PRU execute some arbitrary code and when an interrupt occurs, suspend that execution and handle the interrupt, in the same way as an ordinary processor running a real OS does.
However it seems that it is not possible. When binding system interrupts and interrupt channels to host 0 and 1 (figure 84 in am335xPruReferenceGuide) it seems that the only thing happening is that a bit in register R31 is set in the PRU when an interrupt occurs. After that the code in the PRU actively has to periodically check that bit. This is more like a polling function to see if any interrupt has occurd rather than an asynchrouneous event that suspends normal execution.
There is also a demo, PRU_PRUtoPRU_Interrupt, application in am335x_pru_package from TI. This demo application for how to send interrupts from one PRU to another indicates that a PRU actually has to poll for interrupts rather than actually be assynchrouneously interrupted, in the normal way when talking about interrupts.
I'd just like to have this confirmed by someone with a litle more experience from the am3359. Or if it is possible to have an interrupt service routine, written in assembly and executed locally on the PRU, please tell me where to find that documentation.
Br Håkan