When detecting flight or idle mode, this should indicate
that accel cal values are out of whack.
Signed-off-by: Mike Beattie <mike@ethernal.org>
if (ao_config.accel_plus_g != 0 &&
ao_config.accel_minus_g != 0 &&
ao_flight_accel < ao_config.accel_plus_g + ACCEL_NOSE_UP &&
if (ao_config.accel_plus_g != 0 &&
ao_config.accel_minus_g != 0 &&
ao_flight_accel < ao_config.accel_plus_g + ACCEL_NOSE_UP &&
+ ao_flight_accel > ao_config.accel_plus_g - ACCEL_NOSE_UP &&
!ao_flight_force_idle)
{
/* Disable the USB controller in flight mode
!ao_flight_force_idle)
{
/* Disable the USB controller in flight mode