PX4 Firmware
PX4 Autopilot Software http://px4.io
|
MAVLink 2.0 message formatters implementation. More...
#include "mavlink_main.h"
#include "mavlink_messages.h"
#include "mavlink_command_sender.h"
#include "mavlink_simple_analyzer.h"
#include "mavlink_high_latency2.h"
#include <commander/px4_custom_mode.h>
#include <drivers/drv_pwm_output.h>
#include <lib/conversion/rotation.h>
#include <lib/ecl/geo/geo.h>
#include <lib/mathlib/mathlib.h>
#include <lib/matrix/matrix/math.hpp>
#include <px4_platform_common/time.h>
#include <systemlib/mavlink_log.h>
#include <math.h>
#include <uORB/topics/actuator_armed.h>
#include <uORB/topics/actuator_controls.h>
#include <uORB/topics/actuator_outputs.h>
#include <uORB/topics/airspeed.h>
#include <uORB/topics/battery_status.h>
#include <uORB/topics/camera_trigger.h>
#include <uORB/topics/camera_capture.h>
#include <uORB/topics/cpuload.h>
#include <uORB/topics/debug_key_value.h>
#include <uORB/topics/debug_value.h>
#include <uORB/topics/debug_vect.h>
#include <uORB/topics/debug_array.h>
#include <uORB/topics/differential_pressure.h>
#include <uORB/topics/distance_sensor.h>
#include <uORB/topics/estimator_status.h>
#include <uORB/topics/geofence_result.h>
#include <uORB/topics/home_position.h>
#include <uORB/topics/input_rc.h>
#include <uORB/topics/manual_control_setpoint.h>
#include <uORB/topics/mavlink_log.h>
#include <uORB/topics/vehicle_trajectory_waypoint.h>
#include <uORB/topics/obstacle_distance.h>
#include <uORB/topics/optical_flow.h>
#include <uORB/topics/orbit_status.h>
#include <uORB/topics/position_controller_status.h>
#include <uORB/topics/position_setpoint_triplet.h>
#include <uORB/topics/sensor_combined.h>
#include <uORB/topics/sensor_bias.h>
#include <uORB/topics/tecs_status.h>
#include <uORB/topics/telemetry_status.h>
#include <uORB/topics/transponder_report.h>
#include <uORB/topics/vehicle_angular_velocity.h>
#include <uORB/topics/vehicle_attitude.h>
#include <uORB/topics/vehicle_attitude_setpoint.h>
#include <uORB/topics/vehicle_command.h>
#include <uORB/topics/vehicle_control_mode.h>
#include <uORB/topics/vehicle_global_position.h>
#include <uORB/topics/vehicle_gps_position.h>
#include <uORB/topics/vehicle_land_detected.h>
#include <uORB/topics/vehicle_local_position.h>
#include <uORB/topics/vehicle_local_position_setpoint.h>
#include <uORB/topics/vehicle_odometry.h>
#include <uORB/topics/vehicle_rates_setpoint.h>
#include <uORB/topics/vehicle_status.h>
#include <uORB/topics/vehicle_status_flags.h>
#include <uORB/topics/vtol_vehicle_status.h>
#include <uORB/topics/wind_estimate.h>
#include <uORB/topics/mount_orientation.h>
#include <uORB/topics/collision_report.h>
#include <uORB/topics/sensor_accel.h>
#include <uORB/topics/sensor_gyro.h>
#include <uORB/topics/sensor_mag.h>
#include <uORB/topics/vehicle_air_data.h>
#include <uORB/topics/vehicle_magnetometer.h>
#include <uORB/uORB.h>
Go to the source code of this file.
Functions | |
static uint16_t | cm_uint16_from_m_float (float m) |
static void | get_mavlink_mode_state (const struct vehicle_status_s *const status, uint8_t *mavlink_state, uint8_t *mavlink_base_mode, uint32_t *mavlink_custom_mode) |
void | get_mavlink_navigation_mode (const struct vehicle_status_s *const status, uint8_t *mavlink_base_mode, union px4_custom_mode *custom_mode) |
const char * | get_stream_name (const uint16_t msg_id) |
MavlinkStream * | create_mavlink_stream (const char *stream_name, Mavlink *mavlink) |
Variables | |
static const StreamListItem | streams_list [] |
MAVLink 2.0 message formatters implementation.
Definition in file mavlink_messages.cpp.
|
static |
Definition at line 122 of file mavlink_messages.cpp.
References f().
Referenced by MavlinkStreamGPSRawInt::send(), and MavlinkStreamGPS2Raw::send().
MavlinkStream* create_mavlink_stream | ( | const char * | stream_name, |
Mavlink * | mavlink | ||
) |
Definition at line 5142 of file mavlink_messages.cpp.
Referenced by Mavlink::configure_stream(), and StreamListItem::StreamListItem().
|
static |
Definition at line 274 of file mavlink_messages.cpp.
References vehicle_status_s::arming_state, px4_custom_mode::data, and get_mavlink_navigation_mode().
Referenced by MavlinkStreamHeartbeat::send(), and MavlinkStreamHILActuatorControls::send().
void get_mavlink_navigation_mode | ( | const struct vehicle_status_s *const | status, |
uint8_t * | mavlink_base_mode, | ||
union px4_custom_mode * | custom_mode | ||
) |
Definition at line 134 of file mavlink_messages.cpp.
References vehicle_status_s::arming_state, px4_custom_mode::data, vehicle_status_s::hil_state, px4_custom_mode::main_mode, vehicle_status_s::nav_state, PX4_CUSTOM_MAIN_MODE_ACRO, PX4_CUSTOM_MAIN_MODE_ALTCTL, PX4_CUSTOM_MAIN_MODE_AUTO, PX4_CUSTOM_MAIN_MODE_MANUAL, PX4_CUSTOM_MAIN_MODE_OFFBOARD, PX4_CUSTOM_MAIN_MODE_POSCTL, PX4_CUSTOM_MAIN_MODE_RATTITUDE, PX4_CUSTOM_MAIN_MODE_STABILIZED, PX4_CUSTOM_SUB_MODE_AUTO_FOLLOW_TARGET, PX4_CUSTOM_SUB_MODE_AUTO_LAND, PX4_CUSTOM_SUB_MODE_AUTO_LOITER, PX4_CUSTOM_SUB_MODE_AUTO_MISSION, PX4_CUSTOM_SUB_MODE_AUTO_PRECLAND, PX4_CUSTOM_SUB_MODE_AUTO_RTGS, PX4_CUSTOM_SUB_MODE_AUTO_RTL, PX4_CUSTOM_SUB_MODE_AUTO_TAKEOFF, PX4_CUSTOM_SUB_MODE_POSCTL_ORBIT, px4_custom_mode::sub_mode, and vehicle_status_s::vehicle_type.
Referenced by get_mavlink_mode_state(), StreamListItem::StreamListItem(), and MavlinkStreamHighLatency2::write_vehicle_status().
const char* get_stream_name | ( | const uint16_t | msg_id | ) |
Definition at line 5130 of file mavlink_messages.cpp.
Referenced by MavlinkReceiver::set_message_interval(), and StreamListItem::StreamListItem().
|
static |
Definition at line 5070 of file mavlink_messages.cpp.