AP_HAL_PX4: attempt to initialize USB while soft-disarmed

This commit is contained in:
Jonathan Challinger 2015-01-28 15:56:52 -08:00 committed by Andrew Tridgell
parent c2d60ed7a8
commit e908fcafb1

View File

@ -193,7 +193,7 @@ void PX4UARTDriver::try_initialise(void)
return; return;
} }
_last_initialise_attempt_ms = hal.scheduler->millis(); _last_initialise_attempt_ms = hal.scheduler->millis();
if (hal.util->safety_switch_state() != AP_HAL::Util::SAFETY_ARMED) { if (hal.util->safety_switch_state() != AP_HAL::Util::SAFETY_ARMED || !hal.util->get_soft_armed()) {
begin(0); begin(0);
} }
} }