Other Parts Discussed in Thread: SYSCONFIG
Tool/software:
Hello!
I need to synchronize activities between the R5F core and the PRU by means of interrupts.
I have configured the INTC using SysConfig as follows:
Relevant sections of the code running on R5:
{ ... gPruIcss0Handle = PRUICSS_open(CONFIG_PRU_ICSS0); PRUICSS_registerIrqHandler(gPruIcss0Handle, 0, 16, 16, 0, (void*) &finished); PRUICSS_intcInit(gPruIcss0Handle, &icss0_intc_initdata); status = PRUICSS_initMemory(gPruIcss0Handle, PRUICSS_DATARAM(PRUICSS_PRU0)); DebugP_assert(status != 0); status = PRUICSS_initMemory(gPruIcss0Handle, PRUICSS_DATARAM(PRUICSS_PRU1)); DebugP_assert(status != 0); status = PRUICSS_loadFirmware(gPruIcss0Handle, PRUICSS_PRU0, PRU0Firmware_0, sizeof(PRU0Firmware_0)); DebugP_assert(SystemP_SUCCESS == status); status = PRUICSS_loadFirmware(gPruIcss0Handle, PRUICSS_PRU1, PRU1Firmware_0, sizeof(PRU1Firmware_0)); DebugP_assert(SystemP_SUCCESS == status); PRUICSS_sendEvent(CONFIG_PRU_ICSS0, 0); // this is repeatedly called in application code ... } void finished(void) { PRUICSS_clearEvent(CONFIG_PRU_ICSS0, 1); DebugP_log("ISR Fired \r\n"); ... }
Relevant section of code running on PRU:
mainLoop: ... ldi r0.w0, 0x21 mov r31, r0 l_wait_for_ARM: qbbs l_start, r31, 30 jmp l_wait_for_ARM l_start: ... qba mainLoop
I don't see "ISR Fired" appear on the console - implying that the ISR isn't firing.
Please help me resolve this issue.
Also, is there any example project showcasing the configuration of INTC?
Thanks,
Dhruva