From 89936bab3d2bf3f9d1b7d4362180ad024aa846b4 Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Wed, 13 Nov 2024 08:09:59 +1100 Subject: [PATCH] SRV_Channel: make SRV_Channels::cork non-static for symmetry with the push function --- libraries/SRV_Channel/SRV_Channel.h | 3 +-- libraries/SRV_Channel/SRV_Channels.cpp | 5 +++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/libraries/SRV_Channel/SRV_Channel.h b/libraries/SRV_Channel/SRV_Channel.h index e19c52a4bf..e4778b2773 100644 --- a/libraries/SRV_Channel/SRV_Channel.h +++ b/libraries/SRV_Channel/SRV_Channel.h @@ -538,9 +538,8 @@ public: } return SRV_Channel::Aux_servo_function_t((SRV_Channel::k_motor9+(channel-8))); } - - static void cork(); + void cork(); void push(); // disable PWM output to a set of channels given by a mask. This is used by the AP_BLHeli code diff --git a/libraries/SRV_Channel/SRV_Channels.cpp b/libraries/SRV_Channel/SRV_Channels.cpp index 3ef0c7e343..c1fda6226c 100644 --- a/libraries/SRV_Channel/SRV_Channels.cpp +++ b/libraries/SRV_Channel/SRV_Channels.cpp @@ -545,11 +545,12 @@ void SRV_Channels::zero_rc_outputs() * send an invalid signal to all channels to prevent * undesired/unexpected behavior */ - cork(); + auto &srv = AP::srv(); + srv.cork(); for (uint8_t i=0; iwrite(i, 0); } - AP::srv().push(); + srv.push(); } /*