what‘s difference between #0x7F and #0x6F in MC9S12ZVLRM

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

what‘s difference between #0x7F and #0x6F in MC9S12ZVLRM

2,877 次查看
jingfang
Contributor IV

It directly affects current in Stop Mode.

 

0 项奖励
回复
3 回复数

2,809 次查看
lama
NXP TechSupport
NXP TechSupport

 

Hi,

 I have checked an errata list.
Have you applied the ADC errata solution...
https://www.nxp.com/docs/en/errata/MSE9S12ZVL_0N22G.pdf

Best regards,

Ladislav

0 项奖励
回复

2,867 次查看
lama
NXP TechSupport
NXP TechSupport

Hi,

You should check whether you are in the stop mode.

Of course it affect Stop mode.

S X – I N Z V C
1 1 - 1  /   /  /  / reset status; Only setup function setup bits S,X,I are important in this case


0x7F - CCR = 0B0111XXXX - clears only S bit, enables Stop instruction and all interrupts are globally masked (disabled), none of the interrupt wakes the MCU up from the STOP mode

0x6F - CCR = 0B0110XXXX - enables STOP instruction as well as all I-bit maskable interrupts. These interrupt wakes the MCU up from the STOP mode.

So it looks like you MCU is periodically entered to STOP mode and woken up from it by some of the enabled interrupts.

Best regards,

Ladislav

 

0 项奖励
回复

2,842 次查看
jingfang
Contributor IV

Dear Ladislav,

         Thanks a lot~

0x6F can slove high current in sotp mode.

The problem steps are as follows:

1. Enable ADC Function

2. Enter Stop Mode

Here is my experiment:

Source Code

Modify

Current in Stop Mode

Customer’s Software

 

NONE

High

 

change “andcc #0x7f –>#0x6f”

High

 

Join Solution provided by NXP

Low

Customer’s Software+ Join Solution provided by NXP

change “andcc #0x6f –>#0x7f”

High

0 项奖励
回复