Failsafe - cosmetic changes

This commit is contained in:
bresch 2019-04-01 18:22:25 +02:00 committed by Beat Küng
parent 776b1a28de
commit 96da46d1aa
4 changed files with 6 additions and 7 deletions

View File

@ -1024,8 +1024,7 @@ PX4IO::task_main()
}
/* Check if the IO safety circuit breaker has been updated */
bool circuit_breaker_io_safety_enabled;
circuit_breaker_io_safety_enabled = circuit_breaker_enabled("CBRK_IO_SAFETY", CBRK_IO_SAFETY_KEY);
bool circuit_breaker_io_safety_enabled = circuit_breaker_enabled("CBRK_IO_SAFETY", CBRK_IO_SAFETY_KEY);
/* Bypass IO safety switch logic by setting FORCE_SAFETY_OFF */
(void)io_reg_set(PX4IO_PAGE_SETUP, PX4IO_P_SETUP_FORCE_SAFETY_OFF, circuit_breaker_io_safety_enabled);

View File

@ -105,7 +105,7 @@ PARAM_DEFINE_INT32(CBRK_AIRSPD_CHK, 0);
*
* Setting this parameter to 121212 will disable the flight termination action if triggered
* by the FailureDetector logic or if FMU is lost.
* WARNING: ENABLING THIS CIRCUIT BREAKER IS AT OWN RISK
* This circuit breaker does not affect the RC loss, data link loss and geofence safety logic.
*
* @reboot_required true
* @min 0

View File

@ -690,15 +690,15 @@ static bool failureDetectorCheck(orb_advert_t *mavlink_log_pub, const vehicle_st
if (report_fail) {
if (status.failure_detector_status & vehicle_status_s::FAILURE_ROLL) {
mavlink_log_critical(mavlink_log_pub, "PREFLIGHT FAIL: Roll failure detected");
mavlink_log_critical(mavlink_log_pub, "Preflight Fail: Roll failure detected");
}
if (status.failure_detector_status & vehicle_status_s::FAILURE_PITCH) {
mavlink_log_critical(mavlink_log_pub, "PREFLIGHT FAIL: Pitch failure detected");
mavlink_log_critical(mavlink_log_pub, "Preflight Fail: Pitch failure detected");
}
if (status.failure_detector_status & vehicle_status_s::FAILURE_ALT) {
mavlink_log_critical(mavlink_log_pub, "PREFLIGHT FAIL: Altitude failure detected");
mavlink_log_critical(mavlink_log_pub, "Preflight Fail: Altitude failure detected");
}
}
}

View File

@ -71,7 +71,7 @@ public:
bool update();
uint8_t getStatus() const { return _status; }
bool isFailure() const { return (_status == FAILURE_NONE) ? false : true; }
bool isFailure() const { return _status != FAILURE_NONE; }
private: