Browse Source

SRV_Channel: added k_throttleLeft and k_throttleRight

support for differential thrust for yaw in twin engine planes
mission-4.1.18
Andrew Tridgell 8 years ago
parent
commit
584fbf629b
  1. 2
      libraries/SRV_Channel/SRV_Channel.cpp
  2. 2
      libraries/SRV_Channel/SRV_Channel.h
  3. 2
      libraries/SRV_Channel/SRV_Channel_aux.cpp

2
libraries/SRV_Channel/SRV_Channel.cpp

@ -64,7 +64,7 @@ const AP_Param::GroupInfo SRV_Channel::var_info[] = { @@ -64,7 +64,7 @@ const AP_Param::GroupInfo SRV_Channel::var_info[] = {
// @Param: FUNCTION
// @DisplayName: Servo output function
// @Description: Function assigned to this servo. Seeing this to Disabled(0) will setup this output for control by auto missions or MAVLink servo set commands. any other value will enable the corresponding function
// @Values: 0:Disabled,1:RCPassThru,2:Flap,3:Flap_auto,4:Aileron,6:mount_pan,7:mount_tilt,8:mount_roll,9:mount_open,10:camera_trigger,11:release,12:mount2_pan,13:mount2_tilt,14:mount2_roll,15:mount2_open,16:DifferentialSpoiler1,17:DifferentialSpoiler2,18:AileronWithInput,19:Elevator,20:ElevatorWithInput,21:Rudder,24:Flaperon1,25:Flaperon2,26:GroundSteering,27:Parachute,28:EPM,29:LandingGear,30:EngineRunEnable,31:HeliRSC,32:HeliTailRSC,33:Motor1,34:Motor2,35:Motor3,36:Motor4,37:Motor5,38:Motor6,39:Motor7,40:Motor8,51:RCIN1,52:RCIN2,53:RCIN3,54:RCIN4,55:RCIN5,56:RCIN6,57:RCIN7,58:RCIN8,59:RCIN9,60:RCIN10,61:RCIN11,62:RCIN12,63:RCIN13,64:RCIN14,65:RCIN15,66:RCIN16,67:Ignition,68:Choke,69:Starter,70:Throttle,71:TrackerYaw,72:TrackerPitch
// @Values: 0:Disabled,1:RCPassThru,2:Flap,3:Flap_auto,4:Aileron,6:mount_pan,7:mount_tilt,8:mount_roll,9:mount_open,10:camera_trigger,11:release,12:mount2_pan,13:mount2_tilt,14:mount2_roll,15:mount2_open,16:DifferentialSpoiler1,17:DifferentialSpoiler2,18:AileronWithInput,19:Elevator,20:ElevatorWithInput,21:Rudder,24:Flaperon1,25:Flaperon2,26:GroundSteering,27:Parachute,28:EPM,29:LandingGear,30:EngineRunEnable,31:HeliRSC,32:HeliTailRSC,33:Motor1,34:Motor2,35:Motor3,36:Motor4,37:Motor5,38:Motor6,39:Motor7,40:Motor8,51:RCIN1,52:RCIN2,53:RCIN3,54:RCIN4,55:RCIN5,56:RCIN6,57:RCIN7,58:RCIN8,59:RCIN9,60:RCIN10,61:RCIN11,62:RCIN12,63:RCIN13,64:RCIN14,65:RCIN15,66:RCIN16,67:Ignition,68:Choke,69:Starter,70:Throttle,71:TrackerYaw,72:TrackerPitch,73:ThrottleLeft,74:ThrottleRight
// @User: Standard
AP_GROUPINFO("FUNCTION", 5, SRV_Channel, function, 0),

2
libraries/SRV_Channel/SRV_Channel.h

@ -101,6 +101,8 @@ public: @@ -101,6 +101,8 @@ public:
k_throttle = 70,
k_tracker_yaw = 71, ///< antennatracker yaw
k_tracker_pitch = 72, ///< antennatracker pitch
k_throttleLeft = 73,
k_throttleRight = 74,
k_nr_aux_servo_functions ///< This must be the last enum value (only add new values _before_ this one)
} Aux_servo_function_t;

2
libraries/SRV_Channel/SRV_Channel_aux.cpp

@ -109,6 +109,8 @@ void SRV_Channel::aux_servo_function_setup(void) @@ -109,6 +109,8 @@ void SRV_Channel::aux_servo_function_setup(void)
set_angle(4500);
break;
case k_throttle:
case k_throttleLeft:
case k_throttleRight:
// fixed wing throttle
set_range(100);
break;

Loading…
Cancel
Save