From e3ddf7dadd5f52d9eadf3cb32b796257ca23213c Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Sat, 14 Apr 2018 12:16:11 +1000 Subject: [PATCH] Copter: rename SPRAYER-enabled-define to SPRAYER_ENABLED --- ArduCopter/APM_Config.h | 2 +- ArduCopter/ArduCopter.cpp | 2 +- ArduCopter/Copter.h | 4 ++-- ArduCopter/Parameters.cpp | 2 +- ArduCopter/config.h | 4 ++-- ArduCopter/motors.cpp | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/ArduCopter/APM_Config.h b/ArduCopter/APM_Config.h index 64e15369d2..9c88942e55 100644 --- a/ArduCopter/APM_Config.h +++ b/ArduCopter/APM_Config.h @@ -22,7 +22,7 @@ //#define ADSB_ENABLED DISABLED // disable ADSB support //#define PRECISION_LANDING DISABLED // disable precision landing using companion computer or IRLock sensor //#define BEACON_ENABLED DISABLED // disable beacon support -//#define SPRAYER DISABLED // disable the crop sprayer feature (two ESC controlled pumps the speed of which depends upon the vehicle's horizontal velocity) +//#define SPRAYER_ENABLED DISABLED // disable the crop sprayer feature (two ESC controlled pumps the speed of which depends upon the vehicle's horizontal velocity) //#define WINCH_ENABLED DISABLED // disable winch support //#define GRIPPER_ENABLED DISABLED // disable gripper support //#define RPM_ENABLED DISABLED // disable rotations per minute sensor support diff --git a/ArduCopter/ArduCopter.cpp b/ArduCopter/ArduCopter.cpp index b3fd1990ec..d90ab1d0ae 100644 --- a/ArduCopter/ArduCopter.cpp +++ b/ArduCopter/ArduCopter.cpp @@ -402,7 +402,7 @@ void Copter::three_hz_loop() fence_check(); #endif // AC_FENCE_ENABLED -#if SPRAYER == ENABLED +#if SPRAYER_ENABLED == ENABLED sprayer.update(); #endif diff --git a/ArduCopter/Copter.h b/ArduCopter/Copter.h index 7cbe7205dd..f7160a885e 100644 --- a/ArduCopter/Copter.h +++ b/ArduCopter/Copter.h @@ -101,7 +101,7 @@ #if AC_AVOID_ENABLED == ENABLED #include #endif -#if SPRAYER == ENABLED +#if SPRAYER_ENABLED == ENABLED # include #endif #if GRIPPER_ENABLED == ENABLED @@ -544,7 +544,7 @@ private: AP_RSSI rssi; // Crop Sprayer -#if SPRAYER == ENABLED +#if SPRAYER_ENABLED == ENABLED AC_Sprayer sprayer; #endif diff --git a/ArduCopter/Parameters.cpp b/ArduCopter/Parameters.cpp index 3012c25187..e3c1fb208d 100644 --- a/ArduCopter/Parameters.cpp +++ b/ArduCopter/Parameters.cpp @@ -644,7 +644,7 @@ const AP_Param::Info Copter::var_info[] = { GOBJECT(BoardConfig_CAN, "CAN_", AP_BoardConfig_CAN), #endif -#if SPRAYER == ENABLED +#if SPRAYER_ENABLED == ENABLED // @Group: SPRAY_ // @Path: ../libraries/AC_Sprayer/AC_Sprayer.cpp GOBJECT(sprayer, "SPRAY_", AC_Sprayer), diff --git a/ArduCopter/config.h b/ArduCopter/config.h index 705e184765..11f8c7f079 100644 --- a/ArduCopter/config.h +++ b/ArduCopter/config.h @@ -219,8 +219,8 @@ ////////////////////////////////////////////////////////////////////////////// // Crop Sprayer - enabled only on larger firmwares -#ifndef SPRAYER - # define SPRAYER !HAL_MINIMIZE_FEATURES +#ifndef SPRAYER_ENABLED + # define SPRAYER_ENABLED !HAL_MINIMIZE_FEATURES #endif ////////////////////////////////////////////////////////////////////////////// diff --git a/ArduCopter/motors.cpp b/ArduCopter/motors.cpp index 985e229af6..e340282fb0 100644 --- a/ArduCopter/motors.cpp +++ b/ArduCopter/motors.cpp @@ -198,7 +198,7 @@ bool Copter::init_arm_motors(bool arming_from_gcs) ahrs.set_correct_centrifugal(true); hal.util->set_soft_armed(true); -#if SPRAYER == ENABLED +#if SPRAYER_ENABLED == ENABLED // turn off sprayer's test if on sprayer.test_pump(false); #endif