Clearing or setting the I bit in CCR or not, prior to entering the full stop mode (Low Power Mode)?

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

Clearing or setting the I bit in CCR or not, prior to entering the full stop mode (Low Power Mode)?

640件の閲覧回数
adelantesey
Contributor IV

  Hi,

Can anybody help me on whether I should clear or set the I bit in the CCR prior to the execution of the STOP instruction in MS9S12XEG128? I mean should I use
_asm(" andcc #$6f") or _asm(" andcc #$7f") before STOP instruction?

ラベル(1)
1 返信

396件の閲覧回数
ZhangJennie
NXP TechSupport
NXP TechSupport

MCU can enter into stop mode by assembler instruction “asm STOP; //STOP mode”.

Prior to that you have to clear S bit in CCR register for permission stop mode.

For example you can do that by assembler code “asm ANDCC #0x7F; //clear S bit”

clear S bit is to enable the stop mode. If the S bit is not cleared then STOP instruction has no effect and is executed as a dummy instruction NOP.

hope this helps!

==================================================

this answer is for you. if it helps, please click on "correct answer " button. thanks!

Best Regards,

ZhangJun