mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-24 09:38:29 -04:00
ArduPlane: create and use a singleton for SRV_Channels
avoid creation of static pointers to objects held within SRV_Channels
This commit is contained in:
parent
7888212c74
commit
9ef17dffab
@ -349,7 +349,7 @@ void Plane::one_second_loop()
|
||||
// sync MAVLink system ID
|
||||
mavlink_system.sysid = g.sysid_this_mav;
|
||||
|
||||
SRV_Channels::enable_aux_servos();
|
||||
AP::srv().enable_aux_servos();
|
||||
|
||||
// update notify flags
|
||||
AP_Notify::flags.pre_arm_check = arming.pre_arm_checks(false);
|
||||
|
@ -107,7 +107,7 @@ void Plane::init_rc_out_main()
|
||||
*/
|
||||
void Plane::init_rc_out_aux()
|
||||
{
|
||||
SRV_Channels::enable_aux_servos();
|
||||
AP::srv().enable_aux_servos();
|
||||
|
||||
servos_output();
|
||||
|
||||
|
@ -1050,7 +1050,7 @@ void Plane::servos_output(void)
|
||||
|
||||
SRV_Channels::output_ch_all();
|
||||
|
||||
SRV_Channels::push();
|
||||
AP::srv().push();
|
||||
|
||||
if (g2.servo_channels.auto_trim_enabled()) {
|
||||
servos_auto_trim();
|
||||
|
Loading…
Reference in New Issue
Block a user