I am trying to place a MK60DN512VLQ10 in Very Low Power Run mode using CodeWarrior 10.7 and am having difficulty.
The methods tab has function calls to do this, but it needs a very low power mode clock configuratin that I can not find.
I have tried App note methods for changing from PEE clock mode to BLPE (or BLPI) mode but it always locks up during a loop:
<while((MCG_S & 0x0CU) != 0x08U) { /* Wait until external reference clock is selected as MCG output */>
and it changes through BPE mode, with or without this mode being in the clock configuration.
I got advice through a representitive to:
“The SDK provides API's for the use of different power modes and examples for your application. For example, if you want to set the SMC_PMPROT to allow all power modes you may use the function SMC_SetPowerModeProtection(SMC, kSMC_AllowPowerModeAll); Here you can download the SDK for your device https://mcuxpresso.nxp.com/en/welcome
The config tool available at MCUXpresso will allow configure your mcu in an easy way. I attached you a picture where I set the micro to run in VLPR at 32.768kHz. I reached this speed by using the RTC to set the System/Core clock to 32. 768kHz. For more detailed information about this tool please refer to https://www.nxp.com/docs/en/user-guide/GSMCUXCTUG.pdf ”
I managed to use the MCUXpresso Config Tools v7 to configure the clock as per the picture but the code it compiles calls on calls on header files I do not have.
My question is how can I do this with CodeWarrior, but any help to switch between Run mode and VLPR mode is what I need