I am running into some strange issue with the CLA reading the shared data in CLARAM2, which I make readable from C28 side as follows:
Cla1Regs.MMEMCFG.all = CLA_PROG_ENABLE|CLARAM0_ENABLE|CLARAM1_ENABLE|CLARAM2_ENABLE|CLA_RAM2CPUE;
I put a buffer (type short) that collects ADC data into the shared RAM and at the end of a 60Hz line cycle it is used to calculate the RMS. For testing purposes, I have two identical RMS computing routines running from C28 and CLA (task1). These two routines process the same data buffer configured exactly the same (in CLARAM2). When I run the RMS calculation from the C28 it reads and compute the RMS values with no problem. However, when I try to run the RMS from CLA by calling Cla1ForceTask1(), it always returns zero. I put some breakpoints in the CLA routine and see that when it reads the buffer it always gets zero out of it.
Looking at the map file, I can verify all the CLA program and data to be properly located in the intended memory. The MMEMCFG register looks good through the watch window. Also all CLA and CPU interrupts are checked and the CLA seems to run with no problem.
So why do I see only zero when I try to read it from the CLA, but normal data from the C28?
Thanks in advance,
Erik