MCUXpresso IDE v11.0.1 [Build 2563] [2019-09-01]
C++ FreeRTOS, SDK
Segger j-link Plus
MKL16Z256 on the board. MKL26Z256 in the project.
MCUXpresso SDK: SDK_2.x_MKL26Z256xxx4
I have added the COP to my project uses the watchdog, calling COP_Init(SIM) and COP_Refresh(SIM).
Start code
COP_GetDefaultConfig(&m_configCop);
m_configCop.enableWindowMode = false;
m_configCop.clockSource = kCOP_LpoClock; // 1 kHz
m_configCop.timeoutCycles = kCOP_2Power10CyclesOr2Power18Cycles; // MAX count - timeout in 1024 mSec
COP_Init(SIM, &m_configCop);
Thread code
calls COP_Refresh(SIM) every 100 mSec.
I tested my code, with COP_Refresh(SIM) commented out, or not commented out.
When the app runs under the debugger in MCUXpresso IDE, the COP does not reset the MCU.
When the app runs without the debugger, the COP is resetting the MCU.
So, I know the COP code is working, but I don't have the debugger working as expected.
From the manual, I expect the MCUXpresso IDE debugger to reset and resume the COP
KL16 Sub-Family Reference Manual, Rev. 3.2, October 2013
3.4.10.2 COP watchdog operation
If the 1 kHz clock source is selected, the COP counter is re-initialized to 0 upon entry to
either Debug mode or Stop (including VLPS or LLS) mode. The counter begins from 0
upon exit from Debug mode or Stop mode.
Is there a way to get the MCUXpresso IDE debugger to work with the COP, as implied in the manual?
Thanks,
Bruce Graham