mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-16 04:45:24 +03:00
Fixed use of 'abs()' for floats. (#9242)
Fixed use of 'abs()' for floats.
This commit is contained in:
commit
cb538ea2ed
2 changed files with 2 additions and 2 deletions
|
@ -996,7 +996,7 @@ static FAST_CODE void checkForYawSpin(timeUs_t currentTimeUs)
|
|||
} else {
|
||||
#ifndef SIMULATOR_BUILD
|
||||
// check for spin on yaw axis only
|
||||
if (abs(gyro.gyroADCf[Z]) > gyroConfig()->yaw_spin_threshold) {
|
||||
if (abs((int)gyro.gyroADCf[Z]) > gyroConfig()->yaw_spin_threshold) {
|
||||
yawSpinDetected = true;
|
||||
yawSpinTimeUs = currentTimeUs;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue