From 00484073b9ef0f2b74b3c17f47af34fecb2ec0a3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Kjellstrup?= Date: Wed, 25 Oct 2017 14:36:02 +0200 Subject: [PATCH] Sub: Option to trig by distance only when in AUTO mode --- ArduSub/flight_mode.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ArduSub/flight_mode.cpp b/ArduSub/flight_mode.cpp index e222394820..38f77783ae 100644 --- a/ArduSub/flight_mode.cpp +++ b/ArduSub/flight_mode.cpp @@ -75,6 +75,10 @@ bool Sub::set_mode(control_mode_t mode, mode_reason_t reason) // update notify object notify_flight_mode(control_mode); +#if CAMERA == ENABLED + camera.set_is_auto_mode(control_mode == AUTO); +#endif + #if AC_FENCE == ENABLED // pilot requested flight mode change during a fence breach indicates pilot is attempting to manually recover // this flight mode change could be automatic (i.e. fence, battery, GPS or GCS failsafe)