/* To use, either add this file to the project file list (preferred), or * #include it in a single source file if you are just using * File->CompileToOutput (this works but using the Project feature is better */ /* As is, all interrupts except reset jumps to 0xffff, which is most * likely not going to be useful. To replace an entry, declare your function, * and then change the corresponding entry in the table. For example, * if you have a SCI handler (which must be defined with * #pragma interrupt_handler ...) then in this file: * add * extern void SCIHandler(); * before the table. * In the SCI entry, change: * DUMMY_ENTRY, * to * SCIHandler, */ #if defined(_HC12) /* add any interrupt vectors in here too for HC12 paged compilation */ #pragma nonpaged_function _start #endif // function prototypes extern void ADC_handler(void); extern void SCI1_handler(void); extern void SPI_handler(void); extern void PAIE_handler(void); extern void PAO_handler(void); extern void TOF_handler(void); extern void TC7_handler(void); extern void TC6_handler(void); extern void TC5_handler(void); extern void TC4_handler(void); extern void TC3_handler(void); extern void TC2_handler(void); extern void TC1_handler(void); extern void TC0_handler(void); extern void RTI_handler(void); extern void IRQ_handler(void); extern void XIRQ_handler(void); extern void SWI_handler(void); extern void _start(void); extern void CLM_handler(void); extern void _start(void); // entry point in crt12.s #define DUMMY_ENTRY (void (*)(void))0xFFFF #pragma abs_address:0xffd0 /* change the above address if your vector starts elsewhere */ void (*interrupt_vectors[])(void) = { /* to cast a constant, say 0xb600, use (void (*)())0xb600 */ /* 812A4 vectors starts at 0xff80, but most entries are not used if you use Key Wakeup H, change the start address to 0xffCE and add one entry to the beginning */ DUMMY_ENTRY, /* BDLC */ ADC_handler, /* ADC */ DUMMY_ENTRY, /* RESERVED */ /* COM 1 */ SCI1_handler, /* SCI1 */ SPI_handler, /* SPI */ PAIE_handler, /* PAIE */ PAO_handler, /* PAO */ TOF_handler, /* TOF */ TC7_handler, /* TC7 */ TC6_handler, /* TC6 */ TC5_handler, /* TC5 */ TC4_handler, /* TC4 */ TC3_handler, /* TC3 */ TC2_handler, /* TC2 */ TC1_handler, /* TC1 */ TC0_handler, /* TC0 */ RTI_handler, /* RTI */ IRQ_handler, /* IRQ */ XIRQ_handler, /* XIRQ */ SWI_handler, /* SWI */ DUMMY_ENTRY, /* ILLOP */ _start, /* COP */ CLM_handler, /* CLM */ _start /* RESET */ }; #pragma end_abs_address