We are using TMS320F28375D DSP for our product.
In the firmware of this product, we are using CLA for control loop.
For that we have used three local memory which are RAMLS2,RAMLS3, and RAMLS4 for CLA program
and RAMLS0 and RAMLS1 for CLA Ram memory.
In our program we have combined these 3 local ram into RAMLS2 in "2837x_FLASH_lnk_cpu1.cmd" file as shown below.
RAMLS0 : origin = 0x008000, length = 0x001000
//RAMLS1 : origin = 0x008800, length = 0x000800
RAMLS2 : origin = 0x009000, length = 0x001800
//RAMLS3 : origin = 0x009800, length = 0x001000
//RAMLS4 : origin = 0x00A000, length = 0x000800
Now we have assigned 2 functions of CLA to ram as shown below.
#pragma CODE_SECTION(Cla1Task2, "Cla1Prog"); // memory used for this function is 2480 bytes
#pragma CODE_SECTION(calc_PR_CLA, "Cla1Prog"); // memory used for this function is 2430 bytes
Now the function which we have developed "calc_PR_CLA" malfunction at one specific code line.if we remove that line and put at the separate location of same function it did work.
So can this be due to memory related issue as memory of function is larger than any single local memory (for example RAMLS2 = 2048 bytes)
Is it advicable to combine local memory in firmware?