Copter: add support for 4th mavlink channel

This commit is contained in:
Randy Mackay 2015-05-15 13:24:18 +09:00
parent 35275aab85
commit d8b7e4a199
3 changed files with 12 additions and 0 deletions

View File

@ -193,6 +193,7 @@ public:
k_param_ch11_option,
k_param_ch12_option, // 123
k_param_takeoff_trigger_dz,
k_param_gcs3, // 125
//
// 140: Sensor parameters

View File

@ -884,6 +884,12 @@ const AP_Param::Info var_info[] PROGMEM = {
GOBJECTN(gcs[2], gcs2, "SR2_", GCS_MAVLINK),
#endif
#if MAVLINK_COMM_NUM_BUFFERS > 3
// @Group: SR3_
// @Path: GCS_Mavlink.pde
GOBJECTN(gcs[3], gcs3, "SR3_", GCS_MAVLINK),
#endif
// @Group: AHRS_
// @Path: ../libraries/AP_AHRS/AP_AHRS.cpp
GOBJECT(ahrs, "AHRS_", AP_AHRS),

View File

@ -139,6 +139,11 @@ static void init_ardupilot()
gcs[2].setup_uart(serial_manager, AP_SerialManager::SerialProtocol_MAVLink, 1);
#endif
#if MAVLINK_COMM_NUM_BUFFERS > 3
// setup serial port for fourth telemetry port (not used by default)
gcs[3].setup_uart(serial_manager, AP_SerialManager::SerialProtocol_MAVLink, 2);
#endif
#if FRSKY_TELEM_ENABLED == ENABLED
// setup frsky
frsky_telemetry.init(serial_manager);