Cab Jones

Debug stack start off with an ISR at bottom

Discussion created by Cab Jones on Jun 7, 2012
Latest reply on Jun 20, 2012 by bigmac

CW10.2(1.0.0) MC9S08LG32 Win7x64.


How does this happen--and how can I stop it?  Note that main() is called from Viic_isr.  Of course I cannot get any IIC interrupts.


MISTER_MC9S08LG32_PnE U-MultiLink [CodeWarrior Download]  HCS08, MISTER.abs (Suspended)   Thread [ID: 0x0] (Suspended: Signal 'Halt' received. Description: User halted thread.)    4 main() main.c:139 0x8915    3 vprintf() printf.c:548 0x8c96    2 Viic_isr() i2c.c:317 0x87f6    1 0x7F32 (0x7F32)()  0x7f32  C:\Users\John\workspace500\MISTER\MC9S08LG32\MISTER.abs (6/6/12 11:01 PM)

 I don't do a CLI inside of that isr--in fact, this is my beginning Debug stack--before sny code has been executed.  It appearts to make a difference where I put the EnableInterrupts.  This is how this one starts off

void main(void) {  int temp;  int k;  char ch;   chipinit();  startRTC();/*Real-time clock*/  EnableInterrupts  ...

No CLI in chipinit().  Not even any IICC_IICIE--that happens later on.  If I comment out //EnableInterrupts, then the stack is OK.