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.
Are there issues calling devicelib functions from CLA Tasks?
I am running into an issue similar to another thread, where I am trying to trigger a CLA task from an EPWM interrupt.
(The referenced thread: https://e2e.ti.com/support/microcontrollers/c2000-microcontrollers-group/c2000/f/c2000-microcontrollers-forum/647529/ccs-tms320f28377d-epwm-trigger-cla-task-problem)
The other thread suggested clearing the EPWM interrupt flag in the ETFLG register (using ETCLR), but the example given used
EPwmxRegs.ETCLR.bit.INT = 1
Trying the devicelib method
EPWM_clearEventTriggerInterruptFlag(EPWM1_BASE);
...does not seem to work.
(I think another issue that I'm running into is the code (and me) was getting confused trying to use both devicelib.h and F2837xD_device.h. I have been trying to not use F2837xD_device.h)
Thanks!
F2837xD_device.h is used when you are using the bitfields struct way of accessing registers (EPwmxRegs.ETCLR.bit.INT = 1)
Are you using both bitfields and driverlib functions in your application?
CLA can invoke driverlib functions as long as CLA has access to that peripherals and the function is an inline function.
Let me get back to you on why dirverlib call does not work whereas it works with bitfield struct access (clearly CLA seems to have access to that register)
Regards,
Veena