If a user does not want to use the
R5FSS_VIM_IRQVEC register, the VIM may be used as a more traditional interrupt
controller. Note that in this mode, there is no hardware priority masking (because
the R5FSS_VIM_IRQVEC register is never read). Software would be responsible for
doing all priority operations.
- Determine which interrupt to service
- Read the R5FSS_VIM_PRIIRQ register to determine
which interrupt is the highest priority IRQ currently asserted, OR
- Optionally read the R5FSS_VIM_IRQGSTS register to
determine which groups have IRQs pending, then read the
R5FSS_VIM_IRQSTS_j register and use a software prioritization scheme to
determine which IRQ to service
- Service the interrupt
- Depending on whether the original source of the interrupt was a pulse or a level
- Pulse
- Clear the status by writing a '1' to the
appropriate bit in the R5FSS_VIM_STS_j register, or
R5FSS_VIM_IRQSTS_j register
- Clear the interrupt at the source.
- Level
- Clear the interrupt at the source
- Clear the status by writing a '1' to the
appropriate bit in the R5FSS_VIM_STS_j register, or
R5FSS_VIM_IRQSTS_j register