AnsweredAssumed Answered

Using reset in debugger erases DFlash

Question asked by Rodney McGee on May 12, 2014
Latest reply on May 15, 2014 by Pascal Irrle

I am pretty familiar with "hotsync" debugging a running microcontroller on many different kinds of Freescale parts and family , but the issue I am having is whenever I use the BDM (USBDM or PE Micro Multilink) to debug it erases the DFlash. The trigger for erasure is hitting the reset button in CW. It has no trouble connecting to the device and at no point in time does it ever say erasing or indicate that is it erasing portions of memory in the logs. The program (PFlash) data stays intact.


Steps to reproduce the issue:

1. Program my HCS12XE.

2. Load the data into DFlash via UART. 

3. Hotsync or debug running code.

4. Hit the red reset button, which immediately taking code back to the reset vector, but as a side-effect erases my DFlash. 


Is there anything about the way the memory is setup in my project that would cause the real-time debugger to erase the DFlash upon debugger initiated reset. By the way, it does not happen during a normal power-on or external reset.


Is any more information needed for advice on this issue?