20.21 Relocatable Vector Information (interrupt_vector[])
Here, each interrupt handler for relocatable vector of the RX MCU is defined.

If any interrupt occurs whose vector number is not defined here, the system goes down.

Note, the cfg600px does not generate code to initialize the interrupt control registers, the causes of interrupts, etc. for the interrupts defined here. These initialization need to be implemented in the application.

Note Since the vector number from 1 to 8 are reserved by the RI600PX, do not define these vectors. And do not define the vectors which are reserved by the MCU specification.

Format

Parentheses < >show the user input part.

 interrupt_vector[ <1. Vector number> ] {
     entry_address = <2. Interrupt handler entry address (entry_addreess)>;
     os_int        = <3. Kernel interrupt specification (os_int)>;
     pragma_switch = <4. Switch passed to pragma directive (pragma_switch)>;
 };


1 ) Vector number

- Description
Define the vector number.


- Definition format
Numeric value


- Definition range
From 0 to 255


- When omitting
Cannot be omitted.


2 ) Interrupt handler entry address (entry_addreess)

- Description
Define the starting function of the interrupt handler.


- Definition format
Symbol


- Definition range
-


- When omitting
Cannot be omitted.


3 ) Kernel interrupt specification (os_int)

- Description
Interrupts whose interrupt priority level is lower than or equal to the Kernel interrupt mask level (system_IPL) must be defined as the kernel interrupt, and the other interrupts must be defined as the non-kernel interrupt.
Note, when the Kernel interrupt mask level (system_IPL) is 15, all interrupts for relocatable vector must be defined as the kernel interrupt.



- Definition format
Symbol


- Definition range
Select either of the following:


YES: Kernel interrupt

NO: Non-kernel interrupt

- When omitting
Cannot be omitted.


4 ) Switch passed to pragma directive (pragma_switch)

- Description
The cfg600px outputs "#pragma interrupt" directive to handle the function specified by entry_address as a interrupt function to the system information header file kernel_id.h.
The switches passed to this pragma directive should be specified for pragma_switch.



- Definition format
Symbol


- Definition range
The following can be specified. To specify multiple choices, separate each with a comma. However, "ACC" and "NOACC" cannot be specified at the same time.


E: The "enable" switch that permits a multiple interrupt is passed.

F: The "fint" switch that specifies a fast interrupt is passed. Note, a fast interrupt must be handled as non-kernel interrupt (os_int = NO).

S: The "save" switch that limits the number of registers used in the interrupt handler is passed.

ACC: The "acc" switch that guarantees the ACC register in the interrupt handler is passed.

NOACC: The "no_acc" switch that does not guarantee the ACC register in the interrupt handler is passed

- When omitting
No switches are passed.


Note 1 Refer to Table 20-9 for the guarantee of the ACC register.

Table 20-9 Guarantee of the ACC Register

Setting of pragma_switch

"-save_acc" compiler option

Not specified

Specified

Neither "ACC" nor "NOACC" is not specified.

Neither "acc" nor "no_acc" switch is not passed.

The ACC register is not guaranteed.

Neither "acc" nor "no_acc" switch is not passed.

The ACC register is guaranteed.

"ACC" is specified.

The "acc" switch is passed.

The ACC register is guaranteed.

"NOACC" is specified.

The "no_acc" switch is passed.

The ACC register is not guaranteed.



Note 2 When either "CMT0", "CMT1", "CMT2" or "CMT3" is defined as Selection of timer channel for base clock (timer), it is treated that "interrupt_vector[]" is implicitly defined by the following specification.

- Vector number

- CMT0 : 28

- CMT1 : 29

- CMT2 : 30

- CMT3 : 31

- entry_address : The entry address of the base clock interrupt processing routine in the RI600PX

- os_int : YES

- pragma_switch : E,ACC