Hello,
I am working DEMO9S08SH8 development board with CW V6.3.
My GPIO interrupt is not working. my code is ,
void main()
{
PTBSC_PTBIE = 0; // Disable interrupt
PTBPS_PTBPS0 = 1; // PortB, bit-0 is enabled for interrupt
PTBSC_PTBMOD = 0; // edges only
PTBES_PTBES0 = 0; // interrupt on falling edge
PTBSC_PTBACK = 1; // acknowledge flag
PTBSC_PTBIE = 1; // enable interrupt
EnableInterrupts;
for(;;)
{
;
}
}
interrupt 21 void PORTB_ISR(void)
{
PTBSC_PTBACK = 1; // acknowledge flag
}
Please any one help me