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.
I am using ccs v6 and msp430 microcontroller. When I set a breakpoint in some routine which is called in main while loop and then debug the code on the target, then after enabling the breakpoint and pressing run the code keeps running in the main routine in a for loop. I have to stop to process there because it doesn't stop at the breakpoint location. It just keeps running in the for loop. Pressing step over or step into has no effect. And also i am getting a symbol like 'i' on that line. It is an optimization problem but this does not affect the working of the code on the target device.
The message that I get upon hovering on the 'i' symbol are:
1) Detected SW delay loop using empty loop. recommend using a timer module instead.
2) Detected loop counting up. Recommend loops count down as detecting zeroes is easier
The lines that are causing the problem in the code are:
while(SVSCTL & SVSFG)
{
SVSCTL &= ~SVSFG;
for(i = 0; i < 10000; i++);
}
Ideally once I press run it should stop at the breakpoint location but that doesn't happen.
Can anybody suggest what I should be doing??
Rohit Shriyan said:the device being used is msp430F47187
ccs version number is 6.0.1.00040
Thanks. Can you also provide a test case (project + source + executable)?
Also, can you try updating your CCS version to the latest?
Yes i have done this while creating the project. In that i had set the optimization level to OFF. Is that one and the same??