KL03Z: Trouble Keeping Processor in VLPR Mode

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

KL03Z: Trouble Keeping Processor in VLPR Mode

ソリューションへジャンプ
790件の閲覧回数
sarastout-grand
Contributor III

Hello,

I am trying to run my KL03Z processor in VLPR mode instead of RUN mode. I have set my core clock to 4MHz and the bus clock to 1MHz. I have both TPM timers running off an external clock which remains enabled, one of the timers generates an interrupt every now and then. I have set the PMPROT_AVLP bit for VLPR and the PMCTRL_RUNM bits to VLPR mode. I believe this is all I have to do to get into VLPR mode.

When I step through my code using the debugger, I can clearly see that the I'm in the VLPR mode since the current is as I expect it to be. However, when I run the code (i.e. no longer stepping through), the current jumps up to the RUN value.

Something is causing it to exit VLPR mode without my changing the RUNM bit. I understood that KL03 devices would not exit VLPR from an interrupt. Is that true? Is the only way to exit from VLPR with the KL03 is to change the RUNM bit to 00?

Am I missing something?

Thanks,

Sara

ラベル(1)
0 件の賞賛
1 解決策
621件の閲覧回数
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Sara,

The interrupt doesn't transfer the VLPR mode to RUN mode.

Please check below conditions will switch between RUN with VLRP:

pastedImage_2.png

pastedImage_1.png

Please check if there with code to change the SMC_PMCTRL[RUNM] bits value.

Or there with a reset happens.

BTW:

You could refer MCUXpresso SDK for FRDM-KL03Z SDK package, which provided [power_mode_switch] demo.

I also do a test, there doesn't happen you mentioned issue during debug.

The MCUXpresso SDK for FRDM-KL03Z could be downloaded from here.


Have a great day,
Ma Hui

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

元の投稿で解決策を見る

0 件の賞賛
2 返答(返信)
622件の閲覧回数
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Sara,

The interrupt doesn't transfer the VLPR mode to RUN mode.

Please check below conditions will switch between RUN with VLRP:

pastedImage_2.png

pastedImage_1.png

Please check if there with code to change the SMC_PMCTRL[RUNM] bits value.

Or there with a reset happens.

BTW:

You could refer MCUXpresso SDK for FRDM-KL03Z SDK package, which provided [power_mode_switch] demo.

I also do a test, there doesn't happen you mentioned issue during debug.

The MCUXpresso SDK for FRDM-KL03Z could be downloaded from here.


Have a great day,
Ma Hui

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 件の賞賛
621件の閲覧回数
sarastout-grand
Contributor III

Hi Hui,

Thanks, you have confirmed what I understood about exit from VLPR. I have also been able to confirm that I am still in VLPR mode by looking at the PMSTAT register. I had assumed that I wasn't in VLPR  because of the current draw, it is not as I expected to see for VLPR. I have already asked another question about that.

Thanks,

Sara

0 件の賞賛