Designing Your Model: Model-Code Correspondence : Activity Charts : ISR (Interrupt Service Routine) Activities : ISR Categories

ISR Categories

For OSEK 2.0, three ISR categories can be used: 1, 2, and 3.

The decision of which ISR category to use depends on the content of the functions it runs. According to the OSEK/OS specification, an OS API function cannot be called from a category 1 ISR. For categories 2 and 3, some OS API functions can be called, but only within code sections marked by EnterISR()/LeaveISR() calls.

The following are some code examples for different types of ISRs: