From a0189d606079fcabcc596a59d1053879c82802ea Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Tue, 12 Feb 2019 19:08:27 +1100 Subject: [PATCH] Copter: AP_Frsky_Telem uses singletons --- ArduCopter/Copter.h | 2 +- ArduCopter/system.cpp | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/ArduCopter/Copter.h b/ArduCopter/Copter.h index 179d97d57b..82cafed311 100644 --- a/ArduCopter/Copter.h +++ b/ArduCopter/Copter.h @@ -412,7 +412,7 @@ private: #if FRSKY_TELEM_ENABLED == ENABLED // FrSky telemetry support - AP_Frsky_Telem frsky_telemetry{ahrs, battery, rangefinder}; + AP_Frsky_Telem frsky_telemetry; #endif #if DEVO_TELEM_ENABLED == ENABLED AP_DEVO_Telem devo_telemetry{ahrs}; diff --git a/ArduCopter/system.cpp b/ArduCopter/system.cpp index 6fc1693197..443edd20f4 100644 --- a/ArduCopter/system.cpp +++ b/ArduCopter/system.cpp @@ -91,8 +91,7 @@ void Copter::init_ardupilot() #if FRSKY_TELEM_ENABLED == ENABLED // setup frsky, and pass a number of parameters to the library - frsky_telemetry.init(serial_manager, - get_frame_mav_type(), + frsky_telemetry.init(get_frame_mav_type(), &ap.value); frsky_telemetry.set_frame_string(get_frame_string()); #endif