27398 Commits

Author SHA1 Message Date
Silvan Fuhrer
75ce550db3 Navigator: add terrain collision avoidance logic for Mission/RTL
Avoid flying into terrain using the distance sensor.
Enable through the parameter NAV_MIN_GND_DIST.
Only active during commanded descents with vz>0 (to prevent climb-aways),
excluding landing and VTOL transitions.
It changes the altitude setpoint in the triplet to maintain the current altitude
and republish the triplet. We also change the mission item altitude used for
acceptance calculations to prevent getting stuck in a loop.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2024-07-30 17:50:54 +02:00
Silvan Fuhrer
b74e46b1ac SITL airframes/Navigator: remvoe reference to removed param MIS_LTRMIN_ALT
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2024-07-30 17:50:54 +02:00
chfriedrich98
e5657ba011 battery: remove reboot required flag from BAT_N_CELLS 2024-07-30 16:18:47 +02:00
chfriedrich98
9ca9ae5b24 battery: fix initialization for internal resistance estimation
Don't run/initialize if number of battery cells is zero and reinitialize whenever this parameter changes.
2024-07-30 16:18:47 +02:00
Matthias Grob
ba579245fb battery_status: remove unused smart battery mode 2024-07-30 14:37:11 +02:00
Matthias Grob
a18c18e163 battery_status: remove custom_faults 2024-07-30 14:37:11 +02:00
Matthias Grob
72ed160aa9 batteryCheck: fix comment typo hyster{i,e}sis 2024-07-30 14:37:11 +02:00
Matthias Grob
2e66bbdfb8 battery_status: add failed to arm fault instead of duplicate over temperature 2024-07-30 14:37:11 +02:00
Matthias Grob
e06629bfe5 failsafe: unhealthy battery during spoolup leads to disarm
battery failures can occur upon arming when the load gets sgnificant.
In that case the safest thing to do is prevent a takeoff before anything
worse happens.
2024-07-30 14:37:11 +02:00
Matthias Grob
0d00543292 batteryCheck: explicitly report missing battery with ID 2024-07-30 14:37:11 +02:00
Matthias Grob
7d79bdfa05 batteryCheck: apply supply circuit breaker also to battery checks
This was the case in older versions of PX4.
2024-07-30 14:37:11 +02:00
Matthias Grob
edcda80cb9
Commander: adhere to parameter naming convention (#23466) 2024-07-30 14:27:27 +02:00
chfriedrich98
b93dd0e8d4
purePursuit: migrate parameters to library (#23438) 2024-07-30 14:16:05 +02:00
bresch
7b3d168af1 baro tuning: make hpf argument optional
This filter is often not needed. Setting the default value to -1 makes it
optional.
2024-07-29 14:20:41 +02:00
Silvan Fuhrer
9257744da3
TECS: reduce default of FW_T_SPD_STD to reduce airspeed measurement delay (#23441)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2024-07-29 11:14:59 +02:00
Silvan Fuhrer
d841bf124f fw_position_control: use time literals 2024-07-26 18:01:44 +02:00
Marco Hauswirth
9d9d8aeb4c bugfix: wrong reset_counter used 2024-07-26 18:01:44 +02:00
Marco Hauswirth
5808dac4bc reset position-mode line following after position reset 2024-07-26 18:01:44 +02:00
Silvan Fuhrer
97561d7802 Commander: never allow to switch out of Terminate state with user intend
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2024-07-26 09:53:07 +02:00
Silvan Fuhrer
ee8030de56 Commander: do not switch out of Terminte after disarm
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2024-07-26 09:53:07 +02:00
bresch
0b1eba948a ekf2-flow: add param to force using internal gyro
In some cases the vibration environment of the optical flow sensor is
worse than near the autopilot.
2024-07-25 19:54:19 -04:00
Hamish Willee
a07c986dbc
Params generated as markdown table (#23443) 2024-07-26 07:46:11 +10:00
sbtjagu
85b6b0a406
ackermann: added delay comand support (#23445) 2024-07-25 17:13:30 +02:00
oravla5
b76c1c97b3 ekf2: Optical flow enabled by default 2024-07-25 10:01:35 +02:00
Daniel Agar
fd72578e98 ekf2: avoid constraining parameters every iteration 2024-07-25 09:51:35 +02:00
Silvan Fuhrer
ebcfb5348c Navigator: increase stack by 40 bytes
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2024-07-25 09:22:23 +02:00
David Sidrane
ab82c24e3e systemcmds:Use CONFIG_BOARD_ROOT_PATH instead of string constant 2024-07-24 11:39:44 -04:00
David Sidrane
54b20f1ff3 mavlink:Use CONFIG_BOARD_ROOT_PATH instead of string constant 2024-07-24 11:39:44 -04:00
David Sidrane
ea92c7ffcc lib:Use CONFIG_BOARD_ROOT_PATH instead of string constant 2024-07-24 11:39:44 -04:00
David Sidrane
d0d9aaa6e9 drivers:Use CONFIG_BOARD_ROOT_PATH instead of string constant 2024-07-24 11:39:44 -04:00
Peter van der Perk
a99cc0a20b Remove unused kconfig symbol 2024-07-24 11:39:44 -04:00
Peter van der Perk
46e43ec725 Decouple filepaths from rcS/MTD 2024-07-24 11:39:44 -04:00
bresch
79e0e00d8c ekf2: block process noise increment without constraining the variance
The wind variance can be reset to a value larger than the wind init
variance (e.g.: when the reset occurs when flying close to the N or E
axis). Constraining the variance after a covariance initialization would
artificially increase the correlation and could destabilize the filter.
2024-07-24 17:11:53 +02:00
Marco Hauswirth
39abd87949
set best sensor to -1 after last sensor fails (#23425) 2024-07-24 11:24:07 +02:00
Stockton Slack
36d89df0a7 Fix load monitoring inconsistency bug 2024-07-22 10:33:39 +02:00
Daniel Agar
9ff6c4bf28 remove newlines 2024-07-19 18:25:43 -04:00
Daniel Agar
85de0ff227 boards: move ARK fmu-v6x/pi6x to dedicated RC drivers 2024-07-19 15:42:05 -04:00
Daniel Agar
3a3f04c0f4 drivers/rc: new standalone ghst_rc driver
- extracted from monolithic drivers/rc_input which will eventually be
   dropped once all drivers migrated and boards updated
2024-07-19 15:42:05 -04:00
Daniel Agar
7a6c4f0bfa drivers/rc: new standalone sbus_rc driver
- extracted from monolithic drivers/rc_input which will eventually be
   dropped once all drivers migrated and boards updated
2024-07-19 15:42:05 -04:00
Daniel Agar
561dceea7b drivers/rc: new standalone dsm_rc driver
- extracted from monolithic drivers/rc_input which will eventually be
   dropped once all drivers migrated and boards updated
2024-07-19 15:42:05 -04:00
chfriedrich98
aa0dda7443 ackermann: fix naming conventions 2024-07-19 14:43:40 +02:00
chfriedrich98
f8bebd9e41 ackermann: implement pure pursuit lib 2024-07-19 14:43:40 +02:00
Matthias Grob
f2bca92221 Fix duplicate newlines at the end of files 2024-07-19 14:33:36 +02:00
Matthias Grob
7f14110bb1 Fix missing newlines at the end of files 2024-07-19 14:33:36 +02:00
Roman Bapst
1b9f1b78e5
Added support for resetting wind states to external observation (#23277)
* added support for resetting wind states to external observation

Signed-off-by: RomanBapst <bapstroman@gmail.com>

* moved wind related functions into separate file

Signed-off-by: RomanBapst <bapstroman@gmail.com>

* added VEHICLE_CMD_EXTERNAL_WIND_ESTIMATE

Signed-off-by: RomanBapst <bapstroman@gmail.com>

* correctly compute variances

Signed-off-by: RomanBapst <bapstroman@gmail.com>

* ekf2: implement wind reset

Signed-off-by: RomanBapst <bapstroman@gmail.com>

* only allow VEHICLE_CMD_EXTERNAL_WIND_ESTIMATE during wind dead-reckoning
and increase horizontal velocity variance to allow velocity states to move
towards solution that is aligned with the newly set wind

Signed-off-by: RomanBapst <bapstroman@gmail.com>

* only reset wind on ground

* still use wind reset using airspeed when it wasn't initialized

* exclude func for rover, change reset interface

* handle wind reset in drag-fusion

* replace state reset with variance reset in sideslip/drag fusion

* remove resetWind function

---------

Signed-off-by: RomanBapst <bapstroman@gmail.com>
Co-authored-by: Marco Hauswirth <marco.hauswirth@auterion.com>
2024-07-19 14:33:08 +02:00
Daniel Agar
ca9948a84d msgs/EstimatorStatus.msg rename mag_test_ratio -> hdg_test_ratio
- this is used for more than just mag
2024-07-18 16:39:18 +02:00
Daniel Agar
eac14b7db2 ekf2/commander: simplify navigation filter preflight checks
- remove commander test ratio "tuning knobs" (COM_ARM_EKF_{HGT,POS,VEL,YAW})
   - these are effectively redundant with the actual tuning (noise & gate)
     in the estimator, plus most users have no idea why they'd be
     adjusting these other than to silence an annoying preflight complaint
 - remove ekf2 "PreFlightChecker" with hard coded innovation limits
 - ekf2 preflight innovation flags are now simply if any active source
   exceeds half the limit preflight
2024-07-18 16:39:18 +02:00
chfriedrich98
a42dc2165c add pure pursuit library 2024-07-18 13:25:05 +02:00
chfriedrich98
08c790217d battery: increase max value for battery thresholds 2024-07-18 09:46:58 +02:00
chfriedrich98
5083ec52ec battery: migrate parameters in .c file to .yaml file 2024-07-18 09:46:58 +02:00