added mfts complete check of afts status flags
This commit is contained in:
parent
f019f45c74
commit
f3d674c7df
@ -80,9 +80,8 @@ FTSController::Run() {
|
||||
case AUTO_FTS_STATE_DISARMED:
|
||||
{
|
||||
//AFTS IS NOT CURRENTLY ARMED
|
||||
//TODO ADD GEOFENCE LOADED CHECK ETC
|
||||
//if (_auto_fts_message.config_status != 0 && _auto_fts_message.geofence_loaded != 0 && _auto_fts_message.gps_lock != 0) {
|
||||
if (_auto_fts_message.gps_lock != 0) {
|
||||
if (_auto_fts_message.config_status != 0 && _auto_fts_message.geofence_loaded != 0 && _auto_fts_message.gps_lock != 0) {
|
||||
//AFTS ARMING CONDITIONS ARE MET
|
||||
if (_auto_fts_message.geofence_violated != 0) {
|
||||
// FAILSAFE: CANNOT ARM AUTO-FTS WHEN GEOFENCE IS ALREADY VIOLATED
|
||||
_auto_fts_state = AUTO_FTS_STATE_ERROR;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user