UG-549
ADuCM310 Hardware Reference Manual
Rev. C | Page 58 of 192
For example, to enable the PWM PAIR0 interrupt source in the NVIC, set ISER1[20] = 1. Similarly, to disable the PWM PAIR0 interrupt, set
ICER1[20] = 1.
Alternatively, CMSIS provides a number of useful NVIC functions in the
core_cm3.h
file. The NVIC_EnableIRQ(PWM_PAIR0_IRQn)
function enables the PWM PAIR0 interrupt. The interrupt can be disabled by calling the NVIC_DisableIRQ(PWM_PAIR0_IRQn) function.
To set the priority of a peripheral interrupt, the IPRx bits can be set appropriately or, alternatively, the NVIC_SetPriority() function can be
called. For example, NVIC_SetPriority(TIMER0_IRQn, 2) configures the GP Timer 0 interrupt with a priority level of 2.
Table 64 lists the registers to enable and disable relevant interrupts and set the priority levels. The registers in Table 64 are defined in the
CMSIS
core_cm3.h
file, which is shipped with tools from third party vendors.
Table 64. NVIC Registers
Address
Analog Devices
Header File Name Description
Access
0xE000E004
ICTR
Shows the number of interrupt lines that the NVIC supports.
R
0xE000E010
STCSR
SYSTICK control and status register.
RW
0xE000E014
STRVR
SYSTICK reload value register.
RW
0xE000E018
STCVR
SYSTICK current value register.
RW
0xE000E01C
STCR
SYSTICK calibration value register.
R
0xE000E100
ISER0
Set IRQ0 to IRQ31 enable. Each bit corresponds to Interrupt 0 to Interrupt 31 in Table 63.
RW
0xE000E104
ISER1
Set IRQ32 to IRQ54 enable. Each bit corresponds to interrupt 32 to Interrupt 54 in Table 63.
RW
0xE000E180
ICER0
Clear IRQ0 to IRQ31 by setting the appropriate bit. Each bit corresponds to Interrupt 0 to
Interrupt 31 in Table 63
RW
0xE000E184
ICER1
Clear IRQ32 to IRQ54 by setting the appropriate bit. Each bit corresponds to Interrupt 32 to
Interrupt 54 in Table 63.
RW
0xE000E200
ISPR0
Set IRQ0 to IRQ31 pending. Each bit corresponds to Interrupt 32 to Interrupt 38 in Table 63.
RW
0xE000E204
ISPR1
Set IRQ32 to IRQ54 pending. Each bit corresponds to Interrupt 32 to Interrupt 54 in Table 63.
RW
0xE000E280
ICPR0
Clear IRQ0 to IRQ31 pending. Each bit corresponds to Interrupt 32 to Interrupt 38 in Table 63.
RW
0xE000E284
ICPR1
Clear IRQ32 to IRQ54 pending. Each bit corresponds to Interrupt 32 to Interrupt 54 in Table 63.
RW
0xE000E300
IABR0
IRQ0 to IRQ31 active bits.
RW
0xE000E304
IABR1
IRQ32 to IRQ54 active bits.
RW
0xE000E400
IPR0
IRQ0 to IRQ3 priority.
RW
0xE000E404
IPR1
IRQ4 to IRQ7 priority.
RW
0xE000E408
IPR2
IRQ8 to IRQ11 priority.
RW
0xE000E40C
IPR3
IRQ12 to IRQ15 priority.
RW
0xE000E410
IPR4
IRQ16 to IRQ19 priority.
RW
0xE000E414
IPR5
IRQ20 to IRQ23 priority.
RW
0xE000E418
IPR6
IRQ24 to IRQ27 priority.
RW
0xE000E41C
IPR7
IRQ28 to IRQ31 priority.
RW
0xE000E420
IPR8
IRQ32 to IRQ35 priority.
RW
0xE000E424
IPR9
IRQ36 to IRQ39 priority.
RW
0xE000E428
IPR10
IRQ40 to IRQ43 priority.
RW
0xE000E42C
IPR11
IRQ44 to IRQ47 priority.
RW
0xE000E430
IPR12
IRQ48 to IRQ51 priority.
RW
0xE000E434
IPR13
IRQ52 to IRQ54 priority.
RW
0xE000ED00 CPUID
CPUID base register.
R
0xE000ED04 ICSR
Interrupt control and status register.
RW
0xE000ED08 VTOR
Vector table offset register.
RW
0xE000ED0C AIRCR
Application interrupt/reset control register.
RW
0xE000ED10 SCR
System control register.
RW
0xE000ED14 CCR
Configuration control register.
RW
0xE000ED18 SHPR1
System Handlers Register 1.
RW
0xE000ED1C SHPR2
System Handlers Register 2.
RW
0xE000ED20 SHPR3
System Handlers Register 3.
RW
0xE000ED24 SHCRS
System handler control and state.
RW
0xE000ED28 CFSR
Configurable fault status.
RW