diff --git a/proposed_aerial_msgs/CMakeLists.txt b/proposed_aerial_msgs/CMakeLists.txt index 0339155..2a6abf8 100644 --- a/proposed_aerial_msgs/CMakeLists.txt +++ b/proposed_aerial_msgs/CMakeLists.txt @@ -51,6 +51,7 @@ add_message_files( FILES AngularVelocity.msg Attitude.msg + FlightMode.msg GlobalPosition.msg GlobalWaypoints.msg LinearAcceleration.msg @@ -61,11 +62,10 @@ add_message_files( ) ## Generate services in the 'srv' folder -# add_service_files( -# FILES -# Service1.srv -# Service2.srv -# ) +add_service_files( + FILES + SetFlightMode.srv +) ## Generate actions in the 'action' folder # add_action_files( diff --git a/proposed_aerial_msgs/msg/FlightMode.msg b/proposed_aerial_msgs/msg/FlightMode.msg new file mode 100644 index 0000000..27e2fb1 --- /dev/null +++ b/proposed_aerial_msgs/msg/FlightMode.msg @@ -0,0 +1,8 @@ +# targeting mav_msgs +uint8 FLIGHT_MODE_DISARMED=0 +uint8 FLIGHT_MODE_ARMED=1 +uint8 FLIGHT_MODE_FLYING=2 +uint8 FLIGHT_MODE_LANDED=3 +uint8 FLIGHT_MODE_RTL=4 + +uint8 flight_mode # The flight mode indicated diff --git a/proposed_aerial_msgs/srv/SetFlightMode.srv b/proposed_aerial_msgs/srv/SetFlightMode.srv new file mode 100644 index 0000000..e5a71ba --- /dev/null +++ b/proposed_aerial_msgs/srv/SetFlightMode.srv @@ -0,0 +1,8 @@ +# targeting mav_msgs + +#mav_msgs/ +FlightMode goal # The desired flight mode +--- +#mav_msgs/ +FlightMode result # The resultant state after the attempted transition. +bool success # True if desired change was executed False otherwise.