Skip to main content
KHaug.1
Associate
December 20, 2022
Solved

I have some trouble with my st32cubeMX. I can not enable the EXTI on line 2, why ??

  • December 20, 2022
  • 3 replies
  • 2431 views

The enable boxed are there, but only for EXTI line 2, it's greyed out.

0693W00000WLSSrQAP.png

This topic has been closed for replies.
Best answer by ChahinezC

Hello @KHaug.1​,

Thank you for your feedback,

Actually this is an expected behavior. When it comes to multicontext MCUs, you need to use "pin reservation" feature for GPIO pins. The interrupt will be available when you assign the used pin for EXTI 2 to CM4.

To do so, right click on the pin then select Pin Reservation and finally check Cortex-M4.

Please find below an example with pin PA2:

0693W00000WLda8QAD.png 

Regards,

Chahinez.

3 replies

waclawek.jan
Super User
December 20, 2022

Maybe you don't have a free pin with which this interrupt would be associated? Cube has a weird notion of EXTI being an exclusive function of a pin.

I don't use Cube/CubeMX so may be completely wrong.

JW

ChahinezC
ChahinezCBest answer
Associate II
December 22, 2022

Hello @KHaug.1​,

Thank you for your feedback,

Actually this is an expected behavior. When it comes to multicontext MCUs, you need to use "pin reservation" feature for GPIO pins. The interrupt will be available when you assign the used pin for EXTI 2 to CM4.

To do so, right click on the pin then select Pin Reservation and finally check Cortex-M4.

Please find below an example with pin PA2:

0693W00000WLda8QAD.png 

Regards,

Chahinez.

KHaug.1
KHaug.1Author
Associate
January 10, 2023

Thanks for your answer. I have stacking the pin to be both EXTI2 and PB2 GPIO input. I this case I need to unstack before I can reserve the pin for CM4. But now it works, thanks !