<enumname="MAV_MODE_FLAG"bitmask="true"> <description>These flags encode the MAV mode.</description> <entryvalue="128"name="MAV_MODE_FLAG_SAFETY_ARMED"> <description>0b10000000 MAV safety set to armed. Motors are enabled / running / can start. Ready to fly. Additional note: this flag is to be ignore when sent in the command MAV_CMD_DO_SET_MODE and MAV_CMD_COMPONENT_ARM_DISARM shall be used instead. The flag can still be used to report the armed state.</description> </entry> <entryvalue="64"name="MAV_MODE_FLAG_MANUAL_INPUT_ENABLED"> <description>0b01000000 remote control input is enabled.</description> </entry> <entryvalue="32"name="MAV_MODE_FLAG_HIL_ENABLED"> <description>0b00100000 hardware in the loop simulation. All motors / actuators are blocked, but internal software is full operational.</description> </entry> <entryvalue="16"name="MAV_MODE_FLAG_STABILIZE_ENABLED"> <description>0b00010000 system stabilizes electronically its attitude (and optionally position). It needs however further control inputs to move around.</description> </entry> <entryvalue="8"name="MAV_MODE_FLAG_GUIDED_ENABLED"> <description>0b00001000 guided mode enabled, system flies waypoints / mission items.</description> </entry> <entryvalue="4"name="MAV_MODE_FLAG_AUTO_ENABLED"> <description>0b00000100 autonomous mode enabled, system finds its own goal positions. Guided flag can be set or not, depends on the actual implementation.</description> </entry> <entryvalue="2"name="MAV_MODE_FLAG_TEST_ENABLED"> <description>0b00000010 system has a test mode enabled. This flag is intended for temporary system tests and should not be used for stable implementations.</description> </entry> <entryvalue="1"name="MAV_MODE_FLAG_CUSTOM_MODE_ENABLED"> <description>0b00000001 Reserved for future use.</description> </entry> </enum>
参考心跳的Message定义
1 2 3 4 5 6 7 8 9
<messageid="0"name="HEARTBEAT"> <description>The heartbeat message shows that a system or component is present and responding. The type and autopilot fields (along with the message component id), allow the receiving system to treat further messages from this system appropriately (e.g. by laying out the user interface based on the autopilot). This microservice is documented at https://mavlink.io/en/services/heartbeat.html</description> <fieldtype="uint8_t"name="type"enum="MAV_TYPE">Vehicle or component type. For a flight controller component the vehicle type (quadrotor, helicopter, etc.). For other components the component type (e.g. camera, gimbal, etc.). This should be used in preference to component id for identifying the component type.</field> <fieldtype="uint8_t"name="autopilot"enum="MAV_AUTOPILOT">Autopilot type / class. Use MAV_AUTOPILOT_INVALID for components that are not flight controllers.</field> <fieldtype="uint8_t"name="base_mode"enum="MAV_MODE_FLAG"display="bitmask">System mode bitmap.</field> <fieldtype="uint32_t"name="custom_mode">A bitfield for use for autopilot-specific flags</field> <fieldtype="uint8_t"name="system_status"enum="MAV_STATE">System status flag.</field> <fieldtype="uint8_t_mavlink_version"name="mavlink_version">MAVLink version, not writable by user, gets added by protocol because of magic data type: uint8_t_mavlink_version</field> </message>