Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .changesets/fix-pwm.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
release: patch
summary: Fix reorder issue in PWM constructor
6 changes: 3 additions & 3 deletions Inc/HALAL/Services/PWM/PWM.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,12 @@ template <const TimerDomain::Timer& dev, const ST_LIB::TimerPin pin> class PWM {
friend TimerWrapper<dev>;

TimerWrapper<dev>* timer;
uint32_t* frequency;
uint32_t polarity;
uint32_t negated_polarity;
float* duty_cycle = nullptr;
uint32_t* frequency;
bool is_on = false;
bool is_initialized = false;
uint32_t polarity;
uint32_t negated_polarity;

/* This constructor is private for a reason. Use TimerWrapper<dev>::get_pwm */
PWM(TimerWrapper<dev>* tim,
Expand Down
Loading