hsk-libs-dev
270
High Speed Karlsruhe XC878 library collection
|
HSK Shared Interrupt Service Routine implementation. More...
Macros | |
#define | BIT_RMAP 0 |
SYSCON0 Special Function Register Map Control bit. More... | |
#define | BIT_TF2 7 |
T2_T2CON Timer 2 Overflow bit. More... | |
#define | BIT_EXF2 6 |
T2_T2CON T2EX bit. More... | |
#define | BIT_CCTOVF 3 |
T2CCU_CCTCON CCT Overflow bit. More... | |
#define | BIT_NDOV 2 |
FDCON Normal Divider Overflow bit. More... | |
#define | BIT_EOFSYN 4 |
FDCON End of Syn Byte bit. More... | |
#define | BIT_ERRSYN 5 |
FDCON Syn Byte Error bit. More... | |
#define | BIT_CANSRC0 0 |
IRCON2 MultiCAN Node 0 bit. More... | |
#define | BIT_CANSRC1 5 |
IRCON1 Interrupt Flag 1 for MultiCAN bit. More... | |
#define | BIT_CANSRC2 6 |
IRCON1 Interrupt Flag 2 for MultiCAN bit. More... | |
#define | BIT_ADCSR0 3 |
IRCON1 Interrupt Flag 0 for ADC bit. More... | |
#define | BIT_ADCSR1 4 |
IRCON1 Interrupt Flag 1 for ADC bit. More... | |
#define | BIT_EXINT2 2 |
IRCON0 Interrupt Flag for External Interrupt 2 bit. More... | |
#define | BIT_RI 0 |
SCON Serial Interface Receiver Interrupt Flag. More... | |
#define | BIT_TI 1 |
SCON Serial Interface Transmitter Interrupt Flag. More... | |
#define | BIT_TF2 7 |
T2_T2CON Timer 2 Overflow bit. More... | |
#define | BIT_EXF2 6 |
T2_T2CON T2EX bit. More... | |
#define | BIT_NDOV 2 |
FDCON Normal Divider Overflow bit. More... | |
#define | BIT_EOC 2 |
CD_STATC End of Calculation Flag. More... | |
#define | BIT_IRDY 0 |
MDU_MDUSTAT Interrupt on Result Ready bit. More... | |
#define | BIT_IERR 1 |
MDU_MDUSTAT Interrupt on Error bit. More... | |
#define | BIT_EXINT3 3 |
IRCON0 Interrupt Flag for External Interrupt 3 or T2CC0 Capture/Compare Channel bit. More... | |
#define | BIT_EXINT4 4 |
IRCON0 Interrupt Flag for External Interrupt 4 or T2CC1 Capture/Compare Channel bit. More... | |
#define | BIT_EXINT5 5 |
IRCON0 Interrupt Flag for External Interrupt 5 or T2CC2 Capture/Compare Channel bit. More... | |
#define | BIT_EXINT6 6 |
IRCON0 Interrupt Flag for External Interrupt 6 or T2CC3 Capture/Compare Channel bit. More... | |
#define | BIT_CANSRC3 4 |
IRCON2 Interrupt Flag 3 for MultiCAN bit. More... | |
#define | BIT_NMIWDT 0 |
NMISR Watchdog Timer NMI Flag bit. More... | |
#define | BIT_NMIPLL 1 |
NMISR PLL NMI Flag bit. More... | |
#define | BIT_NMIFLASH 2 |
NMISR FLASH Timer NMI Flag bit. More... | |
#define | BIT_NMIVDDP 5 |
NMISR VDDP Prewarning NMI Flag bit. More... | |
#define | BIT_NMIECC 6 |
NMISR ECC NMI Flag bit. More... | |
Functions | |
void | hsk_isr_root1 (void) |
This is a dummy function used for putting register bank 1 using ISRs into a common call tree for C51. More... | |
void | dummy (void) |
This is a dummy function to point unused function pointers to. More... | |
void | nmidummy (void) |
This is a dummy function to point unused function pointers to. More... | |
void | ISR_hsk_isr5 (void) |
Shared interrupt 5 routine. More... | |
void | ISR_hsk_isr6 (void) |
Shared interrupt 6 routine. More... | |
void | ISR_hsk_isr8 (void) |
Shared interrupt 8 routine. More... | |
void | ISR_hsk_isr9 (void) |
Shared interrupt 9 routine. More... | |
void | ISR_hsk_isr14 (void) |
Shared non-maskable interrupt routine. More... | |
Variables | |
volatile struct hsk_isr5_callback | hsk_isr5 = {&dummy, &dummy, &dummy, &dummy, &dummy, &dummy, &dummy} |
Define callback function pointers for ISR 5. More... | |
volatile struct hsk_isr6_callback | hsk_isr6 = {&dummy, &dummy, &dummy, &dummy} |
Define callback function pointers for ISR 6. More... | |
volatile struct hsk_isr8_callback | hsk_isr8 = {&dummy, &dummy, &dummy, &dummy, &dummy, &dummy, &dummy, &dummy, &dummy} |
Define callback function pointers for ISR 8. More... | |
volatile struct hsk_isr9_callback | hsk_isr9 = {&dummy, &dummy, &dummy, &dummy, &dummy} |
Define callback function pointers for ISR 9. More... | |
volatile struct hsk_isr14_callback | hsk_isr14 = {&nmidummy, &nmidummy, &nmidummy, &nmidummy, &nmidummy} |
Define callback function pointers for NMI ISR. More... | |
HSK Shared Interrupt Service Routine implementation.
This contains interrupts, shared between several interrupt sources. These interrupt sources can hook into the ISRs by storing a callback function in the hsk_isr* data structures.
The following table describes what happens up to the point that the NMI ISR starts operation (based on SDCC code):
CCLK Cycles | Task | Instruction | Duration |
---|---|---|---|
0 | Core: Poll interrupt request | 2 | |
2 | Core: Call ISR | lcall | 1 x 4 |
6 | ISR setup: Push registers | 6 x push | 6 x 4 |
30 | ISR setup: Reset PSW | 1 x mov dir,# | 1 x 4 |
34 | ISR: Backup RMAP | … | 3 x 2 + 4 |
44 | ISR: Reset RMAP | … | 2 x 2 + 4 |
52 | ISR: Select callback | … | … |
#define BIT_ADCSR0 3 |
IRCON1 Interrupt Flag 0 for ADC bit.
#define BIT_ADCSR1 4 |
IRCON1 Interrupt Flag 1 for ADC bit.
#define BIT_CANSRC0 0 |
IRCON2 MultiCAN Node 0 bit.
#define BIT_CANSRC1 5 |
IRCON1 Interrupt Flag 1 for MultiCAN bit.
#define BIT_CANSRC2 6 |
IRCON1 Interrupt Flag 2 for MultiCAN bit.
#define BIT_CANSRC3 4 |
IRCON2 Interrupt Flag 3 for MultiCAN bit.
#define BIT_CCTOVF 3 |
T2CCU_CCTCON CCT Overflow bit.
#define BIT_EOC 2 |
CD_STATC End of Calculation Flag.
#define BIT_EOFSYN 4 |
FDCON End of Syn Byte bit.
#define BIT_ERRSYN 5 |
FDCON Syn Byte Error bit.
#define BIT_EXF2 6 |
T2_T2CON T2EX bit.
T2_T2CON Timer 2 External Flag.
#define BIT_EXF2 6 |
T2_T2CON T2EX bit.
T2_T2CON Timer 2 External Flag.
#define BIT_EXINT2 2 |
IRCON0 Interrupt Flag for External Interrupt 2 bit.
#define BIT_EXINT3 3 |
IRCON0 Interrupt Flag for External Interrupt 3 or T2CC0 Capture/Compare Channel bit.
#define BIT_EXINT4 4 |
IRCON0 Interrupt Flag for External Interrupt 4 or T2CC1 Capture/Compare Channel bit.
#define BIT_EXINT5 5 |
IRCON0 Interrupt Flag for External Interrupt 5 or T2CC2 Capture/Compare Channel bit.
#define BIT_EXINT6 6 |
IRCON0 Interrupt Flag for External Interrupt 6 or T2CC3 Capture/Compare Channel bit.
#define BIT_IERR 1 |
MDU_MDUSTAT Interrupt on Error bit.
#define BIT_IRDY 0 |
MDU_MDUSTAT Interrupt on Result Ready bit.
#define BIT_NDOV 2 |
FDCON Normal Divider Overflow bit.
FDCON Overflow Flag in Normal Divider Mode.
#define BIT_NDOV 2 |
FDCON Normal Divider Overflow bit.
FDCON Overflow Flag in Normal Divider Mode.
#define BIT_NMIECC 6 |
NMISR ECC NMI Flag bit.
#define BIT_NMIFLASH 2 |
NMISR FLASH Timer NMI Flag bit.
#define BIT_NMIPLL 1 |
NMISR PLL NMI Flag bit.
#define BIT_NMIVDDP 5 |
NMISR VDDP Prewarning NMI Flag bit.
#define BIT_NMIWDT 0 |
NMISR Watchdog Timer NMI Flag bit.
#define BIT_RI 0 |
SCON Serial Interface Receiver Interrupt Flag.
#define BIT_RMAP 0 |
SYSCON0 Special Function Register Map Control bit.
#define BIT_TF2 7 |
T2_T2CON Timer 2 Overflow bit.
T2_T2CON Timer 2 Overflow/Underflow Flag.
#define BIT_TF2 7 |
T2_T2CON Timer 2 Overflow bit.
T2_T2CON Timer 2 Overflow/Underflow Flag.
#define BIT_TI 1 |
SCON Serial Interface Transmitter Interrupt Flag.
|
private |
This is a dummy function to point unused function pointers to.
void hsk_isr_root1 | ( | void | ) |
This is a dummy function used for putting register bank 1 using ISRs into a common call tree for C51.
|
private |
Shared non-maskable interrupt routine.
This interrupt has the following sources:
|
private |
Shared interrupt 5 routine.
Activate the interrupt by setting ET2 = 1.
This interrupt has the following sources:
|
private |
Shared interrupt 6 routine.
Activate the interrupt by setting EADC = 1.
This interrupt has the following sources:
|
private |
Shared interrupt 8 routine.
Activate the interrupt by setting EX2 = 1.
This interrupt has the following sources:
|
private |
Shared interrupt 9 routine.
Activate the interrupt by setting EXM = 1.
This interrupt has the following sources:
|
private |
This is a dummy function to point unused function pointers to.
volatile struct hsk_isr14_callback hsk_isr14 = {&nmidummy, &nmidummy, &nmidummy, &nmidummy, &nmidummy} |
Define callback function pointers for NMI ISR.
Introduce callback function pointers for NMI ISR.
volatile struct hsk_isr5_callback hsk_isr5 = {&dummy, &dummy, &dummy, &dummy, &dummy, &dummy, &dummy} |
Define callback function pointers for ISR 5.
Introduce callback function pointers for ISR 5.
volatile struct hsk_isr6_callback hsk_isr6 = {&dummy, &dummy, &dummy, &dummy} |
Define callback function pointers for ISR 6.
Introduce callback function pointers for ISR 6.
volatile struct hsk_isr8_callback hsk_isr8 = {&dummy, &dummy, &dummy, &dummy, &dummy, &dummy, &dummy, &dummy, &dummy} |
Define callback function pointers for ISR 8.
Introduce callback function pointers for ISR 8.