Interrupts HandlingInterrupts occurs when the Real Timer Tmr0 times out and when the UART has a complete byte available for reading. The framework handles those interrupts for you as following:
Registers STATUS and W are saved to the stack and global interrupts are disabled. Then, the source of the interrupt is identified. If it came from the Real Timer, subroutine ISR_Tmr0 is called; if it came from the UART, subroutine ISR_UART is called. These routines in turn make they ways to call user subroutines. More on this in section "Writing your code".
On return, registers STATUS and W are restored from the stack and global interrupts are enabled back.
|