This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Interrupt 10 & interrupt 4 clashing?

Hi!

I have the following code:

int fnRIIRQ() interrupt 4
{
LED = !LED;
return;
}

void Dummy5 (void) interrupt 10
{
}

main()
{
while(1);
}


Looking at the code nothing should happen, there is not serial port connected, but initerrupt 4 is triggering (ie. the LED flashes) at a rate of 7.~hz.

If I change interrupt 10 to interrupt 9 then nothing happens as expected.

Q: why is this happening?

Andrew

Parents
  • During initialisation I didn't set TI & RI to 0...

    Hmmm. According to the ADuC824 documentation, the SCON SFR will be set to 0x00 on reset/power-up. So, TI and RI should both be set to 0. You should not need to do that.

    Are you using a monitor or some kind of boot loader?

    Jon

Reply
  • During initialisation I didn't set TI & RI to 0...

    Hmmm. According to the ADuC824 documentation, the SCON SFR will be set to 0x00 on reset/power-up. So, TI and RI should both be set to 0. You should not need to do that.

    Are you using a monitor or some kind of boot loader?

    Jon

Children