Functions | |
| cy_en_sysint_status_t | Cy_SysInt_Init (const cy_stc_sysint_t *config, cy_israddress userIsr) |
| Initializes the referenced interrupt by setting the priority and the interrupt vector. More... | |
| cy_israddress | Cy_SysInt_SetVector (IRQn_Type IRQn, cy_israddress userIsr) |
| Changes the ISR vector for the interrupt. More... | |
| cy_israddress | Cy_SysInt_GetVector (IRQn_Type IRQn) |
| Gets the address of the current ISR vector for the interrupt. More... | |
| void | Cy_SysInt_SetNmiSource (cy_en_sysint_nmi_t nmiNum, IRQn_Type intrSrc) |
| Sets the interrupt source of the CPU core NMI. More... | |
| IRQn_Type | Cy_SysInt_GetNmiSource (cy_en_sysint_nmi_t nmiNum) |
| Gets the interrupt source of the CPU core NMI for the given NMI source number. More... | |
| void | Cy_SysInt_SoftwareTrig (IRQn_Type IRQn) |
| Triggers an interrupt using software (Not applicable for CM0+). More... | |
| cy_en_sysint_status_t Cy_SysInt_Init | ( | const cy_stc_sysint_t * | config, |
| cy_israddress | userIsr | ||
| ) |
Initializes the referenced interrupt by setting the priority and the interrupt vector.
In case of CM33 with Security Extension enabled, if this function is called from secure world then, the parameters are used to configure secure interrupt. If it is called form non-secure world then the parameters are used to configure non-secure interrupt. In case of CM33 without Security Extension, this function always configures the non-secure interrupt. In case of CM55, this function always configures the non-secure interrupt.
Use the CMSIS core function NVIC_EnableIRQ(config.intrSrc) to enable the interrupt.
| config | Interrupt configuration structure |
| userIsr | Address of the ISR |
| cy_israddress Cy_SysInt_SetVector | ( | IRQn_Type | IRQn, |
| cy_israddress | userIsr | ||
| ) |
Changes the ISR vector for the interrupt.
CM33:
When called from secure world. this function relies on the assumption that the vector table is relocated to __s_vector_table_rw[] in secure SRAM. Otherwise it will return the address of the default ISR location in the secure flash/ROM vector table.
When called from non-secure world. this function relies on the assumption that the vector table is relocated to __ns_vector_table_rw[] in non-secure SRAM. Otherwise it will return the address of the default ISR location in the non-secure flash/ROM vector table.
CM55:
This function relies on the assumption that the vector table is relocated to __ns_vector_table_rw[] in non-secure SRAM. Otherwise it will return the address of the default ISR location in the non-secure flash/ROM vector table.
Use the CMSIS core function NVIC_EnableIRQ(config.intrSrc) to enable the interrupt.
| IRQn | Interrupt source |
| userIsr | Address of the ISR to set in the interrupt vector table |
| cy_israddress Cy_SysInt_GetVector | ( | IRQn_Type | IRQn | ) |
Gets the address of the current ISR vector for the interrupt.
CM33:
When called from the secure world, this function relies on the assumption that the vector table is relocated to __ns_vector_table_rw[] in non-secure SRAM. Otherwise it will return the address of the default ISR location in the flash/ROM vector table.
CM55:
This function relies on the assumption that the vector table is relocated to __ns_vector_table_rw[] in non-secure SRAM. Otherwise it will return the address of the default ISR location in the flash/ROM vector table.
| IRQn | Interrupt source |
| void Cy_SysInt_SetNmiSource | ( | cy_en_sysint_nmi_t | nmiNum, |
| IRQn_Type | intrSrc | ||
| ) |
Sets the interrupt source of the CPU core NMI.
The interrupt source must be a positive number. Setting the value to "unconnected_IRQn" or "disconnected_IRQn" disconnects the interrupt source from the NMI. Depending on the device, the number of interrupt sources that can provide the NMI trigger signal to the core can vary.
| nmiNum | NMI source number. CPUSS_ver2 allows up to 4 sources to trigger the core NMI. |
| IRQn_Type Cy_SysInt_GetNmiSource | ( | cy_en_sysint_nmi_t | nmiNum | ) |
Gets the interrupt source of the CPU core NMI for the given NMI source number.
| nmiNum | NMI source number. CPUSS_ver2 allows up to 4 sources to trigger the core NMI (i.e. #1, 2, 3, 4). |
| void Cy_SysInt_SoftwareTrig | ( | IRQn_Type | IRQn | ) |
Triggers an interrupt using software (Not applicable for CM0+).
| IRQn | Interrupt source |