Skip to content

Commit

Permalink
[stm32] add enable break in timer
Browse files Browse the repository at this point in the history
  • Loading branch information
Victor Costa authored and victorandrehc committed Mar 7, 2024
1 parent 77e028e commit 3dafd53
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/modm/platform/timer/stm32/advanced.hpp.in
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,18 @@ public:
return (TIM{{ id }}->BDTR & TIM_BDTR_MOE);
}
%% if target.family in ["g0"]
static inline void
enableBreak()
{
TIM{{ id }}->BDTR |= TIM_BDTR_BKE;
}

static inline void
disableBreak()
{
TIM{{ id }}->BDTR &= ~(TIM_BDTR_BKE);
}

static inline void
enableBreakInput()
{
Expand Down

0 comments on commit 3dafd53

Please sign in to comment.