TigerSHARC Hardware Interrupt - Generate Interrupt Service Routine

Library

TigerSHARC DSP Support in Embedded IDE Link VS

Description

Create interrupt service routines (ISR) in the software generated by the build process. When you incorporate this block in your model, code generation results in ISRs on the processor that run the processes that are downstream from the this block or an Idle Task block connected to this block.

Dialog Box

Interrupt numbers

Specify an array of interrupt numbers for the interrupts to install. The valid interrupts are 2, 3, 6-9, 14-17, 22-25, 29-32, 37, 38, 41-44, 52.

The width of the block output signal corresponds to the number of interrupt numbers specified in this field. Combined with the Simulink task priorities that you enter and the preemption flag you enter for each interrupt, these three values define how the code and processor handle interrupts during asynchronous scheduler operations.

Simulink task priorities

Each output of the Hardware Interrupt block drives a downstream block (for example, a function call subsystem). Simulink model task priority specifies the priority of the downstream blocks. Specify an array of priorities corresponding to the interrupt numbers entered in Interrupt numbers.

Simulink model task priority values are required to generate the proper rate transition code (refer to Rate Transitions and Asynchronous Blocks in the Real-Time Workshop documentation). The task priority values are also required to ensure absolute time integrity when the asynchronous task needs to obtain real time from its base rate or its caller. Typically, you assign priorities for these asynchronous tasks that are higher than the priorities assigned to periodic tasks.

Preemption flags preemptible – 1, non-preemptible – 0

Higher priority interrupts can preempt interrupts that have lower priority. To allow you to control preemption, use the preemption flags to specify whether an interrupt can be preempted.

Entering 1 indicates that the interrupt can be preempted. Entering 0 indicates the interrupt cannot be preempted. When Interrupt numbers contains more than one interrupt priority, you can assign different preemption flags to each interrupt by entering a vector of flag values, corresponding to the order of the interrupts in Interrupt numbers. If Interrupt numbers contains more than one interrupt, and you enter only one flag value in this field, that status applies to all interrupts.

In the default settings [0 1], the interrupt with priority 15 in Interrupt numbers is not preemptible and the priority 42 interrupt can be preempted.

Enable simulation input

When you select this option, Simulink software adds an input port to the Hardware Interrupt block. This port is used in simulation only. Connect one or more simulated interrupt sources to the simulation input.

  


 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS