mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-26 06:13:35 +08:00
mavlink_receiver: remove unused decode_switch_pos function
This commit is contained in:
committed by
Daniel Agar
parent
7baeb78964
commit
fabeb22ae4
@@ -1894,13 +1894,6 @@ MavlinkReceiver::handle_message_trajectory_representation_waypoints(mavlink_mess
|
|||||||
_trajectory_waypoint_pub.publish(trajectory_waypoint);
|
_trajectory_waypoint_pub.publish(trajectory_waypoint);
|
||||||
}
|
}
|
||||||
|
|
||||||
switch_pos_t
|
|
||||||
MavlinkReceiver::decode_switch_pos(uint16_t buttons, unsigned sw)
|
|
||||||
{
|
|
||||||
// This 2-bit method should be used in the future: (buttons >> (sw * 2)) & 3;
|
|
||||||
return (buttons & (1 << sw)) ? manual_control_setpoint_s::SWITCH_POS_ON : manual_control_setpoint_s::SWITCH_POS_OFF;
|
|
||||||
}
|
|
||||||
|
|
||||||
int
|
int
|
||||||
MavlinkReceiver::decode_switch_pos_n(uint16_t buttons, unsigned sw)
|
MavlinkReceiver::decode_switch_pos_n(uint16_t buttons, unsigned sw)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -205,11 +205,6 @@ private:
|
|||||||
int set_message_interval(int msgId, float interval, int data_rate = -1);
|
int set_message_interval(int msgId, float interval, int data_rate = -1);
|
||||||
void get_message_interval(int msgId);
|
void get_message_interval(int msgId);
|
||||||
|
|
||||||
/**
|
|
||||||
* Decode a switch position from a bitfield.
|
|
||||||
*/
|
|
||||||
switch_pos_t decode_switch_pos(uint16_t buttons, unsigned sw);
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Decode a switch position from a bitfield and state.
|
* Decode a switch position from a bitfield and state.
|
||||||
*/
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user