mc9s12 wake up by irq

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

mc9s12 wake up by irq

673 Views
burnyfu
Contributor II

Hi,

   I  used mc9s12xs128 microcontroller.The microcontroller can enter the stop mode and i want use irq to wake up it.But the irq not work.In normal mode,the irq is ok.

   Help me think about the solution to the problem.Thank you!

0 Kudos
3 Replies

454 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi,

Can you be more specific? Which interrupt do you use?

If I understand, the interrupt works, but you cannot wake the MCU, right?

Regards,

Daniel

0 Kudos

454 Views
burnyfu
Contributor II

Hi,

   I used PP0 pins as IRQ interrupt.The enter stop mode code is as follows

asm ANDCC #0x7F; //clear S bit
asm nop;
asm STOP; //STOP mode

My IRQ interrupt function do nothing.  It's right?

0 Kudos

454 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hi,

IRQ interrupt is associated with the IRQ pin. But you want to use Port P interrupt.

These are two different interrupts.

Regarding the Port P interrupt, you only need to enable the interrupt in PIEP register, select polarity in PPSP register and use correct interrupt vector.

 

Regards,

Daniel

0 Kudos