Andrew Tridgell
11975223dd
AP_Motors: added H_RSC_POWER_NEGC and H_RSC_SLEWRATE
...
this gives more control over throttle for petrol
helis. H_RSC_POWER_NEGC allows for a asymmetric V-curve, which allows
for less power being put into the head when landing or when sitting on
the ground. That can lead to significantly less vibration and chance
of ground oscillation. A heli not being flown with aerobatics does not
need to use high throttle at negative collective pitch.
The H_RSC_SLEWRATE allows for a maximum throttle slew rate to be
set. Some petrol motors can cut if the throttle is moved too
quickly. We had this happen at a height of 6m when switching from
ALT_HOLD to STABILIZE mode. It also lowers the chance of the blades
skewing in their holders with the sudden change of power when the heli
is disarmed. In general it is a bad idea to do instantaneous large
movements of a IC engine throttle.
2016-07-03 18:29:05 +10:00
Andrew Tridgell
bc7488e2f2
AP_Motors: fixed typos
2016-07-01 15:35:29 +10:00
Leonard Hall
fe68fe65e2
AP_Motors: Single and Coax fix flap gains
2016-07-01 12:45:14 +09:00
Leonard Hall
ba2382c409
AP_MotorsCoax: Fix servo 3 and 4 feed through sign
2016-06-20 09:45:17 +09:00
Andrew Tridgell
7a9b4c7572
AP_Motors: fixed motor load calculation
...
scale to 1.0 for max collective
2016-06-19 13:50:04 +10:00
Randy Mackay
e185bab775
AP_MotorsMulticopter: add HOVER_LEARN option to learn but not save
2016-06-18 11:55:49 +09:00
Randy Mackay
23f8227e36
AP_Motors: bug fix to save params on disarm
...
Previously was saving during arming as well as disarming.
Thanks to OXINARF for finding this!
2016-06-18 11:55:49 +09:00
Randy Mackay
a2ffd9ec7d
AP_MotorsMulticopter: fix comment for get_throttle_limit function
2016-06-18 11:55:49 +09:00
Randy Mackay
a1b573ed0a
AP_Motors: rename throttle_ave_max to throttle_avg_max
2016-06-18 11:55:49 +09:00
Randy Mackay
ef106e4b0f
AP_Motors: spool_mode moved out of flags struction
...
No functional change
2016-06-18 11:55:49 +09:00
Leonard Hall
8fff32bde3
AP_MotorsSingle: fix stability patch use of throttle_hover
2016-06-18 11:55:49 +09:00
Leonard Hall
e0f9fc8e40
AP_MotorsSingle: rename rpy_scale, thrust_min_rpy variables
...
No functional change
2016-06-18 11:55:49 +09:00
Leonard Hall
da05902805
AP_MotorsCoax: fix stability patch use of throttle_hover
2016-06-18 11:55:49 +09:00
Leonard Hall
9bc866e771
AP_MotorsCoax: rename rpy_scale internal variable
...
No functional change
2016-06-18 11:55:49 +09:00
Leonard Hall
8bdb906b2b
AP_MotorsCoax: fixes negative thrust
2016-06-18 11:55:49 +09:00
Randy Mackay
71d1818103
AP_MotorsMulticopter: minor comment update
2016-06-18 11:55:49 +09:00
Randy Mackay
818965fa57
AP_MotorsMulticopter: output_to_motors and output_logic become protected
2016-06-18 11:55:49 +09:00
Leonard Hall
02881b59ff
AP_MotorsMulti: float constants
2016-06-18 11:55:49 +09:00
Randy Mackay
79a73a5c2f
AP_Motors: fix example sketch
...
No need to set throttle_mix nor throttle_min
2016-06-18 11:55:49 +09:00
Leonard Hall
bee6c29b89
AP_MotorsMulticopter: current limit keeps battery from sagging below BAT_VOLT_MIN
2016-06-18 11:55:49 +09:00
Leonard Hall
be25ac4acf
AP_MotorsMulticopter: Add current limit time constant variable
2016-06-18 11:55:49 +09:00
Leonard Hall
7e0e0ca874
AP_MotorsMulticopter: battery voltage compensation improvements
2016-06-18 11:55:49 +09:00
Leonard Hall
0ee7b00b0b
AP_MotorsMulticopter: rename _thrust_curve_min to spin_min
2016-06-18 11:55:49 +09:00
Leonard Hall
142a67bb6d
AP_MotorsMulticopter: minor comment change
2016-06-18 11:55:49 +09:00
Leonard Hall
5cace33ca5
AP_MotorsMulticopter: SPIN_MIN replaces min_throttle
2016-06-18 11:55:49 +09:00
Leonard Hall
2c811364d3
AP_MotorsMulticopter: SPIN_ARM param replaces SPIN_ARMED
2016-06-18 11:55:49 +09:00
Leonard Hall
488f90b39d
AP_Motors: add calc_spin_up_to_pwm to reduce repeated code
2016-06-18 11:55:49 +09:00
Randy Mackay
25778a24e2
AP_MotorsMulticopter: add HOVER_LEARN param
2016-06-18 11:55:49 +09:00
Leonard Hall
4f0db2bc36
AP_Motors: learned THST_HOVER replace THR_MID
...
This holds the estimated thrust required for the vehicle to hover
expressed as a number from 0 to 1. 0 will be equivalent to outputting
SPIN_MIN (which is a number from 0~1 but in the full output range) and 1 is equivalent to SPIN_MAX (also 0~1 but in the full output range)
2016-06-18 11:55:49 +09:00
Leonard Hall
5a8fc6283e
AP_Motors: replace throttle_rpy_mix with throttle_avg
...
AC_AttitudeControl now calculates throttle vs attitude control
prioritisation and simply provides overall maximum throttle (aka
throttle_avg) to the motors library
2016-06-18 11:55:49 +09:00
Andrew Tridgell
255bda9f9c
AP_Motors: allow setting of loop rate
...
this allows for SCHED_LOOP_RATE in copter
2016-06-17 15:01:18 +10:00
Leonard Hall
b3fcab8044
AP_Motors: minor comment fix
2016-06-09 09:49:00 +09:00
Andrew Tridgell
f58d837026
AP_Motors: fixed heli RSC output range and float conversion
...
adds H_RSC_PWM_MIN, H_RSC_PWM_MAX and H_RSC_PWM_REV
2016-06-04 18:33:36 +10:00
Leonard Hall
a16018f9fe
AP_Motors: Missed Single fix
2016-05-31 12:44:17 +10:00
Leonard Hall
d67f83559c
AP_Motors: Single and Coax Fixes
2016-05-29 16:12:29 +10:00
Randy Mackay
72b86a3f99
AP_Motors: remove unused stabilizing flag
...
Also initialise some members to resolve converity warnings
2016-05-28 15:45:29 +09:00
Andrew Tridgell
a2ed8fb313
AP_Motors: prevent negative thrust
...
this prevents a sqrt of a negative number
2016-05-26 17:09:11 +10:00
Andrew Tridgell
6855899cbf
AP_Motors: fixed servo constructor for coax
2016-05-26 16:41:16 +10:00
Andrew Tridgell
4e5e301c4e
AP_Motors: fixed servo constructor for heli
2016-05-26 16:41:06 +10:00
Andrew Tridgell
f9fb098222
AP_Motors: fixed channel output for SingleCopter
2016-05-26 16:26:43 +10:00
Andrew Tridgell
65eb9ceb32
AP_Motors: expose min/max pwm
2016-05-26 14:33:57 +10:00
Andrew Tridgell
a44b0e0011
AP_Motors: don't setup oneshot for a zero output mask
2016-05-26 12:18:49 +10:00
Fredrik Hedberg
75d5c87788
AP_Motors: Fix setpoint bug with 0~1 conversion in AP_MotorsHeli
2016-05-25 09:27:40 +09:00
Randy Mackay
8d1f50e78f
AP_Motors: rename get_pwm_min to get_pwm_output_min
2016-05-24 10:00:25 +09:00
Randy Mackay
0c225cf498
AP_MotorsMulticopter: fix typo in comments
2016-05-24 10:00:25 +09:00
Randy Mackay
ff93524ba4
AP_Motors: rename MOT_THST_MAX to MOT_SPIN_MAX
...
Also renamed:
MOT_THST_BAT_MIN,MAX to MOT_BAT_VOLT_MIN,MAX
MOT_CURR_MAX to MOT_BAT_CURR_MAX
2016-05-24 10:00:25 +09:00
Randy Mackay
f1cbdbe914
AP_Motors: update some comments
2016-05-24 10:00:25 +09:00
Randy Mackay
49b14b3cb6
AP_Motors: add PWM_MIN, MAX
...
These parameters allow the motor PWM output range to be different from receiver's throttle input range
Also renamed throttle_pass_through to set_throttle_passthrough_for_esc_calibration and change the method's input to the 0 to 1 range instead of direct PWM value
2016-05-24 10:00:25 +09:00
Ricardo de Almeida Gonzaga
2802775e7d
AP_Motors: Fix typos
2016-05-13 19:20:06 -03:00
Andrew Tridgell
60b3625950
AP_Motors: added hook for vehicle based thrust compensation
...
allow vehicle code to compensate for thrust effectiveness changes due
to properties outside the scope of AP_Motors. This allows for
compensation in tiltrotors and tiltwings.
2016-05-11 05:55:23 +10:00