Tool/software:
Hi,
I need end to end example (code with eplanations for TI RTOS, not Linux) how to trigger interrupt from PRU to ARM core for am572x
Any reference would be appreciated.
Thanks
Rasty
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Tool/software:
Hi,
I need end to end example (code with eplanations for TI RTOS, not Linux) how to trigger interrupt from PRU to ARM core for am572x
Any reference would be appreciated.
Thanks
Rasty
Hello Rasty,
Please check out the following resources:
For examples, please see the last link which points you to processor_sdk_rtos_am57xx_09_03_00_00/pdk_am57xx_1_0_21/packages/ti/drv/pruss
Under this directory you will find the following example test/am572x/armv7/bios/PRUSS_BasicExample_idkAM572x_wSoCLib_armTestproject.txt
Best,
Josue
Hi
Thank you for reply.
Suggested links ask the same questions like I'm asking "Where all AM57xx resources gone?" https://e2e.ti.com/support/processors-group/processors/f/processors-forum/967529/faq-where-did-the-pru-icss-wiki-go
I checked all available information and 3 AI engines, no help.
It can be part of Ethercat/Ethernet implementation.
Can you attach an example that shows how to generate event from PRU to A15 core? I need to know how to setup both sides.
Thanks
Rasty
Rasty,
Please read through the RTOS documentation and the example I shared was not mentioned previously as you are suggesting.
For examples, please see the last link which points you to processor_sdk_rtos_am57xx_09_03_00_00/pdk_am57xx_1_0_21/packages/ti/drv/pruss
Under this directory you will find the following example test/am572x/armv7/bios/PRUSS_BasicExample_idkAM572x_wSoCLib_armTestproject.txt
-Josue
Hi
Document https://www.ti.com/lit/an/sprach5a/sprach5a.pdf mentions PRU_ARMtoPRU_Interrupt and PRU_PRUtoARM_Interrupt projects.
Where are these 2 examples:
PRU_ARMtoPRU_Interrupt and PRU_PRUtoARM_Interrupt ?
Thanks
Rasty
Rasty,
The document points to the PRU Support Package

If you google this you can get to the examples: https://git.ti.com/cgit/pru-software-support-package/pru-software-support-package/tree/examples?id=50b111e4bfb8e8635e3f9238bdf20a31ee9247dd
I must warn you that these examples have not been supported for a long time now.
See the folowing commit message: https://git.ti.com/cgit/pru-software-support-package/pru-software-support-package/commit/?id=2d6af3cde964c0e94e1e645fad9b2be915d807ff
You are very welcome to review the existing code on older releases. This remains in AS-IS condition.
Best,
Josue
Hi
Thank you very much for link.
This code is for am4xxx. Can I assume that it can be also applied to am57xx ?
I see only PRU side, I do not see ARM side. Is there ARM side?
I'm looking for end-to-end example from mapping of PRU event to some global event (interrupt) through configuration of IRQ multiplexer that maps it to ARM interrupt.
Tyhanks
Rasty
Rasty,
After looking at the PRU Software Support Packages, These APIs were never supported on the AM57x, only AM335x and AM43x. I cannot comment on the code reusability.
I believe the only example of an ARM interrupt with PRU will be in the test previously mentioned. I will check with other PRU owners but what is included in the SDKs is what is part of our standard support.
For examples, please see the last link which points you to processor_sdk_rtos_am57xx_09_03_00_00/pdk_am57xx_1_0_21/packages/ti/drv/pruss
Under this directory you will find the following example test/am572x/armv7/bios/PRUSS_BasicExample_idkAM572x_wSoCLib_armTestproject.txt
-Josue
You may also refer to EtherCAT implementation from C:\ti\PRU-ICSS-EtherCAT_Slave_01.00.10.00\protocols\ethercat_slave\ecat_appl\EcatStack\tiescbsp.c
Following APIs are relevant from ARM side
1. Should I carry about IRQ_CROSSBAR configuration or PRUICSS_registerIrqandler does it transparently for me?
2. I see contradictive descriptions/examples of sending event from PRU
a) just write 16+Event to R31 ?
b) need some specific configuration of INTC of PRU, then write to R31 ?
I see parts of puzzle, but not whole picture
1. PRUICSS_registerIrqHandler(pruIcssHandle,evtOutNum,pruIsrNum,1,1,&Sync0Isr);
2. Board_xbarMpuIrqConfigure(CSL_XBAR_INST_MPU_MAP_PRUSS1_IRQ_HOST3,
CSL_XBAR_PRUSS1_IRQ_HOST3); /* Sync0 ISR */
3. Configuration of INTC at PRU (no source code)
4. writing to _R31 on PRU side to generate event (no source code)
I do not see full picture. Can you clarify? I need end to end example.
Thanks
Rasty