17. Extended interrupts and event controller (EXTI)

The extended interrupts and event controller (EXTI) manages the individual CPU and system wakeup through configurable and direct event inputs. It provides wakeup requests to the power control, and generates an interrupt request to the CPU NVIC and events to the CPU event input. For the CPU an additional event generation block (EVG) is needed to generate the CPU event signal.

The EXTI wakeup requests allow the system to be woken up from Stop modes.

The interrupt request and event request generation can be used also in Run modes.

The EXTI also includes the EXTI mux I/Oport selection.

17.1 EXTI main features

The EXTI main features are the following:

The asynchronous event inputs are classified in two groups:

17.2 EXTI block diagram

The EXTI consists of a register block accessed via an AHB interface, the event input trigger block, the masking block, and EXTI mux as shown in Figure 47.

The register block contains all the EXTI registers.

The event input trigger block provides event input edge trigger logic.

The masking block provides the event input distribution to the different wakeup, interrupt and event outputs, and their masking.

The EXTI mux provides the IO port selection on to the EXTI event signal.

Figure 47. EXTI block diagram

Figure 47. EXTI block diagram. The diagram shows the internal architecture of the EXTI block. It includes an AHB interface connected to Registers, which are also connected to an EXTI mux, Event Trigger, and Masking block. The EXTI mux takes IOPort (15:0) and Configurable event (15:0) as inputs. The Event Trigger takes Direct event(x) and Wakeup signals. The Masking block outputs sys_wakeup, c_wakeup, it_exti_per(y)*, c_evt_exti, and c_evt_rst. The c_evt_exti and c_evt_rst signals pass through a Pulse and EVG block to produce c_event and c_fclk signals, which are then sent to the CPU (rxev, nvic(x), nvic(y)). The PWR block receives sys_wakeup and c_wakeup signals. The EXTI block also has an exti_ilac output and an exti[15:0] output to the interconnect. A note at the bottom left states: * it_exti_per(y) are only available for configurable events (y). The diagram is labeled MSv49347V1.
Figure 47. EXTI block diagram. The diagram shows the internal architecture of the EXTI block. It includes an AHB interface connected to Registers, which are also connected to an EXTI mux, Event Trigger, and Masking block. The EXTI mux takes IOPort (15:0) and Configurable event (15:0) as inputs. The Event Trigger takes Direct event(x) and Wakeup signals. The Masking block outputs sys_wakeup, c_wakeup, it_exti_per(y)*, c_evt_exti, and c_evt_rst. The c_evt_exti and c_evt_rst signals pass through a Pulse and EVG block to produce c_event and c_fclk signals, which are then sent to the CPU (rxev, nvic(x), nvic(y)). The PWR block receives sys_wakeup and c_wakeup signals. The EXTI block also has an exti_ilac output and an exti[15:0] output to the interconnect. A note at the bottom left states: * it_exti_per(y) are only available for configurable events (y). The diagram is labeled MSv49347V1.

Table 110. EXTI pin overview

Pin nameI/ODescription
AHB interfaceI/OEXTI register bus interface. When one event is configured to enable security, the AHB interface supports secure accesses
hclkIAHB bus clock and EXTI system clock
Configurable event(y)IAsynchronous wakeup events from peripherals which do not have an associated interrupt and flag in the peripheral
exti_ilacOIllegal access event
Direct event(x)ISynchronous and asynchronous wakeup events from peripherals which have an associated interrupt and flag in the peripheral
IOPort(n)IGPIOs block IO ports[15:0]
exti[15:0]OEXTI GPIO output port to trigger other IPs
it_exti_per (y)OInterrupts to the CPU associated with Configurable event (y)
c_evt_extiOHigh level sensitive event output for CPU synchronous to hclk
Table 110. EXTI pin overview (continued)
Pin nameI/ODescription
c_evt_rstIAsynchronous reset input to clear c_evt_exti
sys_wakeupOAsynchronous system wakeup request to PWR for ck_sys and hclk
c_wakeupOWakeup request to PWR for CPU, synchronous to hclk
Table 111. EVG pin overview
Pin nameI/ODescription
c_fclkICPU free Running clock
c_evt_inIHigh level sensitive events input from EXTI, asynchronous to CPU clock
c_eventOEvent pulse, synchronous to CPU clock
c_evt_rstOEvent reset signal, synchronous to CPU clock

17.2.1 EXTI connections between peripherals and CPU

The peripherals able to generate wakeup or interrupt events when the system is in Stop mode are connected to the EXTI.

The EXTI configurable event interrupts are connected to the NVIC of the CPU.

The dedicated EXTI/EVG CPU event is connected to the CPU rxev input.

The EXTI CPU wakeup signals are connected to the PWR block, and are used to wake up the system and CPU sub-system bus clocks.

17.2.2 EXTI interrupt/event mapping

The EXTI lines are connected as shown in Table 112: EXTI line connections .

Table 112. EXTI line connections
EXTI lineLine sourceLine type
0-15GPIOConfigurable
16PVD outputConfigurable
17RTCDirect
18RTC secureDirect
19TAMPDirect

Table 112. EXTI line connections (continued)

EXTI lineLine sourceLine type
20TAMP secureDirect
21COMP1 outputConfigurable
22COMP2 outputConfigurable
23I2C1 wakeupDirect
24I2C2 wakeupDirect
25I2C3 wakeupDirect
26USART1 wakeupDirect
27USART2 wakeupDirect
28USART3 wakeupDirect
29USART4 wakeupDirect
30USART5 wakeupDirect
31LPUART1 wakeupDirect
32LPTIM1Direct
33LPTIM2Direct
34USB FS wakeupDirect
35PVM1 wakeupConfigurable
36PVM2 wakeupConfigurable
37PVM3 wakeupConfigurable
38PVM4 wakeupConfigurable
39reservedDirect
40I2C4 wakeupDirect
41UCPD1 wakeupDirect
42LPTIM3 wakeupDirect

17.3 EXTI functional description

Depending on the EXTI event input type and wakeup target(s), different logic implementations are used. The applicable features are controlled from register bits:

Table 113. EXTI event input configurations and register control

Event input typeLogic implementationEXTI_RTSREXTI_FTSREXTI_SWIEREXTI_R/FPREXTI_IMREXTI_EMR (1)
ConfigurableConfigurable event input wakeup logicxxxxxx
DirectDirect event input wakeup logic----xx

1. Only for input events with configuration “rxev generation” enabled.

17.3.1 EXTI configurable event input wakeup

Figure 48 is a detailed representation of the logic associated with configurable event inputs which wakeup the CPU sub-system bus clocks and generated an EXTI pending flag and interrupt to the CPU and or a CPU wakeup event.

Figure 48. Configurable event trigger logic CPU wakeup

Figure 48. Configurable event trigger logic CPU wakeup. This block diagram illustrates the internal logic of the EXTI peripheral. On the left, an 'AHB interface' and 'hclk' clock are connected to a 'Peripheral interface' block. This block contains several registers: 'Falling trigger selection register', 'Rising trigger selection register', 'Software interrupt event register', 'CPU Event mask register', 'CPU Interrupt mask register', and 'Pending request register'. Below these registers, a 'Configurable Event input(y)' is processed by an 'Asynchronous Edge detection circuit' which is reset by 'rst'. The output of this circuit goes through a 'Delay' block and a 'Rising Edge detect Pulse generator' (also reset by 'rst'). The output of the pulse generator is connected to a series of AND gates. One AND gate takes inputs from the 'Software interrupt event register' and the 'Rising Edge detect Pulse generator'. Another AND gate takes inputs from the 'CPU Event mask register' and the 'Rising Edge detect Pulse generator'. The outputs of these AND gates are combined via OR gates to generate 'CPU Event(y)' and 'Other CPU Events(x,y)'. These signals are then processed by a 'Rising Edge detect' block (reset by 'rst') to produce 'c_evt_rst' and 'c_evt_exti'. These signals are then processed by an 'EVG' (Event Vector Generator) block, which also receives 'ck_fclk_c' clock, to produce the final 'c_event' signal. Additionally, the 'CPU Event(y)' and 'Other CPU Events(x,y)' signals are processed by a 'Sync' block to produce 'c_wakeup' and 'sys_wakeup' signals. The 'Pending request register' is also connected to the 'CPU Event(y)' and 'Other CPU Events(x,y)' signals. The diagram is labeled 'EXTI' at the bottom left and 'MS46537V1' at the bottom right.
Figure 48. Configurable event trigger logic CPU wakeup. This block diagram illustrates the internal logic of the EXTI peripheral. On the left, an 'AHB interface' and 'hclk' clock are connected to a 'Peripheral interface' block. This block contains several registers: 'Falling trigger selection register', 'Rising trigger selection register', 'Software interrupt event register', 'CPU Event mask register', 'CPU Interrupt mask register', and 'Pending request register'. Below these registers, a 'Configurable Event input(y)' is processed by an 'Asynchronous Edge detection circuit' which is reset by 'rst'. The output of this circuit goes through a 'Delay' block and a 'Rising Edge detect Pulse generator' (also reset by 'rst'). The output of the pulse generator is connected to a series of AND gates. One AND gate takes inputs from the 'Software interrupt event register' and the 'Rising Edge detect Pulse generator'. Another AND gate takes inputs from the 'CPU Event mask register' and the 'Rising Edge detect Pulse generator'. The outputs of these AND gates are combined via OR gates to generate 'CPU Event(y)' and 'Other CPU Events(x,y)'. These signals are then processed by a 'Rising Edge detect' block (reset by 'rst') to produce 'c_evt_rst' and 'c_evt_exti'. These signals are then processed by an 'EVG' (Event Vector Generator) block, which also receives 'ck_fclk_c' clock, to produce the final 'c_event' signal. Additionally, the 'CPU Event(y)' and 'Other CPU Events(x,y)' signals are processed by a 'Sync' block to produce 'c_wakeup' and 'sys_wakeup' signals. The 'Pending request register' is also connected to the 'CPU Event(y)' and 'Other CPU Events(x,y)' signals. The diagram is labeled 'EXTI' at the bottom left and 'MS46537V1' at the bottom right.
  1. 1. Only for the input events that support CPU rxev generation c_event.

The software interrupt event register allows to trigger configurable events by software, writing the corresponding register bit, irrespective of the edge selection setting.

The rising edge and falling edge selection registers allow the enabling and selection of the configurable event active trigger edge or both edges.

The CPU has its dedicated wakeup (interrupt) mask register and a dedicated event mask registers. The enabled event make it possible to generate an event on the CPU. All events for a CPU are ordered together into a single CPU event signal. The event pending registers (EXTI_RPR and EXTI_FPR) is not set for an unmasked CPU event.

The configurable events have unique interrupt pending request registers, shared by the CPU. The pending register is only set for an unmasked interrupt. Each configurable event provides a common interrupt to the CPU. The configurable event interrupts need to be acknowledged by software in the EXTI_RPR and/or EXTI_FPR registers.

When a CPU wakeup (interrupt) or CPU event is enabled the asynchronous edge detection circuit is reset by the clocked delay and rising edge detect pulse generator. This guarantees that the EXTI hclk clock is woken up before the asynchronous edge detection circuit is reset.

Note: A detected configurable event interrupt pending request, may be cleared by any CPU with the correct access permission. The system is not able to enter into low-power modes as long as an interrupt pending request is active.

17.3.2 EXTI direct event input wakeup

Figure 49 is a detailed representation of the logic associated with direct event inputs waking up the system.

The direct events do not have an associated EXTI interrupt. The EXTI only wakes up the system and CPU sub-system clocks and may generate a CPU wakeup event. The peripheral synchronous interrupt, associated with the direct wakeup event wakes up the CPU.

The EXTI direct event is able to generate a CPU event. This CPU event wakes up the CPU. The CPU event may occur before the associated peripheral interrupt flag is set.

Figure 49. Direct event trigger logic CPU wakeup

Figure 49: Direct event trigger logic CPU wakeup. This block diagram illustrates the logic for generating CPU events and wakeups from direct event inputs. On the left, an 'AHB interface' provides a 'hclk' signal. 'Direct Event input(x)' signals enter the system through a 'Delay' block and an 'Asynchronous Rising Edge detect circuit rst'. These signals are processed by a series of AND and OR gates. The 'Delay' path leads to an AND gate, which also receives inputs from 'CPU Interrupt mask register' and 'CPU Event mask register' (via a 'Peripheral interface'). The output of this AND gate is 'CPU Event(x)'. The 'Asynchronous Rising Edge detect circuit rst' output goes to an OR gate, which also receives 'Other CPU Events(x,y)'. The output of this OR gate is 'CPU Wakeup(x)'. Both 'CPU Event(x)' and 'CPU Wakeup(x)' are processed by a 'Same circuit for Configurable and Direct events' block, which contains 'Rising Edge detect rst' and 'Sync' blocks. The 'Rising Edge detect rst' output is 'c_evt_rst', which goes to an 'EVG' block containing 'ck_folk_c' and 'CPU Rising Edge detect Pulse generator' to produce 'c_event'. The 'Sync' block output is 'c_wakeup', which is ORed with 'Other CPU Wakeups' and 'Wakeups(x)' to produce 'sys_wakeup'. A 'Falling Edge detect Pulse generator' block is also shown, receiving 'hclk' and 'Direct Event input(x)' signals.
Figure 49: Direct event trigger logic CPU wakeup. This block diagram illustrates the logic for generating CPU events and wakeups from direct event inputs. On the left, an 'AHB interface' provides a 'hclk' signal. 'Direct Event input(x)' signals enter the system through a 'Delay' block and an 'Asynchronous Rising Edge detect circuit rst'. These signals are processed by a series of AND and OR gates. The 'Delay' path leads to an AND gate, which also receives inputs from 'CPU Interrupt mask register' and 'CPU Event mask register' (via a 'Peripheral interface'). The output of this AND gate is 'CPU Event(x)'. The 'Asynchronous Rising Edge detect circuit rst' output goes to an OR gate, which also receives 'Other CPU Events(x,y)'. The output of this OR gate is 'CPU Wakeup(x)'. Both 'CPU Event(x)' and 'CPU Wakeup(x)' are processed by a 'Same circuit for Configurable and Direct events' block, which contains 'Rising Edge detect rst' and 'Sync' blocks. The 'Rising Edge detect rst' output is 'c_evt_rst', which goes to an 'EVG' block containing 'ck_folk_c' and 'CPU Rising Edge detect Pulse generator' to produce 'c_event'. The 'Sync' block output is 'c_wakeup', which is ORed with 'Other CPU Wakeups' and 'Wakeups(x)' to produce 'sys_wakeup'. A 'Falling Edge detect Pulse generator' block is also shown, receiving 'hclk' and 'Direct Event input(x)' signals.

1. Only for the input events that support CPU rxev generation c_event.

17.3.3 EXTI mux selection

The EXTI mux allow the selection of GPIOs as interrupts and wakeup. The GPIOs are connected via 16 EXTI mux lines to the first 16 EXTI events as configurable event. The selection of GPIO port as EXTI mux output, is controlled by registers: EXTI external interrupt selection register (EXTI_EXTICRn) .

Figure 50. EXTI mux GPIO selection

Figure 50. EXTI mux GPIO selection diagram showing three multiplexers. The first multiplexer selects between PA0, PB0, PC0, and Px0 to produce EXTI0. The second multiplexer selects between PA1, PB1, PC1, and Px1 to produce EXTI1. The third multiplexer selects between PA15, PB15, PC15, and Px15 to produce EXTI15. Ellipses indicate intermediate pins and lines. The diagram is labeled MS44726V1.
Figure 50. EXTI mux GPIO selection diagram showing three multiplexers. The first multiplexer selects between PA0, PB0, PC0, and Px0 to produce EXTI0. The second multiplexer selects between PA1, PB1, PC1, and Px1 to produce EXTI1. The third multiplexer selects between PA15, PB15, PC15, and Px15 to produce EXTI15. Ellipses indicate intermediate pins and lines. The diagram is labeled MS44726V1.

The EXTI mux outputs are available as output signals from the EXTI to trigger other IPs. The EXTI mux outputs are available independent from any masking in EXTI_IMRx and EXTI_EM Rx.

17.4 EXTI functional behavior

The direct event inputs are enabled in the respective peripheral generating the wakeup event. The configurable events are enabled by enabling at least one of the trigger edges.

Once an event input is enabled, the generation of a CPU wakeup is conditioned by the CPU interrupt mask and CPU event mask.

Table 114. Masking functionality

CPU interrupt enable
EXTI_IMR.IMn
CPU event enable
EXTI_EMR.EMn
Configurable event inputs
EXTI_RPR.RPIFn
EXTI_FPR.FPIFn
exti(n) interrupt (1)CPU eventCPU wakeup
00nomaskedmaskedmasked
1nomaskedyesyes
10status latchedyesmaskedyes (2)
1status latchedyesyesyes

1. The single exti(n) interrupt will go to the CPU. If no interrupt is required for CPU, the exti(n) interrupt shall be masked in the CPU NVIC.

2. Only if CPU interrupt is enabled in EXTI_IMR.IMn.

For configurable event inputs, when the enabled edge(s) occur on the event input, an event request is generated. When the associated CPU interrupt is unmasked the corresponding pending bit EXTI_RPR.RPIFn and/or EXTI_FPR.FPIFn is/are set and the CPU sub-system is woken up and CPU interrupt signal is activated. The EXTI_RPR.RPIFn and/or EXTI_FPR.FPIFn pending bit shall be cleared by software writing it to '1'. This action clears the CPU interrupt.

For direct event inputs, when enabled in the associated peripheral, an event request is generated on the rising edge only. There is no corresponding CPU pending bit in the EXTI.

When the associated CPU interrupt is unmasked, the corresponding CPU sub-system is woken up. The CPU is woken up (interrupted) by the peripheral synchronous interrupt.

The CPU event has to be unmasked to generate an event. When the enabled edge(s) occur on the event input a CPU event pulse is generated. There is no event pending bit.

For the configurable event inputs an event request can be generated by software when writing a '1' in the software interrupt/event register EXTI_SWIER, allowing the generation of a rising edge on the event. The rising edge event pending bit is set in EXTI_RPR, irrespective of the setting in EXTI_RTSR.

17.5 EXTI event protection

The EXTI is able to protect event register bits from being modified by non-secure and unprivileged accesses. The protection can individually be activated per input event via the register bits in EXTI_SECCFGR and EXTI_PRIVCFGR. At EXTI level the protection consists in preventing unauthorized write access to:

Table 115. Register protection overview

Register nameAccess typeProtection (1)(2)
EXTI_RTSRRWSecurity and privilege can be bit wise enabled in EXTI_SECCFGR and EXTI_PRIVCFGR
EXTI_FTSRRW
EXTI_SWIERRW
EXTI_RPRRW
EXTI_FPRRW
EXTI_SECCFGRRWAlways secure, and privilege can be bit wise enabled in EXTI_PRIVCFGR
EXTI_PRIVCFGRRWAlways privilege, and security can be bit wise enabled in EXTI_SECCFGR
EXTI_EXTICRnRWSecurity and privilege can be bit wise enabled in EXTI_SECCFGR and EXTI_PRIVCFGR
EXTI_LOCKRRWAlways secure.
EXTI_IMRWSecurity and privilege can be bit wise enabled in EXTI_SECCFGR and EXTI_PRIVCFGR
EXTI_EMRRW

1. Security is enabled with the individual Input event. EXTI_SECCFG registers.

2. Privilege is enabled with the individual Input event EXTI_PRIVCFGRn registers.

17.5.1 EXTI security protection

When security is enabled for an input event, the associated input event configuration and control bits can only be modified and read by a secure access, a non-secure write access is discarded and a read returns 0.

When input events are non-secure, the security is disabled. The associated input event configuration and control bits can be modified and read by a secure access and non-secure access.

The security configuration in registers EXTI_SECCFGR can be globally locked after reset by EXTI_LOCKR.LOCK.

17.5.2 EXTI privilege protection

When privilege is enabled for an input event, the associated input event configuration and control bits can only be modified and read by a privilege access, an unprivileged write access is discarded and a read returns 0.

When input events are unprivileged, the privilege is disabled. The associated input event configuration and control bits can be modified and read by a privilege access and unprivileged access.

The privilege configuration in registers EXTI_PRIVCFGRn can be globally locked after reset by EXTI_LOCKR.LOCK.

17.6 EXTI registers

The EXTI register map is divided in the following sections:

Table 116. EXTI register map sections

Address offsetDescription
0x000 - 0x01CGeneral configurable event [31:0] configuration
0x020 - 0x03CGeneral configurable event [63:32] configuration
0x060 - 0x06CEXTI IOport mux selection
0x070EXTI protection lock configuration
0x080 - 0x0BCCPU input event configuration

All the registers can be accessed with word (32-bit), half-word (16-bit) and byte (8-bit) access.

17.6.1 EXTI rising trigger selection register (EXTI_RTSR1)

Address offset: 0x000

Reset value: 0x0000 0000

Contains only register bits for configurable events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.RT22RT21Res.Res.Res.Res.RT16
r/wr/wr/w
1514131211109876543210
RT15RT14RT13RT12RT11RT10RT9RT8RT7RT6RT5RT4RT3RT2RT1RT0
r/wr/wr/wr/wr/wr/wr/wr/wr/wr/wr/wr/wr/wr/wr/wr/w

Bits 31:23 Reserved, must be kept at reset value.

Bits 22:21 RT[22:21] : Rising trigger event configuration bit of configurable event input x (1) (where x = 18 to 22)

When SECx is disabled, RTx can be accessed with non-secure and secure access.

When SECx is enabled, RTx can only be accessed with secure access. Non-secure write to this bit x is discarded, non-secure read returns 0.

When EXTI_PRIVCFGn.PRIVx is disabled, RTx can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFGn.PRIVx is enabled, RTx can only be accessed with privilege access. Unprivileged write to this bit x is discarded, unprivileged read returns 0.

Bits 20:17 Reserved, must be kept at reset value.

Bits 16:0 RT[16:0] : Rising trigger event configuration bit of configurable event input x (1) (where x = 0 to 16)

When EXTI_SECCFG SECx is disabled, RTx can be accessed with non-secure and secure access.

When EXTI_SECCFG SECx is enabled, RTx can only be accessed with secure access. Non-secure write to this bit x is discarded, non-secure read returns 0.

When EXTI_PRIVCFG PRIVx is disabled, RTx can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFG PRIVx is enabled, RTx can only be accessed with privilege access. Unprivileged write to this bit x is discarded, unprivileged read returns 0.

  1. 1. The configurable event inputs are edge triggered, no glitch must be generated on these inputs. If a rising edge on the configurable event input occurs during writing of the register, the associated pending bit is not set. Rising and falling edge triggers can be set for the same configurable event input. In this case, both edges generate a trigger.

17.6.2 EXTI falling trigger selection register (EXTI_FTSR1)

Address offset: 0x004

Reset value: 0x0000 0000

Contains only register bits for configurable events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.FT22FT21Res.Res.Res.Res.FT16
rwrwrw
1514131211109876543210
FT15FT14FT13FT12FT11FT10FT9FT8FT7FT6FT5FT4FT3FT2FT1FT0
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw

Bits 31:23 Reserved, must be kept at reset value.

Bits 22:21 FT[22:21] : Falling trigger event configuration bit of configurable event input x (1) (where x = 18 to 22).

When EXTI_SECCFGR.SECx is disabled, FTx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, FTx can only be accessed with secure access. Non-secure write to this FTx is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, FTx can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFGR.PRIVx is enabled, FTx can only be accessed with privilege access. Unprivileged write to this FTx is discarded, unprivileged read returns 0.

0: Falling trigger disabled (for event and Interrupt) for input line
1: Falling trigger enabled (for event and Interrupt) for input line.

Bit 20:17 Reserved, must be kept at reset value.

Bits 16:0 FT[16:0] : Falling trigger event configuration bit of configurable event input x (1) (where x = 0 to 16).

When EXTI_SECCFGR.SECx is disabled, FTx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, FTx can only be accessed with secure access. Non-secure write to this FTx is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, FTx can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFGR.PRIVx is enabled, FTx can only be accessed with privilege access. Unprivileged write to this FTx is discarded, unprivileged read returns 0.

0: Falling trigger disabled (for event and Interrupt) for input line
1: Falling trigger enabled (for event and Interrupt) for input line.

  1. 1. The configurable event inputs are edge triggered, no glitch must be generated on these inputs.
    If a falling edge on the configurable event input occurs during writing of the register, the associated pending bit is not set.
    Rising and falling edge triggers can be set for the same configurable event input. In this case, both edges generate a trigger.

17.6.3 EXTI software interrupt event register (EXTI_SWIER1)

Address offset: 0x008

Reset value: 0x0000 0000

Contains only register bits for configurable events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.SWI22SWI21Res.Res.Res.Res.SWI16
rwrwrw
1514131211109876543210
SWI15SWI14SWI13SWI12SWI11SWI10SWI9SWI8SWI7SWI6SWI5SWI4SWI3SWI2SWI1SWI0
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw

Bits 31:23 Reserved, must be kept at reset value.

Bits 22:21 SWI[22:21] : Software interrupt on event x (where x = 18 to 22)

When EXTI_SECFGR.SECx is disabled, SWIx can be accessed with non-secure and secure access.
When EXTI_SECCFGR.SECx is enabled, SWIx can only be accessed with secure access.
Non-secure write to this SWI x is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, SWIx can be accessed with unprivileged and privilege access.
When EXTI_PRIVCFGR.PRIVx is enabled, SWIx can only be accessed with privilege access.
Unprivileged write to this SWIx is discarded, unprivileged read returns 0.

A software interrupt is generated independent from the setting in EXTI_RTSR and EXTI_FTSR. It always returns 0 when read.

Bit 20:17 Reserved, must be kept at reset value.

Bits 16:0 SWI[16:0] : Software interrupt on event x (where x = 18 to 22)

When EXTI_SECFGR.SECx is disabled, SWIx can be accessed with non-secure and secure access.
When EXTI_SECCFGR.SECx is enabled, SWIx can only be accessed with secure access.
Non-secure write to this SWI x is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, SWIx can be accessed with unprivileged and privilege access.
When EXTI_PRIVCFGR.PRIVx is enabled, SWIx can only be accessed with privilege access.
Unprivileged write to this SWIx is discarded, unprivileged read returns 0.

A software interrupt is generated independent from the setting in EXTI_RTSR and EXTI_FTSR. It always returns 0 when read.

17.6.4 EXTI rising edge pending register (EXTI_RPR1)

Address offset: 0x00C

Reset value: 0x0000 0000

Contains only register bits for configurable events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.RPIF22RPIF21Res.Res.Res.Res.RPIF16
rc_w1rc_w1rc_w1
1514131211109876543210
RPIF15RPIF14RPIF13RPIF12RPIF11RPIF10RPIF9RPIF8RPIF7RPIF6RPIF5RPIF4RPIF3RPIF2RPIF1RPIF0
rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1

Bits 31:23 Reserved, must be kept at reset value.

Bits 22:21 RPIF[22:21] : configurable event inputs x rising edge pending bit (where x = 18 to 22).

When EXTI_SECCFGR.SECx is disabled, RPIFx can be accessed with non-secure and secure access.
When EXTI_SECCFGR.SECx is enabled, RPIFx can only be accessed with secure access.
Non-secure write to this RPIFx is discarded, non-secure read returns 0.
When EXTI_PRIVCFGR.PRIVx is disabled, RPIFx can be accessed with unprivileged and privilege access.
When EXTI_PRIVCFGR.PRIVx is enabled, RPIFx can only be accessed with privilege access.
Unprivileged write to this RPIFx is discarded, unprivileged read returns 0.

This bit is set when the rising edge event or an EXTI_SWIER software trigger arrives on the configurable event line. This bit is cleared by writing a 1 into the bit.

Bit 20:17 Reserved, must be kept at reset value.

Bits 16:0 RPIF[16:0] : configurable event inputs x rising edge pending bit (where x = 0 to 16).

When EXTI_SECCFGR.SECx is disabled, RPIFx can be accessed with non-secure and secure access.
When EXTI_SECCFGR.SECx is enabled, RPIFx can only be accessed with secure access.
Non-secure write to this RPIFx is discarded, non-secure read returns 0.
When EXTI_PRIVCFGR.PRIVx is disabled, RPIFx can be accessed with unprivileged and privilege access.
When EXTI_PRIVCFGR.PRIVx is enabled, RPIFx can only be accessed with privilege access.
Unprivileged write to this RPIFx is discarded, unprivileged read returns 0.

This bit is set when the rising edge event or an EXTI_SWIER software trigger arrives on the configurable event line. This bit is cleared by writing a 1 into the bit.

17.6.5 EXTI falling edge pending register (EXTI_FPR1)

Address offset: 0x010

Reset value: 0x0000 0000

Contains only register bits for configurable events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.FPIF22FPIF21Res.Res.Res.Res.FPIF16
rc_w1rc_w1rc_w1
1514131211109876543210
FPIF15FPIF14FPIF13FPIF12FPIF11FPIF10FPIF9FPIF8FPIF7FPIF6FPIF5FPIF4FPIF3FPIF2FPIF1FPIF0
rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1rc_w1

Bits 31:23 Reserved, must be kept at reset value.

Bits 22:21 FPIF[22:21] : configurable event inputs x falling edge pending bit (where x = 22 to 18)

When EXTI_SECCFGR.SECx is disabled, FPIFx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, FPIFx can only be accessed with secure access.

Non-secure write to this FPIFx is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, FPIFx can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFGR.PRIVx is enabled, FPIFx can only be accessed with privilege access. Unprivileged write to this FPIFx is discarded, unprivileged read returns 0.

0: No falling edge trigger request occurred
1: Rising edge trigger request occurred

This bit is set when the falling edge event arrives on the configurable event line. This bit is cleared by writing a 1 into the bit.

Bit 20:17 Reserved, must be kept at reset value.

Bits 16:0 FPIF[16:0] : configurable event inputs x falling edge pending bit (where x = 0 to 16)

When EXTI_SECCFGR.SECx is disabled, FPIFx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, FPIFx can only be accessed with secure access.

Non-secure write to this FPIFx is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, FPIFx can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFGR.PRIVx is enabled, FPIFx can only be accessed with privilege access. Unprivileged write to this FPIFx is discarded, unprivileged read returns 0.

0: No falling edge trigger request occurred
1: Rising edge trigger request occurred

This bit is set when the falling edge event arrives on the configurable event line. This bit is cleared by writing a 1 into the bit.

17.6.6 EXTI security configuration register (EXTI_SECCFGR1)

Address offset: 0x014

Reset value: 0x0000 0000

This register provides write access security, a non-secure write access is ignored and causes the generation of an illegal access event. A non-secure read returns the register data.

Contains only register bits for security capable input events.

31302928272625242322212019181716
SEC31SEC30SEC29SEC28SEC27SEC26SEC25SEC24SEC23SEC22SEC21SEC20SEC19SEC18SEC17SEC16
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw
1514131211109876543210
SEC15SEC14SEC13SEC12SEC11SEC10SEC9SEC8SEC7SEC6SEC5SEC4SEC3SEC2SEC1SEC0
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw

Bits 31:0 SEC[31:0] : Security enable on event input x (where x = 0 to 31)

When EXTI_PRIVCFGn.PRIVx is disabled, SECx can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGn.PRIVx is enabled, SECx can only be written with privilege access. Unprivileged write to this SECx is discarded.

0: Event security disabled (non-secure)

1: Event security enabled (secure)

17.6.7 EXTI privilege configuration register (EXTI_PRIVCFG1)

Address offset: 0x018

Reset value: 0x0000 0000

This register provides privileged write access protection. An unprivileged read returns the register data.

Contains only register bits for security capable input events.

31302928272625242322212019181716
PRIV31PRIV30PRIV29PRIV28PRIV27PRIV26PRIV25PRIV24PRIV23PRIV22PRIV21PRIV20PRIV19PRIV18PRIV17PRIV16
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw
1514131211109876543210
PRIV15PRIV14PRIV13PRIV12PRIV11PRIV10PRIV9PRIV8PRIV7PRIV6PRIV5PRIV4PRIV3PRIV2PRIV1PRIV0
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw

Bits 31:0 PRIV[31:0] : Security enable on event input x (where x = 0 to 31)

When EXTI_SECCFG.SECx is disabled, PRIVx can be accessed with secure and non-secure access.

When EXTI_SECCFG.SECx is enabled, PRIVx can only be written with secure access. Non-secure write to this PRIVx is discarded.

0: Event privilege disabled (unprivileged)

1: Event privilege enabled (privileged)

17.6.8 EXTI rising trigger selection register (EXTI_RTSR2)

Address offset: 0x020

Reset value: 0x0000 0000

Contains only register bits for configurable events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.Res.RT38RT37RT36RT35Res.Res.Res.
rwrwrwrw

Bits 31:7 Reserved, must be kept at reset value.

Bits 6:3 RT[38:35] : Rising trigger event configuration bit of configurable event input x (1) (where x = 35 to 38).

When EXTI_SECCFGR.SECx is disabled, RTx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, RTx can only be accessed with secure access. Non-secure write to this RTx is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, RTx can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFGR.PRIVx is enabled, RTx can only be accessed with privilege access. Unprivileged write to this RTx is discarded, unprivileged read returns 0.

0: Rising trigger disabled (for event and interrupt) for input line

1: Rising trigger enabled (for event and interrupt) for input line

Bits 2:0 Reserved, must be kept at reset value.

  1. 1. The configurable event inputs are edge triggered, no glitch must be generated on these inputs. If a falling edge on the configurable event input occurs during writing of the register, the associated pending bit is not set. Rising and falling edge triggers can be set for the same configurable event input. In this case, both edges generate a trigger.

17.6.9 EXTI falling trigger selection register (EXTI_FTSR2)

Address offset: 0x024

Reset value: 0x0000 0000

Contains only register bits for configurable events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.Res.FT38FT37FT36FT35Res.Res.Res.
rwrwrwrw

Bits 31:7 Reserved, must be kept at reset value.

Bits 6:3 FT[38:35] : Falling trigger event configuration bit of configurable event input x (1) (where x = 35 to 38)

When EXTI_SECCFGR.SECx is disabled, FTx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, FTx can only be accessed with secure access. Non-secure write to this FTx is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, FTx can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFGR.PRIVx is enabled, FTx can only be accessed with privilege access. Unprivileged write to this FTx is discarded, unprivileged read returns 0.

0: Falling trigger disabled (for event and interrupt) for input line

1: Falling trigger enabled (for event and interrupt) for input line

Bits 2:0 Reserved, must be kept at reset value.

  1. 1. The configurable event inputs are edge triggered, no glitch must be generated on these inputs.
    If a falling edge on the configurable event input occurs during writing of the register, the associated pending bit is not set.
    Rising and falling edge triggers can be set for the same configurable event input. In this case, both edges generate a trigger.

17.6.10 EXTI software interrupt event register (EXTI_SWIER2)

Address offset: 0x028

Reset value: 0x0000 0000

Contains only register bits for configurable events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.Res.SWI38SWI37SWI36SWI35Res.Res.Res.
rwrwrwrw

Bits 31:7 Reserved, must be kept at reset value.

Bits 6:3 SWI[38:35] : Software interrupt on event x (where x = 35 to 38)

When EXTI_SECCFGR.SECx is disabled, SWIx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, SWIx can only be accessed with secure access.

Non-secure write to this SWIx is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, SWIx can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFGR.PRIVx is enabled, SWIx can only be accessed with privilege access.
Unprivileged write to this SWIx is discarded, unprivileged read returns 0.

A software interrupt is generated independent from the setting in EXTI_RTSR and EXTI_FTSR. It always return 0 when read.

0: Writing 0 has no effect.

1: Writing a 1 to this bit triggers a rising edge event on event x+32. This bit is auto cleared by HW.

Bits 2:0 Reserved, must be kept at reset value.

17.6.11 EXTI rising edge pending register (EXTI_RPR2)

Address offset: 0x02C

Reset value: 0x0000 0000

Contains only register bits for configurable events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.Res.RPIF38RPIF37RPIF36RPIF35Res.Res.Res.
rc_w1rc_w1rc_w1rc_w1

Bits 31:7 Reserved, must be kept at reset value.

Bits 6:3 RPIF[38:35] : configurable event inputs x rising edge pending bit (where x = 35 to 38).

When EXTI_SECCFGR.SECx is disabled, RPIFx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, RPIFx can only be accessed with secure access.

Non-secure write to this RPIFx is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, RPIF can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFGR.PRIVx is enabled, RPIFx can only be accessed with privilege access.

Unprivileged write to this RPIFx is discarded, unprivileged read returns 0.

0: No rising edge trigger request occurred

1: Rising edge trigger request occurred

This bit is set when the rising edge event or an EXTI_SWIER software trigger arrives on the configurable event line. This bit is cleared by writing a 1 into the bit.

Bits 2:0 Reserved, must be kept at reset value.

17.6.12 EXTI falling edge pending register (EXTI_FPR2)

Address offset: 0x030

Reset value: 0x0000 0000

Contains only register bits for configurable events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.Res.FPIF38FPIF37FPIF36FPIF35Res.Res.Res.
rc_w1rc_w1rc_w1rc_w1

Bits 31:7 Reserved, must be kept at reset value.

Bits 6:3 FPIF[38:35] : configurable event inputs x pending bit (where x = 35 to 38).

When EXTI_SECCFGR.SECx is disabled, FPIFx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, FPIFx can only be accessed with secure access.

Non-secure write to this FPIFx is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, FPIFx can be accessed with unprivileged and privilege access.

When EXTI_PRIVCFGR.PRIVx is enabled, FPIFx can only be accessed with privilege access. Unprivileged write to this FPIFx is discarded, unprivileged read returns 0.

0: No falling edge trigger request occurred

1: Rising edge trigger request occurred

This bit is set when the falling edge event arrives on the configurable event line. This bit is cleared by writing a 1 into the bit.

Bits 2:0 Reserved, must be kept at reset value.

17.6.13 EXTI security enable register (EXTI_SECCFGR2)

Address offset: 0x034

Reset value: 0x0000 0000

This register provides write access security, a non-secure write access is ignored and causes the generation of an illegal access event. A non-secure read returns the register data.

Contains only register bits for security capable Input events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.SEC42SEC41SEC40SEC39SEC38SEC37SEC36SEC35SEC34SEC33SEC32
rwrwrwrwrwrwrwrwrwrwrw

Bits 31:11 Reserved, must be kept at reset value.

Bits 10:0 SEC[42:32] : Security enable on event input x (where x = 32 to 42)

When EXTI_PRIVCFGRn.PRIVx is disabled, SECx can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGRn.PRIVx is enabled, SECx can only be written with privilege access.

Unprivileged write to this SECx is discarded

0: Event security disabled (non-secure)

1: Event security enabled (secure)

17.6.14 EXTI privilege enable register (EXTI_PRIVCFGR2)

Address offset: 0x038

Reset value: 0x0000 0000

This register provides privileged write access protection, an unprivileged write access is discarded and causes the generation of an illegal access event. An unprivileged read returns the register data.

Contains only register bits for security capable Input events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.PRIV42PRIV41PRIV40PRIV39PRIV38PRIV37PRIV36PRIV35PRIV34PRIV33PRIV32
rwrwrwrwrwrwrwrwrwrwrw

Bits 31:11 Reserved, must be kept at reset value.

Bits 10:0 PRIV[42:32] : Privilege enable on event input x (where x = 32 to 42)

When EXTI_SECCFGR.SECx is disabled, PRIVx can be accessed with secure and non-secure access.

When EXTI_SECCFGR.SECx is enabled, PRIVx can only be accessed with secure access. Non-secure write to this PRIVx is discarded.

0: Event privilege disabled (unprivileged)
1: Event security enabled (privileged)

17.6.15 EXTI external interrupt selection register (EXTI_EXTICRn)

Address offset: 0x060 (EXTI_EXTICR1) EXTI mux 0, 1, 2, 3 (m = 0)
Address offset: 0x064 (EXTI_EXTICR2) EXTI mux 4, 5, 6, 7 (m = 4)
Address offset: 0x068 (EXTI_EXTICR3) EXTI mux 8, 9, 10, 11 (m = 8)
Address offset: 0x06C (EXTI_EXTICR4) EXTI mux 12, 13, 14, 15 (m = 12)

Reset value: 0x0000 0000

EXTIm fields contain only the number of bits in line with the nb_ioport configuration.

31302928272625242322212019181716
EXTIm+3[7:0]EXTIm+2[7:0]
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw
1514131211109876543210
EXTIm+1[7:0]EXTIm[7:0]
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw

Bits 31:24 EXTIm+3[7:0] : EXTIm+3 GPIO port selection (where m = 0, 4, 8, or 12 for respectively EXTI_EXTICR[1:4]).

These bits are written by software to select the source input for EXTIm+3 external interrupt.

When EXTI_SECCFGR.SEC(m+3) is disabled, EXTI(m+3) can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SEC(m+3) is enabled, EXTI(m+3) can only be accessed with secure access. Non-secure write is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIV(m+3) is disabled, EXTI(m+3) can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGR.PRIV(m+3) is enabled, EXTI(m+3) can only be accessed with privilege access. Unprivileged write to this bit is discarded.

0x00: PA[m+3] pin

0x01: PB[m+3] pin

0x02: PC[m+3] pin

0x03: PD[m+3] pin

0x04: PE[m+3] pin

0x05: PF[m+3] pin

0x06: PG[m+3] pin

0x07: PH[m+3] pin

Others reserved

Bits 23:1 EXTIm+2[7:0] : EXTIm+2 GPIO port selection (where m = 0, 4, 8, or 12 for respectively EXTI_EXTICR[1:4])(where m = 0, 4, 8, or 12 for respectively EXTI_EXTICR[1:4]).

These bits are written by software to select the source input for EXTIm+2 external interrupt.

When EXTI_SECCFGR.SEC(m+2) is disabled, EXTI(m+2) can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SEC(m+2) is enabled, EXTI(m+2) can only be accessed with secure access. Non-secure write is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIV(m+2) is disabled, EXTI(m+2) can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGR.PRIV(m+2) is enabled, EXTI(m+2) can only be accessed with privilege access. Unprivileged write to this bit is discarded.

0x00: PA[m+2] pin

0x01: PB[m+2] pin

0x02: PC[m+2] pin

0x03: PD[m+2] pin

0x04: PE[m+2] pin

0x05: PF[m+2] pin

0x06: PG[m+2] pin

0x07: PH[m+2] pin

Others reserved

Bits 15:8 EXTIm+1[7:0] : EXTIm+1 GPIO port selection (where m = 0, 4, 8, or 12 for respectively EXTI_EXTICR[1:4]).

These bits are written by software to select the source input for EXTIm+1 external interrupt.

When EXTI_SECCFGR.SEC(m+1) is disabled, EXTI(m+1) can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SEC(m+1) is enabled, EXTI(m+1) can only be accessed with secure access. Non-secure write is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVm+1 is disabled, EXTI(m+1) can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGR.PRIVm+1 is enabled, EXTI(m+1) can only be accessed with privilege access. Unprivileged write to this bit is discarded.

0x00: PA[m+1] pin

0x01: PB[m+1] pin

0x02: PC[m+1] pin

0x03: PD[m+1] pin

0x04: PE[m+1] pin

0x05: PF[m+1] pin

0x06: PG[m+1] pin

0x07: PH[m+1] pin

Others reserved

Bits 7:0 EXTIm[7:0] : EXTIm GPIO port selection (where m = 0, 4, 8, or 12 for respectively EXTIm_EXTICR[1:4]).

These bits are written by software to select the source input for EXTIm external interrupt.

When EXTI_SECCFGR.SEC(m) is disabled, EXTI(m) can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SEC(m) is enabled, EXTI(m) can only be accessed with secure access. Non-secure write is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIV(m) is disabled, EXTI(m) can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGR.PRIV(m) is enabled, EXTI(m) can only be accessed with privilege access. Unprivileged write to this bit is discarded

0x00: PA[m] pin

0x01: PB[m] pin

0x02: PC[m] pin

0x03: PD[m] pin

0x04: PE[m] pin

0x05: PF[m] pin

0x06: PG[m] pin

0x07: PH[m] pin

Others reserved

17.6.16 EXTI lock register (EXTI_LOCKR)

Address offset: 0x070

Reset value: 0x0000 0000

This register provides both write access security, a non-secure write access is ignored and a read access returns zero data, and generate an illegal access event.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.LOCK
rs

Bits 31:1 Reserved, must be kept at reset value.

Bit 0 LOCK : Global security and privilege configuration registers EXTI_SECCFGR and EXTI_PRIVCFGR lock.

This register bit is write once after reset.

0: Security and privilege configuration open, can be modified.

1: Security and privilege configuration locked, can no longer be modified.

17.6.17 EXTI CPU wakeup with interrupt mask register (EXTI_IMR1)

Address offset: 0x080

Reset value: 0xFF9E 0000

Contains register bits for configurable events and direct events.

31302928272625242322212019181716
IM31IM30IM29IM28IM27IM26IM25IM24IM23IM22IM21IM20IM19IM18IM17IM16
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw
1514131211109876543210
IM15IM14IM13IM12IM11IM10IM9IM8IM7IM6IM5IM4IM3IM2IM1IM0
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw

Bits 31:0 IM[31:0] : CPU wakeup with interrupt mask on event input x (1) (where x = 0 to 31).

When EXTI_SECCFGR.SECx is disabled, IMx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, IMx can only be accessed with secure access. Non-secure write to this bit is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, IMx can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGR.PRIVx is enabled, IMx can only be accessed with privilege access. Unprivileged write to this bit is discarded.

0: Wakeup with interrupt request from input event x is masked

1: Wakeup with interrupt request from input event x is unmasked

  1. 1. The reset value for configurable event inputs is set to '0' in order to disable the interrupt by default.

17.6.18 EXTI CPU wakeup with event mask register (EXTI_EMR1)

Address offset: 0x084

Reset value: 0x0000 0000

31302928272625242322212019181716
EM31EM30EM29EM28EM27EM26EM25EM24EM23EM22EM21EM20EM19EM18EM17EM16
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw
1514131211109876543210
EM15EM14EM13EM12EM11EM10EM9EM8EM7EM6EM5EM4EM3EM2EM1EM0
rwrwrwrwrwrwrwrwrwrwrwrwrwrwrwrw

Bits 31:0 EM[31:0] : CPU wakeup with event generation mask on event input x (where x = 0 to 31).

When EXTI_SECCFGR.SECENx is disabled, EMx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECENx is enabled, EMx can only be accessed with secure access. Non-secure write to this bit x is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, EMx can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGR.PRIVx is enabled, EMx can only be accessed with privilege access. Unprivileged write to this bit is discarded.

0: Wakeup with event generation from Line x is masked

1: Wakeup with event generation from Line x is unmasked

17.6.19 EXTI CPU wakeup with interrupt mask register (EXTI_IMR2)

Address offset: 0x090

Reset value: 0x0000 0787

Contains register bits for configurable events and direct events.

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.IM42IM41IM40Res.IM38IM37IM36IM35IM34IM33IM32
rwrwrwrwrwrwrwrwrwrw

Bits 31:11 Reserved, must be kept at reset value.

Bits 10:0 IM[42:40] : CPU wakeup with interrupt mask on event input x (1) (where x = 40 to 42).

When EXTI_SECCFGR.SECx is disabled, IMx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, IMx can only be accessed with secure access. Non-secure write to this bit is discarded, non-secure read returns 0..

When EXTI_PRIVCFGR.PRIVx is disabled, IMx can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGR.PRIVx is enabled, IMx can only be accessed with privilege access. Unprivileged write to this bit is discarded.

0: Wakeup with interrupt request from input event x is masked

1: Wakeup with interrupt request from input event x is unmasked

Bit 7 Reserved, must be kept at reset value.

Bits 6:0 IM[38:32] : CPU wakeup with interrupt mask on event input x (1) (where x = 32 to 38).

When EXTI_SECCFGR.SECx is disabled, IMx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, IMx can only be accessed with secure access. Non-secure write to this bit is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, IMx can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGR.PRIVx is enabled, IMx can only be accessed with privilege access. Unprivileged write to this bit is discarded.

0: Wakeup with interrupt request from input event x is masked

1: Wakeup with interrupt request from input event x is unmasked

  1. 1. The reset value for configurable event inputs is set to '0' in order to disable the interrupt by default.

17.6.20 EXTI CPU wakeup with event mask register (EXTI_EMR2)

Address offset: 0x094

Reset value: 0x0000 0000

31302928272625242322212019181716
Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.
1514131211109876543210
Res.Res.Res.Res.Res.EM42EM41EM40Res.EM38EM37EM36EM35EM34EM33EM32
rwrwrwrwrwrwrwrwrwrw

Bits 31:11 Reserved, must be kept at reset value.

Bits 10:0 EM[42:40] : CPU wakeup with event generation mask on event input (1) (where x = 40 to 42).
When EXTI_SECCFGR.SECx is disabled, EMx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, EMx can only be accessed with secure access.
Non-secure write to this bit x is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, EMx can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGR.PRIVx is enabled, EMx can only be accessed with privilege access.
Unprivileged write to this bit is discarded.

0: Wakeup with event generation from line x is masked

1: Wakeup with event generation from line x is unmasked

Bit 7 Reserved, must be kept at reset value.

Bits 6:0 EM[38:32] : CPU wakeup with event generation mask on event input x (1) (where x = 32 to 38).
When EXTI_SECCFGR.SECx is disabled, EMx can be accessed with non-secure and secure access.

When EXTI_SECCFGR.SECx is enabled, EMx can only be accessed with secure access.
Non-secure write to this bit x is discarded, non-secure read returns 0.

When EXTI_PRIVCFGR.PRIVx is disabled, EMx can be accessed with privilege and unprivileged access.

When EXTI_PRIVCFGR.PRIVx is enabled, EMx can only be accessed with privilege access.
Unprivileged write to this bit is discarded.

0: Wakeup with event generation from line x is masked

1: Wakeup with event generation from line x is unmasked

1. The reset value for configurable event inputs is set to '0' in order to disable the interrupt by default.

17.6.21 EXTI register map

The following table gives the EXTI register map and the reset values.

Table 117. Extended interrupt/event controller register map and reset values

OffsetRegister313029282726252423222120191817161514131211109876543210
0x000EXTI_RTSR1Res.Res.Res.Res.Res.Res.Res.Res.Res.RT[22:21]Res.Res.Res.Res.RT[16:0]
Reset value0000000000000000000
Table 117. Extended interrupt/event controller register map and reset values (continued)
OffsetRegister313029282726252423222120191817161514131211109876543210
0x004EXTI_FTSR1Res.Res.Res.Res.Res.Res.Res.Res.Res.FT[22:21]Res.Res.Res.Res.FT[16:0]
Reset value0000000000000000000
0x008EXTI_SWIER1Res.Res.Res.Res.Res.Res.Res.Res.Res.SWI[22:21]Res.Res.Res.Res.SWI[16:0]
Reset value0000000000000000000
0x00CEXTI_RPR1Res.Res.Res.Res.Res.Res.Res.Res.Res.RPIF[22:21]Res.Res.Res.Res.RPIF[16:0]
Reset value0000000000000000000
0x010EXTI_FPR1Res.Res.Res.Res.Res.Res.Res.Res.Res.FPIF[22:21]Res.Res.Res.Res.FPIF[16:0]
Reset value0000000000000000000
0x014EXTI_SECCFG1SEC[31:0]
Reset value00000000000000000000000000000000
0x018EXTI_PRIVCFG1PRIV[31:0]
Reset value00000000000000000000000000000000
0x020EXTI_RTSR2Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.RT[38:35]Res.Res.
Reset value0000
0x024EXTI_FTSR2Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.FT[38:35]Res.Res.
Reset value0000
0x028EXTI_SWIER2Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.SWI[38:35]Res.Res.
Reset value0000
0x02CEXTI_RPR2Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.RPIF[38:35]Res.Res.
Reset value0000
0x030EXTI_FPR2Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.FPIF[38:35]Res.Res.
Reset value0000
0x034EXTI_SECCFG2Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.SEC[42:32]
Reset value00000000000
0x038EXTI_PRIVCFG2Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.Res.PRIV[42:32]
Reset value00000000000

Table 117. Extended interrupt/event controller register map and reset values (continued)

OffsetRegister313029282726252423222120191817161514131211109876543210
0x060EXTI_EXTICR1EXTI13[7:0]EXTI12[7:0]EXTI11[7:0]EXTI10[7:0]
Reset value00000000000000000000000000000000
0x064EXTI_EXTICR2EXTI7[7:0]EXTI6[7:0]EXTI5[7:0]EXTI4[7:0]
Reset value00000000000000000000000000000000
0x068EXTI_EXTICR3EXTI11[7:0]EXTI10[7:0]EXTI9[7:0]EXTI8[7:0]
Reset value00000000000000000000000000000000
0x06CEXTI_EXTICR4EXTI15[7:0]EXTI14[7:0]EXTI13[7:0]EXTI12[7:0]
Reset value00000000000000000000000000000000
0x070EXTI_LOCKRResResResResResResResResResResResResResResResResResResResResResResResResResResResResResResResLOCK
Reset value0
0x080EXTI_IMR1IM[31:0]
Reset value11111111110011110000000000000000
0x084EXTI_EMR1EM[31:0]
Reset value00000000000000000000000000000000
0x088-0x08CReservedResResResResResResResResResResResResResResResResResResResResResResResResResResResResResResResRes
0x090EXTI_IMR2IM[42:32]
Reset value11110000111
0x094EXTI_EMR2EM[42:32]
Reset value00000000000

Refer to Section 2.3 on page 86 for the register boundary addresses.