Check that the Flash memory is not secured or perform a special Unsecure operation (this erases Flash content). This can happen either by intentionally or accidentally writing to the memory locations managing the Flash security levels.
If a device uses initialization scripts for establishing a debug connection it might display a warning (error line in red color) in the Progress Window if the device is secured.
1.Open Help | Support | Log.
2. Enable log option (27) EVE.
3. Perform Reset action in winIDEA.
4. Check the Progress Window by clicking View | Workspace | Progress for the result of the operation.
The device supports special Unsecure/Chip Erase/Mass Erase operation, that can be initiated when the device is secured to regain debug control.
1. Open Help | Support | Log.
2. Enable log option (27) EVE.
3. Select Hardware | Prepare to Attach to prepare the debugger for connection to the target device.
4. Perform Hardware | Scripts | Unsecure (might also be called Mass Erase or Chip Erase).
5. Check the Progress Window by clicking View | Workspace | Progress for the result of the operation.
Unsecure option might not be available on your microcontroller. See the specific device Reference Manual for more information.
Refer to the topic System reset fails for more information.
Check this general topic on Flash programming.
Open Hardware | <Flash device> | Unsecure.