Other Parts Discussed in Thread: AM2634, , SYSCONFIG
Hi,
I would like to activate the "transfer completion interrupt" of the eDMA on the Sitara AM2634 to trigger the PRU-CPUs and not any of the R5F CPUs.
For that purpose, I have used the "eDMA (intermediate) interrupt transfer" example available in the SDK "MCU-PLUS-SDK-AM263X". I identified that these code is used to trigger interrupt:
EDMA_ccPaRAMEntry_init(&edmaParam);
// code removed for clarity
edmaParam.opt |=
(EDMA_OPT_TCINTEN_MASK | EDMA_OPT_ITCINTEN_MASK |
((((uint32_t)tcc) << EDMA_OPT_TCC_SHIFT) & EDMA_OPT_TCC_MASK)); // enable interrupt in the PaRAM
/* Register interrupt */
intrObj.tccNum = tcc;
intrObj.cbFxn = &EDMA_regionIsrFxn;
intrObj.appData = (void *) &gEdmaTestDoneSem;
status = EDMA_registerIntr(gEdmaHandle[0], &intrObj);
DebugP_assert(status == SystemP_SUCCESS);
With that code, I was able to trigger the events 32 to 48 in the PRU interrupt controller with the right XBAR configuration! Unfortunately, each time the interrupt is triggered, the function EDMA_regionIsrFxn() is executed on the R5F processor on which I run the example.
Therefore, I tried to investigate what is doing the function EDMA_registerIntr() and to avoid enabling the interrupt in the R5F and I tried this code:
// get base objects of eDMA
baseAddr = EDMA_getBaseAddr(gEdmaHandle[0]);
regionId = EDMA_getRegionId(gEdmaHandle[0]);
tcc = EDMA_RESOURCE_ALLOC_ANY;
EDMA_ccPaRAMEntry_init(&edmaParam);
// code removed for clarity
edmaParam.opt |=
(EDMA_OPT_TCINTEN_MASK | EDMA_OPT_ITCINTEN_MASK |
((((uint32_t)tcc) << EDMA_OPT_TCC_SHIFT) & EDMA_OPT_TCC_MASK)); // enable interrupt in the PaRAM
/* enable interrupt */
EDMA_enableEvtIntrRegion(baseAddr, regionId, tcc);
Unfortunately, just enabling the event interrupt region does not trigger the interrupts at SoC level. Is there something I missed in order to activate "eDMA (intermediate) interrupt transfer" without executing an IRQ-Routine on the R5F CPU?
Thank you for your help.
Br, Nicolas