Commit Graph

40493 Commits

Author SHA1 Message Date
David Sidrane 9d0e57230a
boards: new px4_fmu-v6c board support (#19544) 2022-05-20 15:49:06 -04:00
Julian Oes 33a77c225c commander: lockdown is not termination
We use lockdown to prevent outputs like motors and servos from being
active in HITL simulation. This means that we can't treat the lockdown
flag as a flight_terminated, otherwise we can't arm in HITL at all.
2022-05-20 09:43:32 -04:00
Nicolas MARTIN a0cb7f6258 HITL: undefined time_remaining_s should be NAN 2022-05-20 09:38:43 -04:00
Nico van Duijn 04071b9456 Commander: ignore MAV_CMD_REQUEST_MSG
This commit adds the MAV_CMD_REQUEST_MESSAGE to the list of vehicle
commands which are ignored without generating a warning sound.
2022-05-20 15:36:42 +02:00
Matthias Grob 38e027ee45 ArmStateMachine: remove dependency on armed.armed
To have the internal state as single source of truth
for the arming state within Commander.
2022-05-20 13:51:51 +02:00
Matthias Grob 37c485ce89 ArmStateMachine: move arm state into the class 2022-05-20 13:51:51 +02:00
Matthias Grob 47532ca07b ArmStateMachine: replace state name array with method 2022-05-20 13:51:51 +02:00
alessandro c5bbf4553b ubuntu.sh: fix gazebo and openjdk for 22.04 2022-05-20 06:38:09 +02:00
Matthias Grob 887fe7dba2 commander_params: shorten low battery action delay
I got multiple times the feedback now that a consistent delay
is helpful and makes sense but the default delay
is too long
for low battery action where you're trying to come back in time
and possibly the emergency reaction kicks in while the critical action
is executing which leads to a longer accumulated delay.
2022-05-19 21:54:09 +02:00
Daniel Agar fd4b62032e
commander: publish actuator_armed first on any change 2022-05-19 12:47:50 -04:00
PX4 BuildBot 9518b65f93 Update submodule mavlink to latest Thu May 19 00:38:59 UTC 2022
- mavlink in PX4/Firmware (87c73145b36a835b1635de0498a5613a7af5cafc): a1cb2c0e71
    - mavlink current upstream: 99e82cad70
    - Changes: a1cb2c0e71...99e82cad70

    99e82cad 2022-05-19 Hamish Willee - Deprecated GPS_INJECT_DATA (#1842)
bf3df03d 2022-05-16 Hamish Willee - WIND_COV - accuracy units are m/s (#1844)
a73d4864 2022-05-11 Hamish Willee - development.xml FIGURE_EIGHT_EXECUTION_STATUS - add a note about it being set at lower rate (#1841)
2022-05-18 21:41:08 -04:00
mcsauder e8da98fd14 Add gyro clipping to mirror accel clipping monitoring instances. 2022-05-18 21:16:05 -04:00
mcsauder ea10eacb99 Replace EKF/common.h #defines with enums. 2022-05-18 09:25:19 -04:00
Silvan Fuhrer 8f2c84d36f VTOL paras: add min of 0.1 to transition times
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-05-18 10:01:04 +02:00
Silvan Fuhrer c29ca6c959 tailsitter: guard against division by 0
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-05-18 10:01:04 +02:00
Silvan Fuhrer 3cf07e1be5 VTOL: rename params _PTCH to _PITCH
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-05-18 10:01:04 +02:00
Silvan Fuhrer 7c5f0121a5 VTOL: remove some unsued variables
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-05-18 10:01:04 +02:00
Silvan Fuhrer 2b7efeacca vtol_vehicle_status: replace several status bools by single vehicle_vtol_state
Replace vtol_in_rw_mode, vtol_in_trans_mode, in_transition_to_fw by vehicle_vtol_state.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-05-18 10:01:04 +02:00
Silvan Fuhrer 635f64a2e5 Commander: remove permanent stabilization option for fixed-wing flight
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-05-18 10:01:04 +02:00
Silvan Fuhrer d8444df11c Set tailsitter flag via vehicle status
Removes the necessity of including vtol_type.h in other modules.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-05-18 10:01:04 +02:00
Silvan Fuhrer 7292ce483c VTOL: move to cpp params API
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-05-18 10:01:04 +02:00
Daniel Agar ff16131874 icm42670p run at full speed 2022-05-17 08:14:22 -07:00
Daniel Agar 83daf648ef drivers/imu/invensense/icm42670p: cleanup and small fixes 2022-05-17 08:14:22 -07:00
Peter van der Perk 3ea492b7a2 UCANS32K146 Fix CAN1 STB pin 2022-05-17 03:13:05 -07:00
Matthias Grob 02e11eddce mavlink_mission: add more specific information to the error message 2022-05-17 07:49:00 +02:00
Junwoo Hwang 146f0cafe0 Add get*Expo() functions to the Sticks library
To return Exponential Values, which is helpful for reducing the
sensitivity of the stick around the centered value (0), since it's
exponential curve.

Useful for user adjustment implementations, where accidentally touching the stick
wouldn't have so much effect when using the Exponential value, compared
to using the raw position value.
2022-05-16 23:55:05 +02:00
Matthias Grob 4bd2d4cf35 rc_update: add unit tests for mode slot
To verify RC mode switch and mode button functionality works as expected.
2022-05-16 14:37:29 +02:00
achim 3fe4c6e3f5
boards: matek h743-mini specify drivers to still fit to flash
- the code has become a bit bigger again that now the drivers have to be specified a bit more precisely to still fit into the flash.
2022-05-13 14:05:04 -04:00
Beat Küng 32df76ca8a dshot: handle DSHOT_MIN for reversible outputs
Also ensures there's no deadband if dead_l == dead_h (the default).
2022-05-13 14:04:01 -04:00
Matthias Grob 57a0289627 trajectory_setpoint: correct comment typo "kinematically"
Co-authored-by: Mathieu Bresciani <brescianimathieu@gmail.com>
2022-05-12 17:19:48 +02:00
Matthias Grob 4017f4bb0b vehicle_local_position_setpoint: reorder fields for clarity 2022-05-12 17:19:48 +02:00
Matthias Grob b67fbac296 uuv_pos_control: siplify passing on trajectory position setpoint 2022-05-12 17:19:48 +02:00
Matthias Grob 200124f094 mavlink_receiver: check entire Vectors for NAN
Note: Behavioral change Inf also results in the flag being true.
2022-05-12 17:19:48 +02:00
Matthias Grob 8ca28f3796 Separate message for trajectory setpoint 2022-05-12 17:19:48 +02:00
Beat Küng 9166b6953d output drivers: init SmartLock after exit_and_cleanup
This fixes an invalid memory access when exiting the module:
exit_and_cleanup destroys the object, but lock_guard is destructed after
and accesses the lock.
2022-05-12 08:16:35 -04:00
Beat Küng 0a9378e0f6 mavsdk_tests: ensure motor is stopped for motor failure test 2022-05-12 07:58:56 +02:00
Alessandro Simovic b5a3c58a95 sitl: loosen some timeouts
The typhoon_h480 model would not always complete takeoff in 30 seconds
or finish the mission within 60 seconds.
2022-05-12 07:58:56 +02:00
Alessandro Simovic 5c1932dcca disable engine failure detector for SITL VTOL
Tried increasing ESC timeout for VTOL first

VTOL sitl tests are failing because the ESC telemetry seems to be coming
in at 0.3 Hz
2022-05-12 07:58:56 +02:00
Alessandro Simovic 06f69cd469 Add SITL tests for control allocation 2022-05-12 07:58:56 +02:00
Beat Küng 0f860045f7 failure_detector: add failure injector class for motor telemetry
This allows to test motor failures via 'failure motor off -i 1' on a real
system.
2022-05-12 07:58:56 +02:00
Alessandro Simovic 4640f395d7 simulator_mavlink: Add ESC telemetry 2022-05-12 07:58:56 +02:00
Alessandro Simovic 20ccfbb719 control_allocator: remove failed motor from effectiveness
- limit to handling only 1 motor failure
- Log which motor failures are handled
- Remove motor from effectiveness matrix without
  recomputing the scale / normalization
2022-05-12 07:58:56 +02:00
Alessandro Simovic fb71e7587c failure_detector: add motor/ESC failure detection 2022-05-12 07:58:56 +02:00
Beat Küng dfd934fbdb esc_report: add actuator_function 2022-05-12 07:58:56 +02:00
Hamish Willee aab2feb8f5
pwm.cpp: remove the test example (#19587) 2022-05-12 07:56:13 +02:00
alexklimaj 0f69f8ced8 Fix uavcan battery causing immediate RTL time remaining low 2022-05-11 21:48:12 -04:00
Daniel Agar fba7c972d1
drivers/rc_input: ensure RC inversion is disabled initially and latch RC_INPUT_PROTO conservatively
- this allows jumping straight to a non-SBUS RC protocol
 - increased the scan time per protocol 300->500 ms, which the newer DSM parser seems to need in some cases.
 - only set RC_INPUT_PROTO if we've had a successful RC lock for > 3 seconds
2022-05-11 14:30:41 -04:00
Daniel Agar c772e5230f
commander: remove compile time dependencies on non-commander parameters
- this allows builds with mavlink fully disabled
 - move commander MAN_ARM_GESTURE, RC_MAP_ARM_SW, MC_AIRMODE checks to manual_control
2022-05-11 10:14:23 -04:00
Beat Küng 8d36ba6727 log_writer_file: fix corner case when mission log is enabled
Normally _should_run for mission is only ever true if _should_run for the
normal log is. There are exceptions though:
- the log buffer fails to allocate
- there was a write failure (e.g. due to SD card removal)
In that situation, the writer would not wait anymore but busy-loop.
2022-05-11 10:06:35 -04:00
Beat Küng ebbe08bc86 log_writer_file: protect access to _should_run, use px4::atomicbool for _exit_thread 2022-05-11 10:06:35 -04:00