Jelajahi Sumber

一些自定义消息修改

Liu Yang 1 tahun lalu
induk
melakukan
fad0ab01bc
100 mengubah file dengan 6686 tambahan dan 49 penghapusan
  1. 11 0
      SConscript
  2. 32 0
      msg_definitions/VKFly.xml
  3. 61 45
      readme.md
  4. 19 1
      v2.0/VKFly/VKFly.h
  5. 1 1
      v2.0/VKFly/mavlink.h
  6. 59 0
      v2.0/VKFly/mavlink_msg_vkfmu_status.h
  7. 100 0
      v2.0/VKFly/mavlink_msg_vkins_status.h
  8. 1 1
      v2.0/common/common.h
  9. 1 1
      v2.0/common/mavlink.h
  10. 51 0
      v2.0/common/mavlink_msg_actuator_control_target.h
  11. 51 0
      v2.0/common/mavlink_msg_actuator_output_status.h
  12. 81 0
      v2.0/common/mavlink_msg_adsb_vehicle.h
  13. 93 0
      v2.0/common/mavlink_msg_ais_vessel.h
  14. 65 0
      v2.0/common/mavlink_msg_altitude.h
  15. 60 0
      v2.0/common/mavlink_msg_att_pos_mocap.h
  16. 65 0
      v2.0/common/mavlink_msg_attitude.h
  17. 69 0
      v2.0/common/mavlink_msg_attitude_quaternion.h
  18. 60 0
      v2.0/common/mavlink_msg_attitude_quaternion_cov.h
  19. 63 0
      v2.0/common/mavlink_msg_attitude_target.h
  20. 47 0
      v2.0/common/mavlink_msg_auth_key.h
  21. 81 0
      v2.0/common/mavlink_msg_autopilot_state_for_gimbal_device.h
  22. 78 0
      v2.0/common/mavlink_msg_autopilot_version.h
  23. 102 0
      v2.0/common/mavlink_msg_battery_info.h
  24. 84 0
      v2.0/common/mavlink_msg_battery_status.h
  25. 53 0
      v2.0/common/mavlink_msg_button_change.h
  26. 65 0
      v2.0/common/mavlink_msg_camera_capture_status.h
  27. 72 0
      v2.0/common/mavlink_msg_camera_fov_status.h
  28. 75 0
      v2.0/common/mavlink_msg_camera_image_captured.h
  29. 84 0
      v2.0/common/mavlink_msg_camera_information.h
  30. 56 0
      v2.0/common/mavlink_msg_camera_settings.h
  31. 83 0
      v2.0/common/mavlink_msg_camera_tracking_geo_status.h
  32. 74 0
      v2.0/common/mavlink_msg_camera_tracking_image_status.h
  33. 50 0
      v2.0/common/mavlink_msg_camera_trigger.h
  34. 60 0
      v2.0/common/mavlink_msg_can_filter_modify.h
  35. 60 0
      v2.0/common/mavlink_msg_can_frame.h
  36. 60 0
      v2.0/common/mavlink_msg_canfd_frame.h
  37. 66 0
      v2.0/common/mavlink_msg_cellular_config.h
  38. 65 0
      v2.0/common/mavlink_msg_cellular_status.h
  39. 54 0
      v2.0/common/mavlink_msg_change_operator_control.h
  40. 53 0
      v2.0/common/mavlink_msg_change_operator_control_ack.h
  41. 65 0
      v2.0/common/mavlink_msg_collision.h
  42. 62 0
      v2.0/common/mavlink_msg_command_ack.h
  43. 53 0
      v2.0/common/mavlink_msg_command_cancel.h
  44. 83 0
      v2.0/common/mavlink_msg_command_int.h
  45. 77 0
      v2.0/common/mavlink_msg_command_long.h
  46. 57 0
      v2.0/common/mavlink_msg_component_information.h
  47. 51 0
      v2.0/common/mavlink_msg_component_metadata.h
  48. 93 0
      v2.0/common/mavlink_msg_control_system_state.h
  49. 50 0
      v2.0/common/mavlink_msg_current_event_sequence.h
  50. 53 0
      v2.0/common/mavlink_msg_data_stream.h
  51. 65 0
      v2.0/common/mavlink_msg_data_transmission_handshake.h
  52. 53 0
      v2.0/common/mavlink_msg_debug.h
  53. 54 0
      v2.0/common/mavlink_msg_debug_float_array.h
  54. 57 0
      v2.0/common/mavlink_msg_debug_vect.h
  55. 78 0
      v2.0/common/mavlink_msg_distance_sensor.h
  56. 101 0
      v2.0/common/mavlink_msg_efi_status.h
  57. 48 0
      v2.0/common/mavlink_msg_encapsulated_data.h
  58. 69 0
      v2.0/common/mavlink_msg_esc_info.h
  59. 57 0
      v2.0/common/mavlink_msg_esc_status.h
  60. 74 0
      v2.0/common/mavlink_msg_estimator_status.h
  61. 63 0
      v2.0/common/mavlink_msg_event.h
  62. 50 0
      v2.0/common/mavlink_msg_extended_sys_state.h
  63. 59 0
      v2.0/common/mavlink_msg_fence_status.h
  64. 54 0
      v2.0/common/mavlink_msg_file_transfer_protocol.h
  65. 59 0
      v2.0/common/mavlink_msg_flight_information.h
  66. 75 0
      v2.0/common/mavlink_msg_follow_target.h
  67. 77 0
      v2.0/common/mavlink_msg_generator_status.h
  68. 78 0
      v2.0/common/mavlink_msg_gimbal_device_attitude_status.h
  69. 90 0
      v2.0/common/mavlink_msg_gimbal_device_information.h
  70. 63 0
      v2.0/common/mavlink_msg_gimbal_device_set_attitude.h
  71. 71 0
      v2.0/common/mavlink_msg_gimbal_manager_information.h
  72. 66 0
      v2.0/common/mavlink_msg_gimbal_manager_set_attitude.h
  73. 68 0
      v2.0/common/mavlink_msg_gimbal_manager_set_manual_control.h
  74. 68 0
      v2.0/common/mavlink_msg_gimbal_manager_set_pitchyaw.h
  75. 65 0
      v2.0/common/mavlink_msg_gimbal_manager_status.h
  76. 71 0
      v2.0/common/mavlink_msg_global_position_int.h
  77. 72 0
      v2.0/common/mavlink_msg_global_position_int_cov.h
  78. 69 0
      v2.0/common/mavlink_msg_global_vision_position_estimate.h
  79. 98 0
      v2.0/common/mavlink_msg_gps2_raw.h
  80. 83 0
      v2.0/common/mavlink_msg_gps2_rtk.h
  81. 56 0
      v2.0/common/mavlink_msg_gps_global_origin.h
  82. 54 0
      v2.0/common/mavlink_msg_gps_inject_data.h
  83. 101 0
      v2.0/common/mavlink_msg_gps_input.h
  84. 92 0
      v2.0/common/mavlink_msg_gps_raw_int.h
  85. 51 0
      v2.0/common/mavlink_msg_gps_rtcm_data.h
  86. 83 0
      v2.0/common/mavlink_msg_gps_rtk.h
  87. 60 0
      v2.0/common/mavlink_msg_gps_status.h
  88. 116 0
      v2.0/common/mavlink_msg_high_latency.h
  89. 125 0
      v2.0/common/mavlink_msg_high_latency2.h
  90. 92 0
      v2.0/common/mavlink_msg_highres_imu.h
  91. 54 0
      v2.0/common/mavlink_msg_hil_actuator_controls.h
  92. 77 0
      v2.0/common/mavlink_msg_hil_controls.h
  93. 89 0
      v2.0/common/mavlink_msg_hil_gps.h
  94. 80 0
      v2.0/common/mavlink_msg_hil_optical_flow.h
  95. 86 0
      v2.0/common/mavlink_msg_hil_rc_inputs_raw.h
  96. 92 0
      v2.0/common/mavlink_msg_hil_sensor.h
  97. 92 0
      v2.0/common/mavlink_msg_hil_state.h
  98. 90 0
      v2.0/common/mavlink_msg_hil_state_quaternion.h
  99. 79 0
      v2.0/common/mavlink_msg_home_position.h
  100. 53 0
      v2.0/common/mavlink_msg_hygrometer_sensor.h

+ 11 - 0
SConscript

@@ -0,0 +1,11 @@
+import rtconfig
+from building import *
+
+cwd = GetCurrentDir()
+
+src = Glob("*.c")
+
+path = [cwd + "/v2.0/VKFly"]
+
+group = DefineGroup("Mavlink", src, depend=[""], CPPPATH=path)
+Return("group")

+ 32 - 0
msg_definitions/VKFly.xml

@@ -158,6 +158,34 @@
       </entry>
     </enum>
 
+    <enum name="VKFLY_SYS_ERROR3">
+      <description>bitmap for SYS_STATUS error3 </description>
+      <entry value="1" name="VKFLY_SYS_ERROR3_MAG0_DISTURB">
+        <description></description>
+      </entry>
+      <entry value="2" name="VKFLY_SYS_ERROR3_MAG1_DISTURB">
+        <description></description>
+      </entry>
+      <entry value="4" name="VKFLY_SYS_ERROR3_IMU0_ERROR">
+        <description></description>
+      </entry>
+      <entry value="8" name="VKFLY_SYS_ERROR3_IMU1_ERROR">
+        <description></description>
+      </entry>
+      <entry value="16" name="VKFLY_SYS_ERROR3_BARO0_ERROR">
+        <description></description>
+      </entry>
+      <entry value="32" name="VKFLY_SYS_ERROR3_GPS0_ERROR">
+        <description></description>
+      </entry>
+      <entry value="64" name="VKFLY_SYS_ERROR3_GPS1_ERROR">
+        <description></description>
+      </entry>
+      <entry value="128" name="VKFLY_SYS_ERROR3_RTK_ERROR">
+        <description></description>
+      </entry>
+    </enum>
+
     <enum name="VKFLY_CUSTOM_MODE">
       <description>custom mode in HEARTBEAT</description>
       <entry value="3" name="VKFLY_CUSTOM_MODE_ATTITUDE">
@@ -215,10 +243,14 @@
       <entry value="0x02" name="VKFLY_VKINS_NAV_ALT_GPS">
         <description>GPS altitude in data fusion. 0 gps altitude not used. 1 gps altitude used.</description>
       </entry>
+      <entry value="0x04" name="VKFLY_VKINS_NAV_HEADING_RTK">
+        <description>RTK heading data. 0 use mag, 1 use rtk dual ant heading.</description>
+      </entry>
       <entry value="0x10" name="VKFLY_VKINS_NAV_RTK">
         <description>RTK pos data. 0 no RTK, 1 RTK. </description>
       </entry>
     </enum>
+
     <enum name="VKFLY_YAW_CTRL_MODE">
       <description>Yaw control mode</description>
       <entry value="0" name="VKFLY_YAW_KEEP_CURRENT">

+ 61 - 45
readme.md

@@ -19,7 +19,7 @@
   | -------------------------------------------- | ---------- | ---------------- |
   | MAV_SYS_STATUS_SENSOR_3D_GYRO                | 1          | imu1陀螺         |
   | MAV_SYS_STATUS_SENSOR_3D_ACCEL               | 2          | imu1加速度       |
-  | MAV_SYS_STATUS_SENSOR_3D_MAG                 | 4          | mag1磁           |
+  | MAV_SYS_STATUS_SENSOR_3D_MAG                 | 4          | mag1磁力计       |
   | MAV_SYS_STATUS_SENSOR_ABSOLUTE_PRESSURE      | 8          | 气压计           |
   | MAV_SYS_STATUS_SENSOR_DIFFERENTIAL_PRESSURE  | 16         | 空速计           |
   | MAV_SYS_STATUS_SENSOR_GPS                    | 32         | 普通gps1         |
@@ -601,7 +601,21 @@ Q: 用 mavlink FTP 还是用 LOG 系列. FTP 功能更强但实现难度更大.
 
 - VKFLY_SYS_ERROR3
 
-  用于 SYS_STATUS 消息中对应的字节. 详细参考 VKFLY.xml (待定义)
+  用于 SYS_STATUS 消息中对应的字节. 详细参考 VKFLY.xml
+  ```c
+  typedef enum VKFLY_SYS_ERROR3
+  {
+    VKFLY_SYS_ERROR3_MAG0_DISTURB=1, /* mag1 磁干扰 | */
+    VKFLY_SYS_ERROR3_MAG1_DISTURB=2, /* mag2 磁干扰  | */
+    VKFLY_SYS_ERROR3_IMU0_ERROR=4, /* imu1 数据异常 | */
+    VKFLY_SYS_ERROR3_IMU1_ERROR=8, /* imu2 数据异常 | */
+    VKFLY_SYS_ERROR3_BARO0_ERROR=16, /* 气压计数据异常  | */
+    VKFLY_SYS_ERROR3_GPS0_ERROR=32, /* 普通gps1数据异常 | */
+    VKFLY_SYS_ERROR3_GPS1_ERROR=64, /* 普通gps2数据异常 | */
+    VKFLY_SYS_ERROR3_RTK_ERROR=128, /* RTK板卡数据异常 | */
+    VKFLY_SYS_ERROR3_ENUM_END=129, /*  | */
+  } VKFLY_SYS_ERROR3;
+  ```
 
 - VKFLY_SYS_ERROR4
 
@@ -641,7 +655,8 @@ Q: 用 mavlink FTP 还是用 LOG 系列. FTP 功能更强但实现难度更大.
   {
     VKFLY_VKINS_NAV_INSGPS=1, /* ins解算bit位, 0-无ins解算 1-有ins解算| */
     VKFLY_VKINS_NAV_ALT_GPS=2, /* gps高度解算bit位, 0-gps不参与高度解算, 1-gps参与高度解算 | */
-    VKFLY_VKINS_NAV_RTK=16, /* RTK标志位, 0-无RTK定位, 1-有RTK定位 | */
+    VKFLY_VKINS_NAV_HEADING_RTK=4, /* 航向解算标志, 0-磁航向 1-双天线测向 | */
+    VKFLY_VKINS_NAV_RTK=16, /* RTK标志位, 0-无RTK高精度定位, 1-有RTK高精度定位 | */
     VKFLY_VKINS_NAV_STATUS_ENUM_END=17, /*  | */
   } VKFLY_VKINS_NAV_STATUS;
   ```
@@ -738,49 +753,50 @@ Q: 用 mavlink FTP 还是用 LOG 系列. FTP 功能更强但实现难度更大.
   } VKFLY_THROW_CHAN_TYPE;
   ```
 
-- VKFLY_CMD
-  对标准 common 库的 MAV_CMD 类型做几个补充, 用于定义自定义航点.
+### 自定义 command
 
-  - VKFLY_CMD_NAV_WP
+对标准 common 库的 MAV_CMD 类型做几个补充, 用于定义自定义航点.
 
-    拍照航点.
-    
-    | 参数   | 说明                                                                                                                                                                                                                                                                                                         |
-    | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
-    | param1 | 该参数按 byte[4] 进行使用. <br>byte[0]~byte[1] s16, 悬停时间, 单位 s. 0 表示不进行悬停自动转弯. <br>byte[2]~byte[3] s16, 巡航速度, 单位 dm/s. 0 或负数表示使用默认巡航速度参数.                                                                                                                              |
-    | param2 | 该参数按 byte[4] 进行使用. <br>byte[0] u8, 达到该航点时是否单独触发一次相机动作. 参考 VKFLY_DIGICAM_WP_ACT <br>byte[1] u8, 为启动相机自动拍照控制模式. 参考 VKFLY_PHOTO_CTRL_MODE. <br>byte[2]~byte[3] u16, 为拍照模式间隔参数. 当拍照模式为定时时单位为s, 当拍照模式为定距拍照时单位为m. 范围 1~UINT16_MAX. |
-    | param3 | 该参数按 byte[4] 进行使用. <br>byte[0] u8, 吊舱云台控制动作. 参考 VKFLY_GIMBAL_WP_ACT <br>byte[1] s8, 给定俯仰角, 单位 deg, 下视负.<br>byte[2]~byte[3] s16, 给定吊舱相对航向角, 单位 deg, 右转为正.                                                                                                          |
-    | param4 | 该参数按 byte[4] 进行使用. <br>byte[0] u8, 为航向模式参考 VKFLY_YAW_CTRL_MODE. <br>byte[1] u8, 预留. <br>byte[2]~byte[3] s16, 范围-180~180. 当航向模式为 VKFLY_YAW_TO_SETVAL 时表示给定的航向值, 单位deg. 当航向模式为指向 <br>HOME 或 NEXT_WP 或 INTEREST 等给定点点时, 表示叠加的航向偏移.                 |
-    | param5 | 纬度 1e-7deg                                                                                                                                                                                                                                                                                                 |
-    | param6 | 经度 1e-7deg                                                                                                                                                                                                                                                                                                 |
-    | param7 | 高度 m                                                                                                                                                                                                                                                                                                       |
-
-  - VKFLY_CMD_NAV_WP_THROW
-
-    抛投航点
-
-    | 参数   | 说明                                                                                                                                                                                                                                                                                                 |
-    | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
-    | param1 | 该参数按 byte[4] 进行使用. <br>byte[0]~byte[1] s16, 悬停时间, 单位 s. 0 表示不进行悬停自动转弯. 悬停到时间后将执行抛投信号触发. <br>byte[2]~byte[3] s16, 巡航速度, 单位 dm/s. 0 或负数表示使用默认巡航速度参数.                                                                                      |
-    | param2 | 该参数按 byte[4] 进行使用. <br>byte[0]~byte[1] s16, 抛投对地高度, 单位 dm. 0或者负数表示在航点当前高度抛投. 若有有效的对地高度信息如雷达测距仪等, 则自动在航点进行下降到设定的对地高度再执行抛投. <br>byte[2]~byte[3] u16, 抛投通道. 每 bit 代表一个抛投执行通道, bitmap 参考 VKFLY_THROW_CHAN_TYPE. |
-    | param3 | 预留                                                                                                                                                                                                                                                                                                 |
-    | param4 | 该参数作为 byte[4] 类型使用. <br>byte[0] u8, 为航向模式参考 VKFLY_YAW_CTRL_MODE. <br>byte[1]预留. <br>byte[2]~byte[3] s16, 范围-180~180. 当航向模式为 VKFLY_YAW_TO_SETVAL 时表示给定的航向值, 单位deg. 当航向模式为指向 <br>HOME 或 NEXT_WP 或 INTEREST 等给定点点时, 表示叠加的航向偏移.            |
-    | param5 | 纬度 1e-7deg                                                                                                                                                                                                                                                                                         |
-    | param6 | 经度 1e-7deg                                                                                                                                                                                                                                                                                         |
-    | param7 | 高度 m                                                                                                                                                                                                                                                                                               |
-
-  - VKFLY_CMD_NAV_WP_ORBIT_DO_PHOTO
-
-    环绕航点
-    | 参数   | 说明                                                                                                                                                                                                                                                                                                                |
-    | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
-    | param1 | 该参数按 byte[4] 进行使用. <br>byte[0]~byte[1] s16, 环绕半径, 单位 dm. 正数表示顺时针方向环绕, 负数表示逆时针方向环绕. <br>byte[2]~byte[3] s16, 巡航速度. 单位 dm/s. 0或负数表示使用默认的巡航速度设置参数.                                                                                                         |
-    | param2 | 拍照控制. 该参数按 byte[4] 进行使用. <br>byte[0] u8, 达到该航点时是否单独触发一次相机动作. 参考 VKFLY_DIGICAM_WP_ACT. <br>byte[1] u8, 为启动相机自动拍照控制模式. 参考 VKFLY_PHOTO_CTRL_MODE. <br>byte[2]~byte[3] u16, 为拍照模式参数. 当拍照模式为定时时单位为s, 当拍照模式为定距拍照时单位为m. 范围 1~UINT16_MAX. |
-    | param3 | 该参数按 byte[4] 进行使用. <br>byte[0]~byte[1] u16, 为环绕圈数, 单位 0.1 圈. <br>byte[2]~byte[3] u16, 为环绕速度, 单位 dm/s.                                                                                                                                                                                        |
-    | param4 | 该参数作为 byte[4] 类型使用. <br>byte[0] u8, 为航向模式参考 VKFLY_YAW_CTRL_MODE. <br>byte[1]预留. <br>byte[2]~byte[3] s16, 范围-180~180. 当航向模式为 VKFLY_YAW_TO_SETVAL 时表示给定的航向值, 单位deg. 当航向模式为指向 <br>HOME 或 NEXT_WP 或 INTEREST 等给定点点时, 表示叠加的航向偏移.                           |
-    | param5 | 纬度 1e-7deg                                                                                                                                                                                                                                                                                                        |
-    | param6 | 经度 1e-7deg                                                                                                                                                                                                                                                                                                        |
-    | param7 | 高度 m                                                                                                                                                                                                                                                                                                              |
+- VKFLY_CMD_NAV_WP
+
+  拍照航点.
+  
+  | 参数   | 说明                                                                                                                                                                                                                                                                                                         |
+  | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
+  | param1 | 该参数按 byte[4] 进行使用. <br>byte[0]~byte[1] s16, 悬停时间, 单位 s. 0 表示不进行悬停自动转弯. <br>byte[2]~byte[3] s16, 巡航速度, 单位 dm/s. 0 或负数表示使用默认巡航速度参数.                                                                                                                              |
+  | param2 | 该参数按 byte[4] 进行使用. <br>byte[0] u8, 达到该航点时是否单独触发一次相机动作. 参考 VKFLY_DIGICAM_WP_ACT <br>byte[1] u8, 为启动相机自动拍照控制模式. 参考 VKFLY_PHOTO_CTRL_MODE. <br>byte[2]~byte[3] u16, 为拍照模式间隔参数. 当拍照模式为定时时单位为s, 当拍照模式为定距拍照时单位为m. 范围 1~UINT16_MAX. |
+  | param3 | 该参数按 byte[4] 进行使用. <br>byte[0] u8, 吊舱云台控制动作. 参考 VKFLY_GIMBAL_WP_ACT <br>byte[1] s8, 给定俯仰角, 单位 deg, 下视负.<br>byte[2]~byte[3] s16, 给定吊舱相对航向角, 单位 deg, 右转为正.                                                                                                          |
+  | param4 | 该参数按 byte[4] 进行使用. <br>byte[0] u8, 为航向模式参考 VKFLY_YAW_CTRL_MODE. <br>byte[1] u8, 预留. <br>byte[2]~byte[3] s16, 范围-180~180. 当航向模式为 VKFLY_YAW_TO_SETVAL 时表示给定的航向值, 单位deg. 当航向模式为指向 <br>HOME 或 NEXT_WP 或 INTEREST 等给定点点时, 表示叠加的航向偏移.                 |
+  | param5 | 纬度 1e-7deg                                                                                                                                                                                                                                                                                                 |
+  | param6 | 经度 1e-7deg                                                                                                                                                                                                                                                                                                 |
+  | param7 | 高度 m                                                                                                                                                                                                                                                                                                       |
+
+- VKFLY_CMD_NAV_WP_THROW
+
+  抛投航点
+
+  | 参数   | 说明                                                                                                                                                                                                                                                                                                 |
+  | ------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
+  | param1 | 该参数按 byte[4] 进行使用. <br>byte[0]~byte[1] s16, 悬停时间, 单位 s. 0 表示不进行悬停自动转弯. 悬停到时间后将执行抛投信号触发. <br>byte[2]~byte[3] s16, 巡航速度, 单位 dm/s. 0 或负数表示使用默认巡航速度参数.                                                                                      |
+  | param2 | 该参数按 byte[4] 进行使用. <br>byte[0]~byte[1] s16, 抛投对地高度, 单位 dm. 0或者负数表示在航点当前高度抛投. 若有有效的对地高度信息如雷达测距仪等, 则自动在航点进行下降到设定的对地高度再执行抛投. <br>byte[2]~byte[3] u16, 抛投通道. 每 bit 代表一个抛投执行通道, bitmap 参考 VKFLY_THROW_CHAN_TYPE. |
+  | param3 | 预留                                                                                                                                                                                                                                                                                                 |
+  | param4 | 该参数作为 byte[4] 类型使用. <br>byte[0] u8, 为航向模式参考 VKFLY_YAW_CTRL_MODE. <br>byte[1]预留. <br>byte[2]~byte[3] s16, 范围-180~180. 当航向模式为 VKFLY_YAW_TO_SETVAL 时表示给定的航向值, 单位deg. 当航向模式为指向 <br>HOME 或 NEXT_WP 或 INTEREST 等给定点点时, 表示叠加的航向偏移.            |
+  | param5 | 纬度 1e-7deg                                                                                                                                                                                                                                                                                         |
+  | param6 | 经度 1e-7deg                                                                                                                                                                                                                                                                                         |
+  | param7 | 高度 m                                                                                                                                                                                                                                                                                               |
+
+- VKFLY_CMD_NAV_WP_ORBIT_DO_PHOTO
+
+  环绕航点
+  | 参数   | 说明                                                                                                                                                                                                                                                                                                                |
+  | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
+  | param1 | 该参数按 byte[4] 进行使用. <br>byte[0]~byte[1] s16, 环绕半径, 单位 dm. 正数表示顺时针方向环绕, 负数表示逆时针方向环绕. <br>byte[2]~byte[3] s16, 巡航速度. 单位 dm/s. 0或负数表示使用默认的巡航速度设置参数.                                                                                                         |
+  | param2 | 拍照控制. 该参数按 byte[4] 进行使用. <br>byte[0] u8, 达到该航点时是否单独触发一次相机动作. 参考 VKFLY_DIGICAM_WP_ACT. <br>byte[1] u8, 为启动相机自动拍照控制模式. 参考 VKFLY_PHOTO_CTRL_MODE. <br>byte[2]~byte[3] u16, 为拍照模式参数. 当拍照模式为定时时单位为s, 当拍照模式为定距拍照时单位为m. 范围 1~UINT16_MAX. |
+  | param3 | 该参数按 byte[4] 进行使用. <br>byte[0]~byte[1] u16, 为环绕圈数, 单位 0.1 圈. <br>byte[2]~byte[3] u16, 为环绕速度, 单位 dm/s.                                                                                                                                                                                        |
+  | param4 | 该参数作为 byte[4] 类型使用. <br>byte[0] u8, 为航向模式参考 VKFLY_YAW_CTRL_MODE. <br>byte[1]预留. <br>byte[2]~byte[3] s16, 范围-180~180. 当航向模式为 VKFLY_YAW_TO_SETVAL 时表示给定的航向值, 单位deg. 当航向模式为指向 <br>HOME 或 NEXT_WP 或 INTEREST 等给定点点时, 表示叠加的航向偏移.                           |
+  | param5 | 纬度 1e-7deg                                                                                                                                                                                                                                                                                                        |
+  | param6 | 经度 1e-7deg                                                                                                                                                                                                                                                                                                        |
+  | param7 | 高度 m                                                                                                                                                                                                                                                                                                              |
 
 
 ### 自定义消息
@@ -794,7 +810,7 @@ Q: 用 mavlink FTP 还是用 LOG 系列. FTP 功能更强但实现难度更大.
   | --------------- | ----------------------------------------------------------------------------------------- |
   | time_boot_ms    | 系统本地时间戳ms                                                                          |
   | nav_status      | 传感器状态标志, 参考 VKFLY.xml 中 VKFLY_VKINS_NAV_STATUS                                  |
-  | s_flag1         |                                                                                           |
+  | err1            | 错误状态字1, 参考 VKFLY.xml 中 VKFLY_VKINS_ERR1_CODE                                      |
   | s_flag2         |                                                                                           |
   | s_flag3         |                                                                                           |
   | s_flag4         |                                                                                           |

+ 19 - 1
v2.0/VKFly/VKFly.h

@@ -10,7 +10,7 @@
     #error Wrong include order: MAVLINK_VKFLY.H MUST NOT BE DIRECTLY USED. Include mavlink.h from the same directory instead or set ALL AND EVERY defines from MAVLINK.H manually accordingly, including the #define MAVLINK_H call.
 #endif
 
-#define MAVLINK_VKFLY_XML_HASH -1375384045188272973
+#define MAVLINK_VKFLY_XML_HASH 5066305815834855140
 
 #ifdef __cplusplus
 extern "C" {
@@ -129,6 +129,23 @@ typedef enum VKFLY_SYS_ERROR2
 } VKFLY_SYS_ERROR2;
 #endif
 
+/** @brief bitmap for SYS_STATUS error3  */
+#ifndef HAVE_ENUM_VKFLY_SYS_ERROR3
+#define HAVE_ENUM_VKFLY_SYS_ERROR3
+typedef enum VKFLY_SYS_ERROR3
+{
+   VKFLY_SYS_ERROR3_MAG0_DISTURB=1, /*  | */
+   VKFLY_SYS_ERROR3_MAG1_DISTURB=2, /*  | */
+   VKFLY_SYS_ERROR3_IMU0_ERROR=4, /*  | */
+   VKFLY_SYS_ERROR3_IMU1_ERROR=8, /*  | */
+   VKFLY_SYS_ERROR3_BARO0_ERROR=16, /*  | */
+   VKFLY_SYS_ERROR3_GPS0_ERROR=32, /*  | */
+   VKFLY_SYS_ERROR3_GPS1_ERROR=64, /*  | */
+   VKFLY_SYS_ERROR3_RTK_ERROR=128, /*  | */
+   VKFLY_SYS_ERROR3_ENUM_END=129, /*  | */
+} VKFLY_SYS_ERROR3;
+#endif
+
 /** @brief custom mode in HEARTBEAT */
 #ifndef HAVE_ENUM_VKFLY_CUSTOM_MODE
 #define HAVE_ENUM_VKFLY_CUSTOM_MODE
@@ -160,6 +177,7 @@ typedef enum VKFLY_VKINS_NAV_STATUS
 {
    VKFLY_VKINS_NAV_INSGPS=1, /* INS status. 0 means no INS. 1 means INS ok. | */
    VKFLY_VKINS_NAV_ALT_GPS=2, /* GPS altitude in data fusion. 0 gps altitude not used. 1 gps altitude used. | */
+   VKFLY_VKINS_NAV_HEADING_RTK=4, /* RTK heading data. 0 use mag, 1 use rtk dual ant heading. | */
    VKFLY_VKINS_NAV_RTK=16, /* RTK pos data. 0 no RTK, 1 RTK.  | */
    VKFLY_VKINS_NAV_STATUS_ENUM_END=17, /*  | */
 } VKFLY_VKINS_NAV_STATUS;

+ 1 - 1
v2.0/VKFly/mavlink.h

@@ -6,7 +6,7 @@
 #ifndef MAVLINK_H
 #define MAVLINK_H
 
-#define MAVLINK_PRIMARY_XML_HASH -1375384045188272973
+#define MAVLINK_PRIMARY_XML_HASH 5066305815834855140
 
 #ifndef MAVLINK_STX
 #define MAVLINK_STX 253

+ 59 - 0
v2.0/VKFly/mavlink_msg_vkfmu_status.h

@@ -87,6 +87,51 @@ static inline uint16_t mavlink_msg_vkfmu_status_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_VKFMU_STATUS_MIN_LEN, MAVLINK_MSG_ID_VKFMU_STATUS_LEN, MAVLINK_MSG_ID_VKFMU_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a vkfmu_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp in ms from system boot.
+ * @param s_flag1  fmu sflag1
+ * @param s_flag2  fmu sflag2
+ * @param s_flag3  fmu sflag3
+ * @param s_flag4  fmu sflag4
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_vkfmu_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint8_t s_flag1, uint8_t s_flag2, uint8_t s_flag3, uint8_t s_flag4)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_VKFMU_STATUS_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_uint8_t(buf, 4, s_flag1);
+    _mav_put_uint8_t(buf, 5, s_flag2);
+    _mav_put_uint8_t(buf, 6, s_flag3);
+    _mav_put_uint8_t(buf, 7, s_flag4);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_VKFMU_STATUS_LEN);
+#else
+    mavlink_vkfmu_status_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.s_flag1 = s_flag1;
+    packet.s_flag2 = s_flag2;
+    packet.s_flag3 = s_flag3;
+    packet.s_flag4 = s_flag4;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_VKFMU_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_VKFMU_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_VKFMU_STATUS_MIN_LEN, MAVLINK_MSG_ID_VKFMU_STATUS_LEN, MAVLINK_MSG_ID_VKFMU_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_VKFMU_STATUS_MIN_LEN, MAVLINK_MSG_ID_VKFMU_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a vkfmu_status message on a channel
  * @param system_id ID of this system
@@ -155,6 +200,20 @@ static inline uint16_t mavlink_msg_vkfmu_status_encode_chan(uint8_t system_id, u
     return mavlink_msg_vkfmu_status_pack_chan(system_id, component_id, chan, msg, vkfmu_status->time_boot_ms, vkfmu_status->s_flag1, vkfmu_status->s_flag2, vkfmu_status->s_flag3, vkfmu_status->s_flag4);
 }
 
+/**
+ * @brief Encode a vkfmu_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param vkfmu_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_vkfmu_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_vkfmu_status_t* vkfmu_status)
+{
+    return mavlink_msg_vkfmu_status_pack_status(system_id, component_id, _status, msg,  vkfmu_status->time_boot_ms, vkfmu_status->s_flag1, vkfmu_status->s_flag2, vkfmu_status->s_flag3, vkfmu_status->s_flag4);
+}
+
 /**
  * @brief Send a vkfmu_status message
  * @param chan MAVLink channel to send the message

+ 100 - 0
v2.0/VKFly/mavlink_msg_vkins_status.h

@@ -169,6 +169,92 @@ static inline uint16_t mavlink_msg_vkins_status_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_VKINS_STATUS_MIN_LEN, MAVLINK_MSG_ID_VKINS_STATUS_LEN, MAVLINK_MSG_ID_VKINS_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a vkins_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp in ms from system boot.
+ * @param nav_status  VKINS
+        navigation status flag.
+ * @param s_flag1  vinks flag1
+ * @param s_flag2  vinks flag2.
+ * @param s_flag3  vinks flag3.
+ * @param s_flag4  vinks flag4.
+ * @param s_flag5  vinks flag5.
+ * @param s_flag6  vinks flag6.
+ * @param mag_calib_stage  vkins mag calib
+        stage.
+ * @param g0 [m/s/s] vkins initial calibrated gravitation acceleration.
+ * @param raw_latitude [degE7] raw longitude for data fusion
+ * @param raw_longitude [degE7] raw latitidue for data fusion
+ * @param baro_alt [m] raw baromoter altitude for data fusion
+ * @param raw_gps_alt [m] gps amsl altitude for data fusion
+ * @param solv_psat_num  satelites number for position
+ * @param solv_hsat_num  satelites number for heading
+ * @param temperature [cdegC] temperature
+ * @param vibe_coe  
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_vkins_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint8_t nav_status, uint8_t s_flag1, uint8_t s_flag2, uint8_t s_flag3, uint8_t s_flag4, uint8_t s_flag5, uint8_t s_flag6, uint8_t mag_calib_stage, float g0, int32_t raw_latitude, int32_t raw_longitude, float baro_alt, float raw_gps_alt, uint8_t solv_psat_num, uint8_t solv_hsat_num, int16_t temperature, uint8_t vibe_coe)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_VKINS_STATUS_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_float(buf, 4, g0);
+    _mav_put_int32_t(buf, 8, raw_latitude);
+    _mav_put_int32_t(buf, 12, raw_longitude);
+    _mav_put_float(buf, 16, baro_alt);
+    _mav_put_float(buf, 20, raw_gps_alt);
+    _mav_put_int16_t(buf, 24, temperature);
+    _mav_put_uint8_t(buf, 26, nav_status);
+    _mav_put_uint8_t(buf, 27, s_flag1);
+    _mav_put_uint8_t(buf, 28, s_flag2);
+    _mav_put_uint8_t(buf, 29, s_flag3);
+    _mav_put_uint8_t(buf, 30, s_flag4);
+    _mav_put_uint8_t(buf, 31, s_flag5);
+    _mav_put_uint8_t(buf, 32, s_flag6);
+    _mav_put_uint8_t(buf, 33, mag_calib_stage);
+    _mav_put_uint8_t(buf, 34, solv_psat_num);
+    _mav_put_uint8_t(buf, 35, solv_hsat_num);
+    _mav_put_uint8_t(buf, 36, vibe_coe);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_VKINS_STATUS_LEN);
+#else
+    mavlink_vkins_status_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.g0 = g0;
+    packet.raw_latitude = raw_latitude;
+    packet.raw_longitude = raw_longitude;
+    packet.baro_alt = baro_alt;
+    packet.raw_gps_alt = raw_gps_alt;
+    packet.temperature = temperature;
+    packet.nav_status = nav_status;
+    packet.s_flag1 = s_flag1;
+    packet.s_flag2 = s_flag2;
+    packet.s_flag3 = s_flag3;
+    packet.s_flag4 = s_flag4;
+    packet.s_flag5 = s_flag5;
+    packet.s_flag6 = s_flag6;
+    packet.mag_calib_stage = mag_calib_stage;
+    packet.solv_psat_num = solv_psat_num;
+    packet.solv_hsat_num = solv_hsat_num;
+    packet.vibe_coe = vibe_coe;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_VKINS_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_VKINS_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_VKINS_STATUS_MIN_LEN, MAVLINK_MSG_ID_VKINS_STATUS_LEN, MAVLINK_MSG_ID_VKINS_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_VKINS_STATUS_MIN_LEN, MAVLINK_MSG_ID_VKINS_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a vkins_status message on a channel
  * @param system_id ID of this system
@@ -278,6 +364,20 @@ static inline uint16_t mavlink_msg_vkins_status_encode_chan(uint8_t system_id, u
     return mavlink_msg_vkins_status_pack_chan(system_id, component_id, chan, msg, vkins_status->time_boot_ms, vkins_status->nav_status, vkins_status->s_flag1, vkins_status->s_flag2, vkins_status->s_flag3, vkins_status->s_flag4, vkins_status->s_flag5, vkins_status->s_flag6, vkins_status->mag_calib_stage, vkins_status->g0, vkins_status->raw_latitude, vkins_status->raw_longitude, vkins_status->baro_alt, vkins_status->raw_gps_alt, vkins_status->solv_psat_num, vkins_status->solv_hsat_num, vkins_status->temperature, vkins_status->vibe_coe);
 }
 
+/**
+ * @brief Encode a vkins_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param vkins_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_vkins_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_vkins_status_t* vkins_status)
+{
+    return mavlink_msg_vkins_status_pack_status(system_id, component_id, _status, msg,  vkins_status->time_boot_ms, vkins_status->nav_status, vkins_status->s_flag1, vkins_status->s_flag2, vkins_status->s_flag3, vkins_status->s_flag4, vkins_status->s_flag5, vkins_status->s_flag6, vkins_status->mag_calib_stage, vkins_status->g0, vkins_status->raw_latitude, vkins_status->raw_longitude, vkins_status->baro_alt, vkins_status->raw_gps_alt, vkins_status->solv_psat_num, vkins_status->solv_hsat_num, vkins_status->temperature, vkins_status->vibe_coe);
+}
+
 /**
  * @brief Send a vkins_status message
  * @param chan MAVLink channel to send the message

+ 1 - 1
v2.0/common/common.h

@@ -10,7 +10,7 @@
     #error Wrong include order: MAVLINK_COMMON.H MUST NOT BE DIRECTLY USED. Include mavlink.h from the same directory instead or set ALL AND EVERY defines from MAVLINK.H manually accordingly, including the #define MAVLINK_H call.
 #endif
 
-#define MAVLINK_COMMON_XML_HASH -839295890051356236
+#define MAVLINK_COMMON_XML_HASH -1596072890383032290
 
 #ifdef __cplusplus
 extern "C" {

+ 1 - 1
v2.0/common/mavlink.h

@@ -6,7 +6,7 @@
 #ifndef MAVLINK_H
 #define MAVLINK_H
 
-#define MAVLINK_PRIMARY_XML_HASH -839295890051356236
+#define MAVLINK_PRIMARY_XML_HASH -1596072890383032290
 
 #ifndef MAVLINK_STX
 #define MAVLINK_STX 253

+ 51 - 0
v2.0/common/mavlink_msg_actuator_control_target.h

@@ -73,6 +73,43 @@ static inline uint16_t mavlink_msg_actuator_control_target_pack(uint8_t system_i
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_MIN_LEN, MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_LEN, MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_CRC);
 }
 
+/**
+ * @brief Pack a actuator_control_target message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param group_mlx  Actuator group. The "_mlx" indicates this is a multi-instance message and a MAVLink parser should use this field to difference between instances.
+ * @param controls  Actuator controls. Normed to -1..+1 where 0 is neutral position. Throttle for single rotation direction motors is 0..1, negative range for reverse direction. Standard mapping for attitude controls (group 0): (index 0-7): roll, pitch, yaw, throttle, flaps, spoilers, airbrakes, landing gear. Load a pass-through mixer to repurpose them as generic outputs.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_actuator_control_target_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint8_t group_mlx, const float *controls)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_uint8_t(buf, 40, group_mlx);
+    _mav_put_float_array(buf, 8, controls, 8);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_LEN);
+#else
+    mavlink_actuator_control_target_t packet;
+    packet.time_usec = time_usec;
+    packet.group_mlx = group_mlx;
+    mav_array_memcpy(packet.controls, controls, sizeof(float)*8);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_MIN_LEN, MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_LEN, MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_MIN_LEN, MAVLINK_MSG_ID_ACTUATOR_CONTROL_TARGET_LEN);
+#endif
+}
+
 /**
  * @brief Pack a actuator_control_target message on a channel
  * @param system_id ID of this system
@@ -133,6 +170,20 @@ static inline uint16_t mavlink_msg_actuator_control_target_encode_chan(uint8_t s
     return mavlink_msg_actuator_control_target_pack_chan(system_id, component_id, chan, msg, actuator_control_target->time_usec, actuator_control_target->group_mlx, actuator_control_target->controls);
 }
 
+/**
+ * @brief Encode a actuator_control_target struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param actuator_control_target C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_actuator_control_target_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_actuator_control_target_t* actuator_control_target)
+{
+    return mavlink_msg_actuator_control_target_pack_status(system_id, component_id, _status, msg,  actuator_control_target->time_usec, actuator_control_target->group_mlx, actuator_control_target->controls);
+}
+
 /**
  * @brief Send a actuator_control_target message
  * @param chan MAVLink channel to send the message

+ 51 - 0
v2.0/common/mavlink_msg_actuator_output_status.h

@@ -73,6 +73,43 @@ static inline uint16_t mavlink_msg_actuator_output_status_pack(uint8_t system_id
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_MIN_LEN, MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_LEN, MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a actuator_output_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (since system boot).
+ * @param active  Active outputs
+ * @param actuator  Servo / motor output array values. Zero values indicate unused channels.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_actuator_output_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint32_t active, const float *actuator)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_uint32_t(buf, 8, active);
+    _mav_put_float_array(buf, 12, actuator, 32);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_LEN);
+#else
+    mavlink_actuator_output_status_t packet;
+    packet.time_usec = time_usec;
+    packet.active = active;
+    mav_array_memcpy(packet.actuator, actuator, sizeof(float)*32);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_MIN_LEN, MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_LEN, MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_MIN_LEN, MAVLINK_MSG_ID_ACTUATOR_OUTPUT_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a actuator_output_status message on a channel
  * @param system_id ID of this system
@@ -133,6 +170,20 @@ static inline uint16_t mavlink_msg_actuator_output_status_encode_chan(uint8_t sy
     return mavlink_msg_actuator_output_status_pack_chan(system_id, component_id, chan, msg, actuator_output_status->time_usec, actuator_output_status->active, actuator_output_status->actuator);
 }
 
+/**
+ * @brief Encode a actuator_output_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param actuator_output_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_actuator_output_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_actuator_output_status_t* actuator_output_status)
+{
+    return mavlink_msg_actuator_output_status_pack_status(system_id, component_id, _status, msg,  actuator_output_status->time_usec, actuator_output_status->active, actuator_output_status->actuator);
+}
+
 /**
  * @brief Send a actuator_output_status message
  * @param chan MAVLink channel to send the message

+ 81 - 0
v2.0/common/mavlink_msg_adsb_vehicle.h

@@ -133,6 +133,73 @@ static inline uint16_t mavlink_msg_adsb_vehicle_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ADSB_VEHICLE_MIN_LEN, MAVLINK_MSG_ID_ADSB_VEHICLE_LEN, MAVLINK_MSG_ID_ADSB_VEHICLE_CRC);
 }
 
+/**
+ * @brief Pack a adsb_vehicle message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param ICAO_address  ICAO address
+ * @param lat [degE7] Latitude
+ * @param lon [degE7] Longitude
+ * @param altitude_type  ADSB altitude type.
+ * @param altitude [mm] Altitude(ASL)
+ * @param heading [cdeg] Course over ground
+ * @param hor_velocity [cm/s] The horizontal velocity
+ * @param ver_velocity [cm/s] The vertical velocity. Positive is up
+ * @param callsign  The callsign, 8+null
+ * @param emitter_type  ADSB emitter type.
+ * @param tslc [s] Time since last communication in seconds
+ * @param flags  Bitmap to indicate various statuses including valid data fields
+ * @param squawk  Squawk code
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_adsb_vehicle_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t ICAO_address, int32_t lat, int32_t lon, uint8_t altitude_type, int32_t altitude, uint16_t heading, uint16_t hor_velocity, int16_t ver_velocity, const char *callsign, uint8_t emitter_type, uint8_t tslc, uint16_t flags, uint16_t squawk)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ADSB_VEHICLE_LEN];
+    _mav_put_uint32_t(buf, 0, ICAO_address);
+    _mav_put_int32_t(buf, 4, lat);
+    _mav_put_int32_t(buf, 8, lon);
+    _mav_put_int32_t(buf, 12, altitude);
+    _mav_put_uint16_t(buf, 16, heading);
+    _mav_put_uint16_t(buf, 18, hor_velocity);
+    _mav_put_int16_t(buf, 20, ver_velocity);
+    _mav_put_uint16_t(buf, 22, flags);
+    _mav_put_uint16_t(buf, 24, squawk);
+    _mav_put_uint8_t(buf, 26, altitude_type);
+    _mav_put_uint8_t(buf, 36, emitter_type);
+    _mav_put_uint8_t(buf, 37, tslc);
+    _mav_put_char_array(buf, 27, callsign, 9);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ADSB_VEHICLE_LEN);
+#else
+    mavlink_adsb_vehicle_t packet;
+    packet.ICAO_address = ICAO_address;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.altitude = altitude;
+    packet.heading = heading;
+    packet.hor_velocity = hor_velocity;
+    packet.ver_velocity = ver_velocity;
+    packet.flags = flags;
+    packet.squawk = squawk;
+    packet.altitude_type = altitude_type;
+    packet.emitter_type = emitter_type;
+    packet.tslc = tslc;
+    mav_array_memcpy(packet.callsign, callsign, sizeof(char)*9);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ADSB_VEHICLE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ADSB_VEHICLE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ADSB_VEHICLE_MIN_LEN, MAVLINK_MSG_ID_ADSB_VEHICLE_LEN, MAVLINK_MSG_ID_ADSB_VEHICLE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ADSB_VEHICLE_MIN_LEN, MAVLINK_MSG_ID_ADSB_VEHICLE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a adsb_vehicle message on a channel
  * @param system_id ID of this system
@@ -223,6 +290,20 @@ static inline uint16_t mavlink_msg_adsb_vehicle_encode_chan(uint8_t system_id, u
     return mavlink_msg_adsb_vehicle_pack_chan(system_id, component_id, chan, msg, adsb_vehicle->ICAO_address, adsb_vehicle->lat, adsb_vehicle->lon, adsb_vehicle->altitude_type, adsb_vehicle->altitude, adsb_vehicle->heading, adsb_vehicle->hor_velocity, adsb_vehicle->ver_velocity, adsb_vehicle->callsign, adsb_vehicle->emitter_type, adsb_vehicle->tslc, adsb_vehicle->flags, adsb_vehicle->squawk);
 }
 
+/**
+ * @brief Encode a adsb_vehicle struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param adsb_vehicle C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_adsb_vehicle_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_adsb_vehicle_t* adsb_vehicle)
+{
+    return mavlink_msg_adsb_vehicle_pack_status(system_id, component_id, _status, msg,  adsb_vehicle->ICAO_address, adsb_vehicle->lat, adsb_vehicle->lon, adsb_vehicle->altitude_type, adsb_vehicle->altitude, adsb_vehicle->heading, adsb_vehicle->hor_velocity, adsb_vehicle->ver_velocity, adsb_vehicle->callsign, adsb_vehicle->emitter_type, adsb_vehicle->tslc, adsb_vehicle->flags, adsb_vehicle->squawk);
+}
+
 /**
  * @brief Send a adsb_vehicle message
  * @param chan MAVLink channel to send the message

+ 93 - 0
v2.0/common/mavlink_msg_ais_vessel.h

@@ -158,6 +158,85 @@ static inline uint16_t mavlink_msg_ais_vessel_pack(uint8_t system_id, uint8_t co
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_AIS_VESSEL_MIN_LEN, MAVLINK_MSG_ID_AIS_VESSEL_LEN, MAVLINK_MSG_ID_AIS_VESSEL_CRC);
 }
 
+/**
+ * @brief Pack a ais_vessel message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param MMSI  Mobile Marine Service Identifier, 9 decimal digits
+ * @param lat [degE7] Latitude
+ * @param lon [degE7] Longitude
+ * @param COG [cdeg] Course over ground
+ * @param heading [cdeg] True heading
+ * @param velocity [cm/s] Speed over ground
+ * @param turn_rate [cdeg/s] Turn rate
+ * @param navigational_status  Navigational status
+ * @param type  Type of vessels
+ * @param dimension_bow [m] Distance from lat/lon location to bow
+ * @param dimension_stern [m] Distance from lat/lon location to stern
+ * @param dimension_port [m] Distance from lat/lon location to port side
+ * @param dimension_starboard [m] Distance from lat/lon location to starboard side
+ * @param callsign  The vessel callsign
+ * @param name  The vessel name
+ * @param tslc [s] Time since last communication in seconds
+ * @param flags  Bitmask to indicate various statuses including valid data fields
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_ais_vessel_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t MMSI, int32_t lat, int32_t lon, uint16_t COG, uint16_t heading, uint16_t velocity, int8_t turn_rate, uint8_t navigational_status, uint8_t type, uint16_t dimension_bow, uint16_t dimension_stern, uint8_t dimension_port, uint8_t dimension_starboard, const char *callsign, const char *name, uint16_t tslc, uint16_t flags)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_AIS_VESSEL_LEN];
+    _mav_put_uint32_t(buf, 0, MMSI);
+    _mav_put_int32_t(buf, 4, lat);
+    _mav_put_int32_t(buf, 8, lon);
+    _mav_put_uint16_t(buf, 12, COG);
+    _mav_put_uint16_t(buf, 14, heading);
+    _mav_put_uint16_t(buf, 16, velocity);
+    _mav_put_uint16_t(buf, 18, dimension_bow);
+    _mav_put_uint16_t(buf, 20, dimension_stern);
+    _mav_put_uint16_t(buf, 22, tslc);
+    _mav_put_uint16_t(buf, 24, flags);
+    _mav_put_int8_t(buf, 26, turn_rate);
+    _mav_put_uint8_t(buf, 27, navigational_status);
+    _mav_put_uint8_t(buf, 28, type);
+    _mav_put_uint8_t(buf, 29, dimension_port);
+    _mav_put_uint8_t(buf, 30, dimension_starboard);
+    _mav_put_char_array(buf, 31, callsign, 7);
+    _mav_put_char_array(buf, 38, name, 20);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_AIS_VESSEL_LEN);
+#else
+    mavlink_ais_vessel_t packet;
+    packet.MMSI = MMSI;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.COG = COG;
+    packet.heading = heading;
+    packet.velocity = velocity;
+    packet.dimension_bow = dimension_bow;
+    packet.dimension_stern = dimension_stern;
+    packet.tslc = tslc;
+    packet.flags = flags;
+    packet.turn_rate = turn_rate;
+    packet.navigational_status = navigational_status;
+    packet.type = type;
+    packet.dimension_port = dimension_port;
+    packet.dimension_starboard = dimension_starboard;
+    mav_array_memcpy(packet.callsign, callsign, sizeof(char)*7);
+    mav_array_memcpy(packet.name, name, sizeof(char)*20);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_AIS_VESSEL_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_AIS_VESSEL;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_AIS_VESSEL_MIN_LEN, MAVLINK_MSG_ID_AIS_VESSEL_LEN, MAVLINK_MSG_ID_AIS_VESSEL_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_AIS_VESSEL_MIN_LEN, MAVLINK_MSG_ID_AIS_VESSEL_LEN);
+#endif
+}
+
 /**
  * @brief Pack a ais_vessel message on a channel
  * @param system_id ID of this system
@@ -260,6 +339,20 @@ static inline uint16_t mavlink_msg_ais_vessel_encode_chan(uint8_t system_id, uin
     return mavlink_msg_ais_vessel_pack_chan(system_id, component_id, chan, msg, ais_vessel->MMSI, ais_vessel->lat, ais_vessel->lon, ais_vessel->COG, ais_vessel->heading, ais_vessel->velocity, ais_vessel->turn_rate, ais_vessel->navigational_status, ais_vessel->type, ais_vessel->dimension_bow, ais_vessel->dimension_stern, ais_vessel->dimension_port, ais_vessel->dimension_starboard, ais_vessel->callsign, ais_vessel->name, ais_vessel->tslc, ais_vessel->flags);
 }
 
+/**
+ * @brief Encode a ais_vessel struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param ais_vessel C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_ais_vessel_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_ais_vessel_t* ais_vessel)
+{
+    return mavlink_msg_ais_vessel_pack_status(system_id, component_id, _status, msg,  ais_vessel->MMSI, ais_vessel->lat, ais_vessel->lon, ais_vessel->COG, ais_vessel->heading, ais_vessel->velocity, ais_vessel->turn_rate, ais_vessel->navigational_status, ais_vessel->type, ais_vessel->dimension_bow, ais_vessel->dimension_stern, ais_vessel->dimension_port, ais_vessel->dimension_starboard, ais_vessel->callsign, ais_vessel->name, ais_vessel->tslc, ais_vessel->flags);
+}
+
 /**
  * @brief Send a ais_vessel message
  * @param chan MAVLink channel to send the message

+ 65 - 0
v2.0/common/mavlink_msg_altitude.h

@@ -99,6 +99,57 @@ static inline uint16_t mavlink_msg_altitude_pack(uint8_t system_id, uint8_t comp
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ALTITUDE_MIN_LEN, MAVLINK_MSG_ID_ALTITUDE_LEN, MAVLINK_MSG_ID_ALTITUDE_CRC);
 }
 
+/**
+ * @brief Pack a altitude message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param altitude_monotonic [m] This altitude measure is initialized on system boot and monotonic (it is never reset, but represents the local altitude change). The only guarantee on this field is that it will never be reset and is consistent within a flight. The recommended value for this field is the uncorrected barometric altitude at boot time. This altitude will also drift and vary between flights.
+ * @param altitude_amsl [m] This altitude measure is strictly above mean sea level and might be non-monotonic (it might reset on events like GPS lock or when a new QNH value is set). It should be the altitude to which global altitude waypoints are compared to. Note that it is *not* the GPS altitude, however, most GPS modules already output MSL by default and not the WGS84 altitude.
+ * @param altitude_local [m] This is the local altitude in the local coordinate frame. It is not the altitude above home, but in reference to the coordinate origin (0, 0, 0). It is up-positive.
+ * @param altitude_relative [m] This is the altitude above the home position. It resets on each change of the current home position.
+ * @param altitude_terrain [m] This is the altitude above terrain. It might be fed by a terrain database or an altimeter. Values smaller than -1000 should be interpreted as unknown.
+ * @param bottom_clearance [m] This is not the altitude, but the clear space below the system according to the fused clearance estimate. It generally should max out at the maximum range of e.g. the laser altimeter. It is generally a moving target. A negative value indicates no measurement available.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_altitude_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, float altitude_monotonic, float altitude_amsl, float altitude_local, float altitude_relative, float altitude_terrain, float bottom_clearance)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ALTITUDE_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 8, altitude_monotonic);
+    _mav_put_float(buf, 12, altitude_amsl);
+    _mav_put_float(buf, 16, altitude_local);
+    _mav_put_float(buf, 20, altitude_relative);
+    _mav_put_float(buf, 24, altitude_terrain);
+    _mav_put_float(buf, 28, bottom_clearance);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ALTITUDE_LEN);
+#else
+    mavlink_altitude_t packet;
+    packet.time_usec = time_usec;
+    packet.altitude_monotonic = altitude_monotonic;
+    packet.altitude_amsl = altitude_amsl;
+    packet.altitude_local = altitude_local;
+    packet.altitude_relative = altitude_relative;
+    packet.altitude_terrain = altitude_terrain;
+    packet.bottom_clearance = bottom_clearance;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ALTITUDE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ALTITUDE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ALTITUDE_MIN_LEN, MAVLINK_MSG_ID_ALTITUDE_LEN, MAVLINK_MSG_ID_ALTITUDE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ALTITUDE_MIN_LEN, MAVLINK_MSG_ID_ALTITUDE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a altitude message on a channel
  * @param system_id ID of this system
@@ -173,6 +224,20 @@ static inline uint16_t mavlink_msg_altitude_encode_chan(uint8_t system_id, uint8
     return mavlink_msg_altitude_pack_chan(system_id, component_id, chan, msg, altitude->time_usec, altitude->altitude_monotonic, altitude->altitude_amsl, altitude->altitude_local, altitude->altitude_relative, altitude->altitude_terrain, altitude->bottom_clearance);
 }
 
+/**
+ * @brief Encode a altitude struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param altitude C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_altitude_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_altitude_t* altitude)
+{
+    return mavlink_msg_altitude_pack_status(system_id, component_id, _status, msg,  altitude->time_usec, altitude->altitude_monotonic, altitude->altitude_amsl, altitude->altitude_local, altitude->altitude_relative, altitude->altitude_terrain, altitude->bottom_clearance);
+}
+
 /**
  * @brief Send a altitude message
  * @param chan MAVLink channel to send the message

+ 60 - 0
v2.0/common/mavlink_msg_att_pos_mocap.h

@@ -92,6 +92,52 @@ static inline uint16_t mavlink_msg_att_pos_mocap_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ATT_POS_MOCAP_MIN_LEN, MAVLINK_MSG_ID_ATT_POS_MOCAP_LEN, MAVLINK_MSG_ID_ATT_POS_MOCAP_CRC);
 }
 
+/**
+ * @brief Pack a att_pos_mocap message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param q  Attitude quaternion (w, x, y, z order, zero-rotation is 1, 0, 0, 0)
+ * @param x [m] X position (NED)
+ * @param y [m] Y position (NED)
+ * @param z [m] Z position (NED)
+ * @param covariance  Row-major representation of a pose 6x6 cross-covariance matrix upper right triangle (states: x, y, z, roll, pitch, yaw; first six entries are the first ROW, next five entries are the second ROW, etc.). If unknown, assign NaN value to first element in the array.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_att_pos_mocap_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, const float *q, float x, float y, float z, const float *covariance)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ATT_POS_MOCAP_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 24, x);
+    _mav_put_float(buf, 28, y);
+    _mav_put_float(buf, 32, z);
+    _mav_put_float_array(buf, 8, q, 4);
+    _mav_put_float_array(buf, 36, covariance, 21);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ATT_POS_MOCAP_LEN);
+#else
+    mavlink_att_pos_mocap_t packet;
+    packet.time_usec = time_usec;
+    packet.x = x;
+    packet.y = y;
+    packet.z = z;
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+    mav_array_memcpy(packet.covariance, covariance, sizeof(float)*21);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ATT_POS_MOCAP_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ATT_POS_MOCAP;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ATT_POS_MOCAP_MIN_LEN, MAVLINK_MSG_ID_ATT_POS_MOCAP_LEN, MAVLINK_MSG_ID_ATT_POS_MOCAP_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ATT_POS_MOCAP_MIN_LEN, MAVLINK_MSG_ID_ATT_POS_MOCAP_LEN);
+#endif
+}
+
 /**
  * @brief Pack a att_pos_mocap message on a channel
  * @param system_id ID of this system
@@ -161,6 +207,20 @@ static inline uint16_t mavlink_msg_att_pos_mocap_encode_chan(uint8_t system_id,
     return mavlink_msg_att_pos_mocap_pack_chan(system_id, component_id, chan, msg, att_pos_mocap->time_usec, att_pos_mocap->q, att_pos_mocap->x, att_pos_mocap->y, att_pos_mocap->z, att_pos_mocap->covariance);
 }
 
+/**
+ * @brief Encode a att_pos_mocap struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param att_pos_mocap C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_att_pos_mocap_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_att_pos_mocap_t* att_pos_mocap)
+{
+    return mavlink_msg_att_pos_mocap_pack_status(system_id, component_id, _status, msg,  att_pos_mocap->time_usec, att_pos_mocap->q, att_pos_mocap->x, att_pos_mocap->y, att_pos_mocap->z, att_pos_mocap->covariance);
+}
+
 /**
  * @brief Send a att_pos_mocap message
  * @param chan MAVLink channel to send the message

+ 65 - 0
v2.0/common/mavlink_msg_attitude.h

@@ -99,6 +99,57 @@ static inline uint16_t mavlink_msg_attitude_pack(uint8_t system_id, uint8_t comp
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ATTITUDE_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_LEN, MAVLINK_MSG_ID_ATTITUDE_CRC);
 }
 
+/**
+ * @brief Pack a attitude message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param roll [rad] Roll angle (-pi..+pi)
+ * @param pitch [rad] Pitch angle (-pi..+pi)
+ * @param yaw [rad] Yaw angle (-pi..+pi)
+ * @param rollspeed [rad/s] Roll angular speed
+ * @param pitchspeed [rad/s] Pitch angular speed
+ * @param yawspeed [rad/s] Yaw angular speed
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_attitude_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, float roll, float pitch, float yaw, float rollspeed, float pitchspeed, float yawspeed)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ATTITUDE_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_float(buf, 4, roll);
+    _mav_put_float(buf, 8, pitch);
+    _mav_put_float(buf, 12, yaw);
+    _mav_put_float(buf, 16, rollspeed);
+    _mav_put_float(buf, 20, pitchspeed);
+    _mav_put_float(buf, 24, yawspeed);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ATTITUDE_LEN);
+#else
+    mavlink_attitude_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.roll = roll;
+    packet.pitch = pitch;
+    packet.yaw = yaw;
+    packet.rollspeed = rollspeed;
+    packet.pitchspeed = pitchspeed;
+    packet.yawspeed = yawspeed;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ATTITUDE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ATTITUDE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ATTITUDE_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_LEN, MAVLINK_MSG_ID_ATTITUDE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ATTITUDE_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a attitude message on a channel
  * @param system_id ID of this system
@@ -173,6 +224,20 @@ static inline uint16_t mavlink_msg_attitude_encode_chan(uint8_t system_id, uint8
     return mavlink_msg_attitude_pack_chan(system_id, component_id, chan, msg, attitude->time_boot_ms, attitude->roll, attitude->pitch, attitude->yaw, attitude->rollspeed, attitude->pitchspeed, attitude->yawspeed);
 }
 
+/**
+ * @brief Encode a attitude struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param attitude C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_attitude_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_attitude_t* attitude)
+{
+    return mavlink_msg_attitude_pack_status(system_id, component_id, _status, msg,  attitude->time_boot_ms, attitude->roll, attitude->pitch, attitude->yaw, attitude->rollspeed, attitude->pitchspeed, attitude->yawspeed);
+}
+
 /**
  * @brief Send a attitude message
  * @param chan MAVLink channel to send the message

+ 69 - 0
v2.0/common/mavlink_msg_attitude_quaternion.h

@@ -109,6 +109,61 @@ static inline uint16_t mavlink_msg_attitude_quaternion_pack(uint8_t system_id, u
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_LEN, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_CRC);
 }
 
+/**
+ * @brief Pack a attitude_quaternion message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param q1  Quaternion component 1, w (1 in null-rotation)
+ * @param q2  Quaternion component 2, x (0 in null-rotation)
+ * @param q3  Quaternion component 3, y (0 in null-rotation)
+ * @param q4  Quaternion component 4, z (0 in null-rotation)
+ * @param rollspeed [rad/s] Roll angular speed
+ * @param pitchspeed [rad/s] Pitch angular speed
+ * @param yawspeed [rad/s] Yaw angular speed
+ * @param repr_offset_q  Rotation offset by which the attitude quaternion and angular speed vector should be rotated for user display (quaternion with [w, x, y, z] order, zero-rotation is [1, 0, 0, 0], send [0, 0, 0, 0] if field not supported). This field is intended for systems in which the reference attitude may change during flight. For example, tailsitters VTOLs rotate their reference attitude by 90 degrees between hover mode and fixed wing mode, thus repr_offset_q is equal to [1, 0, 0, 0] in hover mode and equal to [0.7071, 0, 0.7071, 0] in fixed wing mode.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_attitude_quaternion_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, float q1, float q2, float q3, float q4, float rollspeed, float pitchspeed, float yawspeed, const float *repr_offset_q)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ATTITUDE_QUATERNION_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_float(buf, 4, q1);
+    _mav_put_float(buf, 8, q2);
+    _mav_put_float(buf, 12, q3);
+    _mav_put_float(buf, 16, q4);
+    _mav_put_float(buf, 20, rollspeed);
+    _mav_put_float(buf, 24, pitchspeed);
+    _mav_put_float(buf, 28, yawspeed);
+    _mav_put_float_array(buf, 32, repr_offset_q, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_LEN);
+#else
+    mavlink_attitude_quaternion_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.q1 = q1;
+    packet.q2 = q2;
+    packet.q3 = q3;
+    packet.q4 = q4;
+    packet.rollspeed = rollspeed;
+    packet.pitchspeed = pitchspeed;
+    packet.yawspeed = yawspeed;
+    mav_array_memcpy(packet.repr_offset_q, repr_offset_q, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ATTITUDE_QUATERNION;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_LEN, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_LEN);
+#endif
+}
+
 /**
  * @brief Pack a attitude_quaternion message on a channel
  * @param system_id ID of this system
@@ -187,6 +242,20 @@ static inline uint16_t mavlink_msg_attitude_quaternion_encode_chan(uint8_t syste
     return mavlink_msg_attitude_quaternion_pack_chan(system_id, component_id, chan, msg, attitude_quaternion->time_boot_ms, attitude_quaternion->q1, attitude_quaternion->q2, attitude_quaternion->q3, attitude_quaternion->q4, attitude_quaternion->rollspeed, attitude_quaternion->pitchspeed, attitude_quaternion->yawspeed, attitude_quaternion->repr_offset_q);
 }
 
+/**
+ * @brief Encode a attitude_quaternion struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param attitude_quaternion C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_attitude_quaternion_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_attitude_quaternion_t* attitude_quaternion)
+{
+    return mavlink_msg_attitude_quaternion_pack_status(system_id, component_id, _status, msg,  attitude_quaternion->time_boot_ms, attitude_quaternion->q1, attitude_quaternion->q2, attitude_quaternion->q3, attitude_quaternion->q4, attitude_quaternion->rollspeed, attitude_quaternion->pitchspeed, attitude_quaternion->yawspeed, attitude_quaternion->repr_offset_q);
+}
+
 /**
  * @brief Send a attitude_quaternion message
  * @param chan MAVLink channel to send the message

+ 60 - 0
v2.0/common/mavlink_msg_attitude_quaternion_cov.h

@@ -92,6 +92,52 @@ static inline uint16_t mavlink_msg_attitude_quaternion_cov_pack(uint8_t system_i
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_LEN, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_CRC);
 }
 
+/**
+ * @brief Pack a attitude_quaternion_cov message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param q  Quaternion components, w, x, y, z (1 0 0 0 is the null-rotation)
+ * @param rollspeed [rad/s] Roll angular speed
+ * @param pitchspeed [rad/s] Pitch angular speed
+ * @param yawspeed [rad/s] Yaw angular speed
+ * @param covariance  Row-major representation of a 3x3 attitude covariance matrix (states: roll, pitch, yaw; first three entries are the first ROW, next three entries are the second row, etc.). If unknown, assign NaN value to first element in the array.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_attitude_quaternion_cov_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, const float *q, float rollspeed, float pitchspeed, float yawspeed, const float *covariance)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 24, rollspeed);
+    _mav_put_float(buf, 28, pitchspeed);
+    _mav_put_float(buf, 32, yawspeed);
+    _mav_put_float_array(buf, 8, q, 4);
+    _mav_put_float_array(buf, 36, covariance, 9);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_LEN);
+#else
+    mavlink_attitude_quaternion_cov_t packet;
+    packet.time_usec = time_usec;
+    packet.rollspeed = rollspeed;
+    packet.pitchspeed = pitchspeed;
+    packet.yawspeed = yawspeed;
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+    mav_array_memcpy(packet.covariance, covariance, sizeof(float)*9);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_LEN, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_QUATERNION_COV_LEN);
+#endif
+}
+
 /**
  * @brief Pack a attitude_quaternion_cov message on a channel
  * @param system_id ID of this system
@@ -161,6 +207,20 @@ static inline uint16_t mavlink_msg_attitude_quaternion_cov_encode_chan(uint8_t s
     return mavlink_msg_attitude_quaternion_cov_pack_chan(system_id, component_id, chan, msg, attitude_quaternion_cov->time_usec, attitude_quaternion_cov->q, attitude_quaternion_cov->rollspeed, attitude_quaternion_cov->pitchspeed, attitude_quaternion_cov->yawspeed, attitude_quaternion_cov->covariance);
 }
 
+/**
+ * @brief Encode a attitude_quaternion_cov struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param attitude_quaternion_cov C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_attitude_quaternion_cov_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_attitude_quaternion_cov_t* attitude_quaternion_cov)
+{
+    return mavlink_msg_attitude_quaternion_cov_pack_status(system_id, component_id, _status, msg,  attitude_quaternion_cov->time_usec, attitude_quaternion_cov->q, attitude_quaternion_cov->rollspeed, attitude_quaternion_cov->pitchspeed, attitude_quaternion_cov->yawspeed, attitude_quaternion_cov->covariance);
+}
+
 /**
  * @brief Send a attitude_quaternion_cov message
  * @param chan MAVLink channel to send the message

+ 63 - 0
v2.0/common/mavlink_msg_attitude_target.h

@@ -97,6 +97,55 @@ static inline uint16_t mavlink_msg_attitude_target_pack(uint8_t system_id, uint8
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ATTITUDE_TARGET_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_TARGET_LEN, MAVLINK_MSG_ID_ATTITUDE_TARGET_CRC);
 }
 
+/**
+ * @brief Pack a attitude_target message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param type_mask  Bitmap to indicate which dimensions should be ignored by the vehicle.
+ * @param q  Attitude quaternion (w, x, y, z order, zero-rotation is 1, 0, 0, 0)
+ * @param body_roll_rate [rad/s] Body roll rate
+ * @param body_pitch_rate [rad/s] Body pitch rate
+ * @param body_yaw_rate [rad/s] Body yaw rate
+ * @param thrust  Collective thrust, normalized to 0 .. 1 (-1 .. 1 for vehicles capable of reverse trust)
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_attitude_target_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint8_t type_mask, const float *q, float body_roll_rate, float body_pitch_rate, float body_yaw_rate, float thrust)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ATTITUDE_TARGET_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_float(buf, 20, body_roll_rate);
+    _mav_put_float(buf, 24, body_pitch_rate);
+    _mav_put_float(buf, 28, body_yaw_rate);
+    _mav_put_float(buf, 32, thrust);
+    _mav_put_uint8_t(buf, 36, type_mask);
+    _mav_put_float_array(buf, 4, q, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ATTITUDE_TARGET_LEN);
+#else
+    mavlink_attitude_target_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.body_roll_rate = body_roll_rate;
+    packet.body_pitch_rate = body_pitch_rate;
+    packet.body_yaw_rate = body_yaw_rate;
+    packet.thrust = thrust;
+    packet.type_mask = type_mask;
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ATTITUDE_TARGET_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ATTITUDE_TARGET;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ATTITUDE_TARGET_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_TARGET_LEN, MAVLINK_MSG_ID_ATTITUDE_TARGET_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ATTITUDE_TARGET_MIN_LEN, MAVLINK_MSG_ID_ATTITUDE_TARGET_LEN);
+#endif
+}
+
 /**
  * @brief Pack a attitude_target message on a channel
  * @param system_id ID of this system
@@ -169,6 +218,20 @@ static inline uint16_t mavlink_msg_attitude_target_encode_chan(uint8_t system_id
     return mavlink_msg_attitude_target_pack_chan(system_id, component_id, chan, msg, attitude_target->time_boot_ms, attitude_target->type_mask, attitude_target->q, attitude_target->body_roll_rate, attitude_target->body_pitch_rate, attitude_target->body_yaw_rate, attitude_target->thrust);
 }
 
+/**
+ * @brief Encode a attitude_target struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param attitude_target C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_attitude_target_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_attitude_target_t* attitude_target)
+{
+    return mavlink_msg_attitude_target_pack_status(system_id, component_id, _status, msg,  attitude_target->time_boot_ms, attitude_target->type_mask, attitude_target->q, attitude_target->body_roll_rate, attitude_target->body_pitch_rate, attitude_target->body_yaw_rate, attitude_target->thrust);
+}
+
 /**
  * @brief Send a attitude_target message
  * @param chan MAVLink channel to send the message

+ 47 - 0
v2.0/common/mavlink_msg_auth_key.h

@@ -63,6 +63,39 @@ static inline uint16_t mavlink_msg_auth_key_pack(uint8_t system_id, uint8_t comp
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_AUTH_KEY_MIN_LEN, MAVLINK_MSG_ID_AUTH_KEY_LEN, MAVLINK_MSG_ID_AUTH_KEY_CRC);
 }
 
+/**
+ * @brief Pack a auth_key message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param key  key
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_auth_key_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               const char *key)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_AUTH_KEY_LEN];
+
+    _mav_put_char_array(buf, 0, key, 32);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_AUTH_KEY_LEN);
+#else
+    mavlink_auth_key_t packet;
+
+    mav_array_memcpy(packet.key, key, sizeof(char)*32);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_AUTH_KEY_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_AUTH_KEY;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_AUTH_KEY_MIN_LEN, MAVLINK_MSG_ID_AUTH_KEY_LEN, MAVLINK_MSG_ID_AUTH_KEY_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_AUTH_KEY_MIN_LEN, MAVLINK_MSG_ID_AUTH_KEY_LEN);
+#endif
+}
+
 /**
  * @brief Pack a auth_key message on a channel
  * @param system_id ID of this system
@@ -119,6 +152,20 @@ static inline uint16_t mavlink_msg_auth_key_encode_chan(uint8_t system_id, uint8
     return mavlink_msg_auth_key_pack_chan(system_id, component_id, chan, msg, auth_key->key);
 }
 
+/**
+ * @brief Encode a auth_key struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param auth_key C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_auth_key_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_auth_key_t* auth_key)
+{
+    return mavlink_msg_auth_key_pack_status(system_id, component_id, _status, msg,  auth_key->key);
+}
+
 /**
  * @brief Send a auth_key message
  * @param chan MAVLink channel to send the message

+ 81 - 0
v2.0/common/mavlink_msg_autopilot_state_for_gimbal_device.h

@@ -133,6 +133,73 @@ static inline uint16_t mavlink_msg_autopilot_state_for_gimbal_device_pack(uint8_
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_MIN_LEN, MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_LEN, MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_CRC);
 }
 
+/**
+ * @brief Pack a autopilot_state_for_gimbal_device message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID
+ * @param target_component  Component ID
+ * @param time_boot_us [us] Timestamp (time since system boot).
+ * @param q  Quaternion components of autopilot attitude: w, x, y, z (1 0 0 0 is the null-rotation, Hamilton convention).
+ * @param q_estimated_delay_us [us] Estimated delay of the attitude data. 0 if unknown.
+ * @param vx [m/s] X Speed in NED (North, East, Down). NAN if unknown.
+ * @param vy [m/s] Y Speed in NED (North, East, Down). NAN if unknown.
+ * @param vz [m/s] Z Speed in NED (North, East, Down). NAN if unknown.
+ * @param v_estimated_delay_us [us] Estimated delay of the speed data. 0 if unknown.
+ * @param feed_forward_angular_velocity_z [rad/s] Feed forward Z component of angular velocity (positive: yawing to the right). NaN to be ignored. This is to indicate if the autopilot is actively yawing.
+ * @param estimator_status  Bitmap indicating which estimator outputs are valid.
+ * @param landed_state  The landed state. Is set to MAV_LANDED_STATE_UNDEFINED if landed state is unknown.
+ * @param angular_velocity_z [rad/s] Z component of angular velocity in NED (North, East, Down). NaN if unknown.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_autopilot_state_for_gimbal_device_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint64_t time_boot_us, const float *q, uint32_t q_estimated_delay_us, float vx, float vy, float vz, uint32_t v_estimated_delay_us, float feed_forward_angular_velocity_z, uint16_t estimator_status, uint8_t landed_state, float angular_velocity_z)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_LEN];
+    _mav_put_uint64_t(buf, 0, time_boot_us);
+    _mav_put_uint32_t(buf, 24, q_estimated_delay_us);
+    _mav_put_float(buf, 28, vx);
+    _mav_put_float(buf, 32, vy);
+    _mav_put_float(buf, 36, vz);
+    _mav_put_uint32_t(buf, 40, v_estimated_delay_us);
+    _mav_put_float(buf, 44, feed_forward_angular_velocity_z);
+    _mav_put_uint16_t(buf, 48, estimator_status);
+    _mav_put_uint8_t(buf, 50, target_system);
+    _mav_put_uint8_t(buf, 51, target_component);
+    _mav_put_uint8_t(buf, 52, landed_state);
+    _mav_put_float(buf, 53, angular_velocity_z);
+    _mav_put_float_array(buf, 8, q, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_LEN);
+#else
+    mavlink_autopilot_state_for_gimbal_device_t packet;
+    packet.time_boot_us = time_boot_us;
+    packet.q_estimated_delay_us = q_estimated_delay_us;
+    packet.vx = vx;
+    packet.vy = vy;
+    packet.vz = vz;
+    packet.v_estimated_delay_us = v_estimated_delay_us;
+    packet.feed_forward_angular_velocity_z = feed_forward_angular_velocity_z;
+    packet.estimator_status = estimator_status;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.landed_state = landed_state;
+    packet.angular_velocity_z = angular_velocity_z;
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_MIN_LEN, MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_LEN, MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_MIN_LEN, MAVLINK_MSG_ID_AUTOPILOT_STATE_FOR_GIMBAL_DEVICE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a autopilot_state_for_gimbal_device message on a channel
  * @param system_id ID of this system
@@ -223,6 +290,20 @@ static inline uint16_t mavlink_msg_autopilot_state_for_gimbal_device_encode_chan
     return mavlink_msg_autopilot_state_for_gimbal_device_pack_chan(system_id, component_id, chan, msg, autopilot_state_for_gimbal_device->target_system, autopilot_state_for_gimbal_device->target_component, autopilot_state_for_gimbal_device->time_boot_us, autopilot_state_for_gimbal_device->q, autopilot_state_for_gimbal_device->q_estimated_delay_us, autopilot_state_for_gimbal_device->vx, autopilot_state_for_gimbal_device->vy, autopilot_state_for_gimbal_device->vz, autopilot_state_for_gimbal_device->v_estimated_delay_us, autopilot_state_for_gimbal_device->feed_forward_angular_velocity_z, autopilot_state_for_gimbal_device->estimator_status, autopilot_state_for_gimbal_device->landed_state, autopilot_state_for_gimbal_device->angular_velocity_z);
 }
 
+/**
+ * @brief Encode a autopilot_state_for_gimbal_device struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param autopilot_state_for_gimbal_device C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_autopilot_state_for_gimbal_device_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_autopilot_state_for_gimbal_device_t* autopilot_state_for_gimbal_device)
+{
+    return mavlink_msg_autopilot_state_for_gimbal_device_pack_status(system_id, component_id, _status, msg,  autopilot_state_for_gimbal_device->target_system, autopilot_state_for_gimbal_device->target_component, autopilot_state_for_gimbal_device->time_boot_us, autopilot_state_for_gimbal_device->q, autopilot_state_for_gimbal_device->q_estimated_delay_us, autopilot_state_for_gimbal_device->vx, autopilot_state_for_gimbal_device->vy, autopilot_state_for_gimbal_device->vz, autopilot_state_for_gimbal_device->v_estimated_delay_us, autopilot_state_for_gimbal_device->feed_forward_angular_velocity_z, autopilot_state_for_gimbal_device->estimator_status, autopilot_state_for_gimbal_device->landed_state, autopilot_state_for_gimbal_device->angular_velocity_z);
+}
+
 /**
  * @brief Send a autopilot_state_for_gimbal_device message
  * @param chan MAVLink channel to send the message

+ 78 - 0
v2.0/common/mavlink_msg_autopilot_version.h

@@ -130,6 +130,70 @@ static inline uint16_t mavlink_msg_autopilot_version_pack(uint8_t system_id, uin
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_AUTOPILOT_VERSION_MIN_LEN, MAVLINK_MSG_ID_AUTOPILOT_VERSION_LEN, MAVLINK_MSG_ID_AUTOPILOT_VERSION_CRC);
 }
 
+/**
+ * @brief Pack a autopilot_version message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param capabilities  Bitmap of capabilities
+ * @param flight_sw_version  Firmware version number
+ * @param middleware_sw_version  Middleware version number
+ * @param os_sw_version  Operating system version number
+ * @param board_version  HW / board version (last 8 bits should be silicon ID, if any). The first 16 bits of this field specify https://github.com/PX4/PX4-Bootloader/blob/master/board_types.txt
+ * @param flight_custom_version  Custom version field, commonly the first 8 bytes of the git hash. This is not an unique identifier, but should allow to identify the commit using the main version number even for very large code bases.
+ * @param middleware_custom_version  Custom version field, commonly the first 8 bytes of the git hash. This is not an unique identifier, but should allow to identify the commit using the main version number even for very large code bases.
+ * @param os_custom_version  Custom version field, commonly the first 8 bytes of the git hash. This is not an unique identifier, but should allow to identify the commit using the main version number even for very large code bases.
+ * @param vendor_id  ID of the board vendor
+ * @param product_id  ID of the product
+ * @param uid  UID if provided by hardware (see uid2)
+ * @param uid2  UID if provided by hardware (supersedes the uid field. If this is non-zero, use this field, otherwise use uid)
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_autopilot_version_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t capabilities, uint32_t flight_sw_version, uint32_t middleware_sw_version, uint32_t os_sw_version, uint32_t board_version, const uint8_t *flight_custom_version, const uint8_t *middleware_custom_version, const uint8_t *os_custom_version, uint16_t vendor_id, uint16_t product_id, uint64_t uid, const uint8_t *uid2)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_AUTOPILOT_VERSION_LEN];
+    _mav_put_uint64_t(buf, 0, capabilities);
+    _mav_put_uint64_t(buf, 8, uid);
+    _mav_put_uint32_t(buf, 16, flight_sw_version);
+    _mav_put_uint32_t(buf, 20, middleware_sw_version);
+    _mav_put_uint32_t(buf, 24, os_sw_version);
+    _mav_put_uint32_t(buf, 28, board_version);
+    _mav_put_uint16_t(buf, 32, vendor_id);
+    _mav_put_uint16_t(buf, 34, product_id);
+    _mav_put_uint8_t_array(buf, 36, flight_custom_version, 8);
+    _mav_put_uint8_t_array(buf, 44, middleware_custom_version, 8);
+    _mav_put_uint8_t_array(buf, 52, os_custom_version, 8);
+    _mav_put_uint8_t_array(buf, 60, uid2, 18);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_AUTOPILOT_VERSION_LEN);
+#else
+    mavlink_autopilot_version_t packet;
+    packet.capabilities = capabilities;
+    packet.uid = uid;
+    packet.flight_sw_version = flight_sw_version;
+    packet.middleware_sw_version = middleware_sw_version;
+    packet.os_sw_version = os_sw_version;
+    packet.board_version = board_version;
+    packet.vendor_id = vendor_id;
+    packet.product_id = product_id;
+    mav_array_memcpy(packet.flight_custom_version, flight_custom_version, sizeof(uint8_t)*8);
+    mav_array_memcpy(packet.middleware_custom_version, middleware_custom_version, sizeof(uint8_t)*8);
+    mav_array_memcpy(packet.os_custom_version, os_custom_version, sizeof(uint8_t)*8);
+    mav_array_memcpy(packet.uid2, uid2, sizeof(uint8_t)*18);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_AUTOPILOT_VERSION_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_AUTOPILOT_VERSION;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_AUTOPILOT_VERSION_MIN_LEN, MAVLINK_MSG_ID_AUTOPILOT_VERSION_LEN, MAVLINK_MSG_ID_AUTOPILOT_VERSION_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_AUTOPILOT_VERSION_MIN_LEN, MAVLINK_MSG_ID_AUTOPILOT_VERSION_LEN);
+#endif
+}
+
 /**
  * @brief Pack a autopilot_version message on a channel
  * @param system_id ID of this system
@@ -217,6 +281,20 @@ static inline uint16_t mavlink_msg_autopilot_version_encode_chan(uint8_t system_
     return mavlink_msg_autopilot_version_pack_chan(system_id, component_id, chan, msg, autopilot_version->capabilities, autopilot_version->flight_sw_version, autopilot_version->middleware_sw_version, autopilot_version->os_sw_version, autopilot_version->board_version, autopilot_version->flight_custom_version, autopilot_version->middleware_custom_version, autopilot_version->os_custom_version, autopilot_version->vendor_id, autopilot_version->product_id, autopilot_version->uid, autopilot_version->uid2);
 }
 
+/**
+ * @brief Encode a autopilot_version struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param autopilot_version C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_autopilot_version_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_autopilot_version_t* autopilot_version)
+{
+    return mavlink_msg_autopilot_version_pack_status(system_id, component_id, _status, msg,  autopilot_version->capabilities, autopilot_version->flight_sw_version, autopilot_version->middleware_sw_version, autopilot_version->os_sw_version, autopilot_version->board_version, autopilot_version->flight_custom_version, autopilot_version->middleware_custom_version, autopilot_version->os_custom_version, autopilot_version->vendor_id, autopilot_version->product_id, autopilot_version->uid, autopilot_version->uid2);
+}
+
 /**
  * @brief Send a autopilot_version message
  * @param chan MAVLink channel to send the message

+ 102 - 0
v2.0/common/mavlink_msg_battery_info.h

@@ -177,6 +177,94 @@ static inline uint16_t mavlink_msg_battery_info_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_BATTERY_INFO_MIN_LEN, MAVLINK_MSG_ID_BATTERY_INFO_LEN, MAVLINK_MSG_ID_BATTERY_INFO_CRC);
 }
 
+/**
+ * @brief Pack a battery_info message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param id  Battery ID
+ * @param battery_function  Function of the battery.
+ * @param type  Type (chemistry) of the battery.
+ * @param state_of_health [%] State of Health (SOH) estimate. Typically 100% at the time of manufacture and will decrease over time and use. -1: field not provided.
+ * @param cells_in_series  Number of battery cells in series. 0: field not provided.
+ * @param cycle_count  Lifetime count of the number of charge/discharge cycles (https://en.wikipedia.org/wiki/Charge_cycle). UINT16_MAX: field not provided.
+ * @param weight [g] Battery weight. 0: field not provided.
+ * @param discharge_minimum_voltage [V] Minimum per-cell voltage when discharging. 0: field not provided.
+ * @param charging_minimum_voltage [V] Minimum per-cell voltage when charging. 0: field not provided.
+ * @param resting_minimum_voltage [V] Minimum per-cell voltage when resting. 0: field not provided.
+ * @param charging_maximum_voltage [V] Maximum per-cell voltage when charged. 0: field not provided.
+ * @param charging_maximum_current [A] Maximum pack continuous charge current. 0: field not provided.
+ * @param nominal_voltage [V] Battery nominal voltage. Used for conversion between Wh and Ah. 0: field not provided.
+ * @param discharge_maximum_current [A] Maximum pack discharge current. 0: field not provided.
+ * @param discharge_maximum_burst_current [A] Maximum pack discharge burst current. 0: field not provided.
+ * @param design_capacity [Ah] Fully charged design capacity. 0: field not provided.
+ * @param full_charge_capacity [Ah] Predicted battery capacity when fully charged (accounting for battery degradation). NAN: field not provided.
+ * @param manufacture_date  Manufacture date (DDMMYYYY) in ASCII characters, 0 terminated. All 0: field not provided.
+ * @param serial_number  Serial number in ASCII characters, 0 terminated. All 0: field not provided.
+ * @param name  Battery device name. Formatted as manufacturer name then product name, separated with an underscore (in ASCII characters), 0 terminated. All 0: field not provided.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_battery_info_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t id, uint8_t battery_function, uint8_t type, uint8_t state_of_health, uint8_t cells_in_series, uint16_t cycle_count, uint16_t weight, float discharge_minimum_voltage, float charging_minimum_voltage, float resting_minimum_voltage, float charging_maximum_voltage, float charging_maximum_current, float nominal_voltage, float discharge_maximum_current, float discharge_maximum_burst_current, float design_capacity, float full_charge_capacity, const char *manufacture_date, const char *serial_number, const char *name)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_BATTERY_INFO_LEN];
+    _mav_put_float(buf, 0, discharge_minimum_voltage);
+    _mav_put_float(buf, 4, charging_minimum_voltage);
+    _mav_put_float(buf, 8, resting_minimum_voltage);
+    _mav_put_float(buf, 12, charging_maximum_voltage);
+    _mav_put_float(buf, 16, charging_maximum_current);
+    _mav_put_float(buf, 20, nominal_voltage);
+    _mav_put_float(buf, 24, discharge_maximum_current);
+    _mav_put_float(buf, 28, discharge_maximum_burst_current);
+    _mav_put_float(buf, 32, design_capacity);
+    _mav_put_float(buf, 36, full_charge_capacity);
+    _mav_put_uint16_t(buf, 40, cycle_count);
+    _mav_put_uint16_t(buf, 42, weight);
+    _mav_put_uint8_t(buf, 44, id);
+    _mav_put_uint8_t(buf, 45, battery_function);
+    _mav_put_uint8_t(buf, 46, type);
+    _mav_put_uint8_t(buf, 47, state_of_health);
+    _mav_put_uint8_t(buf, 48, cells_in_series);
+    _mav_put_char_array(buf, 49, manufacture_date, 9);
+    _mav_put_char_array(buf, 58, serial_number, 32);
+    _mav_put_char_array(buf, 90, name, 50);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_BATTERY_INFO_LEN);
+#else
+    mavlink_battery_info_t packet;
+    packet.discharge_minimum_voltage = discharge_minimum_voltage;
+    packet.charging_minimum_voltage = charging_minimum_voltage;
+    packet.resting_minimum_voltage = resting_minimum_voltage;
+    packet.charging_maximum_voltage = charging_maximum_voltage;
+    packet.charging_maximum_current = charging_maximum_current;
+    packet.nominal_voltage = nominal_voltage;
+    packet.discharge_maximum_current = discharge_maximum_current;
+    packet.discharge_maximum_burst_current = discharge_maximum_burst_current;
+    packet.design_capacity = design_capacity;
+    packet.full_charge_capacity = full_charge_capacity;
+    packet.cycle_count = cycle_count;
+    packet.weight = weight;
+    packet.id = id;
+    packet.battery_function = battery_function;
+    packet.type = type;
+    packet.state_of_health = state_of_health;
+    packet.cells_in_series = cells_in_series;
+    mav_array_memcpy(packet.manufacture_date, manufacture_date, sizeof(char)*9);
+    mav_array_memcpy(packet.serial_number, serial_number, sizeof(char)*32);
+    mav_array_memcpy(packet.name, name, sizeof(char)*50);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_BATTERY_INFO_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_BATTERY_INFO;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_BATTERY_INFO_MIN_LEN, MAVLINK_MSG_ID_BATTERY_INFO_LEN, MAVLINK_MSG_ID_BATTERY_INFO_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_BATTERY_INFO_MIN_LEN, MAVLINK_MSG_ID_BATTERY_INFO_LEN);
+#endif
+}
+
 /**
  * @brief Pack a battery_info message on a channel
  * @param system_id ID of this system
@@ -288,6 +376,20 @@ static inline uint16_t mavlink_msg_battery_info_encode_chan(uint8_t system_id, u
     return mavlink_msg_battery_info_pack_chan(system_id, component_id, chan, msg, battery_info->id, battery_info->battery_function, battery_info->type, battery_info->state_of_health, battery_info->cells_in_series, battery_info->cycle_count, battery_info->weight, battery_info->discharge_minimum_voltage, battery_info->charging_minimum_voltage, battery_info->resting_minimum_voltage, battery_info->charging_maximum_voltage, battery_info->charging_maximum_current, battery_info->nominal_voltage, battery_info->discharge_maximum_current, battery_info->discharge_maximum_burst_current, battery_info->design_capacity, battery_info->full_charge_capacity, battery_info->manufacture_date, battery_info->serial_number, battery_info->name);
 }
 
+/**
+ * @brief Encode a battery_info struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param battery_info C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_battery_info_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_battery_info_t* battery_info)
+{
+    return mavlink_msg_battery_info_pack_status(system_id, component_id, _status, msg,  battery_info->id, battery_info->battery_function, battery_info->type, battery_info->state_of_health, battery_info->cells_in_series, battery_info->cycle_count, battery_info->weight, battery_info->discharge_minimum_voltage, battery_info->charging_minimum_voltage, battery_info->resting_minimum_voltage, battery_info->charging_maximum_voltage, battery_info->charging_maximum_current, battery_info->nominal_voltage, battery_info->discharge_maximum_current, battery_info->discharge_maximum_burst_current, battery_info->design_capacity, battery_info->full_charge_capacity, battery_info->manufacture_date, battery_info->serial_number, battery_info->name);
+}
+
 /**
  * @brief Send a battery_info message
  * @param chan MAVLink channel to send the message

+ 84 - 0
v2.0/common/mavlink_msg_battery_status.h

@@ -140,6 +140,76 @@ static inline uint16_t mavlink_msg_battery_status_pack(uint8_t system_id, uint8_
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_BATTERY_STATUS_MIN_LEN, MAVLINK_MSG_ID_BATTERY_STATUS_LEN, MAVLINK_MSG_ID_BATTERY_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a battery_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param id  Battery ID
+ * @param battery_function  Function of the battery
+ * @param type  Type (chemistry) of the battery
+ * @param temperature [cdegC] Temperature of the battery. INT16_MAX for unknown temperature.
+ * @param voltages [mV] Battery voltage of cells 1 to 10 (see voltages_ext for cells 11-14). Cells in this field above the valid cell count for this battery should have the UINT16_MAX value. If individual cell voltages are unknown or not measured for this battery, then the overall battery voltage should be filled in cell 0, with all others set to UINT16_MAX. If the voltage of the battery is greater than (UINT16_MAX - 1), then cell 0 should be set to (UINT16_MAX - 1), and cell 1 to the remaining voltage. This can be extended to multiple cells if the total voltage is greater than 2 * (UINT16_MAX - 1).
+ * @param current_battery [cA] Battery current, -1: autopilot does not measure the current
+ * @param current_consumed [mAh] Consumed charge, -1: autopilot does not provide consumption estimate
+ * @param energy_consumed [hJ] Consumed energy, -1: autopilot does not provide energy consumption estimate
+ * @param battery_remaining [%] Remaining battery energy. Values: [0-100], -1: autopilot does not estimate the remaining battery.
+ * @param time_remaining [s] Remaining battery time, 0: autopilot does not provide remaining battery time estimate
+ * @param charge_state  State for extent of discharge, provided by autopilot for warning or external reactions
+ * @param voltages_ext [mV] Battery voltages for cells 11 to 14. Cells above the valid cell count for this battery should have a value of 0, where zero indicates not supported (note, this is different than for the voltages field and allows empty byte truncation). If the measured value is 0 then 1 should be sent instead.
+ * @param mode  Battery mode. Default (0) is that battery mode reporting is not supported or battery is in normal-use mode.
+ * @param fault_bitmask  Fault/health indications. These should be set when charge_state is MAV_BATTERY_CHARGE_STATE_FAILED or MAV_BATTERY_CHARGE_STATE_UNHEALTHY (if not, fault reporting is not supported).
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_battery_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t id, uint8_t battery_function, uint8_t type, int16_t temperature, const uint16_t *voltages, int16_t current_battery, int32_t current_consumed, int32_t energy_consumed, int8_t battery_remaining, int32_t time_remaining, uint8_t charge_state, const uint16_t *voltages_ext, uint8_t mode, uint32_t fault_bitmask)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_BATTERY_STATUS_LEN];
+    _mav_put_int32_t(buf, 0, current_consumed);
+    _mav_put_int32_t(buf, 4, energy_consumed);
+    _mav_put_int16_t(buf, 8, temperature);
+    _mav_put_int16_t(buf, 30, current_battery);
+    _mav_put_uint8_t(buf, 32, id);
+    _mav_put_uint8_t(buf, 33, battery_function);
+    _mav_put_uint8_t(buf, 34, type);
+    _mav_put_int8_t(buf, 35, battery_remaining);
+    _mav_put_int32_t(buf, 36, time_remaining);
+    _mav_put_uint8_t(buf, 40, charge_state);
+    _mav_put_uint8_t(buf, 49, mode);
+    _mav_put_uint32_t(buf, 50, fault_bitmask);
+    _mav_put_uint16_t_array(buf, 10, voltages, 10);
+    _mav_put_uint16_t_array(buf, 41, voltages_ext, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_BATTERY_STATUS_LEN);
+#else
+    mavlink_battery_status_t packet;
+    packet.current_consumed = current_consumed;
+    packet.energy_consumed = energy_consumed;
+    packet.temperature = temperature;
+    packet.current_battery = current_battery;
+    packet.id = id;
+    packet.battery_function = battery_function;
+    packet.type = type;
+    packet.battery_remaining = battery_remaining;
+    packet.time_remaining = time_remaining;
+    packet.charge_state = charge_state;
+    packet.mode = mode;
+    packet.fault_bitmask = fault_bitmask;
+    mav_array_memcpy(packet.voltages, voltages, sizeof(uint16_t)*10);
+    mav_array_memcpy(packet.voltages_ext, voltages_ext, sizeof(uint16_t)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_BATTERY_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_BATTERY_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_BATTERY_STATUS_MIN_LEN, MAVLINK_MSG_ID_BATTERY_STATUS_LEN, MAVLINK_MSG_ID_BATTERY_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_BATTERY_STATUS_MIN_LEN, MAVLINK_MSG_ID_BATTERY_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a battery_status message on a channel
  * @param system_id ID of this system
@@ -233,6 +303,20 @@ static inline uint16_t mavlink_msg_battery_status_encode_chan(uint8_t system_id,
     return mavlink_msg_battery_status_pack_chan(system_id, component_id, chan, msg, battery_status->id, battery_status->battery_function, battery_status->type, battery_status->temperature, battery_status->voltages, battery_status->current_battery, battery_status->current_consumed, battery_status->energy_consumed, battery_status->battery_remaining, battery_status->time_remaining, battery_status->charge_state, battery_status->voltages_ext, battery_status->mode, battery_status->fault_bitmask);
 }
 
+/**
+ * @brief Encode a battery_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param battery_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_battery_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_battery_status_t* battery_status)
+{
+    return mavlink_msg_battery_status_pack_status(system_id, component_id, _status, msg,  battery_status->id, battery_status->battery_function, battery_status->type, battery_status->temperature, battery_status->voltages, battery_status->current_battery, battery_status->current_consumed, battery_status->energy_consumed, battery_status->battery_remaining, battery_status->time_remaining, battery_status->charge_state, battery_status->voltages_ext, battery_status->mode, battery_status->fault_bitmask);
+}
+
 /**
  * @brief Send a battery_status message
  * @param chan MAVLink channel to send the message

+ 53 - 0
v2.0/common/mavlink_msg_button_change.h

@@ -75,6 +75,45 @@ static inline uint16_t mavlink_msg_button_change_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_BUTTON_CHANGE_MIN_LEN, MAVLINK_MSG_ID_BUTTON_CHANGE_LEN, MAVLINK_MSG_ID_BUTTON_CHANGE_CRC);
 }
 
+/**
+ * @brief Pack a button_change message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param last_change_ms [ms] Time of last change of button state.
+ * @param state  Bitmap for state of buttons.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_button_change_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint32_t last_change_ms, uint8_t state)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_BUTTON_CHANGE_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_uint32_t(buf, 4, last_change_ms);
+    _mav_put_uint8_t(buf, 8, state);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_BUTTON_CHANGE_LEN);
+#else
+    mavlink_button_change_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.last_change_ms = last_change_ms;
+    packet.state = state;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_BUTTON_CHANGE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_BUTTON_CHANGE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_BUTTON_CHANGE_MIN_LEN, MAVLINK_MSG_ID_BUTTON_CHANGE_LEN, MAVLINK_MSG_ID_BUTTON_CHANGE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_BUTTON_CHANGE_MIN_LEN, MAVLINK_MSG_ID_BUTTON_CHANGE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a button_change message on a channel
  * @param system_id ID of this system
@@ -137,6 +176,20 @@ static inline uint16_t mavlink_msg_button_change_encode_chan(uint8_t system_id,
     return mavlink_msg_button_change_pack_chan(system_id, component_id, chan, msg, button_change->time_boot_ms, button_change->last_change_ms, button_change->state);
 }
 
+/**
+ * @brief Encode a button_change struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param button_change C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_button_change_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_button_change_t* button_change)
+{
+    return mavlink_msg_button_change_pack_status(system_id, component_id, _status, msg,  button_change->time_boot_ms, button_change->last_change_ms, button_change->state);
+}
+
 /**
  * @brief Send a button_change message
  * @param chan MAVLink channel to send the message

+ 65 - 0
v2.0/common/mavlink_msg_camera_capture_status.h

@@ -99,6 +99,57 @@ static inline uint16_t mavlink_msg_camera_capture_status_pack(uint8_t system_id,
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_LEN, MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a camera_capture_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param image_status  Current status of image capturing (0: idle, 1: capture in progress, 2: interval set but idle, 3: interval set and capture in progress)
+ * @param video_status  Current status of video capturing (0: idle, 1: capture in progress)
+ * @param image_interval [s] Image capture interval
+ * @param recording_time_ms [ms] Elapsed time since recording started (0: Not supported/available). A GCS should compute recording time and use non-zero values of this field to correct any discrepancy.
+ * @param available_capacity [MiB] Available storage capacity.
+ * @param image_count  Total number of images captured ('forever', or until reset using MAV_CMD_STORAGE_FORMAT).
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_camera_capture_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint8_t image_status, uint8_t video_status, float image_interval, uint32_t recording_time_ms, float available_capacity, int32_t image_count)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_float(buf, 4, image_interval);
+    _mav_put_uint32_t(buf, 8, recording_time_ms);
+    _mav_put_float(buf, 12, available_capacity);
+    _mav_put_uint8_t(buf, 16, image_status);
+    _mav_put_uint8_t(buf, 17, video_status);
+    _mav_put_int32_t(buf, 18, image_count);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_LEN);
+#else
+    mavlink_camera_capture_status_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.image_interval = image_interval;
+    packet.recording_time_ms = recording_time_ms;
+    packet.available_capacity = available_capacity;
+    packet.image_status = image_status;
+    packet.video_status = video_status;
+    packet.image_count = image_count;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_LEN, MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_CAPTURE_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a camera_capture_status message on a channel
  * @param system_id ID of this system
@@ -173,6 +224,20 @@ static inline uint16_t mavlink_msg_camera_capture_status_encode_chan(uint8_t sys
     return mavlink_msg_camera_capture_status_pack_chan(system_id, component_id, chan, msg, camera_capture_status->time_boot_ms, camera_capture_status->image_status, camera_capture_status->video_status, camera_capture_status->image_interval, camera_capture_status->recording_time_ms, camera_capture_status->available_capacity, camera_capture_status->image_count);
 }
 
+/**
+ * @brief Encode a camera_capture_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param camera_capture_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_camera_capture_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_camera_capture_status_t* camera_capture_status)
+{
+    return mavlink_msg_camera_capture_status_pack_status(system_id, component_id, _status, msg,  camera_capture_status->time_boot_ms, camera_capture_status->image_status, camera_capture_status->video_status, camera_capture_status->image_interval, camera_capture_status->recording_time_ms, camera_capture_status->available_capacity, camera_capture_status->image_count);
+}
+
 /**
  * @brief Send a camera_capture_status message
  * @param chan MAVLink channel to send the message

+ 72 - 0
v2.0/common/mavlink_msg_camera_fov_status.h

@@ -115,6 +115,64 @@ static inline uint16_t mavlink_msg_camera_fov_status_pack(uint8_t system_id, uin
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CAMERA_FOV_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_FOV_STATUS_LEN, MAVLINK_MSG_ID_CAMERA_FOV_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a camera_fov_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param lat_camera [degE7] Latitude of camera (INT32_MAX if unknown).
+ * @param lon_camera [degE7] Longitude of camera (INT32_MAX if unknown).
+ * @param alt_camera [mm] Altitude (MSL) of camera (INT32_MAX if unknown).
+ * @param lat_image [degE7] Latitude of center of image (INT32_MAX if unknown, INT32_MIN if at infinity, not intersecting with horizon).
+ * @param lon_image [degE7] Longitude of center of image (INT32_MAX if unknown, INT32_MIN if at infinity, not intersecting with horizon).
+ * @param alt_image [mm] Altitude (MSL) of center of image (INT32_MAX if unknown, INT32_MIN if at infinity, not intersecting with horizon).
+ * @param q  Quaternion of camera orientation (w, x, y, z order, zero-rotation is 1, 0, 0, 0)
+ * @param hfov [deg] Horizontal field of view (NaN if unknown).
+ * @param vfov [deg] Vertical field of view (NaN if unknown).
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_camera_fov_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, int32_t lat_camera, int32_t lon_camera, int32_t alt_camera, int32_t lat_image, int32_t lon_image, int32_t alt_image, const float *q, float hfov, float vfov)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CAMERA_FOV_STATUS_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_int32_t(buf, 4, lat_camera);
+    _mav_put_int32_t(buf, 8, lon_camera);
+    _mav_put_int32_t(buf, 12, alt_camera);
+    _mav_put_int32_t(buf, 16, lat_image);
+    _mav_put_int32_t(buf, 20, lon_image);
+    _mav_put_int32_t(buf, 24, alt_image);
+    _mav_put_float(buf, 44, hfov);
+    _mav_put_float(buf, 48, vfov);
+    _mav_put_float_array(buf, 28, q, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CAMERA_FOV_STATUS_LEN);
+#else
+    mavlink_camera_fov_status_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.lat_camera = lat_camera;
+    packet.lon_camera = lon_camera;
+    packet.alt_camera = alt_camera;
+    packet.lat_image = lat_image;
+    packet.lon_image = lon_image;
+    packet.alt_image = alt_image;
+    packet.hfov = hfov;
+    packet.vfov = vfov;
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CAMERA_FOV_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CAMERA_FOV_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_FOV_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_FOV_STATUS_LEN, MAVLINK_MSG_ID_CAMERA_FOV_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_FOV_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_FOV_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a camera_fov_status message on a channel
  * @param system_id ID of this system
@@ -196,6 +254,20 @@ static inline uint16_t mavlink_msg_camera_fov_status_encode_chan(uint8_t system_
     return mavlink_msg_camera_fov_status_pack_chan(system_id, component_id, chan, msg, camera_fov_status->time_boot_ms, camera_fov_status->lat_camera, camera_fov_status->lon_camera, camera_fov_status->alt_camera, camera_fov_status->lat_image, camera_fov_status->lon_image, camera_fov_status->alt_image, camera_fov_status->q, camera_fov_status->hfov, camera_fov_status->vfov);
 }
 
+/**
+ * @brief Encode a camera_fov_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param camera_fov_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_camera_fov_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_camera_fov_status_t* camera_fov_status)
+{
+    return mavlink_msg_camera_fov_status_pack_status(system_id, component_id, _status, msg,  camera_fov_status->time_boot_ms, camera_fov_status->lat_camera, camera_fov_status->lon_camera, camera_fov_status->alt_camera, camera_fov_status->lat_image, camera_fov_status->lon_image, camera_fov_status->alt_image, camera_fov_status->q, camera_fov_status->hfov, camera_fov_status->vfov);
+}
+
 /**
  * @brief Send a camera_fov_status message
  * @param chan MAVLink channel to send the message

+ 75 - 0
v2.0/common/mavlink_msg_camera_image_captured.h

@@ -122,6 +122,67 @@ static inline uint16_t mavlink_msg_camera_image_captured_pack(uint8_t system_id,
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_MIN_LEN, MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_LEN, MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_CRC);
 }
 
+/**
+ * @brief Pack a camera_image_captured message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param time_utc [us] Timestamp (time since UNIX epoch) in UTC. 0 for unknown.
+ * @param camera_id  Deprecated/unused. Component IDs are used to differentiate multiple cameras.
+ * @param lat [degE7] Latitude where image was taken
+ * @param lon [degE7] Longitude where capture was taken
+ * @param alt [mm] Altitude (MSL) where image was taken
+ * @param relative_alt [mm] Altitude above ground
+ * @param q  Quaternion of camera orientation (w, x, y, z order, zero-rotation is 1, 0, 0, 0)
+ * @param image_index  Zero based index of this image (i.e. a new image will have index CAMERA_CAPTURE_STATUS.image count -1)
+ * @param capture_result  Boolean indicating success (1) or failure (0) while capturing this image.
+ * @param file_url  URL of image taken. Either local storage or http://foo.jpg if camera provides an HTTP interface.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_camera_image_captured_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint64_t time_utc, uint8_t camera_id, int32_t lat, int32_t lon, int32_t alt, int32_t relative_alt, const float *q, int32_t image_index, int8_t capture_result, const char *file_url)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_LEN];
+    _mav_put_uint64_t(buf, 0, time_utc);
+    _mav_put_uint32_t(buf, 8, time_boot_ms);
+    _mav_put_int32_t(buf, 12, lat);
+    _mav_put_int32_t(buf, 16, lon);
+    _mav_put_int32_t(buf, 20, alt);
+    _mav_put_int32_t(buf, 24, relative_alt);
+    _mav_put_int32_t(buf, 44, image_index);
+    _mav_put_uint8_t(buf, 48, camera_id);
+    _mav_put_int8_t(buf, 49, capture_result);
+    _mav_put_float_array(buf, 28, q, 4);
+    _mav_put_char_array(buf, 50, file_url, 205);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_LEN);
+#else
+    mavlink_camera_image_captured_t packet;
+    packet.time_utc = time_utc;
+    packet.time_boot_ms = time_boot_ms;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.relative_alt = relative_alt;
+    packet.image_index = image_index;
+    packet.camera_id = camera_id;
+    packet.capture_result = capture_result;
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+    mav_array_memcpy(packet.file_url, file_url, sizeof(char)*205);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_MIN_LEN, MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_LEN, MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_MIN_LEN, MAVLINK_MSG_ID_CAMERA_IMAGE_CAPTURED_LEN);
+#endif
+}
+
 /**
  * @brief Pack a camera_image_captured message on a channel
  * @param system_id ID of this system
@@ -206,6 +267,20 @@ static inline uint16_t mavlink_msg_camera_image_captured_encode_chan(uint8_t sys
     return mavlink_msg_camera_image_captured_pack_chan(system_id, component_id, chan, msg, camera_image_captured->time_boot_ms, camera_image_captured->time_utc, camera_image_captured->camera_id, camera_image_captured->lat, camera_image_captured->lon, camera_image_captured->alt, camera_image_captured->relative_alt, camera_image_captured->q, camera_image_captured->image_index, camera_image_captured->capture_result, camera_image_captured->file_url);
 }
 
+/**
+ * @brief Encode a camera_image_captured struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param camera_image_captured C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_camera_image_captured_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_camera_image_captured_t* camera_image_captured)
+{
+    return mavlink_msg_camera_image_captured_pack_status(system_id, component_id, _status, msg,  camera_image_captured->time_boot_ms, camera_image_captured->time_utc, camera_image_captured->camera_id, camera_image_captured->lat, camera_image_captured->lon, camera_image_captured->alt, camera_image_captured->relative_alt, camera_image_captured->q, camera_image_captured->image_index, camera_image_captured->capture_result, camera_image_captured->file_url);
+}
+
 /**
  * @brief Send a camera_image_captured message
  * @param chan MAVLink channel to send the message

+ 84 - 0
v2.0/common/mavlink_msg_camera_information.h

@@ -141,6 +141,76 @@ static inline uint16_t mavlink_msg_camera_information_pack(uint8_t system_id, ui
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CAMERA_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_CAMERA_INFORMATION_LEN, MAVLINK_MSG_ID_CAMERA_INFORMATION_CRC);
 }
 
+/**
+ * @brief Pack a camera_information message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param vendor_name  Name of the camera vendor
+ * @param model_name  Name of the camera model
+ * @param firmware_version  Version of the camera firmware, encoded as: (Dev & 0xff) << 24 | (Patch & 0xff) << 16 | (Minor & 0xff) << 8 | (Major & 0xff). Use 0 if not known.
+ * @param focal_length [mm] Focal length. Use NaN if not known.
+ * @param sensor_size_h [mm] Image sensor size horizontal. Use NaN if not known.
+ * @param sensor_size_v [mm] Image sensor size vertical. Use NaN if not known.
+ * @param resolution_h [pix] Horizontal image resolution. Use 0 if not known.
+ * @param resolution_v [pix] Vertical image resolution. Use 0 if not known.
+ * @param lens_id  Reserved for a lens ID.  Use 0 if not known.
+ * @param flags  Bitmap of camera capability flags.
+ * @param cam_definition_version  Camera definition version (iteration).  Use 0 if not known.
+ * @param cam_definition_uri  Camera definition URI (if any, otherwise only basic functions will be available). HTTP- (http://) and MAVLink FTP- (mavlinkftp://) formatted URIs are allowed (and both must be supported by any GCS that implements the Camera Protocol). The definition file may be xz compressed, which will be indicated by the file extension .xml.xz (a GCS that implements the protocol must support decompressing the file). The string needs to be zero terminated.  Use a zero-length string if not known.
+ * @param gimbal_device_id  Gimbal id of a gimbal associated with this camera. This is the component id of the gimbal device, or 1-6 for non mavlink gimbals. Use 0 if no gimbal is associated with the camera.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_camera_information_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, const uint8_t *vendor_name, const uint8_t *model_name, uint32_t firmware_version, float focal_length, float sensor_size_h, float sensor_size_v, uint16_t resolution_h, uint16_t resolution_v, uint8_t lens_id, uint32_t flags, uint16_t cam_definition_version, const char *cam_definition_uri, uint8_t gimbal_device_id)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CAMERA_INFORMATION_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_uint32_t(buf, 4, firmware_version);
+    _mav_put_float(buf, 8, focal_length);
+    _mav_put_float(buf, 12, sensor_size_h);
+    _mav_put_float(buf, 16, sensor_size_v);
+    _mav_put_uint32_t(buf, 20, flags);
+    _mav_put_uint16_t(buf, 24, resolution_h);
+    _mav_put_uint16_t(buf, 26, resolution_v);
+    _mav_put_uint16_t(buf, 28, cam_definition_version);
+    _mav_put_uint8_t(buf, 94, lens_id);
+    _mav_put_uint8_t(buf, 235, gimbal_device_id);
+    _mav_put_uint8_t_array(buf, 30, vendor_name, 32);
+    _mav_put_uint8_t_array(buf, 62, model_name, 32);
+    _mav_put_char_array(buf, 95, cam_definition_uri, 140);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CAMERA_INFORMATION_LEN);
+#else
+    mavlink_camera_information_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.firmware_version = firmware_version;
+    packet.focal_length = focal_length;
+    packet.sensor_size_h = sensor_size_h;
+    packet.sensor_size_v = sensor_size_v;
+    packet.flags = flags;
+    packet.resolution_h = resolution_h;
+    packet.resolution_v = resolution_v;
+    packet.cam_definition_version = cam_definition_version;
+    packet.lens_id = lens_id;
+    packet.gimbal_device_id = gimbal_device_id;
+    mav_array_memcpy(packet.vendor_name, vendor_name, sizeof(uint8_t)*32);
+    mav_array_memcpy(packet.model_name, model_name, sizeof(uint8_t)*32);
+    mav_array_memcpy(packet.cam_definition_uri, cam_definition_uri, sizeof(char)*140);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CAMERA_INFORMATION_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CAMERA_INFORMATION;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_CAMERA_INFORMATION_LEN, MAVLINK_MSG_ID_CAMERA_INFORMATION_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_CAMERA_INFORMATION_LEN);
+#endif
+}
+
 /**
  * @brief Pack a camera_information message on a channel
  * @param system_id ID of this system
@@ -234,6 +304,20 @@ static inline uint16_t mavlink_msg_camera_information_encode_chan(uint8_t system
     return mavlink_msg_camera_information_pack_chan(system_id, component_id, chan, msg, camera_information->time_boot_ms, camera_information->vendor_name, camera_information->model_name, camera_information->firmware_version, camera_information->focal_length, camera_information->sensor_size_h, camera_information->sensor_size_v, camera_information->resolution_h, camera_information->resolution_v, camera_information->lens_id, camera_information->flags, camera_information->cam_definition_version, camera_information->cam_definition_uri, camera_information->gimbal_device_id);
 }
 
+/**
+ * @brief Encode a camera_information struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param camera_information C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_camera_information_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_camera_information_t* camera_information)
+{
+    return mavlink_msg_camera_information_pack_status(system_id, component_id, _status, msg,  camera_information->time_boot_ms, camera_information->vendor_name, camera_information->model_name, camera_information->firmware_version, camera_information->focal_length, camera_information->sensor_size_h, camera_information->sensor_size_v, camera_information->resolution_h, camera_information->resolution_v, camera_information->lens_id, camera_information->flags, camera_information->cam_definition_version, camera_information->cam_definition_uri, camera_information->gimbal_device_id);
+}
+
 /**
  * @brief Send a camera_information message
  * @param chan MAVLink channel to send the message

+ 56 - 0
v2.0/common/mavlink_msg_camera_settings.h

@@ -81,6 +81,48 @@ static inline uint16_t mavlink_msg_camera_settings_pack(uint8_t system_id, uint8
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CAMERA_SETTINGS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_SETTINGS_LEN, MAVLINK_MSG_ID_CAMERA_SETTINGS_CRC);
 }
 
+/**
+ * @brief Pack a camera_settings message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param mode_id  Camera mode
+ * @param zoomLevel  Current zoom level as a percentage of the full range (0.0 to 100.0, NaN if not known)
+ * @param focusLevel  Current focus level as a percentage of the full range (0.0 to 100.0, NaN if not known)
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_camera_settings_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint8_t mode_id, float zoomLevel, float focusLevel)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CAMERA_SETTINGS_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_uint8_t(buf, 4, mode_id);
+    _mav_put_float(buf, 5, zoomLevel);
+    _mav_put_float(buf, 9, focusLevel);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CAMERA_SETTINGS_LEN);
+#else
+    mavlink_camera_settings_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.mode_id = mode_id;
+    packet.zoomLevel = zoomLevel;
+    packet.focusLevel = focusLevel;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CAMERA_SETTINGS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CAMERA_SETTINGS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_SETTINGS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_SETTINGS_LEN, MAVLINK_MSG_ID_CAMERA_SETTINGS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_SETTINGS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_SETTINGS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a camera_settings message on a channel
  * @param system_id ID of this system
@@ -146,6 +188,20 @@ static inline uint16_t mavlink_msg_camera_settings_encode_chan(uint8_t system_id
     return mavlink_msg_camera_settings_pack_chan(system_id, component_id, chan, msg, camera_settings->time_boot_ms, camera_settings->mode_id, camera_settings->zoomLevel, camera_settings->focusLevel);
 }
 
+/**
+ * @brief Encode a camera_settings struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param camera_settings C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_camera_settings_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_camera_settings_t* camera_settings)
+{
+    return mavlink_msg_camera_settings_pack_status(system_id, component_id, _status, msg,  camera_settings->time_boot_ms, camera_settings->mode_id, camera_settings->zoomLevel, camera_settings->focusLevel);
+}
+
 /**
  * @brief Send a camera_settings message
  * @param chan MAVLink channel to send the message

+ 83 - 0
v2.0/common/mavlink_msg_camera_tracking_geo_status.h

@@ -135,6 +135,75 @@ static inline uint16_t mavlink_msg_camera_tracking_geo_status_pack(uint8_t syste
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_LEN, MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a camera_tracking_geo_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param tracking_status  Current tracking status
+ * @param lat [degE7] Latitude of tracked object
+ * @param lon [degE7] Longitude of tracked object
+ * @param alt [m] Altitude of tracked object(AMSL, WGS84)
+ * @param h_acc [m] Horizontal accuracy. NAN if unknown
+ * @param v_acc [m] Vertical accuracy. NAN if unknown
+ * @param vel_n [m/s] North velocity of tracked object. NAN if unknown
+ * @param vel_e [m/s] East velocity of tracked object. NAN if unknown
+ * @param vel_d [m/s] Down velocity of tracked object. NAN if unknown
+ * @param vel_acc [m/s] Velocity accuracy. NAN if unknown
+ * @param dist [m] Distance between camera and tracked object. NAN if unknown
+ * @param hdg [rad] Heading in radians, in NED. NAN if unknown
+ * @param hdg_acc [rad] Accuracy of heading, in NED. NAN if unknown
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_camera_tracking_geo_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t tracking_status, int32_t lat, int32_t lon, float alt, float h_acc, float v_acc, float vel_n, float vel_e, float vel_d, float vel_acc, float dist, float hdg, float hdg_acc)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_LEN];
+    _mav_put_int32_t(buf, 0, lat);
+    _mav_put_int32_t(buf, 4, lon);
+    _mav_put_float(buf, 8, alt);
+    _mav_put_float(buf, 12, h_acc);
+    _mav_put_float(buf, 16, v_acc);
+    _mav_put_float(buf, 20, vel_n);
+    _mav_put_float(buf, 24, vel_e);
+    _mav_put_float(buf, 28, vel_d);
+    _mav_put_float(buf, 32, vel_acc);
+    _mav_put_float(buf, 36, dist);
+    _mav_put_float(buf, 40, hdg);
+    _mav_put_float(buf, 44, hdg_acc);
+    _mav_put_uint8_t(buf, 48, tracking_status);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_LEN);
+#else
+    mavlink_camera_tracking_geo_status_t packet;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.h_acc = h_acc;
+    packet.v_acc = v_acc;
+    packet.vel_n = vel_n;
+    packet.vel_e = vel_e;
+    packet.vel_d = vel_d;
+    packet.vel_acc = vel_acc;
+    packet.dist = dist;
+    packet.hdg = hdg;
+    packet.hdg_acc = hdg_acc;
+    packet.tracking_status = tracking_status;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_LEN, MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_TRACKING_GEO_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a camera_tracking_geo_status message on a channel
  * @param system_id ID of this system
@@ -227,6 +296,20 @@ static inline uint16_t mavlink_msg_camera_tracking_geo_status_encode_chan(uint8_
     return mavlink_msg_camera_tracking_geo_status_pack_chan(system_id, component_id, chan, msg, camera_tracking_geo_status->tracking_status, camera_tracking_geo_status->lat, camera_tracking_geo_status->lon, camera_tracking_geo_status->alt, camera_tracking_geo_status->h_acc, camera_tracking_geo_status->v_acc, camera_tracking_geo_status->vel_n, camera_tracking_geo_status->vel_e, camera_tracking_geo_status->vel_d, camera_tracking_geo_status->vel_acc, camera_tracking_geo_status->dist, camera_tracking_geo_status->hdg, camera_tracking_geo_status->hdg_acc);
 }
 
+/**
+ * @brief Encode a camera_tracking_geo_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param camera_tracking_geo_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_camera_tracking_geo_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_camera_tracking_geo_status_t* camera_tracking_geo_status)
+{
+    return mavlink_msg_camera_tracking_geo_status_pack_status(system_id, component_id, _status, msg,  camera_tracking_geo_status->tracking_status, camera_tracking_geo_status->lat, camera_tracking_geo_status->lon, camera_tracking_geo_status->alt, camera_tracking_geo_status->h_acc, camera_tracking_geo_status->v_acc, camera_tracking_geo_status->vel_n, camera_tracking_geo_status->vel_e, camera_tracking_geo_status->vel_d, camera_tracking_geo_status->vel_acc, camera_tracking_geo_status->dist, camera_tracking_geo_status->hdg, camera_tracking_geo_status->hdg_acc);
+}
+
 /**
  * @brief Send a camera_tracking_geo_status message
  * @param chan MAVLink channel to send the message

+ 74 - 0
v2.0/common/mavlink_msg_camera_tracking_image_status.h

@@ -117,6 +117,66 @@ static inline uint16_t mavlink_msg_camera_tracking_image_status_pack(uint8_t sys
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_LEN, MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a camera_tracking_image_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param tracking_status  Current tracking status
+ * @param tracking_mode  Current tracking mode
+ * @param target_data  Defines location of target data
+ * @param point_x  Current tracked point x value if CAMERA_TRACKING_MODE_POINT (normalized 0..1, 0 is left, 1 is right), NAN if unknown
+ * @param point_y  Current tracked point y value if CAMERA_TRACKING_MODE_POINT (normalized 0..1, 0 is top, 1 is bottom), NAN if unknown
+ * @param radius  Current tracked radius if CAMERA_TRACKING_MODE_POINT (normalized 0..1, 0 is image left, 1 is image right), NAN if unknown
+ * @param rec_top_x  Current tracked rectangle top x value if CAMERA_TRACKING_MODE_RECTANGLE (normalized 0..1, 0 is left, 1 is right), NAN if unknown
+ * @param rec_top_y  Current tracked rectangle top y value if CAMERA_TRACKING_MODE_RECTANGLE (normalized 0..1, 0 is top, 1 is bottom), NAN if unknown
+ * @param rec_bottom_x  Current tracked rectangle bottom x value if CAMERA_TRACKING_MODE_RECTANGLE (normalized 0..1, 0 is left, 1 is right), NAN if unknown
+ * @param rec_bottom_y  Current tracked rectangle bottom y value if CAMERA_TRACKING_MODE_RECTANGLE (normalized 0..1, 0 is top, 1 is bottom), NAN if unknown
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_camera_tracking_image_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t tracking_status, uint8_t tracking_mode, uint8_t target_data, float point_x, float point_y, float radius, float rec_top_x, float rec_top_y, float rec_bottom_x, float rec_bottom_y)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_LEN];
+    _mav_put_float(buf, 0, point_x);
+    _mav_put_float(buf, 4, point_y);
+    _mav_put_float(buf, 8, radius);
+    _mav_put_float(buf, 12, rec_top_x);
+    _mav_put_float(buf, 16, rec_top_y);
+    _mav_put_float(buf, 20, rec_bottom_x);
+    _mav_put_float(buf, 24, rec_bottom_y);
+    _mav_put_uint8_t(buf, 28, tracking_status);
+    _mav_put_uint8_t(buf, 29, tracking_mode);
+    _mav_put_uint8_t(buf, 30, target_data);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_LEN);
+#else
+    mavlink_camera_tracking_image_status_t packet;
+    packet.point_x = point_x;
+    packet.point_y = point_y;
+    packet.radius = radius;
+    packet.rec_top_x = rec_top_x;
+    packet.rec_top_y = rec_top_y;
+    packet.rec_bottom_x = rec_bottom_x;
+    packet.rec_bottom_y = rec_bottom_y;
+    packet.tracking_status = tracking_status;
+    packet.tracking_mode = tracking_mode;
+    packet.target_data = target_data;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_LEN, MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_MIN_LEN, MAVLINK_MSG_ID_CAMERA_TRACKING_IMAGE_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a camera_tracking_image_status message on a channel
  * @param system_id ID of this system
@@ -200,6 +260,20 @@ static inline uint16_t mavlink_msg_camera_tracking_image_status_encode_chan(uint
     return mavlink_msg_camera_tracking_image_status_pack_chan(system_id, component_id, chan, msg, camera_tracking_image_status->tracking_status, camera_tracking_image_status->tracking_mode, camera_tracking_image_status->target_data, camera_tracking_image_status->point_x, camera_tracking_image_status->point_y, camera_tracking_image_status->radius, camera_tracking_image_status->rec_top_x, camera_tracking_image_status->rec_top_y, camera_tracking_image_status->rec_bottom_x, camera_tracking_image_status->rec_bottom_y);
 }
 
+/**
+ * @brief Encode a camera_tracking_image_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param camera_tracking_image_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_camera_tracking_image_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_camera_tracking_image_status_t* camera_tracking_image_status)
+{
+    return mavlink_msg_camera_tracking_image_status_pack_status(system_id, component_id, _status, msg,  camera_tracking_image_status->tracking_status, camera_tracking_image_status->tracking_mode, camera_tracking_image_status->target_data, camera_tracking_image_status->point_x, camera_tracking_image_status->point_y, camera_tracking_image_status->radius, camera_tracking_image_status->rec_top_x, camera_tracking_image_status->rec_top_y, camera_tracking_image_status->rec_bottom_x, camera_tracking_image_status->rec_bottom_y);
+}
+
 /**
  * @brief Send a camera_tracking_image_status message
  * @param chan MAVLink channel to send the message

+ 50 - 0
v2.0/common/mavlink_msg_camera_trigger.h

@@ -69,6 +69,42 @@ static inline uint16_t mavlink_msg_camera_trigger_pack(uint8_t system_id, uint8_
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CAMERA_TRIGGER_MIN_LEN, MAVLINK_MSG_ID_CAMERA_TRIGGER_LEN, MAVLINK_MSG_ID_CAMERA_TRIGGER_CRC);
 }
 
+/**
+ * @brief Pack a camera_trigger message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp for image frame (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param seq  Image frame sequence
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_camera_trigger_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint32_t seq)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CAMERA_TRIGGER_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_uint32_t(buf, 8, seq);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CAMERA_TRIGGER_LEN);
+#else
+    mavlink_camera_trigger_t packet;
+    packet.time_usec = time_usec;
+    packet.seq = seq;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CAMERA_TRIGGER_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CAMERA_TRIGGER;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_TRIGGER_MIN_LEN, MAVLINK_MSG_ID_CAMERA_TRIGGER_LEN, MAVLINK_MSG_ID_CAMERA_TRIGGER_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAMERA_TRIGGER_MIN_LEN, MAVLINK_MSG_ID_CAMERA_TRIGGER_LEN);
+#endif
+}
+
 /**
  * @brief Pack a camera_trigger message on a channel
  * @param system_id ID of this system
@@ -128,6 +164,20 @@ static inline uint16_t mavlink_msg_camera_trigger_encode_chan(uint8_t system_id,
     return mavlink_msg_camera_trigger_pack_chan(system_id, component_id, chan, msg, camera_trigger->time_usec, camera_trigger->seq);
 }
 
+/**
+ * @brief Encode a camera_trigger struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param camera_trigger C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_camera_trigger_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_camera_trigger_t* camera_trigger)
+{
+    return mavlink_msg_camera_trigger_pack_status(system_id, component_id, _status, msg,  camera_trigger->time_usec, camera_trigger->seq);
+}
+
 /**
  * @brief Send a camera_trigger message
  * @param chan MAVLink channel to send the message

+ 60 - 0
v2.0/common/mavlink_msg_can_filter_modify.h

@@ -91,6 +91,52 @@ static inline uint16_t mavlink_msg_can_filter_modify_pack(uint8_t system_id, uin
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CAN_FILTER_MODIFY_MIN_LEN, MAVLINK_MSG_ID_CAN_FILTER_MODIFY_LEN, MAVLINK_MSG_ID_CAN_FILTER_MODIFY_CRC);
 }
 
+/**
+ * @brief Pack a can_filter_modify message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID.
+ * @param target_component  Component ID.
+ * @param bus  bus number
+ * @param operation  what operation to perform on the filter list. See CAN_FILTER_OP enum.
+ * @param num_ids  number of IDs in filter list
+ * @param ids  filter IDs, length num_ids
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_can_filter_modify_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint8_t bus, uint8_t operation, uint8_t num_ids, const uint16_t *ids)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CAN_FILTER_MODIFY_LEN];
+    _mav_put_uint8_t(buf, 32, target_system);
+    _mav_put_uint8_t(buf, 33, target_component);
+    _mav_put_uint8_t(buf, 34, bus);
+    _mav_put_uint8_t(buf, 35, operation);
+    _mav_put_uint8_t(buf, 36, num_ids);
+    _mav_put_uint16_t_array(buf, 0, ids, 16);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CAN_FILTER_MODIFY_LEN);
+#else
+    mavlink_can_filter_modify_t packet;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.bus = bus;
+    packet.operation = operation;
+    packet.num_ids = num_ids;
+    mav_array_memcpy(packet.ids, ids, sizeof(uint16_t)*16);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CAN_FILTER_MODIFY_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CAN_FILTER_MODIFY;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAN_FILTER_MODIFY_MIN_LEN, MAVLINK_MSG_ID_CAN_FILTER_MODIFY_LEN, MAVLINK_MSG_ID_CAN_FILTER_MODIFY_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAN_FILTER_MODIFY_MIN_LEN, MAVLINK_MSG_ID_CAN_FILTER_MODIFY_LEN);
+#endif
+}
+
 /**
  * @brief Pack a can_filter_modify message on a channel
  * @param system_id ID of this system
@@ -160,6 +206,20 @@ static inline uint16_t mavlink_msg_can_filter_modify_encode_chan(uint8_t system_
     return mavlink_msg_can_filter_modify_pack_chan(system_id, component_id, chan, msg, can_filter_modify->target_system, can_filter_modify->target_component, can_filter_modify->bus, can_filter_modify->operation, can_filter_modify->num_ids, can_filter_modify->ids);
 }
 
+/**
+ * @brief Encode a can_filter_modify struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param can_filter_modify C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_can_filter_modify_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_can_filter_modify_t* can_filter_modify)
+{
+    return mavlink_msg_can_filter_modify_pack_status(system_id, component_id, _status, msg,  can_filter_modify->target_system, can_filter_modify->target_component, can_filter_modify->bus, can_filter_modify->operation, can_filter_modify->num_ids, can_filter_modify->ids);
+}
+
 /**
  * @brief Send a can_filter_modify message
  * @param chan MAVLink channel to send the message

+ 60 - 0
v2.0/common/mavlink_msg_can_frame.h

@@ -91,6 +91,52 @@ static inline uint16_t mavlink_msg_can_frame_pack(uint8_t system_id, uint8_t com
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CAN_FRAME_MIN_LEN, MAVLINK_MSG_ID_CAN_FRAME_LEN, MAVLINK_MSG_ID_CAN_FRAME_CRC);
 }
 
+/**
+ * @brief Pack a can_frame message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID.
+ * @param target_component  Component ID.
+ * @param bus  Bus number
+ * @param len  Frame length
+ * @param id  Frame ID
+ * @param data  Frame data
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_can_frame_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint8_t bus, uint8_t len, uint32_t id, const uint8_t *data)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CAN_FRAME_LEN];
+    _mav_put_uint32_t(buf, 0, id);
+    _mav_put_uint8_t(buf, 4, target_system);
+    _mav_put_uint8_t(buf, 5, target_component);
+    _mav_put_uint8_t(buf, 6, bus);
+    _mav_put_uint8_t(buf, 7, len);
+    _mav_put_uint8_t_array(buf, 8, data, 8);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CAN_FRAME_LEN);
+#else
+    mavlink_can_frame_t packet;
+    packet.id = id;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.bus = bus;
+    packet.len = len;
+    mav_array_memcpy(packet.data, data, sizeof(uint8_t)*8);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CAN_FRAME_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CAN_FRAME;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAN_FRAME_MIN_LEN, MAVLINK_MSG_ID_CAN_FRAME_LEN, MAVLINK_MSG_ID_CAN_FRAME_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CAN_FRAME_MIN_LEN, MAVLINK_MSG_ID_CAN_FRAME_LEN);
+#endif
+}
+
 /**
  * @brief Pack a can_frame message on a channel
  * @param system_id ID of this system
@@ -160,6 +206,20 @@ static inline uint16_t mavlink_msg_can_frame_encode_chan(uint8_t system_id, uint
     return mavlink_msg_can_frame_pack_chan(system_id, component_id, chan, msg, can_frame->target_system, can_frame->target_component, can_frame->bus, can_frame->len, can_frame->id, can_frame->data);
 }
 
+/**
+ * @brief Encode a can_frame struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param can_frame C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_can_frame_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_can_frame_t* can_frame)
+{
+    return mavlink_msg_can_frame_pack_status(system_id, component_id, _status, msg,  can_frame->target_system, can_frame->target_component, can_frame->bus, can_frame->len, can_frame->id, can_frame->data);
+}
+
 /**
  * @brief Send a can_frame message
  * @param chan MAVLink channel to send the message

+ 60 - 0
v2.0/common/mavlink_msg_canfd_frame.h

@@ -91,6 +91,52 @@ static inline uint16_t mavlink_msg_canfd_frame_pack(uint8_t system_id, uint8_t c
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CANFD_FRAME_MIN_LEN, MAVLINK_MSG_ID_CANFD_FRAME_LEN, MAVLINK_MSG_ID_CANFD_FRAME_CRC);
 }
 
+/**
+ * @brief Pack a canfd_frame message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID.
+ * @param target_component  Component ID.
+ * @param bus  bus number
+ * @param len  Frame length
+ * @param id  Frame ID
+ * @param data  Frame data
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_canfd_frame_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint8_t bus, uint8_t len, uint32_t id, const uint8_t *data)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CANFD_FRAME_LEN];
+    _mav_put_uint32_t(buf, 0, id);
+    _mav_put_uint8_t(buf, 4, target_system);
+    _mav_put_uint8_t(buf, 5, target_component);
+    _mav_put_uint8_t(buf, 6, bus);
+    _mav_put_uint8_t(buf, 7, len);
+    _mav_put_uint8_t_array(buf, 8, data, 64);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CANFD_FRAME_LEN);
+#else
+    mavlink_canfd_frame_t packet;
+    packet.id = id;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.bus = bus;
+    packet.len = len;
+    mav_array_memcpy(packet.data, data, sizeof(uint8_t)*64);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CANFD_FRAME_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CANFD_FRAME;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CANFD_FRAME_MIN_LEN, MAVLINK_MSG_ID_CANFD_FRAME_LEN, MAVLINK_MSG_ID_CANFD_FRAME_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CANFD_FRAME_MIN_LEN, MAVLINK_MSG_ID_CANFD_FRAME_LEN);
+#endif
+}
+
 /**
  * @brief Pack a canfd_frame message on a channel
  * @param system_id ID of this system
@@ -160,6 +206,20 @@ static inline uint16_t mavlink_msg_canfd_frame_encode_chan(uint8_t system_id, ui
     return mavlink_msg_canfd_frame_pack_chan(system_id, component_id, chan, msg, canfd_frame->target_system, canfd_frame->target_component, canfd_frame->bus, canfd_frame->len, canfd_frame->id, canfd_frame->data);
 }
 
+/**
+ * @brief Encode a canfd_frame struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param canfd_frame C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_canfd_frame_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_canfd_frame_t* canfd_frame)
+{
+    return mavlink_msg_canfd_frame_pack_status(system_id, component_id, _status, msg,  canfd_frame->target_system, canfd_frame->target_component, canfd_frame->bus, canfd_frame->len, canfd_frame->id, canfd_frame->data);
+}
+
 /**
  * @brief Send a canfd_frame message
  * @param chan MAVLink channel to send the message

+ 66 - 0
v2.0/common/mavlink_msg_cellular_config.h

@@ -106,6 +106,58 @@ static inline uint16_t mavlink_msg_cellular_config_pack(uint8_t system_id, uint8
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CELLULAR_CONFIG_MIN_LEN, MAVLINK_MSG_ID_CELLULAR_CONFIG_LEN, MAVLINK_MSG_ID_CELLULAR_CONFIG_CRC);
 }
 
+/**
+ * @brief Pack a cellular_config message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param enable_lte  Enable/disable LTE. 0: setting unchanged, 1: disabled, 2: enabled. Current setting when sent back as a response.
+ * @param enable_pin  Enable/disable PIN on the SIM card. 0: setting unchanged, 1: disabled, 2: enabled. Current setting when sent back as a response.
+ * @param pin  PIN sent to the SIM card. Blank when PIN is disabled. Empty when message is sent back as a response.
+ * @param new_pin  New PIN when changing the PIN. Blank to leave it unchanged. Empty when message is sent back as a response.
+ * @param apn  Name of the cellular APN. Blank to leave it unchanged. Current APN when sent back as a response.
+ * @param puk  Required PUK code in case the user failed to authenticate 3 times with the PIN. Empty when message is sent back as a response.
+ * @param roaming  Enable/disable roaming. 0: setting unchanged, 1: disabled, 2: enabled. Current setting when sent back as a response.
+ * @param response  Message acceptance response (sent back to GS).
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_cellular_config_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t enable_lte, uint8_t enable_pin, const char *pin, const char *new_pin, const char *apn, const char *puk, uint8_t roaming, uint8_t response)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CELLULAR_CONFIG_LEN];
+    _mav_put_uint8_t(buf, 0, enable_lte);
+    _mav_put_uint8_t(buf, 1, enable_pin);
+    _mav_put_uint8_t(buf, 82, roaming);
+    _mav_put_uint8_t(buf, 83, response);
+    _mav_put_char_array(buf, 2, pin, 16);
+    _mav_put_char_array(buf, 18, new_pin, 16);
+    _mav_put_char_array(buf, 34, apn, 32);
+    _mav_put_char_array(buf, 66, puk, 16);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CELLULAR_CONFIG_LEN);
+#else
+    mavlink_cellular_config_t packet;
+    packet.enable_lte = enable_lte;
+    packet.enable_pin = enable_pin;
+    packet.roaming = roaming;
+    packet.response = response;
+    mav_array_memcpy(packet.pin, pin, sizeof(char)*16);
+    mav_array_memcpy(packet.new_pin, new_pin, sizeof(char)*16);
+    mav_array_memcpy(packet.apn, apn, sizeof(char)*32);
+    mav_array_memcpy(packet.puk, puk, sizeof(char)*16);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CELLULAR_CONFIG_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CELLULAR_CONFIG;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CELLULAR_CONFIG_MIN_LEN, MAVLINK_MSG_ID_CELLULAR_CONFIG_LEN, MAVLINK_MSG_ID_CELLULAR_CONFIG_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CELLULAR_CONFIG_MIN_LEN, MAVLINK_MSG_ID_CELLULAR_CONFIG_LEN);
+#endif
+}
+
 /**
  * @brief Pack a cellular_config message on a channel
  * @param system_id ID of this system
@@ -181,6 +233,20 @@ static inline uint16_t mavlink_msg_cellular_config_encode_chan(uint8_t system_id
     return mavlink_msg_cellular_config_pack_chan(system_id, component_id, chan, msg, cellular_config->enable_lte, cellular_config->enable_pin, cellular_config->pin, cellular_config->new_pin, cellular_config->apn, cellular_config->puk, cellular_config->roaming, cellular_config->response);
 }
 
+/**
+ * @brief Encode a cellular_config struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param cellular_config C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_cellular_config_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_cellular_config_t* cellular_config)
+{
+    return mavlink_msg_cellular_config_pack_status(system_id, component_id, _status, msg,  cellular_config->enable_lte, cellular_config->enable_pin, cellular_config->pin, cellular_config->new_pin, cellular_config->apn, cellular_config->puk, cellular_config->roaming, cellular_config->response);
+}
+
 /**
  * @brief Send a cellular_config message
  * @param chan MAVLink channel to send the message

+ 65 - 0
v2.0/common/mavlink_msg_cellular_status.h

@@ -99,6 +99,57 @@ static inline uint16_t mavlink_msg_cellular_status_pack(uint8_t system_id, uint8
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CELLULAR_STATUS_MIN_LEN, MAVLINK_MSG_ID_CELLULAR_STATUS_LEN, MAVLINK_MSG_ID_CELLULAR_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a cellular_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param status  Cellular modem status
+ * @param failure_reason  Failure reason when status in in CELLULAR_STATUS_FLAG_FAILED
+ * @param type  Cellular network radio type: gsm, cdma, lte...
+ * @param quality  Signal quality in percent. If unknown, set to UINT8_MAX
+ * @param mcc  Mobile country code. If unknown, set to UINT16_MAX
+ * @param mnc  Mobile network code. If unknown, set to UINT16_MAX
+ * @param lac  Location area code. If unknown, set to 0
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_cellular_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t status, uint8_t failure_reason, uint8_t type, uint8_t quality, uint16_t mcc, uint16_t mnc, uint16_t lac)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CELLULAR_STATUS_LEN];
+    _mav_put_uint16_t(buf, 0, mcc);
+    _mav_put_uint16_t(buf, 2, mnc);
+    _mav_put_uint16_t(buf, 4, lac);
+    _mav_put_uint8_t(buf, 6, status);
+    _mav_put_uint8_t(buf, 7, failure_reason);
+    _mav_put_uint8_t(buf, 8, type);
+    _mav_put_uint8_t(buf, 9, quality);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CELLULAR_STATUS_LEN);
+#else
+    mavlink_cellular_status_t packet;
+    packet.mcc = mcc;
+    packet.mnc = mnc;
+    packet.lac = lac;
+    packet.status = status;
+    packet.failure_reason = failure_reason;
+    packet.type = type;
+    packet.quality = quality;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CELLULAR_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CELLULAR_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CELLULAR_STATUS_MIN_LEN, MAVLINK_MSG_ID_CELLULAR_STATUS_LEN, MAVLINK_MSG_ID_CELLULAR_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CELLULAR_STATUS_MIN_LEN, MAVLINK_MSG_ID_CELLULAR_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a cellular_status message on a channel
  * @param system_id ID of this system
@@ -173,6 +224,20 @@ static inline uint16_t mavlink_msg_cellular_status_encode_chan(uint8_t system_id
     return mavlink_msg_cellular_status_pack_chan(system_id, component_id, chan, msg, cellular_status->status, cellular_status->failure_reason, cellular_status->type, cellular_status->quality, cellular_status->mcc, cellular_status->mnc, cellular_status->lac);
 }
 
+/**
+ * @brief Encode a cellular_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param cellular_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_cellular_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_cellular_status_t* cellular_status)
+{
+    return mavlink_msg_cellular_status_pack_status(system_id, component_id, _status, msg,  cellular_status->status, cellular_status->failure_reason, cellular_status->type, cellular_status->quality, cellular_status->mcc, cellular_status->mnc, cellular_status->lac);
+}
+
 /**
  * @brief Send a cellular_status message
  * @param chan MAVLink channel to send the message

+ 54 - 0
v2.0/common/mavlink_msg_change_operator_control.h

@@ -79,6 +79,46 @@ static inline uint16_t mavlink_msg_change_operator_control_pack(uint8_t system_i
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_MIN_LEN, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_LEN, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_CRC);
 }
 
+/**
+ * @brief Pack a change_operator_control message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System the GCS requests control for
+ * @param control_request  0: request control of this MAV, 1: Release control of this MAV
+ * @param version [rad] 0: key as plaintext, 1-255: future, different hashing/encryption variants. The GCS should in general use the safest mode possible initially and then gradually move down the encryption level if it gets a NACK message indicating an encryption mismatch.
+ * @param passkey  Password / Key, depending on version plaintext or encrypted. 25 or less characters, NULL terminated. The characters may involve A-Z, a-z, 0-9, and "!?,.-"
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_change_operator_control_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t control_request, uint8_t version, const char *passkey)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_LEN];
+    _mav_put_uint8_t(buf, 0, target_system);
+    _mav_put_uint8_t(buf, 1, control_request);
+    _mav_put_uint8_t(buf, 2, version);
+    _mav_put_char_array(buf, 3, passkey, 25);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_LEN);
+#else
+    mavlink_change_operator_control_t packet;
+    packet.target_system = target_system;
+    packet.control_request = control_request;
+    packet.version = version;
+    mav_array_memcpy(packet.passkey, passkey, sizeof(char)*25);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_MIN_LEN, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_LEN, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_MIN_LEN, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_LEN);
+#endif
+}
+
 /**
  * @brief Pack a change_operator_control message on a channel
  * @param system_id ID of this system
@@ -142,6 +182,20 @@ static inline uint16_t mavlink_msg_change_operator_control_encode_chan(uint8_t s
     return mavlink_msg_change_operator_control_pack_chan(system_id, component_id, chan, msg, change_operator_control->target_system, change_operator_control->control_request, change_operator_control->version, change_operator_control->passkey);
 }
 
+/**
+ * @brief Encode a change_operator_control struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param change_operator_control C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_change_operator_control_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_change_operator_control_t* change_operator_control)
+{
+    return mavlink_msg_change_operator_control_pack_status(system_id, component_id, _status, msg,  change_operator_control->target_system, change_operator_control->control_request, change_operator_control->version, change_operator_control->passkey);
+}
+
 /**
  * @brief Send a change_operator_control message
  * @param chan MAVLink channel to send the message

+ 53 - 0
v2.0/common/mavlink_msg_change_operator_control_ack.h

@@ -75,6 +75,45 @@ static inline uint16_t mavlink_msg_change_operator_control_ack_pack(uint8_t syst
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_MIN_LEN, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_LEN, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_CRC);
 }
 
+/**
+ * @brief Pack a change_operator_control_ack message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param gcs_system_id  ID of the GCS this message 
+ * @param control_request  0: request control of this MAV, 1: Release control of this MAV
+ * @param ack  0: ACK, 1: NACK: Wrong passkey, 2: NACK: Unsupported passkey encryption method, 3: NACK: Already under control
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_change_operator_control_ack_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t gcs_system_id, uint8_t control_request, uint8_t ack)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_LEN];
+    _mav_put_uint8_t(buf, 0, gcs_system_id);
+    _mav_put_uint8_t(buf, 1, control_request);
+    _mav_put_uint8_t(buf, 2, ack);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_LEN);
+#else
+    mavlink_change_operator_control_ack_t packet;
+    packet.gcs_system_id = gcs_system_id;
+    packet.control_request = control_request;
+    packet.ack = ack;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_MIN_LEN, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_LEN, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_MIN_LEN, MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_ACK_LEN);
+#endif
+}
+
 /**
  * @brief Pack a change_operator_control_ack message on a channel
  * @param system_id ID of this system
@@ -137,6 +176,20 @@ static inline uint16_t mavlink_msg_change_operator_control_ack_encode_chan(uint8
     return mavlink_msg_change_operator_control_ack_pack_chan(system_id, component_id, chan, msg, change_operator_control_ack->gcs_system_id, change_operator_control_ack->control_request, change_operator_control_ack->ack);
 }
 
+/**
+ * @brief Encode a change_operator_control_ack struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param change_operator_control_ack C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_change_operator_control_ack_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_change_operator_control_ack_t* change_operator_control_ack)
+{
+    return mavlink_msg_change_operator_control_ack_pack_status(system_id, component_id, _status, msg,  change_operator_control_ack->gcs_system_id, change_operator_control_ack->control_request, change_operator_control_ack->ack);
+}
+
 /**
  * @brief Send a change_operator_control_ack message
  * @param chan MAVLink channel to send the message

+ 65 - 0
v2.0/common/mavlink_msg_collision.h

@@ -99,6 +99,57 @@ static inline uint16_t mavlink_msg_collision_pack(uint8_t system_id, uint8_t com
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_COLLISION_MIN_LEN, MAVLINK_MSG_ID_COLLISION_LEN, MAVLINK_MSG_ID_COLLISION_CRC);
 }
 
+/**
+ * @brief Pack a collision message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param src  Collision data source
+ * @param id  Unique identifier, domain based on src field
+ * @param action  Action that is being taken to avoid this collision
+ * @param threat_level  How concerned the aircraft is about this collision
+ * @param time_to_minimum_delta [s] Estimated time until collision occurs
+ * @param altitude_minimum_delta [m] Closest vertical distance between vehicle and object
+ * @param horizontal_minimum_delta [m] Closest horizontal distance between vehicle and object
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_collision_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t src, uint32_t id, uint8_t action, uint8_t threat_level, float time_to_minimum_delta, float altitude_minimum_delta, float horizontal_minimum_delta)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_COLLISION_LEN];
+    _mav_put_uint32_t(buf, 0, id);
+    _mav_put_float(buf, 4, time_to_minimum_delta);
+    _mav_put_float(buf, 8, altitude_minimum_delta);
+    _mav_put_float(buf, 12, horizontal_minimum_delta);
+    _mav_put_uint8_t(buf, 16, src);
+    _mav_put_uint8_t(buf, 17, action);
+    _mav_put_uint8_t(buf, 18, threat_level);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_COLLISION_LEN);
+#else
+    mavlink_collision_t packet;
+    packet.id = id;
+    packet.time_to_minimum_delta = time_to_minimum_delta;
+    packet.altitude_minimum_delta = altitude_minimum_delta;
+    packet.horizontal_minimum_delta = horizontal_minimum_delta;
+    packet.src = src;
+    packet.action = action;
+    packet.threat_level = threat_level;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_COLLISION_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_COLLISION;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COLLISION_MIN_LEN, MAVLINK_MSG_ID_COLLISION_LEN, MAVLINK_MSG_ID_COLLISION_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COLLISION_MIN_LEN, MAVLINK_MSG_ID_COLLISION_LEN);
+#endif
+}
+
 /**
  * @brief Pack a collision message on a channel
  * @param system_id ID of this system
@@ -173,6 +224,20 @@ static inline uint16_t mavlink_msg_collision_encode_chan(uint8_t system_id, uint
     return mavlink_msg_collision_pack_chan(system_id, component_id, chan, msg, collision->src, collision->id, collision->action, collision->threat_level, collision->time_to_minimum_delta, collision->altitude_minimum_delta, collision->horizontal_minimum_delta);
 }
 
+/**
+ * @brief Encode a collision struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param collision C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_collision_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_collision_t* collision)
+{
+    return mavlink_msg_collision_pack_status(system_id, component_id, _status, msg,  collision->src, collision->id, collision->action, collision->threat_level, collision->time_to_minimum_delta, collision->altitude_minimum_delta, collision->horizontal_minimum_delta);
+}
+
 /**
  * @brief Send a collision message
  * @param chan MAVLink channel to send the message

+ 62 - 0
v2.0/common/mavlink_msg_command_ack.h

@@ -93,6 +93,54 @@ static inline uint16_t mavlink_msg_command_ack_pack(uint8_t system_id, uint8_t c
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_COMMAND_ACK_MIN_LEN, MAVLINK_MSG_ID_COMMAND_ACK_LEN, MAVLINK_MSG_ID_COMMAND_ACK_CRC);
 }
 
+/**
+ * @brief Pack a command_ack message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param command  Command ID (of acknowledged command).
+ * @param result  Result of command.
+ * @param progress [%] The progress percentage when result is MAV_RESULT_IN_PROGRESS. Values: [0-100], or UINT8_MAX if the progress is unknown.
+ * @param result_param2  Additional result information. Can be set with a command-specific enum containing command-specific error reasons for why the command might be denied. If used, the associated enum must be documented in the corresponding MAV_CMD (this enum should have a 0 value to indicate "unused" or "unknown").
+ * @param target_system  System ID of the target recipient. This is the ID of the system that sent the command for which this COMMAND_ACK is an acknowledgement.
+ * @param target_component  Component ID of the target recipient. This is the ID of the system that sent the command for which this COMMAND_ACK is an acknowledgement.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_command_ack_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint16_t command, uint8_t result, uint8_t progress, int32_t result_param2, uint8_t target_system, uint8_t target_component)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_COMMAND_ACK_LEN];
+    _mav_put_uint16_t(buf, 0, command);
+    _mav_put_uint8_t(buf, 2, result);
+    _mav_put_uint8_t(buf, 3, progress);
+    _mav_put_int32_t(buf, 4, result_param2);
+    _mav_put_uint8_t(buf, 8, target_system);
+    _mav_put_uint8_t(buf, 9, target_component);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_COMMAND_ACK_LEN);
+#else
+    mavlink_command_ack_t packet;
+    packet.command = command;
+    packet.result = result;
+    packet.progress = progress;
+    packet.result_param2 = result_param2;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_COMMAND_ACK_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_COMMAND_ACK;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMMAND_ACK_MIN_LEN, MAVLINK_MSG_ID_COMMAND_ACK_LEN, MAVLINK_MSG_ID_COMMAND_ACK_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMMAND_ACK_MIN_LEN, MAVLINK_MSG_ID_COMMAND_ACK_LEN);
+#endif
+}
+
 /**
  * @brief Pack a command_ack message on a channel
  * @param system_id ID of this system
@@ -164,6 +212,20 @@ static inline uint16_t mavlink_msg_command_ack_encode_chan(uint8_t system_id, ui
     return mavlink_msg_command_ack_pack_chan(system_id, component_id, chan, msg, command_ack->command, command_ack->result, command_ack->progress, command_ack->result_param2, command_ack->target_system, command_ack->target_component);
 }
 
+/**
+ * @brief Encode a command_ack struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param command_ack C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_command_ack_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_command_ack_t* command_ack)
+{
+    return mavlink_msg_command_ack_pack_status(system_id, component_id, _status, msg,  command_ack->command, command_ack->result, command_ack->progress, command_ack->result_param2, command_ack->target_system, command_ack->target_component);
+}
+
 /**
  * @brief Send a command_ack message
  * @param chan MAVLink channel to send the message

+ 53 - 0
v2.0/common/mavlink_msg_command_cancel.h

@@ -75,6 +75,45 @@ static inline uint16_t mavlink_msg_command_cancel_pack(uint8_t system_id, uint8_
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_COMMAND_CANCEL_MIN_LEN, MAVLINK_MSG_ID_COMMAND_CANCEL_LEN, MAVLINK_MSG_ID_COMMAND_CANCEL_CRC);
 }
 
+/**
+ * @brief Pack a command_cancel message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System executing long running command. Should not be broadcast (0).
+ * @param target_component  Component executing long running command.
+ * @param command  Command ID (of command to cancel).
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_command_cancel_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint16_t command)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_COMMAND_CANCEL_LEN];
+    _mav_put_uint16_t(buf, 0, command);
+    _mav_put_uint8_t(buf, 2, target_system);
+    _mav_put_uint8_t(buf, 3, target_component);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_COMMAND_CANCEL_LEN);
+#else
+    mavlink_command_cancel_t packet;
+    packet.command = command;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_COMMAND_CANCEL_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_COMMAND_CANCEL;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMMAND_CANCEL_MIN_LEN, MAVLINK_MSG_ID_COMMAND_CANCEL_LEN, MAVLINK_MSG_ID_COMMAND_CANCEL_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMMAND_CANCEL_MIN_LEN, MAVLINK_MSG_ID_COMMAND_CANCEL_LEN);
+#endif
+}
+
 /**
  * @brief Pack a command_cancel message on a channel
  * @param system_id ID of this system
@@ -137,6 +176,20 @@ static inline uint16_t mavlink_msg_command_cancel_encode_chan(uint8_t system_id,
     return mavlink_msg_command_cancel_pack_chan(system_id, component_id, chan, msg, command_cancel->target_system, command_cancel->target_component, command_cancel->command);
 }
 
+/**
+ * @brief Encode a command_cancel struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param command_cancel C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_command_cancel_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_command_cancel_t* command_cancel)
+{
+    return mavlink_msg_command_cancel_pack_status(system_id, component_id, _status, msg,  command_cancel->target_system, command_cancel->target_component, command_cancel->command);
+}
+
 /**
  * @brief Send a command_cancel message
  * @param chan MAVLink channel to send the message

+ 83 - 0
v2.0/common/mavlink_msg_command_int.h

@@ -135,6 +135,75 @@ static inline uint16_t mavlink_msg_command_int_pack(uint8_t system_id, uint8_t c
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_COMMAND_INT_MIN_LEN, MAVLINK_MSG_ID_COMMAND_INT_LEN, MAVLINK_MSG_ID_COMMAND_INT_CRC);
 }
 
+/**
+ * @brief Pack a command_int message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID
+ * @param target_component  Component ID
+ * @param frame  The coordinate system of the COMMAND.
+ * @param command  The scheduled action for the mission item.
+ * @param current  Not used.
+ * @param autocontinue  Not used (set 0).
+ * @param param1  PARAM1, see MAV_CMD enum
+ * @param param2  PARAM2, see MAV_CMD enum
+ * @param param3  PARAM3, see MAV_CMD enum
+ * @param param4  PARAM4, see MAV_CMD enum
+ * @param x  PARAM5 / local: x position in meters * 1e4, global: latitude in degrees * 10^7
+ * @param y  PARAM6 / local: y position in meters * 1e4, global: longitude in degrees * 10^7
+ * @param z  PARAM7 / z position: global: altitude in meters (relative or absolute, depending on frame).
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_command_int_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint8_t frame, uint16_t command, uint8_t current, uint8_t autocontinue, float param1, float param2, float param3, float param4, int32_t x, int32_t y, float z)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_COMMAND_INT_LEN];
+    _mav_put_float(buf, 0, param1);
+    _mav_put_float(buf, 4, param2);
+    _mav_put_float(buf, 8, param3);
+    _mav_put_float(buf, 12, param4);
+    _mav_put_int32_t(buf, 16, x);
+    _mav_put_int32_t(buf, 20, y);
+    _mav_put_float(buf, 24, z);
+    _mav_put_uint16_t(buf, 28, command);
+    _mav_put_uint8_t(buf, 30, target_system);
+    _mav_put_uint8_t(buf, 31, target_component);
+    _mav_put_uint8_t(buf, 32, frame);
+    _mav_put_uint8_t(buf, 33, current);
+    _mav_put_uint8_t(buf, 34, autocontinue);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_COMMAND_INT_LEN);
+#else
+    mavlink_command_int_t packet;
+    packet.param1 = param1;
+    packet.param2 = param2;
+    packet.param3 = param3;
+    packet.param4 = param4;
+    packet.x = x;
+    packet.y = y;
+    packet.z = z;
+    packet.command = command;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.frame = frame;
+    packet.current = current;
+    packet.autocontinue = autocontinue;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_COMMAND_INT_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_COMMAND_INT;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMMAND_INT_MIN_LEN, MAVLINK_MSG_ID_COMMAND_INT_LEN, MAVLINK_MSG_ID_COMMAND_INT_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMMAND_INT_MIN_LEN, MAVLINK_MSG_ID_COMMAND_INT_LEN);
+#endif
+}
+
 /**
  * @brief Pack a command_int message on a channel
  * @param system_id ID of this system
@@ -227,6 +296,20 @@ static inline uint16_t mavlink_msg_command_int_encode_chan(uint8_t system_id, ui
     return mavlink_msg_command_int_pack_chan(system_id, component_id, chan, msg, command_int->target_system, command_int->target_component, command_int->frame, command_int->command, command_int->current, command_int->autocontinue, command_int->param1, command_int->param2, command_int->param3, command_int->param4, command_int->x, command_int->y, command_int->z);
 }
 
+/**
+ * @brief Encode a command_int struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param command_int C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_command_int_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_command_int_t* command_int)
+{
+    return mavlink_msg_command_int_pack_status(system_id, component_id, _status, msg,  command_int->target_system, command_int->target_component, command_int->frame, command_int->command, command_int->current, command_int->autocontinue, command_int->param1, command_int->param2, command_int->param3, command_int->param4, command_int->x, command_int->y, command_int->z);
+}
+
 /**
  * @brief Send a command_int message
  * @param chan MAVLink channel to send the message

+ 77 - 0
v2.0/common/mavlink_msg_command_long.h

@@ -123,6 +123,69 @@ static inline uint16_t mavlink_msg_command_long_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_COMMAND_LONG_MIN_LEN, MAVLINK_MSG_ID_COMMAND_LONG_LEN, MAVLINK_MSG_ID_COMMAND_LONG_CRC);
 }
 
+/**
+ * @brief Pack a command_long message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System which should execute the command
+ * @param target_component  Component which should execute the command, 0 for all components
+ * @param command  Command ID (of command to send).
+ * @param confirmation  0: First transmission of this command. 1-255: Confirmation transmissions (e.g. for kill command)
+ * @param param1  Parameter 1 (for the specific command).
+ * @param param2  Parameter 2 (for the specific command).
+ * @param param3  Parameter 3 (for the specific command).
+ * @param param4  Parameter 4 (for the specific command).
+ * @param param5  Parameter 5 (for the specific command).
+ * @param param6  Parameter 6 (for the specific command).
+ * @param param7  Parameter 7 (for the specific command).
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_command_long_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint16_t command, uint8_t confirmation, float param1, float param2, float param3, float param4, float param5, float param6, float param7)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_COMMAND_LONG_LEN];
+    _mav_put_float(buf, 0, param1);
+    _mav_put_float(buf, 4, param2);
+    _mav_put_float(buf, 8, param3);
+    _mav_put_float(buf, 12, param4);
+    _mav_put_float(buf, 16, param5);
+    _mav_put_float(buf, 20, param6);
+    _mav_put_float(buf, 24, param7);
+    _mav_put_uint16_t(buf, 28, command);
+    _mav_put_uint8_t(buf, 30, target_system);
+    _mav_put_uint8_t(buf, 31, target_component);
+    _mav_put_uint8_t(buf, 32, confirmation);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_COMMAND_LONG_LEN);
+#else
+    mavlink_command_long_t packet;
+    packet.param1 = param1;
+    packet.param2 = param2;
+    packet.param3 = param3;
+    packet.param4 = param4;
+    packet.param5 = param5;
+    packet.param6 = param6;
+    packet.param7 = param7;
+    packet.command = command;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.confirmation = confirmation;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_COMMAND_LONG_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_COMMAND_LONG;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMMAND_LONG_MIN_LEN, MAVLINK_MSG_ID_COMMAND_LONG_LEN, MAVLINK_MSG_ID_COMMAND_LONG_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMMAND_LONG_MIN_LEN, MAVLINK_MSG_ID_COMMAND_LONG_LEN);
+#endif
+}
+
 /**
  * @brief Pack a command_long message on a channel
  * @param system_id ID of this system
@@ -209,6 +272,20 @@ static inline uint16_t mavlink_msg_command_long_encode_chan(uint8_t system_id, u
     return mavlink_msg_command_long_pack_chan(system_id, component_id, chan, msg, command_long->target_system, command_long->target_component, command_long->command, command_long->confirmation, command_long->param1, command_long->param2, command_long->param3, command_long->param4, command_long->param5, command_long->param6, command_long->param7);
 }
 
+/**
+ * @brief Encode a command_long struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param command_long C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_command_long_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_command_long_t* command_long)
+{
+    return mavlink_msg_command_long_pack_status(system_id, component_id, _status, msg,  command_long->target_system, command_long->target_component, command_long->command, command_long->confirmation, command_long->param1, command_long->param2, command_long->param3, command_long->param4, command_long->param5, command_long->param6, command_long->param7);
+}
+
 /**
  * @brief Send a command_long message
  * @param chan MAVLink channel to send the message

+ 57 - 0
v2.0/common/mavlink_msg_component_information.h

@@ -86,6 +86,49 @@ static inline uint16_t mavlink_msg_component_information_pack(uint8_t system_id,
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_COMPONENT_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_COMPONENT_INFORMATION_LEN, MAVLINK_MSG_ID_COMPONENT_INFORMATION_CRC);
 }
 
+/**
+ * @brief Pack a component_information message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param general_metadata_file_crc  CRC32 of the general metadata file (general_metadata_uri).
+ * @param general_metadata_uri  MAVLink FTP URI for the general metadata file (COMP_METADATA_TYPE_GENERAL), which may be compressed with xz. The file contains general component metadata, and may contain URI links for additional metadata (see COMP_METADATA_TYPE). The information is static from boot, and may be generated at compile time. The string needs to be zero terminated.
+ * @param peripherals_metadata_file_crc  CRC32 of peripherals metadata file (peripherals_metadata_uri).
+ * @param peripherals_metadata_uri  (Optional) MAVLink FTP URI for the peripherals metadata file (COMP_METADATA_TYPE_PERIPHERALS), which may be compressed with xz. This contains data about "attached components" such as UAVCAN nodes. The peripherals are in a separate file because the information must be generated dynamically at runtime. The string needs to be zero terminated.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_component_information_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint32_t general_metadata_file_crc, const char *general_metadata_uri, uint32_t peripherals_metadata_file_crc, const char *peripherals_metadata_uri)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_COMPONENT_INFORMATION_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_uint32_t(buf, 4, general_metadata_file_crc);
+    _mav_put_uint32_t(buf, 8, peripherals_metadata_file_crc);
+    _mav_put_char_array(buf, 12, general_metadata_uri, 100);
+    _mav_put_char_array(buf, 112, peripherals_metadata_uri, 100);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_COMPONENT_INFORMATION_LEN);
+#else
+    mavlink_component_information_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.general_metadata_file_crc = general_metadata_file_crc;
+    packet.peripherals_metadata_file_crc = peripherals_metadata_file_crc;
+    mav_array_memcpy(packet.general_metadata_uri, general_metadata_uri, sizeof(char)*100);
+    mav_array_memcpy(packet.peripherals_metadata_uri, peripherals_metadata_uri, sizeof(char)*100);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_COMPONENT_INFORMATION_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_COMPONENT_INFORMATION;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMPONENT_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_COMPONENT_INFORMATION_LEN, MAVLINK_MSG_ID_COMPONENT_INFORMATION_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMPONENT_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_COMPONENT_INFORMATION_LEN);
+#endif
+}
+
 /**
  * @brief Pack a component_information message on a channel
  * @param system_id ID of this system
@@ -152,6 +195,20 @@ static inline uint16_t mavlink_msg_component_information_encode_chan(uint8_t sys
     return mavlink_msg_component_information_pack_chan(system_id, component_id, chan, msg, component_information->time_boot_ms, component_information->general_metadata_file_crc, component_information->general_metadata_uri, component_information->peripherals_metadata_file_crc, component_information->peripherals_metadata_uri);
 }
 
+/**
+ * @brief Encode a component_information struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param component_information C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_component_information_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_component_information_t* component_information)
+{
+    return mavlink_msg_component_information_pack_status(system_id, component_id, _status, msg,  component_information->time_boot_ms, component_information->general_metadata_file_crc, component_information->general_metadata_uri, component_information->peripherals_metadata_file_crc, component_information->peripherals_metadata_uri);
+}
+
 /**
  * @brief Send a component_information message
  * @param chan MAVLink channel to send the message

+ 51 - 0
v2.0/common/mavlink_msg_component_metadata.h

@@ -73,6 +73,43 @@ static inline uint16_t mavlink_msg_component_metadata_pack(uint8_t system_id, ui
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_COMPONENT_METADATA_MIN_LEN, MAVLINK_MSG_ID_COMPONENT_METADATA_LEN, MAVLINK_MSG_ID_COMPONENT_METADATA_CRC);
 }
 
+/**
+ * @brief Pack a component_metadata message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param file_crc  CRC32 of the general metadata file.
+ * @param uri  MAVLink FTP URI for the general metadata file (COMP_METADATA_TYPE_GENERAL), which may be compressed with xz. The file contains general component metadata, and may contain URI links for additional metadata (see COMP_METADATA_TYPE). The information is static from boot, and may be generated at compile time. The string needs to be zero terminated.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_component_metadata_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint32_t file_crc, const char *uri)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_COMPONENT_METADATA_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_uint32_t(buf, 4, file_crc);
+    _mav_put_char_array(buf, 8, uri, 100);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_COMPONENT_METADATA_LEN);
+#else
+    mavlink_component_metadata_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.file_crc = file_crc;
+    mav_array_memcpy(packet.uri, uri, sizeof(char)*100);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_COMPONENT_METADATA_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_COMPONENT_METADATA;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMPONENT_METADATA_MIN_LEN, MAVLINK_MSG_ID_COMPONENT_METADATA_LEN, MAVLINK_MSG_ID_COMPONENT_METADATA_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_COMPONENT_METADATA_MIN_LEN, MAVLINK_MSG_ID_COMPONENT_METADATA_LEN);
+#endif
+}
+
 /**
  * @brief Pack a component_metadata message on a channel
  * @param system_id ID of this system
@@ -133,6 +170,20 @@ static inline uint16_t mavlink_msg_component_metadata_encode_chan(uint8_t system
     return mavlink_msg_component_metadata_pack_chan(system_id, component_id, chan, msg, component_metadata->time_boot_ms, component_metadata->file_crc, component_metadata->uri);
 }
 
+/**
+ * @brief Encode a component_metadata struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param component_metadata C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_component_metadata_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_component_metadata_t* component_metadata)
+{
+    return mavlink_msg_component_metadata_pack_status(system_id, component_id, _status, msg,  component_metadata->time_boot_ms, component_metadata->file_crc, component_metadata->uri);
+}
+
 /**
  * @brief Send a component_metadata message
  * @param chan MAVLink channel to send the message

+ 93 - 0
v2.0/common/mavlink_msg_control_system_state.h

@@ -159,6 +159,85 @@ static inline uint16_t mavlink_msg_control_system_state_pack(uint8_t system_id,
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_MIN_LEN, MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_LEN, MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_CRC);
 }
 
+/**
+ * @brief Pack a control_system_state message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param x_acc [m/s/s] X acceleration in body frame
+ * @param y_acc [m/s/s] Y acceleration in body frame
+ * @param z_acc [m/s/s] Z acceleration in body frame
+ * @param x_vel [m/s] X velocity in body frame
+ * @param y_vel [m/s] Y velocity in body frame
+ * @param z_vel [m/s] Z velocity in body frame
+ * @param x_pos [m] X position in local frame
+ * @param y_pos [m] Y position in local frame
+ * @param z_pos [m] Z position in local frame
+ * @param airspeed [m/s] Airspeed, set to -1 if unknown
+ * @param vel_variance  Variance of body velocity estimate
+ * @param pos_variance  Variance in local position
+ * @param q  The attitude, represented as Quaternion
+ * @param roll_rate [rad/s] Angular rate in roll axis
+ * @param pitch_rate [rad/s] Angular rate in pitch axis
+ * @param yaw_rate [rad/s] Angular rate in yaw axis
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_control_system_state_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, float x_acc, float y_acc, float z_acc, float x_vel, float y_vel, float z_vel, float x_pos, float y_pos, float z_pos, float airspeed, const float *vel_variance, const float *pos_variance, const float *q, float roll_rate, float pitch_rate, float yaw_rate)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 8, x_acc);
+    _mav_put_float(buf, 12, y_acc);
+    _mav_put_float(buf, 16, z_acc);
+    _mav_put_float(buf, 20, x_vel);
+    _mav_put_float(buf, 24, y_vel);
+    _mav_put_float(buf, 28, z_vel);
+    _mav_put_float(buf, 32, x_pos);
+    _mav_put_float(buf, 36, y_pos);
+    _mav_put_float(buf, 40, z_pos);
+    _mav_put_float(buf, 44, airspeed);
+    _mav_put_float(buf, 88, roll_rate);
+    _mav_put_float(buf, 92, pitch_rate);
+    _mav_put_float(buf, 96, yaw_rate);
+    _mav_put_float_array(buf, 48, vel_variance, 3);
+    _mav_put_float_array(buf, 60, pos_variance, 3);
+    _mav_put_float_array(buf, 72, q, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_LEN);
+#else
+    mavlink_control_system_state_t packet;
+    packet.time_usec = time_usec;
+    packet.x_acc = x_acc;
+    packet.y_acc = y_acc;
+    packet.z_acc = z_acc;
+    packet.x_vel = x_vel;
+    packet.y_vel = y_vel;
+    packet.z_vel = z_vel;
+    packet.x_pos = x_pos;
+    packet.y_pos = y_pos;
+    packet.z_pos = z_pos;
+    packet.airspeed = airspeed;
+    packet.roll_rate = roll_rate;
+    packet.pitch_rate = pitch_rate;
+    packet.yaw_rate = yaw_rate;
+    mav_array_memcpy(packet.vel_variance, vel_variance, sizeof(float)*3);
+    mav_array_memcpy(packet.pos_variance, pos_variance, sizeof(float)*3);
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_MIN_LEN, MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_LEN, MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_MIN_LEN, MAVLINK_MSG_ID_CONTROL_SYSTEM_STATE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a control_system_state message on a channel
  * @param system_id ID of this system
@@ -261,6 +340,20 @@ static inline uint16_t mavlink_msg_control_system_state_encode_chan(uint8_t syst
     return mavlink_msg_control_system_state_pack_chan(system_id, component_id, chan, msg, control_system_state->time_usec, control_system_state->x_acc, control_system_state->y_acc, control_system_state->z_acc, control_system_state->x_vel, control_system_state->y_vel, control_system_state->z_vel, control_system_state->x_pos, control_system_state->y_pos, control_system_state->z_pos, control_system_state->airspeed, control_system_state->vel_variance, control_system_state->pos_variance, control_system_state->q, control_system_state->roll_rate, control_system_state->pitch_rate, control_system_state->yaw_rate);
 }
 
+/**
+ * @brief Encode a control_system_state struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param control_system_state C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_control_system_state_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_control_system_state_t* control_system_state)
+{
+    return mavlink_msg_control_system_state_pack_status(system_id, component_id, _status, msg,  control_system_state->time_usec, control_system_state->x_acc, control_system_state->y_acc, control_system_state->z_acc, control_system_state->x_vel, control_system_state->y_vel, control_system_state->z_vel, control_system_state->x_pos, control_system_state->y_pos, control_system_state->z_pos, control_system_state->airspeed, control_system_state->vel_variance, control_system_state->pos_variance, control_system_state->q, control_system_state->roll_rate, control_system_state->pitch_rate, control_system_state->yaw_rate);
+}
+
 /**
  * @brief Send a control_system_state message
  * @param chan MAVLink channel to send the message

+ 50 - 0
v2.0/common/mavlink_msg_current_event_sequence.h

@@ -69,6 +69,42 @@ static inline uint16_t mavlink_msg_current_event_sequence_pack(uint8_t system_id
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_MIN_LEN, MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_LEN, MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_CRC);
 }
 
+/**
+ * @brief Pack a current_event_sequence message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param sequence  Sequence number.
+ * @param flags  Flag bitset.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_current_event_sequence_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint16_t sequence, uint8_t flags)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_LEN];
+    _mav_put_uint16_t(buf, 0, sequence);
+    _mav_put_uint8_t(buf, 2, flags);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_LEN);
+#else
+    mavlink_current_event_sequence_t packet;
+    packet.sequence = sequence;
+    packet.flags = flags;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_MIN_LEN, MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_LEN, MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_MIN_LEN, MAVLINK_MSG_ID_CURRENT_EVENT_SEQUENCE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a current_event_sequence message on a channel
  * @param system_id ID of this system
@@ -128,6 +164,20 @@ static inline uint16_t mavlink_msg_current_event_sequence_encode_chan(uint8_t sy
     return mavlink_msg_current_event_sequence_pack_chan(system_id, component_id, chan, msg, current_event_sequence->sequence, current_event_sequence->flags);
 }
 
+/**
+ * @brief Encode a current_event_sequence struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param current_event_sequence C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_current_event_sequence_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_current_event_sequence_t* current_event_sequence)
+{
+    return mavlink_msg_current_event_sequence_pack_status(system_id, component_id, _status, msg,  current_event_sequence->sequence, current_event_sequence->flags);
+}
+
 /**
  * @brief Send a current_event_sequence message
  * @param chan MAVLink channel to send the message

+ 53 - 0
v2.0/common/mavlink_msg_data_stream.h

@@ -75,6 +75,45 @@ static inline uint16_t mavlink_msg_data_stream_pack(uint8_t system_id, uint8_t c
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_DATA_STREAM_MIN_LEN, MAVLINK_MSG_ID_DATA_STREAM_LEN, MAVLINK_MSG_ID_DATA_STREAM_CRC);
 }
 
+/**
+ * @brief Pack a data_stream message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param stream_id  The ID of the requested data stream
+ * @param message_rate [Hz] The message rate
+ * @param on_off  1 stream is enabled, 0 stream is stopped.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_data_stream_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t stream_id, uint16_t message_rate, uint8_t on_off)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_DATA_STREAM_LEN];
+    _mav_put_uint16_t(buf, 0, message_rate);
+    _mav_put_uint8_t(buf, 2, stream_id);
+    _mav_put_uint8_t(buf, 3, on_off);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_DATA_STREAM_LEN);
+#else
+    mavlink_data_stream_t packet;
+    packet.message_rate = message_rate;
+    packet.stream_id = stream_id;
+    packet.on_off = on_off;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_DATA_STREAM_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_DATA_STREAM;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DATA_STREAM_MIN_LEN, MAVLINK_MSG_ID_DATA_STREAM_LEN, MAVLINK_MSG_ID_DATA_STREAM_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DATA_STREAM_MIN_LEN, MAVLINK_MSG_ID_DATA_STREAM_LEN);
+#endif
+}
+
 /**
  * @brief Pack a data_stream message on a channel
  * @param system_id ID of this system
@@ -137,6 +176,20 @@ static inline uint16_t mavlink_msg_data_stream_encode_chan(uint8_t system_id, ui
     return mavlink_msg_data_stream_pack_chan(system_id, component_id, chan, msg, data_stream->stream_id, data_stream->message_rate, data_stream->on_off);
 }
 
+/**
+ * @brief Encode a data_stream struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param data_stream C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_data_stream_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_data_stream_t* data_stream)
+{
+    return mavlink_msg_data_stream_pack_status(system_id, component_id, _status, msg,  data_stream->stream_id, data_stream->message_rate, data_stream->on_off);
+}
+
 /**
  * @brief Send a data_stream message
  * @param chan MAVLink channel to send the message

+ 65 - 0
v2.0/common/mavlink_msg_data_transmission_handshake.h

@@ -99,6 +99,57 @@ static inline uint16_t mavlink_msg_data_transmission_handshake_pack(uint8_t syst
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_MIN_LEN, MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN, MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_CRC);
 }
 
+/**
+ * @brief Pack a data_transmission_handshake message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param type  Type of requested/acknowledged data.
+ * @param size [bytes] total data size (set on ACK only).
+ * @param width  Width of a matrix or image.
+ * @param height  Height of a matrix or image.
+ * @param packets  Number of packets being sent (set on ACK only).
+ * @param payload [bytes] Payload size per packet (normally 253 byte, see DATA field size in message ENCAPSULATED_DATA) (set on ACK only).
+ * @param jpg_quality [%] JPEG quality. Values: [1-100].
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_data_transmission_handshake_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t type, uint32_t size, uint16_t width, uint16_t height, uint16_t packets, uint8_t payload, uint8_t jpg_quality)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN];
+    _mav_put_uint32_t(buf, 0, size);
+    _mav_put_uint16_t(buf, 4, width);
+    _mav_put_uint16_t(buf, 6, height);
+    _mav_put_uint16_t(buf, 8, packets);
+    _mav_put_uint8_t(buf, 10, type);
+    _mav_put_uint8_t(buf, 11, payload);
+    _mav_put_uint8_t(buf, 12, jpg_quality);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN);
+#else
+    mavlink_data_transmission_handshake_t packet;
+    packet.size = size;
+    packet.width = width;
+    packet.height = height;
+    packet.packets = packets;
+    packet.type = type;
+    packet.payload = payload;
+    packet.jpg_quality = jpg_quality;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_MIN_LEN, MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN, MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_MIN_LEN, MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a data_transmission_handshake message on a channel
  * @param system_id ID of this system
@@ -173,6 +224,20 @@ static inline uint16_t mavlink_msg_data_transmission_handshake_encode_chan(uint8
     return mavlink_msg_data_transmission_handshake_pack_chan(system_id, component_id, chan, msg, data_transmission_handshake->type, data_transmission_handshake->size, data_transmission_handshake->width, data_transmission_handshake->height, data_transmission_handshake->packets, data_transmission_handshake->payload, data_transmission_handshake->jpg_quality);
 }
 
+/**
+ * @brief Encode a data_transmission_handshake struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param data_transmission_handshake C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_data_transmission_handshake_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_data_transmission_handshake_t* data_transmission_handshake)
+{
+    return mavlink_msg_data_transmission_handshake_pack_status(system_id, component_id, _status, msg,  data_transmission_handshake->type, data_transmission_handshake->size, data_transmission_handshake->width, data_transmission_handshake->height, data_transmission_handshake->packets, data_transmission_handshake->payload, data_transmission_handshake->jpg_quality);
+}
+
 /**
  * @brief Send a data_transmission_handshake message
  * @param chan MAVLink channel to send the message

+ 53 - 0
v2.0/common/mavlink_msg_debug.h

@@ -75,6 +75,45 @@ static inline uint16_t mavlink_msg_debug_pack(uint8_t system_id, uint8_t compone
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_DEBUG_MIN_LEN, MAVLINK_MSG_ID_DEBUG_LEN, MAVLINK_MSG_ID_DEBUG_CRC);
 }
 
+/**
+ * @brief Pack a debug message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param ind  index of debug variable
+ * @param value  DEBUG value
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_debug_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint8_t ind, float value)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_DEBUG_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_float(buf, 4, value);
+    _mav_put_uint8_t(buf, 8, ind);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_DEBUG_LEN);
+#else
+    mavlink_debug_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.value = value;
+    packet.ind = ind;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_DEBUG_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_DEBUG;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DEBUG_MIN_LEN, MAVLINK_MSG_ID_DEBUG_LEN, MAVLINK_MSG_ID_DEBUG_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DEBUG_MIN_LEN, MAVLINK_MSG_ID_DEBUG_LEN);
+#endif
+}
+
 /**
  * @brief Pack a debug message on a channel
  * @param system_id ID of this system
@@ -137,6 +176,20 @@ static inline uint16_t mavlink_msg_debug_encode_chan(uint8_t system_id, uint8_t
     return mavlink_msg_debug_pack_chan(system_id, component_id, chan, msg, debug->time_boot_ms, debug->ind, debug->value);
 }
 
+/**
+ * @brief Encode a debug struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param debug C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_debug_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_debug_t* debug)
+{
+    return mavlink_msg_debug_pack_status(system_id, component_id, _status, msg,  debug->time_boot_ms, debug->ind, debug->value);
+}
+
 /**
  * @brief Send a debug message
  * @param chan MAVLink channel to send the message

+ 54 - 0
v2.0/common/mavlink_msg_debug_float_array.h

@@ -80,6 +80,46 @@ static inline uint16_t mavlink_msg_debug_float_array_pack(uint8_t system_id, uin
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_MIN_LEN, MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_LEN, MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_CRC);
 }
 
+/**
+ * @brief Pack a debug_float_array message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param name  Name, for human-friendly display in a Ground Control Station
+ * @param array_id  Unique ID used to discriminate between arrays
+ * @param data  data
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_debug_float_array_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, const char *name, uint16_t array_id, const float *data)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_uint16_t(buf, 8, array_id);
+    _mav_put_char_array(buf, 10, name, 10);
+    _mav_put_float_array(buf, 20, data, 58);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_LEN);
+#else
+    mavlink_debug_float_array_t packet;
+    packet.time_usec = time_usec;
+    packet.array_id = array_id;
+    mav_array_memcpy(packet.name, name, sizeof(char)*10);
+    mav_array_memcpy(packet.data, data, sizeof(float)*58);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_MIN_LEN, MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_LEN, MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_MIN_LEN, MAVLINK_MSG_ID_DEBUG_FLOAT_ARRAY_LEN);
+#endif
+}
+
 /**
  * @brief Pack a debug_float_array message on a channel
  * @param system_id ID of this system
@@ -143,6 +183,20 @@ static inline uint16_t mavlink_msg_debug_float_array_encode_chan(uint8_t system_
     return mavlink_msg_debug_float_array_pack_chan(system_id, component_id, chan, msg, debug_float_array->time_usec, debug_float_array->name, debug_float_array->array_id, debug_float_array->data);
 }
 
+/**
+ * @brief Encode a debug_float_array struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param debug_float_array C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_debug_float_array_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_debug_float_array_t* debug_float_array)
+{
+    return mavlink_msg_debug_float_array_pack_status(system_id, component_id, _status, msg,  debug_float_array->time_usec, debug_float_array->name, debug_float_array->array_id, debug_float_array->data);
+}
+
 /**
  * @brief Send a debug_float_array message
  * @param chan MAVLink channel to send the message

+ 57 - 0
v2.0/common/mavlink_msg_debug_vect.h

@@ -85,6 +85,49 @@ static inline uint16_t mavlink_msg_debug_vect_pack(uint8_t system_id, uint8_t co
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_DEBUG_VECT_MIN_LEN, MAVLINK_MSG_ID_DEBUG_VECT_LEN, MAVLINK_MSG_ID_DEBUG_VECT_CRC);
 }
 
+/**
+ * @brief Pack a debug_vect message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param name  Name
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param x  x
+ * @param y  y
+ * @param z  z
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_debug_vect_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               const char *name, uint64_t time_usec, float x, float y, float z)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_DEBUG_VECT_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 8, x);
+    _mav_put_float(buf, 12, y);
+    _mav_put_float(buf, 16, z);
+    _mav_put_char_array(buf, 20, name, 10);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_DEBUG_VECT_LEN);
+#else
+    mavlink_debug_vect_t packet;
+    packet.time_usec = time_usec;
+    packet.x = x;
+    packet.y = y;
+    packet.z = z;
+    mav_array_memcpy(packet.name, name, sizeof(char)*10);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_DEBUG_VECT_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_DEBUG_VECT;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DEBUG_VECT_MIN_LEN, MAVLINK_MSG_ID_DEBUG_VECT_LEN, MAVLINK_MSG_ID_DEBUG_VECT_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DEBUG_VECT_MIN_LEN, MAVLINK_MSG_ID_DEBUG_VECT_LEN);
+#endif
+}
+
 /**
  * @brief Pack a debug_vect message on a channel
  * @param system_id ID of this system
@@ -151,6 +194,20 @@ static inline uint16_t mavlink_msg_debug_vect_encode_chan(uint8_t system_id, uin
     return mavlink_msg_debug_vect_pack_chan(system_id, component_id, chan, msg, debug_vect->name, debug_vect->time_usec, debug_vect->x, debug_vect->y, debug_vect->z);
 }
 
+/**
+ * @brief Encode a debug_vect struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param debug_vect C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_debug_vect_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_debug_vect_t* debug_vect)
+{
+    return mavlink_msg_debug_vect_pack_status(system_id, component_id, _status, msg,  debug_vect->name, debug_vect->time_usec, debug_vect->x, debug_vect->y, debug_vect->z);
+}
+
 /**
  * @brief Send a debug_vect message
  * @param chan MAVLink channel to send the message

+ 78 - 0
v2.0/common/mavlink_msg_distance_sensor.h

@@ -127,6 +127,70 @@ static inline uint16_t mavlink_msg_distance_sensor_pack(uint8_t system_id, uint8
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_DISTANCE_SENSOR_MIN_LEN, MAVLINK_MSG_ID_DISTANCE_SENSOR_LEN, MAVLINK_MSG_ID_DISTANCE_SENSOR_CRC);
 }
 
+/**
+ * @brief Pack a distance_sensor message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param min_distance [cm] Minimum distance the sensor can measure
+ * @param max_distance [cm] Maximum distance the sensor can measure
+ * @param current_distance [cm] Current distance reading
+ * @param type  Type of distance sensor.
+ * @param id  Onboard ID of the sensor
+ * @param orientation  Direction the sensor faces. downward-facing: ROTATION_PITCH_270, upward-facing: ROTATION_PITCH_90, backward-facing: ROTATION_PITCH_180, forward-facing: ROTATION_NONE, left-facing: ROTATION_YAW_90, right-facing: ROTATION_YAW_270
+ * @param covariance [cm^2] Measurement variance. Max standard deviation is 6cm. UINT8_MAX if unknown.
+ * @param horizontal_fov [rad] Horizontal Field of View (angle) where the distance measurement is valid and the field of view is known. Otherwise this is set to 0.
+ * @param vertical_fov [rad] Vertical Field of View (angle) where the distance measurement is valid and the field of view is known. Otherwise this is set to 0.
+ * @param quaternion  Quaternion of the sensor orientation in vehicle body frame (w, x, y, z order, zero-rotation is 1, 0, 0, 0). Zero-rotation is along the vehicle body x-axis. This field is required if the orientation is set to MAV_SENSOR_ROTATION_CUSTOM. Set it to 0 if invalid."
+ * @param signal_quality [%] Signal quality of the sensor. Specific to each sensor type, representing the relation of the signal strength with the target reflectivity, distance, size or aspect, but normalised as a percentage. 0 = unknown/unset signal quality, 1 = invalid signal, 100 = perfect signal.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_distance_sensor_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint16_t min_distance, uint16_t max_distance, uint16_t current_distance, uint8_t type, uint8_t id, uint8_t orientation, uint8_t covariance, float horizontal_fov, float vertical_fov, const float *quaternion, uint8_t signal_quality)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_DISTANCE_SENSOR_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_uint16_t(buf, 4, min_distance);
+    _mav_put_uint16_t(buf, 6, max_distance);
+    _mav_put_uint16_t(buf, 8, current_distance);
+    _mav_put_uint8_t(buf, 10, type);
+    _mav_put_uint8_t(buf, 11, id);
+    _mav_put_uint8_t(buf, 12, orientation);
+    _mav_put_uint8_t(buf, 13, covariance);
+    _mav_put_float(buf, 14, horizontal_fov);
+    _mav_put_float(buf, 18, vertical_fov);
+    _mav_put_uint8_t(buf, 38, signal_quality);
+    _mav_put_float_array(buf, 22, quaternion, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_DISTANCE_SENSOR_LEN);
+#else
+    mavlink_distance_sensor_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.min_distance = min_distance;
+    packet.max_distance = max_distance;
+    packet.current_distance = current_distance;
+    packet.type = type;
+    packet.id = id;
+    packet.orientation = orientation;
+    packet.covariance = covariance;
+    packet.horizontal_fov = horizontal_fov;
+    packet.vertical_fov = vertical_fov;
+    packet.signal_quality = signal_quality;
+    mav_array_memcpy(packet.quaternion, quaternion, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_DISTANCE_SENSOR_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_DISTANCE_SENSOR;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DISTANCE_SENSOR_MIN_LEN, MAVLINK_MSG_ID_DISTANCE_SENSOR_LEN, MAVLINK_MSG_ID_DISTANCE_SENSOR_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_DISTANCE_SENSOR_MIN_LEN, MAVLINK_MSG_ID_DISTANCE_SENSOR_LEN);
+#endif
+}
+
 /**
  * @brief Pack a distance_sensor message on a channel
  * @param system_id ID of this system
@@ -214,6 +278,20 @@ static inline uint16_t mavlink_msg_distance_sensor_encode_chan(uint8_t system_id
     return mavlink_msg_distance_sensor_pack_chan(system_id, component_id, chan, msg, distance_sensor->time_boot_ms, distance_sensor->min_distance, distance_sensor->max_distance, distance_sensor->current_distance, distance_sensor->type, distance_sensor->id, distance_sensor->orientation, distance_sensor->covariance, distance_sensor->horizontal_fov, distance_sensor->vertical_fov, distance_sensor->quaternion, distance_sensor->signal_quality);
 }
 
+/**
+ * @brief Encode a distance_sensor struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param distance_sensor C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_distance_sensor_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_distance_sensor_t* distance_sensor)
+{
+    return mavlink_msg_distance_sensor_pack_status(system_id, component_id, _status, msg,  distance_sensor->time_boot_ms, distance_sensor->min_distance, distance_sensor->max_distance, distance_sensor->current_distance, distance_sensor->type, distance_sensor->id, distance_sensor->orientation, distance_sensor->covariance, distance_sensor->horizontal_fov, distance_sensor->vertical_fov, distance_sensor->quaternion, distance_sensor->signal_quality);
+}
+
 /**
  * @brief Send a distance_sensor message
  * @param chan MAVLink channel to send the message

+ 101 - 0
v2.0/common/mavlink_msg_efi_status.h

@@ -171,6 +171,93 @@ static inline uint16_t mavlink_msg_efi_status_pack(uint8_t system_id, uint8_t co
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_EFI_STATUS_MIN_LEN, MAVLINK_MSG_ID_EFI_STATUS_LEN, MAVLINK_MSG_ID_EFI_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a efi_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param health  EFI health status
+ * @param ecu_index  ECU index
+ * @param rpm  RPM
+ * @param fuel_consumed [cm^3] Fuel consumed
+ * @param fuel_flow [cm^3/min] Fuel flow rate
+ * @param engine_load [%] Engine load
+ * @param throttle_position [%] Throttle position
+ * @param spark_dwell_time [ms] Spark dwell time
+ * @param barometric_pressure [kPa] Barometric pressure
+ * @param intake_manifold_pressure [kPa] Intake manifold pressure(
+ * @param intake_manifold_temperature [degC] Intake manifold temperature
+ * @param cylinder_head_temperature [degC] Cylinder head temperature
+ * @param ignition_timing [deg] Ignition timing (Crank angle degrees)
+ * @param injection_time [ms] Injection time
+ * @param exhaust_gas_temperature [degC] Exhaust gas temperature
+ * @param throttle_out [%] Output throttle
+ * @param pt_compensation  Pressure/temperature compensation
+ * @param ignition_voltage [V] Supply voltage to EFI sparking system.  Zero in this value means "unknown", so if the supply voltage really is zero volts use 0.0001 instead.
+ * @param fuel_pressure [kPa] Fuel pressure. Zero in this value means "unknown", so if the fuel pressure really is zero kPa use 0.0001 instead.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_efi_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t health, float ecu_index, float rpm, float fuel_consumed, float fuel_flow, float engine_load, float throttle_position, float spark_dwell_time, float barometric_pressure, float intake_manifold_pressure, float intake_manifold_temperature, float cylinder_head_temperature, float ignition_timing, float injection_time, float exhaust_gas_temperature, float throttle_out, float pt_compensation, float ignition_voltage, float fuel_pressure)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_EFI_STATUS_LEN];
+    _mav_put_float(buf, 0, ecu_index);
+    _mav_put_float(buf, 4, rpm);
+    _mav_put_float(buf, 8, fuel_consumed);
+    _mav_put_float(buf, 12, fuel_flow);
+    _mav_put_float(buf, 16, engine_load);
+    _mav_put_float(buf, 20, throttle_position);
+    _mav_put_float(buf, 24, spark_dwell_time);
+    _mav_put_float(buf, 28, barometric_pressure);
+    _mav_put_float(buf, 32, intake_manifold_pressure);
+    _mav_put_float(buf, 36, intake_manifold_temperature);
+    _mav_put_float(buf, 40, cylinder_head_temperature);
+    _mav_put_float(buf, 44, ignition_timing);
+    _mav_put_float(buf, 48, injection_time);
+    _mav_put_float(buf, 52, exhaust_gas_temperature);
+    _mav_put_float(buf, 56, throttle_out);
+    _mav_put_float(buf, 60, pt_compensation);
+    _mav_put_uint8_t(buf, 64, health);
+    _mav_put_float(buf, 65, ignition_voltage);
+    _mav_put_float(buf, 69, fuel_pressure);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_EFI_STATUS_LEN);
+#else
+    mavlink_efi_status_t packet;
+    packet.ecu_index = ecu_index;
+    packet.rpm = rpm;
+    packet.fuel_consumed = fuel_consumed;
+    packet.fuel_flow = fuel_flow;
+    packet.engine_load = engine_load;
+    packet.throttle_position = throttle_position;
+    packet.spark_dwell_time = spark_dwell_time;
+    packet.barometric_pressure = barometric_pressure;
+    packet.intake_manifold_pressure = intake_manifold_pressure;
+    packet.intake_manifold_temperature = intake_manifold_temperature;
+    packet.cylinder_head_temperature = cylinder_head_temperature;
+    packet.ignition_timing = ignition_timing;
+    packet.injection_time = injection_time;
+    packet.exhaust_gas_temperature = exhaust_gas_temperature;
+    packet.throttle_out = throttle_out;
+    packet.pt_compensation = pt_compensation;
+    packet.health = health;
+    packet.ignition_voltage = ignition_voltage;
+    packet.fuel_pressure = fuel_pressure;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_EFI_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_EFI_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_EFI_STATUS_MIN_LEN, MAVLINK_MSG_ID_EFI_STATUS_LEN, MAVLINK_MSG_ID_EFI_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_EFI_STATUS_MIN_LEN, MAVLINK_MSG_ID_EFI_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a efi_status message on a channel
  * @param system_id ID of this system
@@ -281,6 +368,20 @@ static inline uint16_t mavlink_msg_efi_status_encode_chan(uint8_t system_id, uin
     return mavlink_msg_efi_status_pack_chan(system_id, component_id, chan, msg, efi_status->health, efi_status->ecu_index, efi_status->rpm, efi_status->fuel_consumed, efi_status->fuel_flow, efi_status->engine_load, efi_status->throttle_position, efi_status->spark_dwell_time, efi_status->barometric_pressure, efi_status->intake_manifold_pressure, efi_status->intake_manifold_temperature, efi_status->cylinder_head_temperature, efi_status->ignition_timing, efi_status->injection_time, efi_status->exhaust_gas_temperature, efi_status->throttle_out, efi_status->pt_compensation, efi_status->ignition_voltage, efi_status->fuel_pressure);
 }
 
+/**
+ * @brief Encode a efi_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param efi_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_efi_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_efi_status_t* efi_status)
+{
+    return mavlink_msg_efi_status_pack_status(system_id, component_id, _status, msg,  efi_status->health, efi_status->ecu_index, efi_status->rpm, efi_status->fuel_consumed, efi_status->fuel_flow, efi_status->engine_load, efi_status->throttle_position, efi_status->spark_dwell_time, efi_status->barometric_pressure, efi_status->intake_manifold_pressure, efi_status->intake_manifold_temperature, efi_status->cylinder_head_temperature, efi_status->ignition_timing, efi_status->injection_time, efi_status->exhaust_gas_temperature, efi_status->throttle_out, efi_status->pt_compensation, efi_status->ignition_voltage, efi_status->fuel_pressure);
+}
+
 /**
  * @brief Send a efi_status message
  * @param chan MAVLink channel to send the message

+ 48 - 0
v2.0/common/mavlink_msg_encapsulated_data.h

@@ -67,6 +67,40 @@ static inline uint16_t mavlink_msg_encapsulated_data_pack(uint8_t system_id, uin
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ENCAPSULATED_DATA_MIN_LEN, MAVLINK_MSG_ID_ENCAPSULATED_DATA_LEN, MAVLINK_MSG_ID_ENCAPSULATED_DATA_CRC);
 }
 
+/**
+ * @brief Pack a encapsulated_data message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param seqnr  sequence number (starting with 0 on every transmission)
+ * @param data  image data bytes
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_encapsulated_data_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint16_t seqnr, const uint8_t *data)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ENCAPSULATED_DATA_LEN];
+    _mav_put_uint16_t(buf, 0, seqnr);
+    _mav_put_uint8_t_array(buf, 2, data, 253);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ENCAPSULATED_DATA_LEN);
+#else
+    mavlink_encapsulated_data_t packet;
+    packet.seqnr = seqnr;
+    mav_array_memcpy(packet.data, data, sizeof(uint8_t)*253);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ENCAPSULATED_DATA_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ENCAPSULATED_DATA;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ENCAPSULATED_DATA_MIN_LEN, MAVLINK_MSG_ID_ENCAPSULATED_DATA_LEN, MAVLINK_MSG_ID_ENCAPSULATED_DATA_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ENCAPSULATED_DATA_MIN_LEN, MAVLINK_MSG_ID_ENCAPSULATED_DATA_LEN);
+#endif
+}
+
 /**
  * @brief Pack a encapsulated_data message on a channel
  * @param system_id ID of this system
@@ -124,6 +158,20 @@ static inline uint16_t mavlink_msg_encapsulated_data_encode_chan(uint8_t system_
     return mavlink_msg_encapsulated_data_pack_chan(system_id, component_id, chan, msg, encapsulated_data->seqnr, encapsulated_data->data);
 }
 
+/**
+ * @brief Encode a encapsulated_data struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param encapsulated_data C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_encapsulated_data_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_encapsulated_data_t* encapsulated_data)
+{
+    return mavlink_msg_encapsulated_data_pack_status(system_id, component_id, _status, msg,  encapsulated_data->seqnr, encapsulated_data->data);
+}
+
 /**
  * @brief Send a encapsulated_data message
  * @param chan MAVLink channel to send the message

+ 69 - 0
v2.0/common/mavlink_msg_esc_info.h

@@ -111,6 +111,61 @@ static inline uint16_t mavlink_msg_esc_info_pack(uint8_t system_id, uint8_t comp
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ESC_INFO_MIN_LEN, MAVLINK_MSG_ID_ESC_INFO_LEN, MAVLINK_MSG_ID_ESC_INFO_CRC);
 }
 
+/**
+ * @brief Pack a esc_info message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param index  Index of the first ESC in this message. minValue = 0, maxValue = 60, increment = 4.
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude the number.
+ * @param counter  Counter of data packets received.
+ * @param count  Total number of ESCs in all messages of this type. Message fields with an index higher than this should be ignored because they contain invalid data.
+ * @param connection_type  Connection type protocol for all ESC.
+ * @param info  Information regarding online/offline status of each ESC.
+ * @param failure_flags  Bitmap of ESC failure flags.
+ * @param error_count  Number of reported errors by each ESC since boot.
+ * @param temperature [cdegC] Temperature of each ESC. INT16_MAX: if data not supplied by ESC.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_esc_info_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t index, uint64_t time_usec, uint16_t counter, uint8_t count, uint8_t connection_type, uint8_t info, const uint16_t *failure_flags, const uint32_t *error_count, const int16_t *temperature)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ESC_INFO_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_uint16_t(buf, 24, counter);
+    _mav_put_uint8_t(buf, 42, index);
+    _mav_put_uint8_t(buf, 43, count);
+    _mav_put_uint8_t(buf, 44, connection_type);
+    _mav_put_uint8_t(buf, 45, info);
+    _mav_put_uint32_t_array(buf, 8, error_count, 4);
+    _mav_put_uint16_t_array(buf, 26, failure_flags, 4);
+    _mav_put_int16_t_array(buf, 34, temperature, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ESC_INFO_LEN);
+#else
+    mavlink_esc_info_t packet;
+    packet.time_usec = time_usec;
+    packet.counter = counter;
+    packet.index = index;
+    packet.count = count;
+    packet.connection_type = connection_type;
+    packet.info = info;
+    mav_array_memcpy(packet.error_count, error_count, sizeof(uint32_t)*4);
+    mav_array_memcpy(packet.failure_flags, failure_flags, sizeof(uint16_t)*4);
+    mav_array_memcpy(packet.temperature, temperature, sizeof(int16_t)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ESC_INFO_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ESC_INFO;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ESC_INFO_MIN_LEN, MAVLINK_MSG_ID_ESC_INFO_LEN, MAVLINK_MSG_ID_ESC_INFO_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ESC_INFO_MIN_LEN, MAVLINK_MSG_ID_ESC_INFO_LEN);
+#endif
+}
+
 /**
  * @brief Pack a esc_info message on a channel
  * @param system_id ID of this system
@@ -189,6 +244,20 @@ static inline uint16_t mavlink_msg_esc_info_encode_chan(uint8_t system_id, uint8
     return mavlink_msg_esc_info_pack_chan(system_id, component_id, chan, msg, esc_info->index, esc_info->time_usec, esc_info->counter, esc_info->count, esc_info->connection_type, esc_info->info, esc_info->failure_flags, esc_info->error_count, esc_info->temperature);
 }
 
+/**
+ * @brief Encode a esc_info struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param esc_info C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_esc_info_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_esc_info_t* esc_info)
+{
+    return mavlink_msg_esc_info_pack_status(system_id, component_id, _status, msg,  esc_info->index, esc_info->time_usec, esc_info->counter, esc_info->count, esc_info->connection_type, esc_info->info, esc_info->failure_flags, esc_info->error_count, esc_info->temperature);
+}
+
 /**
  * @brief Send a esc_info message
  * @param chan MAVLink channel to send the message

+ 57 - 0
v2.0/common/mavlink_msg_esc_status.h

@@ -87,6 +87,49 @@ static inline uint16_t mavlink_msg_esc_status_pack(uint8_t system_id, uint8_t co
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ESC_STATUS_MIN_LEN, MAVLINK_MSG_ID_ESC_STATUS_LEN, MAVLINK_MSG_ID_ESC_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a esc_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param index  Index of the first ESC in this message. minValue = 0, maxValue = 60, increment = 4.
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude the number.
+ * @param rpm [rpm] Reported motor RPM from each ESC (negative for reverse rotation).
+ * @param voltage [V] Voltage measured from each ESC.
+ * @param current [A] Current measured from each ESC.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_esc_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t index, uint64_t time_usec, const int32_t *rpm, const float *voltage, const float *current)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ESC_STATUS_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_uint8_t(buf, 56, index);
+    _mav_put_int32_t_array(buf, 8, rpm, 4);
+    _mav_put_float_array(buf, 24, voltage, 4);
+    _mav_put_float_array(buf, 40, current, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ESC_STATUS_LEN);
+#else
+    mavlink_esc_status_t packet;
+    packet.time_usec = time_usec;
+    packet.index = index;
+    mav_array_memcpy(packet.rpm, rpm, sizeof(int32_t)*4);
+    mav_array_memcpy(packet.voltage, voltage, sizeof(float)*4);
+    mav_array_memcpy(packet.current, current, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ESC_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ESC_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ESC_STATUS_MIN_LEN, MAVLINK_MSG_ID_ESC_STATUS_LEN, MAVLINK_MSG_ID_ESC_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ESC_STATUS_MIN_LEN, MAVLINK_MSG_ID_ESC_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a esc_status message on a channel
  * @param system_id ID of this system
@@ -153,6 +196,20 @@ static inline uint16_t mavlink_msg_esc_status_encode_chan(uint8_t system_id, uin
     return mavlink_msg_esc_status_pack_chan(system_id, component_id, chan, msg, esc_status->index, esc_status->time_usec, esc_status->rpm, esc_status->voltage, esc_status->current);
 }
 
+/**
+ * @brief Encode a esc_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param esc_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_esc_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_esc_status_t* esc_status)
+{
+    return mavlink_msg_esc_status_pack_status(system_id, component_id, _status, msg,  esc_status->index, esc_status->time_usec, esc_status->rpm, esc_status->voltage, esc_status->current);
+}
+
 /**
  * @brief Send a esc_status message
  * @param chan MAVLink channel to send the message

+ 74 - 0
v2.0/common/mavlink_msg_estimator_status.h

@@ -117,6 +117,66 @@ static inline uint16_t mavlink_msg_estimator_status_pack(uint8_t system_id, uint
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_ESTIMATOR_STATUS_MIN_LEN, MAVLINK_MSG_ID_ESTIMATOR_STATUS_LEN, MAVLINK_MSG_ID_ESTIMATOR_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a estimator_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param flags  Bitmap indicating which EKF outputs are valid.
+ * @param vel_ratio  Velocity innovation test ratio
+ * @param pos_horiz_ratio  Horizontal position innovation test ratio
+ * @param pos_vert_ratio  Vertical position innovation test ratio
+ * @param mag_ratio  Magnetometer innovation test ratio
+ * @param hagl_ratio  Height above terrain innovation test ratio
+ * @param tas_ratio  True airspeed innovation test ratio
+ * @param pos_horiz_accuracy [m] Horizontal position 1-STD accuracy relative to the EKF local origin
+ * @param pos_vert_accuracy [m] Vertical position 1-STD accuracy relative to the EKF local origin
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_estimator_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint16_t flags, float vel_ratio, float pos_horiz_ratio, float pos_vert_ratio, float mag_ratio, float hagl_ratio, float tas_ratio, float pos_horiz_accuracy, float pos_vert_accuracy)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_ESTIMATOR_STATUS_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 8, vel_ratio);
+    _mav_put_float(buf, 12, pos_horiz_ratio);
+    _mav_put_float(buf, 16, pos_vert_ratio);
+    _mav_put_float(buf, 20, mag_ratio);
+    _mav_put_float(buf, 24, hagl_ratio);
+    _mav_put_float(buf, 28, tas_ratio);
+    _mav_put_float(buf, 32, pos_horiz_accuracy);
+    _mav_put_float(buf, 36, pos_vert_accuracy);
+    _mav_put_uint16_t(buf, 40, flags);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_ESTIMATOR_STATUS_LEN);
+#else
+    mavlink_estimator_status_t packet;
+    packet.time_usec = time_usec;
+    packet.vel_ratio = vel_ratio;
+    packet.pos_horiz_ratio = pos_horiz_ratio;
+    packet.pos_vert_ratio = pos_vert_ratio;
+    packet.mag_ratio = mag_ratio;
+    packet.hagl_ratio = hagl_ratio;
+    packet.tas_ratio = tas_ratio;
+    packet.pos_horiz_accuracy = pos_horiz_accuracy;
+    packet.pos_vert_accuracy = pos_vert_accuracy;
+    packet.flags = flags;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_ESTIMATOR_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_ESTIMATOR_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ESTIMATOR_STATUS_MIN_LEN, MAVLINK_MSG_ID_ESTIMATOR_STATUS_LEN, MAVLINK_MSG_ID_ESTIMATOR_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_ESTIMATOR_STATUS_MIN_LEN, MAVLINK_MSG_ID_ESTIMATOR_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a estimator_status message on a channel
  * @param system_id ID of this system
@@ -200,6 +260,20 @@ static inline uint16_t mavlink_msg_estimator_status_encode_chan(uint8_t system_i
     return mavlink_msg_estimator_status_pack_chan(system_id, component_id, chan, msg, estimator_status->time_usec, estimator_status->flags, estimator_status->vel_ratio, estimator_status->pos_horiz_ratio, estimator_status->pos_vert_ratio, estimator_status->mag_ratio, estimator_status->hagl_ratio, estimator_status->tas_ratio, estimator_status->pos_horiz_accuracy, estimator_status->pos_vert_accuracy);
 }
 
+/**
+ * @brief Encode a estimator_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param estimator_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_estimator_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_estimator_status_t* estimator_status)
+{
+    return mavlink_msg_estimator_status_pack_status(system_id, component_id, _status, msg,  estimator_status->time_usec, estimator_status->flags, estimator_status->vel_ratio, estimator_status->pos_horiz_ratio, estimator_status->pos_vert_ratio, estimator_status->mag_ratio, estimator_status->hagl_ratio, estimator_status->tas_ratio, estimator_status->pos_horiz_accuracy, estimator_status->pos_vert_accuracy);
+}
+
 /**
  * @brief Send a estimator_status message
  * @param chan MAVLink channel to send the message

+ 63 - 0
v2.0/common/mavlink_msg_event.h

@@ -97,6 +97,55 @@ static inline uint16_t mavlink_msg_event_pack(uint8_t system_id, uint8_t compone
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_EVENT_MIN_LEN, MAVLINK_MSG_ID_EVENT_LEN, MAVLINK_MSG_ID_EVENT_CRC);
 }
 
+/**
+ * @brief Pack a event message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param destination_component  Component ID
+ * @param destination_system  System ID
+ * @param id  Event ID (as defined in the component metadata)
+ * @param event_time_boot_ms [ms] Timestamp (time since system boot when the event happened).
+ * @param sequence  Sequence number.
+ * @param log_levels  Log levels: 4 bits MSB: internal (for logging purposes), 4 bits LSB: external. Levels: Emergency = 0, Alert = 1, Critical = 2, Error = 3, Warning = 4, Notice = 5, Info = 6, Debug = 7, Protocol = 8, Disabled = 9
+ * @param arguments  Arguments (depend on event ID).
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_event_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t destination_component, uint8_t destination_system, uint32_t id, uint32_t event_time_boot_ms, uint16_t sequence, uint8_t log_levels, const uint8_t *arguments)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_EVENT_LEN];
+    _mav_put_uint32_t(buf, 0, id);
+    _mav_put_uint32_t(buf, 4, event_time_boot_ms);
+    _mav_put_uint16_t(buf, 8, sequence);
+    _mav_put_uint8_t(buf, 10, destination_component);
+    _mav_put_uint8_t(buf, 11, destination_system);
+    _mav_put_uint8_t(buf, 12, log_levels);
+    _mav_put_uint8_t_array(buf, 13, arguments, 40);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_EVENT_LEN);
+#else
+    mavlink_event_t packet;
+    packet.id = id;
+    packet.event_time_boot_ms = event_time_boot_ms;
+    packet.sequence = sequence;
+    packet.destination_component = destination_component;
+    packet.destination_system = destination_system;
+    packet.log_levels = log_levels;
+    mav_array_memcpy(packet.arguments, arguments, sizeof(uint8_t)*40);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_EVENT_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_EVENT;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_EVENT_MIN_LEN, MAVLINK_MSG_ID_EVENT_LEN, MAVLINK_MSG_ID_EVENT_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_EVENT_MIN_LEN, MAVLINK_MSG_ID_EVENT_LEN);
+#endif
+}
+
 /**
  * @brief Pack a event message on a channel
  * @param system_id ID of this system
@@ -169,6 +218,20 @@ static inline uint16_t mavlink_msg_event_encode_chan(uint8_t system_id, uint8_t
     return mavlink_msg_event_pack_chan(system_id, component_id, chan, msg, event->destination_component, event->destination_system, event->id, event->event_time_boot_ms, event->sequence, event->log_levels, event->arguments);
 }
 
+/**
+ * @brief Encode a event struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param event C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_event_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_event_t* event)
+{
+    return mavlink_msg_event_pack_status(system_id, component_id, _status, msg,  event->destination_component, event->destination_system, event->id, event->event_time_boot_ms, event->sequence, event->log_levels, event->arguments);
+}
+
 /**
  * @brief Send a event message
  * @param chan MAVLink channel to send the message

+ 50 - 0
v2.0/common/mavlink_msg_extended_sys_state.h

@@ -69,6 +69,42 @@ static inline uint16_t mavlink_msg_extended_sys_state_pack(uint8_t system_id, ui
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_EXTENDED_SYS_STATE_MIN_LEN, MAVLINK_MSG_ID_EXTENDED_SYS_STATE_LEN, MAVLINK_MSG_ID_EXTENDED_SYS_STATE_CRC);
 }
 
+/**
+ * @brief Pack a extended_sys_state message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param vtol_state  The VTOL state if applicable. Is set to MAV_VTOL_STATE_UNDEFINED if UAV is not in VTOL configuration.
+ * @param landed_state  The landed state. Is set to MAV_LANDED_STATE_UNDEFINED if landed state is unknown.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_extended_sys_state_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t vtol_state, uint8_t landed_state)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_EXTENDED_SYS_STATE_LEN];
+    _mav_put_uint8_t(buf, 0, vtol_state);
+    _mav_put_uint8_t(buf, 1, landed_state);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_EXTENDED_SYS_STATE_LEN);
+#else
+    mavlink_extended_sys_state_t packet;
+    packet.vtol_state = vtol_state;
+    packet.landed_state = landed_state;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_EXTENDED_SYS_STATE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_EXTENDED_SYS_STATE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_EXTENDED_SYS_STATE_MIN_LEN, MAVLINK_MSG_ID_EXTENDED_SYS_STATE_LEN, MAVLINK_MSG_ID_EXTENDED_SYS_STATE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_EXTENDED_SYS_STATE_MIN_LEN, MAVLINK_MSG_ID_EXTENDED_SYS_STATE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a extended_sys_state message on a channel
  * @param system_id ID of this system
@@ -128,6 +164,20 @@ static inline uint16_t mavlink_msg_extended_sys_state_encode_chan(uint8_t system
     return mavlink_msg_extended_sys_state_pack_chan(system_id, component_id, chan, msg, extended_sys_state->vtol_state, extended_sys_state->landed_state);
 }
 
+/**
+ * @brief Encode a extended_sys_state struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param extended_sys_state C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_extended_sys_state_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_extended_sys_state_t* extended_sys_state)
+{
+    return mavlink_msg_extended_sys_state_pack_status(system_id, component_id, _status, msg,  extended_sys_state->vtol_state, extended_sys_state->landed_state);
+}
+
 /**
  * @brief Send a extended_sys_state message
  * @param chan MAVLink channel to send the message

+ 59 - 0
v2.0/common/mavlink_msg_fence_status.h

@@ -87,6 +87,51 @@ static inline uint16_t mavlink_msg_fence_status_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_FENCE_STATUS_MIN_LEN, MAVLINK_MSG_ID_FENCE_STATUS_LEN, MAVLINK_MSG_ID_FENCE_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a fence_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param breach_status  Breach status (0 if currently inside fence, 1 if outside).
+ * @param breach_count  Number of fence breaches.
+ * @param breach_type  Last breach type.
+ * @param breach_time [ms] Time (since boot) of last breach.
+ * @param breach_mitigation  Active action to prevent fence breach
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_fence_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t breach_status, uint16_t breach_count, uint8_t breach_type, uint32_t breach_time, uint8_t breach_mitigation)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_FENCE_STATUS_LEN];
+    _mav_put_uint32_t(buf, 0, breach_time);
+    _mav_put_uint16_t(buf, 4, breach_count);
+    _mav_put_uint8_t(buf, 6, breach_status);
+    _mav_put_uint8_t(buf, 7, breach_type);
+    _mav_put_uint8_t(buf, 8, breach_mitigation);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_FENCE_STATUS_LEN);
+#else
+    mavlink_fence_status_t packet;
+    packet.breach_time = breach_time;
+    packet.breach_count = breach_count;
+    packet.breach_status = breach_status;
+    packet.breach_type = breach_type;
+    packet.breach_mitigation = breach_mitigation;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_FENCE_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_FENCE_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_FENCE_STATUS_MIN_LEN, MAVLINK_MSG_ID_FENCE_STATUS_LEN, MAVLINK_MSG_ID_FENCE_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_FENCE_STATUS_MIN_LEN, MAVLINK_MSG_ID_FENCE_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a fence_status message on a channel
  * @param system_id ID of this system
@@ -155,6 +200,20 @@ static inline uint16_t mavlink_msg_fence_status_encode_chan(uint8_t system_id, u
     return mavlink_msg_fence_status_pack_chan(system_id, component_id, chan, msg, fence_status->breach_status, fence_status->breach_count, fence_status->breach_type, fence_status->breach_time, fence_status->breach_mitigation);
 }
 
+/**
+ * @brief Encode a fence_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param fence_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_fence_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_fence_status_t* fence_status)
+{
+    return mavlink_msg_fence_status_pack_status(system_id, component_id, _status, msg,  fence_status->breach_status, fence_status->breach_count, fence_status->breach_type, fence_status->breach_time, fence_status->breach_mitigation);
+}
+
 /**
  * @brief Send a fence_status message
  * @param chan MAVLink channel to send the message

+ 54 - 0
v2.0/common/mavlink_msg_file_transfer_protocol.h

@@ -79,6 +79,46 @@ static inline uint16_t mavlink_msg_file_transfer_protocol_pack(uint8_t system_id
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_MIN_LEN, MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_LEN, MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_CRC);
 }
 
+/**
+ * @brief Pack a file_transfer_protocol message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_network  Network ID (0 for broadcast)
+ * @param target_system  System ID (0 for broadcast)
+ * @param target_component  Component ID (0 for broadcast)
+ * @param payload  Variable length payload. The length is defined by the remaining message length when subtracting the header and other fields. The content/format of this block is defined in https://mavlink.io/en/services/ftp.html.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_file_transfer_protocol_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_network, uint8_t target_system, uint8_t target_component, const uint8_t *payload)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_LEN];
+    _mav_put_uint8_t(buf, 0, target_network);
+    _mav_put_uint8_t(buf, 1, target_system);
+    _mav_put_uint8_t(buf, 2, target_component);
+    _mav_put_uint8_t_array(buf, 3, payload, 251);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_LEN);
+#else
+    mavlink_file_transfer_protocol_t packet;
+    packet.target_network = target_network;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    mav_array_memcpy(packet.payload, payload, sizeof(uint8_t)*251);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_MIN_LEN, MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_LEN, MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_MIN_LEN, MAVLINK_MSG_ID_FILE_TRANSFER_PROTOCOL_LEN);
+#endif
+}
+
 /**
  * @brief Pack a file_transfer_protocol message on a channel
  * @param system_id ID of this system
@@ -142,6 +182,20 @@ static inline uint16_t mavlink_msg_file_transfer_protocol_encode_chan(uint8_t sy
     return mavlink_msg_file_transfer_protocol_pack_chan(system_id, component_id, chan, msg, file_transfer_protocol->target_network, file_transfer_protocol->target_system, file_transfer_protocol->target_component, file_transfer_protocol->payload);
 }
 
+/**
+ * @brief Encode a file_transfer_protocol struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param file_transfer_protocol C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_file_transfer_protocol_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_file_transfer_protocol_t* file_transfer_protocol)
+{
+    return mavlink_msg_file_transfer_protocol_pack_status(system_id, component_id, _status, msg,  file_transfer_protocol->target_network, file_transfer_protocol->target_system, file_transfer_protocol->target_component, file_transfer_protocol->payload);
+}
+
 /**
  * @brief Send a file_transfer_protocol message
  * @param chan MAVLink channel to send the message

+ 59 - 0
v2.0/common/mavlink_msg_flight_information.h

@@ -87,6 +87,51 @@ static inline uint16_t mavlink_msg_flight_information_pack(uint8_t system_id, ui
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_FLIGHT_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_FLIGHT_INFORMATION_LEN, MAVLINK_MSG_ID_FLIGHT_INFORMATION_CRC);
 }
 
+/**
+ * @brief Pack a flight_information message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param arming_time_utc [us] Timestamp at arming (since system boot). Set to 0 on boot. Set value on arming. Note, field is misnamed UTC.
+ * @param takeoff_time_utc [us] Timestamp at takeoff (since system boot). Set to 0 at boot and on arming. Note, field is misnamed UTC.
+ * @param flight_uuid  Flight number. Note, field is misnamed UUID.
+ * @param landing_time [ms] Timestamp at landing (in ms since system boot). Set to 0 at boot and on arming.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_flight_information_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint64_t arming_time_utc, uint64_t takeoff_time_utc, uint64_t flight_uuid, uint32_t landing_time)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_FLIGHT_INFORMATION_LEN];
+    _mav_put_uint64_t(buf, 0, arming_time_utc);
+    _mav_put_uint64_t(buf, 8, takeoff_time_utc);
+    _mav_put_uint64_t(buf, 16, flight_uuid);
+    _mav_put_uint32_t(buf, 24, time_boot_ms);
+    _mav_put_uint32_t(buf, 28, landing_time);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_FLIGHT_INFORMATION_LEN);
+#else
+    mavlink_flight_information_t packet;
+    packet.arming_time_utc = arming_time_utc;
+    packet.takeoff_time_utc = takeoff_time_utc;
+    packet.flight_uuid = flight_uuid;
+    packet.time_boot_ms = time_boot_ms;
+    packet.landing_time = landing_time;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_FLIGHT_INFORMATION_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_FLIGHT_INFORMATION;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_FLIGHT_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_FLIGHT_INFORMATION_LEN, MAVLINK_MSG_ID_FLIGHT_INFORMATION_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_FLIGHT_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_FLIGHT_INFORMATION_LEN);
+#endif
+}
+
 /**
  * @brief Pack a flight_information message on a channel
  * @param system_id ID of this system
@@ -155,6 +200,20 @@ static inline uint16_t mavlink_msg_flight_information_encode_chan(uint8_t system
     return mavlink_msg_flight_information_pack_chan(system_id, component_id, chan, msg, flight_information->time_boot_ms, flight_information->arming_time_utc, flight_information->takeoff_time_utc, flight_information->flight_uuid, flight_information->landing_time);
 }
 
+/**
+ * @brief Encode a flight_information struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param flight_information C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_flight_information_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_flight_information_t* flight_information)
+{
+    return mavlink_msg_flight_information_pack_status(system_id, component_id, _status, msg,  flight_information->time_boot_ms, flight_information->arming_time_utc, flight_information->takeoff_time_utc, flight_information->flight_uuid, flight_information->landing_time);
+}
+
 /**
  * @brief Send a flight_information message
  * @param chan MAVLink channel to send the message

+ 75 - 0
v2.0/common/mavlink_msg_follow_target.h

@@ -125,6 +125,67 @@ static inline uint16_t mavlink_msg_follow_target_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_FOLLOW_TARGET_MIN_LEN, MAVLINK_MSG_ID_FOLLOW_TARGET_LEN, MAVLINK_MSG_ID_FOLLOW_TARGET_CRC);
 }
 
+/**
+ * @brief Pack a follow_target message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param timestamp [ms] Timestamp (time since system boot).
+ * @param est_capabilities  bit positions for tracker reporting capabilities (POS = 0, VEL = 1, ACCEL = 2, ATT + RATES = 3)
+ * @param lat [degE7] Latitude (WGS84)
+ * @param lon [degE7] Longitude (WGS84)
+ * @param alt [m] Altitude (MSL)
+ * @param vel [m/s] target velocity (0,0,0) for unknown
+ * @param acc [m/s/s] linear target acceleration (0,0,0) for unknown
+ * @param attitude_q  (0 0 0 0 for unknown)
+ * @param rates  (0 0 0 for unknown)
+ * @param position_cov  eph epv
+ * @param custom_state  button states or switches of a tracker device
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_follow_target_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t timestamp, uint8_t est_capabilities, int32_t lat, int32_t lon, float alt, const float *vel, const float *acc, const float *attitude_q, const float *rates, const float *position_cov, uint64_t custom_state)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_FOLLOW_TARGET_LEN];
+    _mav_put_uint64_t(buf, 0, timestamp);
+    _mav_put_uint64_t(buf, 8, custom_state);
+    _mav_put_int32_t(buf, 16, lat);
+    _mav_put_int32_t(buf, 20, lon);
+    _mav_put_float(buf, 24, alt);
+    _mav_put_uint8_t(buf, 92, est_capabilities);
+    _mav_put_float_array(buf, 28, vel, 3);
+    _mav_put_float_array(buf, 40, acc, 3);
+    _mav_put_float_array(buf, 52, attitude_q, 4);
+    _mav_put_float_array(buf, 68, rates, 3);
+    _mav_put_float_array(buf, 80, position_cov, 3);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_FOLLOW_TARGET_LEN);
+#else
+    mavlink_follow_target_t packet;
+    packet.timestamp = timestamp;
+    packet.custom_state = custom_state;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.est_capabilities = est_capabilities;
+    mav_array_memcpy(packet.vel, vel, sizeof(float)*3);
+    mav_array_memcpy(packet.acc, acc, sizeof(float)*3);
+    mav_array_memcpy(packet.attitude_q, attitude_q, sizeof(float)*4);
+    mav_array_memcpy(packet.rates, rates, sizeof(float)*3);
+    mav_array_memcpy(packet.position_cov, position_cov, sizeof(float)*3);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_FOLLOW_TARGET_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_FOLLOW_TARGET;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_FOLLOW_TARGET_MIN_LEN, MAVLINK_MSG_ID_FOLLOW_TARGET_LEN, MAVLINK_MSG_ID_FOLLOW_TARGET_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_FOLLOW_TARGET_MIN_LEN, MAVLINK_MSG_ID_FOLLOW_TARGET_LEN);
+#endif
+}
+
 /**
  * @brief Pack a follow_target message on a channel
  * @param system_id ID of this system
@@ -209,6 +270,20 @@ static inline uint16_t mavlink_msg_follow_target_encode_chan(uint8_t system_id,
     return mavlink_msg_follow_target_pack_chan(system_id, component_id, chan, msg, follow_target->timestamp, follow_target->est_capabilities, follow_target->lat, follow_target->lon, follow_target->alt, follow_target->vel, follow_target->acc, follow_target->attitude_q, follow_target->rates, follow_target->position_cov, follow_target->custom_state);
 }
 
+/**
+ * @brief Encode a follow_target struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param follow_target C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_follow_target_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_follow_target_t* follow_target)
+{
+    return mavlink_msg_follow_target_pack_status(system_id, component_id, _status, msg,  follow_target->timestamp, follow_target->est_capabilities, follow_target->lat, follow_target->lon, follow_target->alt, follow_target->vel, follow_target->acc, follow_target->attitude_q, follow_target->rates, follow_target->position_cov, follow_target->custom_state);
+}
+
 /**
  * @brief Send a follow_target message
  * @param chan MAVLink channel to send the message

+ 77 - 0
v2.0/common/mavlink_msg_generator_status.h

@@ -123,6 +123,69 @@ static inline uint16_t mavlink_msg_generator_status_pack(uint8_t system_id, uint
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GENERATOR_STATUS_MIN_LEN, MAVLINK_MSG_ID_GENERATOR_STATUS_LEN, MAVLINK_MSG_ID_GENERATOR_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a generator_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param status  Status flags.
+ * @param generator_speed [rpm] Speed of electrical generator or alternator. UINT16_MAX: field not provided.
+ * @param battery_current [A] Current into/out of battery. Positive for out. Negative for in. NaN: field not provided.
+ * @param load_current [A] Current going to the UAV. If battery current not available this is the DC current from the generator. Positive for out. Negative for in. NaN: field not provided
+ * @param power_generated [W] The power being generated. NaN: field not provided
+ * @param bus_voltage [V] Voltage of the bus seen at the generator, or battery bus if battery bus is controlled by generator and at a different voltage to main bus.
+ * @param rectifier_temperature [degC] The temperature of the rectifier or power converter. INT16_MAX: field not provided.
+ * @param bat_current_setpoint [A] The target battery current. Positive for out. Negative for in. NaN: field not provided
+ * @param generator_temperature [degC] The temperature of the mechanical motor, fuel cell core or generator. INT16_MAX: field not provided.
+ * @param runtime [s] Seconds this generator has run since it was rebooted. UINT32_MAX: field not provided.
+ * @param time_until_maintenance [s] Seconds until this generator requires maintenance.  A negative value indicates maintenance is past-due. INT32_MAX: field not provided.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_generator_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t status, uint16_t generator_speed, float battery_current, float load_current, float power_generated, float bus_voltage, int16_t rectifier_temperature, float bat_current_setpoint, int16_t generator_temperature, uint32_t runtime, int32_t time_until_maintenance)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GENERATOR_STATUS_LEN];
+    _mav_put_uint64_t(buf, 0, status);
+    _mav_put_float(buf, 8, battery_current);
+    _mav_put_float(buf, 12, load_current);
+    _mav_put_float(buf, 16, power_generated);
+    _mav_put_float(buf, 20, bus_voltage);
+    _mav_put_float(buf, 24, bat_current_setpoint);
+    _mav_put_uint32_t(buf, 28, runtime);
+    _mav_put_int32_t(buf, 32, time_until_maintenance);
+    _mav_put_uint16_t(buf, 36, generator_speed);
+    _mav_put_int16_t(buf, 38, rectifier_temperature);
+    _mav_put_int16_t(buf, 40, generator_temperature);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GENERATOR_STATUS_LEN);
+#else
+    mavlink_generator_status_t packet;
+    packet.status = status;
+    packet.battery_current = battery_current;
+    packet.load_current = load_current;
+    packet.power_generated = power_generated;
+    packet.bus_voltage = bus_voltage;
+    packet.bat_current_setpoint = bat_current_setpoint;
+    packet.runtime = runtime;
+    packet.time_until_maintenance = time_until_maintenance;
+    packet.generator_speed = generator_speed;
+    packet.rectifier_temperature = rectifier_temperature;
+    packet.generator_temperature = generator_temperature;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GENERATOR_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GENERATOR_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GENERATOR_STATUS_MIN_LEN, MAVLINK_MSG_ID_GENERATOR_STATUS_LEN, MAVLINK_MSG_ID_GENERATOR_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GENERATOR_STATUS_MIN_LEN, MAVLINK_MSG_ID_GENERATOR_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a generator_status message on a channel
  * @param system_id ID of this system
@@ -209,6 +272,20 @@ static inline uint16_t mavlink_msg_generator_status_encode_chan(uint8_t system_i
     return mavlink_msg_generator_status_pack_chan(system_id, component_id, chan, msg, generator_status->status, generator_status->generator_speed, generator_status->battery_current, generator_status->load_current, generator_status->power_generated, generator_status->bus_voltage, generator_status->rectifier_temperature, generator_status->bat_current_setpoint, generator_status->generator_temperature, generator_status->runtime, generator_status->time_until_maintenance);
 }
 
+/**
+ * @brief Encode a generator_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param generator_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_generator_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_generator_status_t* generator_status)
+{
+    return mavlink_msg_generator_status_pack_status(system_id, component_id, _status, msg,  generator_status->status, generator_status->generator_speed, generator_status->battery_current, generator_status->load_current, generator_status->power_generated, generator_status->bus_voltage, generator_status->rectifier_temperature, generator_status->bat_current_setpoint, generator_status->generator_temperature, generator_status->runtime, generator_status->time_until_maintenance);
+}
+
 /**
  * @brief Send a generator_status message
  * @param chan MAVLink channel to send the message

+ 78 - 0
v2.0/common/mavlink_msg_gimbal_device_attitude_status.h

@@ -127,6 +127,70 @@ static inline uint16_t mavlink_msg_gimbal_device_attitude_status_pack(uint8_t sy
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a gimbal_device_attitude_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID
+ * @param target_component  Component ID
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param flags  Current gimbal flags set.
+ * @param q  Quaternion components, w, x, y, z (1 0 0 0 is the null-rotation). The frame is described in the message description.
+ * @param angular_velocity_x [rad/s] X component of angular velocity (positive: rolling to the right). The frame is described in the message description. NaN if unknown.
+ * @param angular_velocity_y [rad/s] Y component of angular velocity (positive: pitching up). The frame is described in the message description. NaN if unknown.
+ * @param angular_velocity_z [rad/s] Z component of angular velocity (positive: yawing to the right). The frame is described in the message description. NaN if unknown.
+ * @param failure_flags  Failure flags (0 for no failure)
+ * @param delta_yaw [rad] Yaw angle relating the quaternions in earth and body frames (see message description). NaN if unknown.
+ * @param delta_yaw_velocity [rad/s] Yaw angular velocity relating the angular velocities in earth and body frames (see message description). NaN if unknown.
+ * @param gimbal_device_id  This field is to be used if the gimbal manager and the gimbal device are the same component and hence have the same component ID. This field is then set a number between 1-6. If the component ID is separate, this field is not required and must be set to 0.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gimbal_device_attitude_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint32_t time_boot_ms, uint16_t flags, const float *q, float angular_velocity_x, float angular_velocity_y, float angular_velocity_z, uint32_t failure_flags, float delta_yaw, float delta_yaw_velocity, uint8_t gimbal_device_id)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_float(buf, 20, angular_velocity_x);
+    _mav_put_float(buf, 24, angular_velocity_y);
+    _mav_put_float(buf, 28, angular_velocity_z);
+    _mav_put_uint32_t(buf, 32, failure_flags);
+    _mav_put_uint16_t(buf, 36, flags);
+    _mav_put_uint8_t(buf, 38, target_system);
+    _mav_put_uint8_t(buf, 39, target_component);
+    _mav_put_float(buf, 40, delta_yaw);
+    _mav_put_float(buf, 44, delta_yaw_velocity);
+    _mav_put_uint8_t(buf, 48, gimbal_device_id);
+    _mav_put_float_array(buf, 4, q, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_LEN);
+#else
+    mavlink_gimbal_device_attitude_status_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.angular_velocity_x = angular_velocity_x;
+    packet.angular_velocity_y = angular_velocity_y;
+    packet.angular_velocity_z = angular_velocity_z;
+    packet.failure_flags = failure_flags;
+    packet.flags = flags;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.delta_yaw = delta_yaw;
+    packet.delta_yaw_velocity = delta_yaw_velocity;
+    packet.gimbal_device_id = gimbal_device_id;
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_ATTITUDE_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gimbal_device_attitude_status message on a channel
  * @param system_id ID of this system
@@ -214,6 +278,20 @@ static inline uint16_t mavlink_msg_gimbal_device_attitude_status_encode_chan(uin
     return mavlink_msg_gimbal_device_attitude_status_pack_chan(system_id, component_id, chan, msg, gimbal_device_attitude_status->target_system, gimbal_device_attitude_status->target_component, gimbal_device_attitude_status->time_boot_ms, gimbal_device_attitude_status->flags, gimbal_device_attitude_status->q, gimbal_device_attitude_status->angular_velocity_x, gimbal_device_attitude_status->angular_velocity_y, gimbal_device_attitude_status->angular_velocity_z, gimbal_device_attitude_status->failure_flags, gimbal_device_attitude_status->delta_yaw, gimbal_device_attitude_status->delta_yaw_velocity, gimbal_device_attitude_status->gimbal_device_id);
 }
 
+/**
+ * @brief Encode a gimbal_device_attitude_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gimbal_device_attitude_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gimbal_device_attitude_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gimbal_device_attitude_status_t* gimbal_device_attitude_status)
+{
+    return mavlink_msg_gimbal_device_attitude_status_pack_status(system_id, component_id, _status, msg,  gimbal_device_attitude_status->target_system, gimbal_device_attitude_status->target_component, gimbal_device_attitude_status->time_boot_ms, gimbal_device_attitude_status->flags, gimbal_device_attitude_status->q, gimbal_device_attitude_status->angular_velocity_x, gimbal_device_attitude_status->angular_velocity_y, gimbal_device_attitude_status->angular_velocity_z, gimbal_device_attitude_status->failure_flags, gimbal_device_attitude_status->delta_yaw, gimbal_device_attitude_status->delta_yaw_velocity, gimbal_device_attitude_status->gimbal_device_id);
+}
+
 /**
  * @brief Send a gimbal_device_attitude_status message
  * @param chan MAVLink channel to send the message

+ 90 - 0
v2.0/common/mavlink_msg_gimbal_device_information.h

@@ -153,6 +153,82 @@ static inline uint16_t mavlink_msg_gimbal_device_information_pack(uint8_t system
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_CRC);
 }
 
+/**
+ * @brief Pack a gimbal_device_information message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param vendor_name  Name of the gimbal vendor.
+ * @param model_name  Name of the gimbal model.
+ * @param custom_name  Custom name of the gimbal given to it by the user.
+ * @param firmware_version  Version of the gimbal firmware, encoded as: (Dev & 0xff) << 24 | (Patch & 0xff) << 16 | (Minor & 0xff) << 8 | (Major & 0xff).
+ * @param hardware_version  Version of the gimbal hardware, encoded as: (Dev & 0xff) << 24 | (Patch & 0xff) << 16 | (Minor & 0xff) << 8 | (Major & 0xff).
+ * @param uid  UID of gimbal hardware (0 if unknown).
+ * @param cap_flags  Bitmap of gimbal capability flags.
+ * @param custom_cap_flags  Bitmap for use for gimbal-specific capability flags.
+ * @param roll_min [rad] Minimum hardware roll angle (positive: rolling to the right, negative: rolling to the left). NAN if unknown.
+ * @param roll_max [rad] Maximum hardware roll angle (positive: rolling to the right, negative: rolling to the left). NAN if unknown.
+ * @param pitch_min [rad] Minimum hardware pitch angle (positive: up, negative: down). NAN if unknown.
+ * @param pitch_max [rad] Maximum hardware pitch angle (positive: up, negative: down). NAN if unknown.
+ * @param yaw_min [rad] Minimum hardware yaw angle (positive: to the right, negative: to the left). NAN if unknown.
+ * @param yaw_max [rad] Maximum hardware yaw angle (positive: to the right, negative: to the left). NAN if unknown.
+ * @param gimbal_device_id  This field is to be used if the gimbal manager and the gimbal device are the same component and hence have the same component ID. This field is then set to a number between 1-6. If the component ID is separate, this field is not required and must be set to 0.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gimbal_device_information_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, const char *vendor_name, const char *model_name, const char *custom_name, uint32_t firmware_version, uint32_t hardware_version, uint64_t uid, uint16_t cap_flags, uint16_t custom_cap_flags, float roll_min, float roll_max, float pitch_min, float pitch_max, float yaw_min, float yaw_max, uint8_t gimbal_device_id)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_LEN];
+    _mav_put_uint64_t(buf, 0, uid);
+    _mav_put_uint32_t(buf, 8, time_boot_ms);
+    _mav_put_uint32_t(buf, 12, firmware_version);
+    _mav_put_uint32_t(buf, 16, hardware_version);
+    _mav_put_float(buf, 20, roll_min);
+    _mav_put_float(buf, 24, roll_max);
+    _mav_put_float(buf, 28, pitch_min);
+    _mav_put_float(buf, 32, pitch_max);
+    _mav_put_float(buf, 36, yaw_min);
+    _mav_put_float(buf, 40, yaw_max);
+    _mav_put_uint16_t(buf, 44, cap_flags);
+    _mav_put_uint16_t(buf, 46, custom_cap_flags);
+    _mav_put_uint8_t(buf, 144, gimbal_device_id);
+    _mav_put_char_array(buf, 48, vendor_name, 32);
+    _mav_put_char_array(buf, 80, model_name, 32);
+    _mav_put_char_array(buf, 112, custom_name, 32);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_LEN);
+#else
+    mavlink_gimbal_device_information_t packet;
+    packet.uid = uid;
+    packet.time_boot_ms = time_boot_ms;
+    packet.firmware_version = firmware_version;
+    packet.hardware_version = hardware_version;
+    packet.roll_min = roll_min;
+    packet.roll_max = roll_max;
+    packet.pitch_min = pitch_min;
+    packet.pitch_max = pitch_max;
+    packet.yaw_min = yaw_min;
+    packet.yaw_max = yaw_max;
+    packet.cap_flags = cap_flags;
+    packet.custom_cap_flags = custom_cap_flags;
+    packet.gimbal_device_id = gimbal_device_id;
+    mav_array_memcpy(packet.vendor_name, vendor_name, sizeof(char)*32);
+    mav_array_memcpy(packet.model_name, model_name, sizeof(char)*32);
+    mav_array_memcpy(packet.custom_name, custom_name, sizeof(char)*32);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_INFORMATION_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gimbal_device_information message on a channel
  * @param system_id ID of this system
@@ -252,6 +328,20 @@ static inline uint16_t mavlink_msg_gimbal_device_information_encode_chan(uint8_t
     return mavlink_msg_gimbal_device_information_pack_chan(system_id, component_id, chan, msg, gimbal_device_information->time_boot_ms, gimbal_device_information->vendor_name, gimbal_device_information->model_name, gimbal_device_information->custom_name, gimbal_device_information->firmware_version, gimbal_device_information->hardware_version, gimbal_device_information->uid, gimbal_device_information->cap_flags, gimbal_device_information->custom_cap_flags, gimbal_device_information->roll_min, gimbal_device_information->roll_max, gimbal_device_information->pitch_min, gimbal_device_information->pitch_max, gimbal_device_information->yaw_min, gimbal_device_information->yaw_max, gimbal_device_information->gimbal_device_id);
 }
 
+/**
+ * @brief Encode a gimbal_device_information struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gimbal_device_information C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gimbal_device_information_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gimbal_device_information_t* gimbal_device_information)
+{
+    return mavlink_msg_gimbal_device_information_pack_status(system_id, component_id, _status, msg,  gimbal_device_information->time_boot_ms, gimbal_device_information->vendor_name, gimbal_device_information->model_name, gimbal_device_information->custom_name, gimbal_device_information->firmware_version, gimbal_device_information->hardware_version, gimbal_device_information->uid, gimbal_device_information->cap_flags, gimbal_device_information->custom_cap_flags, gimbal_device_information->roll_min, gimbal_device_information->roll_max, gimbal_device_information->pitch_min, gimbal_device_information->pitch_max, gimbal_device_information->yaw_min, gimbal_device_information->yaw_max, gimbal_device_information->gimbal_device_id);
+}
+
 /**
  * @brief Send a gimbal_device_information message
  * @param chan MAVLink channel to send the message

+ 63 - 0
v2.0/common/mavlink_msg_gimbal_device_set_attitude.h

@@ -97,6 +97,55 @@ static inline uint16_t mavlink_msg_gimbal_device_set_attitude_pack(uint8_t syste
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_CRC);
 }
 
+/**
+ * @brief Pack a gimbal_device_set_attitude message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID
+ * @param target_component  Component ID
+ * @param flags  Low level gimbal flags.
+ * @param q  Quaternion components, w, x, y, z (1 0 0 0 is the null-rotation). The frame is described in the message description. Set fields to NaN to be ignored.
+ * @param angular_velocity_x [rad/s] X component of angular velocity (positive: rolling to the right). The frame is described in the message description. NaN to be ignored.
+ * @param angular_velocity_y [rad/s] Y component of angular velocity (positive: pitching up). The frame is described in the message description. NaN to be ignored.
+ * @param angular_velocity_z [rad/s] Z component of angular velocity (positive: yawing to the right). The frame is described in the message description. NaN to be ignored.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gimbal_device_set_attitude_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint16_t flags, const float *q, float angular_velocity_x, float angular_velocity_y, float angular_velocity_z)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_LEN];
+    _mav_put_float(buf, 16, angular_velocity_x);
+    _mav_put_float(buf, 20, angular_velocity_y);
+    _mav_put_float(buf, 24, angular_velocity_z);
+    _mav_put_uint16_t(buf, 28, flags);
+    _mav_put_uint8_t(buf, 30, target_system);
+    _mav_put_uint8_t(buf, 31, target_component);
+    _mav_put_float_array(buf, 0, q, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_LEN);
+#else
+    mavlink_gimbal_device_set_attitude_t packet;
+    packet.angular_velocity_x = angular_velocity_x;
+    packet.angular_velocity_y = angular_velocity_y;
+    packet.angular_velocity_z = angular_velocity_z;
+    packet.flags = flags;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_DEVICE_SET_ATTITUDE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gimbal_device_set_attitude message on a channel
  * @param system_id ID of this system
@@ -169,6 +218,20 @@ static inline uint16_t mavlink_msg_gimbal_device_set_attitude_encode_chan(uint8_
     return mavlink_msg_gimbal_device_set_attitude_pack_chan(system_id, component_id, chan, msg, gimbal_device_set_attitude->target_system, gimbal_device_set_attitude->target_component, gimbal_device_set_attitude->flags, gimbal_device_set_attitude->q, gimbal_device_set_attitude->angular_velocity_x, gimbal_device_set_attitude->angular_velocity_y, gimbal_device_set_attitude->angular_velocity_z);
 }
 
+/**
+ * @brief Encode a gimbal_device_set_attitude struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gimbal_device_set_attitude C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gimbal_device_set_attitude_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gimbal_device_set_attitude_t* gimbal_device_set_attitude)
+{
+    return mavlink_msg_gimbal_device_set_attitude_pack_status(system_id, component_id, _status, msg,  gimbal_device_set_attitude->target_system, gimbal_device_set_attitude->target_component, gimbal_device_set_attitude->flags, gimbal_device_set_attitude->q, gimbal_device_set_attitude->angular_velocity_x, gimbal_device_set_attitude->angular_velocity_y, gimbal_device_set_attitude->angular_velocity_z);
+}
+
 /**
  * @brief Send a gimbal_device_set_attitude message
  * @param chan MAVLink channel to send the message

+ 71 - 0
v2.0/common/mavlink_msg_gimbal_manager_information.h

@@ -111,6 +111,63 @@ static inline uint16_t mavlink_msg_gimbal_manager_information_pack(uint8_t syste
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_CRC);
 }
 
+/**
+ * @brief Pack a gimbal_manager_information message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param cap_flags  Bitmap of gimbal capability flags.
+ * @param gimbal_device_id  Gimbal device ID that this gimbal manager is responsible for. Component ID of gimbal device (or 1-6 for non-MAVLink gimbal).
+ * @param roll_min [rad] Minimum hardware roll angle (positive: rolling to the right, negative: rolling to the left)
+ * @param roll_max [rad] Maximum hardware roll angle (positive: rolling to the right, negative: rolling to the left)
+ * @param pitch_min [rad] Minimum pitch angle (positive: up, negative: down)
+ * @param pitch_max [rad] Maximum pitch angle (positive: up, negative: down)
+ * @param yaw_min [rad] Minimum yaw angle (positive: to the right, negative: to the left)
+ * @param yaw_max [rad] Maximum yaw angle (positive: to the right, negative: to the left)
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gimbal_manager_information_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint32_t cap_flags, uint8_t gimbal_device_id, float roll_min, float roll_max, float pitch_min, float pitch_max, float yaw_min, float yaw_max)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_uint32_t(buf, 4, cap_flags);
+    _mav_put_float(buf, 8, roll_min);
+    _mav_put_float(buf, 12, roll_max);
+    _mav_put_float(buf, 16, pitch_min);
+    _mav_put_float(buf, 20, pitch_max);
+    _mav_put_float(buf, 24, yaw_min);
+    _mav_put_float(buf, 28, yaw_max);
+    _mav_put_uint8_t(buf, 32, gimbal_device_id);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_LEN);
+#else
+    mavlink_gimbal_manager_information_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.cap_flags = cap_flags;
+    packet.roll_min = roll_min;
+    packet.roll_max = roll_max;
+    packet.pitch_min = pitch_min;
+    packet.pitch_max = pitch_max;
+    packet.yaw_min = yaw_min;
+    packet.yaw_max = yaw_max;
+    packet.gimbal_device_id = gimbal_device_id;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_INFORMATION_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gimbal_manager_information message on a channel
  * @param system_id ID of this system
@@ -191,6 +248,20 @@ static inline uint16_t mavlink_msg_gimbal_manager_information_encode_chan(uint8_
     return mavlink_msg_gimbal_manager_information_pack_chan(system_id, component_id, chan, msg, gimbal_manager_information->time_boot_ms, gimbal_manager_information->cap_flags, gimbal_manager_information->gimbal_device_id, gimbal_manager_information->roll_min, gimbal_manager_information->roll_max, gimbal_manager_information->pitch_min, gimbal_manager_information->pitch_max, gimbal_manager_information->yaw_min, gimbal_manager_information->yaw_max);
 }
 
+/**
+ * @brief Encode a gimbal_manager_information struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gimbal_manager_information C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gimbal_manager_information_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gimbal_manager_information_t* gimbal_manager_information)
+{
+    return mavlink_msg_gimbal_manager_information_pack_status(system_id, component_id, _status, msg,  gimbal_manager_information->time_boot_ms, gimbal_manager_information->cap_flags, gimbal_manager_information->gimbal_device_id, gimbal_manager_information->roll_min, gimbal_manager_information->roll_max, gimbal_manager_information->pitch_min, gimbal_manager_information->pitch_max, gimbal_manager_information->yaw_min, gimbal_manager_information->yaw_max);
+}
+
 /**
  * @brief Send a gimbal_manager_information message
  * @param chan MAVLink channel to send the message

+ 66 - 0
v2.0/common/mavlink_msg_gimbal_manager_set_attitude.h

@@ -103,6 +103,58 @@ static inline uint16_t mavlink_msg_gimbal_manager_set_attitude_pack(uint8_t syst
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_CRC);
 }
 
+/**
+ * @brief Pack a gimbal_manager_set_attitude message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID
+ * @param target_component  Component ID
+ * @param flags  High level gimbal manager flags to use.
+ * @param gimbal_device_id  Component ID of gimbal device to address (or 1-6 for non-MAVLink gimbal), 0 for all gimbal device components. Send command multiple times for more than one gimbal (but not all gimbals).
+ * @param q  Quaternion components, w, x, y, z (1 0 0 0 is the null-rotation, the frame is depends on whether the flag GIMBAL_MANAGER_FLAGS_YAW_LOCK is set)
+ * @param angular_velocity_x [rad/s] X component of angular velocity, positive is rolling to the right, NaN to be ignored.
+ * @param angular_velocity_y [rad/s] Y component of angular velocity, positive is pitching up, NaN to be ignored.
+ * @param angular_velocity_z [rad/s] Z component of angular velocity, positive is yawing to the right, NaN to be ignored.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gimbal_manager_set_attitude_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint32_t flags, uint8_t gimbal_device_id, const float *q, float angular_velocity_x, float angular_velocity_y, float angular_velocity_z)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_LEN];
+    _mav_put_uint32_t(buf, 0, flags);
+    _mav_put_float(buf, 20, angular_velocity_x);
+    _mav_put_float(buf, 24, angular_velocity_y);
+    _mav_put_float(buf, 28, angular_velocity_z);
+    _mav_put_uint8_t(buf, 32, target_system);
+    _mav_put_uint8_t(buf, 33, target_component);
+    _mav_put_uint8_t(buf, 34, gimbal_device_id);
+    _mav_put_float_array(buf, 4, q, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_LEN);
+#else
+    mavlink_gimbal_manager_set_attitude_t packet;
+    packet.flags = flags;
+    packet.angular_velocity_x = angular_velocity_x;
+    packet.angular_velocity_y = angular_velocity_y;
+    packet.angular_velocity_z = angular_velocity_z;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.gimbal_device_id = gimbal_device_id;
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_ATTITUDE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gimbal_manager_set_attitude message on a channel
  * @param system_id ID of this system
@@ -178,6 +230,20 @@ static inline uint16_t mavlink_msg_gimbal_manager_set_attitude_encode_chan(uint8
     return mavlink_msg_gimbal_manager_set_attitude_pack_chan(system_id, component_id, chan, msg, gimbal_manager_set_attitude->target_system, gimbal_manager_set_attitude->target_component, gimbal_manager_set_attitude->flags, gimbal_manager_set_attitude->gimbal_device_id, gimbal_manager_set_attitude->q, gimbal_manager_set_attitude->angular_velocity_x, gimbal_manager_set_attitude->angular_velocity_y, gimbal_manager_set_attitude->angular_velocity_z);
 }
 
+/**
+ * @brief Encode a gimbal_manager_set_attitude struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gimbal_manager_set_attitude C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gimbal_manager_set_attitude_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gimbal_manager_set_attitude_t* gimbal_manager_set_attitude)
+{
+    return mavlink_msg_gimbal_manager_set_attitude_pack_status(system_id, component_id, _status, msg,  gimbal_manager_set_attitude->target_system, gimbal_manager_set_attitude->target_component, gimbal_manager_set_attitude->flags, gimbal_manager_set_attitude->gimbal_device_id, gimbal_manager_set_attitude->q, gimbal_manager_set_attitude->angular_velocity_x, gimbal_manager_set_attitude->angular_velocity_y, gimbal_manager_set_attitude->angular_velocity_z);
+}
+
 /**
  * @brief Send a gimbal_manager_set_attitude message
  * @param chan MAVLink channel to send the message

+ 68 - 0
v2.0/common/mavlink_msg_gimbal_manager_set_manual_control.h

@@ -105,6 +105,60 @@ static inline uint16_t mavlink_msg_gimbal_manager_set_manual_control_pack(uint8_
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_CRC);
 }
 
+/**
+ * @brief Pack a gimbal_manager_set_manual_control message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID
+ * @param target_component  Component ID
+ * @param flags  High level gimbal manager flags.
+ * @param gimbal_device_id  Component ID of gimbal device to address (or 1-6 for non-MAVLink gimbal), 0 for all gimbal device components. Send command multiple times for more than one gimbal (but not all gimbals).
+ * @param pitch  Pitch angle unitless (-1..1, positive: up, negative: down, NaN to be ignored).
+ * @param yaw  Yaw angle unitless (-1..1, positive: to the right, negative: to the left, NaN to be ignored).
+ * @param pitch_rate  Pitch angular rate unitless (-1..1, positive: up, negative: down, NaN to be ignored).
+ * @param yaw_rate  Yaw angular rate unitless (-1..1, positive: to the right, negative: to the left, NaN to be ignored).
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gimbal_manager_set_manual_control_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint32_t flags, uint8_t gimbal_device_id, float pitch, float yaw, float pitch_rate, float yaw_rate)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_LEN];
+    _mav_put_uint32_t(buf, 0, flags);
+    _mav_put_float(buf, 4, pitch);
+    _mav_put_float(buf, 8, yaw);
+    _mav_put_float(buf, 12, pitch_rate);
+    _mav_put_float(buf, 16, yaw_rate);
+    _mav_put_uint8_t(buf, 20, target_system);
+    _mav_put_uint8_t(buf, 21, target_component);
+    _mav_put_uint8_t(buf, 22, gimbal_device_id);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_LEN);
+#else
+    mavlink_gimbal_manager_set_manual_control_t packet;
+    packet.flags = flags;
+    packet.pitch = pitch;
+    packet.yaw = yaw;
+    packet.pitch_rate = pitch_rate;
+    packet.yaw_rate = yaw_rate;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.gimbal_device_id = gimbal_device_id;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_MANUAL_CONTROL_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gimbal_manager_set_manual_control message on a channel
  * @param system_id ID of this system
@@ -182,6 +236,20 @@ static inline uint16_t mavlink_msg_gimbal_manager_set_manual_control_encode_chan
     return mavlink_msg_gimbal_manager_set_manual_control_pack_chan(system_id, component_id, chan, msg, gimbal_manager_set_manual_control->target_system, gimbal_manager_set_manual_control->target_component, gimbal_manager_set_manual_control->flags, gimbal_manager_set_manual_control->gimbal_device_id, gimbal_manager_set_manual_control->pitch, gimbal_manager_set_manual_control->yaw, gimbal_manager_set_manual_control->pitch_rate, gimbal_manager_set_manual_control->yaw_rate);
 }
 
+/**
+ * @brief Encode a gimbal_manager_set_manual_control struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gimbal_manager_set_manual_control C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gimbal_manager_set_manual_control_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gimbal_manager_set_manual_control_t* gimbal_manager_set_manual_control)
+{
+    return mavlink_msg_gimbal_manager_set_manual_control_pack_status(system_id, component_id, _status, msg,  gimbal_manager_set_manual_control->target_system, gimbal_manager_set_manual_control->target_component, gimbal_manager_set_manual_control->flags, gimbal_manager_set_manual_control->gimbal_device_id, gimbal_manager_set_manual_control->pitch, gimbal_manager_set_manual_control->yaw, gimbal_manager_set_manual_control->pitch_rate, gimbal_manager_set_manual_control->yaw_rate);
+}
+
 /**
  * @brief Send a gimbal_manager_set_manual_control message
  * @param chan MAVLink channel to send the message

+ 68 - 0
v2.0/common/mavlink_msg_gimbal_manager_set_pitchyaw.h

@@ -105,6 +105,60 @@ static inline uint16_t mavlink_msg_gimbal_manager_set_pitchyaw_pack(uint8_t syst
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_CRC);
 }
 
+/**
+ * @brief Pack a gimbal_manager_set_pitchyaw message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID
+ * @param target_component  Component ID
+ * @param flags  High level gimbal manager flags to use.
+ * @param gimbal_device_id  Component ID of gimbal device to address (or 1-6 for non-MAVLink gimbal), 0 for all gimbal device components. Send command multiple times for more than one gimbal (but not all gimbals).
+ * @param pitch [rad] Pitch angle (positive: up, negative: down, NaN to be ignored).
+ * @param yaw [rad] Yaw angle (positive: to the right, negative: to the left, NaN to be ignored).
+ * @param pitch_rate [rad/s] Pitch angular rate (positive: up, negative: down, NaN to be ignored).
+ * @param yaw_rate [rad/s] Yaw angular rate (positive: to the right, negative: to the left, NaN to be ignored).
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gimbal_manager_set_pitchyaw_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint32_t flags, uint8_t gimbal_device_id, float pitch, float yaw, float pitch_rate, float yaw_rate)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_LEN];
+    _mav_put_uint32_t(buf, 0, flags);
+    _mav_put_float(buf, 4, pitch);
+    _mav_put_float(buf, 8, yaw);
+    _mav_put_float(buf, 12, pitch_rate);
+    _mav_put_float(buf, 16, yaw_rate);
+    _mav_put_uint8_t(buf, 20, target_system);
+    _mav_put_uint8_t(buf, 21, target_component);
+    _mav_put_uint8_t(buf, 22, gimbal_device_id);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_LEN);
+#else
+    mavlink_gimbal_manager_set_pitchyaw_t packet;
+    packet.flags = flags;
+    packet.pitch = pitch;
+    packet.yaw = yaw;
+    packet.pitch_rate = pitch_rate;
+    packet.yaw_rate = yaw_rate;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.gimbal_device_id = gimbal_device_id;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_SET_PITCHYAW_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gimbal_manager_set_pitchyaw message on a channel
  * @param system_id ID of this system
@@ -182,6 +236,20 @@ static inline uint16_t mavlink_msg_gimbal_manager_set_pitchyaw_encode_chan(uint8
     return mavlink_msg_gimbal_manager_set_pitchyaw_pack_chan(system_id, component_id, chan, msg, gimbal_manager_set_pitchyaw->target_system, gimbal_manager_set_pitchyaw->target_component, gimbal_manager_set_pitchyaw->flags, gimbal_manager_set_pitchyaw->gimbal_device_id, gimbal_manager_set_pitchyaw->pitch, gimbal_manager_set_pitchyaw->yaw, gimbal_manager_set_pitchyaw->pitch_rate, gimbal_manager_set_pitchyaw->yaw_rate);
 }
 
+/**
+ * @brief Encode a gimbal_manager_set_pitchyaw struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gimbal_manager_set_pitchyaw C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gimbal_manager_set_pitchyaw_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gimbal_manager_set_pitchyaw_t* gimbal_manager_set_pitchyaw)
+{
+    return mavlink_msg_gimbal_manager_set_pitchyaw_pack_status(system_id, component_id, _status, msg,  gimbal_manager_set_pitchyaw->target_system, gimbal_manager_set_pitchyaw->target_component, gimbal_manager_set_pitchyaw->flags, gimbal_manager_set_pitchyaw->gimbal_device_id, gimbal_manager_set_pitchyaw->pitch, gimbal_manager_set_pitchyaw->yaw, gimbal_manager_set_pitchyaw->pitch_rate, gimbal_manager_set_pitchyaw->yaw_rate);
+}
+
 /**
  * @brief Send a gimbal_manager_set_pitchyaw message
  * @param chan MAVLink channel to send the message

+ 65 - 0
v2.0/common/mavlink_msg_gimbal_manager_status.h

@@ -99,6 +99,57 @@ static inline uint16_t mavlink_msg_gimbal_manager_status_pack(uint8_t system_id,
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a gimbal_manager_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param flags  High level gimbal manager flags currently applied.
+ * @param gimbal_device_id  Gimbal device ID that this gimbal manager is responsible for. Component ID of gimbal device (or 1-6 for non-MAVLink gimbal).
+ * @param primary_control_sysid  System ID of MAVLink component with primary control, 0 for none.
+ * @param primary_control_compid  Component ID of MAVLink component with primary control, 0 for none.
+ * @param secondary_control_sysid  System ID of MAVLink component with secondary control, 0 for none.
+ * @param secondary_control_compid  Component ID of MAVLink component with secondary control, 0 for none.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gimbal_manager_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, uint32_t flags, uint8_t gimbal_device_id, uint8_t primary_control_sysid, uint8_t primary_control_compid, uint8_t secondary_control_sysid, uint8_t secondary_control_compid)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_uint32_t(buf, 4, flags);
+    _mav_put_uint8_t(buf, 8, gimbal_device_id);
+    _mav_put_uint8_t(buf, 9, primary_control_sysid);
+    _mav_put_uint8_t(buf, 10, primary_control_compid);
+    _mav_put_uint8_t(buf, 11, secondary_control_sysid);
+    _mav_put_uint8_t(buf, 12, secondary_control_compid);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_LEN);
+#else
+    mavlink_gimbal_manager_status_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.flags = flags;
+    packet.gimbal_device_id = gimbal_device_id;
+    packet.primary_control_sysid = primary_control_sysid;
+    packet.primary_control_compid = primary_control_compid;
+    packet.secondary_control_sysid = secondary_control_sysid;
+    packet.secondary_control_compid = secondary_control_compid;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_MIN_LEN, MAVLINK_MSG_ID_GIMBAL_MANAGER_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gimbal_manager_status message on a channel
  * @param system_id ID of this system
@@ -173,6 +224,20 @@ static inline uint16_t mavlink_msg_gimbal_manager_status_encode_chan(uint8_t sys
     return mavlink_msg_gimbal_manager_status_pack_chan(system_id, component_id, chan, msg, gimbal_manager_status->time_boot_ms, gimbal_manager_status->flags, gimbal_manager_status->gimbal_device_id, gimbal_manager_status->primary_control_sysid, gimbal_manager_status->primary_control_compid, gimbal_manager_status->secondary_control_sysid, gimbal_manager_status->secondary_control_compid);
 }
 
+/**
+ * @brief Encode a gimbal_manager_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gimbal_manager_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gimbal_manager_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gimbal_manager_status_t* gimbal_manager_status)
+{
+    return mavlink_msg_gimbal_manager_status_pack_status(system_id, component_id, _status, msg,  gimbal_manager_status->time_boot_ms, gimbal_manager_status->flags, gimbal_manager_status->gimbal_device_id, gimbal_manager_status->primary_control_sysid, gimbal_manager_status->primary_control_compid, gimbal_manager_status->secondary_control_sysid, gimbal_manager_status->secondary_control_compid);
+}
+
 /**
  * @brief Send a gimbal_manager_status message
  * @param chan MAVLink channel to send the message

+ 71 - 0
v2.0/common/mavlink_msg_global_position_int.h

@@ -111,6 +111,63 @@ static inline uint16_t mavlink_msg_global_position_int_pack(uint8_t system_id, u
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_MIN_LEN, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_LEN, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_CRC);
 }
 
+/**
+ * @brief Pack a global_position_int message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_boot_ms [ms] Timestamp (time since system boot).
+ * @param lat [degE7] Latitude, expressed
+ * @param lon [degE7] Longitude, expressed
+ * @param alt [mm] Altitude (MSL). Note that virtually all GPS modules provide both WGS84 and MSL.
+ * @param relative_alt [mm] Altitude above ground
+ * @param vx [cm/s] Ground X Speed (Latitude, positive north)
+ * @param vy [cm/s] Ground Y Speed (Longitude, positive east)
+ * @param vz [cm/s] Ground Z Speed (Altitude, positive down)
+ * @param hdg [cdeg] Vehicle heading (yaw angle), 0.0..359.99 degrees. If unknown, set to: UINT16_MAX
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_global_position_int_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_boot_ms, int32_t lat, int32_t lon, int32_t alt, int32_t relative_alt, int16_t vx, int16_t vy, int16_t vz, uint16_t hdg)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GLOBAL_POSITION_INT_LEN];
+    _mav_put_uint32_t(buf, 0, time_boot_ms);
+    _mav_put_int32_t(buf, 4, lat);
+    _mav_put_int32_t(buf, 8, lon);
+    _mav_put_int32_t(buf, 12, alt);
+    _mav_put_int32_t(buf, 16, relative_alt);
+    _mav_put_int16_t(buf, 20, vx);
+    _mav_put_int16_t(buf, 22, vy);
+    _mav_put_int16_t(buf, 24, vz);
+    _mav_put_uint16_t(buf, 26, hdg);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_LEN);
+#else
+    mavlink_global_position_int_t packet;
+    packet.time_boot_ms = time_boot_ms;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.relative_alt = relative_alt;
+    packet.vx = vx;
+    packet.vy = vy;
+    packet.vz = vz;
+    packet.hdg = hdg;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GLOBAL_POSITION_INT;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_MIN_LEN, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_LEN, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_MIN_LEN, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_LEN);
+#endif
+}
+
 /**
  * @brief Pack a global_position_int message on a channel
  * @param system_id ID of this system
@@ -191,6 +248,20 @@ static inline uint16_t mavlink_msg_global_position_int_encode_chan(uint8_t syste
     return mavlink_msg_global_position_int_pack_chan(system_id, component_id, chan, msg, global_position_int->time_boot_ms, global_position_int->lat, global_position_int->lon, global_position_int->alt, global_position_int->relative_alt, global_position_int->vx, global_position_int->vy, global_position_int->vz, global_position_int->hdg);
 }
 
+/**
+ * @brief Encode a global_position_int struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param global_position_int C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_global_position_int_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_global_position_int_t* global_position_int)
+{
+    return mavlink_msg_global_position_int_pack_status(system_id, component_id, _status, msg,  global_position_int->time_boot_ms, global_position_int->lat, global_position_int->lon, global_position_int->alt, global_position_int->relative_alt, global_position_int->vx, global_position_int->vy, global_position_int->vz, global_position_int->hdg);
+}
+
 /**
  * @brief Send a global_position_int message
  * @param chan MAVLink channel to send the message

+ 72 - 0
v2.0/common/mavlink_msg_global_position_int_cov.h

@@ -115,6 +115,64 @@ static inline uint16_t mavlink_msg_global_position_int_cov_pack(uint8_t system_i
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_MIN_LEN, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_LEN, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_CRC);
 }
 
+/**
+ * @brief Pack a global_position_int_cov message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param estimator_type  Class id of the estimator this estimate originated from.
+ * @param lat [degE7] Latitude
+ * @param lon [degE7] Longitude
+ * @param alt [mm] Altitude in meters above MSL
+ * @param relative_alt [mm] Altitude above ground
+ * @param vx [m/s] Ground X Speed (Latitude)
+ * @param vy [m/s] Ground Y Speed (Longitude)
+ * @param vz [m/s] Ground Z Speed (Altitude)
+ * @param covariance  Row-major representation of a 6x6 position and velocity 6x6 cross-covariance matrix (states: lat, lon, alt, vx, vy, vz; first six entries are the first ROW, next six entries are the second row, etc.). If unknown, assign NaN value to first element in the array.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_global_position_int_cov_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint8_t estimator_type, int32_t lat, int32_t lon, int32_t alt, int32_t relative_alt, float vx, float vy, float vz, const float *covariance)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_int32_t(buf, 8, lat);
+    _mav_put_int32_t(buf, 12, lon);
+    _mav_put_int32_t(buf, 16, alt);
+    _mav_put_int32_t(buf, 20, relative_alt);
+    _mav_put_float(buf, 24, vx);
+    _mav_put_float(buf, 28, vy);
+    _mav_put_float(buf, 32, vz);
+    _mav_put_uint8_t(buf, 180, estimator_type);
+    _mav_put_float_array(buf, 36, covariance, 36);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_LEN);
+#else
+    mavlink_global_position_int_cov_t packet;
+    packet.time_usec = time_usec;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.relative_alt = relative_alt;
+    packet.vx = vx;
+    packet.vy = vy;
+    packet.vz = vz;
+    packet.estimator_type = estimator_type;
+    mav_array_memcpy(packet.covariance, covariance, sizeof(float)*36);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_MIN_LEN, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_LEN, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_MIN_LEN, MAVLINK_MSG_ID_GLOBAL_POSITION_INT_COV_LEN);
+#endif
+}
+
 /**
  * @brief Pack a global_position_int_cov message on a channel
  * @param system_id ID of this system
@@ -196,6 +254,20 @@ static inline uint16_t mavlink_msg_global_position_int_cov_encode_chan(uint8_t s
     return mavlink_msg_global_position_int_cov_pack_chan(system_id, component_id, chan, msg, global_position_int_cov->time_usec, global_position_int_cov->estimator_type, global_position_int_cov->lat, global_position_int_cov->lon, global_position_int_cov->alt, global_position_int_cov->relative_alt, global_position_int_cov->vx, global_position_int_cov->vy, global_position_int_cov->vz, global_position_int_cov->covariance);
 }
 
+/**
+ * @brief Encode a global_position_int_cov struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param global_position_int_cov C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_global_position_int_cov_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_global_position_int_cov_t* global_position_int_cov)
+{
+    return mavlink_msg_global_position_int_cov_pack_status(system_id, component_id, _status, msg,  global_position_int_cov->time_usec, global_position_int_cov->estimator_type, global_position_int_cov->lat, global_position_int_cov->lon, global_position_int_cov->alt, global_position_int_cov->relative_alt, global_position_int_cov->vx, global_position_int_cov->vy, global_position_int_cov->vz, global_position_int_cov->covariance);
+}
+
 /**
  * @brief Send a global_position_int_cov message
  * @param chan MAVLink channel to send the message

+ 69 - 0
v2.0/common/mavlink_msg_global_vision_position_estimate.h

@@ -109,6 +109,61 @@ static inline uint16_t mavlink_msg_global_vision_position_estimate_pack(uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_MIN_LEN, MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_LEN, MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_CRC);
 }
 
+/**
+ * @brief Pack a global_vision_position_estimate message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param usec [us] Timestamp (UNIX time or since system boot)
+ * @param x [m] Global X position
+ * @param y [m] Global Y position
+ * @param z [m] Global Z position
+ * @param roll [rad] Roll angle
+ * @param pitch [rad] Pitch angle
+ * @param yaw [rad] Yaw angle
+ * @param covariance  Row-major representation of pose 6x6 cross-covariance matrix upper right triangle (states: x_global, y_global, z_global, roll, pitch, yaw; first six entries are the first ROW, next five entries are the second ROW, etc.). If unknown, assign NaN value to first element in the array.
+ * @param reset_counter  Estimate reset counter. This should be incremented when the estimate resets in any of the dimensions (position, velocity, attitude, angular speed). This is designed to be used when e.g an external SLAM system detects a loop-closure and the estimate jumps.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_global_vision_position_estimate_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t usec, float x, float y, float z, float roll, float pitch, float yaw, const float *covariance, uint8_t reset_counter)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_LEN];
+    _mav_put_uint64_t(buf, 0, usec);
+    _mav_put_float(buf, 8, x);
+    _mav_put_float(buf, 12, y);
+    _mav_put_float(buf, 16, z);
+    _mav_put_float(buf, 20, roll);
+    _mav_put_float(buf, 24, pitch);
+    _mav_put_float(buf, 28, yaw);
+    _mav_put_uint8_t(buf, 116, reset_counter);
+    _mav_put_float_array(buf, 32, covariance, 21);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_LEN);
+#else
+    mavlink_global_vision_position_estimate_t packet;
+    packet.usec = usec;
+    packet.x = x;
+    packet.y = y;
+    packet.z = z;
+    packet.roll = roll;
+    packet.pitch = pitch;
+    packet.yaw = yaw;
+    packet.reset_counter = reset_counter;
+    mav_array_memcpy(packet.covariance, covariance, sizeof(float)*21);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_MIN_LEN, MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_LEN, MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_MIN_LEN, MAVLINK_MSG_ID_GLOBAL_VISION_POSITION_ESTIMATE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a global_vision_position_estimate message on a channel
  * @param system_id ID of this system
@@ -187,6 +242,20 @@ static inline uint16_t mavlink_msg_global_vision_position_estimate_encode_chan(u
     return mavlink_msg_global_vision_position_estimate_pack_chan(system_id, component_id, chan, msg, global_vision_position_estimate->usec, global_vision_position_estimate->x, global_vision_position_estimate->y, global_vision_position_estimate->z, global_vision_position_estimate->roll, global_vision_position_estimate->pitch, global_vision_position_estimate->yaw, global_vision_position_estimate->covariance, global_vision_position_estimate->reset_counter);
 }
 
+/**
+ * @brief Encode a global_vision_position_estimate struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param global_vision_position_estimate C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_global_vision_position_estimate_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_global_vision_position_estimate_t* global_vision_position_estimate)
+{
+    return mavlink_msg_global_vision_position_estimate_pack_status(system_id, component_id, _status, msg,  global_vision_position_estimate->usec, global_vision_position_estimate->x, global_vision_position_estimate->y, global_vision_position_estimate->z, global_vision_position_estimate->roll, global_vision_position_estimate->pitch, global_vision_position_estimate->yaw, global_vision_position_estimate->covariance, global_vision_position_estimate->reset_counter);
+}
+
 /**
  * @brief Send a global_vision_position_estimate message
  * @param chan MAVLink channel to send the message

+ 98 - 0
v2.0/common/mavlink_msg_gps2_raw.h

@@ -165,6 +165,90 @@ static inline uint16_t mavlink_msg_gps2_raw_pack(uint8_t system_id, uint8_t comp
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GPS2_RAW_MIN_LEN, MAVLINK_MSG_ID_GPS2_RAW_LEN, MAVLINK_MSG_ID_GPS2_RAW_CRC);
 }
 
+/**
+ * @brief Pack a gps2_raw message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param fix_type  GPS fix type.
+ * @param lat [degE7] Latitude (WGS84)
+ * @param lon [degE7] Longitude (WGS84)
+ * @param alt [mm] Altitude (MSL). Positive for up.
+ * @param eph  GPS HDOP horizontal dilution of position (unitless * 100). If unknown, set to: UINT16_MAX
+ * @param epv  GPS VDOP vertical dilution of position (unitless * 100). If unknown, set to: UINT16_MAX
+ * @param vel [cm/s] GPS ground speed. If unknown, set to: UINT16_MAX
+ * @param cog [cdeg] Course over ground (NOT heading, but direction of movement): 0.0..359.99 degrees. If unknown, set to: UINT16_MAX
+ * @param satellites_visible  Number of satellites visible. If unknown, set to UINT8_MAX
+ * @param dgps_numch  Number of DGPS satellites
+ * @param dgps_age [ms] Age of DGPS info
+ * @param yaw [cdeg] Yaw in earth frame from north. Use 0 if this GPS does not provide yaw. Use UINT16_MAX if this GPS is configured to provide yaw and is currently unable to provide it. Use 36000 for north.
+ * @param alt_ellipsoid [mm] Altitude (above WGS84, EGM96 ellipsoid). Positive for up.
+ * @param h_acc [mm] Position uncertainty.
+ * @param v_acc [mm] Altitude uncertainty.
+ * @param vel_acc [mm] Speed uncertainty.
+ * @param hdg_acc [degE5] Heading / track uncertainty
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gps2_raw_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint8_t fix_type, int32_t lat, int32_t lon, int32_t alt, uint16_t eph, uint16_t epv, uint16_t vel, uint16_t cog, uint8_t satellites_visible, uint8_t dgps_numch, uint32_t dgps_age, uint16_t yaw, int32_t alt_ellipsoid, uint32_t h_acc, uint32_t v_acc, uint32_t vel_acc, uint32_t hdg_acc)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GPS2_RAW_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_int32_t(buf, 8, lat);
+    _mav_put_int32_t(buf, 12, lon);
+    _mav_put_int32_t(buf, 16, alt);
+    _mav_put_uint32_t(buf, 20, dgps_age);
+    _mav_put_uint16_t(buf, 24, eph);
+    _mav_put_uint16_t(buf, 26, epv);
+    _mav_put_uint16_t(buf, 28, vel);
+    _mav_put_uint16_t(buf, 30, cog);
+    _mav_put_uint8_t(buf, 32, fix_type);
+    _mav_put_uint8_t(buf, 33, satellites_visible);
+    _mav_put_uint8_t(buf, 34, dgps_numch);
+    _mav_put_uint16_t(buf, 35, yaw);
+    _mav_put_int32_t(buf, 37, alt_ellipsoid);
+    _mav_put_uint32_t(buf, 41, h_acc);
+    _mav_put_uint32_t(buf, 45, v_acc);
+    _mav_put_uint32_t(buf, 49, vel_acc);
+    _mav_put_uint32_t(buf, 53, hdg_acc);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GPS2_RAW_LEN);
+#else
+    mavlink_gps2_raw_t packet;
+    packet.time_usec = time_usec;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.dgps_age = dgps_age;
+    packet.eph = eph;
+    packet.epv = epv;
+    packet.vel = vel;
+    packet.cog = cog;
+    packet.fix_type = fix_type;
+    packet.satellites_visible = satellites_visible;
+    packet.dgps_numch = dgps_numch;
+    packet.yaw = yaw;
+    packet.alt_ellipsoid = alt_ellipsoid;
+    packet.h_acc = h_acc;
+    packet.v_acc = v_acc;
+    packet.vel_acc = vel_acc;
+    packet.hdg_acc = hdg_acc;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GPS2_RAW_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GPS2_RAW;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS2_RAW_MIN_LEN, MAVLINK_MSG_ID_GPS2_RAW_LEN, MAVLINK_MSG_ID_GPS2_RAW_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS2_RAW_MIN_LEN, MAVLINK_MSG_ID_GPS2_RAW_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gps2_raw message on a channel
  * @param system_id ID of this system
@@ -272,6 +356,20 @@ static inline uint16_t mavlink_msg_gps2_raw_encode_chan(uint8_t system_id, uint8
     return mavlink_msg_gps2_raw_pack_chan(system_id, component_id, chan, msg, gps2_raw->time_usec, gps2_raw->fix_type, gps2_raw->lat, gps2_raw->lon, gps2_raw->alt, gps2_raw->eph, gps2_raw->epv, gps2_raw->vel, gps2_raw->cog, gps2_raw->satellites_visible, gps2_raw->dgps_numch, gps2_raw->dgps_age, gps2_raw->yaw, gps2_raw->alt_ellipsoid, gps2_raw->h_acc, gps2_raw->v_acc, gps2_raw->vel_acc, gps2_raw->hdg_acc);
 }
 
+/**
+ * @brief Encode a gps2_raw struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gps2_raw C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gps2_raw_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gps2_raw_t* gps2_raw)
+{
+    return mavlink_msg_gps2_raw_pack_status(system_id, component_id, _status, msg,  gps2_raw->time_usec, gps2_raw->fix_type, gps2_raw->lat, gps2_raw->lon, gps2_raw->alt, gps2_raw->eph, gps2_raw->epv, gps2_raw->vel, gps2_raw->cog, gps2_raw->satellites_visible, gps2_raw->dgps_numch, gps2_raw->dgps_age, gps2_raw->yaw, gps2_raw->alt_ellipsoid, gps2_raw->h_acc, gps2_raw->v_acc, gps2_raw->vel_acc, gps2_raw->hdg_acc);
+}
+
 /**
  * @brief Send a gps2_raw message
  * @param chan MAVLink channel to send the message

+ 83 - 0
v2.0/common/mavlink_msg_gps2_rtk.h

@@ -135,6 +135,75 @@ static inline uint16_t mavlink_msg_gps2_rtk_pack(uint8_t system_id, uint8_t comp
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GPS2_RTK_MIN_LEN, MAVLINK_MSG_ID_GPS2_RTK_LEN, MAVLINK_MSG_ID_GPS2_RTK_CRC);
 }
 
+/**
+ * @brief Pack a gps2_rtk message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_last_baseline_ms [ms] Time since boot of last baseline message received.
+ * @param rtk_receiver_id  Identification of connected RTK receiver.
+ * @param wn  GPS Week Number of last baseline
+ * @param tow [ms] GPS Time of Week of last baseline
+ * @param rtk_health  GPS-specific health report for RTK data.
+ * @param rtk_rate [Hz] Rate of baseline messages being received by GPS
+ * @param nsats  Current number of sats used for RTK calculation.
+ * @param baseline_coords_type  Coordinate system of baseline
+ * @param baseline_a_mm [mm] Current baseline in ECEF x or NED north component.
+ * @param baseline_b_mm [mm] Current baseline in ECEF y or NED east component.
+ * @param baseline_c_mm [mm] Current baseline in ECEF z or NED down component.
+ * @param accuracy  Current estimate of baseline accuracy.
+ * @param iar_num_hypotheses  Current number of integer ambiguity hypotheses.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gps2_rtk_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_last_baseline_ms, uint8_t rtk_receiver_id, uint16_t wn, uint32_t tow, uint8_t rtk_health, uint8_t rtk_rate, uint8_t nsats, uint8_t baseline_coords_type, int32_t baseline_a_mm, int32_t baseline_b_mm, int32_t baseline_c_mm, uint32_t accuracy, int32_t iar_num_hypotheses)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GPS2_RTK_LEN];
+    _mav_put_uint32_t(buf, 0, time_last_baseline_ms);
+    _mav_put_uint32_t(buf, 4, tow);
+    _mav_put_int32_t(buf, 8, baseline_a_mm);
+    _mav_put_int32_t(buf, 12, baseline_b_mm);
+    _mav_put_int32_t(buf, 16, baseline_c_mm);
+    _mav_put_uint32_t(buf, 20, accuracy);
+    _mav_put_int32_t(buf, 24, iar_num_hypotheses);
+    _mav_put_uint16_t(buf, 28, wn);
+    _mav_put_uint8_t(buf, 30, rtk_receiver_id);
+    _mav_put_uint8_t(buf, 31, rtk_health);
+    _mav_put_uint8_t(buf, 32, rtk_rate);
+    _mav_put_uint8_t(buf, 33, nsats);
+    _mav_put_uint8_t(buf, 34, baseline_coords_type);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GPS2_RTK_LEN);
+#else
+    mavlink_gps2_rtk_t packet;
+    packet.time_last_baseline_ms = time_last_baseline_ms;
+    packet.tow = tow;
+    packet.baseline_a_mm = baseline_a_mm;
+    packet.baseline_b_mm = baseline_b_mm;
+    packet.baseline_c_mm = baseline_c_mm;
+    packet.accuracy = accuracy;
+    packet.iar_num_hypotheses = iar_num_hypotheses;
+    packet.wn = wn;
+    packet.rtk_receiver_id = rtk_receiver_id;
+    packet.rtk_health = rtk_health;
+    packet.rtk_rate = rtk_rate;
+    packet.nsats = nsats;
+    packet.baseline_coords_type = baseline_coords_type;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GPS2_RTK_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GPS2_RTK;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS2_RTK_MIN_LEN, MAVLINK_MSG_ID_GPS2_RTK_LEN, MAVLINK_MSG_ID_GPS2_RTK_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS2_RTK_MIN_LEN, MAVLINK_MSG_ID_GPS2_RTK_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gps2_rtk message on a channel
  * @param system_id ID of this system
@@ -227,6 +296,20 @@ static inline uint16_t mavlink_msg_gps2_rtk_encode_chan(uint8_t system_id, uint8
     return mavlink_msg_gps2_rtk_pack_chan(system_id, component_id, chan, msg, gps2_rtk->time_last_baseline_ms, gps2_rtk->rtk_receiver_id, gps2_rtk->wn, gps2_rtk->tow, gps2_rtk->rtk_health, gps2_rtk->rtk_rate, gps2_rtk->nsats, gps2_rtk->baseline_coords_type, gps2_rtk->baseline_a_mm, gps2_rtk->baseline_b_mm, gps2_rtk->baseline_c_mm, gps2_rtk->accuracy, gps2_rtk->iar_num_hypotheses);
 }
 
+/**
+ * @brief Encode a gps2_rtk struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gps2_rtk C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gps2_rtk_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gps2_rtk_t* gps2_rtk)
+{
+    return mavlink_msg_gps2_rtk_pack_status(system_id, component_id, _status, msg,  gps2_rtk->time_last_baseline_ms, gps2_rtk->rtk_receiver_id, gps2_rtk->wn, gps2_rtk->tow, gps2_rtk->rtk_health, gps2_rtk->rtk_rate, gps2_rtk->nsats, gps2_rtk->baseline_coords_type, gps2_rtk->baseline_a_mm, gps2_rtk->baseline_b_mm, gps2_rtk->baseline_c_mm, gps2_rtk->accuracy, gps2_rtk->iar_num_hypotheses);
+}
+
 /**
  * @brief Send a gps2_rtk message
  * @param chan MAVLink channel to send the message

+ 56 - 0
v2.0/common/mavlink_msg_gps_global_origin.h

@@ -81,6 +81,48 @@ static inline uint16_t mavlink_msg_gps_global_origin_pack(uint8_t system_id, uin
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_MIN_LEN, MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_LEN, MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_CRC);
 }
 
+/**
+ * @brief Pack a gps_global_origin message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param latitude [degE7] Latitude (WGS84)
+ * @param longitude [degE7] Longitude (WGS84)
+ * @param altitude [mm] Altitude (MSL). Positive for up.
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gps_global_origin_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               int32_t latitude, int32_t longitude, int32_t altitude, uint64_t time_usec)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_LEN];
+    _mav_put_int32_t(buf, 0, latitude);
+    _mav_put_int32_t(buf, 4, longitude);
+    _mav_put_int32_t(buf, 8, altitude);
+    _mav_put_uint64_t(buf, 12, time_usec);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_LEN);
+#else
+    mavlink_gps_global_origin_t packet;
+    packet.latitude = latitude;
+    packet.longitude = longitude;
+    packet.altitude = altitude;
+    packet.time_usec = time_usec;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_MIN_LEN, MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_LEN, MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_MIN_LEN, MAVLINK_MSG_ID_GPS_GLOBAL_ORIGIN_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gps_global_origin message on a channel
  * @param system_id ID of this system
@@ -146,6 +188,20 @@ static inline uint16_t mavlink_msg_gps_global_origin_encode_chan(uint8_t system_
     return mavlink_msg_gps_global_origin_pack_chan(system_id, component_id, chan, msg, gps_global_origin->latitude, gps_global_origin->longitude, gps_global_origin->altitude, gps_global_origin->time_usec);
 }
 
+/**
+ * @brief Encode a gps_global_origin struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gps_global_origin C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gps_global_origin_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gps_global_origin_t* gps_global_origin)
+{
+    return mavlink_msg_gps_global_origin_pack_status(system_id, component_id, _status, msg,  gps_global_origin->latitude, gps_global_origin->longitude, gps_global_origin->altitude, gps_global_origin->time_usec);
+}
+
 /**
  * @brief Send a gps_global_origin message
  * @param chan MAVLink channel to send the message

+ 54 - 0
v2.0/common/mavlink_msg_gps_inject_data.h

@@ -79,6 +79,46 @@ static inline uint16_t mavlink_msg_gps_inject_data_pack(uint8_t system_id, uint8
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GPS_INJECT_DATA_MIN_LEN, MAVLINK_MSG_ID_GPS_INJECT_DATA_LEN, MAVLINK_MSG_ID_GPS_INJECT_DATA_CRC);
 }
 
+/**
+ * @brief Pack a gps_inject_data message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param target_system  System ID
+ * @param target_component  Component ID
+ * @param len [bytes] Data length
+ * @param data  Raw data (110 is enough for 12 satellites of RTCMv2)
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gps_inject_data_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t target_system, uint8_t target_component, uint8_t len, const uint8_t *data)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GPS_INJECT_DATA_LEN];
+    _mav_put_uint8_t(buf, 0, target_system);
+    _mav_put_uint8_t(buf, 1, target_component);
+    _mav_put_uint8_t(buf, 2, len);
+    _mav_put_uint8_t_array(buf, 3, data, 110);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GPS_INJECT_DATA_LEN);
+#else
+    mavlink_gps_inject_data_t packet;
+    packet.target_system = target_system;
+    packet.target_component = target_component;
+    packet.len = len;
+    mav_array_memcpy(packet.data, data, sizeof(uint8_t)*110);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GPS_INJECT_DATA_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GPS_INJECT_DATA;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_INJECT_DATA_MIN_LEN, MAVLINK_MSG_ID_GPS_INJECT_DATA_LEN, MAVLINK_MSG_ID_GPS_INJECT_DATA_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_INJECT_DATA_MIN_LEN, MAVLINK_MSG_ID_GPS_INJECT_DATA_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gps_inject_data message on a channel
  * @param system_id ID of this system
@@ -142,6 +182,20 @@ static inline uint16_t mavlink_msg_gps_inject_data_encode_chan(uint8_t system_id
     return mavlink_msg_gps_inject_data_pack_chan(system_id, component_id, chan, msg, gps_inject_data->target_system, gps_inject_data->target_component, gps_inject_data->len, gps_inject_data->data);
 }
 
+/**
+ * @brief Encode a gps_inject_data struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gps_inject_data C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gps_inject_data_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gps_inject_data_t* gps_inject_data)
+{
+    return mavlink_msg_gps_inject_data_pack_status(system_id, component_id, _status, msg,  gps_inject_data->target_system, gps_inject_data->target_component, gps_inject_data->len, gps_inject_data->data);
+}
+
 /**
  * @brief Send a gps_inject_data message
  * @param chan MAVLink channel to send the message

+ 101 - 0
v2.0/common/mavlink_msg_gps_input.h

@@ -171,6 +171,93 @@ static inline uint16_t mavlink_msg_gps_input_pack(uint8_t system_id, uint8_t com
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GPS_INPUT_MIN_LEN, MAVLINK_MSG_ID_GPS_INPUT_LEN, MAVLINK_MSG_ID_GPS_INPUT_CRC);
 }
 
+/**
+ * @brief Pack a gps_input message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param gps_id  ID of the GPS for multiple GPS inputs
+ * @param ignore_flags  Bitmap indicating which GPS input flags fields to ignore.  All other fields must be provided.
+ * @param time_week_ms [ms] GPS time (from start of GPS week)
+ * @param time_week  GPS week number
+ * @param fix_type  0-1: no fix, 2: 2D fix, 3: 3D fix. 4: 3D with DGPS. 5: 3D with RTK
+ * @param lat [degE7] Latitude (WGS84)
+ * @param lon [degE7] Longitude (WGS84)
+ * @param alt [m] Altitude (MSL). Positive for up.
+ * @param hdop  GPS HDOP horizontal dilution of position (unitless). If unknown, set to: UINT16_MAX
+ * @param vdop  GPS VDOP vertical dilution of position (unitless). If unknown, set to: UINT16_MAX
+ * @param vn [m/s] GPS velocity in north direction in earth-fixed NED frame
+ * @param ve [m/s] GPS velocity in east direction in earth-fixed NED frame
+ * @param vd [m/s] GPS velocity in down direction in earth-fixed NED frame
+ * @param speed_accuracy [m/s] GPS speed accuracy
+ * @param horiz_accuracy [m] GPS horizontal accuracy
+ * @param vert_accuracy [m] GPS vertical accuracy
+ * @param satellites_visible  Number of satellites visible.
+ * @param yaw [cdeg] Yaw of vehicle relative to Earth's North, zero means not available, use 36000 for north
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gps_input_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint8_t gps_id, uint16_t ignore_flags, uint32_t time_week_ms, uint16_t time_week, uint8_t fix_type, int32_t lat, int32_t lon, float alt, float hdop, float vdop, float vn, float ve, float vd, float speed_accuracy, float horiz_accuracy, float vert_accuracy, uint8_t satellites_visible, uint16_t yaw)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GPS_INPUT_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_uint32_t(buf, 8, time_week_ms);
+    _mav_put_int32_t(buf, 12, lat);
+    _mav_put_int32_t(buf, 16, lon);
+    _mav_put_float(buf, 20, alt);
+    _mav_put_float(buf, 24, hdop);
+    _mav_put_float(buf, 28, vdop);
+    _mav_put_float(buf, 32, vn);
+    _mav_put_float(buf, 36, ve);
+    _mav_put_float(buf, 40, vd);
+    _mav_put_float(buf, 44, speed_accuracy);
+    _mav_put_float(buf, 48, horiz_accuracy);
+    _mav_put_float(buf, 52, vert_accuracy);
+    _mav_put_uint16_t(buf, 56, ignore_flags);
+    _mav_put_uint16_t(buf, 58, time_week);
+    _mav_put_uint8_t(buf, 60, gps_id);
+    _mav_put_uint8_t(buf, 61, fix_type);
+    _mav_put_uint8_t(buf, 62, satellites_visible);
+    _mav_put_uint16_t(buf, 63, yaw);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GPS_INPUT_LEN);
+#else
+    mavlink_gps_input_t packet;
+    packet.time_usec = time_usec;
+    packet.time_week_ms = time_week_ms;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.hdop = hdop;
+    packet.vdop = vdop;
+    packet.vn = vn;
+    packet.ve = ve;
+    packet.vd = vd;
+    packet.speed_accuracy = speed_accuracy;
+    packet.horiz_accuracy = horiz_accuracy;
+    packet.vert_accuracy = vert_accuracy;
+    packet.ignore_flags = ignore_flags;
+    packet.time_week = time_week;
+    packet.gps_id = gps_id;
+    packet.fix_type = fix_type;
+    packet.satellites_visible = satellites_visible;
+    packet.yaw = yaw;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GPS_INPUT_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GPS_INPUT;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_INPUT_MIN_LEN, MAVLINK_MSG_ID_GPS_INPUT_LEN, MAVLINK_MSG_ID_GPS_INPUT_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_INPUT_MIN_LEN, MAVLINK_MSG_ID_GPS_INPUT_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gps_input message on a channel
  * @param system_id ID of this system
@@ -281,6 +368,20 @@ static inline uint16_t mavlink_msg_gps_input_encode_chan(uint8_t system_id, uint
     return mavlink_msg_gps_input_pack_chan(system_id, component_id, chan, msg, gps_input->time_usec, gps_input->gps_id, gps_input->ignore_flags, gps_input->time_week_ms, gps_input->time_week, gps_input->fix_type, gps_input->lat, gps_input->lon, gps_input->alt, gps_input->hdop, gps_input->vdop, gps_input->vn, gps_input->ve, gps_input->vd, gps_input->speed_accuracy, gps_input->horiz_accuracy, gps_input->vert_accuracy, gps_input->satellites_visible, gps_input->yaw);
 }
 
+/**
+ * @brief Encode a gps_input struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gps_input C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gps_input_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gps_input_t* gps_input)
+{
+    return mavlink_msg_gps_input_pack_status(system_id, component_id, _status, msg,  gps_input->time_usec, gps_input->gps_id, gps_input->ignore_flags, gps_input->time_week_ms, gps_input->time_week, gps_input->fix_type, gps_input->lat, gps_input->lon, gps_input->alt, gps_input->hdop, gps_input->vdop, gps_input->vn, gps_input->ve, gps_input->vd, gps_input->speed_accuracy, gps_input->horiz_accuracy, gps_input->vert_accuracy, gps_input->satellites_visible, gps_input->yaw);
+}
+
 /**
  * @brief Send a gps_input message
  * @param chan MAVLink channel to send the message

+ 92 - 0
v2.0/common/mavlink_msg_gps_raw_int.h

@@ -153,6 +153,84 @@ static inline uint16_t mavlink_msg_gps_raw_int_pack(uint8_t system_id, uint8_t c
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GPS_RAW_INT_MIN_LEN, MAVLINK_MSG_ID_GPS_RAW_INT_LEN, MAVLINK_MSG_ID_GPS_RAW_INT_CRC);
 }
 
+/**
+ * @brief Pack a gps_raw_int message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param fix_type  GPS fix type.
+ * @param lat [degE7] Latitude (WGS84, EGM96 ellipsoid)
+ * @param lon [degE7] Longitude (WGS84, EGM96 ellipsoid)
+ * @param alt [mm] Altitude (MSL). Positive for up. Note that virtually all GPS modules provide the MSL altitude in addition to the WGS84 altitude.
+ * @param eph  GPS HDOP horizontal dilution of position (unitless * 100). If unknown, set to: UINT16_MAX
+ * @param epv  GPS VDOP vertical dilution of position (unitless * 100). If unknown, set to: UINT16_MAX
+ * @param vel [cm/s] GPS ground speed. If unknown, set to: UINT16_MAX
+ * @param cog [cdeg] Course over ground (NOT heading, but direction of movement) in degrees * 100, 0.0..359.99 degrees. If unknown, set to: UINT16_MAX
+ * @param satellites_visible  Number of satellites visible. If unknown, set to UINT8_MAX
+ * @param alt_ellipsoid [mm] Altitude (above WGS84, EGM96 ellipsoid). Positive for up.
+ * @param h_acc [mm] Position uncertainty.
+ * @param v_acc [mm] Altitude uncertainty.
+ * @param vel_acc [mm] Speed uncertainty.
+ * @param hdg_acc [degE5] Heading / track uncertainty
+ * @param yaw [cdeg] Yaw in earth frame from north. Use 0 if this GPS does not provide yaw. Use UINT16_MAX if this GPS is configured to provide yaw and is currently unable to provide it. Use 36000 for north.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gps_raw_int_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint8_t fix_type, int32_t lat, int32_t lon, int32_t alt, uint16_t eph, uint16_t epv, uint16_t vel, uint16_t cog, uint8_t satellites_visible, int32_t alt_ellipsoid, uint32_t h_acc, uint32_t v_acc, uint32_t vel_acc, uint32_t hdg_acc, uint16_t yaw)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GPS_RAW_INT_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_int32_t(buf, 8, lat);
+    _mav_put_int32_t(buf, 12, lon);
+    _mav_put_int32_t(buf, 16, alt);
+    _mav_put_uint16_t(buf, 20, eph);
+    _mav_put_uint16_t(buf, 22, epv);
+    _mav_put_uint16_t(buf, 24, vel);
+    _mav_put_uint16_t(buf, 26, cog);
+    _mav_put_uint8_t(buf, 28, fix_type);
+    _mav_put_uint8_t(buf, 29, satellites_visible);
+    _mav_put_int32_t(buf, 30, alt_ellipsoid);
+    _mav_put_uint32_t(buf, 34, h_acc);
+    _mav_put_uint32_t(buf, 38, v_acc);
+    _mav_put_uint32_t(buf, 42, vel_acc);
+    _mav_put_uint32_t(buf, 46, hdg_acc);
+    _mav_put_uint16_t(buf, 50, yaw);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GPS_RAW_INT_LEN);
+#else
+    mavlink_gps_raw_int_t packet;
+    packet.time_usec = time_usec;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.eph = eph;
+    packet.epv = epv;
+    packet.vel = vel;
+    packet.cog = cog;
+    packet.fix_type = fix_type;
+    packet.satellites_visible = satellites_visible;
+    packet.alt_ellipsoid = alt_ellipsoid;
+    packet.h_acc = h_acc;
+    packet.v_acc = v_acc;
+    packet.vel_acc = vel_acc;
+    packet.hdg_acc = hdg_acc;
+    packet.yaw = yaw;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GPS_RAW_INT_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GPS_RAW_INT;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_RAW_INT_MIN_LEN, MAVLINK_MSG_ID_GPS_RAW_INT_LEN, MAVLINK_MSG_ID_GPS_RAW_INT_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_RAW_INT_MIN_LEN, MAVLINK_MSG_ID_GPS_RAW_INT_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gps_raw_int message on a channel
  * @param system_id ID of this system
@@ -254,6 +332,20 @@ static inline uint16_t mavlink_msg_gps_raw_int_encode_chan(uint8_t system_id, ui
     return mavlink_msg_gps_raw_int_pack_chan(system_id, component_id, chan, msg, gps_raw_int->time_usec, gps_raw_int->fix_type, gps_raw_int->lat, gps_raw_int->lon, gps_raw_int->alt, gps_raw_int->eph, gps_raw_int->epv, gps_raw_int->vel, gps_raw_int->cog, gps_raw_int->satellites_visible, gps_raw_int->alt_ellipsoid, gps_raw_int->h_acc, gps_raw_int->v_acc, gps_raw_int->vel_acc, gps_raw_int->hdg_acc, gps_raw_int->yaw);
 }
 
+/**
+ * @brief Encode a gps_raw_int struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gps_raw_int C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gps_raw_int_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gps_raw_int_t* gps_raw_int)
+{
+    return mavlink_msg_gps_raw_int_pack_status(system_id, component_id, _status, msg,  gps_raw_int->time_usec, gps_raw_int->fix_type, gps_raw_int->lat, gps_raw_int->lon, gps_raw_int->alt, gps_raw_int->eph, gps_raw_int->epv, gps_raw_int->vel, gps_raw_int->cog, gps_raw_int->satellites_visible, gps_raw_int->alt_ellipsoid, gps_raw_int->h_acc, gps_raw_int->v_acc, gps_raw_int->vel_acc, gps_raw_int->hdg_acc, gps_raw_int->yaw);
+}
+
 /**
  * @brief Send a gps_raw_int message
  * @param chan MAVLink channel to send the message

+ 51 - 0
v2.0/common/mavlink_msg_gps_rtcm_data.h

@@ -73,6 +73,43 @@ static inline uint16_t mavlink_msg_gps_rtcm_data_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GPS_RTCM_DATA_MIN_LEN, MAVLINK_MSG_ID_GPS_RTCM_DATA_LEN, MAVLINK_MSG_ID_GPS_RTCM_DATA_CRC);
 }
 
+/**
+ * @brief Pack a gps_rtcm_data message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param flags  LSB: 1 means message is fragmented, next 2 bits are the fragment ID, the remaining 5 bits are used for the sequence ID. Messages are only to be flushed to the GPS when the entire message has been reconstructed on the autopilot. The fragment ID specifies which order the fragments should be assembled into a buffer, while the sequence ID is used to detect a mismatch between different buffers. The buffer is considered fully reconstructed when either all 4 fragments are present, or all the fragments before the first fragment with a non full payload is received. This management is used to ensure that normal GPS operation doesn't corrupt RTCM data, and to recover from a unreliable transport delivery order.
+ * @param len [bytes] data length
+ * @param data  RTCM message (may be fragmented)
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gps_rtcm_data_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t flags, uint8_t len, const uint8_t *data)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GPS_RTCM_DATA_LEN];
+    _mav_put_uint8_t(buf, 0, flags);
+    _mav_put_uint8_t(buf, 1, len);
+    _mav_put_uint8_t_array(buf, 2, data, 180);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GPS_RTCM_DATA_LEN);
+#else
+    mavlink_gps_rtcm_data_t packet;
+    packet.flags = flags;
+    packet.len = len;
+    mav_array_memcpy(packet.data, data, sizeof(uint8_t)*180);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GPS_RTCM_DATA_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GPS_RTCM_DATA;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_RTCM_DATA_MIN_LEN, MAVLINK_MSG_ID_GPS_RTCM_DATA_LEN, MAVLINK_MSG_ID_GPS_RTCM_DATA_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_RTCM_DATA_MIN_LEN, MAVLINK_MSG_ID_GPS_RTCM_DATA_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gps_rtcm_data message on a channel
  * @param system_id ID of this system
@@ -133,6 +170,20 @@ static inline uint16_t mavlink_msg_gps_rtcm_data_encode_chan(uint8_t system_id,
     return mavlink_msg_gps_rtcm_data_pack_chan(system_id, component_id, chan, msg, gps_rtcm_data->flags, gps_rtcm_data->len, gps_rtcm_data->data);
 }
 
+/**
+ * @brief Encode a gps_rtcm_data struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gps_rtcm_data C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gps_rtcm_data_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gps_rtcm_data_t* gps_rtcm_data)
+{
+    return mavlink_msg_gps_rtcm_data_pack_status(system_id, component_id, _status, msg,  gps_rtcm_data->flags, gps_rtcm_data->len, gps_rtcm_data->data);
+}
+
 /**
  * @brief Send a gps_rtcm_data message
  * @param chan MAVLink channel to send the message

+ 83 - 0
v2.0/common/mavlink_msg_gps_rtk.h

@@ -135,6 +135,75 @@ static inline uint16_t mavlink_msg_gps_rtk_pack(uint8_t system_id, uint8_t compo
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GPS_RTK_MIN_LEN, MAVLINK_MSG_ID_GPS_RTK_LEN, MAVLINK_MSG_ID_GPS_RTK_CRC);
 }
 
+/**
+ * @brief Pack a gps_rtk message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_last_baseline_ms [ms] Time since boot of last baseline message received.
+ * @param rtk_receiver_id  Identification of connected RTK receiver.
+ * @param wn  GPS Week Number of last baseline
+ * @param tow [ms] GPS Time of Week of last baseline
+ * @param rtk_health  GPS-specific health report for RTK data.
+ * @param rtk_rate [Hz] Rate of baseline messages being received by GPS
+ * @param nsats  Current number of sats used for RTK calculation.
+ * @param baseline_coords_type  Coordinate system of baseline
+ * @param baseline_a_mm [mm] Current baseline in ECEF x or NED north component.
+ * @param baseline_b_mm [mm] Current baseline in ECEF y or NED east component.
+ * @param baseline_c_mm [mm] Current baseline in ECEF z or NED down component.
+ * @param accuracy  Current estimate of baseline accuracy.
+ * @param iar_num_hypotheses  Current number of integer ambiguity hypotheses.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gps_rtk_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t time_last_baseline_ms, uint8_t rtk_receiver_id, uint16_t wn, uint32_t tow, uint8_t rtk_health, uint8_t rtk_rate, uint8_t nsats, uint8_t baseline_coords_type, int32_t baseline_a_mm, int32_t baseline_b_mm, int32_t baseline_c_mm, uint32_t accuracy, int32_t iar_num_hypotheses)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GPS_RTK_LEN];
+    _mav_put_uint32_t(buf, 0, time_last_baseline_ms);
+    _mav_put_uint32_t(buf, 4, tow);
+    _mav_put_int32_t(buf, 8, baseline_a_mm);
+    _mav_put_int32_t(buf, 12, baseline_b_mm);
+    _mav_put_int32_t(buf, 16, baseline_c_mm);
+    _mav_put_uint32_t(buf, 20, accuracy);
+    _mav_put_int32_t(buf, 24, iar_num_hypotheses);
+    _mav_put_uint16_t(buf, 28, wn);
+    _mav_put_uint8_t(buf, 30, rtk_receiver_id);
+    _mav_put_uint8_t(buf, 31, rtk_health);
+    _mav_put_uint8_t(buf, 32, rtk_rate);
+    _mav_put_uint8_t(buf, 33, nsats);
+    _mav_put_uint8_t(buf, 34, baseline_coords_type);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GPS_RTK_LEN);
+#else
+    mavlink_gps_rtk_t packet;
+    packet.time_last_baseline_ms = time_last_baseline_ms;
+    packet.tow = tow;
+    packet.baseline_a_mm = baseline_a_mm;
+    packet.baseline_b_mm = baseline_b_mm;
+    packet.baseline_c_mm = baseline_c_mm;
+    packet.accuracy = accuracy;
+    packet.iar_num_hypotheses = iar_num_hypotheses;
+    packet.wn = wn;
+    packet.rtk_receiver_id = rtk_receiver_id;
+    packet.rtk_health = rtk_health;
+    packet.rtk_rate = rtk_rate;
+    packet.nsats = nsats;
+    packet.baseline_coords_type = baseline_coords_type;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GPS_RTK_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GPS_RTK;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_RTK_MIN_LEN, MAVLINK_MSG_ID_GPS_RTK_LEN, MAVLINK_MSG_ID_GPS_RTK_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_RTK_MIN_LEN, MAVLINK_MSG_ID_GPS_RTK_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gps_rtk message on a channel
  * @param system_id ID of this system
@@ -227,6 +296,20 @@ static inline uint16_t mavlink_msg_gps_rtk_encode_chan(uint8_t system_id, uint8_
     return mavlink_msg_gps_rtk_pack_chan(system_id, component_id, chan, msg, gps_rtk->time_last_baseline_ms, gps_rtk->rtk_receiver_id, gps_rtk->wn, gps_rtk->tow, gps_rtk->rtk_health, gps_rtk->rtk_rate, gps_rtk->nsats, gps_rtk->baseline_coords_type, gps_rtk->baseline_a_mm, gps_rtk->baseline_b_mm, gps_rtk->baseline_c_mm, gps_rtk->accuracy, gps_rtk->iar_num_hypotheses);
 }
 
+/**
+ * @brief Encode a gps_rtk struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gps_rtk C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gps_rtk_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gps_rtk_t* gps_rtk)
+{
+    return mavlink_msg_gps_rtk_pack_status(system_id, component_id, _status, msg,  gps_rtk->time_last_baseline_ms, gps_rtk->rtk_receiver_id, gps_rtk->wn, gps_rtk->tow, gps_rtk->rtk_health, gps_rtk->rtk_rate, gps_rtk->nsats, gps_rtk->baseline_coords_type, gps_rtk->baseline_a_mm, gps_rtk->baseline_b_mm, gps_rtk->baseline_c_mm, gps_rtk->accuracy, gps_rtk->iar_num_hypotheses);
+}
+
 /**
  * @brief Send a gps_rtk message
  * @param chan MAVLink channel to send the message

+ 60 - 0
v2.0/common/mavlink_msg_gps_status.h

@@ -95,6 +95,52 @@ static inline uint16_t mavlink_msg_gps_status_pack(uint8_t system_id, uint8_t co
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_GPS_STATUS_MIN_LEN, MAVLINK_MSG_ID_GPS_STATUS_LEN, MAVLINK_MSG_ID_GPS_STATUS_CRC);
 }
 
+/**
+ * @brief Pack a gps_status message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param satellites_visible  Number of satellites visible
+ * @param satellite_prn  Global satellite ID
+ * @param satellite_used  0: Satellite not used, 1: used for localization
+ * @param satellite_elevation [deg] Elevation (0: right on top of receiver, 90: on the horizon) of satellite
+ * @param satellite_azimuth [deg] Direction of satellite, 0: 0 deg, 255: 360 deg.
+ * @param satellite_snr [dB] Signal to noise ratio of satellite
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_gps_status_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t satellites_visible, const uint8_t *satellite_prn, const uint8_t *satellite_used, const uint8_t *satellite_elevation, const uint8_t *satellite_azimuth, const uint8_t *satellite_snr)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_GPS_STATUS_LEN];
+    _mav_put_uint8_t(buf, 0, satellites_visible);
+    _mav_put_uint8_t_array(buf, 1, satellite_prn, 20);
+    _mav_put_uint8_t_array(buf, 21, satellite_used, 20);
+    _mav_put_uint8_t_array(buf, 41, satellite_elevation, 20);
+    _mav_put_uint8_t_array(buf, 61, satellite_azimuth, 20);
+    _mav_put_uint8_t_array(buf, 81, satellite_snr, 20);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_GPS_STATUS_LEN);
+#else
+    mavlink_gps_status_t packet;
+    packet.satellites_visible = satellites_visible;
+    mav_array_memcpy(packet.satellite_prn, satellite_prn, sizeof(uint8_t)*20);
+    mav_array_memcpy(packet.satellite_used, satellite_used, sizeof(uint8_t)*20);
+    mav_array_memcpy(packet.satellite_elevation, satellite_elevation, sizeof(uint8_t)*20);
+    mav_array_memcpy(packet.satellite_azimuth, satellite_azimuth, sizeof(uint8_t)*20);
+    mav_array_memcpy(packet.satellite_snr, satellite_snr, sizeof(uint8_t)*20);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_GPS_STATUS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_GPS_STATUS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_STATUS_MIN_LEN, MAVLINK_MSG_ID_GPS_STATUS_LEN, MAVLINK_MSG_ID_GPS_STATUS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_GPS_STATUS_MIN_LEN, MAVLINK_MSG_ID_GPS_STATUS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a gps_status message on a channel
  * @param system_id ID of this system
@@ -164,6 +210,20 @@ static inline uint16_t mavlink_msg_gps_status_encode_chan(uint8_t system_id, uin
     return mavlink_msg_gps_status_pack_chan(system_id, component_id, chan, msg, gps_status->satellites_visible, gps_status->satellite_prn, gps_status->satellite_used, gps_status->satellite_elevation, gps_status->satellite_azimuth, gps_status->satellite_snr);
 }
 
+/**
+ * @brief Encode a gps_status struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param gps_status C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_gps_status_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_gps_status_t* gps_status)
+{
+    return mavlink_msg_gps_status_pack_status(system_id, component_id, _status, msg,  gps_status->satellites_visible, gps_status->satellite_prn, gps_status->satellite_used, gps_status->satellite_elevation, gps_status->satellite_azimuth, gps_status->satellite_snr);
+}
+
 /**
  * @brief Send a gps_status message
  * @param chan MAVLink channel to send the message

+ 116 - 0
v2.0/common/mavlink_msg_high_latency.h

@@ -201,6 +201,108 @@ static inline uint16_t mavlink_msg_high_latency_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIGH_LATENCY_MIN_LEN, MAVLINK_MSG_ID_HIGH_LATENCY_LEN, MAVLINK_MSG_ID_HIGH_LATENCY_CRC);
 }
 
+/**
+ * @brief Pack a high_latency message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param base_mode  Bitmap of enabled system modes.
+ * @param custom_mode  A bitfield for use for autopilot-specific flags.
+ * @param landed_state  The landed state. Is set to MAV_LANDED_STATE_UNDEFINED if landed state is unknown.
+ * @param roll [cdeg] roll
+ * @param pitch [cdeg] pitch
+ * @param heading [cdeg] heading
+ * @param throttle [%] throttle (percentage)
+ * @param heading_sp [cdeg] heading setpoint
+ * @param latitude [degE7] Latitude
+ * @param longitude [degE7] Longitude
+ * @param altitude_amsl [m] Altitude above mean sea level
+ * @param altitude_sp [m] Altitude setpoint relative to the home position
+ * @param airspeed [m/s] airspeed
+ * @param airspeed_sp [m/s] airspeed setpoint
+ * @param groundspeed [m/s] groundspeed
+ * @param climb_rate [m/s] climb rate
+ * @param gps_nsat  Number of satellites visible. If unknown, set to UINT8_MAX
+ * @param gps_fix_type  GPS Fix type.
+ * @param battery_remaining [%] Remaining battery (percentage)
+ * @param temperature [degC] Autopilot temperature (degrees C)
+ * @param temperature_air [degC] Air temperature (degrees C) from airspeed sensor
+ * @param failsafe  failsafe (each bit represents a failsafe where 0=ok, 1=failsafe active (bit0:RC, bit1:batt, bit2:GPS, bit3:GCS, bit4:fence)
+ * @param wp_num  current waypoint number
+ * @param wp_distance [m] distance to target
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_high_latency_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t base_mode, uint32_t custom_mode, uint8_t landed_state, int16_t roll, int16_t pitch, uint16_t heading, int8_t throttle, int16_t heading_sp, int32_t latitude, int32_t longitude, int16_t altitude_amsl, int16_t altitude_sp, uint8_t airspeed, uint8_t airspeed_sp, uint8_t groundspeed, int8_t climb_rate, uint8_t gps_nsat, uint8_t gps_fix_type, uint8_t battery_remaining, int8_t temperature, int8_t temperature_air, uint8_t failsafe, uint8_t wp_num, uint16_t wp_distance)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIGH_LATENCY_LEN];
+    _mav_put_uint32_t(buf, 0, custom_mode);
+    _mav_put_int32_t(buf, 4, latitude);
+    _mav_put_int32_t(buf, 8, longitude);
+    _mav_put_int16_t(buf, 12, roll);
+    _mav_put_int16_t(buf, 14, pitch);
+    _mav_put_uint16_t(buf, 16, heading);
+    _mav_put_int16_t(buf, 18, heading_sp);
+    _mav_put_int16_t(buf, 20, altitude_amsl);
+    _mav_put_int16_t(buf, 22, altitude_sp);
+    _mav_put_uint16_t(buf, 24, wp_distance);
+    _mav_put_uint8_t(buf, 26, base_mode);
+    _mav_put_uint8_t(buf, 27, landed_state);
+    _mav_put_int8_t(buf, 28, throttle);
+    _mav_put_uint8_t(buf, 29, airspeed);
+    _mav_put_uint8_t(buf, 30, airspeed_sp);
+    _mav_put_uint8_t(buf, 31, groundspeed);
+    _mav_put_int8_t(buf, 32, climb_rate);
+    _mav_put_uint8_t(buf, 33, gps_nsat);
+    _mav_put_uint8_t(buf, 34, gps_fix_type);
+    _mav_put_uint8_t(buf, 35, battery_remaining);
+    _mav_put_int8_t(buf, 36, temperature);
+    _mav_put_int8_t(buf, 37, temperature_air);
+    _mav_put_uint8_t(buf, 38, failsafe);
+    _mav_put_uint8_t(buf, 39, wp_num);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIGH_LATENCY_LEN);
+#else
+    mavlink_high_latency_t packet;
+    packet.custom_mode = custom_mode;
+    packet.latitude = latitude;
+    packet.longitude = longitude;
+    packet.roll = roll;
+    packet.pitch = pitch;
+    packet.heading = heading;
+    packet.heading_sp = heading_sp;
+    packet.altitude_amsl = altitude_amsl;
+    packet.altitude_sp = altitude_sp;
+    packet.wp_distance = wp_distance;
+    packet.base_mode = base_mode;
+    packet.landed_state = landed_state;
+    packet.throttle = throttle;
+    packet.airspeed = airspeed;
+    packet.airspeed_sp = airspeed_sp;
+    packet.groundspeed = groundspeed;
+    packet.climb_rate = climb_rate;
+    packet.gps_nsat = gps_nsat;
+    packet.gps_fix_type = gps_fix_type;
+    packet.battery_remaining = battery_remaining;
+    packet.temperature = temperature;
+    packet.temperature_air = temperature_air;
+    packet.failsafe = failsafe;
+    packet.wp_num = wp_num;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIGH_LATENCY_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIGH_LATENCY;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIGH_LATENCY_MIN_LEN, MAVLINK_MSG_ID_HIGH_LATENCY_LEN, MAVLINK_MSG_ID_HIGH_LATENCY_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIGH_LATENCY_MIN_LEN, MAVLINK_MSG_ID_HIGH_LATENCY_LEN);
+#endif
+}
+
 /**
  * @brief Pack a high_latency message on a channel
  * @param system_id ID of this system
@@ -326,6 +428,20 @@ static inline uint16_t mavlink_msg_high_latency_encode_chan(uint8_t system_id, u
     return mavlink_msg_high_latency_pack_chan(system_id, component_id, chan, msg, high_latency->base_mode, high_latency->custom_mode, high_latency->landed_state, high_latency->roll, high_latency->pitch, high_latency->heading, high_latency->throttle, high_latency->heading_sp, high_latency->latitude, high_latency->longitude, high_latency->altitude_amsl, high_latency->altitude_sp, high_latency->airspeed, high_latency->airspeed_sp, high_latency->groundspeed, high_latency->climb_rate, high_latency->gps_nsat, high_latency->gps_fix_type, high_latency->battery_remaining, high_latency->temperature, high_latency->temperature_air, high_latency->failsafe, high_latency->wp_num, high_latency->wp_distance);
 }
 
+/**
+ * @brief Encode a high_latency struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param high_latency C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_high_latency_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_high_latency_t* high_latency)
+{
+    return mavlink_msg_high_latency_pack_status(system_id, component_id, _status, msg,  high_latency->base_mode, high_latency->custom_mode, high_latency->landed_state, high_latency->roll, high_latency->pitch, high_latency->heading, high_latency->throttle, high_latency->heading_sp, high_latency->latitude, high_latency->longitude, high_latency->altitude_amsl, high_latency->altitude_sp, high_latency->airspeed, high_latency->airspeed_sp, high_latency->groundspeed, high_latency->climb_rate, high_latency->gps_nsat, high_latency->gps_fix_type, high_latency->battery_remaining, high_latency->temperature, high_latency->temperature_air, high_latency->failsafe, high_latency->wp_num, high_latency->wp_distance);
+}
+
 /**
  * @brief Send a high_latency message
  * @param chan MAVLink channel to send the message

+ 125 - 0
v2.0/common/mavlink_msg_high_latency2.h

@@ -219,6 +219,117 @@ static inline uint16_t mavlink_msg_high_latency2_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIGH_LATENCY2_MIN_LEN, MAVLINK_MSG_ID_HIGH_LATENCY2_LEN, MAVLINK_MSG_ID_HIGH_LATENCY2_CRC);
 }
 
+/**
+ * @brief Pack a high_latency2 message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param timestamp [ms] Timestamp (milliseconds since boot or Unix epoch)
+ * @param type  Type of the MAV (quadrotor, helicopter, etc.)
+ * @param autopilot  Autopilot type / class. Use MAV_AUTOPILOT_INVALID for components that are not flight controllers.
+ * @param custom_mode  A bitfield for use for autopilot-specific flags (2 byte version).
+ * @param latitude [degE7] Latitude
+ * @param longitude [degE7] Longitude
+ * @param altitude [m] Altitude above mean sea level
+ * @param target_altitude [m] Altitude setpoint
+ * @param heading [deg/2] Heading
+ * @param target_heading [deg/2] Heading setpoint
+ * @param target_distance [dam] Distance to target waypoint or position
+ * @param throttle [%] Throttle
+ * @param airspeed [m/s*5] Airspeed
+ * @param airspeed_sp [m/s*5] Airspeed setpoint
+ * @param groundspeed [m/s*5] Groundspeed
+ * @param windspeed [m/s*5] Windspeed
+ * @param wind_heading [deg/2] Wind heading
+ * @param eph [dm] Maximum error horizontal position since last message
+ * @param epv [dm] Maximum error vertical position since last message
+ * @param temperature_air [degC] Air temperature from airspeed sensor
+ * @param climb_rate [dm/s] Maximum climb rate magnitude since last message
+ * @param battery [%] Battery level (-1 if field not provided).
+ * @param wp_num  Current waypoint number
+ * @param failure_flags  Bitmap of failure flags.
+ * @param custom0  Field for custom payload.
+ * @param custom1  Field for custom payload.
+ * @param custom2  Field for custom payload.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_high_latency2_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint32_t timestamp, uint8_t type, uint8_t autopilot, uint16_t custom_mode, int32_t latitude, int32_t longitude, int16_t altitude, int16_t target_altitude, uint8_t heading, uint8_t target_heading, uint16_t target_distance, uint8_t throttle, uint8_t airspeed, uint8_t airspeed_sp, uint8_t groundspeed, uint8_t windspeed, uint8_t wind_heading, uint8_t eph, uint8_t epv, int8_t temperature_air, int8_t climb_rate, int8_t battery, uint16_t wp_num, uint16_t failure_flags, int8_t custom0, int8_t custom1, int8_t custom2)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIGH_LATENCY2_LEN];
+    _mav_put_uint32_t(buf, 0, timestamp);
+    _mav_put_int32_t(buf, 4, latitude);
+    _mav_put_int32_t(buf, 8, longitude);
+    _mav_put_uint16_t(buf, 12, custom_mode);
+    _mav_put_int16_t(buf, 14, altitude);
+    _mav_put_int16_t(buf, 16, target_altitude);
+    _mav_put_uint16_t(buf, 18, target_distance);
+    _mav_put_uint16_t(buf, 20, wp_num);
+    _mav_put_uint16_t(buf, 22, failure_flags);
+    _mav_put_uint8_t(buf, 24, type);
+    _mav_put_uint8_t(buf, 25, autopilot);
+    _mav_put_uint8_t(buf, 26, heading);
+    _mav_put_uint8_t(buf, 27, target_heading);
+    _mav_put_uint8_t(buf, 28, throttle);
+    _mav_put_uint8_t(buf, 29, airspeed);
+    _mav_put_uint8_t(buf, 30, airspeed_sp);
+    _mav_put_uint8_t(buf, 31, groundspeed);
+    _mav_put_uint8_t(buf, 32, windspeed);
+    _mav_put_uint8_t(buf, 33, wind_heading);
+    _mav_put_uint8_t(buf, 34, eph);
+    _mav_put_uint8_t(buf, 35, epv);
+    _mav_put_int8_t(buf, 36, temperature_air);
+    _mav_put_int8_t(buf, 37, climb_rate);
+    _mav_put_int8_t(buf, 38, battery);
+    _mav_put_int8_t(buf, 39, custom0);
+    _mav_put_int8_t(buf, 40, custom1);
+    _mav_put_int8_t(buf, 41, custom2);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIGH_LATENCY2_LEN);
+#else
+    mavlink_high_latency2_t packet;
+    packet.timestamp = timestamp;
+    packet.latitude = latitude;
+    packet.longitude = longitude;
+    packet.custom_mode = custom_mode;
+    packet.altitude = altitude;
+    packet.target_altitude = target_altitude;
+    packet.target_distance = target_distance;
+    packet.wp_num = wp_num;
+    packet.failure_flags = failure_flags;
+    packet.type = type;
+    packet.autopilot = autopilot;
+    packet.heading = heading;
+    packet.target_heading = target_heading;
+    packet.throttle = throttle;
+    packet.airspeed = airspeed;
+    packet.airspeed_sp = airspeed_sp;
+    packet.groundspeed = groundspeed;
+    packet.windspeed = windspeed;
+    packet.wind_heading = wind_heading;
+    packet.eph = eph;
+    packet.epv = epv;
+    packet.temperature_air = temperature_air;
+    packet.climb_rate = climb_rate;
+    packet.battery = battery;
+    packet.custom0 = custom0;
+    packet.custom1 = custom1;
+    packet.custom2 = custom2;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIGH_LATENCY2_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIGH_LATENCY2;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIGH_LATENCY2_MIN_LEN, MAVLINK_MSG_ID_HIGH_LATENCY2_LEN, MAVLINK_MSG_ID_HIGH_LATENCY2_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIGH_LATENCY2_MIN_LEN, MAVLINK_MSG_ID_HIGH_LATENCY2_LEN);
+#endif
+}
+
 /**
  * @brief Pack a high_latency2 message on a channel
  * @param system_id ID of this system
@@ -353,6 +464,20 @@ static inline uint16_t mavlink_msg_high_latency2_encode_chan(uint8_t system_id,
     return mavlink_msg_high_latency2_pack_chan(system_id, component_id, chan, msg, high_latency2->timestamp, high_latency2->type, high_latency2->autopilot, high_latency2->custom_mode, high_latency2->latitude, high_latency2->longitude, high_latency2->altitude, high_latency2->target_altitude, high_latency2->heading, high_latency2->target_heading, high_latency2->target_distance, high_latency2->throttle, high_latency2->airspeed, high_latency2->airspeed_sp, high_latency2->groundspeed, high_latency2->windspeed, high_latency2->wind_heading, high_latency2->eph, high_latency2->epv, high_latency2->temperature_air, high_latency2->climb_rate, high_latency2->battery, high_latency2->wp_num, high_latency2->failure_flags, high_latency2->custom0, high_latency2->custom1, high_latency2->custom2);
 }
 
+/**
+ * @brief Encode a high_latency2 struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param high_latency2 C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_high_latency2_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_high_latency2_t* high_latency2)
+{
+    return mavlink_msg_high_latency2_pack_status(system_id, component_id, _status, msg,  high_latency2->timestamp, high_latency2->type, high_latency2->autopilot, high_latency2->custom_mode, high_latency2->latitude, high_latency2->longitude, high_latency2->altitude, high_latency2->target_altitude, high_latency2->heading, high_latency2->target_heading, high_latency2->target_distance, high_latency2->throttle, high_latency2->airspeed, high_latency2->airspeed_sp, high_latency2->groundspeed, high_latency2->windspeed, high_latency2->wind_heading, high_latency2->eph, high_latency2->epv, high_latency2->temperature_air, high_latency2->climb_rate, high_latency2->battery, high_latency2->wp_num, high_latency2->failure_flags, high_latency2->custom0, high_latency2->custom1, high_latency2->custom2);
+}
+
 /**
  * @brief Send a high_latency2 message
  * @param chan MAVLink channel to send the message

+ 92 - 0
v2.0/common/mavlink_msg_highres_imu.h

@@ -153,6 +153,84 @@ static inline uint16_t mavlink_msg_highres_imu_pack(uint8_t system_id, uint8_t c
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIGHRES_IMU_MIN_LEN, MAVLINK_MSG_ID_HIGHRES_IMU_LEN, MAVLINK_MSG_ID_HIGHRES_IMU_CRC);
 }
 
+/**
+ * @brief Pack a highres_imu message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param xacc [m/s/s] X acceleration
+ * @param yacc [m/s/s] Y acceleration
+ * @param zacc [m/s/s] Z acceleration
+ * @param xgyro [rad/s] Angular speed around X axis
+ * @param ygyro [rad/s] Angular speed around Y axis
+ * @param zgyro [rad/s] Angular speed around Z axis
+ * @param xmag [gauss] X Magnetic field
+ * @param ymag [gauss] Y Magnetic field
+ * @param zmag [gauss] Z Magnetic field
+ * @param abs_pressure [hPa] Absolute pressure
+ * @param diff_pressure [hPa] Differential pressure
+ * @param pressure_alt  Altitude calculated from pressure
+ * @param temperature [degC] Temperature
+ * @param fields_updated  Bitmap for fields that have updated since last message
+ * @param id  Id. Ids are numbered from 0 and map to IMUs numbered from 1 (e.g. IMU1 will have a message with id=0)
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_highres_imu_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, float xacc, float yacc, float zacc, float xgyro, float ygyro, float zgyro, float xmag, float ymag, float zmag, float abs_pressure, float diff_pressure, float pressure_alt, float temperature, uint16_t fields_updated, uint8_t id)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIGHRES_IMU_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 8, xacc);
+    _mav_put_float(buf, 12, yacc);
+    _mav_put_float(buf, 16, zacc);
+    _mav_put_float(buf, 20, xgyro);
+    _mav_put_float(buf, 24, ygyro);
+    _mav_put_float(buf, 28, zgyro);
+    _mav_put_float(buf, 32, xmag);
+    _mav_put_float(buf, 36, ymag);
+    _mav_put_float(buf, 40, zmag);
+    _mav_put_float(buf, 44, abs_pressure);
+    _mav_put_float(buf, 48, diff_pressure);
+    _mav_put_float(buf, 52, pressure_alt);
+    _mav_put_float(buf, 56, temperature);
+    _mav_put_uint16_t(buf, 60, fields_updated);
+    _mav_put_uint8_t(buf, 62, id);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIGHRES_IMU_LEN);
+#else
+    mavlink_highres_imu_t packet;
+    packet.time_usec = time_usec;
+    packet.xacc = xacc;
+    packet.yacc = yacc;
+    packet.zacc = zacc;
+    packet.xgyro = xgyro;
+    packet.ygyro = ygyro;
+    packet.zgyro = zgyro;
+    packet.xmag = xmag;
+    packet.ymag = ymag;
+    packet.zmag = zmag;
+    packet.abs_pressure = abs_pressure;
+    packet.diff_pressure = diff_pressure;
+    packet.pressure_alt = pressure_alt;
+    packet.temperature = temperature;
+    packet.fields_updated = fields_updated;
+    packet.id = id;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIGHRES_IMU_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIGHRES_IMU;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIGHRES_IMU_MIN_LEN, MAVLINK_MSG_ID_HIGHRES_IMU_LEN, MAVLINK_MSG_ID_HIGHRES_IMU_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIGHRES_IMU_MIN_LEN, MAVLINK_MSG_ID_HIGHRES_IMU_LEN);
+#endif
+}
+
 /**
  * @brief Pack a highres_imu message on a channel
  * @param system_id ID of this system
@@ -254,6 +332,20 @@ static inline uint16_t mavlink_msg_highres_imu_encode_chan(uint8_t system_id, ui
     return mavlink_msg_highres_imu_pack_chan(system_id, component_id, chan, msg, highres_imu->time_usec, highres_imu->xacc, highres_imu->yacc, highres_imu->zacc, highres_imu->xgyro, highres_imu->ygyro, highres_imu->zgyro, highres_imu->xmag, highres_imu->ymag, highres_imu->zmag, highres_imu->abs_pressure, highres_imu->diff_pressure, highres_imu->pressure_alt, highres_imu->temperature, highres_imu->fields_updated, highres_imu->id);
 }
 
+/**
+ * @brief Encode a highres_imu struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param highres_imu C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_highres_imu_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_highres_imu_t* highres_imu)
+{
+    return mavlink_msg_highres_imu_pack_status(system_id, component_id, _status, msg,  highres_imu->time_usec, highres_imu->xacc, highres_imu->yacc, highres_imu->zacc, highres_imu->xgyro, highres_imu->ygyro, highres_imu->zgyro, highres_imu->xmag, highres_imu->ymag, highres_imu->zmag, highres_imu->abs_pressure, highres_imu->diff_pressure, highres_imu->pressure_alt, highres_imu->temperature, highres_imu->fields_updated, highres_imu->id);
+}
+
 /**
  * @brief Send a highres_imu message
  * @param chan MAVLink channel to send the message

+ 54 - 0
v2.0/common/mavlink_msg_hil_actuator_controls.h

@@ -79,6 +79,46 @@ static inline uint16_t mavlink_msg_hil_actuator_controls_pack(uint8_t system_id,
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_MIN_LEN, MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_LEN, MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_CRC);
 }
 
+/**
+ * @brief Pack a hil_actuator_controls message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param controls  Control outputs -1 .. 1. Channel assignment depends on the simulated hardware.
+ * @param mode  System mode. Includes arming state.
+ * @param flags  Flags as bitfield, 1: indicate simulation using lockstep.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_hil_actuator_controls_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, const float *controls, uint8_t mode, uint64_t flags)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_uint64_t(buf, 8, flags);
+    _mav_put_uint8_t(buf, 80, mode);
+    _mav_put_float_array(buf, 16, controls, 16);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_LEN);
+#else
+    mavlink_hil_actuator_controls_t packet;
+    packet.time_usec = time_usec;
+    packet.flags = flags;
+    packet.mode = mode;
+    mav_array_memcpy(packet.controls, controls, sizeof(float)*16);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_MIN_LEN, MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_LEN, MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_MIN_LEN, MAVLINK_MSG_ID_HIL_ACTUATOR_CONTROLS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a hil_actuator_controls message on a channel
  * @param system_id ID of this system
@@ -142,6 +182,20 @@ static inline uint16_t mavlink_msg_hil_actuator_controls_encode_chan(uint8_t sys
     return mavlink_msg_hil_actuator_controls_pack_chan(system_id, component_id, chan, msg, hil_actuator_controls->time_usec, hil_actuator_controls->controls, hil_actuator_controls->mode, hil_actuator_controls->flags);
 }
 
+/**
+ * @brief Encode a hil_actuator_controls struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param hil_actuator_controls C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_hil_actuator_controls_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_hil_actuator_controls_t* hil_actuator_controls)
+{
+    return mavlink_msg_hil_actuator_controls_pack_status(system_id, component_id, _status, msg,  hil_actuator_controls->time_usec, hil_actuator_controls->controls, hil_actuator_controls->mode, hil_actuator_controls->flags);
+}
+
 /**
  * @brief Send a hil_actuator_controls message
  * @param chan MAVLink channel to send the message

+ 77 - 0
v2.0/common/mavlink_msg_hil_controls.h

@@ -123,6 +123,69 @@ static inline uint16_t mavlink_msg_hil_controls_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIL_CONTROLS_MIN_LEN, MAVLINK_MSG_ID_HIL_CONTROLS_LEN, MAVLINK_MSG_ID_HIL_CONTROLS_CRC);
 }
 
+/**
+ * @brief Pack a hil_controls message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param roll_ailerons  Control output -1 .. 1
+ * @param pitch_elevator  Control output -1 .. 1
+ * @param yaw_rudder  Control output -1 .. 1
+ * @param throttle  Throttle 0 .. 1
+ * @param aux1  Aux 1, -1 .. 1
+ * @param aux2  Aux 2, -1 .. 1
+ * @param aux3  Aux 3, -1 .. 1
+ * @param aux4  Aux 4, -1 .. 1
+ * @param mode  System mode.
+ * @param nav_mode  Navigation mode (MAV_NAV_MODE)
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_hil_controls_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, float roll_ailerons, float pitch_elevator, float yaw_rudder, float throttle, float aux1, float aux2, float aux3, float aux4, uint8_t mode, uint8_t nav_mode)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIL_CONTROLS_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 8, roll_ailerons);
+    _mav_put_float(buf, 12, pitch_elevator);
+    _mav_put_float(buf, 16, yaw_rudder);
+    _mav_put_float(buf, 20, throttle);
+    _mav_put_float(buf, 24, aux1);
+    _mav_put_float(buf, 28, aux2);
+    _mav_put_float(buf, 32, aux3);
+    _mav_put_float(buf, 36, aux4);
+    _mav_put_uint8_t(buf, 40, mode);
+    _mav_put_uint8_t(buf, 41, nav_mode);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIL_CONTROLS_LEN);
+#else
+    mavlink_hil_controls_t packet;
+    packet.time_usec = time_usec;
+    packet.roll_ailerons = roll_ailerons;
+    packet.pitch_elevator = pitch_elevator;
+    packet.yaw_rudder = yaw_rudder;
+    packet.throttle = throttle;
+    packet.aux1 = aux1;
+    packet.aux2 = aux2;
+    packet.aux3 = aux3;
+    packet.aux4 = aux4;
+    packet.mode = mode;
+    packet.nav_mode = nav_mode;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIL_CONTROLS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIL_CONTROLS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_CONTROLS_MIN_LEN, MAVLINK_MSG_ID_HIL_CONTROLS_LEN, MAVLINK_MSG_ID_HIL_CONTROLS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_CONTROLS_MIN_LEN, MAVLINK_MSG_ID_HIL_CONTROLS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a hil_controls message on a channel
  * @param system_id ID of this system
@@ -209,6 +272,20 @@ static inline uint16_t mavlink_msg_hil_controls_encode_chan(uint8_t system_id, u
     return mavlink_msg_hil_controls_pack_chan(system_id, component_id, chan, msg, hil_controls->time_usec, hil_controls->roll_ailerons, hil_controls->pitch_elevator, hil_controls->yaw_rudder, hil_controls->throttle, hil_controls->aux1, hil_controls->aux2, hil_controls->aux3, hil_controls->aux4, hil_controls->mode, hil_controls->nav_mode);
 }
 
+/**
+ * @brief Encode a hil_controls struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param hil_controls C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_hil_controls_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_hil_controls_t* hil_controls)
+{
+    return mavlink_msg_hil_controls_pack_status(system_id, component_id, _status, msg,  hil_controls->time_usec, hil_controls->roll_ailerons, hil_controls->pitch_elevator, hil_controls->yaw_rudder, hil_controls->throttle, hil_controls->aux1, hil_controls->aux2, hil_controls->aux3, hil_controls->aux4, hil_controls->mode, hil_controls->nav_mode);
+}
+
 /**
  * @brief Send a hil_controls message
  * @param chan MAVLink channel to send the message

+ 89 - 0
v2.0/common/mavlink_msg_hil_gps.h

@@ -147,6 +147,81 @@ static inline uint16_t mavlink_msg_hil_gps_pack(uint8_t system_id, uint8_t compo
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIL_GPS_MIN_LEN, MAVLINK_MSG_ID_HIL_GPS_LEN, MAVLINK_MSG_ID_HIL_GPS_CRC);
 }
 
+/**
+ * @brief Pack a hil_gps message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param fix_type  0-1: no fix, 2: 2D fix, 3: 3D fix. Some applications will not use the value of this field unless it is at least two, so always correctly fill in the fix.
+ * @param lat [degE7] Latitude (WGS84)
+ * @param lon [degE7] Longitude (WGS84)
+ * @param alt [mm] Altitude (MSL). Positive for up.
+ * @param eph  GPS HDOP horizontal dilution of position (unitless * 100). If unknown, set to: UINT16_MAX
+ * @param epv  GPS VDOP vertical dilution of position (unitless * 100). If unknown, set to: UINT16_MAX
+ * @param vel [cm/s] GPS ground speed. If unknown, set to: UINT16_MAX
+ * @param vn [cm/s] GPS velocity in north direction in earth-fixed NED frame
+ * @param ve [cm/s] GPS velocity in east direction in earth-fixed NED frame
+ * @param vd [cm/s] GPS velocity in down direction in earth-fixed NED frame
+ * @param cog [cdeg] Course over ground (NOT heading, but direction of movement), 0.0..359.99 degrees. If unknown, set to: UINT16_MAX
+ * @param satellites_visible  Number of satellites visible. If unknown, set to UINT8_MAX
+ * @param id  GPS ID (zero indexed). Used for multiple GPS inputs
+ * @param yaw [cdeg] Yaw of vehicle relative to Earth's North, zero means not available, use 36000 for north
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_hil_gps_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint8_t fix_type, int32_t lat, int32_t lon, int32_t alt, uint16_t eph, uint16_t epv, uint16_t vel, int16_t vn, int16_t ve, int16_t vd, uint16_t cog, uint8_t satellites_visible, uint8_t id, uint16_t yaw)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIL_GPS_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_int32_t(buf, 8, lat);
+    _mav_put_int32_t(buf, 12, lon);
+    _mav_put_int32_t(buf, 16, alt);
+    _mav_put_uint16_t(buf, 20, eph);
+    _mav_put_uint16_t(buf, 22, epv);
+    _mav_put_uint16_t(buf, 24, vel);
+    _mav_put_int16_t(buf, 26, vn);
+    _mav_put_int16_t(buf, 28, ve);
+    _mav_put_int16_t(buf, 30, vd);
+    _mav_put_uint16_t(buf, 32, cog);
+    _mav_put_uint8_t(buf, 34, fix_type);
+    _mav_put_uint8_t(buf, 35, satellites_visible);
+    _mav_put_uint8_t(buf, 36, id);
+    _mav_put_uint16_t(buf, 37, yaw);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIL_GPS_LEN);
+#else
+    mavlink_hil_gps_t packet;
+    packet.time_usec = time_usec;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.eph = eph;
+    packet.epv = epv;
+    packet.vel = vel;
+    packet.vn = vn;
+    packet.ve = ve;
+    packet.vd = vd;
+    packet.cog = cog;
+    packet.fix_type = fix_type;
+    packet.satellites_visible = satellites_visible;
+    packet.id = id;
+    packet.yaw = yaw;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIL_GPS_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIL_GPS;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_GPS_MIN_LEN, MAVLINK_MSG_ID_HIL_GPS_LEN, MAVLINK_MSG_ID_HIL_GPS_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_GPS_MIN_LEN, MAVLINK_MSG_ID_HIL_GPS_LEN);
+#endif
+}
+
 /**
  * @brief Pack a hil_gps message on a channel
  * @param system_id ID of this system
@@ -245,6 +320,20 @@ static inline uint16_t mavlink_msg_hil_gps_encode_chan(uint8_t system_id, uint8_
     return mavlink_msg_hil_gps_pack_chan(system_id, component_id, chan, msg, hil_gps->time_usec, hil_gps->fix_type, hil_gps->lat, hil_gps->lon, hil_gps->alt, hil_gps->eph, hil_gps->epv, hil_gps->vel, hil_gps->vn, hil_gps->ve, hil_gps->vd, hil_gps->cog, hil_gps->satellites_visible, hil_gps->id, hil_gps->yaw);
 }
 
+/**
+ * @brief Encode a hil_gps struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param hil_gps C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_hil_gps_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_hil_gps_t* hil_gps)
+{
+    return mavlink_msg_hil_gps_pack_status(system_id, component_id, _status, msg,  hil_gps->time_usec, hil_gps->fix_type, hil_gps->lat, hil_gps->lon, hil_gps->alt, hil_gps->eph, hil_gps->epv, hil_gps->vel, hil_gps->vn, hil_gps->ve, hil_gps->vd, hil_gps->cog, hil_gps->satellites_visible, hil_gps->id, hil_gps->yaw);
+}
+
 /**
  * @brief Send a hil_gps message
  * @param chan MAVLink channel to send the message

+ 80 - 0
v2.0/common/mavlink_msg_hil_optical_flow.h

@@ -129,6 +129,72 @@ static inline uint16_t mavlink_msg_hil_optical_flow_pack(uint8_t system_id, uint
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_MIN_LEN, MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_LEN, MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_CRC);
 }
 
+/**
+ * @brief Pack a hil_optical_flow message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param sensor_id  Sensor ID
+ * @param integration_time_us [us] Integration time. Divide integrated_x and integrated_y by the integration time to obtain average flow. The integration time also indicates the.
+ * @param integrated_x [rad] Flow in radians around X axis (Sensor RH rotation about the X axis induces a positive flow. Sensor linear motion along the positive Y axis induces a negative flow.)
+ * @param integrated_y [rad] Flow in radians around Y axis (Sensor RH rotation about the Y axis induces a positive flow. Sensor linear motion along the positive X axis induces a positive flow.)
+ * @param integrated_xgyro [rad] RH rotation around X axis
+ * @param integrated_ygyro [rad] RH rotation around Y axis
+ * @param integrated_zgyro [rad] RH rotation around Z axis
+ * @param temperature [cdegC] Temperature
+ * @param quality  Optical flow quality / confidence. 0: no valid flow, 255: maximum quality
+ * @param time_delta_distance_us [us] Time since the distance was sampled.
+ * @param distance [m] Distance to the center of the flow field. Positive value (including zero): distance known. Negative value: Unknown distance.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_hil_optical_flow_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint8_t sensor_id, uint32_t integration_time_us, float integrated_x, float integrated_y, float integrated_xgyro, float integrated_ygyro, float integrated_zgyro, int16_t temperature, uint8_t quality, uint32_t time_delta_distance_us, float distance)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_uint32_t(buf, 8, integration_time_us);
+    _mav_put_float(buf, 12, integrated_x);
+    _mav_put_float(buf, 16, integrated_y);
+    _mav_put_float(buf, 20, integrated_xgyro);
+    _mav_put_float(buf, 24, integrated_ygyro);
+    _mav_put_float(buf, 28, integrated_zgyro);
+    _mav_put_uint32_t(buf, 32, time_delta_distance_us);
+    _mav_put_float(buf, 36, distance);
+    _mav_put_int16_t(buf, 40, temperature);
+    _mav_put_uint8_t(buf, 42, sensor_id);
+    _mav_put_uint8_t(buf, 43, quality);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_LEN);
+#else
+    mavlink_hil_optical_flow_t packet;
+    packet.time_usec = time_usec;
+    packet.integration_time_us = integration_time_us;
+    packet.integrated_x = integrated_x;
+    packet.integrated_y = integrated_y;
+    packet.integrated_xgyro = integrated_xgyro;
+    packet.integrated_ygyro = integrated_ygyro;
+    packet.integrated_zgyro = integrated_zgyro;
+    packet.time_delta_distance_us = time_delta_distance_us;
+    packet.distance = distance;
+    packet.temperature = temperature;
+    packet.sensor_id = sensor_id;
+    packet.quality = quality;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIL_OPTICAL_FLOW;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_MIN_LEN, MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_LEN, MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_MIN_LEN, MAVLINK_MSG_ID_HIL_OPTICAL_FLOW_LEN);
+#endif
+}
+
 /**
  * @brief Pack a hil_optical_flow message on a channel
  * @param system_id ID of this system
@@ -218,6 +284,20 @@ static inline uint16_t mavlink_msg_hil_optical_flow_encode_chan(uint8_t system_i
     return mavlink_msg_hil_optical_flow_pack_chan(system_id, component_id, chan, msg, hil_optical_flow->time_usec, hil_optical_flow->sensor_id, hil_optical_flow->integration_time_us, hil_optical_flow->integrated_x, hil_optical_flow->integrated_y, hil_optical_flow->integrated_xgyro, hil_optical_flow->integrated_ygyro, hil_optical_flow->integrated_zgyro, hil_optical_flow->temperature, hil_optical_flow->quality, hil_optical_flow->time_delta_distance_us, hil_optical_flow->distance);
 }
 
+/**
+ * @brief Encode a hil_optical_flow struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param hil_optical_flow C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_hil_optical_flow_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_hil_optical_flow_t* hil_optical_flow)
+{
+    return mavlink_msg_hil_optical_flow_pack_status(system_id, component_id, _status, msg,  hil_optical_flow->time_usec, hil_optical_flow->sensor_id, hil_optical_flow->integration_time_us, hil_optical_flow->integrated_x, hil_optical_flow->integrated_y, hil_optical_flow->integrated_xgyro, hil_optical_flow->integrated_ygyro, hil_optical_flow->integrated_zgyro, hil_optical_flow->temperature, hil_optical_flow->quality, hil_optical_flow->time_delta_distance_us, hil_optical_flow->distance);
+}
+
 /**
  * @brief Send a hil_optical_flow message
  * @param chan MAVLink channel to send the message

+ 86 - 0
v2.0/common/mavlink_msg_hil_rc_inputs_raw.h

@@ -141,6 +141,78 @@ static inline uint16_t mavlink_msg_hil_rc_inputs_raw_pack(uint8_t system_id, uin
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_MIN_LEN, MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_LEN, MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_CRC);
 }
 
+/**
+ * @brief Pack a hil_rc_inputs_raw message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param chan1_raw [us] RC channel 1 value
+ * @param chan2_raw [us] RC channel 2 value
+ * @param chan3_raw [us] RC channel 3 value
+ * @param chan4_raw [us] RC channel 4 value
+ * @param chan5_raw [us] RC channel 5 value
+ * @param chan6_raw [us] RC channel 6 value
+ * @param chan7_raw [us] RC channel 7 value
+ * @param chan8_raw [us] RC channel 8 value
+ * @param chan9_raw [us] RC channel 9 value
+ * @param chan10_raw [us] RC channel 10 value
+ * @param chan11_raw [us] RC channel 11 value
+ * @param chan12_raw [us] RC channel 12 value
+ * @param rssi  Receive signal strength indicator in device-dependent units/scale. Values: [0-254], UINT8_MAX: invalid/unknown.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_hil_rc_inputs_raw_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, uint16_t chan1_raw, uint16_t chan2_raw, uint16_t chan3_raw, uint16_t chan4_raw, uint16_t chan5_raw, uint16_t chan6_raw, uint16_t chan7_raw, uint16_t chan8_raw, uint16_t chan9_raw, uint16_t chan10_raw, uint16_t chan11_raw, uint16_t chan12_raw, uint8_t rssi)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_uint16_t(buf, 8, chan1_raw);
+    _mav_put_uint16_t(buf, 10, chan2_raw);
+    _mav_put_uint16_t(buf, 12, chan3_raw);
+    _mav_put_uint16_t(buf, 14, chan4_raw);
+    _mav_put_uint16_t(buf, 16, chan5_raw);
+    _mav_put_uint16_t(buf, 18, chan6_raw);
+    _mav_put_uint16_t(buf, 20, chan7_raw);
+    _mav_put_uint16_t(buf, 22, chan8_raw);
+    _mav_put_uint16_t(buf, 24, chan9_raw);
+    _mav_put_uint16_t(buf, 26, chan10_raw);
+    _mav_put_uint16_t(buf, 28, chan11_raw);
+    _mav_put_uint16_t(buf, 30, chan12_raw);
+    _mav_put_uint8_t(buf, 32, rssi);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_LEN);
+#else
+    mavlink_hil_rc_inputs_raw_t packet;
+    packet.time_usec = time_usec;
+    packet.chan1_raw = chan1_raw;
+    packet.chan2_raw = chan2_raw;
+    packet.chan3_raw = chan3_raw;
+    packet.chan4_raw = chan4_raw;
+    packet.chan5_raw = chan5_raw;
+    packet.chan6_raw = chan6_raw;
+    packet.chan7_raw = chan7_raw;
+    packet.chan8_raw = chan8_raw;
+    packet.chan9_raw = chan9_raw;
+    packet.chan10_raw = chan10_raw;
+    packet.chan11_raw = chan11_raw;
+    packet.chan12_raw = chan12_raw;
+    packet.rssi = rssi;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_MIN_LEN, MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_LEN, MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_MIN_LEN, MAVLINK_MSG_ID_HIL_RC_INPUTS_RAW_LEN);
+#endif
+}
+
 /**
  * @brief Pack a hil_rc_inputs_raw message on a channel
  * @param system_id ID of this system
@@ -236,6 +308,20 @@ static inline uint16_t mavlink_msg_hil_rc_inputs_raw_encode_chan(uint8_t system_
     return mavlink_msg_hil_rc_inputs_raw_pack_chan(system_id, component_id, chan, msg, hil_rc_inputs_raw->time_usec, hil_rc_inputs_raw->chan1_raw, hil_rc_inputs_raw->chan2_raw, hil_rc_inputs_raw->chan3_raw, hil_rc_inputs_raw->chan4_raw, hil_rc_inputs_raw->chan5_raw, hil_rc_inputs_raw->chan6_raw, hil_rc_inputs_raw->chan7_raw, hil_rc_inputs_raw->chan8_raw, hil_rc_inputs_raw->chan9_raw, hil_rc_inputs_raw->chan10_raw, hil_rc_inputs_raw->chan11_raw, hil_rc_inputs_raw->chan12_raw, hil_rc_inputs_raw->rssi);
 }
 
+/**
+ * @brief Encode a hil_rc_inputs_raw struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param hil_rc_inputs_raw C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_hil_rc_inputs_raw_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_hil_rc_inputs_raw_t* hil_rc_inputs_raw)
+{
+    return mavlink_msg_hil_rc_inputs_raw_pack_status(system_id, component_id, _status, msg,  hil_rc_inputs_raw->time_usec, hil_rc_inputs_raw->chan1_raw, hil_rc_inputs_raw->chan2_raw, hil_rc_inputs_raw->chan3_raw, hil_rc_inputs_raw->chan4_raw, hil_rc_inputs_raw->chan5_raw, hil_rc_inputs_raw->chan6_raw, hil_rc_inputs_raw->chan7_raw, hil_rc_inputs_raw->chan8_raw, hil_rc_inputs_raw->chan9_raw, hil_rc_inputs_raw->chan10_raw, hil_rc_inputs_raw->chan11_raw, hil_rc_inputs_raw->chan12_raw, hil_rc_inputs_raw->rssi);
+}
+
 /**
  * @brief Send a hil_rc_inputs_raw message
  * @param chan MAVLink channel to send the message

+ 92 - 0
v2.0/common/mavlink_msg_hil_sensor.h

@@ -153,6 +153,84 @@ static inline uint16_t mavlink_msg_hil_sensor_pack(uint8_t system_id, uint8_t co
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIL_SENSOR_MIN_LEN, MAVLINK_MSG_ID_HIL_SENSOR_LEN, MAVLINK_MSG_ID_HIL_SENSOR_CRC);
 }
 
+/**
+ * @brief Pack a hil_sensor message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param xacc [m/s/s] X acceleration
+ * @param yacc [m/s/s] Y acceleration
+ * @param zacc [m/s/s] Z acceleration
+ * @param xgyro [rad/s] Angular speed around X axis in body frame
+ * @param ygyro [rad/s] Angular speed around Y axis in body frame
+ * @param zgyro [rad/s] Angular speed around Z axis in body frame
+ * @param xmag [gauss] X Magnetic field
+ * @param ymag [gauss] Y Magnetic field
+ * @param zmag [gauss] Z Magnetic field
+ * @param abs_pressure [hPa] Absolute pressure
+ * @param diff_pressure [hPa] Differential pressure (airspeed)
+ * @param pressure_alt  Altitude calculated from pressure
+ * @param temperature [degC] Temperature
+ * @param fields_updated  Bitmap for fields that have updated since last message
+ * @param id  Sensor ID (zero indexed). Used for multiple sensor inputs
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_hil_sensor_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, float xacc, float yacc, float zacc, float xgyro, float ygyro, float zgyro, float xmag, float ymag, float zmag, float abs_pressure, float diff_pressure, float pressure_alt, float temperature, uint32_t fields_updated, uint8_t id)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIL_SENSOR_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 8, xacc);
+    _mav_put_float(buf, 12, yacc);
+    _mav_put_float(buf, 16, zacc);
+    _mav_put_float(buf, 20, xgyro);
+    _mav_put_float(buf, 24, ygyro);
+    _mav_put_float(buf, 28, zgyro);
+    _mav_put_float(buf, 32, xmag);
+    _mav_put_float(buf, 36, ymag);
+    _mav_put_float(buf, 40, zmag);
+    _mav_put_float(buf, 44, abs_pressure);
+    _mav_put_float(buf, 48, diff_pressure);
+    _mav_put_float(buf, 52, pressure_alt);
+    _mav_put_float(buf, 56, temperature);
+    _mav_put_uint32_t(buf, 60, fields_updated);
+    _mav_put_uint8_t(buf, 64, id);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIL_SENSOR_LEN);
+#else
+    mavlink_hil_sensor_t packet;
+    packet.time_usec = time_usec;
+    packet.xacc = xacc;
+    packet.yacc = yacc;
+    packet.zacc = zacc;
+    packet.xgyro = xgyro;
+    packet.ygyro = ygyro;
+    packet.zgyro = zgyro;
+    packet.xmag = xmag;
+    packet.ymag = ymag;
+    packet.zmag = zmag;
+    packet.abs_pressure = abs_pressure;
+    packet.diff_pressure = diff_pressure;
+    packet.pressure_alt = pressure_alt;
+    packet.temperature = temperature;
+    packet.fields_updated = fields_updated;
+    packet.id = id;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIL_SENSOR_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIL_SENSOR;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_SENSOR_MIN_LEN, MAVLINK_MSG_ID_HIL_SENSOR_LEN, MAVLINK_MSG_ID_HIL_SENSOR_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_SENSOR_MIN_LEN, MAVLINK_MSG_ID_HIL_SENSOR_LEN);
+#endif
+}
+
 /**
  * @brief Pack a hil_sensor message on a channel
  * @param system_id ID of this system
@@ -254,6 +332,20 @@ static inline uint16_t mavlink_msg_hil_sensor_encode_chan(uint8_t system_id, uin
     return mavlink_msg_hil_sensor_pack_chan(system_id, component_id, chan, msg, hil_sensor->time_usec, hil_sensor->xacc, hil_sensor->yacc, hil_sensor->zacc, hil_sensor->xgyro, hil_sensor->ygyro, hil_sensor->zgyro, hil_sensor->xmag, hil_sensor->ymag, hil_sensor->zmag, hil_sensor->abs_pressure, hil_sensor->diff_pressure, hil_sensor->pressure_alt, hil_sensor->temperature, hil_sensor->fields_updated, hil_sensor->id);
 }
 
+/**
+ * @brief Encode a hil_sensor struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param hil_sensor C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_hil_sensor_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_hil_sensor_t* hil_sensor)
+{
+    return mavlink_msg_hil_sensor_pack_status(system_id, component_id, _status, msg,  hil_sensor->time_usec, hil_sensor->xacc, hil_sensor->yacc, hil_sensor->zacc, hil_sensor->xgyro, hil_sensor->ygyro, hil_sensor->zgyro, hil_sensor->xmag, hil_sensor->ymag, hil_sensor->zmag, hil_sensor->abs_pressure, hil_sensor->diff_pressure, hil_sensor->pressure_alt, hil_sensor->temperature, hil_sensor->fields_updated, hil_sensor->id);
+}
+
 /**
  * @brief Send a hil_sensor message
  * @param chan MAVLink channel to send the message

+ 92 - 0
v2.0/common/mavlink_msg_hil_state.h

@@ -153,6 +153,84 @@ static inline uint16_t mavlink_msg_hil_state_pack(uint8_t system_id, uint8_t com
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIL_STATE_MIN_LEN, MAVLINK_MSG_ID_HIL_STATE_LEN, MAVLINK_MSG_ID_HIL_STATE_CRC);
 }
 
+/**
+ * @brief Pack a hil_state message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param roll [rad] Roll angle
+ * @param pitch [rad] Pitch angle
+ * @param yaw [rad] Yaw angle
+ * @param rollspeed [rad/s] Body frame roll / phi angular speed
+ * @param pitchspeed [rad/s] Body frame pitch / theta angular speed
+ * @param yawspeed [rad/s] Body frame yaw / psi angular speed
+ * @param lat [degE7] Latitude
+ * @param lon [degE7] Longitude
+ * @param alt [mm] Altitude
+ * @param vx [cm/s] Ground X Speed (Latitude)
+ * @param vy [cm/s] Ground Y Speed (Longitude)
+ * @param vz [cm/s] Ground Z Speed (Altitude)
+ * @param xacc [mG] X acceleration
+ * @param yacc [mG] Y acceleration
+ * @param zacc [mG] Z acceleration
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_hil_state_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, float roll, float pitch, float yaw, float rollspeed, float pitchspeed, float yawspeed, int32_t lat, int32_t lon, int32_t alt, int16_t vx, int16_t vy, int16_t vz, int16_t xacc, int16_t yacc, int16_t zacc)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIL_STATE_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 8, roll);
+    _mav_put_float(buf, 12, pitch);
+    _mav_put_float(buf, 16, yaw);
+    _mav_put_float(buf, 20, rollspeed);
+    _mav_put_float(buf, 24, pitchspeed);
+    _mav_put_float(buf, 28, yawspeed);
+    _mav_put_int32_t(buf, 32, lat);
+    _mav_put_int32_t(buf, 36, lon);
+    _mav_put_int32_t(buf, 40, alt);
+    _mav_put_int16_t(buf, 44, vx);
+    _mav_put_int16_t(buf, 46, vy);
+    _mav_put_int16_t(buf, 48, vz);
+    _mav_put_int16_t(buf, 50, xacc);
+    _mav_put_int16_t(buf, 52, yacc);
+    _mav_put_int16_t(buf, 54, zacc);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIL_STATE_LEN);
+#else
+    mavlink_hil_state_t packet;
+    packet.time_usec = time_usec;
+    packet.roll = roll;
+    packet.pitch = pitch;
+    packet.yaw = yaw;
+    packet.rollspeed = rollspeed;
+    packet.pitchspeed = pitchspeed;
+    packet.yawspeed = yawspeed;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.vx = vx;
+    packet.vy = vy;
+    packet.vz = vz;
+    packet.xacc = xacc;
+    packet.yacc = yacc;
+    packet.zacc = zacc;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIL_STATE_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIL_STATE;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_STATE_MIN_LEN, MAVLINK_MSG_ID_HIL_STATE_LEN, MAVLINK_MSG_ID_HIL_STATE_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_STATE_MIN_LEN, MAVLINK_MSG_ID_HIL_STATE_LEN);
+#endif
+}
+
 /**
  * @brief Pack a hil_state message on a channel
  * @param system_id ID of this system
@@ -254,6 +332,20 @@ static inline uint16_t mavlink_msg_hil_state_encode_chan(uint8_t system_id, uint
     return mavlink_msg_hil_state_pack_chan(system_id, component_id, chan, msg, hil_state->time_usec, hil_state->roll, hil_state->pitch, hil_state->yaw, hil_state->rollspeed, hil_state->pitchspeed, hil_state->yawspeed, hil_state->lat, hil_state->lon, hil_state->alt, hil_state->vx, hil_state->vy, hil_state->vz, hil_state->xacc, hil_state->yacc, hil_state->zacc);
 }
 
+/**
+ * @brief Encode a hil_state struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param hil_state C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_hil_state_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_hil_state_t* hil_state)
+{
+    return mavlink_msg_hil_state_pack_status(system_id, component_id, _status, msg,  hil_state->time_usec, hil_state->roll, hil_state->pitch, hil_state->yaw, hil_state->rollspeed, hil_state->pitchspeed, hil_state->yawspeed, hil_state->lat, hil_state->lon, hil_state->alt, hil_state->vx, hil_state->vy, hil_state->vz, hil_state->xacc, hil_state->yacc, hil_state->zacc);
+}
+
 /**
  * @brief Send a hil_state message
  * @param chan MAVLink channel to send the message

+ 90 - 0
v2.0/common/mavlink_msg_hil_state_quaternion.h

@@ -151,6 +151,82 @@ static inline uint16_t mavlink_msg_hil_state_quaternion_pack(uint8_t system_id,
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HIL_STATE_QUATERNION_MIN_LEN, MAVLINK_MSG_ID_HIL_STATE_QUATERNION_LEN, MAVLINK_MSG_ID_HIL_STATE_QUATERNION_CRC);
 }
 
+/**
+ * @brief Pack a hil_state_quaternion message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @param attitude_quaternion  Vehicle attitude expressed as normalized quaternion in w, x, y, z order (with 1 0 0 0 being the null-rotation)
+ * @param rollspeed [rad/s] Body frame roll / phi angular speed
+ * @param pitchspeed [rad/s] Body frame pitch / theta angular speed
+ * @param yawspeed [rad/s] Body frame yaw / psi angular speed
+ * @param lat [degE7] Latitude
+ * @param lon [degE7] Longitude
+ * @param alt [mm] Altitude
+ * @param vx [cm/s] Ground X Speed (Latitude)
+ * @param vy [cm/s] Ground Y Speed (Longitude)
+ * @param vz [cm/s] Ground Z Speed (Altitude)
+ * @param ind_airspeed [cm/s] Indicated airspeed
+ * @param true_airspeed [cm/s] True airspeed
+ * @param xacc [mG] X acceleration
+ * @param yacc [mG] Y acceleration
+ * @param zacc [mG] Z acceleration
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_hil_state_quaternion_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint64_t time_usec, const float *attitude_quaternion, float rollspeed, float pitchspeed, float yawspeed, int32_t lat, int32_t lon, int32_t alt, int16_t vx, int16_t vy, int16_t vz, uint16_t ind_airspeed, uint16_t true_airspeed, int16_t xacc, int16_t yacc, int16_t zacc)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HIL_STATE_QUATERNION_LEN];
+    _mav_put_uint64_t(buf, 0, time_usec);
+    _mav_put_float(buf, 24, rollspeed);
+    _mav_put_float(buf, 28, pitchspeed);
+    _mav_put_float(buf, 32, yawspeed);
+    _mav_put_int32_t(buf, 36, lat);
+    _mav_put_int32_t(buf, 40, lon);
+    _mav_put_int32_t(buf, 44, alt);
+    _mav_put_int16_t(buf, 48, vx);
+    _mav_put_int16_t(buf, 50, vy);
+    _mav_put_int16_t(buf, 52, vz);
+    _mav_put_uint16_t(buf, 54, ind_airspeed);
+    _mav_put_uint16_t(buf, 56, true_airspeed);
+    _mav_put_int16_t(buf, 58, xacc);
+    _mav_put_int16_t(buf, 60, yacc);
+    _mav_put_int16_t(buf, 62, zacc);
+    _mav_put_float_array(buf, 8, attitude_quaternion, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HIL_STATE_QUATERNION_LEN);
+#else
+    mavlink_hil_state_quaternion_t packet;
+    packet.time_usec = time_usec;
+    packet.rollspeed = rollspeed;
+    packet.pitchspeed = pitchspeed;
+    packet.yawspeed = yawspeed;
+    packet.lat = lat;
+    packet.lon = lon;
+    packet.alt = alt;
+    packet.vx = vx;
+    packet.vy = vy;
+    packet.vz = vz;
+    packet.ind_airspeed = ind_airspeed;
+    packet.true_airspeed = true_airspeed;
+    packet.xacc = xacc;
+    packet.yacc = yacc;
+    packet.zacc = zacc;
+    mav_array_memcpy(packet.attitude_quaternion, attitude_quaternion, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HIL_STATE_QUATERNION_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HIL_STATE_QUATERNION;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_STATE_QUATERNION_MIN_LEN, MAVLINK_MSG_ID_HIL_STATE_QUATERNION_LEN, MAVLINK_MSG_ID_HIL_STATE_QUATERNION_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HIL_STATE_QUATERNION_MIN_LEN, MAVLINK_MSG_ID_HIL_STATE_QUATERNION_LEN);
+#endif
+}
+
 /**
  * @brief Pack a hil_state_quaternion message on a channel
  * @param system_id ID of this system
@@ -250,6 +326,20 @@ static inline uint16_t mavlink_msg_hil_state_quaternion_encode_chan(uint8_t syst
     return mavlink_msg_hil_state_quaternion_pack_chan(system_id, component_id, chan, msg, hil_state_quaternion->time_usec, hil_state_quaternion->attitude_quaternion, hil_state_quaternion->rollspeed, hil_state_quaternion->pitchspeed, hil_state_quaternion->yawspeed, hil_state_quaternion->lat, hil_state_quaternion->lon, hil_state_quaternion->alt, hil_state_quaternion->vx, hil_state_quaternion->vy, hil_state_quaternion->vz, hil_state_quaternion->ind_airspeed, hil_state_quaternion->true_airspeed, hil_state_quaternion->xacc, hil_state_quaternion->yacc, hil_state_quaternion->zacc);
 }
 
+/**
+ * @brief Encode a hil_state_quaternion struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param hil_state_quaternion C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_hil_state_quaternion_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_hil_state_quaternion_t* hil_state_quaternion)
+{
+    return mavlink_msg_hil_state_quaternion_pack_status(system_id, component_id, _status, msg,  hil_state_quaternion->time_usec, hil_state_quaternion->attitude_quaternion, hil_state_quaternion->rollspeed, hil_state_quaternion->pitchspeed, hil_state_quaternion->yawspeed, hil_state_quaternion->lat, hil_state_quaternion->lon, hil_state_quaternion->alt, hil_state_quaternion->vx, hil_state_quaternion->vy, hil_state_quaternion->vz, hil_state_quaternion->ind_airspeed, hil_state_quaternion->true_airspeed, hil_state_quaternion->xacc, hil_state_quaternion->yacc, hil_state_quaternion->zacc);
+}
+
 /**
  * @brief Send a hil_state_quaternion message
  * @param chan MAVLink channel to send the message

+ 79 - 0
v2.0/common/mavlink_msg_home_position.h

@@ -129,6 +129,71 @@ static inline uint16_t mavlink_msg_home_position_pack(uint8_t system_id, uint8_t
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HOME_POSITION_MIN_LEN, MAVLINK_MSG_ID_HOME_POSITION_LEN, MAVLINK_MSG_ID_HOME_POSITION_CRC);
 }
 
+/**
+ * @brief Pack a home_position message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param latitude [degE7] Latitude (WGS84)
+ * @param longitude [degE7] Longitude (WGS84)
+ * @param altitude [mm] Altitude (MSL). Positive for up.
+ * @param x [m] Local X position of this position in the local coordinate frame (NED)
+ * @param y [m] Local Y position of this position in the local coordinate frame (NED)
+ * @param z [m] Local Z position of this position in the local coordinate frame (NED: positive "down")
+ * @param q  
+        Quaternion indicating world-to-surface-normal and heading transformation of the takeoff position.
+        Used to indicate the heading and slope of the ground.
+        All fields should be set to NaN if an accurate quaternion for both heading and surface slope cannot be supplied.
+      
+ * @param approach_x [m] Local X position of the end of the approach vector. Multicopters should set this position based on their takeoff path. Grass-landing fixed wing aircraft should set it the same way as multicopters. Runway-landing fixed wing aircraft should set it to the opposite direction of the takeoff, assuming the takeoff happened from the threshold / touchdown zone.
+ * @param approach_y [m] Local Y position of the end of the approach vector. Multicopters should set this position based on their takeoff path. Grass-landing fixed wing aircraft should set it the same way as multicopters. Runway-landing fixed wing aircraft should set it to the opposite direction of the takeoff, assuming the takeoff happened from the threshold / touchdown zone.
+ * @param approach_z [m] Local Z position of the end of the approach vector. Multicopters should set this position based on their takeoff path. Grass-landing fixed wing aircraft should set it the same way as multicopters. Runway-landing fixed wing aircraft should set it to the opposite direction of the takeoff, assuming the takeoff happened from the threshold / touchdown zone.
+ * @param time_usec [us] Timestamp (UNIX Epoch time or time since system boot). The receiving end can infer timestamp format (since 1.1.1970 or since system boot) by checking for the magnitude of the number.
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_home_position_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               int32_t latitude, int32_t longitude, int32_t altitude, float x, float y, float z, const float *q, float approach_x, float approach_y, float approach_z, uint64_t time_usec)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HOME_POSITION_LEN];
+    _mav_put_int32_t(buf, 0, latitude);
+    _mav_put_int32_t(buf, 4, longitude);
+    _mav_put_int32_t(buf, 8, altitude);
+    _mav_put_float(buf, 12, x);
+    _mav_put_float(buf, 16, y);
+    _mav_put_float(buf, 20, z);
+    _mav_put_float(buf, 40, approach_x);
+    _mav_put_float(buf, 44, approach_y);
+    _mav_put_float(buf, 48, approach_z);
+    _mav_put_uint64_t(buf, 52, time_usec);
+    _mav_put_float_array(buf, 24, q, 4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HOME_POSITION_LEN);
+#else
+    mavlink_home_position_t packet;
+    packet.latitude = latitude;
+    packet.longitude = longitude;
+    packet.altitude = altitude;
+    packet.x = x;
+    packet.y = y;
+    packet.z = z;
+    packet.approach_x = approach_x;
+    packet.approach_y = approach_y;
+    packet.approach_z = approach_z;
+    packet.time_usec = time_usec;
+    mav_array_memcpy(packet.q, q, sizeof(float)*4);
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HOME_POSITION_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HOME_POSITION;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HOME_POSITION_MIN_LEN, MAVLINK_MSG_ID_HOME_POSITION_LEN, MAVLINK_MSG_ID_HOME_POSITION_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HOME_POSITION_MIN_LEN, MAVLINK_MSG_ID_HOME_POSITION_LEN);
+#endif
+}
+
 /**
  * @brief Pack a home_position message on a channel
  * @param system_id ID of this system
@@ -217,6 +282,20 @@ static inline uint16_t mavlink_msg_home_position_encode_chan(uint8_t system_id,
     return mavlink_msg_home_position_pack_chan(system_id, component_id, chan, msg, home_position->latitude, home_position->longitude, home_position->altitude, home_position->x, home_position->y, home_position->z, home_position->q, home_position->approach_x, home_position->approach_y, home_position->approach_z, home_position->time_usec);
 }
 
+/**
+ * @brief Encode a home_position struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param home_position C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_home_position_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_home_position_t* home_position)
+{
+    return mavlink_msg_home_position_pack_status(system_id, component_id, _status, msg,  home_position->latitude, home_position->longitude, home_position->altitude, home_position->x, home_position->y, home_position->z, home_position->q, home_position->approach_x, home_position->approach_y, home_position->approach_z, home_position->time_usec);
+}
+
 /**
  * @brief Send a home_position message
  * @param chan MAVLink channel to send the message

+ 53 - 0
v2.0/common/mavlink_msg_hygrometer_sensor.h

@@ -75,6 +75,45 @@ static inline uint16_t mavlink_msg_hygrometer_sensor_pack(uint8_t system_id, uin
     return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_HYGROMETER_SENSOR_MIN_LEN, MAVLINK_MSG_ID_HYGROMETER_SENSOR_LEN, MAVLINK_MSG_ID_HYGROMETER_SENSOR_CRC);
 }
 
+/**
+ * @brief Pack a hygrometer_sensor message
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ *
+ * @param id  Hygrometer ID
+ * @param temperature [cdegC] Temperature
+ * @param humidity [c%] Humidity
+ * @return length of the message in bytes (excluding serial stream start sign)
+ */
+static inline uint16_t mavlink_msg_hygrometer_sensor_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
+                               uint8_t id, int16_t temperature, uint16_t humidity)
+{
+#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
+    char buf[MAVLINK_MSG_ID_HYGROMETER_SENSOR_LEN];
+    _mav_put_int16_t(buf, 0, temperature);
+    _mav_put_uint16_t(buf, 2, humidity);
+    _mav_put_uint8_t(buf, 4, id);
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_HYGROMETER_SENSOR_LEN);
+#else
+    mavlink_hygrometer_sensor_t packet;
+    packet.temperature = temperature;
+    packet.humidity = humidity;
+    packet.id = id;
+
+        memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_HYGROMETER_SENSOR_LEN);
+#endif
+
+    msg->msgid = MAVLINK_MSG_ID_HYGROMETER_SENSOR;
+#if MAVLINK_CRC_EXTRA
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HYGROMETER_SENSOR_MIN_LEN, MAVLINK_MSG_ID_HYGROMETER_SENSOR_LEN, MAVLINK_MSG_ID_HYGROMETER_SENSOR_CRC);
+#else
+    return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_HYGROMETER_SENSOR_MIN_LEN, MAVLINK_MSG_ID_HYGROMETER_SENSOR_LEN);
+#endif
+}
+
 /**
  * @brief Pack a hygrometer_sensor message on a channel
  * @param system_id ID of this system
@@ -137,6 +176,20 @@ static inline uint16_t mavlink_msg_hygrometer_sensor_encode_chan(uint8_t system_
     return mavlink_msg_hygrometer_sensor_pack_chan(system_id, component_id, chan, msg, hygrometer_sensor->id, hygrometer_sensor->temperature, hygrometer_sensor->humidity);
 }
 
+/**
+ * @brief Encode a hygrometer_sensor struct with provided status structure
+ *
+ * @param system_id ID of this system
+ * @param component_id ID of this component (e.g. 200 for IMU)
+ * @param status MAVLink status structure
+ * @param msg The MAVLink message to compress the data into
+ * @param hygrometer_sensor C-struct to read the message contents from
+ */
+static inline uint16_t mavlink_msg_hygrometer_sensor_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_hygrometer_sensor_t* hygrometer_sensor)
+{
+    return mavlink_msg_hygrometer_sensor_pack_status(system_id, component_id, _status, msg,  hygrometer_sensor->id, hygrometer_sensor->temperature, hygrometer_sensor->humidity);
+}
+
 /**
  * @brief Send a hygrometer_sensor message
  * @param chan MAVLink channel to send the message

Beberapa file tidak ditampilkan karena terlalu banyak file yang berubah dalam diff ini