Hi
I am Using S912ZVCA192 controller. I want the controller to go to sleep mode and then wake it up with Key Wake up Interrupt.
Note:1
I am Using
asm ANDCC #0x7F; //clear S bit - 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.
asm STOP; //STOP mode
to go to sleep mode.
Note:2
I am configuring KWP interrupt before executing the above Instruction.
/*configure port AD for KWU feature*/
DDRAD_DDRADL3 = 0; /* Configure PAD3 as input */
DIENADL_DIENADL3 = 1; /* Pin is configured as digital input */
PERAD_PERADL3 = 0; /* Enable Pull Device on PAD3 */
PPSAD_PPSADL3 = 1; /* Configure interrupt for Rising Edge */
PIEAD_PIEADL3 = 1; /* Enable Interrupt on PAD3 (KWAD3) */
And In ISR of KWP
interrupt VectorNumber_Vportad HLUWAKE_INT(void)
{
PIFADL_PIFADL3=1;
CPMUCOP = 0x01;
CPMUARMCOP = 0x50U;
CPMUARMCOP = 0xA0U;
}
The problem is controller does not enters full stop mode.
Regards
Kiran Bhat