16. Nested vectored interrupt controller (NVIC)

16.1 NVIC main features

The NVIC and the processor core interface are closely coupled, enabling low-latency interrupt processing and efficient processing of late arriving interrupts.

The NVIC registers are banked across secure and nonsecure states. All interrupts including the core exceptions are managed by the NVIC. For more information about NVIC and its registers, refer to the programming manual for Cortex-M33 core (PM0264).

16.2 SysTick calibration value register

The Cortex-M33 with TrustZone mainline security extension embeds two SysTick timers. When TrustZone is activated, the following SysTick timers are available:

When TrustZone is disabled, only one SysTick timer is available.

The SysTick timer calibration value (STCALIB) is 0x3E8. It gives a reference time base of 1 ms based on a SysTick clock frequency of 1 MHz. In order to match the 1 ms time base for an application running at a given frequency, the SysTick reload value must be programmed as follows in the SYST_RVR register:

The HCLK refers to the AHB frequency value in MHz.

Example: SysTick clock source is CPU clock HCLK of 100 MHz, to match a time base of 1 ms: SysTick reload value = \( (100 \times STCALIB) - 1 = 0x1869F \)

For more information about SysTick and its registers, refer to the programming manual for Cortex-M33 core (PM0264).

16.3 Interrupt and exception vectors

The grey rows in the table below indicate core exceptions.

Table 134. STM32U3 series vector table (1)

IRQ numberPriority (2)AcronymDescriptionAddress offset
--4ResetReset0x0000 0004
-14-2NMINon maskable interrupt. The RCC clock security system (CSS) and flash ECC detection interrupts are linked to the NMI vector.0x0000 0008
-13-3 or -1Secure HardFaultSecure hard fault0x0000 000C
-1HardFaultHard fault
-12SettableMemManageMemory management0x0000 0010
-11SettableBusFaultPre-fetch fault, memory access fault0x0000 0014
-10SettableUsageFaultUndefined instruction or illegal state0x0000 0018
-9SettableSecureFaultSecure fault0x0000 001C
---Reserved0x0000 0020 -
0x0000 0028
-5SettableSVCSupervisor call0x0000 002C
-4SettableDebugMonitorDebug monitor0x0000 0030
---Reserved0x0000 0034
-2SettablePendSVPendable request for system service0x0000 0038
-1SettableSysTickSystem tick timer0x0000 003C
0SettableWWDGWindow watchdog interrupt0x0000 0040
1SettablePVD_PVMProgrammable voltage detector/peripheral voltage monitor EXTI16/19/20/21/220x0000 0044
2SettableRTCRTC nonsecure global interrupts0x0000 0048
3SettableRTC_SRTC secure global interrupts0x0000 004C
4SettableTAMPTamper global interrupts0x0000 0050
5SettableRAMCFGRAM configuration global interrupt0x0000 0054
6SettableFLASHFlash memory nonsecure global interrupts0x0000 0058
7SettableFLASH_SFlash memory secure global interrupt0x0000 005C
8SettableGTZCGTZC1 global interrupt0x0000 0060
9SettableRCCRCC nonsecure global interrupt0x0000 0064
Table 134. STM32U3 series vector table (1) (continued)
IRQ numberPriority (2)AcronymDescriptionAddress offset
10SettableRCC_SRCC secure global interrupt0x0000 0068
11SettableEXTI0EXTI line0 interrupt0x0000 006C
12SettableEXTI1EXTI line1 interrupt0x0000 0070
13SettableEXTI2EXTI line2 interrupt0x0000 0074
14SettableEXTI3EXTI line3 interrupt0x0000 0078
15SettableEXTI4EXTI line4 interrupt0x0000 007C
16SettableEXTI5EXTI line5 interrupt0x0000 0080
17SettableEXTI6EXTI line6 interrupt0x0000 0084
18SettableEXTI7EXTI line7 interrupt0x0000 0088
19SettableEXTI8EXTI line8 interrupt0x0000 008C
20SettableEXTI9EXTI line9 interrupt0x0000 0090
21SettableEXTI10EXTI line10 interrupt0x0000 0094
22SettableEXTI11EXTI line11 interrupt0x0000 0098
23SettableEXTI12EXTI line12 interrupt0x0000 009C
24SettableEXTI13EXTI line13 interrupt0x0000 00A0
25SettableEXTI14EXTI line14 interrupt0x0000 00A4
26SettableEXTI15EXTI line15 interrupt0x0000 00A8
27SettableIWDGIndependent watchdog interrupt0x0000 00AC
28SettableSAESSecure AES0x0000 00B0
29SettableGPDMA1_CH0GPDMA1 channel 0 global interrupt0x0000 00B4
30SettableGPDMA1_CH1GPDMA1 channel 1 global interrupt0x0000 00B8
31SettableGPDMA1_CH2GPDMA1 channel 2 global interrupt0x0000 00BC
32SettableGPDMA1_CH3GPDMA1 channel 3 global interrupt0x0000 00C0
33SettableGPDMA1_CH4GPDMA1 channel 4 global interrupt0x0000 00C4
34SettableGPDMA1_CH5GPDMA1 channel 5 global interrupt0x0000 00C8
35SettableGPDMA1_CH6GPDMA1 channel 6 global interrupt0x0000 00CC
36SettableGPDMA1_CH7GPDMA1 channel 7 global interrupt0x0000 00D0
37SettableADC1ADC1 global interrupt0x0000 00D4
38SettableDAC1DAC1 global interrupt0x0000 00D8
Table 134. STM32U3 series vector table (1) (continued)
IRQ numberPriority (2)AcronymDescriptionAddress offset
39SettableFDCAN1_IT0FDCAN1 interrupt 00x0000 00DC
40SettableFDCAN1_IT1FDCAN1 interrupt 10x0000 00E0
41SettableTIM1_BRK
TIM1_TERR
TIM1_IERR
TIM1 break
TIM1 transition error
TIM1 index error
0x0000 00E4
42SettableTIM1_UPTIM1 update0x0000 00E8
43SettableTIM1_TRG_COM
TIM1_DIR
TIM1_IDX
TIM1 trigger and commutation
TIM1 direction change interrupt
TIM1 index
0x0000 00EC
44SettableTIM1_CCTIM1 capture compare interrupt0x0000 00F0
45SettableTIM2TIM2 global interrupt0x0000 00F4
46SettableTIM3TIM3 global interrupt0x0000 00F8
47SettableTIM4TIM4 global interrupt0x0000 00FC
48--Reserved0x0000 0100
49SettableTIM6TIM6 global interrupt0x0000 0104
50SettableTIM7TIM7 global interrupt0x0000 0108
51SettableTIM12TIM12 global interrupt0x0000 010C
52--Reserved0x0000 0110
53SettableI3C1_EVI3C1 event interrupt0x0000 0114
54SettableI3C1_ERI3C1 error interrupt0x0000 0118
55SettableI2C1_EVI2C1 event interrupt0x0000 011C
56SettableI2C_ERI2C1 error interrupt0x0000 0120
57SettableI2C2_EVI2C2 event interrupt0x0000 0124
58SettableI2C2_ERI2C2 error interrupt0x0000 0128
59SettableSPI1SPI1 global interrupt0x0000 012C
60SettableSPI2SPI2 global interrupt0x0000 0130
61SettableUSART1USART1 global interrupt0x0000 0134
62SettableUSART2USART2 global interrupt0x0000 0138
63SettableUSART3USART3 global interrupt0x0000 013C
64SettableUART4UART4 global interrupt0x0000 0140
Table 134. STM32U3 series vector table (1) (continued)
IRQ numberPriority (2)AcronymDescriptionAddress offset
65SettableUART5UART5 global interrupt0x0000 0144
66SettableLPUART1LPUART1 global interrupt0x0000 0148
67SettableLPTIM1LPTIM1 global interrupt0x0000 014C
68SettableLPTIM2LPTIM2 global interrupt0x0000 0150
69SettableTIM15TIM15 global interrupt0x0000 0154
70SettableTIM16TIM16 global interrupt0x0000 0158
71SettableTIM17TIM17 global interrupt0x0000 015C
72SettableCOMPCOMP1/COMP20x0000 0160
73SettableUSBUSB global interrupt0x0000 0164
74SettableCRSClock recovery system global interrupt0x0000 0168
75--Reserved0x0000 016C
76SettableOCTOSPI1OCTOSPI1 global interrupt0x0000 0170
77SettableHSP1HSP1 global interrupt0x0000 0174
78SettableSDMMC1SDMMC1 global interrupt0x0000 0178
79--Reserved0x0000 017C
80SettableGPDMA1_CH8GPDMA1 channel 8 interrupt0x0000 0180
81SettableGPDMA1_CH9GPDMA1 channel 9 interrupt0x0000 0184
82SettableGPDMA1_CH10GPDMA1 channel 10 interrupt0x0000 0188
83SettableGPDMA1_CH11GPDMA1 channel 11 interrupt0x0000 018C
84--Reserved0x0000 0190
85--Reserved0x0000 0194
86--Reserved0x0000 0198
87--Reserved0x0000 019C
88SettableI2C3_EVI2C3 event interrupt0x0000 01A0
89SettableI2C3_ERI2C3 error interrupt0x0000 01A4
90SettableSAI1SAI1 global interrupt0x0000 01A8
91--Reserved0x0000 01AC
92SettableTSCTSC global interrupt0x0000 01B0
93SettableAESAES global interrupt0x0000 01B4
Table 134. STM32U3 series vector table (1) (continued)
IRQ numberPriority (2)AcronymDescriptionAddress offset
94SettableRNGRNG global interrupt0x0000 01B8
95SettableFPUFloating point interrupt0x0000 01BC
96SettableHASHHASH interrupt0x0000 01C0
97SettablePKAPKA global interrupt0x0000 01C4
98SettableLPTIM3LPTIM3 global interrupt0x0000 01C8
99SettableSPI3SPI3 global interrupt0x0000 01CC
100SettableI3C2_EVI3C2 event interrupt0x0000 01D0
101SettableI3C2_ERI3C2 error interrupt0x0000 01D4
102SettableTIM8_BRK
TIM8_TERR
TIM8_IERR
TIM8 break
TIM8 transition error
TIM8 index error
0x0000 01D8
103SettableTIM8_UPTIM8 update0x0000 01DC
104SettableTIM8_TRG_COM
TIM8_DIR
TIM8_IDX
TIM8 trigger and commutation
TIM8 direction change interrupt
TIM8 index
0x0000 01E0
105SettableTIM8_CCTIM8 capture compare interrupt0x0000 01E4
106--Reserved0x0000 01E8
107SettableICACHEInstruction cache global interrupt0x0000 01EC
108--Reserved0x0000 01F0
109SettableLCDLCD global interrupt0x0000 01F4
110SettableLPTIM4LPTIM4 global interrupt0x0000 01EC
111--Reserved0x0000 01FC
112SettableADF1ADF1 interrupt0x0000 0200
113SettableADC2ADC2 global interrupt0x0000 0204
114SettableFDCAN2_IT0FDCAN2 interrupt 00x0000 0208
115SettableFDCAN2_IT1FDCAN2 interrupt 10x0000 020C
116SettableI2C4_EVI2C4 event interrupt0x0000 0210
117SettableI2C4_ERI2C4 error interrupt0x0000 0214
118--Reserved0x0000 0218
119SettableSPI4SPI4 global interrupt0x0000 021C
Table 134. STM32U3 series vector table (1) (continued)
IRQ numberPriority (2)AcronymDescriptionAddress offset
120--Reserved0x0000 0220
121--Reserved0x0000 0224
122--Reserved0x0000 0228
123SettablePWRPWR nonsecure interrupt0x0000 022C
124SettablePWR_SPWR secure interrupt0x0000 0230
  1. 1. Some interrupt lines are only available on some STM32U3 series devices. Refer to the device datasheet for availability of associated peripheral. If not present, consider this interrupt line as reserved.
  2. 2. If multiple pending interrupts have the same programmed priority level, the pending interrupt with the lowest IRQ number takes precedence. For example, if both interrupt[n] and interrupt[n+1] are pending and have the same priority, then interrupt[n] is processed before interrupt[n+1]. For further information, refer to the Arm Cortex-M33 technical documentation.