Fix stall detection polarity

pull/65/head
Alex Voinea 2021-07-18 09:13:55 +03:00 committed by D.R.racer
parent badd2b8cf9
commit 75ea171d8f
1 changed files with 1 additions and 1 deletions

View File

@ -111,7 +111,7 @@ public:
/// Return SG state
static inline bool Stall(const MotorParams &params) {
return gpio::ReadPin(params.sgPin) == gpio::Level::high;
return gpio::ReadPin(params.sgPin) == gpio::Level::low;
}
/// Reads a driver register and updates the status flags