diff --git a/firmware/CHANGELOG.md b/firmware/CHANGELOG.md index efd31bdf00..736b0ec730 100644 --- a/firmware/CHANGELOG.md +++ b/firmware/CHANGELOG.md @@ -31,6 +31,9 @@ Release template (copy/paste this for new release): ### Added - DAC with Lua #5601 +### Fixed + - Changing idle stepper settings causes kernel panic + ## October 2023 "Day 591" ### Breaking Changes diff --git a/firmware/controllers/system/thread_controller.h b/firmware/controllers/system/thread_controller.h index 9703f0dc90..1c78a3cdf6 100644 --- a/firmware/controllers/system/thread_controller.h +++ b/firmware/controllers/system/thread_controller.h @@ -19,6 +19,7 @@ class ThreadController : public chibios_rt::BaseStaticThread { private: const tprio_t m_prio; + bool m_started = false; protected: // Override this function to implement your controller's thread's behavior. @@ -44,6 +45,10 @@ public: */ void start() { - chibios_rt::BaseStaticThread::start(m_prio); + if (!m_started) + { + m_started = true; + chibios_rt::BaseStaticThread::start(m_prio); + } } };