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.

Compiler/TMS320F28335: Facing problem while executing from FLASH

Part Number: TMS320F28335


Tool/software: TI C/C++ Compiler

I am new to programming, I am trying to test a code in TMS320F28335 experimenter kit,

code contain 3 ISR - timer0 (5s), timer1 (25ms) and SCI

in timer0 --> toggling GPIO31, timer1 --> CpuTimer1.InterruptCount++, In SCI ISR --> if (message[n][index]!= '\0') SciaRegs.SCITXBUF= message[n][index++];

Program run perfectly from RAM, but when I switch to FLASH facing some issues

while(1)
{
SciaRegs.SCITXBUF=message[n][index++];

while(CpuTimer1.InterruptCount < 40)
{

}
index = 0;
CpuTimer1.InterruptCount = 0;
n++;
if(n == SCIMAX) n = 0;
}

While running from FLASH, CpuTimer1.InterruptCount is keep incrementing not resetting after 40, I tried using a another variable instead of CpuTimer1.InterruptCount (which increment in timer ISR and used in while condition) --> working.

What is the issue while using CpuTimer1.InterruptCount

 

Thanks and regards

Shinto