aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoman Bapst <romanbapst@yahoo.de>2015-04-27 14:25:26 +0200
committerLorenz Meier <lm@inf.ethz.ch>2015-04-27 22:22:52 +0200
commitbd1c3363df44170523c68fd87ee19f2582a5e8fc (patch)
tree7bf56e57c71bcfedc47a7af9be4bab290beb21da
parent06352bee62e96da5c3225ab091d5c1e1777742b3 (diff)
downloadpx4-firmware-bd1c3363df44170523c68fd87ee19f2582a5e8fc.tar.gz
px4-firmware-bd1c3363df44170523c68fd87ee19f2582a5e8fc.tar.bz2
px4-firmware-bd1c3363df44170523c68fd87ee19f2582a5e8fc.zip
added new vtol mav types
-rw-r--r--msg/vehicle_status.msg6
-rw-r--r--src/modules/commander/commander_helper.cpp6
2 files changed, 8 insertions, 4 deletions
diff --git a/msg/vehicle_status.msg b/msg/vehicle_status.msg
index 2e001cac7..2a7e493a3 100644
--- a/msg/vehicle_status.msg
+++ b/msg/vehicle_status.msg
@@ -72,8 +72,10 @@ uint8 VEHICLE_TYPE_FLAPPING_WING = 16 # Flapping wing
uint8 VEHICLE_TYPE_KITE = 17 # Kite
uint8 VEHICLE_TYPE_ONBOARD_CONTROLLER=18 # Onboard companion controller
uint8 VEHICLE_TYPE_VTOL_DUOROTOR = 19 # Vtol with two engines
-uint8 VEHICLE_TYPE_VTOL_QUADROTOR = 20 # Vtol with four engines*/
-uint8 VEHICLE_TYPE_ENUM_END = 21
+uint8 VEHICLE_TYPE_VTOL_QUADROTOR = 20 # Vtol with four engines
+uint8 VEHICLE_TYPE_VTOL_HEXAROTOR = 21 # Vtol with six engines
+uint8 VEHICLE_TYPE_VTOL_OCTOROTOR = 22 # Vtol with eight engines
+uint8 VEHICLE_TYPE_ENUM_END = 23
uint8 VEHICLE_BATTERY_WARNING_NONE = 0 # no battery low voltage warning active
uint8 VEHICLE_BATTERY_WARNING_LOW = 1 # warning of low voltage
diff --git a/src/modules/commander/commander_helper.cpp b/src/modules/commander/commander_helper.cpp
index 5f735b7b7..99b926be4 100644
--- a/src/modules/commander/commander_helper.cpp
+++ b/src/modules/commander/commander_helper.cpp
@@ -85,8 +85,10 @@ bool is_rotary_wing(const struct vehicle_status_s *current_status)
}
bool is_vtol(const struct vehicle_status_s * current_status) {
- return current_status->system_type == vehicle_status_s::VEHICLE_TYPE_VTOL_DUOROTOR ||
- current_status->system_type == vehicle_status_s::VEHICLE_TYPE_VTOL_QUADROTOR;
+ return (current_status->system_type == vehicle_status_s::VEHICLE_TYPE_VTOL_DUOROTOR ||
+ current_status->system_type == vehicle_status_s::VEHICLE_TYPE_VTOL_QUADROTOR ||
+ current_status->system_type == vehicle_status_s::VEHICLE_TYPE_VTOL_HEXAROTOR ||
+ current_status->system_type == vehicle_status_s::VEHICLE_TYPE_VTOL_OCTOROTOR);
}
static int buzzer = -1;