Andrew Tridgell
b187a0c6eb
AP_Motors: added quadplane frame type
...
this puts the motors on outputs 5 to 8, to leave the first 4 for the
plane
2016-01-09 07:38:51 +11:00
Andrew Tridgell
7c9ee9363b
AP_Motors: added rc_map_mask() function
2016-01-06 22:09:40 +11:00
Andrew Tridgell
dfccf8f713
AP_Motors: also wrap set_freq and enable_ch for motor mapping
2016-01-06 22:09:40 +11:00
Andrew Tridgell
77af00c5e1
AP_Motors: allow arbitrary mapping of channels on multirotors
...
using RCn_FUNCTION with motor1, motor2 etc
2016-01-06 22:09:40 +11:00
Andrew Tridgell
d31ba2b380
AP_Motors: added rc_write function
...
this is intended to make remapping motors and rescaling output easier
2016-01-04 16:56:54 +11:00
Lucas De Marchi
5244559010
Minimize AP_Progmem.h includes
...
Most of AP_Progmem is already gone so we can stop including it in most
of the places. The only places that need it are the ones using
pgm_read_*() APIs.
In some cases the header needed to be added in the .cpp since it was
removed from the .h to reduce scope. In those cases the headers were
also reordered.
2015-10-30 14:35:32 +09:00
Lucas De Marchi
d97d97dc54
AP_Motors: get rid of _motor_to_channel_map
...
This was only used for supporting APM1. The removal was mostly automatic
with:
sed -i 's/pgm_read_byte(&_motor_to_channel_map\[\([^]]*\)\])/\1/g' libraries/AP_Motors/*.cpp
sed -i 's/_motor_to_channel_map\[\([^]]*\)\]/\1/g' libraries/AP_Motors/*.cpp
And then remove references to MOTOR_TO_CHANNEL_MAP and
_motor_to_channel_map and make sure the variable used in shifts is
unsigned
2015-09-29 11:59:25 +09:00
Gustavo Jose de Sousa
1e619c6c59
AP_Motors: standardize inclusion of libaries headers
...
This commit changes the way libraries headers are included in source files:
- If the header is in the same directory the source belongs to, so the
notation '#include ""' is used with the path relative to the directory
containing the source.
- If the header is outside the directory containing the source, then we use
the notation '#include <>' with the path relative to libraries folder.
Some of the advantages of such approach:
- Only one search path for libraries headers.
- OSs like Windows may have a better lookup time.
2015-08-11 16:38:19 +10:00
Leonard Hall
1a583c5382
AP_Motors: calc_roll_pwm based on throttle pwm range
2015-08-03 14:12:49 +09:00
Randy Mackay
c9dedbd3b2
AP_Motors: remove multicopter only features
...
Also rename uses of Multirotor to Multicopter
2015-07-21 16:25:28 +09:00
Robert Lefebvre
61d6c5aa1d
AP_Motors: Creation of AP_Motors_Multirotor class
2015-07-21 16:24:38 +09:00
Randy Mackay
8225e58454
AP_Motors: throttle_min method in 0 to 1000 range
...
Previously the pwm range value was returned. This value is only used by
the multicopter attitude controller's angle boost function.
2015-07-20 20:44:46 +09:00
Robert Lefebvre
11214b3414
AP_Motors: move constraints to set_throttle
2015-06-22 13:52:59 +09:00
Randy Mackay
71e4bccecb
AP_Motors: init members in constructor
...
Also add f to end of float constants
2015-05-25 22:13:41 +09:00
Robert Lefebvre
b8181b6b90
AP_Motors: RCMAP fix
...
Remove all RC Input channels passed as reference into AP_Motors. All input handling self-contained inside AP_Motors.
Rework Tricopter to use internal servo calcs.
2015-05-25 22:13:32 +09:00
Robert Lefebvre
73bafa131e
AP_MotorsHeli: Overload output()
...
To protect it from future interference from Multirotor code.
2015-05-22 09:38:23 +09:00
Robert Lefebvre
d3ce68a8ca
AP_MotorsHeli: Overload update_throttle_filter()
...
Do not reset filter to zero when disarmed to allow collective pitch servo movement.
2015-05-22 09:38:20 +09:00
Randy Mackay
68b05a4ca2
AP_Motors: is_throttle_mix_min returns bol
2015-05-08 14:14:32 +09:00
Leonard Hall
0f894ac1a8
AP_Motors: Rename and move Throttle Mix / Comp
2015-05-08 14:14:17 +09:00
Andrew Tridgell
2e57c62ebb
AP_Motors: fix for HAL_SITL rename
2015-05-05 09:45:55 +10:00
Randy Mackay
0acc06d713
AP_Motors: minor comment for interlock
2015-05-01 14:30:45 +09:00
Robert Lefebvre
6bdace30d2
AP_Motors: Add throttle interlock functionality
...
AP_MotorsMatrix's output_armed_zero_throttle uses output_min default from base class
2015-05-01 14:30:24 +09:00
Jonathan Challinger
348001e786
AP_Motors: add get_throttle_warn function
2015-05-01 12:56:11 +09:00
Jonathan Challinger
41ae7207c7
AP_Motors: scale roll/pitch/yaw gain for air density
2015-04-29 14:36:15 +09:00
Jonathan Challinger
a07b322d31
AP_Motors: set_throttle takes a float
2015-04-24 16:30:45 +09:00
Jonathan Challinger
4993fd4d71
AP_Motors: use new lowpass filter
2015-04-17 10:46:47 +09:00
Jonathan Challinger
e80776f1f5
AP_Motors: remove MOT_THR_FILT parameter and add interface to configure filter
2015-04-16 21:00:01 +09:00
Jonathan Challinger
8e442675a7
AP_Motors: introduce set_stabilize(bool), specifies whether torque demands should be output
2015-04-16 20:59:40 +09:00
Jonathan Challinger
a2c69fe90d
AP_Motors: add optional motor output throttle filter
2015-04-16 20:59:31 +09:00
Leonard Hall
88be3d67e7
AP_Motors: add get for throttle comp
2015-04-16 13:29:50 +09:00
Jonathan Challinger
89cdd02f58
AP_Motors: remove duplicate get_throttle function
2015-04-01 10:15:05 -07:00
Jonathan Challinger
0e53c0a892
AP_Motors: make output_armed() and output_disarmed() pure virtual
2015-04-01 10:14:38 -07:00
Randy Mackay
5e26450a6f
AP_Motors: make THR_LOW_COMP a variable instead of param
2015-03-10 12:20:27 +09:00
Leonard Hall
007c96a3d8
AP_Motors: Low throttle compensation setters
2015-03-10 12:20:21 +09:00
Leonard Hall
11a19803e0
Motors: add accessors for motor logging
...
accessor include get_roll, get_pitch, get_yaw, throttle input
2015-03-06 14:01:58 +09:00
Leonard Hall
3e960dfc3b
Motors: add get_voltage_comp_gain
...
This clarifies that lift_max is the inverse of the battery voltage gain
compensation
2015-03-03 15:49:04 +09:00
Leonard Hall
997c6f0868
Motors: move battery resistance calcs to parent
...
Moving from MotorsMatrix to parent Motors class allows these to be used
from other frame types
Also initialise battery resistance
2015-03-03 15:49:02 +09:00
Randy Mackay
09d7cdbc23
Motors: batt_voltage_filt becomes filter object
2015-03-03 15:49:00 +09:00
Leonard Hall
529c6fed3a
Motors: move over current throttle limiting to parent
...
Moving from MotorsMatrix to parent Motors class allows this to be used
from other frame types
2015-03-03 15:48:54 +09:00
Randy Mackay
1a9d3125ef
Motors: _hover_out to pct * 10 instead of pwm
2015-03-03 15:48:50 +09:00
Leonard Hall
6b7bdf64bd
Motors: move batt voltage lift_max calcs to parent
...
Moving from MotorsMatrix to parent Motors class allows them to be used
by other frame types
Also added sanity check of batt_voltage_min
2015-03-03 15:48:48 +09:00
Randy Mackay
2eaa4a8445
Motors: remove old throttle curve
2015-03-03 15:48:42 +09:00
Leonard Hall
751dbb7df7
Motors: move thrust curve and volt scaling to parent
...
Moving from MotorsMatrix to Motors allows it to be used from other frames
2015-03-03 15:48:41 +09:00
Randy Mackay
77d4b3a2ae
Motors: add loop_rate to constructor
2015-03-03 15:48:32 +09:00
Leonard Hall
1d0ee68116
Motors: over current throttle limiting
2015-03-03 15:48:28 +09:00
Randy Mackay
f6523c0997
Motors: Add THR_LOW_CMP to adjust low throttle inputs affect on attitude control
2015-03-03 15:48:21 +09:00
Leonard Hall
83e3e2fec2
Motors: thrust curve and voltage scaling for matrix supported frames
2015-03-03 15:48:19 +09:00
Leonard Hall
5b0bd49ff2
Motors: configurable yaw headroom for matrix frames
2015-03-03 15:48:15 +09:00
Randy Mackay
677f6cce7f
AP_Motors: reduce slow-start increment for fast CPUs
2014-10-18 20:54:08 +09:00
Jason Short
b57539a9ad
AP_Motors: throttle_pass_through accepts pwm
2014-09-19 22:21:45 +09:00