Interrupts and events

It describes the details of interrupt and events processing in the code generated by Processor Expert.

An interrupt is a signal that causes the processor stop the execution of the code and execute the Interrupt service routine. When the execution of the code is suspended, the current state of the processor core is saved on the stack. After the execution finishes, the previous state of the processor core is restored from the stack and the suspended program continues from the point where it was interrupted. The signals causing interrupts can be hardware events or software commands. Each interrupt can have an assigned Interrupt Service Routine (ISR) that is called when the interrupt occurs. The table assigning the subroutines to interrupts is called Interrupt Vector Table and it is completely generated by Processor Expert. Most of the interrupts have corresponding Processor Expert Events that allow handling of these interrupts. Processor Expert allows to configure interrupt priorities, if they are supported by the processor. see Processor Expert priority system for details.

Processor Expert Events are part of the Embedded component interface and encapsulate the hardware or software events within the system. Events are offered by the High and Low Level components to help you to service the events without any knowledge of the platform specific code required for such service.

Processor Expert Events can be enabled and disabled and have a user-written program subroutines that are invoked when the event occurs. Events often correspond to interrupts and for that case are invoked from the generated ISR. Moreover, the event can also be a software event caused by a buffer overflow or improper method parameter.