Copter: AP_Frsky_Telem uses singletons

This commit is contained in:
Peter Barker 2019-02-12 19:08:27 +11:00 committed by Francisco Ferreira
parent 9023e6eb7d
commit a0189d6060
2 changed files with 2 additions and 3 deletions

View File

@ -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};

View File

@ -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