On Mon, 13 Jul 2020 10:32:37 -0700 (PDT), in
gmane.comp.hardware.beagleboard.user
[email protected] wrote:

>Hello,
>
>I am trying to configure a low latency interrupt to detect change in GPIO 
>input pin i.e. input to Beagle Bone AI changes from 0 ->1 or 1-> 0 , it 
>should generate an interrupt. I want to do this preferably in PRU by 
>implementing an ISR .
>
>Do you have an example code?


        Everything I've read indicates that the PRUs do not have true
interrupts. One writes a polling loop looking for a change of state.

        There does appear to be a way for the PRU to interrupt the ARM (after
the polling loop detects the state change), however...
https://processors.wiki.ti.com/index.php/PRU_Linux-based_Example_Code#PRU_PRUtoARM_Interrupt
https://git.ti.com/cgit/pru-software-support-package/pru-software-support-package/tree/examples/am335x
{I don't like that example -- they are writing to memory /after/ generating
the interrupt signal; if the ARM response is fast enough, it could be
reading that memory before the PRU writes to it!}

        All the other mentions of "interrupt" on the PRU contain the phrase
"polling".

https://git.ti.com/cgit/pru-software-support-package/pru-software-support-package/tree/examples/am335x/PRU_ARMtoPRU_Interrupt/PRU_ARMtoPRU_Interrupt.c
-=-=-=-
/*
 * NOTE!
 * This example is no longer supported. It interacts with ARM side code
 * that no longer exists. It is only included as a potential reference.
 */

<SNIP>

        /* Wait until receipt of interrupt on host 0 */
        while ((__R31 & 0x40000000) == 0) {
        }
-=-=-=-


        Unfortunately, those pages also seem to be based on the UIO PRUSS
system, which I think is deprecated and RemoteProc is the "current" scheme.

http://software-dl.ti.com/processor-sdk-linux/esd/docs/latest/linux/Foundational_Components_PRU-ICSS_PRU_ICSSG.html#getting-started-with-pru-icss


-- 
Dennis L Bieber

-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beagleboard/8thpgf5b4mdfll2snhak3jhmln76m2fot8%404ax.com.

Reply via email to