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'm building and executing code for the MSP430F415 processor using CCSv4 with the MSP-FET430UIF JTAG debugger. In the initialization code prior to entering the main() loop, I have a few memset() calls to clear out some buffers. On the first memset() call, the return address gets corrupted on the stack as soon as I step into the memset() call from the main() function. This causes the code to jump into the weeds when memset() returns. The corrupted return address is not always the same and sometimes it even points to a RAM location. I don't see this problem when the target is running without the debugger attached. It isn't a stack overflow issue because only about 4 stack bytes (of the 80 bytes available) are being used at this point in the code.
Anyone had similar problems with this debugger? Other ideas?
Thanks.
--------------------------------------------
A little additional information... This isn't only caused by a memset() call. I substituted a dummy function call and it does the same thing. If I single step into the function call, the return address on the stack is the start address of the function I stepped into, rather than the next line of code after the call to this dummy function. This strengthens my suspicion the debugger is responsible.
**Attention** This is a public forum