Skip to content

Commit

Permalink
[stm32] Make EXTI IRQ public for every GPIO pin
Browse files Browse the repository at this point in the history
  • Loading branch information
salkinium committed Jan 14, 2020
1 parent c62cdf8 commit 34bb804
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
3 changes: 1 addition & 2 deletions src/modm/platform/gpio/stm32/pin.hpp.in
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ public:
static constexpr bool isInverted = false;
static constexpr Port port = Port::{{port}}; ///< Port name
static constexpr uint8_t pin = {{pin}}; ///< Pin number
static constexpr IRQn_Type ExternalInterruptIRQ = EXTI{{ exti_irqn }}_IRQn;

protected:
/// Bitmask for registers that contain a 1bit value for every pin.
Expand All @@ -61,8 +62,6 @@ protected:
static constexpr uint8_t af_offset = (pin * 4) % 32;
/// Alternate Function register mask.
static constexpr uint32_t af_mask = 0xf << af_offset;
/// ExternalInterruptIRQ
static constexpr IRQn_Type ExternalInterruptIRQ = EXTI{{ exti_irqn }}_IRQn;

public:
/// @cond
Expand Down
3 changes: 1 addition & 2 deletions src/modm/platform/gpio/stm32/pin_f1.hpp.in
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ public:
static constexpr bool isInverted = false;
static constexpr Port port = Port::{{port}}; ///< Port name
static constexpr uint8_t pin = {{pin}}; ///< Pin Number
static constexpr IRQn_Type ExternalInterruptIRQ = EXTI{{ exti_irqn }}_IRQn;

protected:
/// Bitmask for registers that contain a 1bit value for every pin.
Expand All @@ -59,8 +60,6 @@ protected:
static constexpr uint32_t mask4 = 0xf << (cr_pin * 4);
/// Port Number.
static constexpr uint8_t port_nr = static_cast<uint8_t>(port);
/// ExternalInterruptIRQ
static constexpr IRQn_Type ExternalInterruptIRQ = EXTI{{ exti_irqn }}_IRQn;

public:
/// @cond
Expand Down

0 comments on commit 34bb804

Please sign in to comment.