Silvan Fuhrer
889a2fddea
FW Position Control: remove unnsed params
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 19:06:07 +02:00
Silvan Fuhrer
e3e021a1c2
FW Attitude Control: rename att_control to angular_acceleration_setpoint
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
e595952ed4
FW Attitude Control: add @brief, @param and @return for control_attitude()
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
f67d80460f
FW Attitude controller: update copyright headers
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Jaeyoung Lim
bcdf61b65f
Fix format
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
b87afb138c
Update src/modules/fw_att_control/FixedwingAttitudeControl.cpp
...
reduce code duplication
Co-authored-by: Mathieu Bresciani <brescianimathieu@gmail.com >
2022-08-19 09:40:48 +02:00
Jaeyoung Lim
70134296ed
Fix parameter description from review comments
...
This commit makes the parameter description of the fixewing attitude controller more descriptive
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
c54f62e17a
FW attitude control: fix ff terms and constrain outputs to (-1, 1)
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
dadd4f39ad
FW attitude control: fix yaw rate publishing
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
6724e4af26
FW attitude control: manual stick input sets yaw rate setpoint, not rudder directly
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
22067a1128
FW attitude control: set FF gains for rate controller to 0 as FF controls is handles outside
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
57e052d02d
FW attitdue controller: use allocator status for anti-windup
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
6aab44e425
ControlAllocator: publish allocator_status from all active matrices (2 for VTOL, otherwise 1)
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
a9b848cae3
FW attitue controller: fix publishing of rate controller status
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
5a2127d026
fixed-wing: update rate controller integrator handling
...
-always reset roll/pitch/yaw integrators at the same time
-reset them while waiting for launch or during FW Takeoff before Climbout
-reset wheel rate integrator only when disarmed
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
cd080289c6
FW attitude controller: constrain rates correctly
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
15c95a7b6a
FW attitude controller: improve readability and fix euler rate sp vs. body rate sp
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Silvan Fuhrer
e0a998e6ad
FW attitude controller: remove unused control_input.scaler
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Jaeyoung Lim
33d068cfb2
Added feedforward terms in fw att control
2022-08-19 09:40:48 +02:00
Jaeyoung Lim
958c61dbba
Populate rate control setpoints properly
2022-08-19 09:40:48 +02:00
JaeyoungLim
6f24f4cd1c
Update src/modules/fw_att_control/fw_att_control_params.c
...
Co-authored-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-19 09:40:48 +02:00
Jaeyoung Lim
dcff481219
Map derivative gains for rate controls
2022-08-19 09:40:48 +02:00
Jaeyoung-Lim
f2877ce585
Replace rate controller with RateControlLibrary
...
This commit makes the fw attitude controller take share the rate controller as a library with the mc_rate_control module
2022-08-19 09:40:48 +02:00
bresch
02c4e0361c
MCPosControl: fix horizontal anti-reset windup algirithm
...
Since the horizontal and vertical velocity controllers are now
decoupled, it can be that the horizontal acceleration produced by the
controller is actually greater than the desired one (by design). This
condition would actually make the ARW run "backwards", degrading the
controller performance.
2022-08-18 14:19:10 +02:00
mcsauder
87a5705960
Rename math::gradual() to math::interpolate() and add unit tests to cover additional corner cases.
2022-08-18 14:18:02 +02:00
Junwoo Hwang
d7a962b426
mavlink: fix PX4_DEBUG message formats
2022-08-12 09:43:12 +02:00
Silvan Fuhrer
ffb8fb4383
Allocation: add SteeringWheel type control surface
...
Directly use yaw controls for it, and don't add it to the allocation matrix,
as that would have an effect on rudder scaling if the wheel also would have
a yaw effectiveness.
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-12 09:43:12 +02:00
Silvan Fuhrer
9e18b351bc
Allocation: add Single Channel Aileron to CS types
...
This is the control surface type for airframes that have only a
single aileron servo or have the ailerons on a single output channel.
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-12 09:43:12 +02:00
Silvan Fuhrer
c6d1b1f50f
Allocation: add A-tail servo type
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-12 09:43:12 +02:00
Beat Küng
f2db7b8deb
control_allocator: hide motor positions for fixed-wings
...
should not be set for now
2022-08-12 09:43:12 +02:00
Beat Küng
923a90d78b
control_allocator: set default control surface type to (not set)
...
Before it was set to left aileron, but the torque values were all 0.
2022-08-12 09:43:12 +02:00
Oleg
6ea3c6a7d2
mavlink_ftp: fix to correctly trim reply messages
...
Clear any not used payload data to correctly trim mavlink ftp message reply to avoid sending long ACK and NACK messages.
2022-08-12 08:53:33 +02:00
Matthias Grob
1f81101994
mc_att_control_main: do not jump throttle scaling when taking off
...
2fbb70d9ca made the lowest possible
throttle value commanded by stick in Stabilized mode before taking off 0.
The real world problem with this is that when takeoff is detected then
the entire throttle scaling range jumps from
[0, MPC_MANTHR_MIN]
to [MPC_MANTHR_MIN, MPC_MANTHR_MIN].
As a result whenever MPC_MANTHR_MIN is not zero there is a thrust jump
on every takeoff just at the moment takeoff is detected even when the
stick is moved continuously.
Because of this I suggest to revert to having a higher throttle value
from the beginning on because it's less complicated and there's
no obvious value in starting out with zero thrust if anyways not
possible to go back to zero for safety once takeoff is detected.
2022-08-11 14:18:54 +02:00
Matthias Grob
5b1b6f6080
mc_att_control_main: use gradual() for throttle curve rescale without hover thrust
2022-08-11 14:18:54 +02:00
Matthias Grob
7cb6a47714
TIME_ESTIMATE_TO_TARGET: fill unsupported fields with value representing unavailability
2022-08-11 07:27:04 +02:00
bresch
7996a1a70f
ekf2: reset ekf preflight checks on takeoff correctly
...
Using the control status flags isn't robust as this part of the code
runs at the EKF update rate while the in_air transition is don at the
prediction rate. It was then likely to miss the transition
2022-08-10 16:52:28 +02:00
marcirsch
a8b342722e
mavlink_main: Add TIME_ESTIMATE_TO_TARGET stream to config, onboard, and onboard_low_bandwidth modes
...
Signed-off-by: marcirsch <marcell@auterion.com >
2022-08-10 09:13:58 +02:00
marcirsch
4bf6ebf4c3
TIME_ESTIMATE_TO_TARGET: Populate TIME_ESTIMATE_TO_TARGET MAVLink message with the estimated time to RTL
...
mavlink_messages: Added newly created MAVLink stream
mavlink_main: Enabled stream
Signed-off-by: marcirsch <marcell@auterion.com >
2022-08-10 09:13:58 +02:00
Daniel Agar
7c809f034d
replay: ReplayEkf2 disable parameter auto save
...
- not needed and silences a startup error
2022-08-08 21:27:47 -04:00
Daniel Agar
34dee09b74
ekf2: replay fixes, don't use HRT for timeout checks
...
- this interferes with current ekf2 replay where the latest IMU sample
is effectively the current timestamp
2022-08-08 21:27:47 -04:00
Daniel Agar
1c49a4349f
ekf2: force skip multi-EKF config if replay is enabled
2022-08-08 21:27:47 -04:00
Daniel Agar
66b55d9d0a
ekf2: fix yaw estimator velocity accuracy
...
- additionally require GPS speed accuracy is within EKF2_REQ_SACC
2022-08-08 21:27:01 -04:00
Thomas Stastny
0ea347a5c9
fw pos ctrl: fix the touchdown offset on flare, and nudge the wheel directly
2022-08-08 09:32:44 +02:00
Thomas Stastny
02d7a46025
fw pos ctrl: increase landing nudge rate
2022-08-08 09:32:44 +02:00
Daniel Agar
bce4237963
move ekf2 Matrix helper utilities to mathlib
2022-08-05 09:58:07 -04:00
Silvan Fuhrer
a064164c14
FW pos C params: add param group FW Auto Landing
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-05 14:11:59 +02:00
Silvan Fuhrer
b039ae1614
FW pos c params: change grouping of some clearly longitudinal params to TECS
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-05 14:11:59 +02:00
Silvan Fuhrer
45073f000a
FW Position control: reduce defaults for max pitch
...
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-05 14:11:59 +02:00
Silvan Fuhrer
d04f21aa16
FW attitude controller: reduce FW_MAN_P_MAX from 45 to 30
...
45° is a very large pitch angle, and for me 30° is much more reasonable for
a default value.
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-05 14:11:59 +02:00
Silvan Fuhrer
828992adf7
increase default of MPC_Z_VEL_MAX_DN and MPC_Z_V_AUTO_DN from 1 to 1.5
...
I think most vehicle can safely decend with at least 1.5m/s, and having this
value too low makes Descents/Landings/RTLs unnecessary long.
Signed-off-by: Silvan Fuhrer <silvan@auterion.com >
2022-08-05 14:11:59 +02:00