Preflight checks: made sure pre-flight check results are always reported first thing on the console and always on new or re-established telemetry links AFTER waiting for the hotplug timeout

(leads to double publishing on the console when a new link is established, but this is the best compromise between fixing and completely restructuring)
This commit is contained in:
Andreas Antener
2016-11-24 12:19:37 +01:00
committed by Lorenz Meier
parent c069264752
commit e9737d6f7a
2 changed files with 7 additions and 4 deletions

View File

@@ -1105,8 +1105,6 @@ bool set_nav_state(struct vehicle_status_s *status, struct commander_state_s *in
int preflight_check(struct vehicle_status_s *status, orb_advert_t *mavlink_log_pub, bool prearm, bool force_report,
status_flags_s *status_flags, battery_status_s *battery, bool can_arm_without_gps, hrt_abstime time_since_boot)
{
/*
*/
bool reportFailures = force_report || (!status_flags->condition_system_prearm_error_reported &&
status_flags->condition_system_hotplug_timeout);