AP_Motors: Initialize throttle range directly

This was causing SITL to hang at boot when motors object is statically allocated.
This commit is contained in:
Jacob Walser 2017-02-28 11:56:07 -05:00 committed by Lucas De Marchi
parent b86513f503
commit 507b461388

View File

@ -189,8 +189,9 @@ AP_MotorsMulticopter::AP_MotorsMulticopter(uint16_t loop_rate, uint16_t speed_hz
_batt_voltage_filt.set_cutoff_frequency(AP_MOTORS_BATT_VOLT_FILT_HZ); _batt_voltage_filt.set_cutoff_frequency(AP_MOTORS_BATT_VOLT_FILT_HZ);
_batt_voltage_filt.reset(1.0f); _batt_voltage_filt.reset(1.0f);
// default throttle ranges (i.e. _throttle_radio_min, _throttle_radio_max) // default throttle range
set_throttle_range(1100, 1900); _throttle_radio_min = 1100;
_throttle_radio_max = 1900;
}; };
// output - sends commands to the motors // output - sends commands to the motors