Hi,
I use the CAN wakeup interrupt to wake up the s12z from pseudo stop mode.
In the CAN receive ISR,I use the instruction “STOP” to make the cpu into the pseudo stop mode:
interrupt void CAN_Receive_IRQHandle(void){
....
EnableInterrupts;
asm ANDCC #0x7F;
asm STOP;
......
}
I find the CPU enter the pseudo stop mode successfully,but I can not wake up the CPU by CAN wakeup interrupt.
In addition,if I write the instruction “STOP” in the “main” function,the CPU is waken up successfully.
I want to known whether I can "STOP" in the ISR,and what I need to pay attention to?
Hi @SCort_li,
Normally, this ISR can't be preempted by itself or by an interrupt with the same or lower priority.
If you need this ISR to be preempted by itself, you would need to overwrite the Condition Code Register (CCR) of the core, bits IPL[2:0] holds the current priority level.
For more information please refer to CPU S12Z Reference Manual
Regards,
Daniel