diff options
| author | Dario Nieuwenhuis <[email protected]> | 2024-10-08 20:48:26 +0000 |
|---|---|---|
| committer | GitHub <[email protected]> | 2024-10-08 20:48:26 +0000 |
| commit | 456c226b29799f7db56ab60b0ae3d95cc7d6a32a (patch) | |
| tree | 3ae1776823fa25ab058ace790a06092a74e175e0 | |
| parent | 42815e944af09f7de6278483caf0fb7e65ab1d1d (diff) | |
| parent | df0fc041981105a19beb690e30c3ab1f532d7298 (diff) | |
Merge pull request #3404 from farmblox/fix-stm32-exti-low-power
stm32: fix low-power EXTI IRQ handler dropped edges
| -rw-r--r-- | embassy-stm32/src/exti.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/embassy-stm32/src/exti.rs b/embassy-stm32/src/exti.rs index 224d51b84..87512c92d 100644 --- a/embassy-stm32/src/exti.rs +++ b/embassy-stm32/src/exti.rs | |||
| @@ -41,9 +41,6 @@ fn exticr_regs() -> pac::afio::Afio { | |||
| 41 | } | 41 | } |
| 42 | 42 | ||
| 43 | unsafe fn on_irq() { | 43 | unsafe fn on_irq() { |
| 44 | #[cfg(feature = "low-power")] | ||
| 45 | crate::low_power::on_wakeup_irq(); | ||
| 46 | |||
| 47 | #[cfg(not(any(exti_c0, exti_g0, exti_u0, exti_l5, exti_u5, exti_h5, exti_h50)))] | 44 | #[cfg(not(any(exti_c0, exti_g0, exti_u0, exti_l5, exti_u5, exti_h5, exti_h50)))] |
| 48 | let bits = EXTI.pr(0).read().0; | 45 | let bits = EXTI.pr(0).read().0; |
| 49 | #[cfg(any(exti_c0, exti_g0, exti_u0, exti_l5, exti_u5, exti_h5, exti_h50))] | 46 | #[cfg(any(exti_c0, exti_g0, exti_u0, exti_l5, exti_u5, exti_h5, exti_h50))] |
| @@ -68,6 +65,9 @@ unsafe fn on_irq() { | |||
| 68 | EXTI.rpr(0).write_value(Lines(bits)); | 65 | EXTI.rpr(0).write_value(Lines(bits)); |
| 69 | EXTI.fpr(0).write_value(Lines(bits)); | 66 | EXTI.fpr(0).write_value(Lines(bits)); |
| 70 | } | 67 | } |
| 68 | |||
| 69 | #[cfg(feature = "low-power")] | ||
| 70 | crate::low_power::on_wakeup_irq(); | ||
| 71 | } | 71 | } |
| 72 | 72 | ||
| 73 | struct BitIter(u32); | 73 | struct BitIter(u32); |
