Open Frans-Willem opened 5 years ago
To shut down the controller if the connection to the display is lost makes sense to me.
Regarding the watchdog: I have noticed that the reset is done in the motor pwm interrupt. Lets say the code hangs somewhere in an endless loop, the interrupt will be executed anyway at fixed time intervals and thus reset the watchdog. As I have experienced a situation where the motor would not stop anymore, I think the watchdog should be activated and the reset should be moved to the main loop.
Hm, we already got this discussion @ endless-sphere long time ago, but i want to re-think it one more time. Why is the display essential to the function of the motor?
There's some code in watchdog.c, but it's not actually called.
On top of that, seeing as the display is vital to the motor, I think we should add a timeout/watchdog that kills the motor if we're not receiving anything from the display for more than 500ms or so.