17.1 Interrupt Operation

The compiler incorporates features allowing interrupts to be fully handled from C/C++ code. Interrupt code is the name given to any code that executes as a result of an interrupt occurring. Interrupt code completes at the point where the corresponding return from interrupt instruction is executed. This contrasts with main-line code, which, for a freestanding application, is usually the main part of the program that executes after Reset.

Each interrupt typically has a control bit in a special function register (SFR) that can disable that interrupt source. Most also have a configurable priority level. Check your device data sheet and the appropriate technical reference manual for full information on how your device handles interrupts.