Skip to main content
Nmv1608
Associate II
June 23, 2020
Question

External interrupts

  • June 23, 2020
  • 3 replies
  • 1269 views

The line where the external interrupt is set  SYSCFG->EXTICR [2] |= (3 << 12); I want to set it for port D pin 10. How the masking and unmasking is done for port D?

This topic has been closed for replies.

3 replies

waclawek.jan
Super User
June 23, 2020

Which STM32?

JW

Nmv1608
Nmv1608Author
Associate II
June 23, 2020

stm32l476 mcu

waclawek.jan
Super User
June 23, 2020

Bits 11:8 EXTI10[3:0]: EXTI 10 configuration bits

These bits are written by software to select the source input for the EXTI10 external 

interrupt. 

0000: PA[10] pin

0001: PB[10] pin

0010: PC[10] pin

0011: PD[10] pin

0100: PE[10] pin

0101: PF[10] pin

0110: PG[10] pin

so for PD10 you probably want

SYSCFG->EXTICR [2] |= (3 << 8); 

JW

Nmv1608
Nmv1608Author
Associate II
June 24, 2020

Thank you for the answer.