Compare commits

...

1089 Commits

Author SHA1 Message Date
Konrad ebe6d57fb8 [Mission]: Update the mission mode to use the planned mission interface library 2023-02-01 09:03:33 +01:00
Konrad f8bcd673ab [Mission] Add planned mission interface to easily extract data from dataman. 2023-02-01 09:03:33 +01:00
Silvan Fuhrer cbc4c35bcf Commander params: improve meta data for max flight time and wind
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-02-01 08:48:09 +01:00
Silvan Fuhrer 6d84da5cf1 Commander: add max flight time warning (starting at 90%)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-02-01 08:48:09 +01:00
Beat Küng b1709743f7 commander: add wind or flight time limit exceeded mode requirement
This prevents switching into any of these modes once the condition is set.
2023-02-01 08:48:09 +01:00
Beat Küng a8628c9d9c fix commander: clear takeoff_time only on disarm
Otherwise the flight time restriction flag gets cleared too early, before
disarming (which puts the vehicle into the previous mode and it might
take off again).
2023-02-01 08:48:09 +01:00
Beat Küng 8e4c5884ec fix commander: need to check for valid mode change even if already the same
Fixes the following case:
- user intention set to X
- failsafe triggers, mode = Y
- can_run for X becomes false
- user tries to switch to X
  -> need to re-evaluate can_run
2023-02-01 08:48:09 +01:00
Beat Küng 7988491e37 failsafe simulator: improve spacing for multi-line checkboxes
Reduces line-height to 100% in that case.
2023-02-01 08:48:09 +01:00
ShiauweiZhao 931f602995 drivers/imu/invensense: new IAM-20680HP IMU driver (#21025) 2023-01-31 09:33:26 -05:00
Daniel Agar 2be701f902 platforms/nuttx: cmake debug pass GDB path and set RTOS plugin file extension 2023-01-30 20:19:38 -05:00
Eric Katzfey a4aa76f0ac VOXL2 board updates and new Kconfig option for ROOTFSDIR
- also includes a couple of miscellaneous changes to VOXL2 support to show Qurt messages on px4 console and put logs in the proper spot
2023-01-30 12:03:40 -05:00
Julian Oes b1fc0ca0d0 mavlink: always forward messages to/from USB
Previously, it was not possible to enable forwarding of messages to/from
teh USB instance because it does not have a param for it, like the
serial instances have.

With this commit, we change the default to always set forwarding on for
the USB instance as that is likely desired.

Signed-off-by: Julian Oes <julian@oes.ch>
2023-01-30 10:46:14 -05:00
Julian Oes 0446292c75 mavlink: always use public method
Signed-off-by: Julian Oes <julian@oes.ch>
2023-01-30 10:46:14 -05:00
Julian Oes 7b8cf4913e mavlink: show forwarding status
Signed-off-by: Julian Oes <julian@oes.ch>
2023-01-30 10:46:14 -05:00
Daniel Agar 47215bb625 lib/wind_estimator: symforce codegen remove reserved identifier naming
- from the C standard, "All identifiers that begin with an underscore and either an uppercase letter or another underscore are always reserved for any use"
2023-01-30 09:24:32 -05:00
Daniel Agar efe1d43550 ekf2: symforce codegen remove reserved identifier naming
- from the C standard, "All identifiers that begin with an underscore and either an uppercase letter or another underscore are always reserved for any use"
2023-01-30 09:24:32 -05:00
Beat Küng 0687fd2689 lockstep_scheduler: avoid pthread_cond_destroy on at_exit
The static object is destroyed on at_exit while threads might still be
inside a CS. This can lead to a hanging process.
Cleaner would be to gracefully stop the threads.

According to https://linux.die.net/man/3/pthread_cond_destroy:
Attempting to destroy a condition variable upon which other threads are
currently blocked results in undefined behavior.
2023-01-30 11:45:02 +01:00
Hamish Willee f25abbc80a Fix magnetometer typo 2023-01-30 10:24:16 +01:00
Daniel Agar 8da993c30e Update world_magnetic_model to latest Sat Jan 28 11:14:05 UTC 2023
Co-authored-by: PX4 BuildBot <bot@px4.io>
2023-01-28 11:41:03 -05:00
PX4 BuildBot 88038717dc update all px4board kconfig 2023-01-28 11:39:51 -05:00
Roman Bapst 4646762f9d Use multiplication instead of division 2023-01-28 10:31:17 -05:00
Silvan Fuhrer 0c735dea2e AirspeedSelector: use scientific notation for small param
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-28 10:31:17 -05:00
Silvan Fuhrer d32f400851 WindEstimator: use isAllFinite()
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-28 10:31:17 -05:00
Silvan Fuhrer a6d14796e4 WindEstimator: add consts, fix float comparison to 0 and use consistently floats in division
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-28 10:31:17 -05:00
Silvan Fuhrer 15335b194a WindEstimator: use state indexing enum consistently
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-28 10:31:17 -05:00
PX4 BuildBot 21ddb04856 Update submodule mavlink to latest Sat Jan 28 00:39:00 UTC 2023
- mavlink in PX4/Firmware (fa65292bb7542cb1f2a4cdaac10738fa17777a6d): https://github.com/mavlink/mavlink/commit/74dee05f0cd121ae27e021d011a04b161c9d0440
    - mavlink current upstream: https://github.com/mavlink/mavlink/commit/e3b8756e37cd2cd01ba658461bb4dbffb2fdf914
    - Changes: https://github.com/mavlink/mavlink/compare/74dee05f0cd121ae27e021d011a04b161c9d0440...e3b8756e37cd2cd01ba658461bb4dbffb2fdf914

    e3b8756e 2023-01-25 olliw42 - update storm32.xml (#1941)
2023-01-27 21:14:07 -05:00
Silvan Fuhrer 48f2b42e12 FWPositionController: remove factor of 2 for switching to LOITER if altitude is not reached
Instead check if system has previously switched into LOITER to acheive the current
WP of type POSITION, and in that case stay in LOITER until altitude is reached.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-27 16:51:30 +03:00
Eric Katzfey e862fde084 ver: use PX4_INFO_RAW and add vendor version (#21008) 2023-01-27 07:13:37 +01:00
Silvan Fuhrer d53d200aa5 Update msg/TecsStatus.msg
Co-authored-by: KonradRudin <98741601+KonradRudin@users.noreply.github.com>
2023-01-26 17:04:43 +01:00
Silvan Fuhrer 88ec117e59 TECS: rename tecs_status.altitude_filtered to altitude_sp_ref
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-26 17:04:43 +01:00
Silvan Fuhrer 06f4195663 PositionControllerStatus.msg: add comments
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-26 17:04:43 +01:00
Silvan Fuhrer fc1c5da92c tecs_status.msg: add comments to states
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-26 17:04:43 +01:00
Silvan Fuhrer 5099a91f87 TECS: keep _pitch_integ_state in radians
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-26 17:04:43 +01:00
Silvan Fuhrer e16f98c2b6 FW Position controller: remove unused climbout arguments
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-26 17:04:43 +01:00
Eric Katzfey aae431e4d5 Removed unused variables in LED driver that were causing fatal build errors on Qurt platform (#21007) 2023-01-25 16:35:56 -08:00
PX4 BuildBot d6d41af9a4 Update submodule nuttx to latest Wed Jan 25 12:38:18 UTC 2023
- nuttx in PX4/Firmware (d3b7112dd9): https://github.com/PX4/NuttX/commit/f80785664fcd99e36835dcb7e9b9b97cd5e9cf8d
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/35997053c5f61039e542c01440feb10baba5049d
    - Changes: https://github.com/PX4/NuttX/compare/f80785664fcd99e36835dcb7e9b9b97cd5e9cf8d...35997053c5f61039e542c01440feb10baba5049d

    35997053c5 2023-01-23 David Sidrane - [BACKPORT] s32k1xx:serial Do not use TC use TDRE & TIE
2023-01-25 14:48:22 -05:00
PX4 BuildBot cc5509381a boards: update all NuttX defconfigs 2023-01-25 14:47:48 -05:00
PX4 BuildBot 03f681ebf8 update all px4board kconfig 2023-01-25 12:57:17 -05:00
Silvan Fuhrer a210c96aa9 Commander: ssimplify error messages for LOITER rejection
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-25 16:40:27 +01:00
Silvan Fuhrer 148ffe4e25 add support for DO_CHANGE_ALTITUDE
Do the same as DO_REPOSITION wit only the altitude field populated
and MAV_DO_REPOSITION_FLAGS set, which means:
- switch to Loiter mode if not already in it
- set the current altitude to what is specified in the altitdue field,
keep current altitude setpoint otherwise
- keep current position setpoint
- fall back to current estimated position in case a position setpoint
is not finite

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-25 16:40:27 +01:00
Daniel Agar 0bdec5bcc0 cmake: nuttx fix jlink-nuttx dependency 2023-01-25 09:06:35 -05:00
KonradRudin d3b7112dd9 [TECS]: If in airspeedless mode, add the throttle integrator term to the throttle setpoint, if the integrator term is positive. This should avoid reducing airspeed when switching to airspeedless mode. (#20987) 2023-01-25 09:16:11 +01:00
modaltb 20b7a8c9f6 drivers/actuators/modalai_esc --> modal_io and rename UART_ESC prefix to MODAL_IO (#20995) 2023-01-24 20:24:58 -05:00
Benjamin Perseghetti 60de5b3ea4 simulation/gz_bridge: remove proceeding px4_ from servos in gazebo model (#20998)
Signed-off-by: Benjamin Perseghetti <bperseghetti@rudislabs.com>
2023-01-24 19:56:11 -05:00
Benjamin Perseghetti 684b4a4b8a simulation/gz_bridge: rc_cessna plane model working, Gazebo Garden updates, and prepare for proper airspeed (#20989)
Co-authored-by: Benjamin Perseghetti <bperseghetti@rudislabs.com>
Co-authored-by: Alejandro Hernández Cordero <ahcorde@gmail.com>
2023-01-24 19:01:45 -05:00
modaltb fbd2e111d0 boards/modalai/fc-v1: revert DMA changes on FCv1 for now (from #20956) 2023-01-24 14:50:05 -05:00
alexklimaj 0776c47d88 Enable ARK CANnode pwm outputs 7 and 8 2023-01-24 14:49:21 -05:00
alexklimaj ac7dc030c3 Add ARK CANnode ver command 2023-01-24 14:49:21 -05:00
Daniel Agar 64c2ec5eea simulation/gz_bridge: remove cmake CONFIGURE_DEPENDS
- PX4 build system simulation targets are optional and no longer
strictly required
2023-01-24 13:58:30 -05:00
Daniel Agar 9cb6de8010 simulation: relax jmavsim java requirements (finding vecmath.jar) 2023-01-24 13:56:24 -05:00
Daniel Agar 3b543c7700 mavlink: serialize mavlink generation to prevent broken output
- let uAvionix generation fully complete before generating CONFIG_MAVLINK_DIALECT
2023-01-24 13:49:28 -05:00
JaeyoungLim 644aeb9153 support fixed-wing in new Gazebo (gz or ignition gazebo) (#20939)
* Add gz plane airframe config

Co-authored-by: Alejandro Hernández Cordero <ahcorde@gmail.com>
Co-authored-by: Benjamin Perseghetti <bperseghetti@rudislabs.com>
2023-01-24 09:22:53 -05:00
Jiangxuan Chen c31867f104 support for KakuteH7v2, KakuteH7mini, and BMI270 IMU driver (#20545)
Signed-off-by: Julian Oes <julian@oes.ch>
2023-01-22 19:41:39 -05:00
Daniel Agar 7c9dcd1985 drivers/uavcan: silence noisy libuavcan cmake version deprecation warning for now
- keep drivers/uavcannode cmake in sync with drivers/uavcan
2023-01-22 14:48:43 -05:00
Daniel Agar 1b46028fd3 mavlink: generate mavlink quiet by default (stdout redirected to log file) 2023-01-22 14:45:41 -05:00
bresch 6e30f8f5cb ekf2: use dedicated aid_src message for flow for terrain aiding 2023-01-21 15:31:19 -05:00
bresch b4b48cae75 ekf2: terrain flow - migrate to Symforce 2023-01-21 15:31:19 -05:00
Daniel Agar 3f842f01a0 simulator/gz_bridge: split actuator outputs for ESCs and servos (#20979)
- existing SIM_GZ outputs -> SIM_GZ_EC (ESCs)
 - new SIM_GZ_SV for servos (not fully implemented)
2023-01-21 14:44:09 -05:00
berkercanatar 9ac6b3d3c5 Update current year in LICENSE
Update year to match with the current year 2023 in LICENSE file.
2023-01-21 12:57:27 -05:00
modaltb c0e8508b01 actuators/modalai_esc/modalai_esc: fix ESC ID to Motor remap regression (#20977) 2023-01-21 12:57:02 -05:00
Daniel Agar a93ef657d1 HIL/test_airframes.sh allow 'gps' and 'mavlink' status to fail
- we're only looking for debug info if/when things go wrong later
2023-01-21 11:38:39 -05:00
Daniel Agar fb000e874f boards: px4_fmu-v5_debug quiet RTC debug errors
- test rack CUAV v5 plus is producing false positives (in this particular situation) that are failing the overall testing
2023-01-21 11:14:28 -05:00
Daniel Agar 6b13fb8b86 HIL/test_airframes.sh check mavlink and gps status before stopping all
- occasionally these fail on the test rack (cube orange), so try to
gather more information
2023-01-21 11:06:23 -05:00
FriedrichTuttas 1830195d30 boards: px4_fmu-v6x add pulldowns to GPIO pins UART7 RTS and UART7 CTS (#20974)
- https://github.com/PX4/PX4-Autopilot/issues/20762

Co-authored-by: David Sidrane <David.Sidrane@Nscdg.com>
2023-01-21 10:19:57 -05:00
Daniel Agar 1aa8ec4537 drivers: initial VectorNav (VN-100, VN-200, VN-300) support 2023-01-20 19:09:30 -05:00
Daniel Agar bd9d09663f commander: avoid uint64 timestamp implicit float conversions
- 64 bit time in microseconds stored in a 32 bit float quickly becomes problematic
 - fixes https://github.com/PX4/PX4-Autopilot/issues/20944
2023-01-19 17:48:40 -05:00
Daniel Agar 3822ef1519 boards: update all in tree bootloaders 2023-01-19 17:25:39 -05:00
PX4 BuildBot c4127813b3 Update submodule sitl_gazebo-classic to latest Thu Jan 19 12:38:59 UTC 2023
- sitl_gazebo-classic in PX4/Firmware (f3cdf70732): https://github.com/PX4/PX4-SITL_gazebo-classic/commit/1a725dd858a3a7c15e79e8e40aa91f4fad9128e5
    - sitl_gazebo-classic current upstream: https://github.com/PX4/PX4-SITL_gazebo-classic/commit/9343aaf4e275db48fce02dd25c5bd8273c2d583a
    - Changes: https://github.com/PX4/PX4-SITL_gazebo-classic/compare/1a725dd858a3a7c15e79e8e40aa91f4fad9128e5...9343aaf4e275db48fce02dd25c5bd8273c2d583a

    9343aaf 2023-01-15 JaeyoungLim - Fix model prefix for user camera plugin (#948)
e5836d3 2023-01-13 Simone - Added robot namespace to the model (#941)
2023-01-19 12:33:53 -05:00
PX4 BuildBot d2240c0c48 Update submodule nuttx to latest Thu Jan 19 12:39:05 UTC 2023
- nuttx in PX4/Firmware (0e2eed62f9a9b44cefc9765fd21aac1a368e4314): https://github.com/PX4/NuttX/commit/d43edd7879fb398de9abcc9d58e8a65c9ed254db
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/f80785664fcd99e36835dcb7e9b9b97cd5e9cf8d
    - Changes: https://github.com/PX4/NuttX/compare/d43edd7879fb398de9abcc9d58e8a65c9ed254db...f80785664fcd99e36835dcb7e9b9b97cd5e9cf8d

    f80785664f 2023-01-16 Julian Oes - [FIX] Add missing define condition
1751c2c7cb 2023-01-16 Julian Oes - [BACKPORT] stm32h7: add SMPS PWR option for STM32H7X7
2023-01-19 12:33:27 -05:00
PX4 BuildBot 8d6a336b2c boards: update all NuttX defconfigs 2023-01-19 12:32:57 -05:00
PX4 BuildBot 898dbb96b4 update all px4board kconfig 2023-01-19 12:32:09 -05:00
Silvan Fuhrer f3cdf70732 VTOL: Quad-chute: rework loss of altitude condition
Previously the condition was based on hard coded height rate estimate and
setpoint values and an altitude error threshold. That showed to be leading
to false positives when the vehicle doesn't tightly follow the altitdue
ramp given by TECS to achieve a new altitude setpoint, and has become
completely infeasibly with the latest TECS rework that leads to non-ramped
altitude setpoint changes in the tecs_status message.
The new check no longer checks the altitude error but only the height rate
instead. It begins to integrate the height rate error once it detects an
uncommanded descend condition (height rate negative while setpoint is
positive). Integral threshold can be tuned by user (VT_QC_HR_ERROR_I).

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-19 09:36:09 +01:00
Silvan Fuhrer 36dc75bedf VTOL: introduce new quad-chute check for altitude loss during front transition
By default the threshold is set to 10m.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-19 09:36:09 +01:00
Beat Küng 98705ced2f lightware_laser_i2c: fix unreliable startup detection
In rare occasions asking for the protocol values after setting it returned
[0, 0]. I did not see any documentation for having to wait, but adding a
short wait period fixes it.
2023-01-18 23:02:56 -05:00
modaltb 05d828642d boards/modalai: FCv1 DMA optimiziation for 2Mbit UART (#20956)
- disable unused SPI3 DMA
- enable USART2 RX/TX, UART5/6 TX, UART4 RX
2023-01-18 23:01:57 -05:00
Daniel Agar 9d7c4b8273 boards: ark_can-flow_default disable sensors/vehicle_acceleration to save flash 2023-01-18 22:58:19 -05:00
Daniel Agar ffa9d61065 boards: px4_sitl_default include gz_bridge by default 2023-01-18 22:56:17 -05:00
Daniel Agar 2b5722786b cmake: fix and update packaging 2023-01-18 22:51:12 -05:00
alexklimaj 5eb13e4448 ARKV6X bootloader init all pwm outputs as input pulldown 2023-01-18 21:52:11 -05:00
alexklimaj 7c2da8d1ef Enable ARKV6X SPIX SYNC, enable icm426889 and iim42652 CLKIN 2023-01-18 21:52:11 -05:00
Daniel Agar 967c37ac17 boards: mro_pixracerpro_default disable examples/fake_gps to save flash 2023-01-18 21:44:09 -05:00
Daniel Agar 6a64e74ef3 icm42688p: fix register bank selection
* icm42688p: clear INT_CONFIG1 INT_ASYNC_RESET for proper INT1/INT2 pin operation
2023-01-18 11:08:03 -05:00
Daniel Agar 95300d5637 ekf2: refactor output predictor to class
- refactor all EKF backend output predictor pieces into new OutputPredictor class
 - output states are now calculated immediately with new high rate IMU rather than after EKF update
 - IMU delayed sample is passed as around as control data to avoid storing an extra copy and make the requirement clear
2023-01-18 10:59:34 -05:00
murata c054ca20cc logger: Add arm to shutdown 2023-01-18 07:47:36 +01:00
Julian Oes 35d6b734f5 perf: avoid leaks in dtor
From what address sanitizer tells me, we need to tell delete what type
it is deleting.

Signed-off-by: Julian Oes <julian@oes.ch>
2023-01-17 21:20:51 -05:00
modaltb 8123090571 boards: modalai FCv2 BSP updates (#20958)
- FCv2 MR1
 - configure TELEM2 for VOXL use case by default
 - use ICP201XX baro by default
2023-01-17 21:20:16 -05:00
Siddharth Bharat Purohit 1c63d5666b boards: add support for CubeOrange+ (#20304)
Co-authored-by: Julian Oes <julian@oes.ch>
2023-01-17 20:55:57 -05:00
Daniel Agar 71d916dbcd ekf2: PreFlightChecker fix vel_ne_innov_lpf index 2023-01-17 13:03:38 -05:00
modaltb 6f718cd48d drivers/actuators/modalai_esc: update to use mixer module and control allocator properly
- update motor mapping to use new UART_ESC_FUNC* auto generated params
 - add support for actuator_test msg to support Actuator Testing in QGC
 - modalai_fc-vX targets start driver if configured
 - keep track of ESC spin direction in own param
 - set ramp up param in MixerOutput to false
2023-01-16 21:46:37 -05:00
Beniamino Pozzan 2a64145dcd microdds_client: add _subs reset method to allow reconnections
Signed-off-by: Beniamino Pozzan <beniamino.pozzan@phd.unipd.it>
2023-01-16 21:43:49 -05:00
Alex Klimaj 00bfd5436a ekf2: increase optical flow preflight check innovation limit (#20940) 2023-01-15 17:52:12 -05:00
Daniel Agar 6991ac014c rename 'gazebo' simulation to 'gazebo-classic' (#20936)
- use `gazebo-classic` everywhere consistently referring to the original Gazebo (eg version 9,10,11)
   - additional `gazebo_*` helper targets added for compatibility, but warn about deprecation and tell you the new target naming
 - use `gz` everywhere when referring to Gazebo (aka Ignition Gazebo or new Gazebo)
2023-01-15 11:36:12 -05:00
Daniel Agar 6605378d0d boards: px4_fmu-v6c_default disable systemcmds/serial_test to save flash 2023-01-14 19:24:47 -05:00
Daniel Agar 30a240a7a4 boards: modalai_fc-v2_default disable examples/fake_gps to save flash 2023-01-14 19:23:19 -05:00
Daniel Agar 52b9b9ba2f simulation: restore 'gazebo' alias for 'gazebo_iris'
- only create helper targets if Gazebo 11 found on system
2023-01-14 17:03:18 -05:00
murata 82ecbccd85 distance_sensor: Add TF02 Pro I2C 2023-01-14 09:28:33 -05:00
Jukka Laitinen 2985b5b9c2 msg/ActuatorTest.msg: Use default queue size the same as MAX_NUM_MOTORS
For the esc_calibration code, the actuator test is published for each motor
in a row. If the orb queue size is too small, messages are lost and not
received in mixer_module.

Set the default orb queue size of ActuatorTest high enough to keep the commands
for all motors in the queue.

Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2023-01-14 09:19:10 -05:00
Daniel Agar 45912066d2 fix copyright header year range 2023-01-14 09:16:16 -05:00
Daniel Agar 674a59e48f ekf2: new gyro bias limit parameter EKF2_GYR_B_LIM
- default is now a more conservative 0.15 rad/s (~8.6 deg/s) instead of the previous hardcoded 20 deg/s
2023-01-14 09:15:46 -05:00
Andrew Wilkins 22f7d913bd rover_pos_control: thrust normalization for joystick input (#20885) 2023-01-13 20:11:39 -05:00
Peter van der Perk 7d92d4893e VSCode C/C++ include path and config hints 2023-01-13 20:03:53 -05:00
Daniel Agar c97381c97f mavlink: streams SCALED_IMU fix gyro dt 2023-01-13 20:01:41 -05:00
Daniel Agar 5942194c66 iridiumsbd: advertise status topic immediately and log by default 2023-01-13 20:01:03 -05:00
Eric Katzfey ac80dcd7a8 Voxl2: add qurt i2c driver support and first i2c driver voxlpm 2023-01-13 19:59:41 -05:00
Julian Oes 1e93ae3148 jsbsim: take FG_BINARY env var into account
This is just to match the docs.

Signed-off-by: Julian Oes <julian@oes.ch>
2023-01-13 17:07:20 -05:00
Silvan Fuhrer 7c766692c4 FW Att and Rate Controller, Tailsitter: fix tailsitter frame transformations
Strictly follow the following convention for tailsitter:
FW Attitude and FW rate controller always operate in the FW frame, meaning that roll is
roll in FW, which for tailsitter means around the yaw axis in the body frame. The interfaces
between modules is though always in body frame.

That enables us to do the axis transformations for tailsitter, that are currently distributed
all over the controller (attitude, rate, vtol module), only at the input and output data of modules.

Side effect is that the FW rate control tuning gains meanings change: while before the roll gains
where meant for the body axis, they are now always applied for the FW roll axis (also in hover). So
the naming now is correct for FW, while before it was for Hover.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-13 18:18:11 +01:00
Silvan Fuhrer edb59a9000 VTOL: improve QC parameter meta data
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-13 19:02:21 +03:00
Silvan Fuhrer 544be72503 VTOL: improve messaging for quad-chute triggered error messages
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-13 19:02:21 +03:00
Silvan Fuhrer 623c1418bb Commander: improve messaging for vtol fixed-wing system failure arming check
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-13 19:02:21 +03:00
Silvan Fuhrer 303b879748 VTOL/Commander: rename transition_failsafe to vtol_fixed_wing_system_failure
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-13 19:02:21 +03:00
Silvan Fuhrer 2d4be68e00 VTOL: reset quad-chute failsafe flag when user triggeres a new transition to FW
This failsafe flag is currently used for not allowing to re-transition to FW, as well
as disabling pusher assist in hover. Till now it was only possible to reset it with
a commanded transition to MC, which many ground station interfaces didn't allow
as the system, after a quad-chute, already was in MC mode.
Hereby it is changed to reset when a new transition to FW is triggered (either via
RC switch or MAVLink command). It is the users responsibility to assess the situation
after a quad-chute happened to try to transition to FW again, manually proceed/land
the vehicle in MC, or let it finish the defined behavior after a quad-chute.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-13 19:02:21 +03:00
Silvan Fuhrer 8a680a3153 VTOL: fix quad-chute max altitude limit
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-13 19:02:21 +03:00
bresch 3d50a7ce44 CAL_MAG_SIDES: do not save with factory cal 2023-01-13 10:48:01 -05:00
bresch 3d73e273e6 MAG_SIDES: don't spam user to not change parameter
otherwise this will always show up on every boot if factory calibration
was done in an earlier release
2023-01-13 10:48:01 -05:00
Tanja Baumann 0099523710 v6x: fix IMU rotations for V6X009010 and V6X010010 (#20901)
And add V6X000010 (pixhawk base board)
2023-01-13 14:09:35 +01:00
bresch ced41febb7 hide legacy read-only parameter under Developer category 2023-01-13 11:40:56 +01:00
Matthias Grob a7c03de434 StickAccelerationXY: apply jerk limit after drag 2023-01-13 10:19:43 +01:00
Eric Katzfey 2a315f86ca Qurt specific drivers for testing and some updates to the startup process (#20917)
* Added a couple of Qurt specific drivers for testing and some updates to Qurt startup code
2023-01-12 20:17:30 -05:00
Mathieu Bresciani 767fcb2774 sensors: prefix mag config param SENS instead of CAL (#20723)
* sensors: prefix mag config param SENS instead of CAL
* mag sides: keep CAL_MAG_SIDES required by QGC
2023-01-12 09:42:36 -05:00
Daniel Agar 635daeed8a NuttX push jlink-nuttx into cmake and enable CONFIG_DEBUG_TCBINFO by default 2023-01-12 09:05:26 -05:00
Daniel Agar 5453630a6d Jenkins: hardware test rack ignore irrelevant sensor timeouts 2023-01-11 16:56:19 -05:00
Peter van der Perk 8b5f35b3fe Add S32K3 vscode support add Jlink rtos vscode support 2023-01-11 16:15:13 -05:00
Jaeyoung Lim 16d6e699bb Update sitl_gazebo submodule 2023-01-11 14:39:05 -05:00
Daniel Agar 0f9bc351f1 ekf2: fix global_pos alt_reset_counter publish (#20906)
- fixes #20900
2023-01-11 14:15:07 -05:00
SiHyun Noh 714b3d82fb thepeach: update px4board kconfig to fix missing fw_rate_control module (#20898) 2023-01-11 10:02:46 -05:00
Eric Katzfey 89180ac0f9 Fixed Kconfig and px4board files for voxl2 2023-01-11 09:53:18 -05:00
Julian Oes 72d36fc874 sensors: Add param for VL53L0X to startup
It turns out there was no param to enable starting the VL53L0X at
startup.

Signed-off-by: Julian Oes <julian@oes.ch>
2023-01-11 09:52:27 -05:00
David Jablonski c6239ce8c2 replay: fix replay msg ids larger than 128 (#20865) 2023-01-11 09:13:53 -05:00
Silvan Fuhrer bc9abf8c36 Commander: always update parameters, not just if disarmed
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-11 10:01:08 +01:00
alexklimaj e19c7ca18b Add reboot command to ark flow 2023-01-11 08:11:18 +01:00
Beniamino Pozzan af336719e6 gz_bridge: fix world selector environment variable
Signed-off-by: Beniamino Pozzan <beniamino.pozzan@phd.unipd.it>
2023-01-08 00:15:35 -05:00
PX4 BuildBot e6c4416250 update all px4board kconfig 2023-01-07 21:53:01 -05:00
Daniel Agar 618288cca9 SITL Gazebo classic make airframes simulator specific 2023-01-07 17:00:35 -05:00
Daniel Agar 97c8a60d67 SITL gz make airframes simulator specific 2023-01-07 17:00:35 -05:00
Daniel Agar ae4cb24100 SITL flightgear make airframes simulator specific 2023-01-07 17:00:35 -05:00
Daniel Agar 1abe35c220 SITL jsbsim make airframes simulator specific 2023-01-07 17:00:35 -05:00
Daniel Agar 75125da34c SITL sihsim make airframes simulator specific 2023-01-07 17:00:35 -05:00
Daniel Agar 95a6eba36c SITL jmavsim make airframes simulator specific
-cleanup and simplify jmavsim SITL launch and debug
2023-01-07 17:00:35 -05:00
Daniel Agar 760fff7d89 Kconfig: fix missing SERIAL_EXT2 (fmu-v5x/v6x) 2023-01-07 12:10:52 -05:00
Daniel Agar dc5ce9b0ce boards: NuttX increase default CONFIG_ARCH_INTERRUPTSTACK 512->768 bytes
- during casual testing on default configs the stack was penetration was reaching ~90% which is a bit too close for comfort
 - increasing by 50% to be conservative
2023-01-07 12:07:35 -05:00
Daniel Agar 7f7dfea998 drivers/imu/analog_devices: experimental support for new ADIS16507 IMU (untested) 2023-01-07 10:56:30 -05:00
Daniel Agar f520d4b3be Update submodule mavlink to latest Sat Jan 7 12:38:21 UTC 2023
- mavlink in PX4/Firmware (8bc88ed526044a864427a4b65135c3baffabb2ef): https://github.com/mavlink/mavlink/commit/0c7792edfeee7cf08e531cb4ce5b4f01854e5724
    - mavlink current upstream: https://github.com/mavlink/mavlink/commit/74dee05f0cd121ae27e021d011a04b161c9d0440
    - Changes: https://github.com/mavlink/mavlink/compare/0c7792edfeee7cf08e531cb4ce5b4f01854e5724...74dee05f0cd121ae27e021d011a04b161c9d0440

74dee05f 2023-01-04 Beat Küng - component_metadata: add translation schema (#1934)
0267c4cf 2023-01-04 Bob Long - common.xml: add fuel_pressure ext. to EFI_STATUS (#1938)
c64818e8 2023-01-04 Mathieu Mirmont - common.xml: fix typos in AIS_TYPE enumerate (#1939)
2306bf79 2023-01-04 Hamish Willee - Update pymavlink (#1940)
0077129b 2022-10-06 Peter Hall - Development: update airspeed message
fbf84c64 2022-10-05 Peter Hall - gitignore: add /.vscode
817c44d8 2022-12-15 Mathieu Mirmont - Add the MAV_TYPE_VTOL_TILTWING aircraft type (#1933)

Co-authored-by: PX4 BuildBot <bot@px4.io>
2023-01-07 10:55:05 -05:00
Julian Oes 243caac44a mavlink: filter command_acks by target
When we receive a command_long or command_int message to
answer, it arrives with a source sysid/compid, so this means we can send
the command_ack back on the appropriate MAVLink instances instead of all
of them.

This commit filters outgoing command_ack messages, so they are only sent
on the MAVLink instances where the sysid/compid has been seen in the
past.

This means that a command_ack is likely still sent on multiple links for
a setup with redundant links.

This should also prevent command_acks from being blasted on Iridium links
when it's not required.

Signed-off-by: Julian Oes <julian@oes.ch>
2023-01-07 10:39:08 -05:00
Matthias Grob 19cee04f3a ubuntu.sh: always install "Gazebo" next to "Gazebo classic" on 22.04 2023-01-07 10:37:02 -05:00
Marcin 91e97eded9 setup ubuntu.sh; fix legacy gazebo for ubuntu22.04 2023-01-07 10:37:02 -05:00
murata,katsutoshi d821404e4f commander: failsafe define enums for actions (#20880) 2023-01-07 10:10:57 -05:00
bresch 49f8bcfc69 ekf2: purge old ekf2 derivation 2023-01-06 18:35:19 -05:00
Peter van der Perk d1b95a21e4 Fixes MR-CANHUBK3 FMU build and adds it to the CI targets 2023-01-06 18:02:45 -05:00
Hamish Willee 1551e2f15c MIS_TKO_LAND_REQ - improve English for value 4 2023-01-06 09:43:16 +01:00
Julian Oes 7e3dcd7be4 sensors: fix overlapping ifdef
This fixes the case where vehicle_angular_rate is no longer started when
airspeed is not enabled.

Signed-off-by: Julian Oes <julian@oes.ch>
2023-01-05 21:09:14 -05:00
bresch 26122886ae ekf2: drag fusion - improve parameter description
The user should refer to the online documentation for tuning guidelines
and not the parameter description.
2023-01-05 12:03:24 -05:00
bresch 06ef39d05e ekf2: MC drag fusion - interpolate between X an Y "b" coefficients
Use the current sideslip angle to generate a drag coefficient that is a
mixture of X and Y coefficients, creating an elliptic distribution.
2023-01-05 12:03:24 -05:00
bresch 420f5ef2b7 ekf2: migrate drag fusion derivation to SymForce 2023-01-05 12:03:24 -05:00
bresch 04f76c932e ekf2: decompose drag vector into x-y components
The drag force is a vector.
drag_x = drag.norm() * vx / v.norm()
2023-01-05 12:03:24 -05:00
Paul Riseborough 1a9c358858 ekf2: Add unit tests for drag fusion 2023-01-05 12:03:24 -05:00
bresch 0509f612dd ekf2: fix drag data downsampling
setDragData needs the imu data at full speed to downsample it without
skipping samples.
2023-01-05 12:03:24 -05:00
Daniel Agar 34c57cc5b5 px4-rc.simulator shellcheck fixes 2023-01-04 17:35:41 -05:00
bresch 14bf04b9a4 SIH: add to px4_fmu-v5_default and auto start GPS sim driver
- add simulator kconfig dependencies
 - exclude SIH (+deps) where sufficient flash isn't available
2023-01-04 16:26:15 -05:00
Peter van der Perk fa87375d0c Add hardfault log progmem flash backend 2023-01-04 12:52:01 -05:00
Daniel Agar ca9ae80b10 px4-rc.simulator support launching new Gazebo Garden vs Fortress (#20864)
- "ign gazebo" command is now "gz sim" as of Gazebo Garden
2023-01-04 12:39:06 -05:00
JaeyoungLim 21e88f64b4 Add new fixed wing rate control module (fw_rate_control)
* Fixedwing rate control into a separate module
* Start fw_rate_control for vtol
* Move over airspeed related parameters to fw_rate_control

Co-authored-by: Silvan Fuhrer <silvan@auterion.com>
2023-01-04 11:14:00 -05:00
Peter van der Perk 4c2c06060d PX4Board kconfig add dependency chain for QURT & POSIX modules 2023-01-04 09:40:17 -05:00
Peter van der Perk ddaa3c24eb Fix MR-CANHUBK3 2023-01-04 05:52:58 -05:00
frederictaillandier 315c075e5c updating the sitl-gazebo-sniffer to allow a vehicle name in the serialized object 2023-01-03 17:00:48 +01:00
bresch 28d664aed5 EKF2: purge outdated matlab scripts
Those files are no longer maintained and will just confuse new users
2022-12-30 13:01:58 -05:00
Daniel Agar cc1b043e18 cmake/kconfig.cmake: fix whitespace 2022-12-30 13:01:30 -05:00
dagar 618ce9a865 [AUTO COMMIT] update change indication 2022-12-29 16:37:34 -05:00
Daniel Agar 20a1c73cf0 ekf2: reinit baro height on sensor or calibration change
- handle reset on delayed time horizon
2022-12-29 16:37:34 -05:00
Silvan Fuhrer 0e2df5a152 remove drivers/pca9685
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-12-29 12:57:41 -05:00
Silvan Fuhrer 348dcf11c8 remove examples/hwtest
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-12-29 12:57:11 -05:00
bresch 3e4e5c991c ekf2: add mag unit tests 2022-12-29 12:56:36 -05:00
bresch 657bd6cf72 ekf2: stop mag fusion when inhibited for too long
Also do not try to run anything if mag is inhibited
2022-12-29 12:56:36 -05:00
bresch c75a9058a5 EKF2: only fuse zero innovation if yaw var is large 2022-12-29 12:56:36 -05:00
Daniel Agar 40e3503c39 boards: fix all NuttX configs (CONFIG_SMALL NuttX upgrade migration) 2022-12-29 12:50:37 -05:00
Daniel Agar 0fbb6db6d4 boards: update all NuttX defconfig (make all_olddefconfig) 2022-12-29 12:50:37 -05:00
Daniel Agar c2f15f5957 boards: update all px4boards (make all_px4_savedefconfig) 2022-12-29 12:50:37 -05:00
Daniel Agar 0204a55354 Makefile: add all_olddefconfig and all_px4_savedefconfig helpers for updating all boards 2022-12-29 12:50:37 -05:00
Daniel Agar f37eb55e19 platforms/nuttx: FATAL error if NSH enabled and SET disabled 2022-12-29 12:50:37 -05:00
Peter van der Perk 964e9dd8c4 Fix MRO NuttX defconfig 2022-12-28 17:00:58 -05:00
Peter van der Perk f7c183edd3 Update NuttX kernel for K3 changes 2022-12-28 10:21:58 -05:00
Peter van der Perk 5e3165af70 S32K3 Enable dflash progmem 2022-12-28 10:21:58 -05:00
Peter van der Perk 2fde13c07d S32K3 EMAC TJA1103 Support 2022-12-28 10:21:58 -05:00
Peter van der Perk 2f1a165d85 S32K3 Enable IRQ stack 2022-12-28 10:21:58 -05:00
Benjamin Perseghetti c3174b5dec Tools/setup/ubuntu.sh: Fixes install for 22.04 gazebo (#20833)
Fixes ubuntu installation script for 22.04 to only install gazebo.

Signed-off-by: Benjamin Perseghetti <bperseghetti@rudislabs.com>
2022-12-28 10:16:43 -05:00
Peter van der Perk beabe56253 S32K3XX call functional reset on board_reset 2022-12-27 08:33:24 -05:00
Yannick Fuhrer 98529a5b49 Battery: delay initialization of SoC (#20729)
* Battery: delay initialization of SoC

* battery: rework of battery initialization delay

Co-authored-by: Matthias Grob <maetugr@gmail.com>
2022-12-26 18:44:22 +01:00
PX4 BuildBot 54d825730e Update submodule libcanard to latest Sat Dec 24 00:39:03 UTC 2022
- libcanard in PX4/Firmware (280ef8935565d4a13e0780c926e1707fa5a90118): https://github.com/opencyphal/libcanard/commit/2e3b11f6b8325080c160d38521b169b0bbb6b1c7
    - libcanard current upstream: https://github.com/opencyphal/libcanard/commit/5c69d451ab0787a81dcb615692d707f2a286f5e5
    - Changes: https://github.com/opencyphal/libcanard/compare/2e3b11f6b8325080c160d38521b169b0bbb6b1c7...5c69d451ab0787a81dcb615692d707f2a286f5e5

    5c69d45 2022-11-03 John Vishnefske - Add sanitizers to unit test cmake build (#205)
989124d 2022-10-30 Pavel Kirienko - Fix 203 (#204)
f85103b 2022-10-13 joshvazquez-amzn - Fix warnings in test helpers (#202)
2022-12-23 22:36:09 -05:00
PX4 BuildBot b6eb5ba790 Update submodule sitl_gazebo to latest Sat Dec 24 00:39:01 UTC 2022
- sitl_gazebo in PX4/Firmware (bb591c6c29): https://github.com/PX4/PX4-SITL_gazebo/commit/049b667d5e86fa71bd47c41dd10e911a0e2681b0
    - sitl_gazebo current upstream: https://github.com/PX4/PX4-SITL_gazebo/commit/d44ce17f4368ab961f87fcc59845647fb629033f
    - Changes: https://github.com/PX4/PX4-SITL_gazebo/compare/049b667d5e86fa71bd47c41dd10e911a0e2681b0...d44ce17f4368ab961f87fcc59845647fb629033f

    d44ce17 2022-12-19 Frederic Taillandier - fixing macos test build (#935)
7f9239c 2022-12-19 Daniel Mesham - Add safe landing world (#932)
61b1fc1 2022-12-19 Daniel Mesham - Update depth camera to match the RealSense D455 (#933)
2022-12-23 22:34:32 -05:00
Julian Oes bb591c6c29 mavlink_shell: fix stall on CubeOrange
On CubeOrange where no console is configured by default, starting
MAVLink shell just stalls, and doesn't work.

Also, logfile download has been reported not to work, and again, seems
to work with this change.

Signed-off-by: Julian Oes <julian@oes.ch>
2022-12-23 11:00:20 -05:00
bresch 86a3d2459a ekf2: remove old yaw estimator generated code 2022-12-23 10:28:19 -05:00
bresch 0388c161e7 ekf2: compare yaw estimator sympy vs symforce 2022-12-23 10:28:19 -05:00
bresch 7c33019510 EKF2: move yaw estimator to symforce 2022-12-23 10:28:19 -05:00
alexklimaj 2f1b3142a6 Decrease PAW3902 and PAA3905 backup schedule to 200ms 2022-12-22 20:46:19 -05:00
Eric Katzfey c3e70b03aa Add more to Voxl2 build and fix associated build errors (#20821)
- Do not pull in PWM parameters when DISABLE_PARAMS_MODULE_SCOPING is TRUE since VOXL2 has no PWM nor any of the required timer_config files that go along with that
 - Replace non-standard M_PI constants with PX4 defined M_PI_F constants
 - Include missing header file for function hrt_absolute_time declaration
 - Add new PX4_SOC_ARCH_ID for the VOXL2 board
2022-12-22 15:44:19 -05:00
alexklimaj 35a9dba6e6 Enable ARKV6X heater 2022-12-22 15:12:32 -05:00
Daniel Agar 03c0808ae6 vscode/settings.json: add .sdf and Jenkinsfile associations 2022-12-21 16:46:25 -05:00
Silvan Fuhrer aff3f2e77f boards: disable gyro fft module for v5 and v5x to safe flash
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-12-21 10:17:59 -05:00
Daniel Agar f2cd7667dc systemcmds/bsondump: new command line utility (extracted from parameters) 2022-12-21 10:14:00 -05:00
Konrad f5524fa605 TECS: Combine both airspeed and airspeed derivative filters in TECS into one MIMO filter using a steady state Kalman filter. 2022-12-21 09:04:19 +01:00
Konrad 08c36612b3 TECS: Updated throttle control for airspeed sensorless vehicles. It includes the P gain controller instead of feedforward only. I term is still disabled. 2022-12-21 09:04:19 +01:00
Konrad 77539d4dac TECS: Rearrange setpoint input. If an altitude rate is given, use this as a feedforward term in the altitude control. If an altitude setpoint is given use a reference model to get a smooth altitude setpoint. 2022-12-21 09:04:19 +01:00
Konrad 8c6dfc840b TECS: Fix bug to reset airspeed derivative and energy rate low pass filters at every time step. 2022-12-21 09:04:19 +01:00
Konrad 7a3e0f53c2 TECS: Replaced old tecs by cleaned up version. 2022-12-21 09:04:19 +01:00
Konrad 991689d3cd TECS: Add new tecs library in parallel to old tecs in the position control library for comparison. 2022-12-21 09:04:19 +01:00
Konrad c64e111d8e TECS: Rearranged the TECS library into submodules. 2022-12-21 09:04:19 +01:00
Daniel Agar 54a32eb2f7 ekf2: EV overhaul yaw and position fusion (#20501)
- move EV yaw and EV position to new state machines
 - EV yaw and EV pos now configured via EKF2_EV_CTRL (migrated from EKF2_AID_MASK)
 - new EV position offset estimator to enable EV position while GPS position is active (no more EV pos delta fusion)
 - yaw_align now strictly means north (no more rotate external vision aid mask)
 - automatic switching between EV yaw, and yaw align north based on GPS quality
2022-12-20 10:23:56 -05:00
Silvan Fuhrer 20342216e2 Airspeed Selector: use better density source and only save scale parameter if valid (#20764)
* AirspeedSelector: use vehicle_air_data.rho for calculating groundspeed-wind CAS

Previously the vehicle_air_data.temperature and pressure was used, instead of the
density field directly.
Only makes a difference if there is an airspeed sensor connected to provide
the air temperature.

* AirspeedSelector: only safe estimated scale in param if airspeed is valid

* AirspeedSelector: remove 0.01 cliff for saving learned scale to param

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-12-20 15:52:54 +01:00
David Sidrane efbb2cf2e3 nxp_ucans32k146:Add LPSPI DMA
nxp_ucans32k146:Add Dready
2022-12-20 09:31:05 -05:00
David Sidrane b7ea31ceed s32k1xx:Add gpiosetevent 2022-12-20 09:31:05 -05:00
David Sidrane da536b3a82 nxp_ucans32k146:Add PROBEs for debugging 2022-12-20 09:29:07 -05:00
David Sidrane e8aa54e7bb nxp_ucans32k146:Use GPIO based RTS (Buffer not character) 2022-12-20 09:29:07 -05:00
David Sidrane fe7d761a11 nxp_ucans32k146:Use serial DMA 2022-12-20 09:29:07 -05:00
David Sidrane 39822ef5a1 nxp_mr-canhubk:lpuart0 use Serial HW flow control 2022-12-20 09:27:40 -05:00
David Sidrane 6a7f5a339b nxp_mr-canhubk3:fmu use Serial DMA 2022-12-20 09:27:40 -05:00
David Sidrane 022e941ebe NuttX with s32k3 Serial DMA 2022-12-20 09:27:40 -05:00
Igor Misic 52275923ad adsb: add support for callsign 2022-12-20 08:18:09 +01:00
Eric Katzfey 678607117a Qurt UART ESC driver support (#20784) 2022-12-20 01:25:12 -05:00
PX4 BuildBot da7d52e302 Update submodule libevents to latest Tue Dec 20 00:39:10 UTC 2022
- libevents in PX4/Firmware (26f3fea7ebb328ef58d4d592dae0559c91f13c1c): https://github.com/mavlink/libevents/commit/0c8bc543db2f8c78f59214d5bcf959bdadd96677
    - libevents current upstream: https://github.com/mavlink/libevents/commit/8d9c5551273a52e22253ea6abf28d9e4b05e0ab7
    - Changes: https://github.com/mavlink/libevents/compare/0c8bc543db2f8c78f59214d5bcf959bdadd96677...8d9c5551273a52e22253ea6abf28d9e4b05e0ab7

    8d9c555 2022-12-13 Beat Küng - README: clarify use of component ID
2022-12-20 01:24:15 -05:00
Peter van der Perk b8e07cc52c Fix Ethernet Socket Defaults 2022-12-19 13:24:55 -05:00
Silvan Fuhrer 9c66f1b14a AirspeedValidator: Remvoe airspeed variance after boot check (#20678)
This checks was introduced to catch the (unlikely) case of the driver publishing
a stale value that is not actually from a current measurement right after boot.
This was done by declaring it invalid if there is no update of the measurement
within the first 10s after boot.
Practice though has shown that around 0, many airspeed sensors have such a low
resolution that the reported airspeed value is often at the exact same value
for longer periods of time on totally healthy sensors, and thus we trigger
some false positive failure detections.
Given that this failure mode (driver publishing stale data) is quite rare (if
it doesn't receive new data it should stop publishing), I remove this check
here again.
When in aerodynamic flight mode and armed, there is still the data stuck
check that can trigger if there is no update for 2s.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-12-19 11:36:48 +01:00
Igor Misic df441ac202 drivers/gps: add param for enabling protocols at i2c interface 2022-12-19 08:52:36 +01:00
tanja e5255b173a v6x: use param SENS_INT_BARO_EN to start internal bmp388 2022-12-19 08:50:31 +01:00
tanja 987de56af2 v6x: rev10 has second PM 2022-12-19 08:50:31 +01:00
tanja 09039faf0a v6x: change bootloader UART7 to UART5 2022-12-19 08:50:31 +01:00
Eric Katzfey b0580d88e1 Added muorb aggregator from DSP to Apps direction 2022-12-16 19:43:00 -05:00
Peter van der Perk d945e87e4f S32K3 DRDY less ambigious 2022-12-16 12:02:44 -05:00
Peter van der Perk 05dd43a8de S32K3 Correct pinirq pinset for external interrupt 2022-12-16 12:02:44 -05:00
RomanBapst ffdf186598 vtol_att_control: reset transition timer states when starting a transition
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-12-16 11:36:00 +03:00
frederictaillandier 84c5ce3a53 removing catkin sitl_gazebo submodule tests as it has also been removed in PX4-Autopilot
Updating the submodule
https://github.com/PX4/PX4-SITL_gazebo/pull/934
2022-12-16 08:11:28 +01:00
JaeyoungLim 9db133b13d Remove angular velocity controller module 2022-12-16 07:52:20 +01:00
Peter van der Perk 52c0cba24b NuttX with TXAVAL merged
nxp_ucans32k146:Use txavail NuttX

   Fix Stack Size
   Expose some K1 debug features
2022-12-15 08:29:10 -05:00
RomanBapst 48e8477799 vtol_att_control: disable maximum height for quadchute by default
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-12-15 15:40:53 +03:00
RomanBapst 9ed51ba8ed quadchute: introduced parameter to specify maximum height
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-12-15 15:40:53 +03:00
Peter van der Perk f3fe10f63e S32K Dynamic periphclocks 2022-12-14 10:44:42 -05:00
Marcell Rausch 6c7702b906 mavlink: Keep sending GPS_RAW_INT/GPS2_RAW.hpp streams on GPS failure
* GPS_RAW_INT: Only send no gps messages if gps has ever been present
 * GPS2_RAW: Keep in sync with GPS_RAW_INT

Signed-off-by: Marcell Rausch <marcell@auterion.com>
2022-12-14 09:12:39 -05:00
David Sidrane 96362bfb52 nxp_mr-canhubk3 Add PROBEs for Debugging 2022-12-14 07:34:23 -05:00
Beat Küng 5217bedd4b commander: make SYS_HAS_MAG a count param and ensure system has N calibrated + enabled mags 2022-12-14 07:55:04 +01:00
Tanja Baumann d75e61eef6 v6x: fix rc.board_sensors ver command (#20763) 2022-12-14 07:53:12 +01:00
Daniel Agar 4d318ebd30 mavlink: add initial mavlink OPEN_DRONE_ID_SYSTEM stream 2022-12-13 19:39:27 -05:00
Daniel Agar 696eeb9a49 ekf2: update EV height state machine (small piece of EV overhaul)
- respect new EKF2_EV_CTRL parameter for VPOS usage
  - EV hgt rotate EV position before usage (there's often a small offset in frames)
  - EV hgt reset use proper EV velocity body frame
  - try to keep EV hgt and EV vel state machines consistent
  - small incremental piece of https://github.com/PX4/PX4-Autopilot/pull/19128
2022-12-13 13:29:18 -05:00
Daniel Agar 805ffa9d0b ekf2: push mag cal reset to delayed time horizon 2022-12-13 10:24:02 -05:00
David Sidrane 57b82af3a0 Hard fault on Port E config (CAN0) due to not sizing the table correctly
@PetervdPerk-NXP  bit by the non-auto sizing table bug again!

Symptom: Hard fault on Port E config (CAN0)
2022-12-13 10:09:40 -05:00
PX4 BuildBot 8b02b6b661 Update submodule mavlink to latest Tue Dec 13 12:38:57 UTC 2022
- mavlink in PX4/Firmware (8e1e5c4faa7749f6bc16650c7452af249a7dcc3a): https://github.com/mavlink/mavlink/commit/081120844300d68e90c8c4d40ab4662cb3eb604c
    - mavlink current upstream: https://github.com/mavlink/mavlink/commit/0c7792edfeee7cf08e531cb4ce5b4f01854e5724
    - Changes: https://github.com/mavlink/mavlink/compare/081120844300d68e90c8c4d40ab4662cb3eb604c...0c7792edfeee7cf08e531cb4ce5b4f01854e5724

    0c7792ed 2022-12-08 olliw42 - Gimbal Device: Adding more invalid and bitmask attributes (II) (#1927)
771926e6 2022-12-07 olliw42 - gimbal manager cap flags: resolve duplication mistake
2bc32222 2022-12-07 olliw42 - add gimbal device flags to low word of gimbal manager flags (#1928)
2022-12-13 09:06:14 -05:00
Beat Küng 685d5cb473 fix kconfig: rename LINUX to LINUX_TARGET
LINUX is defined by cmake >= 3.25:
https://cmake.org/cmake/help/latest/variable/LINUX.html
2022-12-13 09:05:18 -05:00
Roman Bapst 257d4e473b fixed tailsitter transitions (#20756)
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-12-13 10:38:38 +01:00
tanja aba11ce920 rename all instances of serial PPB to EXT2 2022-12-13 08:09:15 +01:00
tanja ba344231d2 v6x: configure SPI busses for board 0x010 2022-12-13 08:09:15 +01:00
tanja ed0f602ce8 v6x: Adapt sensor set for board 0x010 upstream 2022-12-13 08:09:15 +01:00
tanja aec4b93527 v6x: Add EXT2 instance on ttyS3 2022-12-13 08:09:15 +01:00
Eric Katzfey e17ddcc0e5 Qurt platform custom icm42688p IMU driver (#20753)
- first version of IMU driver for the VOXL 2 platform (Qurt)
 - this is a customized version of the Invensense ICM42688P driver, it is currently in the VOXL 2 board directory
2022-12-12 22:02:23 -05:00
Peter van der Perk 33e39d68f7 DroneCAN SocketCAN driver add FMU support 2022-12-12 20:06:13 -05:00
Eric Katzfey 9b3feee6ee worker and HRT threads for Qurt platform (#20739)
* Getting work manager and hrt threads ready for Qurt platform
2022-12-12 14:25:28 -05:00
Daniel Agar dc0823062e github actions: disable vtol_standard address sanitizer test
- unfortunately this is often too slow for github actions
2022-12-12 14:23:13 -05:00
bresch 41abf695a8 ekf2: use more efficient covariance update computation
KSK' is faster to compute than KHP and is mathematically equivalent
2022-12-12 12:31:54 -05:00
Daniel Agar 61fa28c0d6 Tools/generate_board_targets_json.py exclude px4_ros2_default for now 2022-12-12 11:46:36 -05:00
dirksavage88 5b667cf4ba Uavcannode hygrometer support: temp and humidity
Signed-off-by: dirksavage88 <dirksavage88@gmail.com>
2022-12-12 10:54:08 -05:00
Eric Katzfey a5e4295029 lib/drivers: device drivers library for Qurt platform (#20741) 2022-12-10 19:31:06 -05:00
Noah Bliss d8bfee517a boards: beaglebone blue point to a newer version of librobotcontrol (#20740)
- Fixes PRU path issues found in old versions of the library.
2022-12-10 17:27:32 -05:00
alexklimaj 29ade6c472 Increase SPI stacks by 16 bytes 2022-12-10 10:54:20 -05:00
Zachary Lowell e4f641e9b5 Qurt qshell implementation (#20736) 2022-12-09 16:49:41 -05:00
Daniel Agar 8cf13d50a8 ekf2: EKFGSF_yaw minor cleanup (#20510)
- don't store unnecessary IMU copy in class, pass it through where required
 - remove custom pi constants
 - remove unused fields from ahrs_ekf_gsf (vel_NE, fuse_gps, accel_dt)
 - explicitly initialize everything in header
 - apply PX4 code style
 - set GPS velocity before yaw estimator update, not after
2022-12-09 13:24:00 -05:00
Zachary Lowell 643eed51cb Qurt lightweight parameter implementation (#20735) 2022-12-09 09:55:49 -08:00
Daniel Agar f3884d5835 Update world_magnetic_model to latest Fri Dec 9 11:14:09 UTC 2022
Co-authored-by: PX4 BuildBot <bot@px4.io>
2022-12-09 11:40:30 -05:00
Daniel Agar 41fa53605c boards: rebuild STM32H7 bootloaders and px4-io-v2 2022-12-09 11:02:21 -05:00
Peter van der Perk 5b7a2230fc Update NuttX kernel 2022-12-09 06:36:40 -05:00
Peter van der Perk 3b5f0e21bc Add Sysview support in conjunction with PX4 cpuload note driver 2022-12-09 06:36:40 -05:00
Beat Küng a502146d73 board_hw_rev_ver: fix hex printf 2022-12-09 07:52:50 +01:00
Beat Küng 8bde2a7a28 board_hw_rev_ver.c: check for 'rv == OK' before reading the revision
Otherwise a potential failure reading the hw version can get overwritten.
2022-12-09 07:52:50 +01:00
Daniel Agar 8114aad983 initial minimal PX4_ROS2 platform and px4_ros2_default build (#20689)
- new ROS2 platform in PX4 intended for creating configs that build and run entirely in ROS2
 - PX4_CONFIG defaults to px4_ros2_default if no config specified and in a colcon workspace with ROS_VERSION=2
 - currently doesn't do much other than allow you to build px4 msgs interface package
2022-12-08 23:03:44 -05:00
Roman Bapst cfb670fbb3 Refactor quadchute logic (#20704)
* moved computation of _time_since_trans_start into base class

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

* refactor quadchute logic
- move entired logic into VtolType class
- split into smaller functions

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

* Update src/modules/vtol_att_control/vtol_type.h

Co-authored-by: Silvan Fuhrer <silvan@auterion.com>

Signed-off-by: RomanBapst <bapstroman@gmail.com>
Co-authored-by: Silvan Fuhrer <silvan@auterion.com>
2022-12-08 11:56:20 +03:00
Daniel Agar 2b1d8c1d8e mavlink switch to common dialect by default and update to latest 2022-12-07 15:46:04 -05:00
Daniel Agar 72cb4bee01 SITL gz fixes and init cleanup (#20725)
- remove broken gz version handling and remove x500-legacy
 - fix all shellcheck warnings
 - prepare for Gazebo Garden compatibility (needs more work)
2022-12-07 15:41:13 -05:00
Beniamino Pozzan f2c71a8874 microdds_client: added environment variable for defining namespace
Signed-off-by: Beniamino Pozzan <beniamino.pozzan@phd.unipd.it>
2022-12-07 14:36:23 -05:00
Beniamino Pozzan 5a2e41c4e4 microdds_client: add XRCE_DDS_KEY parameter
Multiple agents can connect to the same client

For sitl builds, if the intance number is different from zero,
  XRCE_DDS_KEY is set to the instance number and
  the microdds_client is automatically started
    with namespace
      px4_"instance_number"
    and udp port 8888
If the instance number is equal to zero
  XRCE_DDS_KEY is left untouched and
  the microdds_client is automatically started
    without namespace
    and udp port 8888

Signed-off-by: Beniamino Pozzan <beniamino.pozzan@phd.unipd.it>
2022-12-07 14:36:23 -05:00
Beniamino Pozzan a92897fb58 microdds_client: add namespace to partecipant name
The partecipant name is modified into
"client_namespace"/px4_micro_xrce_dds

For sitl builds the microdds_client is automatically started
with namespace
px4_"instance_number"
and udp port
8888+"intance_number"

Signed-off-by: Beniamino Pozzan <beniamino.pozzan@phd.unipd.it>
2022-12-07 14:36:23 -05:00
Daniel Agar 8eb2a0a3ec ekf2: delete orientation_covariances_euler()
- usage replaced with now public calcRotVecVariances()
2022-12-07 12:41:27 -05:00
Mathieu Bresciani a187bb3b80 ekf2: predict covariance before predicting state (#20715)
* To predict the covariance, the jacobian from the previous to the current state is required.
2022-12-07 09:34:19 -05:00
Daniel Agar c12d9124bd Update submodule GPS drivers to latest Wed Dec 7 12:38:31 UTC 2022
- GPS drivers in PX4/Firmware (4eb0a0598048df07c213659944b2720ee42e1cc2): https://github.com/PX4/PX4-GPSDrivers/commit/b49a6c257371abae6e26e0a3e0fc04b963b2f13d
    - GPS drivers current upstream: https://github.com/PX4/PX4-GPSDrivers/commit/b76fc1df45952abbc76c7eb9f5a5ab3ae994bef2
    - Changes: https://github.com/PX4/PX4-GPSDrivers/compare/b49a6c257371abae6e26e0a3e0fc04b963b2f13d...b76fc1df45952abbc76c7eb9f5a5ab3ae994bef2

    b76fc1d 2022-11-21 qst0528 - ashtech: fix position accuracy loss caused by misplaced integer cast (#118)

Co-authored-by: PX4 BuildBot <bot@px4.io>
2022-12-07 09:16:31 -05:00
PX4 BuildBot db791fa317 Update submodule sitl_gazebo to latest Wed Dec 7 12:38:25 UTC 2022
- sitl_gazebo in PX4/Firmware (b3cebc6686): https://github.com/PX4/PX4-SITL_gazebo/commit/b38e701ec4230a6105ace872447c0f63bc181d41
    - sitl_gazebo current upstream: https://github.com/PX4/PX4-SITL_gazebo/commit/1b56329b73f68f1480e58b1137b3e5169c7453d1
    - Changes: https://github.com/PX4/PX4-SITL_gazebo/compare/b38e701ec4230a6105ace872447c0f63bc181d41...1b56329b73f68f1480e58b1137b3e5169c7453d1

    1b56329 2022-11-22 Frederic Taillandier - adding a gazebo position sniffer to get position at a high rate from another program (#928)
2022-12-07 09:16:00 -05:00
PX4 BuildBot b3cebc6686 Update submodule libevents to latest Wed Dec 7 00:39:06 UTC 2022
- libevents in PX4/Firmware (ff161d5eca5ee3e605840dc05642984985fcbf5a): https://github.com/mavlink/libevents/commit/179f86a8fc7fd74cb80630e77b1b9435d3c5b748
    - libevents current upstream: https://github.com/mavlink/libevents/commit/0c8bc543db2f8c78f59214d5bcf959bdadd96677
    - Changes: https://github.com/mavlink/libevents/compare/179f86a8fc7fd74cb80630e77b1b9435d3c5b748...0c8bc543db2f8c78f59214d5bcf959bdadd96677

    0c8bc54 2022-11-07 Beat Küng - README: fix typo
ca1cce0 2022-11-04 Beat Küng - README: add note for usage of UNIT's
2022-12-06 19:39:37 -05:00
PX4 BuildBot 9c8bf0b4e0 Update submodule apps to latest Tue Dec 6 23:41:48 UTC 2022
- apps in PX4/Firmware (351bd1768a4a862f81b2a262225e945c0e4fe4fa): https://github.com/PX4/NuttX-apps/commit/e04333c986a47ec03ccb83e985f520fe30e3f1b6
    - apps current upstream: https://github.com/PX4/NuttX-apps/commit/a489381b49835ecba6f3b873b5071d882a18152f
    - Changes: https://github.com/PX4/NuttX-apps/compare/e04333c986a47ec03ccb83e985f520fe30e3f1b6...a489381b49835ecba6f3b873b5071d882a18152f

    a489381b4 2022-10-17 Peter van der Perk - [REJECTED] Backport 0d06c1c netinit:Network Monitor add a polled option
7b7cd332e 2022-09-12 Peter van der Perk - [REJECTED] Backport dbcb783671cee8a8c97b5909d9eb818c3864ca93 FAT DMA fix
2022-12-06 19:37:39 -05:00
Daniel Agar c1c4c96c88 boards: flywoo_gn-f405 NuttX upgrade fixes 2022-12-06 19:35:30 -05:00
Daniel Agar 4f99ac209c gitmodules update NuttX to 10.3.0+ 2022-12-06 18:40:58 -05:00
Silvan Fuhrer 2b8295e30f FW Position control: switch from L1 to NPFG guidance by default
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-12-06 12:54:58 -05:00
Daniel Agar f12dbb3ff7 boards: px4_fmu-v5_test disable common distance sensors to save flash 2022-12-06 11:39:25 -05:00
Daniel Agar 91a43c3bce boards: px4_fmu-v5_uavcanv0periph disable camera_feedback to save flash 2022-12-06 10:48:56 -05:00
Daniel Agar 9b20228ffb boards: modalai_voxl2-io NuttX upgrade fixes and sync with px4-io-v2 2022-12-06 10:45:30 -05:00
Daniel Agar a191509b27 boards: raspberrypi_pico NuttX upgrade fixes 2022-12-06 10:40:27 -05:00
Zachary Lowell 91acd494a3 Qurt uORB communicator fixes (#20705)
- there was an issue sending a message from slpi to apps. Seems the code was stuck in an loop and crashed when the message was sent from slpi to apps
2022-12-06 10:33:19 -05:00
Beat Küng 1ea026961e jmavsim_run.sh: add module exports to avoid access errors
With openjdk 17.0.5 2022-10-18, jmavsim fails to start due to missing
exports. This was previously a warning and turned into an error now.

Caught AppContextInfo(Bug 1004) InaccessibleObjectException: Unable to make public static sun.awt.AppContext sun.awt.AppContext.getAppContext() accessible: module java.desktop does not "exports sun.awt" to unnamed module @2c767a52 on thread J3D-Renderer-1
    [0]: java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:354)
    [1]: java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
    [2]: java.base/java.lang.reflect.Method.checkCanSetAccessible(Method.java:199)
    [3]: java.base/java.lang.reflect.Method.setAccessible(Method.java:193)
    [4]: com.jogamp.nativewindow.awt.AppContextInfo$1$1.run(AppContextInfo.java:40)
    [5]: com.jogamp.common.util.UnsafeUtil.doWithoutIllegalAccessLogger(UnsafeUtil.java:219)
    [6]: com.jogamp.nativewindow.awt.AppContextInfo$1.run(AppContextInfo.java:34)
    [7]: java.base/java.security.AccessController.doPrivileged(AccessController.java:318)
    [8]: com.jogamp.nativewindow.awt.AppContextInfo.<clinit>(AppContextInfo.java:31)
    [9]: com.jogamp.nativewindow.awt.JAWTWindow.<init>(JAWTWindow.java:128)
    [10]: jogamp.nativewindow.jawt.x11.X11JAWTWindow.<init>(X11JAWTWindow.java:60)
    [11]: java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    [12]: java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:77)
    [13]: java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    [14]: java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
    [15]: java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:480)
    [16]: jogamp.nativewindow.NativeWindowFactoryImpl.getAWTNativeWindow(NativeWindowFactoryImpl.java:105)
    [17]: jogamp.nativewindow.NativeWindowFactoryImpl.getNativeWindowImpl(NativeWindowFactoryImpl.java:66)
    [18]: com.jogamp.nativewindow.NativeWindowFactory.getNativeWindow(NativeWindowFactory.java:654)
    [19]: javax.media.j3d.JoglPipeline$QueryCanvas.addNotify(JoglPipeline.java:8604)
    [20]: java.desktop/java.awt.Container.addNotify(Container.java:2804)
    [21]: java.desktop/java.awt.Window.addNotify(Window.java:791)
    [22]: java.desktop/java.awt.Frame.addNotify(Frame.java:495)
    [23]: java.desktop/java.awt.Window.show(Window.java:1053)
    [24]: java.desktop/java.awt.Component.show(Component.java:1728)
    [25]: java.desktop/java.awt.Component.setVisible(Component.java:1675)
    [26]: java.desktop/java.awt.Window.setVisible(Window.java:1036)
    [27]: javax.media.j3d.JoglPipeline.getBestConfiguration(JoglPipeline.java:8379)
    [28]: javax.media.j3d.Renderer.doWork(Renderer.java:496)
    [29]: javax.media.j3d.J3dThread.run(J3dThread.java:271)
Caught AppContextInfo(Bug 1004) IllegalAccessException: class com.jogamp.nativewindow.awt.AppContextInfo cannot access class sun.awt.AppContext (in module java.desktop) because module java.desktop does not export sun.awt to unnamed module @2c767a52 on thread J3D-Renderer-1
    [0]: java.base/jdk.internal.reflect.Reflection.newIllegalAccessException(Reflection.java:392)
    [1]: java.base/java.lang.reflect.AccessibleObject.checkAccess(AccessibleObject.java:674)
    [2]: java.base/java.lang.reflect.Method.invoke(Method.java:560)
    [3]: com.jogamp.nativewindow.awt.AppContextInfo.fetchAppContext(AppContextInfo.java:191)
    [4]: com.jogamp.nativewindow.awt.AppContextInfo.update(AppContextInfo.java:135)
    [5]: com.jogamp.nativewindow.awt.AppContextInfo.<init>(AppContextInfo.java:50)
    [6]: com.jogamp.nativewindow.awt.JAWTWindow.<init>(JAWTWindow.java:128)
    [7]: jogamp.nativewindow.jawt.x11.X11JAWTWindow.<init>(X11JAWTWindow.java:60)
    [8]: java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    [9]: java.base/jdk.internal.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:77)
    [10]: java.base/jdk.internal.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
    [11]: java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:499)
    [12]: java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:480)
    [13]: jogamp.nativewindow.NativeWindowFactoryImpl.getAWTNativeWindow(NativeWindowFactoryImpl.java:105)
    [14]: jogamp.nativewindow.NativeWindowFactoryImpl.getNativeWindowImpl(NativeWindowFactoryImpl.java:66)
    [15]: com.jogamp.nativewindow.NativeWindowFactory.getNativeWindow(NativeWindowFactory.java:654)
    [16]: javax.media.j3d.JoglPipeline$QueryCanvas.addNotify(JoglPipeline.java:8604)
    [17]: java.desktop/java.awt.Container.addNotify(Container.java:2804)
    [18]: java.desktop/java.awt.Window.addNotify(Window.java:791)
    [19]: java.desktop/java.awt.Frame.addNotify(Frame.java:495)
    [20]: java.desktop/java.awt.Window.show(Window.java:1053)
    [21]: java.desktop/java.awt.Component.show(Component.java:1728)
    [22]: java.desktop/java.awt.Component.setVisible(Component.java:1675)
    [23]: java.desktop/java.awt.Window.setVisible(Window.java:1036)
    [24]: javax.media.j3d.JoglPipeline.getBestConfiguration(JoglPipeline.java:8379)
    [25]: javax.media.j3d.Renderer.doWork(Renderer.java:496)
    [26]: javax.media.j3d.J3dThread.run(J3dThread.java:271)
Exception in thread "main" java.lang.reflect.InvocationTargetException
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
        at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.base/java.lang.reflect.Method.invoke(Method.java:568)
        at org.eclipse.jdt.internal.jarinjarloader.JarRsrcLoader.main(JarRsrcLoader.java:61)
Caused by: java.lang.RuntimeException: java.lang.IllegalAccessException: class javax.media.j3d.JoglPipeline cannot access class sun.awt.X11GraphicsDevice (in module java.desktop) because module java.desktop does not export sun.awt to unnamed module @2c767a52
        at javax.media.j3d.JoglPipeline.getScreen(JoglPipeline.java:8553)
        at javax.media.j3d.Screen3D.<init>(Screen3D.java:354)
        at javax.media.j3d.Canvas3D.<init>(Canvas3D.java:1124)
        at javax.media.j3d.Canvas3D.<init>(Canvas3D.java:1026)
        at javax.media.j3d.Canvas3D.<init>(Canvas3D.java:990)
        at me.drton.jmavsim.Visualizer3D$CustomCanvas3D.<init>(Visualizer3D.java:909)
        at me.drton.jmavsim.Visualizer3D.<init>(Visualizer3D.java:196)
        at me.drton.jmavsim.Simulator.<init>(Simulator.java:193)
        at me.drton.jmavsim.Simulator.main(Simulator.java:944)
        ... 5 more
Caused by: java.lang.IllegalAccessException: class javax.media.j3d.JoglPipeline cannot access class sun.awt.X11GraphicsDevice (in module java.desktop) because module java.desktop does not export sun.awt to unnamed module @2c767a52
        at java.base/jdk.internal.reflect.Reflection.newIllegalAccessException(Reflection.java:392)
        at java.base/java.lang.reflect.AccessibleObject.checkAccess(AccessibleObject.java:674)
        at java.base/java.lang.reflect.Method.invoke(Method.java:560)
        at javax.media.j3d.JoglPipeline.getScreen(JoglPipeline.java:8551)
        ... 13 more
2022-12-06 09:00:05 -05:00
Thomas Stastny 2da10183f3 welford mean: remove old comments 2022-12-06 08:59:12 -05:00
Silvan Fuhrer ac28c6b7e2 VTOL: take home_position into account for ground clearance (#20683)
* VTOL: take home_position into account for ground clearance

For approximating distance to ground in case there is no valid distance sensor
data, subtract the home position altitude from the local position altitude.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
Co-authored-by: Matthias Grob <maetugr@gmail.com>
2022-12-06 13:19:35 +01:00
Peter van der Perk f1ff47c088 nxp_ucans32k146:Use DMA on I2C 2022-12-06 06:50:46 -05:00
Peter van der Perk 45244e610f NXP MR-CANHUBK3 Support 2022-12-06 06:49:28 -05:00
MAD-CRAZY-MAN 7f01e3962f thepeach_k1/r1: Copyright Amendment, Rename HW comment Correctly. 2022-12-06 06:43:46 -05:00
MAD-CRAZY-MAN 5fc10971ff update by NuttX 10.3+ 2022-12-06 06:43:46 -05:00
MAD-CRAZY-MAN 21093b829b boards: Add ThePeach K1/R1 2022-12-06 06:43:46 -05:00
bresch 8e3517fae0 DataValidator: fix unexpected failover
Instead of always starting with instance 0 (potentially an internal
mag), first take the current sensor as reference to compare the other
ones against it.
The issue is that otherwise we can end up in a
situation where a switch occurs because the currently used sensor isn't
much better than a sensor with a lower index: because the selected one
isn't much better, we cannot "fail-over" to it and get stuck on another
sensor, triggering a fail-over.
2022-12-06 08:16:23 +01:00
Thomas Stastny c5dc1221b6 failure detector: use multiplication instead of division
Co-authored-by: Daniel Agar <daniel@agar.ca>
2022-11-30 14:51:07 -05:00
Thomas Stastny 4e8381e8cf failure detector: negative guard sqrt in std dev calc 2022-11-30 14:51:07 -05:00
Thomas Stastny eb80e0410c failure detector: fix imbalanced prop metric time interval 2022-11-30 14:51:07 -05:00
Daniel Agar 89b81b0bd6 create Welford mean Vector with covariance and improve precision with Kahan summation (#20676)
- WelfordMeanVector now computes covariance
 - use Kahan summation for Welford mean (but continue using float32 for actual mean, etc)
 - WelfordMean and WelfordMeanVector handle initial value and count roll over
 - Welford mean count rollover at 16 bit max to prevent numerical issues and shift weight to newer samples
 - sensors/vehicle_imu: update Welford mean usage (now simplified with resets removed)
    - fix vehicle_imu_status accel var, now properly rotated with full covariance matrix
 - gyro_calibration: update Welford mean usage
2022-11-30 14:50:13 -05:00
bresch 5155346d60 ekf2: do not use gnss data when no lock 2022-11-30 08:50:34 -05:00
Jaeyoung Lim 65577a4f89 Fix invalid offboard setpoints for fw pos control
This commit fixes a regression that disables offboard control
2022-11-30 09:14:57 +01:00
bresch 5d7faefa84 ekf2: don't add invalid GNSS samples to the buffer 2022-11-30 00:22:15 -05:00
Silvan Fuhrer 0c923bda4e FW Attitude Control: fix integral resetting
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-29 18:36:15 +01:00
alexklimaj b78b896498 Adjust min and max can bootloader timing for ardupilot compatibility 2022-11-29 10:21:28 -05:00
Matthias Grob 9e776741d9 battery: allow for external state of charge injection 2022-11-29 09:27:50 +01:00
Matthias Grob babe93c3bf rc_update: adapt throttle trim calibration for [-1,1]
This is fully backwards compatible: If the throttle trim is set to
the minimum then it's the legacy calibration and gets
interpreted such that there is no trim and behavior remains as before.
If the trim is set to a different value than the minimum then it gets
used like with all other channels which was unsupported before.
2022-11-28 19:25:55 +01:00
Matthias Grob 331cb21dee manual_control_setpoint: change stick axes naming
In review it was requested to have a different name for
manual_control_setpoint.z because of the adjusted range.

I started to investigate what naming is most intuitive and found
that most people recognize the stick axes as roll, pitch, yaw, throttle.
It comes at no surprise because other autopilots
and APIs seem to share this convention.

While changing the code I realized that even within the code base
the axes are usually assigned to a variable with that name or
have comments next to the assignment clarifying the axes
using these names.
2022-11-28 19:25:55 +01:00
Matthias Grob 83246c84cf Switch manual_control_setpoint.z scaling from [0,1] to [-1,1]
To be consistent with all other axes of stick input and avoid future
rescaling confusion.

Note: for the MAVLink message 69 MANUAL_CONTROL it's using the full range
according to the message specs now [-1000,1000].
2022-11-28 19:25:55 +01:00
Matthias Grob 5579e319ff mavlink_receiver: refactor forgotten manual_control_setpoint naming 2022-11-28 19:25:55 +01:00
Peter van der Perk f16286f3eb Add jlink-nuttx build command for gdb helper for multi-task debugging 2022-11-28 06:29:18 -05:00
Matthias Grob aac05d7bcd Remove unmaintained rover_steering_control example 2022-11-28 10:02:04 +01:00
Matthias Grob a953167a6a Remove unmaintained uuv_example_app 2022-11-28 10:02:04 +01:00
Silvan Fuhrer 79c55614d8 FW PositionController: remove mavlink_log_pub, and only use events
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer bd176241f8 param translation: remove old param translations (more than 1 release back)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 3f773809c4 LaunchDetection: fix code style (name class members with trailing underscore)
And also align parameter handle name to real parameter name.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 1d75138659 LaunchDetector: fix counter logic
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 1400f81874 FW Pos C: rename LAUN_* param to FW_LAUN_* to be more explicit
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 5587a47471 Launch Detection: reduce user notification to info from warning
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 5a1adab6fb FW Position controller params: flaring params slight meta data adjustments
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 7fb70c55df FW Position controller: runway takeoff: track initial takeoff yaw if not in Mission Takeoff
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 1b89f26691 FW PosC: remove hack to force _landed to false if (not)launch_detected, as it is now handles in land detector
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer df1cd4f147 LaunchDetection: code style changes and fix info message.
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer e6e2c889e0 FW Position controller: rename LAUN_ALL_ON to LAUN_DECTN_ON
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer c8129fd902 Launch Detection: add briefs
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 59e5c68cb0 FW Position control: use yaw at launch detection as bearing setpoint during hand launch takeoff
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer b2f21b956c FW Position control: move LAUN_ALL_ON param to FW Positon Control main params
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 7691e3ff32 FW Land Detector: force to landed if currently landed and in launch process
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 90e1f98c57 FW Launch Detection: refactor state machine and pubish launch_detection_status message
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 35da7f9bc4 Launch Detection: consolidate in single class (use the only existing method, catapult)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer b05878690d Launch Detector: remove LAUN_CAT_PMAX
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 5161165d85 FW land detector: expose trigger time in parameter (LNDFW_TRIG_TIME)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
Silvan Fuhrer 71835f57c9 FW land detector: reduce default for LNDFW_VEL_Z_MAX to 1m/s
And remove 0.7 factor for airspeed-less flying for the vertical speed threshold.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-25 18:45:36 +01:00
benjinne 85e9c17a5e drivers/power_monitor: add TI INA220 driver (#20504) 2022-11-23 15:11:29 -05:00
bresch 7888cc8cfd GyroCalibration: update sensor correction before using it
Otherwise, the thermal offset value can be outdated
2022-11-23 13:24:43 -05:00
bresch dae37803da TC: erase current calibration when temp cal is completed 2022-11-23 13:24:43 -05:00
Matthias Grob d81ca65c6f rc_update: replace RC scaling with interpolate function use 2022-11-23 11:06:44 -05:00
Matthias Grob 9de3af1cbc Functions: interpolate brackets and spacing 2022-11-23 11:06:44 -05:00
alexklimaj c7a8589afc Add ARK PAB Carrier
Add ARK_FMU_V6X to RCS netman

Remove arkv6x rc single wire

Fix arkv6x mtd

arkv6x bootloader init all pins to prevent power cycling peripherals on boot

arkv6x don't power cycle sd card on boot

arkv6x add UART4 Telem 4
2022-11-22 18:14:50 -05:00
Daniel Agar 28e1f6790f Jenkinsfile-hardware: don't run logger on stack check build
- stackcheck build is so slow it will trigger the logger watchdog (error fails Jenkins)
2022-11-22 16:07:22 -05:00
David Sidrane 9faa8e23e8 NuttX Upgrade CONFIG_LIB_BOARDCTL->CONFIG_BOARDCTL 2022-11-22 14:30:08 -05:00
David Sidrane 6e78cbe746 NuttX Upgrade CONFIG_LIB_USRWORK->CONFIG_LIBC_USRWORK 2022-11-22 14:30:08 -05:00
Silvan Fuhrer 9cd3eae0aa Navigator: re-introduce min loiter alt, but only apply it for Loiters w/o a specified altitude setpoint
Also applies to Loiters that are started due to the previous mode being over (Takeoff,
VTOL_Takeoff, Mission).

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-22 13:46:25 -05:00
Thomas Stastny 8157d83bfc ROMFS: remove deprecated runway takeoff param sets 2022-11-22 13:46:25 -05:00
Thomas Stastny 263a1884b1 fixed-wing: explicitly define landing airspeed
landing airspeed was previously defined by a scale factor multiplied by minimum airspeed. this commit changes this parameter to an explicit speed, and when unspecified, defaults to the minimum airspeed
2022-11-22 13:46:25 -05:00
Silvan Fuhrer 9bdf09a300 Mission: fix float to double conversion when setting lat/lon to NAN
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-22 13:46:25 -05:00
Silvan Fuhrer 49c363674a FW Position Control: only prevent automatic aborts if already flaring, but allow manual aborts
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-22 13:46:25 -05:00
Silvan Fuhrer 94d44c40a7 FW Position control: remove param FW_CLMBOUT_DIFF and instead use hardcoded 10m for clearing aborted flag
Use kClearanceAltitudeBuffer for it, which is also used to ensure that during takeoff an
altitude setpoint above the clearance altitdue is set.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-22 13:46:25 -05:00
Silvan Fuhrer 0941ae7579 Navigator: remove MIS_LTRMIN_ALT param, and use new param MIS_LND_ABRT_ALT for landing abort
MIS_LTRMIN_ALt was used to limit the go-to altitude of a LOITER_TO_ALT (not the exit altitude,
but the altitude that the vehicle went to to fly to WP), and during landing abort to climb to
at least this altitude. The min entry altitude of LOITER_TO_ALT I remove with this commit, while
for the min alt during abort I added the new parameter MIS_LND_ABRT_ALT.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-22 13:46:25 -05:00
Thomas Stastny ed39eb4672 mission landing abort: take min loiter alt above land point or current vehicle alt (remove arbitrary +20m) 2022-11-22 13:46:25 -05:00
Thomas Stastny 0fc35ef082 fixed-wing landing abort: disable early landing config during a landing abort
previously, the next position setpoint in the triplet was left unchanged during an abort, which meant that the abort loiter current point combined with land next point triggered the early landing config logic. this commit is only a hack to make things work temporarily.. this needs to be handled better.
2022-11-22 13:46:25 -05:00
Thomas Stastny 08ba5d762f fixed-wing takeoff: sync launch logic with newer runway takeoff modifications
- explicitly defined takeoff airspeed setpoint
- dont use climbout mode
- allow max climb on takeoff
- dont handle post clearance altitude case (navigator will switch anyway)
2022-11-22 13:46:25 -05:00
Silvan Fuhrer a787a326e3 Fixed-wing: split out control of steering wheel into seperate message LandingGearWheel
Completely detach the steering wheel logic from the yaw controller (beside using the
same manual stick input in a manual flight mode).

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-22 13:46:25 -05:00
Silvan Fuhrer 6c611a7e8b VehicleAttitudeSetpoint: rename fw_control_yaw to fw_control_yaw_wheel to make usage clearer
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-22 13:46:25 -05:00
Thomas Stastny 4b036e6723 fixed-wing landing: dont allow land abort while flaring 2022-11-22 13:46:25 -05:00
Thomas Stastny a8c2eaf3e0 fixed-wing landing: add a touchdown time and subsequent ramp down to rwto pitch setpoint after the flare to keep wheels on ground 2022-11-22 13:46:25 -05:00
Thomas Stastny 1de1416773 fixed-wing landing: convert flare time pitch and throttle constraint ramps to sqrt function to make more aggressive 2022-11-22 13:46:25 -05:00
Thomas Stastny f23328d14f fixed-wing landing: ramp in flaring throttle setpoints from last throttle state to keep control continuity
- also put flaring internal states into a struct to organize a bit
- one concern with blending the throttle setpoint like this with the flare time param is that folding prop belly landing airframes may want to have a separate param for shorter throttle kill and still use the flare time ramps for everything else
2022-11-22 13:46:25 -05:00
Thomas Stastny 68e1921f27 make FW_LND_FL_TIME min positive non-zero to protect dividing by zero 2022-11-22 13:46:25 -05:00
Thomas Stastny 928be2958d fixed-wing landing: continue to follow path throughout flare
abruptly changing to a heading setpoint on flare can cause the aircraft to roll and deviate from the runway, this commit
- maintains path following control during the flare not to disrupt the tracking just before touchdown
- (unfortunately for crosswind landing) removes the body axis alignment for runway bearing - this is a compromise

to achieve both runway bearing body axis alignment AND a specific touchdown point, either
1. the wind would need to be considered, and an appropriate diagonal approach (obstructions allowing)  defined to the runway
2. slip control added, keeping path following outputs only commanding roll (controlling airspeed vector) and using yaw-rate command (only actuated by e.g. rudder) to align body axis with the runway
2022-11-22 13:46:25 -05:00
Thomas Stastny e5a9a57d79 fixed-wing landing: ramp in throttle constraints during flare 2022-11-22 13:46:25 -05:00
Thomas Stastny 4fbfc42805 fixed-wing runway takeoff: ramp in pitch constraints and throttle setpoint on takeoff rotation
- consolidate takeoff rotation transition times for pitch constraints and throttle setpoint with a single param
- consolidate pitch takeoff constraint parameters (remove rwto_max_pitch, use nominal max)
- input correct units to rwto pitch constraint getters
- encapsulate absolute time interpolator method for transitions
- start runway ops from idle throttle
2022-11-22 13:46:25 -05:00
Thomas Stastny a4349193b5 fixed-wing runway takeoff: climbout at specified takeoff airspeed and max climb rate
TECS climbout mode was used for takeoff climbout, which puts throttle to full and does not regulate a specific airspeed.
This commit sets the desired takeoff airspeed explicitly and allows max climb rate to track the ascent.
2022-11-22 13:46:25 -05:00
Thomas Stastny 47963b5b67 fixed-wing runway takeoff: define explicit takeoff speeds
previously a scale factor param on min airspeed was used to define the climbout airspeed for runway takeoff
additionally, the rotation speed was defined by another hardcoded scale on top of the previously scaled min airspeed
this commit explicitly defines a takeoff speed and rotation speed for runway takeoff in params, with option to disable
2022-11-22 13:46:25 -05:00
Beat Küng 46dbb7cf63 fix pwm_out, px4io: prevent disarm and rate param updates during boot
Before, the logic to update disarm and rate values also triggered during
bootup on the px4io, because the output functions are only set in
updateSubscriptions().
Therefore change the check to prevent updating during the first cycle.
2022-11-22 13:41:16 -05:00
Beat Küng a20c581111 mixer_module: remove unused limit_callbacks_to_primary argument 2022-11-22 13:41:16 -05:00
dsix-ls2n 2833832968 simulation/gz_bridge: ignition with no lockstep (#20561)
When using ignition SITL simulation with NO_LOCKSTEP, the SITL PX4 fails to update the IMU data from Ignition Gazebo.

The timestamp for the IMU data is taken from the ignition message:

 - In LOCKSTEP mode the clock from the ignition simulation and the one from PX4 SITL are synchronized, hence everything works fine
 - In NO_LOCKSTEP mode, those clocks are not synchronized anymore, so the timestamp for the IMU data should not be the one from Ignition but the current time in PX4 SITL when receiving the message.
2022-11-22 11:26:11 -05:00
Matthias Grob 55b454a8a5 MulticopterPositionControl: avoid invalid setpoint message when switching to altitude controlled mode 2022-11-22 16:03:41 +01:00
bresch 60c448ce3a ekf2: GNSS yaw, use reported yaw accuracy when available 2022-11-22 09:59:31 -05:00
bresch b25bc1b982 ekf2: GNSS yaw, update->fuse pattern 2022-11-22 09:59:31 -05:00
bresch 4cb327fba3 ekf2: remove old GPS yaw autogenerated code 2022-11-22 09:59:31 -05:00
bresch 16a3fee54f ekf2_test: check behavior of GNSS yaw fusion at singularities 2022-11-22 09:59:31 -05:00
bresch 4116de31ad ekf2: compare GNSS yaw fusion sympy vs symforce 2022-11-22 09:59:31 -05:00
bresch eff2c6adcf ekf2: migrate GNSS yaw fusion to SymForce 2022-11-22 09:59:31 -05:00
Michael Schaeuble 19bca47b9e Preserve gimbal control when receiving updates from an input that is not active
The update function of InputMavlinkGimbalV2 returns UpdatedNotActive when receiving control commands from a system or component that doesn't match the primary control. This can happen if a component just sends commands without being in control or when transitioning to a different primary control.
If the input is marked as already_active, it will reset last_input_active which in turn resets the primary control in the next iteration. According to the MAVLink gimbal protocol v2, a component needs to send  MAV_CMD_DO_GIMBAL_MANAGER_CONFIGURE to start controlling the gimbal and to remove control. However, with the current implementation there are several other commands that would reset the primary control.

With this PR, the primary control remains with the component that requested it last if updates from a not active component are received.
2022-11-22 12:08:47 +01:00
JaeyoungLim 2586900c26 Log local position setpoint reference for fixedwings when running NPFG (#20512)
* Log position setpoint reference of npfg

This commit logs the local position setpoint reference when using NPFG

* Address review comments

This commit address review comments from @tstastny
2022-11-22 08:19:38 +01:00
Silvan Fuhrer c24f9561e9 FW Att C: use new param FW_MAN_YR_MAX to control yawing with sticks in attitude controlled mode
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-21 21:26:20 -05:00
Silvan Fuhrer c186f798b6 FW Att C: do not directly override actuator_controls[YAW] but only change yaw rate sp
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-21 21:26:20 -05:00
Daniel Agar 08cdb96f77 boards: px4_fmu-v5_uavcanv0periph disable systemcmds to save flash 2022-11-21 21:23:02 -05:00
Daniel Agar 16564af788 Jenkinsfile-hardware: remove px4_fmu-v3 2022-11-21 21:18:01 -05:00
Silvan Fuhrer 44f831c41a Navigator: Mission feasibilty check: set _has_landing also for normal landing waypoints (without pattern)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-21 18:03:21 +01:00
Silvan Fuhrer e68ba81d6d MissionFeasibilityChecker: for MC only find if landing is present, but don't do any validation
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-21 18:03:21 +01:00
Silvan Fuhrer f2f094c33d MissionFeasibilityChecker: add @briefs
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-21 18:03:21 +01:00
Silvan Fuhrer 4cd7dfa162 MissionFeasibility: add combined takeoff/landing requirement check
Replace the existing check for the availability of a takeoff mission item with a combined
check for takeoff and landing item (or landing pattern). New param MIS_TKO_LAND_REQ
can be set to require only a takeoff, only a landing, both takeoff and landing, and
both or none. The latter is meant to be set if is e.g. deemed unsafe to start a flight
through a Takeoff WP without though defining a Landing - as then in case of a RTL the
vehicle doesn't follow a pre-defined path but instead only can do default RTL that especially
for FW and VTOL isn't always safe.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-21 18:03:21 +01:00
Alex Mikhalev cce3b43b4f mavlink: Fix setting MAV_SIK_RADIO_ID
The AT commands were formatted incorrectly
2022-11-21 08:12:40 +01:00
Daniel Agar 2cb4ef0629 NuttX 10.3+ upgrade (#20190)
Co-authored-by: Peter van der Perk <peter.vanderperk@nxp.com>
Co-authored-by: David Sidrane <David.Sidrane@NscDg.com>
Co-authored-by: alexklimaj <alex@arkelectron.com>
2022-11-20 20:28:07 -05:00
Beat Küng 45b390b0bf microdds: use UXR_DURABILITY_VOLATILE for data reader
This corresponds to the ROS2 default. Using reader=TRANSIENT_LOCAL and
writer=VOLATILE (=default) is incompatible according to
https://docs.ros.org/en/rolling/Concepts/About-Quality-of-Service-Settings.html
2022-11-18 21:41:24 -05:00
Silvan Fuhrer b36758b1a0 Update src/modules/fw_pos_control_l1/FixedwingPositionControl.hpp
fix typo

Co-authored-by: Thomas Stastny <thomas.stastny@auterion.com>
2022-11-18 17:35:34 +01:00
Silvan Fuhrer c4c94febfa FW Pos C: clearly define FW_AIRSPD_MIN as stall+margin, and automatically increase f(load_factor)
Previously the minimum airspeed setpoint was adjusted to the load_factor compensated
stall speed, which, when the stall speed was set without margin, gave the controller
no room for error (the vehicle would stall if the controller has even a small airspeed
error).

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-18 17:35:34 +01:00
Silvan Fuhrer f2ca9387cf FW Position Control: also run airspeed adaptions based on wind, accelerated stall etc. in manual modes
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-18 17:35:34 +01:00
Silvan Fuhrer cec16dd9b3 FW Attidue Controller: use FW_AIRSPD_MIN for DTRIM instead of STALL
This is to make it again in line with the parameter description and docs

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-18 17:25:10 +01:00
alexklimaj 64768f1cda Increase allowed rtk injections to 8 for moving base. Update GPS submodule. 2022-11-18 11:04:17 -05:00
alexklimaj 8b61b22da6 Fix CANNODE_SUB_MBD typo 2022-11-18 11:04:17 -05:00
Jukka Laitinen f2607335ac rc/crsf_rc/CrsfRc.cpp: Include fcntl.h for "open"
Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2022-11-18 07:10:27 +01:00
Jukka Laitinen 9081238dc5 microdds_client.cpp: Include posix.h for PX4_STACK_ADJUSTED macro
Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2022-11-18 07:10:27 +01:00
Jukka Laitinen 9ce234ece8 SafetyButton.cpp: Include board_config.h
Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2022-11-18 07:10:27 +01:00
Jukka Laitinen ff3a3dac01 cdc_acm_check.cpp: Add missing #includes
- Include board_config.h for BOARD_GET_EXTERNAL_LOCKOUT_STATE etc. macros
- Include fcntl.h for "open"

Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2022-11-18 07:10:27 +01:00
Jukka Laitinen 966560edc0 Fix overflows in abstime_to_ts
Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2022-11-18 07:10:05 +01:00
Zachary Lowell 52b16d062c uORB Remote Manager Update (#20623) 2022-11-17 13:51:01 -08:00
Silvan Fuhrer 8b7c074680 FW Position Control: remove 0.9 mergin factor on stall vs min param comparison
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-17 13:33:10 +01:00
Silvan Fuhrer 2e0c8da7ef FW Position Control: fix load factor calculation
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-17 13:33:10 +01:00
Silvan Fuhrer 798cc4f01c LandDetectorMC: enforce that LNDMC_Z_VEL_MAX is larger than MPC_LAND_CRWL/MPC_LAND_SPEED (#20614)
* LandDetectorMC: enforce that LNDMC_Z_VEL_MAX * 1.2 is below *MPC_LAND_CRWL/MPC_LAND_SPEED

Otherwise the _in_descend flag doesn't get set correctly during the last part
of the landing, where the descend speed is at MPC_LAND_CRWL or LAND_SPEED.
The _in_descend flag is set it the velocity setpoint is >1.1*LNDMC_Z_VEL_MAX.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
Co-authored-by: Matthias Grob <maetugr@gmail.com>
2022-11-17 10:56:26 +01:00
Matthias Grob e58ad581a0 modalai_esc_params: remove unused parameter 2022-11-17 10:50:41 +01:00
Matthias Grob fd4d4e001d PULL_REQUEST_TEMPLATE: suggestion to make it more "concise" 2022-11-16 17:28:27 +01:00
TSC21 9c0e09c3df mavlink_main: report in AUTOPILOT_VERSION.capabilities that FLIGHT_TERMINATION is supported 2022-11-16 16:51:47 +01:00
Matthias Grob d4f18bda8e navigator_params: remove deprecated parameters
The usage of `NAV_AH_...` was removed in
5d33b9e999
#14307
2022-11-16 10:26:12 -05:00
Matthias Grob fbe5024fa8 commander_params: remove deprecated COM_RCL_ACT_T
It's now covered with COM_FAIL_ACT_T
2022-11-16 08:11:09 +01:00
Daniel Agar da82757bf6 ekf2: accumulate multiple vel/pos/orientation reset deltas per update
- if in a single EKF update there are multiple resets we need to track the accumulated delta so the change consumed by the controllers is correct
2022-11-15 13:20:54 -05:00
alexklimaj 2e918eba00 Revert "Update MAVLink so common includes standard (#20542)"
This reverts commit 0e2b1ee979.
2022-11-15 13:09:56 -05:00
Eric Katzfey 796fa8bd72 boards/modalai: separate voxl2 builds into two board builds instead of single board build with different variants
* Made voxl2 apps processor and slpi dsp processor builds into separate board builds so that they can
more easily be configured independently.

* Removed board specific link library command from px4_config.cmake and moved it to a more generic
board specific solution that can be used by any board that needs custom link libraries.

* Removed redundant cmake command for Qurt

* Removed unused definition from Qurt cmake file

* Removed unnecessary QURT_LIB cmake function

* Reorganized the voxl2 build structure to avoid 4 level board directories.

* Reverted cmake files to remove 4 level board naming code

* Updated documentation
2022-11-15 13:09:04 -05:00
bresch 22420a7bf1 ekf2: do not fuse ZVU if other velocity source is active 2022-11-15 11:17:07 -05:00
bresch c67f03f383 ekf2: update change indicator 2022-11-14 11:51:32 -05:00
bresch f319cc528b ekf2: remove old flow fusion generated code 2022-11-14 11:51:32 -05:00
bresch 2a83dbf81d ekf2_test: compare flow fusion sympy vs symforce 2022-11-14 11:51:32 -05:00
bresch 93564baccf ekf2_flow: recalculate innovation after fusing 1st axis
The state changed so we need to recalculate the innovation of the 2nd
axis after fusing the 1st one
2022-11-14 11:51:32 -05:00
bresch 4dbdf23346 ekf2: update _R_to_earth when the state quat changed through fusion 2022-11-14 11:51:32 -05:00
bresch 28458340e6 ekf2_flow: check innov variance health after fusing 1st axis 2022-11-14 11:51:32 -05:00
bresch 73a8c388e8 ekf2: fuse by looping through axes 2022-11-14 11:51:32 -05:00
bresch b54a4417fa ekf2: migrate flow fusion to SymForce 2022-11-14 11:51:32 -05:00
Daniel Agar 639d1ddca2 ekf2: update flags (in_air, at_rest, etc) on delayed time horizon (#20576)
- in a lot of cases this won't really matter, although you can see it in logs (especially with things like vehicle_at_rest), but it's something we might as well do properly

Co-authored-by: Mathieu Bresciani <brescianimathieu@gmail.com>
2022-11-14 11:35:40 -05:00
Beat Küng b0e1cc72f7 fix orbit for mc: handle VEHICLE_CMD_DO_ORBIT command and avoid race condition
Fixes a regression from 8bae4e5c0e, where
the orbit flight task wasn't an extra task (flight_tasks_to_add) anymore
and therefore the command handling wasn't generated.

There was a race condition that could cause several outcomes. The most severe
was that flight_mode_manager gets the command, switches to orbit and then
in the next iteration switches back because commander did not change
nav_state yet. When commander then switches, flight_mode_manager would still
be in the old mode.
This is prevented by storing the command (allowing it to arrive before or
after mode switch), and then apply it after the switch happens.
2022-11-14 17:31:35 +01:00
Beat Küng c1f9824396 flight_mode_manager: remove command ack for VEHICLE_CMD_DO_ORBIT
Already acked in commander
2022-11-14 17:31:35 +01:00
Daniel Agar 9e7db0ed54 merge vehicle_angular_acceleration into vehicle_angular_velocity (#20531)
- vehicle_angular_velocity and vehicle_angular_acceleration are produced together from the same input data, consumed together, and share the the same metadata (timestamps)
 - individually these topics each have 16 bytes of metadata (2 timestamps) for 12 bytes of data (x,y,z float32)
2022-11-14 11:03:59 -05:00
bresch 7d1f1d0f84 ekf2: replace macro constants by typed constexpr 2022-11-14 10:45:23 -05:00
bresch 06702da003 ekf2: add GNSS yaw max interval
yaw data usually comes at lower rate than vel/pos
2022-11-14 10:45:23 -05:00
bresch 9834c7917b ekf2: use yaw emergency estimator more aggressively
During the whole flight, if the difference between the yaw estimate from
EKF2 and the emergency estimator is large and that the GNSS velocity
fusion is failing continuously, immediately reset to the emergency yaw
estimate.
2022-11-14 10:45:23 -05:00
GaspardBesacier dfced1fe46 VTOL: Smarter pusher ramp up during front transtitions for standard VTOLs (#20394)
New param VT_PSHER_SLEW for ramping up throttle of pusher during front/back transition, that replaces the old VT_PSHER_RMP_DT param.
2022-11-14 16:32:51 +01:00
Silvan Fuhrer f5ecd1106f VTOL: some parater meta data fixes/improvements
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-14 16:25:46 +01:00
Silvan Fuhrer c04a67401e Remove some @decimal and @increment from integer parameters
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-14 16:25:46 +01:00
Silvan Fuhrer a018debd37 FW Position controller: fix some parameter meta data
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-14 16:25:46 +01:00
Silvan Fuhrer 0d7a029bfc FW Attitude controller params: fix meta data for Acro rates
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-14 16:25:46 +01:00
Matthias Grob 30d74f124d commander_params: make disarm timeouts more explicit decimals
of 100ms increment
2022-11-14 16:25:46 +01:00
Silvan Fuhrer 464a7fcbed Commander params: add @decimal to COM_SPOOLUP_TIME
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-14 16:25:46 +01:00
alexklimaj 054a549dae Move uavcan start to end of rcS to prevent sd card read lock 2022-11-14 09:32:10 -05:00
Daniel Agar bd5bc9d207 ekf2: cleanup terrain estimator init (shouldn't be valid by default)
- with Ekf::initialiseFilter() resetting _time_last_hagl_fuse the terrain estimate was technically valid regardless of any range or flow data availability and as a result optical flow fusion is able to start and stay active
 - only consider terrain estimate valid based on control status flags and recent fusion
2022-11-14 09:29:46 -05:00
Michael Schaeuble d7fde289de Use gimbal attitude for the camera feedback when available
The CameraFeedback module used only the vehicle attitude for the camera orientation so far. With this change, the gimbal_device_attitude_status is used to compute the global camera orientation when a gimbal is used.
2022-11-14 09:26:14 -05:00
Beat Küng 640f9cc801 commander: fix initialization order of _failsafe_flags
In this case it did not cause any problems.
Fixes a compiler warning:
/src/modules/commander/HealthAndArmingChecks/HealthAndArmingChecks.cpp:39:21: error: member ‘HealthAndArmingChecks::_failsafe_flags’ is used uninitialized [-Werror=uninitialized]
   39 |           _reporter(_failsafe_flags)
      |                     ^~~~~~~~~~~~~~~
2022-11-14 11:27:23 +01:00
Paul Erik Frivold 8e5efb0131 simulator_mavlink: Add basic vio failure injection (#20577)
* simulator_mavlink: Add basic vio failure injection

Signed-off-by: Paul Frivold <paul@kefrobotics.com>

* simulator_mavlink: Rm failure not supported warning

Failures commands are also handled in other files,
so warning here could be confusing.

Signed-off-by: Paul Frivold <paul@kefrobotics.com>

Signed-off-by: Paul Frivold <paul@kefrobotics.com>
2022-11-14 13:36:23 +13:00
Igor Mišić acd8f20a85 systemcmds/ver: remove duplicate header 2022-11-11 07:21:04 +01:00
batinkov 241bcc863b Decimal added for the CAL_ACC[012]* parameters 2022-11-11 07:10:55 +01:00
Zachary Lowell b6ab7f159f Qurt MUORB Communication (#20584) 2022-11-10 11:10:18 -08:00
Thomas Stastny 6b9d86680b commander: fix hold after mission logic
previous change in logic to hold after mission clear also broke rtl, as non-mission takeoff still published a mission result which allowed entering the mission finished condition and always changing state to loiter (ignoring rtl). new logic only switches navigation states if mission is finish and the nav state is explicitly in takeoff state, or in mission state
2022-11-10 16:17:18 +01:00
Thomas Stastny 6dad3a5150 commander: hold after mission clear 2022-11-10 12:08:05 +01:00
Igor Mišić 815eed2c6d mtd: add support for extended HW revision 2022-11-10 07:45:44 +01:00
Junwoo Hwang 855eb42c59 Rename param and paramgroups to airframe and airframegroups
The srcparser.py is specific to each use case (e.g. Airframes, Parameters, px4events, etc as in Tool/* folders).
Therefore it is confusing to have the px_process_airframes.py script handle concept of airframes under the generic name 'params'.

This improves readability and sets the baseground for implementing more specific vehicle type supports, as mentioned in https://github.com/PX4/PX4-user_guide/pull/1858#discussion_r876554728
2022-11-10 07:39:27 +01:00
Zachary Lowell ee11b57e75 Qurt platform configuration cleanup (#20583) 2022-11-09 11:24:00 -08:00
Matthias Grob a38bdcfc9d MulticopterPositionControl: fix amending existing idle setpoint from before takeoff
once the rampup starts. The rampup requires a valid vertical velocity setpoint.
The corner case is:
- We are before takeoff and amending the setpoint to be 0,0,100 acceleration
in order to idle
- The rampup starts BUT the setpoint is not yet overwritten by the trajectory
setpoint topic
- The idle setpoint gets amended to not contain a feed-forward vertical
acceleration because the rampup is velocity based
- The result is a brief invalid 0,0,NAN acceleration setpoint
- That invalid setpoint gets overridden by a failsafe that holds zero velocity
- Zero velocity leads to applying ~hover thrust briefly
2022-11-09 17:13:22 +01:00
Daniel Agar 84d1435880 ekf2: ensure minimum output buffer sizing
- buffer at least 2 samples for the IMU output predictor buffers
 - dropping below 2 becomes problematic for the minimum observation
interval calculation and the vertical output buffer trapezoidal
integration
2022-11-09 09:49:35 -05:00
Damien SIX 9246d38667 commander: fix offboard disarm failsafe 2022-11-09 08:20:45 +01:00
Daniel Mesham 1e39c4828f Check for OA interface failures only after it has been activated
The OA interface is 'activated' when it receives the first trajectory message.
2022-11-08 23:20:16 -05:00
Basti e721d8dd8f Split timeout check on avoidance input.
This split is necessary if the input from the mission computer might
switch from waypoints to bezier points. Otherwise
stays true.
2022-11-08 23:20:16 -05:00
Matthias Grob c85d4fdb1c MulticopterLandDetector: refactor maybe_landed condition
removing all early returns
2022-11-08 22:50:19 -05:00
PX4 BuildBot b7d2868de9 Update submodule sitl_gazebo to latest Wed Nov 9 00:39:01 UTC 2022
- sitl_gazebo in PX4/Firmware (0e2b1ee979): https://github.com/PX4/PX4-SITL_gazebo/commit/56b5508b72f40339448f3525dd4dc51f30512cbd
    - sitl_gazebo current upstream: https://github.com/PX4/PX4-SITL_gazebo/commit/b38e701ec4230a6105ace872447c0f63bc181d41
    - Changes: https://github.com/PX4/PX4-SITL_gazebo/compare/56b5508b72f40339448f3525dd4dc51f30512cbd...b38e701ec4230a6105ace872447c0f63bc181d41

    b38e701 2022-11-03 frederictaillandier - adding jinja parameters
cc8f33d 2022-11-03 frederictaillandier - allowing to override the streaming gimbal ip and port
6c3f1f8 2022-11-03 alessandro - send orientation q with landing_target message (#919)
48e764b 2022-11-02 Frederic Taillandier - allowing to override the video stream ip in a simpler way than using the jinja file (#923)
2022-11-08 22:46:42 -05:00
Hamish Willee 0e2b1ee979 Update MAVLink so common includes standard (#20542) 2022-11-09 09:24:24 +11:00
Zachary Lowell a9989df36c Qurt uORB SLPI Implementation (#20538)
- allow uORB to be compiled and run on the qurt architecture.
2022-11-08 12:30:36 -05:00
Daniel Agar 5239993c88 ekf2: move EV vel to new state machine, introduce EKF2_EV_CTRL param 2022-11-08 11:46:41 -05:00
Daniel Agar 688dae1108 ekf2: add new EKF2_EV_QMIN parameter 2022-11-08 11:46:41 -05:00
Damien SIX 5910f8982a fix warning (mavlink): connection to gcs 2022-11-08 13:02:23 +01:00
tanja 2eed5306c0 SPI: use official HW_VER_REV function 2022-11-08 07:48:21 +01:00
Chris Seto 6df2b68d72 Clean msp_osd help string and debug message 2022-11-07 21:05:17 -05:00
Matthias Grob f1b6f22bac AngularVelocityController: set timestamps on line before publishing 2022-11-07 21:04:25 -05:00
Matthias Grob ae606488bd MulticopterRateControl: set timestamp last before publishing torque and thrust setpoints 2022-11-07 21:04:25 -05:00
Junwoo Hwang 3e35f948d8 autopilot_tester: Make wait_until_ready also wait until vehicle can
arm

- Previously, due to the way MAVSDK's `health_all_ok` was implemented,
vehicle often didn't have a valid global position estimate (although
function returned true), and it wouldn't arm, and the SITL would fail
- Also sometimes as vehicle didn't have manual control, it entered weird
states where it wasn't able to arm as well
- This adds a check to make sure vehicle is able to arm, directly from
the Health struct
2022-11-08 11:53:43 +13:00
Daniel Agar dac9f0dac4 boards: px4_fmu-v6x_default include systemcmds/gpio 2022-11-07 17:10:47 -05:00
Daniel Agar 4190353192 vehicle_magnetometer: fix standalone mag bias est factored into in flight mag cal
- preflight mag bias estimate is in the vehicle body frame and removed from the raw mag data after it's rotated, calibrated, etc
 - in flight mag bias (from ekf2) is in the vehicle body frame, but stored as a sensor frame offset immediately
2022-11-07 09:31:17 -05:00
JaeyoungLim a9542baf3c Enable motor controls for tailsitter VTOLs in fixed wing mode (enable Quad Tailsitters) (#20511)
* Enable motor controls for fixed wing mode in tailsitters

This commit enable motor controls in fixed wing mode for tailsitters

This is needed for enabling quad tailsitters

* VTOL: differential thrust in FW: adapt params to be generic for all axes

Until now only suppoted on yaw axis. Not to be supported also on Roll and Pitch.

- VT_FW_DIFTHR_EN: make bitmask for all three axes independently. First bit is Yaw,
sucht that existing meaning of VT_FW_DIFTHR_EN doesn't change.
- VT_FW_DIFTHR_SC: rename to VT_FW_DIFTHR_S_Y and add same params for roll (_R) and
pitch (_P).

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>

* Integrate differential control bits to three axis control

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-07 15:29:14 +01:00
Peter van der Perk 1fc1a81d8f UCANS32K146 Add support for 2nd PWM 2022-11-03 06:26:52 -04:00
Beat Küng 6511866408 fix commander: check that offboard_control_mode data is recent
This is a regression from https://github.com/PX4/PX4-Autopilot/pull/20172
2022-11-02 10:11:29 -04:00
Daniel Agar 298cc61e07 ekf2: push fuse beta config into backend 2022-11-02 10:09:26 -04:00
Beat Küng 0996e5319f commander: add preflight check for hardfault files on SD card 2022-11-02 09:59:00 -04:00
Beat Küng ab3fe543d4 libevents: update submodule 2022-11-02 09:59:00 -04:00
Silvan Fuhrer 83e906e2e9 Control_allocator_status.msg: remove allocated_ fields
It's enough that the setpoints and the unallocated values are logged, from these
 the allocated values can be calculated if required.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-02 14:56:13 +01:00
Silvan Fuhrer f44713e8a3 ControlAllocator: enable custom saturation logic to override default one
Custom saturation logic currently implemented for Tiltrotor VTOL and Helicopter.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-02 14:56:13 +01:00
Silvan Fuhrer 2e20fb7f97 ActuatorEffectiveness: add _collective_ keyword to controls for collective tilt to disinct from yaw tilt
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-02 14:56:13 +01:00
Zachary Lowell a2d0199516 Uncommenting Qurt platform task code (#20533) 2022-11-01 15:35:20 -07:00
Matthias Grob 7667883385 MulticopterLandDetector: make in descend detection depend on vertical speed threshold
It's very important that the in descend detection is always
at a strictly higher velocity than the vertical movement check.
This combination is basically used to check for vertical downwards
velocity tracking. Desired descend, no movement -> ground

If in descend threshold is lower than vertical movement it is
by definition even with perfect tracking the case that with
any velocity between the two thresholds there is no movement
even though a descend is commanded.

See first fix of this problem #7831
e39b38ba96
2022-11-01 18:35:54 +01:00
Matthias Grob ac646d32e6 MulticopterLandDetector: Apply threshold widening only when landed, not maybe landed 2022-11-01 18:35:54 +01:00
Matthias Grob 509c37c373 MulticopterLandDetector: use quick access for xy angular velocity components 2022-11-01 18:35:54 +01:00
Matthias Grob d9764f2ef4 MulticopterLandDetector: rename vertical velocity threshold variable 2022-11-01 18:35:54 +01:00
Silvan Fuhrer 06bf60672b MC LandDetector: add constant (0.3) for vz threshold for in_descend flag
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-01 18:35:54 +01:00
Silvan Fuhrer 4e74473932 MC LandDetector: remove 2s phase after not maybe landed to still increase thresholds
I don't see where this is necessary. During takeoff, the maybe landed flag should
only get cleared once system is about to takeoff, and thus well after the spool up
is complete (for which the higher thresholds are meant in this case).

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-01 18:35:54 +01:00
Silvan Fuhrer 91adb4c9e0 MC LandDetector: widen thresholds for vz and rotational movment always in maybe landed and 2s after
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-01 18:35:54 +01:00
Silvan Fuhrer 27309a45cc MC LandDetector: remove dependency on MPC_LAND_SPEED and MPC_LAND_CRWL
Don't consider these params for vertical speed threshold,
and instead increase the default for LNDMC_Z_VEL_MAX and
use solely that one. Makes the land detector outcome more
predictable and its interal logic simpler, while the new
default tuning is resulting in about the same vz threshold
as before.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-01 18:35:54 +01:00
Silvan Fuhrer 263c7923d6 MPC params: MPC_LAN_CRWL: fix description and reduce min
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-01 18:35:54 +01:00
Silvan Fuhrer bace45ba8d LandDetector: log rotational_movement
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-11-01 18:35:54 +01:00
tanja 7097518373 px_uploader: Allow for multiple firmware files 2022-11-01 07:45:11 +01:00
benjinne c5c634be7f lisXmdl: use I2CSPIDriverConfig (#20506)
- allows to configure the I2C address
- lis3mdl: add 2nd possible address to start
2022-11-01 07:42:27 +01:00
Matthias Grob afe1f82423 ver command: clarify PX4 version instead of FW version 2022-11-01 07:36:23 +01:00
JaeyoungLim a90857f651 FW separate reset integrals for messages (#20502)
This commit separates integral resets for attitude and rate control setpoints
2022-11-01 06:06:27 +01:00
Zachary Lowell 6d2dd798a0 Qurt drv_hrt Implementation (#20528) 2022-10-31 15:40:29 -07:00
Zachary Lowell 82f63475d7 Qurt work_queue Implementation (#20522) 2022-10-31 09:59:10 -07:00
Eric Katzfey 34c852255e Changed M_PI to M_PI_F in the matrix library since M_PI is non-standard. (#20458)
* Changed M_PI to M_PI_F in the matrix library since M_PI is non-standard.

* Added a new M_PI_PRECISE constant definition to px4_platform_common/defines.h to be
used in places when M_PI is desired but shouldn't be used because it is not C standard.

* Added the px4_platform_common/defines.h include to the matrix library math.hpp header to pull
in some non-standard M_PI constants and updated the test files to use those constants.

* Fixed PI constants in matrix helper test to prevent test failure
2022-10-31 11:51:23 -04:00
Thomas Debrunner ba3f3935ab hardfault_log: Correctly annotate adddresses for the stack trace in the hardfault log. 2022-10-31 06:36:11 -04:00
JaeyoungLim 3f5d7f38cd Handle waypoint altitude acceptance radius for boats (#20508)
This corrects the waypoint handling logic to include boat type vehicles
2022-10-31 09:13:13 +01:00
Julian Oes 21f49ff5be drivers: fix two includes for CLion
This fixes two errors where CLion complains:

error: 'size_t' does not name a type
2022-10-31 07:56:59 +01:00
PX4 BuildBot 80af8262b5 Update submodule mavlink to latest Sat Oct 29 12:39:05 UTC 2022
- mavlink in PX4/Firmware (f8b38591ac0bd31a87cb38ae4b2f7dd74400cda2): https://github.com/mavlink/mavlink/commit/dda5a18ddb002a871ba301bb584893ee6378e2f3
    - mavlink current upstream: https://github.com/mavlink/mavlink/commit/d012c7afd5f4e2a9388710596fd3eb9a1b3eb086
    - Changes: https://github.com/mavlink/mavlink/compare/dda5a18ddb002a871ba301bb584893ee6378e2f3...d012c7afd5f4e2a9388710596fd3eb9a1b3eb086

    d012c7af 2022-10-27 Hamish Willee - update pymavlink to latest (#1906)
e1058881 2022-10-27 Hamish Willee - BATTERY_STATUS_V2 - update to 20221013 RFC version (#1846)
27007cc3 2022-10-25 Hamish Willee - fix typo MAV_PROTOCOL_CAPABILITY_PARAM_ENCODE_C_CAST (#1904)
00007aca 2022-10-19 Hamish Willee - SET_DEFAULT_INTERVAL may be 0 (#1903)
af35d3a4 2022-10-09 Ashish Kurmi - ci: add minimum GitHub token permissions for workflow (#1898)
33dde554 2022-10-09 Siddharth Bharat Purohit - add vendor specs for cubepilot (#1901)
2022-10-29 10:56:25 -04:00
PX4 BuildBot a3caaa1372 Update submodule sitl_gazebo to latest Sat Oct 29 12:38:55 UTC 2022
- sitl_gazebo in PX4/Firmware (498937c56c): https://github.com/PX4/PX4-SITL_gazebo/commit/e80432759540c91f85a012f47aa6ebb0ee9de7e4
    - sitl_gazebo current upstream: https://github.com/PX4/PX4-SITL_gazebo/commit/56b5508b72f40339448f3525dd4dc51f30512cbd
    - Changes: https://github.com/PX4/PX4-SITL_gazebo/compare/e80432759540c91f85a012f47aa6ebb0ee9de7e4...56b5508b72f40339448f3525dd4dc51f30512cbd

    56b5508 2022-10-13 junkdood - Update boat.sdf.jinja
2022-10-29 10:55:53 -04:00
Daniel Agar d4fb1b1f8b Update submodule GPS drivers to latest Sat Oct 29 12:39:01 UTC 2022
- GPS drivers in PX4/Firmware (d67b19ac1d41b2dcfc61ed6d353ae513ac3f4a82): https://github.com/PX4/PX4-GPSDrivers/commit/1ff87868f6008f06e2033ee05dd904ec54109e52
    - GPS drivers current upstream: https://github.com/PX4/PX4-GPSDrivers/commit/fa2177d690207e42e0d8c92e9663578340d44fe4
    - Changes: https://github.com/PX4/PX4-GPSDrivers/compare/1ff87868f6008f06e2033ee05dd904ec54109e52...fa2177d690207e42e0d8c92e9663578340d44fe4

    fa2177d 2022-10-10 Michael Schaeuble - Return from GPSDriverUBX::receive when ready, don't wait until no data is received

Co-authored-by: PX4 BuildBot <bot@px4.io>
2022-10-29 10:55:20 -04:00
Thomas Stastny 498937c56c fw rate control: initialize rate control resets to false in stabilized mode
before there was a corner case where if in an auto mode that sets a reset command on the attitude setpoint message (e.g. auto takeoff), if the mode was then switched stabilized, this reset bool would never be changed back to false and the integrators would reset every cycle
2022-10-28 09:26:51 +02:00
Zachary Lowell 824e02a8b6 Qurt tasks implementation (#20499) 2022-10-27 14:46:47 -07:00
Eric Katzfey fa74ee3d5b perf: removed dprintf from perf library
* Removed dprintf from perf library since it is only ever used with fd=1 (STDOUT) so moved to PX4_INFO_RAW instead. This helps with some platforms (e.g. Qurt) which have some Posix support but not full Posix support.
2022-10-27 09:58:05 -04:00
Silvan Fuhrer 5edbc2f80a Navigator: remove update of reposition setpoint at Transition command
This was previously required to reset the flight speed after a VTOL transition,
but is now no longer required as the DO_CHANGE_SPEED commands are handles directly
in the controllers.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-27 11:04:22 +02:00
Silvan Fuhrer 473b471fb6 Navigator: add guards for using mission_item.loiter_radius only if finite and >FLT_EPS
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-27 10:28:05 +02:00
Silvan Fuhrer 605d4c47b9 Navigator: initialize _mission_item for all navigation modes in Navigator::Navigator()
This fixes the issue where the init happended in the initializer list, at which point
the params were not yet initialized and thus resulted in random values for the init
values of _mission_item.loiter_radius and .acceptance_radius.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-27 10:28:05 +02:00
afwilkin b834f2b5e3 README.md update for discord 2022-10-27 08:06:52 +02:00
Junwoo Hwang c2b2ae55d9 payload_deliverer: Refactor & Handle vehicle command conflicts
Refactor
- Require reboot for PD_GRIPPER_EN parameter change
- Define gripper ACTION_NONE for readability. This makes implicit assumption that -1 equals no-action commanded more explicit
- Tidy the scattered vcmd_ack struct handling cases into a single function
- Refactor to remove return in the middle of function: avoids future complications where a programmer may expect the logic at the end of the function to be executed, but isn't

Vehicle Command Handling
- Cancel the previous running vehicle command if we receive a different vehicle command
- Reject vehicle command if we get a same one that is getting executed
- Save the source system & component of currently running vehicle command
- Added note about new discovered edge case of having same entity sending different gripper commands consequently, where an unexpected ack result may be received
2022-10-27 07:51:17 +02:00
Junwoo Hwang 6529e39f8b payload_deliverer & gripper: Improve intermediate state & vcmd_ack
Gripper:
- Don't command gripper (via uORB `gripper` topic, which maps into an
actuator via Control Allocation) if we are already at the state we want
(e.g. Grabbed / Released) or in the intermediate state to the state we
want -> This prevents spamming on `gripper` topic

Payload Deliverer:
- Add read-once function for Gripper's released / grabbed state
- Send vehicle_command_ack for both release/grab actions.

TODO: target_system & target_component for the released/grabbed vcmd_ack
is incomplete, since we are not keeping track of the vehicle_command
that corresponds to this. This needs to be dealt with in the future, not
sure what the best solution it is for now.

Possible solutions:
- Queue-ing the vehicle command?
- Tying the gripper's action to specific vehicle command one-on-one, to make sure if we send multiple vehicle commands, we know
which command resulted in the action exactly?)

Only command Gripper grab when we are actually initializing gripper

- Previously, on every parameter update, gripper grab was being
commanded
- This commit narrows that scope to only when we are actually
initializing the gripper

Handle gripper de-initialization upon parameter change

- Also added some local state initialization code to init() function of
Gripper
- This will now make init / de-init more graceful & controlled compared
to before
2022-10-27 07:51:17 +02:00
Junwoo Hwang 36a3c716d6 Send IN_PROGRESS command ack when actuating gripper
- This hopefully then alerts the GCS that the command is getting
processed
- Referenced commander's `handle_command` function to implement this. As
it seems like GCS needs the acknowledgement of the command being
processed to execute such commands properly
- Also send FAILED command ack if we can't actuate the gripper

Fix wrong GRIPPER_ACTION conversion from floating point to int32_t

- Due to the MAVLink spec, we actually just convert enums into floating
point, so in PX4 we need to convert the float directly into integer as
well (although there can be precision issues on large numbers)
- This is a limitation in MAVLink spec, and should hopefully be
changed in MAVLink v2
2022-10-27 07:51:17 +02:00
Zachary Lowell eb16730400 Qurt IOCTL dependency addition (#20480) 2022-10-26 12:09:07 -07:00
Beat Küng 25fe13583e Jenskinsfile: use nuttx container as emscripten requires xz to be installed
Fixes the error:
Error: tar (child): xz: Cannot exec: No such file or directory
2022-10-26 14:54:48 -04:00
Zachary Lowell 740d2fccb1 qurt: update for functional logger 2022-10-25 21:07:15 -04:00
Zachary Lowell bcae7e550b Qurt platform/common dependency fixes 2022-10-25 21:06:00 -04:00
Daniel Agar a242a0210e Update world_magnetic_model to latest Mon 24 Oct 2022 09:29:11 PM EDT 2022-10-25 09:20:01 -04:00
Daniel Agar c32cf21b63 commander: estimator check shorten messages
- otherwise these are awkwardly split in mavlink
2022-10-25 08:02:47 +02:00
Daniel Agar a7b909234b commander: estimator nav test is not an arming check 2022-10-25 08:01:30 +02:00
Daniel Agar 6f861ba889 ekf2: pos/vel reset helpers pass new variance
- optical flow velocity reset use already computed _flow_vel_ne
2022-10-24 10:59:58 -04:00
thomas f9f466854b abort front transition in vtol module instead of in navigator/rtl.cpp 2022-10-24 13:55:41 +02:00
thomas 26c36a96f2 remove unnecessary check. correct int comparison. 2022-10-24 13:55:41 +02:00
thomas bf98503dec better return altitude initialisation 2022-10-24 13:55:41 +02:00
thomas f771c7ff63 back transition if RTL is called during front transition 2022-10-24 13:55:41 +02:00
Hamish Willee 96a305322a params/uorb docs: rename mixer to control allocation (#20447) 2022-10-24 13:22:26 +02:00
Igor Mišić 1c5750b292 mavlink: add support for uAvionix transmitters 2022-10-24 11:56:17 +02:00
Igor Mišić c35ae7260b transponder/sagetech_mxs: move the ADS-B related parameters to the lib
ADS-B parameters can be reused for other ADS-B devices
2022-10-24 11:56:17 +02:00
Igor Mišić 4e6c094a54 mavlink/CMakeLists: add uAvionix dialect 2022-10-24 11:56:17 +02:00
Silvan Fuhrer 128e49358e Wind Estimator: remove filter reset due to beta fusion timeout
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-24 09:56:18 +02:00
Daniel Agar ed558e199f ekf2: remove realignYawGPS() (replaced with yaw estimator) 2022-10-21 09:01:30 -04:00
Silvan Fuhrer c267cf71c3 FW Position Control: fix entering of no-position-estimate failsafes
Affects the states AUTO_ALTITUDE and AUTO_CLIMBRATE. Those modes should only be entered
if armed (as they are pure failsafe modes). Also allow though to enter them even if
the position setpoint(s) are invalid, as they are not needed.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-21 09:51:38 +02:00
Silvan Fuhrer 67b2c835e0 FW Positon control: do not use position_setpoint.valid to validate current position_setpoint
Instead of checking the .valid flag of position_setpoint, check for ISFINITE() of lat, lon, alt
    when pulling the position_setpoint triplet. This fixes problems where the .valid flag didn't
    reflect the proper state of the setpoint (e.g. .valid was true, .lat though NAN)

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-21 09:51:38 +02:00
Silvan Fuhrer d8e483ae20 TECS: guard against NAN airspeed setpoints
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-21 09:51:38 +02:00
Eric Katzfey 4afd19f037 Moved the bad-function-cast compiler warning option out of the common flags and into
the nuttx and posix specific options files since this option cannot be used with
the qurt platform. There are header files in the hexagon sdk that fail this check.
2022-10-20 18:18:40 -04:00
bresch 96e7ea7a08 ekf2: remove old mag declination auto-code 2022-10-20 18:16:25 -04:00
bresch f0a0a3e545 ekf2_test: compare mag decl fusion sympy vs symforce 2022-10-20 18:16:25 -04:00
bresch 2f3ea88099 ekf2: migrate mag declination to SymForce 2022-10-20 18:16:25 -04:00
Beniamino Pozzan 7786437a19 Makefile: remove update_ros2_bridge make commands
as Tools/update_px4_ros2_bridge.sh as been deleted
update_ros2_bridge, update_px4_ros_com and update_px4_msgs
are no more needed

Signed-off-by: Beniamino Pozzan <beniamino.pozzan@phd.unipd.it>
2022-10-20 17:43:16 -04:00
Daniel Agar 5030b21d2e ekf2: replace quatToInverseRotMat if only used once 2022-10-20 14:15:32 -04:00
Daniel Agar fb3adc3faa ekf2: move baro compensation to delayed time horizon and add validity check
- this removes an unnecessary virtual call and simplifies things a bit

Co-authored-by: bresch <brescianimathieu@gmail.com>
2022-10-20 09:17:55 -04:00
Daniel Agar b400b7fcc4 vehicle_angular_velocity: ESC RPM notch filters minimize filter resets (#20449)
- vehicle_angular_velocity: ESC RPM notch filters minimize filter resets
 - only allow one filter init per axis per cycle
 - "park" ESC notch filters at min frequency instead of full disable
 - relax timeout before a notch filter is disabled
 - add new parameter IMU_GYRO_DNF_MIN for configuring the minimum notch filter frequency
2022-10-20 09:05:23 -04:00
bresch 89bc28e836 wind_est: extract utility functions to separate file 2022-10-20 11:41:46 +02:00
bresch 2549054b28 wind_est: remove old derivation
replaced by derivation.py
2022-10-20 11:41:46 +02:00
bresch 7115d5643c wind_est: auto-generate initialization of state and cov matrix 2022-10-20 11:41:46 +02:00
bresch a7124d3738 wind_est: auto-generate beta fusion using Symforce 2022-10-20 11:41:46 +02:00
bresch 487b84e90b wind_est: place codegen details in function 2022-10-20 11:41:46 +02:00
Daniel Agar fe80e7aa46 commander: respect COM_CPU_MAX for overload and adjust default threshold 2022-10-19 20:25:06 -04:00
Daniel Agar 309465858a commander: elapsed time checks avoid subtracting unsigned integers
- avoid the possibility of unsigned underflow from subtracting two HRT timestamps (uint64_t)
 - most of these aren't problematic, but people tend to replicate the pattern, so it's better to be safe
 - likely wasn't a problem when people were using hrt_absolute_time() in place, but if using an existing timestamp there's the possibility it's older than a more recent topic update
2022-10-19 20:21:36 -04:00
Daniel Agar cea185268e msg ROS2 compatibility, microdds_client improvements (timesync, reduced code size, added topics, etc), fastrtps purge
- update all msgs to be directly compatible with ROS2
 - microdds_client improvements
   - timesync
   - reduced code size
   - add to most default builds if we can afford it
   - lots of other little changes
 - purge fastrtps (I tried to save this multiple times, but kept hitting roadblocks)
2022-10-19 19:36:47 -04:00
Daniel Agar e211e0ca0e commander: limit some estimator checks to prearm 2022-10-19 19:06:56 -04:00
David Sidrane f60b883041 px4_fmu-v6:Add Revision 1 to manifest to note I2C4 is only internal 2022-10-19 15:48:34 -04:00
Daniel Agar f9509b442c ekf2: height aid source consistency (#20405)
- working towards keeping all height source (baro/ev/gnss/rng) handling as consistent as possible, possibly refactoring these out into separate classes later
2022-10-19 15:35:07 -04:00
Matthias Grob 870229ef49 FunctionsTest: add isFinite() tests with Vector3f arguments 2022-10-19 19:09:20 +02:00
Matthias Grob 5ca28dd6dc Use isAllFinite() in all places that check finiteness on entire vectors or matrices 2022-10-19 19:09:20 +02:00
Matthias Grob 93de9567a5 Matrix: add isAllFinite() to check if every element is finite 2022-10-19 19:09:20 +02:00
bresch f77d7d9413 [AUTO COMMIT] update change indication 2022-10-19 17:34:31 +02:00
bresch cf9859965a ekf2: remove old yaw fusion auto-code 2022-10-19 17:34:31 +02:00
bresch e33215b61c ekf2_test: compare yaw fusion sympy vs symforce 2022-10-19 17:34:31 +02:00
bresch 42f683fa64 ekf2_test: test using positive definite covariance matrix
A covariance matrix needs to be positive definite
2022-10-19 17:34:31 +02:00
bresch 10f9ac148f ekf2: migrate mag yaw fusion to SymForce 2022-10-19 17:34:31 +02:00
bresch a41b6f416e ekf2_test: verify heading innov variance in all orientations 2022-10-19 17:34:31 +02:00
bresch f11908a266 ekf2: generate yaw fusion jacobians using symforce 2022-10-19 17:34:31 +02:00
Peter van der Perk ccd90ede7a Added io_bypass_control daemon to control IO directly from uORB useful RTPS full offboard (#20422) 2022-10-19 09:15:12 -04:00
Silvan Fuhrer aade01776a airspeed selector: only do sideslip fusion (for airspeed less wind estimate) if not landed
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-19 10:35:28 +02:00
Silvan Fuhrer ebc883f157 airspeed selector: remove redundant armed check (it already checks for in_air)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-19 10:35:28 +02:00
Silvan Fuhrer 0c4b2cd0c5 airspeed_selector: update wind estimator (w/o airspeed fusion) always if in FW mode
This fixes a bug where by accident the vtol_status was considered instead of the
vehicle_status, preventing it from running on planes.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-19 10:35:28 +02:00
Jaeyoung Lim 7e49147bcf Fix feedforward acceleration setpoints for fixedwing offboard position
This commit fixes feedforward acceleration setpoints for fixedwing offboard position control.

Previously when acceleration feedforward inputs were sent, negative curvature accelerations were not being computed properly
2022-10-19 09:15:13 +02:00
Daniel Agar b71fc63162 ekf2: fix sideslip timeout (typo) 2022-10-18 18:38:25 -04:00
Daniel Agar 0d2ff6e224 ekf2: test ekf_logger further reduce std::precision to minimize false positives 2022-10-18 14:19:16 -04:00
Daniel Agar 535415a537 ekf2: add OF estimator aid src status 2022-10-18 14:19:16 -04:00
Matthias Grob 75c63aee2a Fix confusion between trajectory_setpoint and vehicle_local_postion_setpoint 2022-10-17 16:18:00 -04:00
Daniel Agar 7c237fca74 boards: px4_sitl use Mavlink development dialect 2022-10-17 16:16:36 -04:00
Daniel Agar 743200df22 mavlink: move mavlink dialect selection to kconfig 2022-10-17 16:16:36 -04:00
Daniel Agar d792a3ff5b simulator_mavlink: use existing development/common mavlink generation if available 2022-10-17 16:16:36 -04:00
Hamish Willee 2a9801f191 Default mavlink dialect should be common.xml 2022-10-17 16:16:36 -04:00
bresch 8b9ac2d7f3 ekf2: remove old mag 3D fusion auto-code 2022-10-17 16:14:56 -04:00
bresch 77a36219c6 ekf2_test: compare 3D mag fusion sympy vs symforce 2022-10-17 16:14:56 -04:00
bresch b92cbe12a0 ekf2: migrate mag 3D fusion to symforce
ekf2: merge mag 3d innov var, Hx and Kx computation to reduce flash

Slightly less code produced, almost no performance change

ekf2_mag3D: do not pre-compute Kalman gains

The vector of Kalaman gains is not too expensive to compute using
matrix-vector multiplication. Pre-generating it using CSE takes a lot of
flash space for little benefit.
2022-10-17 16:14:56 -04:00
Silvan Fuhrer 5ea8c6e507 FlightTaskAuto: remove unused _getTargetVelocityXY()
Inclusive velocity_valid field in position_setpoint message that's then
no longer needed.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-17 16:12:15 -04:00
Silvan Fuhrer 42c613a0c7 position_setpoint.msg: remove unused alt_valid
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-17 16:12:15 -04:00
Silvan Fuhrer 42dd9b5063 position_setpoint.msg: remove unused velocity_frame field
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-17 16:12:15 -04:00
Daniel Agar 0d6766d14d limit vehicle_command subscription updates per cycle
- this is a precaution to eliminate the possibility of getting stuck in
a loop trying to keep up with a high rate publication that could be
coming from a higher priority task
2022-10-17 16:10:51 -04:00
Daniel Agar 677f3e9294 sensors/vehicle_optical_flow: limit gyro updates and generation lost error per cycle
- in the worst case scenario printing the error message can take longer than the next gyro publication, so combined with an infinite loop you could get stuck here
2022-10-17 13:45:04 -04:00
Alex Klimaj 8545164869 sensors/vehicle_optical_flow: only get gyro if optical flow delta angle not available (#20416) 2022-10-17 10:23:36 -04:00
Daniel Agar 116bb6049f ekf2: fusion helper consistency
- yaw fusion use measurementUpdate()
 - fuseVelPosHeight() respect _accel_bias_inhibit (like measurementUpdate())
2022-10-17 10:17:31 -04:00
Silvan Fuhrer 7bc90c7f00 FW rate controller gains: put default for all IMAX gains to 0.4
The previous default for yaw and roll was 0.2, which is very low, and for wheel was
1, which is very high. A value of 0.4 makes sense to me for all axes.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-17 10:27:09 +02:00
Silvan Fuhrer 4bbe8f3c0d FW rate controller gains: open up some limitis for the rate controller gains
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-17 10:27:09 +02:00
Silvan Fuhrer e2d1e79614 FW rate controller gains: reduce max FW_YR_I from 50 to 1
I guess this was a left over from times where the controller had a completely different structure,
a value of 50 is well outside of reasonable range (50x the default).

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-17 10:27:09 +02:00
Silvan Fuhrer ea44c89366 FW rate controller gains: reduce max FF gains to 1
The previous max of 10 for the FF gains seems a bit very high for me, well outside
of reasonable reange.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-17 10:27:09 +02:00
bresch 458e5a6b0e ekf2: update change indicator 2022-10-14 11:42:23 -04:00
bresch 1b4092abbb symforce: temporarily remove custom cmake command
otherwise the generated files are removed with make clean
2022-10-14 11:42:23 -04:00
bresch a8a3107c05 ekf2: remove old covariance prediction code 2022-10-14 11:42:23 -04:00
bresch df084d65e3 ekf2_test: compare covariance prediction sympy vs symforce 2022-10-14 11:42:23 -04:00
bresch a4e511b90e ekf2: migrate covariance prediction to SymForce 2022-10-14 11:42:23 -04:00
chris1seto 079dfdf209 drivers/osd/msp_osd: cleanup and small fixes/additions (#20399)
- Fixed clearing arming word if flightmode unknown
 - Added power and cell voltage elements
 - New OSD layout
 - Fixed home direction/distance are now correct

Co-authored-by: Chris Seto <chris1seto@gmail.com>
2022-10-14 10:54:14 -04:00
Beat Küng 3c290d812d commander: use printRejectMode() also for rtl, takeoff, land & mission commands 2022-10-13 16:05:25 -04:00
Beat Küng d542ffc10c refactor vehicle_status_flags: rename to failsafe_flags 2022-10-13 16:05:25 -04:00
Beat Küng f9c8e760b1 CI: add failsafe web build & deployment to the user guide 2022-10-13 16:05:25 -04:00
chris1seto 0ddba3ea90 Fix Discord badge not a link in README (#20406)
* Add link to image
* Update link to nice permalink

Co-authored-by: Chris Seto <chris1seto@gmail.com>
2022-10-13 11:05:28 -07:00
Daniel Agar 2de990fd4b estimator_aid_source split GNSS pos (3d) -> pos (2d) + hgt
- per estimator air source status only keep a single set of flags and
timestamp that applies to the entire source
2022-10-13 11:28:50 -04:00
David Sidrane 8a9a091ff3 nxp_fmurt1062-v1:Timer configuration for 1 channel per group (timer) 2022-10-13 08:17:51 +02:00
David Sidrane 3be8d52c8e imxrt:io_timers Support 1 channel per group (timer) 2022-10-13 08:17:51 +02:00
David Sidrane 7f7137320a fix imxrt: use 1:1 timer group to channel association 2022-10-13 08:17:51 +02:00
chris1seto 7e9ec325f7 Convert README to Discord (#20400) 2022-10-12 21:41:00 -07:00
bresch bdd043f27f ekf2: fix sideslip fusion sign 2022-10-12 16:14:47 +02:00
bresch 53865118fb ekf2: remove old sideslip fusion code 2022-10-12 09:55:35 -04:00
bresch f7c749c9cd ekf2_test: compare sideslip fusion of Sympy and SymForce 2022-10-12 09:55:35 -04:00
bresch d0f92bfbd5 ekf2_test: create helper functions for auto-generated code diff 2022-10-12 09:55:35 -04:00
bresch 5f54f6fcda ekf2: migrate sideslip fusion to SymForce
- split fusion into update (compute innov and innov_var) and actual fusion to the state vector
- use estimator_aid_source_1d struct to group the data
2022-10-12 09:55:35 -04:00
Beat Küng c09be0f0ac airframes: add r1 again
This was dropped in f454dcef6b
2022-10-12 07:35:35 +02:00
Beat Küng 9b7a8d4568 vehicle_status_flags: add group 'Other' 2022-10-11 22:31:20 -04:00
Beat Küng f7819f5dba commander: reorder update calls
Moves the arming checks before the command handling.
This reduces the chance of race conditions. However it does not prevent
them! The SDK will need to check when offboard is ready to run/arm to fix
this.
Specifically this is for sitl offboard tests, where offboard_control_mode
is updated and immediately after a mode switch into offboard is commanded.
2022-10-11 22:31:20 -04:00
Beat Küng 38d3739b6d refactor commander: rename rc_signal_lost -> manual_control_signal_lost, data_link_lost -> gcs_connection_lost 2022-10-11 22:31:20 -04:00
Beat Küng e2d8ca73a5 commander: add unit tests for failsafe state machine 2022-10-11 22:31:20 -04:00
Beat Küng 3d1da597dd commander: run arming checks on _offboard_control_mode_sub update 2022-10-11 22:31:20 -04:00
Beat Küng 6ee2252b8c events: handle events being generated before a mavlink module started
- do not print dropped events warnings
- make sure current sequence is still sent with reset flag
2022-10-11 22:31:20 -04:00
Beat Küng 3fcdf40a47 events: use PRIx32 to print uint32 2022-10-11 22:31:20 -04:00
Beat Küng acaa50a448 geofence: add and report reason for violation 2022-10-11 22:31:20 -04:00
mcsauder ebc88afe46 Apply Google Style to Commander Private methods, rename geofence message geofence_violation to primary_geofence_breached. 2022-10-11 22:31:20 -04:00
Beat Küng 693af897b3 commander: check if battery was already disconnected on arming
If so, don't report.
Happens e.g. with USB powered pixhawk.
2022-10-11 22:31:20 -04:00
Beat Küng 24142bc014 commander: RcCalibrationChecks: avoid param access on each cycle
reduces cpu usage a bit
2022-10-11 22:31:20 -04:00
Beat Küng c72c580a0b commander: run arming checks @ 10Hz
Required for things like RC loss.
2022-10-11 22:31:20 -04:00
Beat Küng 6fda555cba commander: move ownership of vehicle_status_flags_s to HealthAndArmingChecks 2022-10-11 22:31:20 -04:00
Beat Küng cf2eb69d25 px4events/srcparser: ensure message is a string literal 2022-10-11 22:31:20 -04:00
Beat Küng 500a896a56 commander: print reason for mode rejection & report for GCS switches as well 2022-10-11 22:31:20 -04:00
Beat Küng e4bb219d10 vehicle_status_flags: cleanup message, move non-failsafe flags to vehicle_status 2022-10-11 22:31:20 -04:00
Beat Küng ae6377dfa0 mission_result: remove unused fields 2022-10-11 22:31:20 -04:00
Beat Küng 455b885f86 commander: use new failsafe state machine and add user intention class 2022-10-11 22:31:20 -04:00
Beat Küng a04230faa1 commander: add failsafe state machine with webassembly simulation
to run the simulation:
install sdk: https://emscripten.org/docs/getting_started/downloads.html
make run_failsafe_web_server
open http://0.0.0.0:8000/

Co-authored-by: Konrad <konrad@auterion.com>
2022-10-11 22:31:20 -04:00
Beat Küng 82911e48be fix commander: check estimator type & avoid timestamp wrap-around
Before it was possible that the publication timestamp was never than 'now',
leading to wrap-around.
2022-10-11 22:31:20 -04:00
Beat Küng 27f8298bb9 fix commander: add local position requirement to NAVIGATION_STATE_AUTO_LAND 2022-10-11 22:31:20 -04:00
Beat Küng 57c7b5e843 flight_mode_manager: reduce error verbosity & remove mode switching
While disarmed, commander allows to be in any mode now.
2022-10-11 22:31:20 -04:00
Beat Küng 31dfdea12e commander: remove state_machine_helper tests 2022-10-11 22:31:20 -04:00
Beat Küng e9387cac1d mavlink: move get_px4_custom_mode to px4_custom_mode.h 2022-10-11 22:31:20 -04:00
Silvan Fuhrer 9159f020cb mavlink local_position_ned: always publish on update, not just when xy and v_xy valid
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-11 00:47:32 -04:00
Daniel Agar ce609144b0 simulation/gz_bridge: fix implicit floating-point conversions 2022-10-09 14:11:19 -04:00
Daniel Agar 9010029e0d lib/drivers/device: Device.hpp fully init devid
- constructor use available setters
2022-10-09 13:49:39 -04:00
Daniel Agar f3964513c7 sensors: fix accel/gyro/mag calibration offset units 2022-10-09 13:02:38 -04:00
Daniel Agar ee4821ed0a commander: relax COM_ARM_MAG_ANG default to minimize false positives
- this check is mainly intended for catching blatant setup problems like a magnetometer that's mounted 90 or 180 degrees off
2022-10-09 12:41:06 -04:00
fkaiser 30150f723a Tools/px_uploader.py: use monotonic clock if available (#20352)
Signed-off-by: fkaiser <fabian.kaiser@wingtra.com>
2022-10-06 09:49:05 -04:00
alexklimaj 064f3f86bc Increase mag calibration max_var_allowed 2022-10-06 08:44:36 -04:00
Hamish Willee 022aa13aa1 mpu9250_i2c - also needs docs update 2022-10-05 20:26:25 -04:00
Hamish Willee 6d612b1ba4 MPU9250 driver doc incorrect 2022-10-05 20:26:25 -04:00
Daniel Agar 8cc39096cb load_mon: NuttX cpuload use system times for calculation
- this is to minimize the impact of any load_mon scheduling jitter in the sampled load percentage
2022-10-05 14:21:38 -04:00
benjinne 29b031c862 Tools/setup/ubuntu.sh update comment to include 22.04 2022-10-05 13:41:47 -04:00
Daniel Agar 5f0a539633 gps_blending: fix blending init to best instance
- output GPS publication defaults to best input instance
 - blended states are explicitly cleared and then populated with
weighted blend
2022-10-05 10:26:48 -04:00
Beat Küng f79dad1e63 fix ROMFS: run camera trigger, capture and PPS before pwm_out
As they might need to reserve the pwm pins.
2022-10-05 09:13:35 -04:00
Matthias Grob 46e6e83e14 Commander: allow disarmin not-landed boat like rover
This is a hotfix and a boat should never even detect a takeoff
in normal operation.
2022-10-05 09:07:18 -04:00
Beat Küng dafead6f20 logger: add compressed events metadata file if it exists in the ROMFS
Allows to decode events not (yet) on main.
The file is currently ~15KB.
2022-10-05 07:44:55 +02:00
Beat Küng 02035d94aa metadata: sort json output
ensures the files don't change arbitrarily
2022-10-05 07:44:55 +02:00
modaltb 06a0aedbdb modalai_esc: directly using deadband param value instead of converting it to RPM 2022-10-04 20:14:59 -04:00
Thomas Debrunner 0af87ec745 mavlink: initial OPEN_DRONE_ID_BASIC_ID/OPEN_DRONE_ID_LOCATION support 2022-10-04 14:40:59 -04:00
Matthias Grob b179427b4c Remove opinionated non-default MPC_TKO_SPEED from airframes 2022-10-04 11:36:57 -04:00
pandafeng1999 e4b4df4e5d drivers/distance_sensor/gy_us42: add the specified i2c address 2022-10-04 11:35:45 -04:00
Matthias Grob f96507bb22 vtol_takeoff: fix comment typo 2022-10-04 10:01:04 -04:00
Peter van der Perk c807d6079d FMUK66-V3 Enable DMA on SPI 2022-10-04 09:46:04 -04:00
Peter van der Perk 0cf2ecedb9 FMUK66 Disable Telnet to save RAM 2022-10-04 09:46:04 -04:00
Julian Oes 5c77bbcb4c ms5611: ignore reading 0
This prevents publishing a negative pressure which leads to a NAN
altitude estimate further down the line.
2022-10-04 09:37:53 -04:00
Beat Küng 04b1cbb423 vtol_att_control: standard: also do blending for FW controls
So that the sum of the control is always 1.
2022-10-04 09:54:11 +02:00
Silvan Fuhrer 6db92b4011 ControlAllocation: remove actuator trim value from actuator_sp to calculate allocated control
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-10-04 07:51:25 +02:00
Zachary Lowell 4520186878 qurt: replacing qurt threads with pthread 2022-10-03 18:01:04 -04:00
bresch 4b687beb3b ekf2: remove old airspeed fusion code 2022-10-03 10:59:42 -04:00
bresch 299e6058e3 ekf2_test: test airspeed symforce vs sympy generated code 2022-10-03 10:59:42 -04:00
bresch 29ebef1f74 ekf2: migrate fuse_airspeed to SymForce 2022-10-03 10:59:42 -04:00
Daniel Agar 41cda14126 ekf2: add symforce code generation helper target 2022-10-03 10:59:42 -04:00
Daniel Agar c9441bb48a boards: px4_fmu-v2/v3 allow optional mpu9250 probe to fail without error 2022-10-02 21:40:18 -04:00
Benjamin Perseghetti aa2b47845a new Gazebo simulation handle older gz versions (#20342) 2022-10-02 21:30:30 -04:00
PX4 BuildBot f4d2e176ae Update submodule sitl_gazebo to latest Sun Oct 2 12:38:54 UTC 2022
- sitl_gazebo in PX4/Firmware (2bd1ac005f): https://github.com/PX4/PX4-SITL_gazebo/commit/b968405a617005ba0a793a8b4703913d4c6eff5f
    - sitl_gazebo current upstream: https://github.com/PX4/PX4-SITL_gazebo/commit/e80432759540c91f85a012f47aa6ebb0ee9de7e4
    - Changes: https://github.com/PX4/PX4-SITL_gazebo/compare/b968405a617005ba0a793a8b4703913d4c6eff5f...e80432759540c91f85a012f47aa6ebb0ee9de7e4

    e804327 2022-10-01 Thomas Stauber - set lidar measurements to 0.0 if out of range (#914)
7ed1da6 2022-09-27 Karthik S - Advanced Lift-Drag Plugin (#901)
669d7f5 2022-09-08 Oleg Kalachev - Fix local addr assignment for qgc and sdk sockets
2022-10-02 10:54:31 -04:00
PX4 BuildBot f7a5c91fb3 Update submodule libcanard to latest Sun Oct 2 12:38:56 UTC 2022
- libcanard in PX4/Firmware (8e144eece9e9cd5a23dbeb6723591f214cad631a): https://github.com/opencyphal/libcanard/commit/db87ea32aa092c48ea103963138b6346dd3e9008
    - libcanard current upstream: https://github.com/opencyphal/libcanard/commit/2e3b11f6b8325080c160d38521b169b0bbb6b1c7
    - Changes: https://github.com/opencyphal/libcanard/compare/db87ea32aa092c48ea103963138b6346dd3e9008...2e3b11f6b8325080c160d38521b169b0bbb6b1c7

    2e3b11f 2022-07-15 Pavel Kirienko - Follow-up for #197 -- fix minor issues discovered by Sonar (#198)
106ceaf 2022-07-11 Dmitry Ponomarev - Fix cast-align warnings on ARM
8953fe6 2022-07-06 Dmitry Ponomarev - Add ARM build to github workflow
2022-10-02 10:54:05 -04:00
PX4 BuildBot 644a836d0a Update submodule libevents to latest Sun Oct 2 12:39:02 UTC 2022
- libevents in PX4/Firmware (ddc1e6d6c5c2707be5522d4c4d7434403202cf45): https://github.com/mavlink/libevents/commit/82dabdb914d7bd640c281900e2852d0afc074b68
    - libevents current upstream: https://github.com/mavlink/libevents/commit/a89808bffd1efb0543e66f17a7fa12dfce5e6bf0
    - Changes: https://github.com/mavlink/libevents/compare/82dabdb914d7bd640c281900e2852d0afc074b68...a89808bffd1efb0543e66f17a7fa12dfce5e6bf0

    a89808b 2022-09-26 Beat Küng - combine.py: sort json keys
2022-10-02 10:53:28 -04:00
PX4 BuildBot cf0cd4ebf2 Update submodule mavlink to latest Sun Oct 2 12:39:04 UTC 2022
- mavlink in PX4/Firmware (65bd1fd4c000a7fa0de2a0e8dce1ba9b2a62fa86): https://github.com/mavlink/mavlink/commit/c46af523263ff0dad59afe018fe387c1df030442
    - mavlink current upstream: https://github.com/mavlink/mavlink/commit/dda5a18ddb002a871ba301bb584893ee6378e2f3
    - Changes: https://github.com/mavlink/mavlink/compare/c46af523263ff0dad59afe018fe387c1df030442...dda5a18ddb002a871ba301bb584893ee6378e2f3

    dda5a18d 2022-09-28 WickedShell - Support a return to default speed for DO_CHANGE_SPEED (#1890)
4e04dbbf 2022-09-24 Hamish Willee - MAV_FRAME_BODY_FRD - match to implementations and sanity (#1894)
89a61214 2022-09-23 Hamish Willee - DO_CHANGE_SPEED - clarify lifetime of speed setting (#1892)
11414f88 2022-09-21 Søren Friis - Clarify swarm fields (#1891)
5cdf8b60 2022-09-08 Hamish Willee - HOME_POSITION - clarify local frame means NED (#1886)
551e3b49 2022-09-07 Julian Oes - Fix CI (#1888)
d99ee9b6 2022-09-07 Julian Oes - pymavlink: update submodule to latest master (#1887)
92d2a58d 2022-09-01 Hamish Willee - common.xml:TIMESYNC docs and extensions (#1878)
c424dc65 2022-09-01 Julian Oes - minimal: try to make component ID less confusing (#1876)
153939bd 2022-09-01 Hamish Willee - Fix typo MAV_CMD_DO_SET_MISSION_CURRENT
5043a1e0 2022-09-01 Hamish Willee - MAV_CMD_DO_SET_MISSION_CURRENT - allow mission resetting (#1870)
90aa7bfc 2022-08-31 Chikirev Sirguy - Update common.xml (#1815)
554ccadd 2022-08-31 Hamish Willee - common: OpenDroneID messages no longer WIP (#1882)
06448cf6 2022-08-24 Hamish Willee - MAV_ODID_ARM_STATUS entries update to naming convention (#1883)
ff649224 2022-08-18 Patrick José Pereira - Fix gibberish descriptions ualberta.xml (#1881)
11f4b236 2022-08-18 Hamish Willee - Mission item - document values for autocontinue (#1868)
fb8ac31b 2022-08-18 Julian Oes - development: remove MISSION_CHANGED (#1879)
76b794c2 2022-08-18 Julian Oes - common: extend MISSION_CURRENT (#1869)
1ae3edc4 2022-08-15 Andrew Tridgell - common: added OPEN_DRONE_ID_SYSTEM_UPDATE message (#1880)
aa25f4df 2022-08-11 Andrew Tridgell - common: added OPEN_DRONE_ID_ARM_STATUS (#1873)
2022-10-02 10:53:00 -04:00
Daniel Agar 2bd1ac005f .gitmodules update branches master -> main 2022-10-01 12:22:22 -04:00
Silvan Fuhrer 9b3cb6c758 FW Attitdue controller: fix throttle in acro (use _rate_sp.throttle_body) (#20330)
* FW Attitdue controller: fix throttle in acro (use _rate_sp.throttle_body)

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>

* FW Attitude controller: do manual control polling before attitude setpoint polling

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-30 13:45:20 +02:00
Silvan Fuhrer 34b6786f79 actuator_controls.msg: fix NUM_ACTUATOR_CONTROLS (9)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-29 14:25:16 -04:00
Beat Küng 64ae0049de mission: add support for NAV_CMD_DO_SET_ACTUATOR 2022-09-29 14:23:16 -04:00
Daniel Agar a27aeb30bf mc_pos_control: fix trajectory setpoint copy
- trajectory_setpoint and vehicle_local_position_setpoint used to be
the same data type
 - we got extremely lucky here that this didn't cause any issues due to
all the fields still aligning
2022-09-29 14:17:00 -04:00
bresch 20b46ad33f ekf2_test: test validity of local position when not at rest
At rest, the zero velocity update keeps the local position valid all the
time. Deactivate it to be able to test the validity checks
2022-09-29 14:16:36 -04:00
bresch 1914053db2 ekf2: synchronize z_valid and v_z_valid
mc_pos_control doesn't handle all the cases at the moment
2022-09-29 14:16:36 -04:00
bresch f753b92cff ekf2: start fake pos fusion after dead-reckoning timeout
Starting the fake position as soon as all the aiding sources stop makes
the local position immediately invalid while we could continue to navigate
for a couple of second with inertial dead-reckoning
2022-09-29 14:16:36 -04:00
bresch bb790c9bec ekf2: add vertical dead-reckoning timeout check for height validity 2022-09-29 14:16:36 -04:00
Thomas Stastny da99387215 welford mean: protect against negative variances 2022-09-29 14:14:16 -04:00
Thomas Stastny d3849c0265 welford mean: convert to matrix only template 2022-09-29 14:14:16 -04:00
Daniel Agar d4e5876d4c vehicle_imu: only reset raw accel/gyro Welford mean periodically
- vehicle_imu_status can publish immediately on any measured sample
rate change or sensor error increment, but the windowed mean/variance
shouldn't necessarily reset that often
2022-09-29 14:14:16 -04:00
Benjamin Perseghetti f9522e831c Gazebo Simulation Enablement (#20319) 2022-09-29 13:49:31 -04:00
Silvan Fuhrer f89df9d986 VTOL: make const and return when either of mc or fw att sp isn't updated
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-29 16:01:43 +02:00
Silvan Fuhrer fdcbabeb9e VTOL Tailsitter: don't use the fw attitude sp for determing the initial pitch if not recent
Use a pitch of 0 to initialize the ramp otherwise.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-29 16:01:43 +02:00
Silvan Fuhrer 9c5a423753 VTOL: in update_transition_state(): check that needed virtual attitude setpoints are recent
This is to prevent that that data from non-recent publications of the virtual
attitude setpoints are used in the transition code.
It removes the previous implementation where the update_transition_state()
method was only run when both mc and fw virtual att sp where recent, independetly
of whether both are used or not.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-29 16:01:43 +02:00
Silvan Fuhrer dd2e6bd416 ROMFS: SITL configs: enable airmode by default for all VTOLs
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-29 16:01:43 +02:00
Silvan Fuhrer fbc7e6a435 ROMFS: tiltrotor sitl config: use tilt for yaw in hover as opposed to differential thrust
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-29 16:01:43 +02:00
Silvan Fuhrer 97e3b76a2e VTOL: improve readability of VT_FWD_THRUST_EN param
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-29 16:01:43 +02:00
Roman Bapst 20457c5e2e position_setpoint: replaced loiter_direction integer by boolean (#20317)
* position_setpoint: replaced loiter_direction integer by boolean (loiter_direction_counter_clockwise)

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-09-29 11:06:10 +02:00
Yang Hau 5d39fdba6d fix: Add boundary protection for array access 2022-09-29 08:11:03 +02:00
Yang Hau 2dcde93d96 fix: Fix misuse of atoi() 2022-09-29 08:11:03 +02:00
Yang Hau e2f3157ecb fix: Add missing comma for const strings 2022-09-29 08:11:03 +02:00
David Sidrane 99ef597719 Nuttx with backport of stm32h7:SDMMC fix unaligned access 2022-09-29 07:56:46 +02:00
Ville Juven 59e86c490d Remove include <log.h> from defines.h
The reason for this is that log.h includes drv_hrt.h which sucks in
half the project's include files with it, which causes strange build
issues
2022-09-29 07:56:24 +02:00
Daniel Agar 1f7080a710 ekf2: extend sensor bias stability requirement
- for accel/gyro/mag estimated bias only consider them stable (valid
for calibration updates) if the value isn't changing (10% of limit) over
the validity period
2022-09-28 10:40:52 -04:00
Daniel Agar 16f8adb4b3 hysteresis: avoid subtracting unsigned integers
- avoid potential errors with timestamp passed in from different sources
2022-09-28 09:51:16 -04:00
bresch 06f2004580 Mag: fix estimated bias save to calibration
Clear the calibration at the end only otherwise everything gets erased
at the end of the first iteration of the outer loop
2022-09-28 10:43:54 +02:00
Karthik S 70d73c8690 Advanced Plane Airframe for SITL Advanced Lift-Drag Plugin (#20207)
* Changed sitl_gazebo to the advanced liftdrag plugin fork.

* Added advanced plane and its associated parameters to PX4. Also tweaked one of the plugins to fix a compilation error (upcasting from float to double).

* Switched gazebo back to main branch, to avoid merge conflicts.

* Change simulator bridge back to what it was in main branch

* Changed sitl_gazebo to match the PX4 main branch's (commit hash b968405)

* Changed SimulatorIgnitionBridge to match most recent main.
2022-09-27 23:09:27 +02:00
jmackay2 0ee4d89744 drivers/osd/msp_osd: fix uorb_to_msg isnan floating-point check (#20309) 2022-09-27 14:41:43 -04:00
Eric Katzfey a5bfc3fbc2 Added a self test feature to the VOXL 2 muorb module (#20307)
* Removed exit after dsp signature generation.
* First full test suite
* Cleaned up the muorb tests
* Improved VOXL 2 self test trigger in startup file
* Removed unneeded include file
2022-09-26 16:25:24 -04:00
Daniel Agar 7bc79b491f sensors/vehicle_magnetometer: more granular in flight mag cal reset on parameter changes
- if mag calibration parameters change only reset any inflight mag cal
for the corresponding magnetometer
2022-09-26 12:42:32 -04:00
Daniel Agar 462d0af384 uORB: fix static orb_exists call for protected build
- unify ORBSet to maximum code coverage
2022-09-26 12:38:58 -04:00
Silvan Fuhrer 2717137982 RTL params: remove some unnecessary param constraints
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-26 13:32:35 +02:00
Silvan Fuhrer b0a7d206f3 RTL params: increase max of RTL_RETURN_ALT and improve description
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-26 13:32:35 +02:00
Charles Cross cfdaba35cc Adds reset counter logic to EV height fusion 2022-09-26 11:48:18 +02:00
Daniel M. Sahu 779e738143 MSP OSD Revision 2022-09-24 18:40:47 -04:00
chris1seto 770f8080c0 CRSF: Validate unknown packet sizes to be smaller than max packet size
Co-authored-by: Chris Seto <chris1seto@gmail.com>
2022-09-24 16:36:17 -04:00
Daniel Agar 57bdac2b26 cmake: px4_parse_function_args re-enable failure on unparsed (invalid) arguments 2022-09-24 13:48:51 -04:00
Daniel Agar ca0465aeca Tools/generate_board_targets_json.py: properly exclude VOXL2 for now 2022-09-24 11:27:31 -04:00
Daniel Agar e58275e6f5 platforms/posix: restore none SITL helper target for replay 2022-09-23 19:20:01 -04:00
chris1seto 77fdce9f3c drivers/rc/crsf_rc: update standalone driver for CRSF and direct support for lq/rssi (#20084)
Co-authored-by: Chris Seto <chris1seto@gmail.com>
2022-09-23 19:19:25 -04:00
chris1seto 86cddc6a52 fw_autotune_attitude_control : Add better support for RC TX control while in FW AT (#20069)
Co-authored-by: Chris Seto <chris1seto@gmail.com>
2022-09-23 19:17:51 -04:00
Daniel Agar b7fab39165 icm20948_i2c_passthrough: PX4_ERR is reset/configure fails and check temperature for validity 2022-09-23 19:16:10 -04:00
Daniel Agar eb2a714aa5 ak09916: PX4_ERR if reset/configure is failing after 5s 2022-09-23 19:16:10 -04:00
Daniel Agar 16b4149492 Tools/generate_board_targets_json.py exclude VOXL2 for now (dev environment not yet available to github) 2022-09-23 16:40:56 -04:00
Thomas Debrunner 32277f6332 uavcan rgbled: Scale brightness for constant illumination 2022-09-23 14:33:20 -04:00
Eric Katzfey d30ccb2b1d initial board and platform support for the ModalAI VOXL 2 (POSIX + QuRT) 2022-09-23 12:03:05 -04:00
David Sidrane e6b292b693 Revert "boards: px4_fmu-v6x_default remove gyro_fft to save flash (will be restored later)"
This reverts commit ed16354413.
2022-09-23 09:32:43 -04:00
David Sidrane d749389f95 fmu-v6x:CUAV HW Version changes 2022-09-23 09:32:43 -04:00
bresch cddade2047 ekf2: use validated airspeed from airspeed sensor only
don't use synthetic measurements to prevent circular dependency
2022-09-23 09:26:47 -04:00
Julian Oes 8080ca966a boards/platform: remove confusing override
This removes the odd px4_i2c_bus_external override which was confusing
me and lead to odd and inconsistent results.

The function is now only available with an int as the argument.
2022-09-23 20:54:08 +12:00
Junwoo Hwang 13d565d707 payload_deliverer: Add gripper state output to "status" CLI output
- Previously it was hard to check which state the gripper was in
(GRAB/GRABBED/ etc), not even whether it was correctly initialized, this
commit adds that functionality
2022-09-23 07:41:51 +02:00
Junwoo Hwang e65d48c070 payload_deliverer: Fix Gripper unitialized message spamming
- When the gripper was uninitialized, the error message popped up
everytime the module had 'any' vehicle command received. But we should
be spamming only when we do actually get 'DO_GRIPPER' command received,
this commit adds that feature
- Also converted error messages for CLI when gripper test functinality
fails, so that user would get a feedback (originally, the PX4_DEBUG was
of course not outputting everything)
2022-09-23 07:41:51 +02:00
alexklimaj fdf4b668eb Ark flow rev 3 with PAA3905"
Add AFBR-S50LX85D
2022-09-22 20:36:43 -04:00
Daniel Agar 38d332a553 ekf2: inhibit accel bias dynamically when fake position/height fusion active
- inhibit accel bias learning dynamically depending on the angle between an accelerometer and the vertical axis when fake position fusion is active
2022-09-22 20:32:20 -04:00
Daniel Agar 1806f0d2b4 boards: delete broken flywoo_gn-f405_rtps 2022-09-22 17:44:24 -04:00
Silvan Fuhrer 300288b57e FW Attitude Controller: fix polling of rate setpoint for tailsitter
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-22 19:13:36 +02:00
Daniel Agar ed16354413 boards: px4_fmu-v6x_default remove gyro_fft to save flash (will be restored later) 2022-09-22 11:36:16 -04:00
David Sidrane e284d4aa52 fmu-v6x:CUAV HW Version changes 2022-09-22 11:36:16 -04:00
CUAVmengxiao 21daa0f398 drivers: add support for ICP101XX and ICP201XX 2022-09-22 11:36:16 -04:00
CUAVmengxiao 9493008dbb px4_fmu-v6X: add CUAV board 2022-09-22 11:36:16 -04:00
Silvan Fuhrer 0df878bc18 Navigator: use NAV_FW_ALTL_RAD only for FW landings, not VTOL landings
Also containst a mini refactor by removing the unnecessary function
get_default_altitude_acceptance_radius().

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-22 16:52:51 +02:00
Silvan Fuhrer c6c7733587 FW Position control: add option to scale min airspeed wtih wind magnitude
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-22 16:39:27 +02:00
Beat Küng e8ac9b266b px4events: add @skip-file tag 2022-09-22 09:42:39 -04:00
Daniel Agar 54c97db8b2 ekf2: fix covariance comment typo 2022-09-21 15:29:07 -04:00
Silvan Fuhrer d7fab74727 VTOL: remove _flag_was_in_trans_mode from standard vtol (not used)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-21 14:18:43 -04:00
Silvan Fuhrer 828f629413 VTOL: remove some pwm hackery leftovers from legacy mixing systems
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-21 14:18:43 -04:00
Beat Küng d948fcd72b fix control_allocator: check if 2. thrust and torque sp topic is valid
Otherwise the 2. setpoint is equal to the first one. This is only an issue
if the 2. instance isn't advertised.
2022-09-21 15:11:11 +02:00
Silvan Fuhrer a53e1277dd remove fixedwing example module
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-21 09:03:35 -04:00
Daniel Agar a96187cb18 drivers/optical_flow: paw3902/paa3905 refactor into simple state machine for reset/configure/read 2022-09-20 18:59:00 -04:00
vincentpoont2 d5f7763817 add V5X005001 V5X005002 to start correct sensor 2022-09-21 10:40:04 +12:00
RomanBapst e41913a699 vtol_type: removed unused "was_in_trans_mode" function
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-09-20 16:50:07 +02:00
RomanBapst 2a6cd4a409 vtol_att_control: avoid using non-recent attitude setpoint during beginning
of transition

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-09-20 16:50:07 +02:00
Julian Oes 5aa873aed5 fmu-v6x: alias, add VX43
- alias from hw_mft_list_v0650 to hw_mft_list_v0600 as it is the same
- add V6X50 again
2022-09-20 08:26:16 -04:00
Julian Oes d78de90fc8 fmu-v5x: alias for duplicates, remove commented
- Removed commented out config data.
- hw_mft_list_v0540 was the same as hw_mft_list_v0500
2022-09-20 08:26:16 -04:00
Daniel Agar a47895e809 [DO NOT MERGE] px4_i2c_device_external hacks 2022-09-20 10:31:26 +12:00
Julian Oes b922307ddb px4_fmu-v6c: Move I2C 4 back to External
This is a revert of the revert.
This reverts commit 1080855f4d.
2022-09-20 10:31:26 +12:00
Julian Oes 94c8a4a840 fmu-v6c: internal baro and mag on external bus
This swaps the internal baro and mag back to the bus which is both
internal an external but configured as external for this case.
2022-09-20 10:31:26 +12:00
Silvan Fuhrer 13fc5918cc AirspeedValidator: keep data stuck test but only enable in FW mode
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-19 17:44:44 +02:00
Silvan Fuhrer 1a5d0f4347 AirspeedValidator: add new check (variance after boot) and disable data stuck check by default
This new check is inteded to trigger if there is no data variation published by
the airspeed driver for the first 10s after the first data is published.
This is to capture malfunctioning sensors/drivers that do publish a value, this
value though does not come from real sensor measurements.
Previously this was captured by the data stuck check, but it has shown that
some drivers can publish a stuck value without being actually malfunctioning
(e.g. when the airspeed is outside of their measurement range). Checking for
any data variation is the more conservative check that still catches the above
described failure case.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-19 17:44:44 +02:00
Daniel Agar 0a5c9d4951 position_setpoint delete unused landing_gear 2022-09-19 11:16:45 -04:00
Daniel Agar 11dd924bd4 position_setpoint delete unused SETPOINT_TYPE_FOLLOW_TARGET 2022-09-19 11:16:45 -04:00
Beat Küng c707997b9e lockstep_scheduler: use PRIu64 for timestamp printf 2022-09-19 10:04:31 -04:00
Daniel Agar 87815d8869 simulator_ignition_bridge: add simple esc_status publication
- ideally we'd get this from the actual joint velocity, but this is
good enough to start
2022-09-19 09:49:12 -04:00
Daniel Agar 3440f543f1 simulator_ignition_bridge: wait for first clock set before returning successfully 2022-09-16 21:37:09 -04:00
Daniel Agar 98036f93c5 msp_osd: fix module documentation 2022-09-16 18:54:14 -04:00
modaltb e1098c328e modalai_esc: maintenance release 1 (#20225) 2022-09-16 14:52:28 -07:00
Daniel Agar 07c34f7446 boards: px4_fmu-v6x update bootloader 2022-09-16 12:11:25 -04:00
chris1seto cfb98e44c9 MSP telemetry and OSD support (#19515)
Co-authored-by: Chris Seto <chris.seto@bossanova.com>
2022-09-16 11:46:08 -04:00
Daniel Agar eaa9eae472 simulator_ignition_bridge: fix double promotions 2022-09-16 11:36:35 -04:00
Daniel Agar 085ec0e8ef flight_mode_manager: StickAccelerationXY minimize setpoint oscillations around 0 2022-09-16 07:54:12 +02:00
Ville Juven f300ec1da2 px4_platform_common/atomic.h: fetch_add/sub were really fetch_inc/dec
fetch_add/sub were really inc/dec for the __atomic_always_lock_free == true
branch. This fixes them so that the arg "num" is actually used.
2022-09-15 21:11:08 -04:00
Daniel Agar ff196a7363 crsf_rc: trivial compile fixes for updated vehicle_gps_position and removed NAVIGATION_STATE_AUTO_LANDENGFAIL 2022-09-15 21:01:53 -04:00
Daniel Agar 97f239d3ab boards/flywoo/gn-f405: fix code style 2022-09-15 20:06:01 -04:00
chris1seto b682b30ab1 drivers/rc/crsf_rc: create new standalone CRSF driver 2022-09-15 20:00:20 -04:00
David O b910c1dcf4 Update mavlink_main.cpp
Corrected
2022-09-15 19:49:49 -04:00
David O 8f7233b1e2 Tailsitters need ATTITUDE_QUATERNION to display properly the artificial horizon 2022-09-15 19:49:49 -04:00
Daniel Agar 05850e2fc0 mavlink: eliminate timestamped_list dynamic allocation 2022-09-15 19:27:39 -04:00
David Sidrane eaac84ab20 px4_fmu-v6x_bootloader:Ensure PWM pins are low from boot 2022-09-15 19:24:50 -04:00
Oleg Kalachev 585e81fc30 mavlink: fix path for mavlink_types.h include 2022-09-15 19:20:11 -04:00
Daniel Agar 5fcdffc8c0 drivers/device/nuttx/I2C: only issue I2C_RESET() if retrying, and only before the next retry 2022-09-15 18:42:30 -04:00
Claudio Micheli 30e867d4de navigator_main: use camera_trigger driver for single captures
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2022-09-15 18:15:25 -04:00
Julian Oes fc89705ef8 navigator: stop capturing images on mission exit
When a mission starts capturing images using the
MAV_CMD_IMAGE_START_CAPTURE command, it should also stop it again, in
case it is stopped early, e.g. with RTL.
2022-09-15 18:15:25 -04:00
Zhengtian 70194f52cd boards: New target flywoo goku-gn-f405s-aio (#20131) 2022-09-15 18:11:49 -04:00
Ville Juven 3b9936edd2 hrt_ioctl: Move common code under /common folder
The HRT ioctl is common code, so move it out of chip specific code
2022-09-15 17:57:40 -04:00
Bruce Meagher b1c7098c54 Initial version of log history support. 2022-09-15 14:15:34 -04:00
Beniamino Pozzan 2e83c3a465 Fixed fastrtps version reading in microRTPS generation
Issue addressed: ROS2 is built from source and
no system-wide version of fastrtps is installed

Signed-off-by: Beniamino Pozzan <beniamino.pozzan@phd.unipd.it>
2022-09-15 13:36:40 -04:00
vincentpoont2 4951ce0ed7 Add PX4 vision v1.5 Airframe 2022-09-15 13:33:04 -04:00
Ville Juven 328bc5b8c2 image_toc.c: Check that the ToC actually lies within the first entry
As the first entry is used to sign / authenticate the ToC, make sure
the ToC is actually in the first entry.
2022-09-15 13:32:08 -04:00
murata 9e2ff11d45 fmu-v6x: Add sd_bench command 2022-09-15 13:25:34 -04:00
Travis Bottalico 9c0750776d voxl2_io: initial board support 2022-09-15 13:19:01 -04:00
Silvan Fuhrer 5a74f07a74 RTL: always fill loiter_radius field, indpendent on vehicle type
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-15 13:17:36 -04:00
Silvan Fuhrer e9f349a2fc RTL: set WP type to LOITER_TO_ALT for FW in Return stage
Such that the loiter (orbit) status can be displayed on groundstation
and the WP is accepted once within loiter radius

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-15 13:17:36 -04:00
Silvan Fuhrer 5f0fc7aaf1 FW Position Controller: fix publishing of negative loiter directions (CCW)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-15 13:17:36 -04:00
Silvan Fuhrer 7a760c8c6e RTL: use loiter radius from mission for loiter before enganging mission in RTL
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-15 13:17:36 -04:00
Alex Klimaj 0ce76679b7 boards: add new ARKV6X (#20191) 2022-09-15 13:13:49 -04:00
Alvin Sun 80243aef53 remove microdds from rtps target 2022-09-15 13:10:23 -04:00
Alvin Sun c3e6421549 add v4 rtps build 2022-09-15 13:09:35 -04:00
mcsauder b885c920d8 Breakout header file from sensors.cpp and delete unnecessary #includes. 2022-09-15 13:09:04 -04:00
Junwoo Hwang e3dff5c074 board_identity: Add UUID/MFGUID/GUID unit tests
- To check stack smashing (buffer overflow)
- To check if the buffer without enough length gets appropriate values
filled
- To check if the format has expected length
2022-09-15 13:06:15 -04:00
Junwoo Hwang f5215e8207 board_identity: Fix UUID format function buffer overflow bug
- Previously, not having a proper boundary check caused overflows in the
buffer (wrong memory access)
- Moreoever, negative size values getting introduced to snprintf &
strncat were also being truncated to unsigned value, hence causing
overflow, so index check needed to be added before both functions
- Fixed typo in board_common.h
2022-09-15 13:06:15 -04:00
bresch facf01d69d ekf2: report combined vertical position test ratio 2022-09-15 08:51:19 -04:00
Daniel Agar 54b5d4c5b8 drivers/rc_input: don't allow starting on the px4io serial port 2022-09-14 21:23:30 -04:00
Jaeyoung Lim 9245d71397 Fixedwing att control rate loop cleanup 2022-09-14 13:53:58 +02:00
Silvan Fuhrer b4f27c9abb MissionBlock: loiter exit condition based on vector operation instead of atan
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-14 10:47:21 +02:00
Silvan Fuhrer 27780308c0 MissionBlock: base loiter course exit condition on a constant value instead of MIS_YAW_ERR
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-14 10:47:21 +02:00
Konrad 5a7f098b8d Enable multiple simulated imu and magnetometers in gazebo 2022-09-14 10:27:04 +02:00
Silvan Fuhrer f9b6edab07 Navigator/FW Position Control: VTOL front towards specified transition heading if available
If the current yaw setpoint is valid we should use it to make the transition in this direction.
For a VTOL_TAKEOFF the yaw_setpoint is used to specify the transition direction (the
vehicle is aligned towards it and then transition is started). The current yaw can be
a bit off (e.g. because MIS_YAW_ERR is large), and it is better to track the actual setpoint.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-09-14 08:55:20 +02:00
alexklimaj 82b28bc72f Add BMP390 to BMP388 driver 2022-09-13 09:33:24 -04:00
Vojtech Spurny 7ca16cd504 increased rate of Lidar Lite driver over I2C 2022-09-13 09:11:12 -04:00
David Sidrane 1080855f4d Revert "px4_fmu-v6c Move I2C 4 to External"
This reverts commit 6b2509cbba.
2022-09-13 01:06:17 -04:00
alexklimaj ba1b6f4d2c Standardize AFBR irq lock calls 2022-09-12 19:14:18 -04:00
alexklimaj 3398380262 Switch to async AFBR measurement calls and use schedule. 2022-09-12 13:00:25 -04:00
Shriv 3dffa5e6df gps: add UART2 Baudrate Configurability and New UBX Mode. (#20133) 2022-09-12 14:13:17 +02:00
Daniel Agar b8fb5dfa51 merge px4_sitl_ign into px4_sitl_default (#20188)
- for convenience merge px4_sitl_ign into px4_sitl_default, but allow simulator_ignition_bridge to quietly skip inclusion if ignition-transport isn't available
 - simulator_ignition_bridge only try setting the system clock in
lockstep builds
 - this simplifies usage and CI system dependencies
2022-09-10 16:18:02 -04:00
bresch 34d8bd7988 update EKF2 change indicator 2022-09-10 12:29:29 -04:00
bresch 6bd81c0eb7 ekf2: do not store delayed baro sample in class
the sample is popped from the buffer and directly used; there is no
need to keep a local copy of it
2022-09-10 12:29:29 -04:00
bresch ae1e12a6b5 ekf2: remove baro accumulation from initializeFilter 2022-09-10 12:29:29 -04:00
bresch fe4a6ce8de ekf2: allow initialization without baro data when fusion is disabled 2022-09-10 12:29:29 -04:00
bresch a54fa7b9b1 ekf2: add fake height fusion logic
When there is no vertical aiding, fake height is started to constrain
the vertical channel of the EKF
2022-09-10 12:29:29 -04:00
bresch aa716936bf ekf2: move synthetic_position flag to control_status.flags.fake_pos 2022-09-10 12:29:29 -04:00
Julian Oes 86f7e15f7a libuavcan: update submodule
This fixes a Python 3.10 issue for me.
2022-09-09 20:41:11 -04:00
Daniel Agar 8f25acd428 sih remove gps and use standalone sensor_gps_sim 2022-09-09 18:00:50 -04:00
Daniel Agar bfe0d71a21 sih remove baro and use standalone sensor_baro_sim 2022-09-09 18:00:50 -04:00
Daniel Agar c5336abba2 sih remove mag and use standalone sensor_mag_sim 2022-09-09 18:00:50 -04:00
Daniel Agar 99a20646e2 simulator sih add local position ground truth and cleanup 2022-09-09 18:00:50 -04:00
Daniel Agar 355f184f06 boards/px4/fmu-v3: allow optional ms5607 startup to fail quietly (no error) 2022-09-09 17:32:18 -04:00
Alvin Sun 238fdadfee Add attitude and bodyrate control to RTPS 2022-09-09 22:21:02 +02:00
Daniel Agar 3f3a5f19f0 parameters: open export files O_TRUNC to discard previous data
- rcS parameter backup try to directly restore param (FRAM) from backup (in case SD card is removed before successful export)
 - rcS parameter backup logging rearrange to capture more logging output (param_import_fail.txt)
 - posix rcS try to keep param backup and restore roughly in sync with NuttX rcS
 - tinybson fix debug printf format
 - param_export_internal ensure file descriptor positioned at 0 (precaution)
2022-09-09 16:20:16 -04:00
Igor Mišić 296b1704c5 invensense/icm42688p: add additional state FIFO_RESET
This state is added to give extra time between  FIFO flush command. Some icm42688p IMUs need more time between config -> FIFO reset -> FIFO read. More about the issue  #20181
2022-09-09 16:19:10 -04:00
Alex Klimaj efcf4c95fd drivers/uavcannode: Add RTCMStream subscriber and fix RTCMStream Publisher (#20056)
* Add cannode RTCMStream subscriber
* Fix uavcan RTCMStream publisher
* Break out CANNODE_SUB_RTCM and CANNODE_SUB_MBD
2022-09-09 15:16:09 -04:00
Daniel Agar 9d1aeb6aa7 platforms/posix: cleanup macos legacy 2022-09-09 13:05:06 -04:00
matthewoots b09329f287 boards/matek/h743: add fix to resolve no startup of imu for matek_h743 target (#20184)
* Add fix for matek_h743 target that resolves no startup of imu for h743-wing v3 and h743-wlite boards
* Added imu driver according to spi bus (https://www.mateksys.com/?portfolio=h743-wing-v2#tab-id-7)
2022-09-09 13:02:38 -04:00
Agata Barcis e268e69265 Fixed fastrtps version reading in microRTPS generation for ROS2 built from sources 2022-09-09 15:11:11 +01:00
Daniel Agar b45daac0e8 commander: fix angular velocity validity
- vehicle_angular_velocity timestamp can be newer than saved now
2022-09-09 09:14:09 -04:00
Daniel Agar 15fece7e14 delete SYS_CTRL_ALLOC 2022-09-09 09:14:09 -04:00
Daniel Agar 13f9eabd70 delete unused actuator_controls_3 2022-09-09 09:14:09 -04:00
Daniel Agar 55be169e18 delete remaining PWM_MAIN/PWM_AUX/PWM_EXTRA parameters 2022-09-09 09:14:09 -04:00
Daniel Agar 4ec9e2f216 uavcan: delete unused ESC idle and soft_stop 2022-09-09 09:14:09 -04:00
Daniel Agar bdec17a9d4 drivers/pwm_out_sim: add perf counters (sync with drivers/pwm_out) 2022-09-09 09:14:09 -04:00
Daniel Agar baa05b2631 drivers/pwm_out: remove custom module boilerplate (dual output bank handling) 2022-09-09 09:14:09 -04:00
Daniel Agar ce337a3d80 delete unused PWM IOCTLs 2022-09-09 09:14:09 -04:00
Daniel Agar bcdd2203d3 delete systemcmds/motor_test and msg/test_motor.msg 2022-09-09 09:14:09 -04:00
Daniel Agar 72efe84b80 delete MOT_ORDERING 2022-09-09 09:14:09 -04:00
Daniel Agar a7bbcd5b04 delete lib/mixer and mixer_module static mixing 2022-09-09 09:14:09 -04:00
Daniel Agar 0019ffbea6 delete drv_mixer.h 2022-09-09 09:14:09 -04:00
Daniel Agar d3312f955f delete systemcmds/pwm 2022-09-09 09:14:09 -04:00
Daniel Agar 5dd1e5a018 delete systemcmds/mixer 2022-09-09 09:14:09 -04:00
Daniel Agar cac9c51ac8 ROMFS: purge old mixing system
- SYS_USE_IO is now off by default (enabled by default per board)
2022-09-09 09:14:09 -04:00
Julian Oes ed10146e9f fmu-v6: disable Rev 0, Rev 1 for HB Mini, and CM4
As I understand it, only Rev 3 and Rev 4 were shipped by HB for Mini and
CM4, and are likely to be used for it.

It would be nice to have all combinations but it requires quite some
flash in the current implementation.
2022-09-08 20:54:19 -04:00
Julian Oes f05fccebb7 fmu-v5x: disable rev0 for HB Mini and CM4 base
As I understand it, only Rev 1 and Rev 2 were shipped by HB, and likely
to be used for the Mini and CM4.
2022-09-08 20:54:19 -04:00
Julian Oes 6bd020e848 platforms: decrease flash usage by type for bus id
My assumption is that the bus are numbered < 127.
This saves about 100 bytes of flash.
2022-09-08 20:54:19 -04:00
vincentpoont2 4fe90322db update fmu-v6x rc.board_sensors, add V6X004003 2022-09-08 20:54:19 -04:00
vincentpoont2 167c3da99d update fmuv5x rc.board_sensors with V5X004000 2022-09-08 20:54:19 -04:00
Vincent Poon 70321ed610 update v5x rc.board_sensors
add V5X004002
2022-09-08 20:54:19 -04:00
Vincentpoont2 f476ebdcbf Correct BOARD_NUM_SPI_CFG_HW_VERSIONS at board_config.h 2022-09-08 20:54:19 -04:00
Vincentpoont2 9d5adf8bab Fix Error on manifest.c 2022-09-08 20:54:19 -04:00
Vincentpoont2 e91295e5db Fix Error on board_config.h Define on FMUv5X & FMUv6X 2022-09-08 20:54:19 -04:00
Vincentpoont2 b16a53018d Add Holybro Pixhawk Pi CM4 Baseboard Support 2022-09-08 20:54:19 -04:00
Don Gagne 0987bb2e8e Fix bug with yaw only reposition
Fix formatting
2022-09-08 17:55:30 -04:00
Matthias Grob da01dd9eeb mission_block: explicitly (re)set the acceptance radius to default for takeoff items
otherwise a previously adjusted or uninitialized radius from the last flight
can cause problems during the new takeoff
2022-09-08 14:49:32 +02:00
Matthias Grob b825b61a20 mission_block: minimal acceptance radius of 1mm
to avoid float rounding errors leading to tiny acceptance radii
getting considered
2022-09-08 14:49:32 +02:00
Ville Juven 9c204774f1 px4_userspace_init: Fix NULL dereference for px4_spi_buses in user space
For targets that define the SPI buses via px4_spi_buses_all_hw, a call
to px4_set_spi_buses_from_hw_version() is needed. Otherwise a NULL
de-reference will occur when trying to access px4_spi_buses.

Fixes a system crash in px4_fmu-v5_protected:
up_assert: Assertion failed at file:armv7-m/arm_memfault.c line: 101 task: wq:lp_default
2022-09-08 07:05:11 +02:00
Justin 88bf1030b5 Update CI to use the main branches. 2022-09-07 20:03:19 -04:00
Ville Juven d4cce452cf modules/dataman: Increase stack size by 100B
Fixes:
WARN  [load_mon] dataman low on stack! (276 bytes left)

Seen on px4_fmu-v5_protected target.
2022-09-07 20:02:26 -04:00
Junwoo Hwang 2542b1bb26 Implement Pacakge delivery via Gripper during mission
This feature allows user to use a Gripper type pacakge delivery
mechanism on a drone to trigger the delivery during a mission via the
mission item `DO_GRIPPER`.

This is a minimal change that is intended to have simplest pacakge
delivery feature on PX4, however the future scope would extend this
feature out of Navigator, and rather move towards a federated PX4
(flight-mode flexibility) architecture. But until then, this will serve
the purpose.

Update Tools/sitl_gazebo submodule to remove sdf file overwrite error

- There was an error happening due to .sdf file being overwritten, it
was caused by a wrongfully added. sdf file.
- This update pulls in the PR commit: https://github.com/Auterion/sitl_gazebo/pull/147

Initial cut on supporing PAYLOAD_PLACE mission item

Tidy and comment on navigation.h to clarify mission item definition

- Convert vehicle command ack subscription data type to
SubscriptionData, to not care about having a dedicated struct for
copying the latest data
- Tidy and comment on navigation.h to clarify the definition of
mission_item_s, which is confusing as it is an intergration of MAVLink
Standard into PX4's internal Mission Item structure

Rename mission_block's mission item reached function & cleanup navigator

- Isolated Handle Vehicle Commands function inside the Navigator
- Rename mission_block's mission item reached function to 'reached or
completed', as the navigation command can also be an action (e.g.
DO_SET_SERVO, which doesn't make sense to refer to as 'reached' when we
have successfully done executed the command)

Include MAVLink PR commit to include payload_drop message

More changes to add payload_drop MAVLink message support

- Comitting for testing purposes

Add mission item payload_drop to vehicle command payload drop link

- Now with a mission item with the nav_cmd set to 'payload drop', the
appropriate 'payload drop' vehicle command will be issued

Make Payload drop executable via Mission Plan

Implement payload_drop module to simulate payload delivery

- Simple module that acknowledges the payload drop vehicle command after
certain time, to simulate a successful delivery

Additional changes - payload drop module not working yet

- Need to do more thread stuff to make it work :(

Fix Payload Drop enum mismatch in vehicle_command enums

- First functional Payload Drop Implementation MVP
- Simple Ack & resuming mission from Navigator tested successfully

Hold the position while executing payload drop mission item

- Still the position hold is not solid, maybe I am missing something in
the position setpoint part and all the internal implications of
Navigator :(

Add DO_WINCH command support

Some fixes after rebase on develop branch

- Some missed brackets
- Some comment edits, etc

Add DO_WINCH command support

- Still has a problem of flying away from the waypoint while the
DO_WINCH is being executed, probably position setpoint related stuff :(

Apply braking of the vehicle for DO_WINCH command

- Copies the behavior of NAV_CMD_DELAY, which executes a smooth, braking
behavior when executing the delay because of the braking condition in
`set_mission_items` function
- This will not apply to Fixed wings
- The payload deploy getting triggered may be too early, as right now as
soon as the vehicle approaches the waypoint within the acceptance
threshold, the payload gets deployed

Add DO_GRIPPER support

Implement Gripper actual Hardware triggering support

- Currently not working, possibly in the mixer there's a bug
- Implemented the publishing of actuator_controls_1 uORB topic
- Implemented the test command for the payload_drop module, to test the
grpiper functionality
- Edited px4board file to include the payload_drop module
- Added Holybro X500 V2 airframe file, to enable testing on X500 V2
- Created new Quad X Payload Delivery mixer, which maps the actuator
controls 1 topic's data into the MAIN pin 5 output

Make Payload Drop Gripper Work

- Initialization of the Gripper position to CLOSED on Constructor of the
payload_drop module
- Setting the OPEN and CLOSED value to the appropriate actuator controls
input

Set vehicle_command_ack message's timestamp correctly

- By not setting the timestamp, the ack commands were not correctly
graphed in PlotJuggler!

Rename payload drop module to payload deliverer

- I think it's a more complex name (harder to type), but more generic

Add Gripper class (WIP)

Add Gripper class functionalities

- Add gripper uORB message
- Add gripper state machine

Use Gripper class as main interface in payload_deliverer

- Utilizes Gripper class functions for doing Gripper functionality

Remove mixer based package delivery trigger logic

- Remove custom mixer files that mapped actuator controls to outputs
statically

Additional improvements of the payload_deliverer

Fix payload_deliverer module not starting

- _task_id wasn't geting set appropriately in task_spawn function, which
led to runtime failure

Add Gripper Function to mixer_module

- Still not showing up as function mapping in QGC, needs fix

Add parameters to control gripper behavior

- Now user can enable / disable gripper
- Also select which type of gripper to use

Applying review from nuno

Remove timeout fetching from mission item and use gripper's timeout

- Previously, it was planned to use a custom DO_GRIPPER and DO_WINCH
MAVLink message definitions with information on timeout, but since now
we are using original message definition, only relevant timeout
information is defined in the payload_deliverer class

- This change brings in the timeout parameter to the Navigator, which
then sets the timeout in the mission_block class level, which then
processes the timeout logic

Make payload deployment work for Allmend test :P

Support gripper open/close test commands in payload_deliverer

Move enum definition for GRIPPER_ACTION to vehicle_command.msg

Remove double call for ` ${R}etc/init.d/rc.vehicle_setup`

- Was introduced during the rebase
- Was causing module already running & uORB topic can't be advertised
errors

Fix format via `make format` command

Modify S500 airframe file to use for control allocation usage

- Added Control allocation related parameters as default to not have it
reset every time the airframe is selected

Implement mission specific payload deploy timeout and more changes

Switch payload_deliverer to run on work queue

Remove unnecessary files

- Airframe changes from enabling control allocation are removed

Address review comments

- Remove debug messages
- Remove unnecessary or verbose comments & code
- Properly call parameter_update() function

Switch payload_deliverer to scheduled interval work item & refactor

- Switch to Schedeuled on Interval Work Item, as previous vehicle
command subscription callback based behavior led to vehicle comamnd ack
not being sent accordingly (since the Run() wouldn't be called unless
there's a new vehicle command), leading to ack command not being sent
out
- Also, old vehicle commands were getting fetched due to the
subscription callback as well, which was removed with this patch
- Fix the wrong population of floating point param2 field of vehicle
command by int8_t type gripper action by creating dedicated function
- Refactor and add comments to increase readability

Add gripper::grabbing() method and handle this in parameter update

- Previously, the intermediate state 'grabbing' was not considered, and
when the parameter update was called after the first initialization of
the gripper, the grab() function was being called again, which would
produce unnecessary duplicate vehicle command.
- Also replaced direct .grab() access to sending vehicle comamnd, which
unifies the gripper actuation mechanism through vehicle commands.

Navigator: Change SubscriptionData to Subscription to reduce memory usage

- Also removed unused vehicle command ack sub

PayloadDeliverer: Remove unnecessary changes & Bring back vehicle_command sub cb
2022-09-07 08:11:52 +02:00
Matthias Grob e115095f70 Functions: correct interpolate function for N points 2022-09-07 08:00:27 +02:00
Beat Küng 4087c27e84 control_allocator: handle saturation flags for helicopters 2022-09-07 08:00:27 +02:00
alexklimaj aa8d594e9b Add heli servo trim 2022-09-07 08:00:27 +02:00
Matthias Grob 667e99be81 Helicopter: fix unit test after default throttle curve was changed 2022-09-07 08:00:27 +02:00
Matthias Grob 115cf4d572 Helicopter: More intuitive yaw direction configuration for the common cases 2022-09-07 08:00:27 +02:00
Matthias Grob f233f2167e generic_250, px4vision: remove zero manual thrust without airmode
When hitting zero thrust by stick there is 0 torque authority
without airmode. So 0% minimum manual thrust should never be the default
without airmode.
2022-09-07 08:00:27 +02:00
Matthias Grob 8a25d06ed7 heli_defaults: comment and spacing 2022-09-07 08:00:26 +02:00
Beat Küng cecef7e3f6 control_allocator: update heli throttle + collective curve defaults 2022-09-07 08:00:26 +02:00
Beat Küng d38c02fd6a commander: increase maximum COM_SPOOLUP_TIME to 30s (for helis) 2022-09-07 08:00:26 +02:00
Beat Küng 2635e2c386 airframes: replace blade with generic helicopter 2022-09-07 08:00:26 +02:00
Beat Küng 7e75b497ae helicopter: add switch to engage main motor
For helicopters it's useful (e.g. during bringup) to be able to disable
the main rotor while the tail is still controlled to safely land.
2022-09-07 08:00:26 +02:00
Matthias Grob f32d931117 helicopter: add yaw sign parameter & expose settings in UI 2022-09-07 08:00:26 +02:00
Matthias Grob 349f152601 Helicopter: throttle spoolup upon arming
Uses COM_SPOOLUP_TIME to slowly ramp the throttle and allow the
tailrotor to compensate in a coordinated way based on the yaw
compesation from throttle, see CA_HELI_YAW_TH_S.

This coordinated spoolup is necessary to avoid unsafe yaw twitches
because of the heli rotating until the correct compensation kicks in
through the feedback controller.
2022-09-07 08:00:26 +02:00
Matthias Grob 7bf62373ae Helicopter: refactor complicated throttle curve logic 2022-09-07 08:00:26 +02:00
Matthias Grob 2edb35b1b5 Functions: add gradual function with arbitrary number of corner points 2022-09-07 08:00:26 +02:00
Matthias Grob 6a9a049f1e Helicopter: add unit testing for throttle curve 2022-09-07 08:00:26 +02:00
Matthias Grob 9ba6f4efb7 Helicopter: add yaw compensation from throttle CA_HELI_YAW_TH_S 2022-09-07 08:00:26 +02:00
Matthias Grob 554d965a2d Helicopter: use absolute value for yaw compensation from collective pitch 2022-09-07 08:00:26 +02:00
Beat Küng 608ab9ff9c control_allocator: extend description for CA_SP0_ANGx 2022-09-07 08:00:25 +02:00
Beat Küng e346190e63 helicopter: use tail motor & add CA_HELI_YAW_CP_S 2022-09-07 08:00:25 +02:00
Julian Oes 5ece24cdc4 setup: attempt to fix macOS CI
Somehow the wheel install of pymavlink fails without future, let's try
to work around that.
2022-09-07 13:49:37 +12:00
Peter van der Perk 8f0c2f4146 UCANS32K1 Enable some sensors by default 2022-09-06 09:43:11 -04:00
bresch 92fbd86b46 ekf2: add gps altitude drift test 2022-09-05 10:28:37 -04:00
bresch a2a5093881 ekf2: relax zero velocity update
The ZVU is too strong and prevents the EKF from following variations in
the height aiding sources, creating large innovations.
2022-09-05 10:28:37 -04:00
Daniel Agar d996af4647 ekf2: pass gpsSample around where required
- this minimizes potential misuse accessing _gps_sample_delayed and
makes the dependency clear
2022-09-05 10:27:19 -04:00
RomanBapst 0c860fa227 airspeed_selector: don't declare wind estimate valid if estmator is not initialised
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-09-05 10:21:38 -04:00
Ville Juven 9ed35debec board_ctrl: Clean up usage of VBUS, nARMED from user/kernelspace
Move logic implemented in the header files to source files, this way
it will be simpler to define which is compiled to kernel space and
which to user space

Also allows to remove some headers that pull in half the universe
from the board definitions (which should just be pin definitions and
no functionality)
2022-09-05 07:37:28 +02:00
Benjamin Perseghetti a56f654651 Multi-Vehicle Ignition Gazebo Simulation (#20154) 2022-09-04 21:10:29 -04:00
Daniel Agar 7bbdc220f5 ekf2: initialiseFilter() simplify mag heading init and resetQuatStateYaw
- most of resetQuatStateYaw doesn't apply to initial heading init, so
removing the special case keeps it simple
2022-09-02 08:46:10 -04:00
Ville Juven e467d11990 boards/px4/fmu-v5/toc: The RD certificate signature points to the wrong place
The signature end address is incorrect
2022-09-02 08:00:27 +02:00
Daniel Agar 5dfd2f39ef boards/cubepilot/cubeorange: initialize all I2C pins immediately 2022-09-01 20:46:09 -04:00
Daniel Agar e93a3a2a3a ak09916: enable retries and reset perf count 2022-09-01 20:45:20 -04:00
Daniel Agar f66b5ce204 simulation: ignition bridge allow IMU or pose callbacks to update system time if newer than clock
* requires HRT lockstep changes to eliminate offset (PR #20146)
2022-09-01 20:42:21 -04:00
Daniel Agar c52f2143d2 posix lockstep remove HRT offset and use full sim time 2022-09-01 20:40:37 -04:00
Daniel Agar 3da0293369 simulator_ignition_bridge: init error handling 2022-09-01 18:54:59 -04:00
Beat Küng 43c5f14aa0 commander: update arming & health protocol, add modes to event hash 2022-09-01 17:07:23 -04:00
Beat Küng f57321d365 simulator_mavlink: fix esc_status publication 2022-09-01 17:07:23 -04:00
Beat Küng 295caaea60 events/enums.json: remove redundant manual_control_input 2022-09-01 17:07:23 -04:00
Beat Küng 2c96bb3746 px4_parameters.hpp.jinja: explicitly set .name attribute
Fixes the compile error on llvm:
mixture of designated and non-designated initializers in the same initializer list is a C99 extension [-Wc99-designator]
2022-09-01 17:07:23 -04:00
Beat Küng 1370cc0d74 log.h: add PRINTF_LOG option for direct printf to reduce dependencies 2022-09-01 17:07:23 -04:00
Beat Küng a9c1415337 Makefile: allow to set CMAKE_ARGS via CLI 2022-09-01 17:07:23 -04:00
Beat Küng 4e940fab83 perf_counter: remove unused include sys/queue.h 2022-09-01 17:07:23 -04:00
Beat Küng 9eff6dd049 commander: cleanup param value description for COM_POSCTL_NAVL 2022-09-01 17:07:23 -04:00
Beat Küng 0e130eac83 refactor commander: move code inside run() into separate methods 2022-09-01 17:07:23 -04:00
Beat Küng dcb9b712bb refactor commander: move vehicle control mode to ModeUtil 2022-09-01 17:07:23 -04:00
Beat Küng f197c8884d commander: move esc checks to arming check 2022-09-01 17:07:23 -04:00
Beat Küng c9037f115b refactor commander: split out home position 2022-09-01 17:07:23 -04:00
Beat Küng f17f38197d commander: move estimator checks to arming check 2022-09-01 17:07:23 -04:00
Beat Küng cfe3d793bf commander: move battery handling into arming checks 2022-09-01 17:07:23 -04:00
Daniel Agar 5cb44a521c ekf2: estimator interface handle sample time with signed integers
- this prevents unsigned integer overflow if the timestamp is smaller
than the configured delay (mostly a simulation edge case)
2022-09-01 09:47:29 -04:00
dagar 75f6f22223 [AUTO COMMIT] update change indication 2022-08-31 08:52:30 -04:00
Daniel Agar 1948c5057a ekf2: handle all time on delayed horizon (except for newest sample checks)
- a growing number of samples come into the backend with the time
already delayed (sensor's interrupt setting timestamp sample)
 - if the incoming timestamp is already delayed then the new data checks
(relative to latest IMU) can be slightly wrong
 - handle almost all timestamps and checks on delayed time horizon,
except for explicit checks of new samples
 - isRecent() and isTimedOut() helpers use delayed time
 - add new isNewestSampleRecent() used for checking the incoming
timestamp of the incoming (adjusted) data
2022-08-31 08:52:30 -04:00
Jukka Laitinen d6a4e158cf Add call-gates to px4_crypto for protected build
This adds kernel-userspace interfaces to crypto layer

Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2022-08-31 09:48:49 +02:00
Beat Küng d681782c7f fix flashfs: find_entry: do not go to the next sector if the CRC is invalid 2022-08-31 09:42:59 +02:00
Beat Küng 4f52cda504 flashfs: ensure no address past the end of a sector is dereferenced
As it might result in a hardfault if it's the last flash sector.
2022-08-31 09:42:59 +02:00
Beat Küng 2776b723ea holybro/kakuteh7: switch to flash-based params 2022-08-31 09:42:59 +02:00
Hamish Willee e780a583cd Fix typo follow height: FLW_TGT_HT 2022-08-29 13:25:35 +02:00
Ben Berry 734d3e4aa0 Reverted changes that broke Level Horizon calibration 2022-08-29 09:54:36 +02:00
Beat Küng afc99749b8 px4/fmu-v5/uavcanv0perith: disable gps to reduce flash usage 2022-08-25 22:02:15 -04:00
Beat Küng 715afd27f5 ROMFS: exclude mixers on v2 & disable mixer command
The dynamic mixing is now the default
2022-08-25 22:02:15 -04:00
Beat Küng f0295cf596 px4/fmu-v2/defconfig: disable PROCFS
Reduces flash usage by ~7.3KB
2022-08-25 22:02:15 -04:00
Beat Küng ad222760dd platforms: move CONFIG_FS_PROCFS_MAX_TASKS definition to cpuload.h
So it's used for both cases
2022-08-25 22:02:15 -04:00
Beat Küng 70ec3493c5 px4/fmu-v5/stackcheck: disable distance sensors to reduce flash 2022-08-25 22:02:15 -04:00
Beat Küng 666b84027d GyroFFT: disable 4096 for IMU_GYRO_FFT_LEN
saves around 10.5KB flash on px4-fmu-v5
2022-08-25 22:02:15 -04:00
Beat Küng 060738cae1 src: avoid use of double precision pow & exp
saves around 5KB flash on px4-fmu-v5
2022-08-25 22:02:15 -04:00
Beat Küng 983a9815eb libevents: update submodule 2022-08-25 22:02:15 -04:00
Beat Küng 4c41934bb4 commander: inline HealthComponentIndex::HealthComponentIndex
Saves around 1KB flash
2022-08-25 22:02:15 -04:00
Beat Küng 1c89b0c9c8 commander: use actuator_function for ESC reporting 2022-08-25 22:02:15 -04:00
Beat Küng 13c93db11a commander: use circuit breaker params directly in arming checks 2022-08-25 22:02:15 -04:00
Beat Küng 4230eee24f commander: print 'ready for takeoff' to console for sitl after startup 2022-08-25 22:02:15 -04:00
Beat Küng 2fccb576ad commander: remove unused includes and variables 2022-08-25 22:02:15 -04:00
Beat Küng dbb814ff24 HealthAndArmingChecks: CONSOLE_PRINT_ARMING_CHECK_EVENT & reduce flash usage
- print list of events whenever they change if
  CONSOLE_PRINT_ARMING_CHECK_EVENT is set, instead of on each update call
- reduce flash usage by moving out templated code into non-template method
2022-08-25 22:02:15 -04:00
Beat Küng b2cb164c12 commander: replace health flags with health_report from arming checks 2022-08-25 22:02:15 -04:00
Beat Küng 6d1fb92eb7 commander: rework arming checks to use the events interface 2022-08-25 22:02:15 -04:00
Beat Küng b4a3597c7d posix rcS: set PWM_AUX_OUT
Prevents a shell error in rc.interface
2022-08-25 22:02:15 -04:00
Beat Küng b3fe0eeae8 mavlink_events: send reset sequence out immediately on startup 2022-08-25 22:02:15 -04:00
Beat Küng 552d08176f posix rcS: set MAV_PROTO_VER to 2
For SITL it's important that the GCS receives the first events messages
that reset the sequence number, in case the user does not press 'Disconnect'
when restarting SITL.
2022-08-25 22:02:15 -04:00
Beat Küng c7b64e3c01 commander: check for ack when calling 'commander takeoff' 2022-08-25 22:02:15 -04:00
Beat Küng 406b0bbc86 commander: handle VEHICLE_CMD_RUN_PREARM_CHECKS 2022-08-25 22:02:15 -04:00
Beat Küng 8f9be0541f HealthAndArmingChecks: add support for legacy mavlink_log reporting 2022-08-25 22:02:15 -04:00
Beat Küng f23363f88c HealthAndArmingChecks: add unit tests for Report 2022-08-25 22:02:15 -04:00
Beat Küng 2507f0a143 px4events: fix known_groups list 2022-08-25 22:02:15 -04:00
Beat Küng fcadc69e52 mavlink_receiver: set timestamp to gps_inject_data_topic 2022-08-25 22:02:15 -04:00
Beat Küng c95192d050 orb_print_message_internal: handle 64 bit bitsets 2022-08-25 22:02:15 -04:00
Beat Küng b7a6de05df arming checks: add health topic 2022-08-25 22:02:15 -04:00
Beat Küng 07afcf4586 commander preflight checks: new structure using events interface
- Reporter class that keeps track of results (list of events + whether
  arming is possible + health).
  And only reports when one or more checks change.
2022-08-25 22:02:15 -04:00
Beat Küng 04f7df3848 SubscriptionMultiArray: use Subscription instead of SubscriptionInterval
Saves ~3KB RAM on fmu-v5.
2022-08-25 22:02:15 -04:00
Daniel Agar 9b0b0d1168 ekf2: update test change indication csv 2022-08-25 15:55:45 -04:00
Ville Juven f60f6d2425 Remove px4_work_queue from the kernel side LD command
The comment is right, it is not needed -> get rid of it
2022-08-25 13:30:11 -04:00
Daniel Agar 2786239ca6 Jenkinsfile: HIL remove delete airframe from test 2022-08-25 09:48:49 -04:00
Benjamin Perseghetti 02c9ec6085 Add thumbnails for x500. 2022-08-25 09:10:03 -04:00
Benjamin Perseghetti 0e8e38e698 Add x500 ignition (replaces x3) 2022-08-25 09:10:03 -04:00
Daniel Agar 4040e4cdf2 simulation organization and cleanup
- new modules/simulation directory to collect all simulators and related modules
 - new Tools/simulation directory to collect and organize scattered simulation submodules, scripts, etc
 - simulation module renamed to simulator_mavlink
 - sih renamed to simulator_sih (not a great name, but I wanted to be clear it was a simulator)
 - ignition_simulator renamed to simulator_ignition_bridge
 - large sitl_target.cmake split by simulation option and in some cases pushed to appropriate modules
 - sitl targets broken down to what's actually available (eg jmavsim only has 1 model and 1 world)
 - new Gazebo consistently referred to as Ignition for now (probably the least confusing thing until we fully drop Gazebo classic support someday)
2022-08-25 09:10:03 -04:00
David Sidrane 6b2509cbba px4_fmu-v6c Move I2C 4 to External 2022-08-25 08:46:51 -04:00
FARHANG 8b4df8ceb2 airframes: re-add Holybro X500v2 with dynamic control allocation 2022-08-25 07:52:18 +02:00
Jukka Laitinen f8f1213841 board_adc: Small fix for printf formatter
Print sizeof type with %zu to be compatible with 64 bit targets, where it is unsigned long

Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2022-08-25 07:50:23 +02:00
bresch 0061ef8b89 [AUTO COMMIT] update change indication 2022-08-24 09:16:11 -04:00
bresch 090d03eea2 ekf2: publish GNSS, rng and EV height biases 2022-08-24 09:16:11 -04:00
bresch a2a29ba0dd ekf2: verify parameter configuration for height sources 2022-08-24 09:16:11 -04:00
bresch 8dd5d0d1a3 ekf2: don't reset height when in conditional range aiding 2022-08-24 09:16:11 -04:00
bresch 20cd599bb7 ekf2: fix param migration 2022-08-24 09:16:11 -04:00
bresch 2d39097f60 ekf2: move rng height to file 2022-08-24 09:16:11 -04:00
bresch 28b4cd0579 ekf2: move GNSS hgt control to file 2022-08-24 09:16:11 -04:00
bresch b6f76b5eaa ekf2: move ev control to file 2022-08-24 09:16:11 -04:00
bresch f555281c94 ekf2: move height control-related function to file 2022-08-24 09:16:11 -04:00
bresch d87feee5b0 ekf2: move baro control logic to file 2022-08-24 09:16:11 -04:00
bresch 12e25eba62 ekf2: add common height fusion timeout parameter 2022-08-24 09:16:11 -04:00
bresch 52f726c5b7 ekf2: in bias estimator, use psd instead of var for prediction
PSD is independent from the sampling time while variance isn't
2022-08-24 09:16:11 -04:00
bresch b04d61c411 ekf2: param migration for rng aid, aid mask (gps) and hgt mode 2022-08-24 09:16:11 -04:00
bresch 3fb218600a ekf2_test: add multi height source unit tests 2022-08-24 09:16:11 -04:00
bresch aba2eac0df ekf2: publish GNSS, rng and EV height biases 2022-08-24 09:16:11 -04:00
bresch 6833c7e311 ekf2: adjust ekf2 aid parameters in configs 2022-08-24 09:16:11 -04:00
bresch 8962cf2d25 ekf2: GPS, baro and range finder control parameters
Also remove the legacy "range aid" than can be achieved by setting the
height reference to range finder and the range finder control parameter
to "conditional".

Conditional range aiding cal also be set when the height reference isn't
the range finder. This prevents the ratchetting effect due to switching
between references.
2022-08-24 09:16:11 -04:00
bresch 578e1339ca ekf2: re-implement range aid
range aid simply forces the range finder to be the height reference when
starting
2022-08-24 09:16:11 -04:00
bresch 88ac5ea210 ekf2_test: add test case for accel clipping handling 2022-08-24 09:16:11 -04:00
bresch 375753eba8 ekf2_test: add inertial nav falling detection tests 2022-08-24 09:16:11 -04:00
bresch 66ce1a002b ekf2_test: rename VisionHeight -> ExternalVisionHeight 2022-08-24 09:16:11 -04:00
bresch 82ec7a495a ekf2: refactor inertial nav falling check 2022-08-24 09:16:11 -04:00
bresch f9188b2a14 ekf2: refactor vertical acceleration check for multiple height sources 2022-08-24 09:16:11 -04:00
bresch 8fd79688c0 ekf2: enable multiple height sources fusion
Instead of having a single height source fused into the EKF and the
other ones "waiting" for a failure or the primary sensor, fuse all
sources in EKF2 at the same time. To prevent the sources from fighting against each
other, the "primary" source is set as reference and the other ones are
running a bias estimator in order to make all the secondary height
sources converge to the primary one.

If the reference isn't available, another one is automatically selected
from a priority list. This secondary reference keeps its current bias
estimate but stops updating it in order to be the new reference as close
as possible to the primary one.
2022-08-24 09:16:11 -04:00
bresch f5f31006a0 Ekf2: create HeightBiasEstimator class
Contains some logic common to all height bias estimators
2022-08-24 09:16:11 -04:00
JacobCrabill 57125a4c8f cyphal: Fix FMUv5 config; throw error if no CAN driver exists 2022-08-23 21:24:24 -04:00
huiyulhy c81efd0174 Fix velocity smoothing functional test 2022-08-23 21:11:35 -04:00
Beat Küng 7b810bb776 boards: update px4 io binary 2022-08-23 21:07:18 -04:00
Beat Küng b260df711c Makefile: force serial build for px4io_update 2022-08-23 21:07:18 -04:00
Beat Küng bae275898b rc/sbus: restart parser after sucessful decoding & increase time limit
Instead of directly passing the next packet to the parser after successful
parsing, switch the state to SBUS2_DECODE_STATE_SBUS_START and search for
the start byte again.

The timeout is increased as the IO main loop also takes a bit of time
(max ~0.7ms).

Tested on v5x with Futaba R7008SB (60Hz update rate) and FrSky X8R (111Hz
update rate).

Background:
When using the Futaba R7008SB, I noticed there's additional bytes added in
between packets. Often it's a null byte, but sometimes more. There's some
consistency but I did not find any documentation for it.
Sample data:
a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 34 00 0f 05 ec
1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 04 00 c0 8b
00 0f 04 ec 1f a8 fb 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00
14 00 0f 04 ec 1f a8 fb 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80
00 24 00 0f 05 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10
80 00 34 00 0f 05 ec 1f 30 60 bf 1c bd 07 16 5b 81 05 d4 a0 06 20 00 01 08
40 00 02 10 80 00 34 00 0f 07 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01
08 40 00 02 10 80 00 04 00 03 c0 31 00 0f 05 fc 1f a8 fb 07 16 5b 81 05 d4
a0 06 20 00 01 08 40 00 02 10 80 00 14 00 0f 05 fc 1f a8 fb 07 16 5b 81 05
d4 a0 06 20 00 01 08 40 00 02 10 80 00 24 00 0f 04 ec 1f a8 fd 07 16 5b 81
05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 34 00 0f 04 ec 1f a8 fd 07 16 5b
81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 04 00 03 c4 00 00 0f 04 ec 1f
a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 14 00 0f 04 ec
1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 24 00 0f 04
ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 34 00 0f
05 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 04 00
03 c0 31 00 0f 05 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02
10 80 00 14 00 0f 05 fc 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00
02 10 80 00 24 00 0f 05 fc 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40
00 02 10 80 00 34 00 0f 05 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08
40 00 0f 05 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80
00 04 00 03 c0 31 00 0f 05 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08
40 00 02 10 80 00 14 00 0f 05 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01
08 40 00 02 10 80 00 24 00 0f 05 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00
01 08 40 00 02 10 80 00 34 00 0f 05 f4 1f a8 fb 07 16 5b 81 05 d4 a0 06 20
00 01 08 40 00 02 10 80 00 04 00 03 c4 00 00 b0 60 7f 1c bd 07 16 5b 81 05
d4 a0 06 20 00 01 08 40 00 02 10 80 00 14 00 0f 05 ec 1f a8 fd 07 16 5b 81
05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 24 00 0f 05 ec 1f a8 fd 07 16 5b
81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 34 00 0f 05 ec 1f a8 fb 07 16
5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 04 00 03 c0 31 00 b0 60 bf
1c bd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 14 00 0f 04 f4
1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 24 00 30 70
7f 1c bd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 34 00 0f 05
f4 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10 80 00 04 00 03
c4 00 00 0f 05 fc 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01 08 40 00 02 10
80 00 14 00 0f 05 ec 1f b0 60 bf 1c bd 07 16 5b 81 05 d4 a0 06 20 00 01 08
40 00 02 10 80 00 14 00 0f 05 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00 01
08 40 00 02 10 80 00 24 00 0f 05 ec 1f a8 fd 07 16 5b 81 05 d4 a0 06 20 00

This was causing the parser to skip entire packets resulting in an update
rate of ~31Hz on the FMU side.
With this patch the update rate increases to 42-48Hz.

The investigation was triggered by an RC glitch with a packet containing
random channel data. It's likely, although not completely verified that
the frequent desync randomly happend to pass the CRC check with garbage
data.
2022-08-23 21:07:18 -04:00
Daniel Agar b58f70726f ekf2: scale delta angle and delta velocity bias to particular IMU sample 2022-08-23 21:06:13 -04:00
Ville Juven 213d5dac2a platforms/nuttx: Fix hard coded path for karch library
Use CONFIG_ARCH instead of arm
2022-08-23 21:05:41 -04:00
Ville Juven 4f6d523c95 mixer_module: Fix linking of mixer_module
The module has a hard dependency on mixer library, so link them together
2022-08-23 21:04:58 -04:00
bresch f89044cfbe ekf2: fix replay EKF2 start when CONSTRAINED_FLASH 2022-08-23 11:14:15 -04:00
modaltb 40149ecabc boards: modalai_fc-v2 configure SPI6, disable unused SPI3/4 (#20093) 2022-08-22 20:58:44 -04:00
alexklimaj 913bae9924 Revert "drivers/uavcan: update libuavcan"
This reverts commit deb938fcea.
2022-08-22 20:57:06 -04:00
Daniel Agar cfc579542e new Ignition Gazebo simulation interface architecture (#20057)
- much simpler direct interface using Ignition Transport 
 - in tree models and worlds
 - control allocation output configuration, no more magic actuator mapping to mavlink and back
 - currently requires no custom Gazebo plugins (keeping things as lightweight and simple as possible)

Co-authored-by: Jaeyoung-Lim <jalim@ethz.ch>
2022-08-22 10:58:19 -04:00
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 70d7070307 ROMFS: plane airframe: make tuning tighter
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
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
Thomas Debrunner 44a18acd51 Fix race condition in px4io serial driver (#20005)
* px4io: prevent memory corruption on corrput io data

* px4io_serial: Prevent race between handling wait timeout case and interrupt posting semaphore
2022-08-18 17:46:47 +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
bresch 021b23826d wind_replay: allow estimated local vel and GNSS vel sources
local vel by default, set --gnss to use GNSS vel instead
2022-08-18 14:09:23 +02:00
bresch be6acb0a68 wind_est: add python script to replay wind estimator equations 2022-08-18 14:09:23 +02:00
bresch 4d21c90cbb wind_est: generate wind estimator equations for python use 2022-08-18 14:09:23 +02:00
Kalyan Sriram deb938fcea drivers/uavcan: update libuavcan 2022-08-16 11:05:51 -04:00
Daniel Agar 1c72f86761 Update src/drivers/imu/analog_devices/adis16470/ADIS16470.cpp
Co-authored-by: Kabir Mohammed  <kabir@corvus-robotics.com>
2022-08-16 08:40:43 -04:00
Daniel Agar 49d87f1907 adis16470: fix accel and gyro scaling 2022-08-16 08:40:43 -04:00
bresch 616b5689ba Python: move symforce to optional requirements
symforce requires python 3.8 which isn't available by default on ubuntu
18.04.
2022-08-15 21:14:07 -04:00
Silvan Fuhrer a7a8daaf4d ROMFS: tiltrotor sitl config: some small tuning improvements in hover
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-08-16 02:48:44 +02:00
Silvan Fuhrer 771dbf9395 ROMFS: tiltrotor sitl config: adapt CA params to new output indexes
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-08-16 02:48:44 +02:00
Silvan Fuhrer 09f83016c9 update sitl_gazebo (tiltrotor index fixes)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-08-16 02:48:44 +02:00
Junwoo Hwang d7a962b426 mavlink: fix PX4_DEBUG message formats 2022-08-12 09:43:12 +02:00
Junwoo Hwang 0c218e6628 atl/mantis-edu: enable mavlink ftp 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 f454dcef6b ROMFS: set control allocation parameters for airframes
Removes some airframes:
- 1000_rc_fw_easystar.hil
- 10015_tbs_discovery
- 10016_3dr_iris
- 10018_tbs_endurance
- 13001_caipirinha_vtol
- 13002_firefly6
- 13003_quad_tailsitter
- 13004_quad+_tailsitter
- 13005_vtol_AAERT_quad
- 13006_vtol_standard_delta
- 13007_vtol_AAVVT_quad
- 13008_QuadRanger
- 13009_vtol_spt_ranger
- 13012_convergence
- 13050_generic_vtol_octo
- 14001_tri_y_yaw+
- 14002_tri_y_yaw-
- 15001_coax_heli
- 2105_maja
- 2200_mini_talon
- 3031_phantom
- 3032_skywalker_x5
- 3033_wingwing
- 3036_pigeon
- 3100_tbs_caipirinha
- 4003_qavr5
- 4009_qav250
- 4019_x500_v2
- 4030_3dr_solo
- 4031_3dr_quad
- 4051_s250aq
- 4072_draco
- 4080_zmr250
- 4090_nanomind
- 4100_tiltquadrotor
- 50003_aion_robotics_r1_rover
2022-08-12 09:43:12 +02:00
Beat Küng 4d60fadc05 ROMFS: set control allocation parameters for sitl airframes
Removes some airframes:
- if750a
- solo
- iris_ctrlalloc
- typhoon_h480_ctrlalloc
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
Beat Küng 720cf5a485 config: enable dynamic control allocation by default (SYS_CTRL_ALLOC=1) 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
David Sidrane cd971948da NuttX Backport critical F7 Ethernet issues 2022-08-12 08:22:55 +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 7f2fea1cca mpu9250: try all I2C addresses if not manually specified 2022-08-09 13:06:40 -04:00
Jaeyoung Lim d4b77a6172 Update sitl gazebo submodule 2022-08-09 16:35:27 +02:00
Jaeyoung Lim ea5b1be2d4 Disable rear motors tilt for tiltrotor SITL airframe
This commit disables the rear motor tilt on the tiltrotor SITL airframe
2022-08-09 16:35:27 +02:00
Jukka Laitinen c7aaf52fd4 Double the allocated stack size of 64-bit NuttX built-in modules
Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
2022-08-09 08:08:54 +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
bresch d9d127a237 lightware dist sensor: set min range based on datasheet 2022-08-08 19:32:44 -04:00
Daniel Agar 0bce1ef573 drivers/imu: new TDK IIM-42652 IMU support 2022-08-08 13:51:39 -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
Beat Küng 3e68870547 gtest: update to version 1.12.1
Fixes the error
googletest-src/googletest/src/gtest-death-test.cc:1283:24: error: ‘dummy’ may be used uninitialized [-Werror=maybe-uninitialized]
with GCC 11
2022-08-08 07:43:42 +02:00
Daniel Agar bce4237963 move ekf2 Matrix helper utilities to mathlib 2022-08-05 09:58:07 -04:00
Silvan Fuhrer 6ebc88fed7 ROMFS: vtol_defaults: reduce aggressiveness around roll and yaw axis
For most VTOLs the param defaults for the agressiveness of the MC attitude controller
are too high, as VTOLs usually have high intertia and lot af drag due to wings and
can thus not rotate as fast as MCs.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-08-05 14:11:59 +02: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
Silvan Fuhrer c42667ac64 ROMFS: vtol_defaults: remvoe custom NAV_ACC_RAD, leave at param default (10)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-08-05 14:11:59 +02:00
Silvan Fuhrer 4614c1a0b4 ROMFS: vtol_defaults: increase default hover speeds
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-08-05 14:11:59 +02:00
Silvan Fuhrer 0d10491b89 ROMFS: vtol_defaults: remove MPC_TKO_SPEED from VTOL defaults
The VTOL default was set to 1, while the param default is 1.5.
I don't see why it shuold be a different default for VTOLs and thus remove it.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-08-05 14:11:59 +02:00
Matthias Grob 87cbda1992 FlightTaskOrbit: parameterize hardcoded maximum radius (#20012) 2022-08-05 09:19:32 +02:00
Daniel Agar dfdfbbfa9c msg/vehicle_odometry.msg: simplify covariance handling and update all usage (#19966)
- replace float32[21] URT covariances with smaller dedicated position/velocity/orientation variances (the crossterms are unused, awkward, and relatively costly)
 - these are easier to casually inspect and more representative of what's actually being used currently and reduces the size of vehicle_odometry_s quite a bit
 - ekf2: add new helper to get roll/pitch/yaw covariances
 - mavlink: receiver ODOMETRY handle more frame types for both pose (MAV_FRAME_LOCAL_NED, MAV_FRAME_LOCAL_ENU, MAV_FRAME_LOCAL_FRD, MAV_FRAME_LOCAL_FLU) and velocity (MAV_FRAME_LOCAL_NED, MAV_FRAME_LOCAL_ENU, MAV_FRAME_LOCAL_FRD, MAV_FRAME_LOCAL_FLU, MAV_FRAME_BODY_FRD)
 - mavlink: delete unused ATT_POS_MOCAP stream (this is just a passthrough)

Co-authored-by: Mathieu Bresciani <brescianimathieu@gmail.com>
2022-08-04 12:55:21 -04:00
bresch 61f390b0dd ekf2_test: fix height offset compensation after origin reset 2022-08-04 16:50:31 +02:00
bresch e34de53e2e ekf2_test: let the GPS start before setting the new origin
fix test by reducing the distance to the new origin: the maximum size of
the local position origin is a cube of 1e6m. If the origin is moved
further than this, the state is clipped to that maximum value
2022-08-04 16:50:31 +02:00
Silvan Fuhrer 55f395a7e9 FlightTaskAuto: apply cruise speed from position triplet also when negative (#20006)
Navigator sets the cruise_speed to -1 if the controller shouldn't listen to
it and instead use the default speed (for MC: MPC_XY_CRUISE). This is for
example for RTL the case, where we want to return at the default speed,
independetly of what the mission speed before was.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-08-04 13:36:15 +02:00
FARHANG 2498cbbb74 boards: px4_fmu-v6c rc.board_defaults remove irrelevant ethernet configuration 2022-08-03 11:13:12 -04:00
Tony Cake f321117568 GHST: Add support for GPS Telemetry (#19953)
Add support for the basic GPS telemetry values when using the GHST protocol.

* Fix formatting in GHST GPS telemetry changes

* GHST GPS Telemetry formatting cleanup

* GHST GPS Telemetry, Last formatting change
2022-08-03 10:44:21 +02:00
Hamish Willee 270c456121 CI - build on main as well (#20001) 2022-08-02 16:52:17 -07:00
Roman Bapst dbf7d32e07 Skip VTOL_TAKEOFF mission item when in fixed wing mode (#19985)
* mission: skip VTOL_TAKEOFF mission item when in fixed wing mode

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

* mission: added better comment regarding skipping VTOL Takeoff in fw mode

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-08-02 15:34:42 +02:00
RomanBapst f11f2e9797 addressed review comments
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-08-02 15:29:25 +02:00
RomanBapst a425bc4c92 vehicle_local_position: fixed comment
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-08-02 15:29:25 +02:00
RomanBapst fbd4534edc WindEstimator: reworked filter initialisation
- separate initialisation with and without airspeed

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-08-02 15:29:25 +02:00
RomanBapst a63f1b71fe wind_estimator: added simple check for validity of synthetic airspeed
- synthetic airspeed will only be declared valid as soon as the wind variance
has dropped below a parameterized threshold. This is useful for vehicles without
an airspeed sensor which rely on synthetic airspeed but only once the vehicle
has turned sufficiently for the wind estimates to be reliable.

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2022-08-02 15:29:25 +02:00
Hamish Willee a715b5468e mc_wind_estimator - improve readability (#19545) 2022-08-02 09:26:06 +02:00
Hamish Willee 30e2490d5b Docs are now in user guide and main (#19977)
* Fix links to docs in source to point to docs on main not master

* More docs and scripts that need to point to main
2022-08-01 11:39:39 +10:00
Peter van der Perk c566fb414b S32K1XX add dummy iwdg driver 2022-07-31 11:21:41 -04:00
Beat Küng e7588d2da0 px4io+pwm_out: set the PWM rate and disarmed value when a channel is first set to a servo
This should simplify the first setup a bit.
2022-07-31 11:20:57 -04:00
Igor Mišić f929017618 boards: link missing arch_io_pins lib 2022-07-31 11:19:20 -04:00
Daniel Agar 41d9c3dd2a ekf2: add AUX velocity aid src status
- also includes velocity and position helpers for using estimator aid
   source status messages that will later be used for GPS, EV, etc
2022-07-29 12:02:31 -04:00
Daniel Agar a397c09e59 ekf2: use estimator_aid_src for all yaw sources (mag, gnss, ev) 2022-07-29 11:20:48 -04:00
Agata Barcis d5d88cba5b generate_microRTPS_bridge.py updated to support ROS2 humble
Signed-off-by: Agata Barcis <agata.barcis@tii.ae>
2022-07-29 15:21:05 +02:00
Silvan Fuhrer 638eff426a AirspeedValidator: increase max update step size of tas_scale_validated from 1% to 5%
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2022-07-29 09:29:27 +02:00
2867 changed files with 153755 additions and 77890 deletions
+7 -11
View File
@@ -9,10 +9,10 @@ pipeline {
script {
def build_nodes = [:]
def docker_images = [
armhf: "px4io/px4-dev-armhf:2021-09-08",
arm64: "px4io/px4-dev-aarch64:2021-09-08",
base: "px4io/px4-dev-base-bionic:2021-09-08",
nuttx: "px4io/px4-dev-nuttx-focal:2021-09-08",
armhf: "px4io/px4-dev-armhf:2022-08-12",
arm64: "px4io/px4-dev-aarch64:2022-08-12",
base: "px4io/px4-dev-ros2-foxy:2022-08-12",
nuttx: "px4io/px4-dev-nuttx-focal:2022-08-12",
]
def armhf_builds = [
@@ -42,6 +42,8 @@ pipeline {
"ark_can-gps_default",
"ark_can-rtk-gps_canbootloader",
"ark_can-rtk-gps_default",
"ark_fmu-v6x_bootloader",
"ark_fmu-v6x_default",
"atl_mantis-edu_default",
"av_x-v1_default",
"bitcraze_crazyflie_default",
@@ -67,23 +69,18 @@ pipeline {
"matek_h743-slim_default",
"matek_h743_default",
"modalai_fc-v1_default",
"modalai_fc-v1_rtps",
"modalai_fc-v2_default",
"modalai_voxl2-io_default",
"mro_ctrl-zero-f7_default",
"mro_ctrl-zero-f7-oem_default",
"mro_ctrl-zero-h7-oem_default",
"mro_ctrl-zero-h7-oem_rtps",
"mro_ctrl-zero-h7_default",
"mro_ctrl-zero-h7_rtps",
"mro_pixracerpro_default",
"mro_pixracerpro_rtps",
"mro_x21-777_default",
"mro_x21_default",
"nxp_fmuk66-e_default",
"nxp_fmuk66-e_rtps",
"nxp_fmuk66-e_socketcan",
"nxp_fmuk66-v3_default",
"nxp_fmuk66-v3_rtps",
"nxp_fmuk66-v3_socketcan",
"nxp_fmurt1062-v1_default",
"nxp_ucans32k146_canbootloader",
@@ -101,7 +98,6 @@ pipeline {
"px4_fmu-v5_debug",
"px4_fmu-v5_default",
"px4_fmu-v5_lto",
"px4_fmu-v5_rtps",
"px4_fmu-v5_stackcheck",
"px4_fmu-v5_uavcanv0periph",
"px4_fmu-v5x_default",
+36 -91
View File
@@ -61,9 +61,13 @@ pipeline {
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "IMU_GYRO_RATEMAX" --value "2000"'
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_AUTOSTART" --value "13000"' // generic vtol standard
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_BL_UPDATE" --value "1"' // update bootloader
sh './Tools/HIL/reboot.py --device `find /dev/serial -name *usb-*`' // reboot to apply
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger on"' // run logger
checkStatus()
quickCalibrate()
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "px4io status"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger off"' // stop logger
}
}
stage("print topics") {
@@ -132,8 +136,12 @@ pipeline {
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "IMU_GYRO_RATEMAX" --value "2000"'
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_AUTOSTART" --value "13000"' // generic vtol standard
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_BL_UPDATE" --value "1"' // update bootloader
sh './Tools/HIL/reboot.py --device `find /dev/serial -name *usb-*`' // reboot to apply
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger on"' // run logger
checkStatus()
quickCalibrate()
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger off"' // stop logger
}
}
stage("print topics") {
@@ -152,76 +160,6 @@ pipeline {
}
}
stage("px4_fmu-v3_test") {
stages {
stage("build px4_fmu-v3_test") {
agent {
docker {
image 'px4io/px4-dev-nuttx-focal:2021-09-08'
args '--cpu-shares 512 -e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
checkoutSCM()
sh 'make px4_fmu-v3_test'
sh 'make px4_fmu-v3_test bootloader_elf'
sh 'ccache -s'
stash includes: 'build/*/*.elf, platforms/nuttx/Debug/*, platforms/nuttx/NuttX/nuttx/tools/nuttx-gdbinit, Tools/HIL/*', name: 'px4_fmu-v3_test'
}
post {
always {
sh 'make distclean; git clean -ff -x -d .'
}
}
} // stage build
stage("hardware") {
agent {
label 'px4_fmu-v3'
}
stages {
stage("flash") {
steps {
sh 'export'
sh 'find /dev/serial'
unstash 'px4_fmu-v3_test'
sh './platforms/nuttx/Debug/upload_jlink_gdb.sh build/px4_fmu-v3_test/px4_fmu-v3_bootloader.elf'
// flash board and watch bootup
sh './platforms/nuttx/Debug/upload_jlink_gdb.sh build/px4_fmu-v3_test/px4_fmu-v3_test.elf && ./Tools/HIL/monitor_firmware_upload.py --device `find /dev/serial -name *usb-*` --baudrate 57600'
resetBoard()
}
}
stage("tests") {
steps {
runTests()
}
}
stage("status") {
steps {
// configure
resetParameters()
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_AUTOSTART" --value "13000"' // generic vtol standard
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_BL_UPDATE" --value "1"' // update bootloader
checkStatus()
quickCalibrate()
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "px4io status"'
}
}
stage("print topics") {
steps {
printTopics()
}
}
}
post {
always {
sh 'cat /tmp/pyserial_spy_file.txt || true'
sh './platforms/nuttx/Debug/jlink_gdb_backtrace_simple.sh build/px4_fmu-v3_test/px4_fmu-v3_test.elf || true'
}
}
} // stage test
}
}
stage("px4_fmu-v4_test") {
stages {
stage("build px4_fmu-v4_test") {
@@ -271,8 +209,12 @@ pipeline {
resetParameters()
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_AUTOSTART" --value "4001"' // generic quadcopter
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_BL_UPDATE" --value "1"' // update bootloader
sh './Tools/HIL/reboot.py --device `find /dev/serial -name *usb-*`' // reboot to apply
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger on"' // run logger
checkStatus()
quickCalibrate()
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger off"' // stop logger
}
}
stage("print topics") {
@@ -340,9 +282,13 @@ pipeline {
resetParameters()
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_AUTOSTART" --value "13000"' // generic vtol standard
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_BL_UPDATE" --value "1"' // update bootloader
sh './Tools/HIL/reboot.py --device `find /dev/serial -name *usb-*`' // reboot to apply
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger on"' // run logger
checkStatus()
quickCalibrate()
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "px4io status"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger off"' // stop logger
}
}
stage("print topics") {
@@ -431,6 +377,7 @@ pipeline {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param set IMU_GYRO_RATEMAX 200" || true' // limit cpu usage
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param set MAV_0_CONFIG 0" || true' // limit cpu usage
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param set MAV_1_CONFIG 0" || true' // limit cpu usage
sh './Tools/HIL/reboot.py --device `find /dev/serial -name *usb-*`' // reboot to apply
checkStatus()
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "px4io status" || true'
}
@@ -513,6 +460,7 @@ pipeline {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param set IMU_GYRO_RATEMAX 200" || true' // limit cpu usage
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param set MAV_0_CONFIG 0" || true' // limit cpu usage
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param set MAV_1_CONFIG 0" || true' // limit cpu usage
sh './Tools/HIL/reboot.py --device `find /dev/serial -name *usb-*`' // reboot to apply
checkStatus()
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "px4io status" || true'
}
@@ -582,9 +530,13 @@ pipeline {
resetParameters()
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_AUTOSTART" --value "4001"' // generic quadcopter
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_BL_UPDATE" --value "1"' // update bootloader
sh './Tools/HIL/reboot.py --device `find /dev/serial -name *usb-*`' // reboot to apply
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger on"' // run logger
checkStatus()
quickCalibrate()
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "px4io status" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger off"' // stop logger
}
}
stage("print topics") {
@@ -653,8 +605,12 @@ pipeline {
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "IMU_GYRO_RATEMAX" --value "400"'
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_AUTOSTART" --value "4001"' // generic quadcopter
sh './Tools/HIL/nsh_param_set.py --device `find /dev/serial -name *usb-*` --name "SYS_BL_UPDATE" --value "1"' // update bootloader
sh './Tools/HIL/reboot.py --device `find /dev/serial -name *usb-*`' // reboot to apply
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger on"' // run logger
checkStatus()
quickCalibrate()
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger off"' // stop logger
}
}
stage("print topics") {
@@ -728,14 +684,8 @@ void checkStatus() {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param save"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param status"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param show SYS*"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param dump"'
sh './Tools/HIL/reboot.py --device `find /dev/serial -name *usb-*`' // reboot to apply
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param show SYS*"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param dump"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "bsondump /fs/mtd_params"'
// run logger
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger on"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "sleep 1"' // sleep before continuing
// status commands
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "cat /proc/fs/blocks"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "cat /proc/fs/mount"'
@@ -765,14 +715,12 @@ void checkStatus() {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "mavlink status" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "mount"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "mtd status"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param dump"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "bsondump /fs/mtd_params"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param show" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param status"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "perf latency"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "perf"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "ps"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "pwm info -d /dev/pwm_output0"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "pwm info -d /dev/pwm_output1" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "pwm_out status"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "sensors status"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "top once"'
@@ -781,8 +729,6 @@ void checkStatus() {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "uorb top -1 -a" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "ver all"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "work_queue status"'
// stop logger
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "logger off"'
}
void resetParameters() {
@@ -794,7 +740,7 @@ void resetParameters() {
void runTests() {
// test loading a range of airframes
sh './Tools/HIL/test_airframes.sh `find /dev/serial -name *usb-*` 2100 3000 4001 6001 8001 10016'
sh './Tools/HIL/test_airframes.sh `find /dev/serial -name *usb-*` 2100 3000 4001 6001 8001'
resetParameters()
@@ -809,9 +755,11 @@ void runTests() {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "top once"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "work_queue status"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "sensors stop"' // ignore irrelevant sensor timeouts during test
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "ostest"'
sh './Tools/HIL/reboot.py --device `find /dev/serial -name *usb-*`' // reboot after ostest
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "sensors stop"' // ignore irrelevant sensor timeouts during test
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "commander_tests" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "controllib_test"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "lightware_laser_test"'
@@ -821,13 +769,13 @@ void runTests() {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "tests file" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param dump /fs/mtd_params"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "bsondump /fs/mtd_params"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "mtd readtest"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param dump /fs/mtd_params"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "bsondump /fs/mtd_params"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "mtd rwtest"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param dump /fs/mtd_params"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "bsondump /fs/mtd_params"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "mtd erase"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "param dump /fs/mtd_params"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "bsondump /fs/mtd_params" || true' // expected to fail after erase
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "sd_bench"'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "sd_bench -v"'
@@ -857,7 +805,6 @@ void printTopics() {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener actuator_controls_0" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener actuator_controls_1" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener actuator_controls_2" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener actuator_controls_3" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener actuator_outputs" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener adc_report" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener airspeed_validated" || true'
@@ -919,12 +866,10 @@ void printTopics() {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener system_power" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener task_stack_info" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener telemetry_status" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener test_motor" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener trajectory_setpoint" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener tune_control" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vehicle_acceleration" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vehicle_air_data" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vehicle_angular_acceleration" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vehicle_angular_velocity" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vehicle_attitude" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vehicle_attitude_setpoint" || true'
@@ -941,7 +886,7 @@ void printTopics() {
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vehicle_odometry" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vehicle_rates_setpoint" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vehicle_status" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vehicle_status_flags" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener failsafe_flags" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener vtol_vehicle_status" || true'
sh './Tools/HIL/run_nsh_cmd.py --device `find /dev/serial -name *usb-*` --cmd "listener yaw_estimator_status" || true'
}
+1 -2
View File
@@ -19,9 +19,8 @@
*.jar binary
*.xml text eol=lf
# PX4 mixers, msgs, etc
# PX4 msgs, etc
*.bin binary
*.mix text eol=lf
*.msg text eol=lf
*.config text eol=lf
*.sdf text eol=lf
+1 -1
View File
@@ -20,7 +20,7 @@ A clear and concise description of what you expected to happen.
## Log Files and Screenshots
*Always* provide a link to the flight log file:
- Download the flight log file from the vehicle ([tutorial](https://docs.px4.io/master/en/getting_started/flight_reporting.html)).
- Download the flight log file from the vehicle ([tutorial](https://docs.px4.io/main/en/getting_started/flight_reporting.html)).
- Upload the log to the [PX4 Flight Review](http://logs.px4.io/)
- Share the link to the log (Copy and paste the URL of the log)
+1 -1
View File
@@ -5,7 +5,7 @@ labels: feature-request
---
For general questions please use [PX4 Discuss](http://discuss.px4.io/) or Slack (you can find an invite link on this project README).
For general questions please use [PX4 Discuss](http://discuss.px4.io/) or Discord (you can find an invite link on this project README).
## Describe problem solved by the proposed feature
A clear and concise description of the problem, if any, this feature will solve. E.g. I'm always frustrated when ...
+24 -12
View File
@@ -1,17 +1,29 @@
Please use [PX4 Discuss](http://discuss.px4.io/) or [Slack](http://slack.px4.io/) to align on pull requests if necessary. You can then open draft pull requests to get early feedback.
<!--
## Describe problem solved by this pull request
A clear and concise description of the problem this proposed change will solve. Or, what it will improve.
E.g. For this use case I ran into...
Thank you for your contribution!
## Describe your solution
A clear and concise description of what you have implemented.
Get early feedback through
- Dronecode Discord: https://discord.gg/dronecode
- PX4 Discuss: http://discuss.px4.io/
- opening a draft pr and sharing the link
## Describe possible alternatives
A clear and concise description of alternative solutions or features you've considered.
-->
## Test data / coverage
How was it tested? What cases were covered? Logs uploaded to https://review.px4.io/ and screenshots of the important plot parts.
### Solved Problem
When ... I found that ...
## Additional context
Add any other related context or media.
Fixes #{Github issue ID}
### Solution
- Add ... for ...
- Refactor ...
### Alternatives
We could also ...
### Test coverage
- Unit/integration test: ...
- Simulation/hardware testing logs: https://review.px4.io/
### Context
Related links, screenshot before/after, video
+1 -2
View File
@@ -3,7 +3,7 @@ name: Checks
on:
push:
branches:
- 'master'
- 'main'
pull_request:
branches:
- '*'
@@ -23,7 +23,6 @@ jobs:
"shellcheck_all",
"NO_NINJA_BUILD=1 px4_fmu-v5_default",
"NO_NINJA_BUILD=1 px4_sitl_default",
"BUILD_MICRORTPS_AGENT=1 px4_sitl_rtps",
"airframe_metadata",
"module_documentation",
"parameters_metadata",
+1 -1
View File
@@ -3,7 +3,7 @@ name: Clang Tidy
on:
push:
branches:
- 'master'
- 'main'
pull_request:
branches:
- '*'
+1 -1
View File
@@ -3,7 +3,7 @@ name: Linux Targets
on:
push:
branches:
- 'master'
- 'main'
pull_request:
branches:
- '*'
+1 -1
View File
@@ -3,7 +3,7 @@ name: Linux ARM64 Targets
on:
push:
branches:
- 'master'
- 'main'
pull_request:
branches:
- '*'
+1 -1
View File
@@ -3,7 +3,7 @@ name: MacOS build
on:
push:
branches:
- 'master'
- 'main'
pull_request:
branches:
- '*'
+3 -1
View File
@@ -3,7 +3,7 @@ name: Nuttx Targets
on:
push:
branches:
- 'master'
- 'main'
pull_request:
branches:
- '*'
@@ -21,6 +21,7 @@ jobs:
ark_can-gps,
ark_can-rtk-gps,
ark_cannode,
ark_fmu-v6x,
atl_mantis-edu,
av_x-v1,
bitcraze_crazyflie,
@@ -53,6 +54,7 @@ jobs:
nxp_fmuk66-e,
nxp_fmuk66-v3,
nxp_fmurt1062-v1,
nxp_mr-canhubk3,
nxp_ucans32k146,
omnibus_f4sd,
px4_fmu-v2,
+1 -1
View File
@@ -3,7 +3,7 @@ name: Deploy metadata for all targets
on:
push:
branches:
- 'master'
- 'main'
- 'release/*'
- 'pr-metadata-test'
+44
View File
@@ -0,0 +1,44 @@
name: Failsafe Simulator Build
on:
push:
branches:
- 'main'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
defaults:
run:
shell: bash
strategy:
fail-fast: false
matrix:
check: [
"failsafe_web",
]
container:
image: px4io/px4-dev-nuttx-focal:2021-09-08
options: --privileged --ulimit core=-1 --security-opt seccomp=unconfined
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: check environment
run: |
export
ulimit -a
- name: install emscripten
run: |
git clone https://github.com/emscripten-core/emsdk.git _emscripten_sdk
cd _emscripten_sdk
./emsdk install latest
./emsdk activate latest
- name: ${{matrix.check}}
run: |
. ./_emscripten_sdk/emsdk_env.sh
make ${{matrix.check}}
+3 -3
View File
@@ -3,7 +3,7 @@ name: MAVROS Mission Tests
on:
push:
branches:
- 'master'
- 'main'
pull_request:
branches:
- '*'
@@ -59,13 +59,13 @@ jobs:
run: |
export
ulimit -a
- name: Build PX4 and sitl_gazebo
- name: Build PX4 and sitl_gazebo-classic
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: |
ccache -z
make px4_sitl_default
make px4_sitl_default sitl_gazebo
make px4_sitl_default sitl_gazebo-classic
ccache -s
- name: Core dump settings
+3 -3
View File
@@ -3,7 +3,7 @@ name: MAVROS Offboard Tests
on:
push:
branches:
- 'master'
- 'main'
pull_request:
branches:
- '*'
@@ -54,13 +54,13 @@ jobs:
run: |
export
ulimit -a
- name: Build PX4 and sitl_gazebo
- name: Build PX4 and sitl_gazebo-classic
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: |
ccache -z
make px4_sitl_default
make px4_sitl_default sitl_gazebo
make px4_sitl_default sitl_gazebo-classic
ccache -s
- name: Core dump settings
+5 -31
View File
@@ -3,7 +3,7 @@ name: Metadata
on:
push:
branches:
- 'master'
- 'main'
- 'release/*'
- 'pr-metadata-test'
@@ -116,7 +116,7 @@ jobs:
ls -ls *
# TODO: deploy graph_px4_sitl.json to S3 px4-travis:Firmware/master/
micrortps_agent:
ROS2_msgs:
runs-on: ubuntu-latest
container: px4io/px4-dev-base-focal:2021-09-08
steps:
@@ -124,34 +124,8 @@ jobs:
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: microRTPS agent
run: |
make px4_sitl_rtps
git clone https://github.com/PX4/micrortps_agent.git
cp -R build/px4_sitl_rtps/src/modules/micrortps_bridge/micrortps_agent/* micrortps_agent
ROS_msgs:
runs-on: ubuntu-latest
container: px4io/px4-dev-base-focal:2021-09-08
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: PX4 ROS msgs
- name: PX4 ROS2 msgs
run: |
git clone https://github.com/PX4/px4_msgs.git
python3 msg/tools/uorb_to_ros_msgs.py msg/ px4_msgs/msg/
ROS2_bridge:
runs-on: ubuntu-latest
container: px4io/px4-dev-base-focal:2021-09-08
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: PX4 ROS2 bridge
run: |
git clone https://github.com/PX4/px4_ros_com.git
./msg/tools/uorb_to_ros_urtps_topics.py -i msg/tools/urtps_bridge_topics.yaml -o px4_ros_com/templates/urtps_bridge_topics.yaml
rm px4_msgs/msg/*.msg
cp msg/*.msg px4_msgs/msg/
+1 -1
View File
@@ -3,7 +3,7 @@ name: Python CI Checks
on:
push:
branches:
- 'master'
- 'main'
pull_request:
branches:
- '*'
+5 -5
View File
@@ -3,7 +3,7 @@ name: SITL Tests
on:
push:
branches:
- 'master'
- 'main'
pull_request:
branches:
- '*'
@@ -16,7 +16,7 @@ jobs:
matrix:
config:
- {model: "iris", latitude: "59.617693", longitude: "-151.145316", altitude: "48", build_type: "RelWithDebInfo" } # Alaska
- {model: "standard_vtol", latitude: "-38.071235", longitude: "145.281220", altitude: "31", build_type: "AddressSanitizer" } # Australia
# - {model: "standard_vtol", latitude: "-38.071235", longitude: "145.281220", altitude: "31", build_type: "AddressSanitizer" } # Australia
- {model: "tailsitter" , latitude: "29.660316", longitude: "-82.316658", altitude: "30", build_type: "RelWithDebInfo" } # Florida
- {model: "standard_vtol", latitude: "47.397742", longitude: "8.545594", altitude: "488", build_type: "Coverage" } # Zurich
@@ -74,14 +74,14 @@ jobs:
- name: Build SITL Gazebo
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: make px4_sitl_default sitl_gazebo
- name: ccache post-run sitl_gazebo
run: make px4_sitl_default sitl_gazebo-classic
- name: ccache post-run sitl_gazebo-classic
run: ccache -s
- name: Build MAVSDK tests
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
DONT_RUN: 1
run: make px4_sitl_default gazebo mavsdk_tests
run: make px4_sitl_default sitl_gazebo-classic mavsdk_tests
- name: ccache post-run mavsdk_tests
run: ccache -s
-1
View File
@@ -93,7 +93,6 @@ rules.ninja
/googletest-*/
/logs
/mavsdk_tests
/test_mixer_multirotor
/unit-*
/uORB/
DartConfiguration.tcl
+16 -21
View File
@@ -6,35 +6,31 @@
path = src/drivers/uavcan/libuavcan
url = https://github.com/dronecan/libuavcan.git
branch = main
[submodule "Tools/jMAVSim"]
path = Tools/jMAVSim
[submodule "Tools/simulation/jmavsim/jMAVSim"]
path = Tools/simulation/jmavsim/jMAVSim
url = https://github.com/PX4/jMAVSim.git
branch = master
[submodule "Tools/sitl_gazebo"]
path = Tools/sitl_gazebo
url = https://github.com/PX4/PX4-SITL_gazebo.git
branch = master
branch = main
[submodule "Tools/simulation/gazebo-classic/sitl_gazebo-classic"]
path = Tools/simulation/gazebo-classic/sitl_gazebo-classic
url = https://github.com/PX4/PX4-SITL_gazebo-classic.git
branch = main
[submodule "src/drivers/gps/devices"]
path = src/drivers/gps/devices
url = https://github.com/PX4/PX4-GPSDrivers.git
branch = master
[submodule "src/modules/micrortps_bridge/micro-CDR"]
path = src/modules/micrortps_bridge/micro-CDR
url = https://github.com/PX4/Micro-CDR.git
branch = master
branch = main
[submodule "platforms/nuttx/NuttX/nuttx"]
path = platforms/nuttx/NuttX/nuttx
url = https://github.com/PX4/NuttX.git
branch = px4_firmware_nuttx-10.1.0+
branch = px4_firmware_nuttx-10.3.0+
[submodule "platforms/nuttx/NuttX/apps"]
path = platforms/nuttx/NuttX/apps
url = https://github.com/PX4/NuttX-apps.git
branch = px4_firmware_nuttx-10.1.0+
branch = px4_firmware_nuttx-10.3.0+
[submodule "Tools/flightgear_bridge"]
path = Tools/flightgear_bridge
path = Tools/simulation/flightgear/flightgear_bridge
url = https://github.com/PX4/PX4-FlightGear-Bridge.git
[submodule "Tools/jsbsim_bridge"]
path = Tools/jsbsim_bridge
[submodule "Tools/simulation/jsbsim/jsbsim_bridge"]
path = Tools/simulation/jsbsim/jsbsim_bridge
url = https://github.com/PX4/px4-jsbsim-bridge.git
[submodule "src/drivers/cyphal/libcanard"]
path = src/drivers/cyphal/libcanard
@@ -53,9 +49,7 @@
[submodule "src/lib/events/libevents"]
path = src/lib/events/libevents
url = https://github.com/mavlink/libevents.git
[submodule "Tools/simulation-ignition"]
path = Tools/simulation-ignition
url = https://github.com/PX4/px4-simulation-ignition.git
branch = main
[submodule "src/lib/crypto/libtomcrypt"]
path = src/lib/crypto/libtomcrypt
url = https://github.com/PX4/libtomcrypt.git
@@ -66,4 +60,5 @@
branch = px4
[submodule "src/modules/microdds_client/Micro-XRCE-DDS-Client"]
path = src/modules/microdds_client/Micro-XRCE-DDS-Client
url = https://github.com/eProsima/Micro-XRCE-DDS-Client.git
url = https://github.com/PX4/Micro-XRCE-DDS-Client.git
branch = px4
+1 -1
View File
@@ -11,7 +11,7 @@ matrix:
dist: xenial
# In order to stay under the coverity rate limit, we only run this weekly
# and not on push which is configured in travis-ci settings.
if: branch = master
if: branch = main
before_install:
- echo -n | openssl s_client -connect scan.coverity.com:443 | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' | sudo tee -a /etc/ssl/certs/ca-
+1
View File
@@ -4,6 +4,7 @@ compile_commands.json
# generated by cmake
launch.json
c_cpp_properties.json
# C/C++ extension does some local caching in this folder
ipch/
+29 -4
View File
@@ -2,15 +2,15 @@ CONFIG:
default: px4_sitl_default
choices:
px4_sitl_default:
short: px4_sitl
short: px4_sitl_default
buildType: RelWithDebInfo
settings:
CONFIG: px4_sitl_default
px4_sitl_rtps:
short: px4_sitl_rtps
px4_sitl_nolockstep:
short: px4_sitl_nolockstep
buildType: RelWithDebInfo
settings:
CONFIG: px4_sitl_rtps
CONFIG: px4_sitl_nolockstep
px4_sitl_asan:
short: px4_sitl (AddressSanitizer)
buildType: AddressSanitizer
@@ -131,6 +131,16 @@ CONFIG:
buildType: MinSizeRel
settings:
CONFIG: ark_cannode_canbootloader
ark_fmu-v6x_bootloader:
short: ark_fmu-v6x_bootloader
buildType: MinSizeRel
settings:
CONFIG: ark_fmu-v6x_bootloader
ark_fmu-v6x_default:
short: ark_fmu-v6x_default
buildType: MinSizeRel
settings:
CONFIG: ark_fmu-v6x_default
atl_mantis-edu_default:
short: atl_mantis-edu
buildType: MinSizeRel
@@ -226,6 +236,11 @@ CONFIG:
buildType: MinSizeRel
settings:
CONFIG: modalai_fc-v2_default
modalai_voxl2-io_default:
short: modalai_voxl2-io
buildType: MinSizeRel
settings:
CONFIG: modalai_voxl2-io_default
mro_ctrl-zero-f7_default:
short: mro_ctrl-zero-f7
buildType: MinSizeRel
@@ -251,6 +266,16 @@ CONFIG:
buildType: MinSizeRel
settings:
CONFIG: nxp_fmuk66-v3_default
nxp_mr-canhubk3_default:
short: nxp_mr-canhubk3_default
buildType: MinSizeRel
settings:
CONFIG: nxp_mr-canhubk3_default
nxp_mr-canhubk3_fmu:
short: nxp_mr-canhubk3_fmu
buildType: MinSizeRel
settings:
CONFIG: nxp_mr-canhubk3_fmu
raspberrypi_pico_default:
short: raspberrypi_pico
buildType: MinSizeRel
+4 -3
View File
@@ -119,7 +119,9 @@
"utility": "cpp",
"valarray": "cpp",
"variant": "cpp",
"vector": "cpp"
"vector": "cpp",
"Jenkinsfile*": "groovy",
"*.sdf": "xml"
},
"search.exclude": {
"${workspaceFolder}/build": true
@@ -133,6 +135,5 @@
"workbench.settings.enableNaturalLanguageSearch": false,
"yaml.schemas": {
"${workspaceFolder}/validation/module_schema.yaml": "${workspaceFolder}/src/modules/*/module.yaml"
},
"cortex-debug.openocdPath": "${env:PICO_SDK_PATH}/../openocd/src/openocd" // Added for rp2040
}
}
+184 -247
View File
@@ -49,238 +49,198 @@
"group": "test"
}
},
{
"label": "jmavsim build",
"type": "shell",
"command": "ant create_run_jar copy_res",
"options": {
"cwd": "${workspaceFolder}/Tools/jMAVSim"
},
"problemMatcher": [],
"presentation":{
"echo": true,
"reveal": "never",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false,
}
},
{
"label": "jmavsim",
"type": "shell",
"dependsOn": "jmavsim build",
"command": "java -Djava.ext.dirs= -jar jmavsim_run.jar -r 250 -lockstep -tcp localhost:4560 -qgc",
"options": {
"cwd": "${workspaceFolder}/Tools/jMAVSim/out/production",
"env": {
"PX4_SIM_SPEED_FACTOR": "1"
}
},
"isBackground": true,
"presentation": {
"echo": true,
"reveal": "never",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": [
{
"pattern": [
{
"regexp": ".",
"file": 1,
"location": 2,
"message": 3
}
],
"background": {
"activeOnStart": true,
"beginsPattern": ".",
"endsPattern": ".",
}
}
]
},
{
"label": "jmavsim kill",
"type": "shell",
"command": "kill $(ps aux | grep jmavsim | grep -v 'grep' | awk '{print $2}')",
"command": "kill $(ps aux | grep jmavsim | grep -v 'grep' | awk '{print $2}') || true",
"presentation": {
"echo": false,
"reveal": "never",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": []
},
{
"label": "gazebo build",
"type": "shell",
"command": "make px4_sitl_default sitl_gazebo",
"options": {
"cwd": "${workspaceFolder}"
},
"problemMatcher": [],
"presentation":{
"echo": true,
"reveal": "always",
"reveal": "never",
"revealProblems": "onProblem",
"focus": false,
"panel": "shared",
"panel": "dedicated",
"showReuseMessage": false,
"clear": false,
}
},
{
"label": "gazebo start",
"type": "shell",
"dependsOn": "gazebo build",
"options": {
"cwd": "${workspaceFolder}",
"env": {
"GAZEBO_PLUGIN_PATH": "${workspaceFolder}/build/px4_sitl_default/build_gazebo",
"GAZEBO_MODEL_PATH": "${workspaceFolder}/Tools/sitl_gazebo/models",
"PX4_SIM_SPEED_FACTOR": "1"
}
},
"command": "gzserver --verbose ${workspaceFolder}/Tools/sitl_gazebo/worlds/${input:gazeboWorld}.world",
"isBackground": true,
"presentation": {
"echo": true,
"reveal": "never",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": [
{
"pattern": [
{
"regexp": ".",
"file": 1,
"location": 2,
"message": 3
}
],
"background": {
"activeOnStart": true,
"beginsPattern": ".",
"endsPattern": ".",
}
}
]
},
{
"label": "gazebo",
"type": "shell",
"dependsOn": "gazebo start",
"options": {
"cwd": "${workspaceFolder}",
"env": {
"GAZEBO_PLUGIN_PATH": "${workspaceFolder}/build/px4_sitl_default/build_gazebo",
"GAZEBO_MODEL_PATH": "${workspaceFolder}/Tools/sitl_gazebo/models",
"PX4_SIM_SPEED_FACTOR": "1"
}
},
"command": "gz model --verbose --spawn-file=${workspaceFolder}/Tools/sitl_gazebo/models/${input:vehicleModel}/${input:vehicleModel}.sdf --model-name=${input:vehicleModel} -x 1.01 -y 0.98 -z 0.83",
"isBackground": false,
"presentation": {
"echo": true,
"reveal": "never",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": [
{
"pattern": [
{
"regexp": ".",
"file": 1,
"location": 2,
"message": 3
}
],
"background": {
"activeOnStart": true,
"beginsPattern": ".",
"endsPattern": ".",
}
}
]
},
{
"label": "gazebo client",
"type": "shell",
"dependsOn": "gazebo build",
"options": {
"cwd": "${workspaceFolder}",
"env": {
"GAZEBO_PLUGIN_PATH": "${workspaceFolder}/build/px4_sitl_default/build_gazebo",
"GAZEBO_MODEL_PATH": "${workspaceFolder}/Tools/sitl_gazebo/models",
"PX4_SIM_SPEED_FACTOR": "1"
}
},
"command": "gzclient --verbose",
"isBackground": true,
"presentation": {
"echo": true,
"reveal": "never",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": [
{
"pattern": [
{
"regexp": ".",
"file": 1,
"location": 2,
"message": 3
}
],
"background": {
"activeOnStart": true,
"beginsPattern": ".",
"endsPattern": ".",
}
}
]
},
{
"label": "gazebo kill",
"type": "shell",
"command": "killall gzserver",
"presentation": {
"echo": true,
"reveal": "silent",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
"close": true
},
"problemMatcher": [],
"dependsOn":["px4_sitl_cleanup"]
},
{
"label": "px4_sitl_cleanup",
"label": "gazebo-classic build",
"type": "shell",
"command": "rm -rfv /tmp/px4*",
"command": "make px4_sitl_default sitl_gazebo-classic",
"options": {
"cwd": "${workspaceFolder}"
},
"presentation": {
"echo": true,
"reveal": "silent",
"reveal": "never",
"revealProblems": "onProblem",
"focus": false,
"panel": "shared",
"panel": "dedicated",
"showReuseMessage": false,
"clear": false
"clear": false,
"close": true
},
"problemMatcher": [],
},
{
"label": "gazebo-classic start",
"type": "shell",
"dependsOn": "gazebo-classic build",
"options": {
"cwd": "${workspaceFolder}",
"env": {
"GAZEBO_PLUGIN_PATH": "${workspaceFolder}/build/px4_sitl_default/build_gazebo-classic",
"GAZEBO_MODEL_PATH": "${workspaceFolder}/Tools/simulation/gazebo-classic/sitl_gazebo-classic/models",
"PX4_SIM_SPEED_FACTOR": "1"
}
},
"command": "gzserver --verbose ${workspaceFolder}/Tools/simulation/gazebo-classic/sitl_gazebo-classic/worlds/empty.world",
"isBackground": true,
"presentation": {
"echo": true,
"reveal": "never",
"revealProblems": "onProblem",
"focus": false,
"panel": "dedicated",
"showReuseMessage": false,
"clear": false,
"close": true
},
"problemMatcher": [
{
"pattern": [
{
"regexp": ".",
"file": 1,
"location": 2,
"message": 3
}
],
"background": {
"activeOnStart": true,
"beginsPattern": ".",
"endsPattern": ".",
}
}
]
},
{
"label": "gazebo-classic",
"type": "shell",
"dependsOn": "gazebo-classic start",
"options": {
"cwd": "${workspaceFolder}",
"env": {
"GAZEBO_PLUGIN_PATH": "${workspaceFolder}/build/px4_sitl_default/build_gazebo-classic",
"GAZEBO_MODEL_PATH": "${workspaceFolder}/Tools/simulation/gazebo-classic/sitl_gazebo-classic/models",
"PX4_SIM_SPEED_FACTOR": "1"
}
},
"command": "gz model --verbose --spawn-file=${workspaceFolder}/Tools/simulation/gazebo-classic/sitl_gazebo-classic/models/iris/iris.sdf --model-name=iris -x 1.01 -y 0.98 -z 0.83",
"isBackground": false,
"presentation": {
"echo": true,
"reveal": "never",
"revealProblems": "onProblem",
"focus": false,
"panel": "dedicated",
"showReuseMessage": false,
"clear": false,
"close": true
},
"problemMatcher": [
{
"pattern": [
{
"regexp": ".",
"file": 1,
"location": 2,
"message": 3
}
],
"background": {
"activeOnStart": true,
"beginsPattern": ".",
"endsPattern": ".",
}
}
]
},
{
"label": "ign gazebo",
"type": "shell",
"options": {
"cwd": "${workspaceFolder}",
"env": {
"IGN_GAZEBO_RESOURCE_PATH": "${workspaceFolder}/Tools/simulation/gz/models",
}
},
"command": "ign gazebo -v 4 -r ${workspaceFolder}/Tools/simulation/gz/worlds/${input:gzWorld}.sdf",
"isBackground": true,
"presentation": {
"echo": true,
"reveal": "always",
"revealProblems": "onProblem",
"focus": true,
"panel": "dedicated",
"showReuseMessage": false,
"clear": false,
"close": false
},
"problemMatcher": [],
"dependsOn":["ign gazebo kill"]
},
{
"label": "gazebo-classic kill",
"type": "shell",
"command": "pkill -9 -f gzserver || true",
"presentation": {
"echo": true,
"reveal": "never",
"revealProblems": "onProblem",
"focus": false,
"panel": "dedicated",
"showReuseMessage": false,
"clear": false,
"close": true
},
"problemMatcher": [],
"dependsOn":["px4_sitl_cleanup"]
},
{
"label": "ign gazebo kill",
"type": "shell",
"command": "pkill -9 -f 'ign gazebo' || true",
"presentation": {
"echo": true,
"reveal": "never",
"revealProblems": "onProblem",
"focus": false,
"panel": "dedicated",
"showReuseMessage": false,
"clear": false,
"close": true
},
"problemMatcher": [],
"dependsOn":["px4_sitl_cleanup"]
},
{
"label": "px4_sitl_cleanup",
"type": "shell",
"command": "rm -rfv /tmp/px4* || true",
"presentation": {
"echo": true,
"reveal": "never",
"revealProblems": "onProblem",
"focus": false,
"panel": "dedicated",
"showReuseMessage": false,
"clear": false,
"close": true
},
"problemMatcher": [],
"dependsOn":["px4_kill"]
@@ -288,14 +248,16 @@
{
"label": "px4_kill",
"type": "shell",
"command": "killall px4 || true",
"command": "pkill -9 px4 || true",
"presentation": {
"echo": true,
"reveal": "silent",
"reveal": "never",
"revealProblems": "onProblem",
"focus": false,
"panel": "shared",
"panel": "dedicated",
"showReuseMessage": false,
"clear": false
"clear": false,
"close": true
},
"problemMatcher": []
},
@@ -337,37 +299,12 @@
"inputs": [
{
"type": "pickString",
"id": "vehicleModel",
"description": "gazebo model",
"id": "gzWorld",
"description": "gz world",
"options": [
"iris",
"typhoon_h480",
"plane",
"plane_catapult",
"plane_lidar",
"standard_vtol",
"tailsitter",
"tiltrotor",
"r1_rover",
"boat"
"default"
],
"default": "iris"
},
{
"type": "pickString",
"id": "gazeboWorld",
"description": "gazebo world",
"options": [
"baylands",
"empty",
"ksql_airport",
"mcmillan_airfield",
"sonoma_raceway",
"warehouse",
"windy",
"yosemite"
],
"default": "empty"
"default": "default"
}
]
}
+44 -58
View File
@@ -1,6 +1,6 @@
############################################################################
#
# Copyright (c) 2017 - 2019 PX4 Development Team. All rights reserved.
# Copyright (c) 2017 - 2022 PX4 Development Team. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions
@@ -118,7 +118,21 @@ execute_process(
OUTPUT_STRIP_TRAILING_WHITESPACE
WORKING_DIRECTORY ${PX4_SOURCE_DIR}
)
message(STATUS "PX4 version: ${PX4_GIT_TAG}")
# git describe to X.Y.Z version
string(REPLACE "." ";" VERSION_LIST ${PX4_GIT_TAG})
# major version
list(GET VERSION_LIST 0 PX4_VERSION_MAJOR)
string(REPLACE "v" "" PX4_VERSION_MAJOR ${PX4_VERSION_MAJOR})
# minor version
list(GET VERSION_LIST 1 PX4_VERSION_MINOR)
# patch version
list(GET VERSION_LIST 2 PX4_VERSION_PATCH)
string(REPLACE "-" ";" PX4_VERSION_PATCH ${PX4_VERSION_PATCH})
list(GET PX4_VERSION_PATCH 0 PX4_VERSION_PATCH)
message(STATUS "PX4 version: ${PX4_GIT_TAG} (${PX4_VERSION_MAJOR}.${PX4_VERSION_MINOR}.${PX4_VERSION_PATCH})")
define_property(GLOBAL PROPERTY PX4_MODULE_LIBRARIES
BRIEF_DOCS "PX4 module libs"
@@ -143,25 +157,17 @@ define_property(GLOBAL PROPERTY PX4_SRC_FILES
# configuration
#
set(CONFIG "px4_sitl_default" CACHE STRING "desired configuration")
include(px4_add_module)
set(config_module_list)
set(config_kernel_list)
# Find Python
# If using catkin, Python 2 is found since it points
# to the Python libs installed with the ROS distro
if (NOT CATKIN_DEVEL_PREFIX)
find_package(PythonInterp 3)
# We have a custom error message to tell users how to install python3.
if (NOT PYTHONINTERP_FOUND)
message(FATAL_ERROR "Python 3 not found. Please install Python 3:\n"
" Ubuntu: sudo apt install python3 python3-dev python3-pip\n"
" macOS: brew install python")
endif()
else()
find_package(PythonInterp REQUIRED)
find_package(PythonInterp 3)
# We have a custom error message to tell users how to install python3.
if(NOT PYTHONINTERP_FOUND)
message(FATAL_ERROR "Python 3 not found. Please install Python 3:\n"
" Ubuntu: sudo apt install python3 python3-dev python3-pip\n"
" macOS: brew install python")
endif()
option(PYTHON_COVERAGE "Python code coverage" OFF)
@@ -207,6 +213,11 @@ if(EXISTS "${PX4_SOURCE_DIR}/platforms/${PX4_PLATFORM}/cmake/init.cmake")
include(init)
endif()
#=============================================================================
# project definition
#
project(px4 CXX C ASM)
# CMake build type (Debug Release RelWithDebInfo MinSizeRel Coverage)
if(NOT CMAKE_BUILD_TYPE)
if(${PX4_PLATFORM} STREQUAL "nuttx")
@@ -235,11 +246,6 @@ endif()
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug;Release;RelWithDebInfo;MinSizeRel;Coverage;AddressSanitizer;UndefinedBehaviorSanitizer")
message(STATUS "cmake build type: ${CMAKE_BUILD_TYPE}")
#=============================================================================
# project definition
#
project(px4 CXX C ASM)
# Check if LTO option and check if toolchain supports it
if(LTO)
include(CheckIPOSupported)
@@ -256,15 +262,9 @@ set(CMAKE_C_STANDARD 11)
set(CMAKE_C_STANDARD_REQUIRED ON)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
# For the catkin build process, unset build of dynamically-linked binaries
# and do not change CMAKE_RUNTIME_OUTPUT_DIRECTORY
if (NOT CATKIN_DEVEL_PREFIX)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PX4_BINARY_DIR})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG ${PX4_BINARY_DIR})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE ${PX4_BINARY_DIR})
else()
SET(BUILD_SHARED_LIBS OFF)
endif()
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${PX4_BINARY_DIR})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG ${PX4_BINARY_DIR})
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE ${PX4_BINARY_DIR})
#=============================================================================
@@ -296,7 +296,10 @@ if(${PX4_PLATFORM} STREQUAL "posix")
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
set(CMAKE_ENABLE_EXPORTS ON)
include(coverage)
if(CMAKE_BUILD_TYPE MATCHES "Coverage")
include(coverage)
endif()
include(sanitizers)
# Define GNU standard installation directories
@@ -309,21 +312,6 @@ endif()
include(ccache)
#=============================================================================
# find programs and packages
#
# see if catkin was invoked to build this
if (CATKIN_DEVEL_PREFIX)
message(STATUS "catkin ENABLED")
find_package(catkin REQUIRED)
if (catkin_FOUND)
catkin_package()
else()
message(FATAL_ERROR "catkin not found")
endif()
endif()
#=============================================================================
# get chip and chip manufacturer
#
@@ -414,7 +402,6 @@ if(BUILD_TESTING)
DEPENDS
px4
examples__dyn_hello
test_mixer_multirotor
USES_TERMINAL
COMMENT "Running tests"
WORKING_DIRECTORY ${PX4_BINARY_DIR})
@@ -451,10 +438,10 @@ add_subdirectory(src/lib/metadata EXCLUDE_FROM_ALL)
add_subdirectory(src/lib/parameters EXCLUDE_FROM_ALL)
if(${PX4_PLATFORM} STREQUAL "nuttx" AND NOT CONFIG_BUILD_FLAT)
target_link_libraries(parameters_interface INTERFACE usr_parameters)
target_link_libraries(kernel_parameters_interface INTERFACE parameters)
target_link_libraries(parameters_interface INTERFACE usr_parameters)
target_link_libraries(kernel_parameters_interface INTERFACE parameters)
else()
target_link_libraries(parameters_interface INTERFACE parameters)
target_link_libraries(parameters_interface INTERFACE parameters)
endif()
# firmware added last to generate the builtin for included modules
@@ -483,21 +470,20 @@ add_custom_command(OUTPUT ${uorb_graph_config}
add_custom_target(uorb_graph DEPENDS ${uorb_graph_config})
include(bloaty)
include(doxygen)
include(metadata)
include(package)
# print size
add_custom_target(size
COMMAND size $<TARGET_FILE:px4>
DEPENDS px4
WORKING_DIRECTORY ${PX4_BINARY_DIR}
USES_TERMINAL
)
# install python requirements using configured python
add_custom_target(install_python_requirements
COMMAND ${PYTHON_EXECUTABLE} -m pip install --requirement ${PX4_SOURCE_DIR}/Tools/setup/requirements.txt
DEPENDS ${PX4_SOURCE_DIR}/Tools/setup/requirements.txt
USES_TERMINAL
)
if(EXISTS "${PX4_SOURCE_DIR}/platforms/${PX4_PLATFORM}/cmake/finalize.cmake")
include(finalize)
endif()
+2 -2
View File
@@ -8,7 +8,7 @@ First [fork and clone](https://help.github.com/articles/fork-a-repo) the project
### Create a feature branch
*Always* branch off master for new features.
*Always* branch off main for new features.
```
git checkout -b mydescriptivebranchname
@@ -16,7 +16,7 @@ git checkout -b mydescriptivebranchname
### Edit and build the code
The [developer guide](http://dev.px4.io/) explains how to set up the development environment on Mac OS, Linux or Windows. Please take note of our [coding style](https://dev.px4.io/master/en/contribute/code.html) when editing files.
The [developer guide](https://docs.px4.io/main/en/development/development.html) explains how to set up the development environment on Mac OS, Linux or Windows. Please take note of our [coding style](https://docs.px4.io/main/en/contribute/code.html) when editing files.
### Commit your changes
-1
View File
@@ -829,7 +829,6 @@ RECURSIVE = YES
# run.
EXCLUDE = @CMAKE_SOURCE_DIR@/src/modules/uavcan/libuavcan \
@CMAKE_SOURCE_DIR@/src/modules/micrortps_bridge/micro-CDR \
@CMAKE_SOURCE_DIR@/src/examples \
@CMAKE_SOURCE_DIR@/src/templates
Vendored
+55 -167
View File
@@ -7,81 +7,12 @@ pipeline {
stage('Analysis') {
when {
anyOf {
branch 'master'
branch 'main'
branch 'master' // should be removed, but in case there is something going on...
branch 'pr-jenkins' // for testing
}
}
parallel {
// stage('Catkin build on ROS workspace') {
// agent {
// docker {
// image 'px4io/px4-dev-ros-melodic:2021-08-18'
// args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw -e HOME=$WORKSPACE'
// }
// }
// steps {
// sh 'ls -l'
// sh '''#!/bin/bash -l
// echo $0;
// mkdir -p catkin_ws/src;
// cd catkin_ws;
// git -C ${WORKSPACE}/catkin_ws/src/Firmware submodule update --init --recursive --force Tools/sitl_gazebo
// git clone --recursive ${WORKSPACE}/catkin_ws/src/Firmware/Tools/sitl_gazebo src/mavlink_sitl_gazebo;
// git -C ${WORKSPACE}/catkin_ws/src/Firmware fetch --tags;
// source /opt/ros/melodic/setup.bash;
// export PYTHONPATH=/opt/ros/$ROS_DISTRO/lib/python2.7/dist-packages:/usr/lib/python2.7/dist-packages:/usr/local/lib/python2.7/dist-packages;
// catkin init;
// catkin build -j$(nproc) -l$(nproc);
// '''
// // test if the binary was correctly installed and runs using 'mavros_posix_silt.launch'
// sh '''#!/bin/bash -l
// echo $0;
// source catkin_ws/devel/setup.bash;
// rostest px4 pub_test.launch;
// '''
// }
// post {
// always {
// sh 'rm -rf catkin_ws'
// }
// failure {
// archiveArtifacts(allowEmptyArchive: false, artifacts: '.ros/**/*.xml, .ros/**/*.log')
// }
// }
// options {
// checkoutToSubdirectory('catkin_ws/src/Firmware')
// }
// }
stage('Colcon build on ROS2 workspace') {
agent {
docker {
image 'px4io/px4-dev-ros2-foxy:2021-08-18'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'ls -l'
sh '''#!/bin/bash -l
echo $0;
unset ROS_DISTRO;
mkdir -p colcon_ws/src;
cd colcon_ws;
git -C ${WORKSPACE}/colcon_ws/src/Firmware submodule update --init --recursive --force Tools/sitl_gazebo;
git -C ${WORKSPACE}/colcon_ws/src/Firmware fetch --tags;
source /opt/ros/foxy/setup.sh;
colcon build --event-handlers console_direct+ --symlink-install;
'''
}
post {
always {
sh 'rm -rf colcon_ws'
}
}
options {
checkoutToSubdirectory('colcon_ws/src/Firmware')
}
}
stage('Airframe') {
agent {
@@ -148,7 +79,7 @@ pipeline {
docker { image 'px4io/px4-dev-base-focal:2021-08-18' }
}
steps {
sh 'mkdir -p build/msg_docs; ./msg/tools/generate_msg_docs.py -d build/msg_docs'
sh 'mkdir -p build/msg_docs; ./Tools/msg/generate_msg_docs.py -d build/msg_docs'
dir('build') {
archiveArtifacts(artifacts: 'msg_docs/*.md')
stash includes: 'msg_docs/*.md', name: 'msg_documentation'
@@ -161,6 +92,36 @@ pipeline {
}
}
stage('failsafe docs') {
agent {
docker { image 'px4io/px4-dev-nuttx-focal:2021-08-18' }
}
steps {
sh '''#!/bin/bash -l
echo $0;
git clone https://github.com/emscripten-core/emsdk.git _emscripten_sdk;
cd _emscripten_sdk;
./emsdk install latest;
./emsdk activate latest;
cd ..;
. ./_emscripten_sdk/emsdk_env.sh;
make failsafe_web;
cd build/px4_sitl_default_failsafe_web;
mkdir -p failsafe_sim;
cp index.* parameters.json failsafe_sim;
'''
dir('build/px4_sitl_default_failsafe_web') {
archiveArtifacts(artifacts: 'failsafe_sim/*')
stash includes: 'failsafe_sim/*', name: 'failsafe_sim'
}
}
post {
always {
sh 'make distclean; git clean -ff -x -d .'
}
}
}
stage('uORB graphs') {
agent {
docker {
@@ -202,22 +163,25 @@ pipeline {
unstash 'metadata_parameters'
unstash 'metadata_module_documentation'
unstash 'msg_documentation'
unstash 'failsafe_sim'
unstash 'uorb_graph'
withCredentials([usernamePassword(credentialsId: 'px4buildbot_github_personal_token', passwordVariable: 'GIT_PASS', usernameVariable: 'GIT_USER')]) {
sh('git clone https://${GIT_USER}:${GIT_PASS}@github.com/PX4/px4_user_guide.git')
sh('cp airframes.md px4_user_guide/en/airframes/airframe_reference.md')
sh('cp parameters.md px4_user_guide/en/advanced_config/parameter_reference.md')
sh('cp -R modules/*.md px4_user_guide/en/modules/')
sh('cp -R graph_*.json px4_user_guide/.vuepress/public/en/middleware/')
sh('cp -R msg_docs/*.md px4_user_guide/en/msg_docs/')
sh('cd px4_user_guide; git status; git add .; git commit -a -m "Update PX4 Firmware metadata `date`" || true')
sh('cd px4_user_guide; git push origin master || true')
sh('rm -rf px4_user_guide')
sh('git clone https://${GIT_USER}:${GIT_PASS}@github.com/PX4/PX4-user_guide.git')
sh('cp airframes.md PX4-user_guide/en/airframes/airframe_reference.md')
sh('cp parameters.md PX4-user_guide/en/advanced_config/parameter_reference.md')
sh('cp -R modules/*.md PX4-user_guide/en/modules/')
sh('cp -R graph_*.json PX4-user_guide/.vuepress/public/en/middleware/')
sh('cp -R msg_docs/*.md PX4-user_guide/en/msg_docs/')
sh('cp -R failsafe_sim/* PX4-user_guide/.vuepress/public/en/config/failsafe')
sh('cd PX4-user_guide; git status; git add .; git commit -a -m "Update PX4 Firmware metadata `date`" || true')
sh('cd PX4-user_guide; git push origin main || true')
sh('rm -rf PX4-user_guide')
}
}
when {
anyOf {
branch 'master'
branch 'main'
branch 'master' // should be removed, but in case there is something going on...
branch 'pr-jenkins' // for testing
}
}
@@ -245,7 +209,8 @@ pipeline {
}
when {
anyOf {
branch 'master'
branch 'main'
branch 'master' // should be removed, but in case there is something going on...
branch 'pr-jenkins' // for testing
}
}
@@ -254,36 +219,6 @@ pipeline {
}
}
stage('microRTPS agent') {
agent {
docker { image 'px4io/px4-dev-base-focal:2021-08-18' }
}
steps {
sh('export')
sh('git fetch --all --tags')
sh('make distclean; git clean -ff -x -d .')
sh('make px4_sitl_rtps')
withCredentials([usernamePassword(credentialsId: 'px4buildbot_github_personal_token', passwordVariable: 'GIT_PASS', usernameVariable: 'GIT_USER')]) {
sh("git clone https://${GIT_USER}:${GIT_PASS}@github.com/PX4/micrortps_agent.git -b ${BRANCH_NAME}")
sh("rm -rf micrortps_agent/src micrortps_agent/idl")
sh('cp -R build/px4_sitl_rtps/src/modules/micrortps_bridge/micrortps_agent/* micrortps_agent')
sh('cd micrortps_agent; git status; git add src; git commit -a -m "Update microRTPS agent source code `date`" || true')
sh('cd micrortps_agent; git push origin ${BRANCH_NAME} || true')
sh('cd micrortps_agent; git status; git add idl; git commit -a -m "Update IDL definitions `date`" || true')
sh('cd micrortps_agent; git push origin ${BRANCH_NAME} || true')
sh('cd micrortps_agent; git status; git add CMakeLists.txt; git commit -a -m "Update CMakeLists.txt `date`" || true')
sh('cd micrortps_agent; git push origin ${BRANCH_NAME} || true')
sh('rm -rf micrortps_agent')
}
}
when {
anyOf {
branch 'master'
branch 'pr-jenkins' // for testing
}
}
}
stage('PX4 ROS msgs') {
agent {
docker { image 'px4io/px4-dev-base-focal:2021-08-18' }
@@ -293,65 +228,17 @@ pipeline {
sh('make distclean; git clean -ff -x -d .')
withCredentials([usernamePassword(credentialsId: 'px4buildbot_github_personal_token', passwordVariable: 'GIT_PASS', usernameVariable: 'GIT_USER')]) {
sh("git clone https://${GIT_USER}:${GIT_PASS}@github.com/PX4/px4_msgs.git")
// 'master' branch
sh('./msg/tools/uorb_to_ros_msgs.py msg/ px4_msgs/msg/')
// 'main' branch
sh('rm -f px4_msgs/msg/*.msg')
sh('cp msg/*.msg px4_msgs/msg/')
sh('cd px4_msgs; git status; git add .; git commit -a -m "Update message definitions `date`" || true')
sh('cd px4_msgs; git push origin master || true')
// 'ros1' branch
sh('cd px4_msgs; git checkout ros1')
sh('./msg/tools/uorb_to_ros_msgs.py msg/ px4_msgs/msg/')
sh('cd px4_msgs; git status; git add .; git commit -a -m "Update message definitions `date`" || true')
sh('cd px4_msgs; git push origin ros1 || true')
sh('cd px4_msgs; git push origin main || true')
sh('rm -rf px4_msgs')
}
}
when {
anyOf {
branch 'master'
branch 'pr-jenkins' // for testing
}
}
}
stage('PX4 ROS2 bridge') {
agent {
docker { image 'px4io/px4-dev-base-focal:2021-08-18' }
}
steps {
sh('export')
sh('make distclean; git clean -ff -x -d .')
withCredentials([usernamePassword(credentialsId: 'px4buildbot_github_personal_token', passwordVariable: 'GIT_PASS', usernameVariable: 'GIT_USER')]) {
sh("git clone https://${GIT_USER}:${GIT_PASS}@github.com/PX4/px4_ros_com.git -b ${BRANCH_NAME}")
// deploy uORB RTPS ID map
sh('./msg/tools/uorb_to_ros_urtps_topics.py -i msg/tools/urtps_bridge_topics.yaml -o px4_ros_com/templates/urtps_bridge_topics.yaml')
sh('cd px4_ros_com; git status; git add .; git commit -a -m "Update uORB RTPS ID map `date`" || true')
sh('cd px4_ros_com; git push origin ${BRANCH_NAME} || true')
// deploy uORB RTPS required tools
sh('cp msg/tools/uorb_rtps_classifier.py px4_ros_com/scripts/uorb_rtps_classifier.py')
sh('cp msg/tools/generate_microRTPS_bridge.py px4_ros_com/scripts/generate_microRTPS_bridge.py')
sh('cp msg/tools/px_generate_uorb_topic_files.py px4_ros_com/scripts/px_generate_uorb_topic_files.py')
sh('cp msg/tools/px_generate_uorb_topic_helper.py px4_ros_com/scripts/px_generate_uorb_topic_helper.py')
// deploy templates
sh('cp msg/templates/urtps/microRTPS_agent.cpp.em px4_ros_com/templates/microRTPS_agent.cpp.em')
sh('cp msg/templates/urtps/microRTPS_timesync.cpp.em px4_ros_com/templates/microRTPS_timesync.cpp.em')
sh('cp msg/templates/urtps/microRTPS_timesync.h.em px4_ros_com/templates/microRTPS_timesync.h.em')
sh('cp msg/templates/urtps/microRTPS_transport.cpp px4_ros_com/templates/microRTPS_transport.cpp')
sh('cp msg/templates/urtps/microRTPS_transport.h px4_ros_com/templates/microRTPS_transport.h')
sh('cp msg/templates/urtps/Publisher.cpp.em px4_ros_com/templates/Publisher.cpp.em')
sh('cp msg/templates/urtps/Publisher.h.em px4_ros_com/templates/Publisher.h.em')
sh('cp msg/templates/urtps/Subscriber.cpp.em px4_ros_com/templates/Subscriber.cpp.em')
sh('cp msg/templates/urtps/Subscriber.h.em px4_ros_com/templates/Subscriber.h.em')
sh('cp msg/templates/urtps/RtpsTopics.cpp.em px4_ros_com/templates/RtpsTopics.cpp.em')
sh('cp msg/templates/urtps/RtpsTopics.h.em px4_ros_com/templates/RtpsTopics.h.em')
sh('cd px4_ros_com; git status; git add .; git commit -a -m "Update uORB RTPS script tools `date`" || true')
sh('cd px4_ros_com; git push origin ${BRANCH_NAME} || true')
sh('rm -rf px4_msgs')
}
}
when {
anyOf {
branch 'master'
branch 'pr-jenkins' // for testing
branch 'main'
}
}
}
@@ -373,7 +260,8 @@ pipeline {
}
when {
anyOf {
branch 'master'
branch 'main'
branch 'master' // should be removed, but in case there is something going on...
branch 'pr-jenkins' // for testing
}
}
+19 -4
View File
@@ -17,6 +17,8 @@ menu "Toolchain"
bool "posix"
config PLATFORM_QURT
bool "qurt"
config PLATFORM_ROS2
bool "ros2"
endchoice
config BOARD_PLATFORM
@@ -24,6 +26,7 @@ menu "Toolchain"
default "nuttx" if PLATFORM_NUTTX
default "posix" if PLATFORM_POSIX
default "qurt" if PLATFORM_QURT
default "ros2" if PLATFORM_ROS2
config BOARD_LOCKSTEP
bool "Force enable lockstep"
@@ -37,8 +40,8 @@ menu "Toolchain"
help
forces nolockstep behaviour, despite REPLAY env variable
config BOARD_LINUX
bool "Linux OS"
config BOARD_LINUX_TARGET
bool "Linux OS Target"
depends on PLATFORM_POSIX
help
Board Platform is running the Linux operating system
@@ -70,6 +73,13 @@ menu "Toolchain"
help
relative path to the ROMFS root directory
config BOARD_ROOTFSDIR
string "Root directory"
depends on PLATFORM_POSIX
default "."
help
Configure the root directory in the file system for PX4 files
config BOARD_IO
string "IO board name"
default "px4_io-v2_default"
@@ -171,8 +181,8 @@ menu "Serial ports"
config BOARD_SERIAL_WIFI
string "WIFI tty port"
config BOARD_SERIAL_PPB
string "PPB (Pixhawk Payload Bus) tty port"
config BOARD_SERIAL_EXT2
string "EXT2 tty port"
endmenu
menu "drivers"
@@ -190,3 +200,8 @@ endmenu
menu "examples"
source "src/examples/Kconfig"
endmenu
menu "platforms"
depends on PLATFORM_QURT || PLATFORM_POSIX
source "platforms/common/Kconfig"
endmenu
+1 -1
View File
@@ -1,6 +1,6 @@
BSD 3-Clause License
Copyright (c) 2012 - 2022, PX4 Development Team
Copyright (c) 2012 - 2023, PX4 Development Team
All rights reserved.
Redistribution and use in source and binary forms, with or without
+45 -50
View File
@@ -129,57 +129,54 @@ else
BUILD_DIR_SUFFIX :=
endif
CMAKE_ARGS ?=
# additional config parameters passed to cmake
ifdef EXTERNAL_MODULES_LOCATION
CMAKE_ARGS += -DEXTERNAL_MODULES_LOCATION:STRING=$(EXTERNAL_MODULES_LOCATION)
override CMAKE_ARGS += -DEXTERNAL_MODULES_LOCATION:STRING=$(EXTERNAL_MODULES_LOCATION)
endif
ifdef PX4_CMAKE_BUILD_TYPE
CMAKE_ARGS += -DCMAKE_BUILD_TYPE=${PX4_CMAKE_BUILD_TYPE}
override CMAKE_ARGS += -DCMAKE_BUILD_TYPE=${PX4_CMAKE_BUILD_TYPE}
else
# Address Sanitizer
ifdef PX4_ASAN
CMAKE_ARGS += -DCMAKE_BUILD_TYPE=AddressSanitizer
override CMAKE_ARGS += -DCMAKE_BUILD_TYPE=AddressSanitizer
endif
# Memory Sanitizer
ifdef PX4_MSAN
CMAKE_ARGS += -DCMAKE_BUILD_TYPE=MemorySanitizer
override CMAKE_ARGS += -DCMAKE_BUILD_TYPE=MemorySanitizer
endif
# Thread Sanitizer
ifdef PX4_TSAN
CMAKE_ARGS += -DCMAKE_BUILD_TYPE=ThreadSanitizer
override CMAKE_ARGS += -DCMAKE_BUILD_TYPE=ThreadSanitizer
endif
# Undefined Behavior Sanitizer
ifdef PX4_UBSAN
CMAKE_ARGS += -DCMAKE_BUILD_TYPE=UndefinedBehaviorSanitizer
override CMAKE_ARGS += -DCMAKE_BUILD_TYPE=UndefinedBehaviorSanitizer
endif
# Fuzz Testing
ifdef PX4_FUZZ
CMAKE_ARGS += -DCMAKE_BUILD_TYPE=FuzzTesting
override CMAKE_ARGS += -DCMAKE_BUILD_TYPE=FuzzTesting
endif
endif
# Pick up specific Python path if set
ifdef PYTHON_EXECUTABLE
CMAKE_ARGS += -DPYTHON_EXECUTABLE=${PYTHON_EXECUTABLE}
endif
# Check if the microRTPS agent is to be built
ifdef BUILD_MICRORTPS_AGENT
CMAKE_ARGS += -DBUILD_MICRORTPS_AGENT=ON
override CMAKE_ARGS += -DPYTHON_EXECUTABLE=${PYTHON_EXECUTABLE}
endif
# Functions
# --------------------------------------------------------------------
# describe how to build a cmake config
define cmake-build
$(eval CMAKE_ARGS += -DCONFIG=$(1))
$(eval override CMAKE_ARGS += -DCONFIG=$(1))
@$(eval BUILD_DIR = "$(SRC_DIR)/build/$(1)")
@# check if the desired cmake configuration matches the cache then CMAKE_CACHE_CHECK stays empty
@$(call cmake-cache-check)
@@ -251,7 +248,7 @@ endef
# Other targets
# --------------------------------------------------------------------
.PHONY: qgc_firmware px4fmu_firmware misc_qgc_extra_firmware check_rtps
.PHONY: qgc_firmware px4fmu_firmware misc_qgc_extra_firmware
# QGroundControl flashable NuttX firmware
qgc_firmware: px4fmu_firmware misc_qgc_extra_firmware
@@ -276,15 +273,7 @@ misc_qgc_extra_firmware: \
check_airmind_mindpx-v2_default \
sizes
# builds with RTPS
check_rtps: \
check_px4_fmu-v3_rtps \
check_px4_fmu-v4_rtps \
check_px4_fmu-v4pro_rtps \
check_px4_sitl_rtps \
sizes
.PHONY: sizes check quick_check check_rtps uorb_graphs
.PHONY: sizes check quick_check uorb_graphs
sizes:
@-find build -name *.elf -type f | xargs size 2> /dev/null || :
@@ -314,10 +303,14 @@ uorb_graphs:
@$(MAKE) --no-print-directory px4_fmu-v5_default uorb_graph
@$(MAKE) --no-print-directory px4_sitl_default uorb_graph
px4io_update: px4_io-v2_default cubepilot_io-v2_default
px4io_update:
@$(MAKE) --no-print-directory px4_io-v2_default
@$(MAKE) --no-print-directory cubepilot_io-v2_default
# px4_io-v2_default
cp build/px4_io-v2_default/px4_io-v2_default.bin boards/ark/fmu-v6x/extras/px4_io-v2_default.bin
cp build/px4_io-v2_default/px4_io-v2_default.bin boards/holybro/durandal-v1/extras/px4_io-v2_default.bin
cp build/px4_io-v2_default/px4_io-v2_default.bin boards/holybro/pix32v5/extras/px4_io-v2_default.bin
cp build/px4_io-v2_default/px4_io-v2_default.bin boards/mro/x21/extras/px4_io-v2_default.bin
cp build/px4_io-v2_default/px4_io-v2_default.bin boards/mro/x21-777/extras/px4_io-v2_default.bin
cp build/px4_io-v2_default/px4_io-v2_default.bin boards/px4/fmu-v2/extras/px4_io-v2_default.bin
cp build/px4_io-v2_default/px4_io-v2_default.bin boards/px4/fmu-v3/extras/px4_io-v2_default.bin
@@ -331,7 +324,7 @@ px4io_update: px4_io-v2_default cubepilot_io-v2_default
cp build/cubepilot_io-v2_default/cubepilot_io-v2_default.bin boards/cubepilot/cubeyellow/extras/cubepilot_io-v2_default.bin
git status
bootloaders_update: cuav_nora_bootloader cuav_x7pro_bootloader cubepilot_cubeorange_bootloader holybro_durandal-v1_bootloader holybro_kakuteh7_bootloader matek_h743_bootloader matek_h743-mini_bootloader matek_h743-slim_bootloader modalai_fc-v2_bootloader mro_ctrl-zero-classic_bootloader mro_ctrl-zero-h7_bootloader mro_ctrl-zero-h7-oem_bootloader mro_pixracerpro_bootloader px4_fmu-v6c_bootloader px4_fmu-v6u_bootloader px4_fmu-v6x_bootloader
bootloaders_update: ark_fmu-v6x_bootloader cuav_nora_bootloader cuav_x7pro_bootloader cubepilot_cubeorange_bootloader holybro_durandal-v1_bootloader holybro_kakuteh7_bootloader matek_h743_bootloader matek_h743-mini_bootloader matek_h743-slim_bootloader modalai_fc-v2_bootloader mro_ctrl-zero-classic_bootloader mro_ctrl-zero-h7_bootloader mro_ctrl-zero-h7-oem_bootloader mro_pixracerpro_bootloader px4_fmu-v6c_bootloader px4_fmu-v6u_bootloader px4_fmu-v6x_bootloader
git status
.PHONY: coverity_scan
@@ -381,7 +374,7 @@ format:
.PHONY: rostest python_coverage
tests:
$(eval CMAKE_ARGS += -DTESTFILTER=$(TESTFILTER))
$(eval override CMAKE_ARGS += -DTESTFILTER=$(TESTFILTER))
$(eval ARGS += test_results)
$(eval ASAN_OPTIONS += color=always:check_initialization_order=1:detect_stack_use_after_return=1)
$(eval UBSAN_OPTIONS += color=always)
@@ -395,17 +388,17 @@ tests_coverage:
rostest: px4_sitl_default
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo-classic
tests_integration: px4_sitl_default
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo-classic
@$(MAKE) --no-print-directory px4_sitl_default mavsdk_tests
@"$(SRC_DIR)"/test/mavsdk_tests/mavsdk_test_runner.py --speed-factor 20 test/mavsdk_tests/configs/sitl.json
tests_integration_coverage:
@$(MAKE) clean
@$(MAKE) --no-print-directory px4_sitl_default PX4_CMAKE_BUILD_TYPE=Coverage
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo-classic
@$(MAKE) --no-print-directory px4_sitl_default mavsdk_tests
@"$(SRC_DIR)"/test/mavsdk_tests/mavsdk_test_runner.py --speed-factor 20 test/mavsdk_tests/configs/sitl.json
@mkdir -p coverage
@@ -415,13 +408,13 @@ tests_mission: rostest
@"$(SRC_DIR)"/test/rostest_px4_run.sh mavros_posix_tests_missions.test
rostest_run: px4_sitl_default
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo-classic
@"$(SRC_DIR)"/test/rostest_px4_run.sh $(TEST_FILE) mission:=$(TEST_MISSION) vehicle:=$(TEST_VEHICLE)
tests_mission_coverage:
@$(MAKE) clean
@$(MAKE) --no-print-directory px4_sitl_default PX4_CMAKE_BUILD_TYPE=Coverage
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo PX4_CMAKE_BUILD_TYPE=Coverage
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo-classic PX4_CMAKE_BUILD_TYPE=Coverage
@"$(SRC_DIR)"/test/rostest_px4_run.sh mavros_posix_test_mission.test mission:=VTOL_mission_1 vehicle:=standard_vtol
@$(MAKE) --no-print-directory px4_sitl_default generate_coverage
@@ -489,12 +482,14 @@ shellcheck_all:
validate_module_configs:
@find "$(SRC_DIR)"/src/modules "$(SRC_DIR)"/src/drivers "$(SRC_DIR)"/src/lib -name *.yaml -type f \
-not -path "$(SRC_DIR)/src/lib/mixer_module/*" -not -path "$(SRC_DIR)/src/lib/crypto/libtommath/*" -print0 | \
-not -path "$(SRC_DIR)/src/lib/mixer_module/*" \
-not -path "$(SRC_DIR)/src/modules/microdds_client/dds_topics.yaml" \
-not -path "$(SRC_DIR)/src/lib/crypto/libtommath/*" -print0 | \
xargs -0 "$(SRC_DIR)"/Tools/validate_yaml.py --schema-file "$(SRC_DIR)"/validation/module_schema.yaml
# Cleanup
# --------------------------------------------------------------------
.PHONY: clean submodulesclean submodulesupdate gazeboclean distclean
.PHONY: clean submodulesclean submodulesupdate distclean
clean:
@[ ! -d "$(SRC_DIR)/build" ] || find "$(SRC_DIR)/build" -mindepth 1 -maxdepth 1 -type d -exec sh -c "echo {}; cmake --build {} -- clean || rm -rf {}" \; # use generated build system to clean, wipe build directory if it fails
@@ -512,10 +507,7 @@ submodulesupdate:
@git submodule update --init --recursive --jobs 4
@git fetch --all --tags --recurse-submodules=yes --jobs=4
gazeboclean:
@rm -rf ~/.gazebo/*
distclean: gazeboclean
distclean:
@git submodule deinit --force $(SRC_DIR)
@rm -rf "$(SRC_DIR)/build"
@git clean --force -X "$(SRC_DIR)/msg/" "$(SRC_DIR)/platforms/" "$(SRC_DIR)/posix-configs/" "$(SRC_DIR)/ROMFS/" "$(SRC_DIR)/src/" "$(SRC_DIR)/test/" "$(SRC_DIR)/Tools/"
@@ -555,17 +547,20 @@ check_px4: $(call make_list,nuttx,"px4") \
check_nxp: $(call make_list,nuttx,"nxp") \
sizes
ifneq ($(ROS2_WS_DIR),)
ROS2_WS_DIR := $(basename ${ROS2_WS_DIR})
else
ROS2_WS_DIR := ~/colcon_ws
endif
# helpers for running olddefconfig (nuttx) and px4_savedefconfig on all boards
.PHONY: all_oldconfig all_px4_savedefconfig
all_oldconfig:
@for targ in $(ALL_CONFIG_TARGETS); do $(MAKE) $$targ oldconfig; done
update_ros2_bridge:
@Tools/update_px4_ros2_bridge.sh --ws_dir ${ROS2_WS_DIR} --all
all_px4_savedefconfig:
@for targ in $(ALL_CONFIG_TARGETS); do $(MAKE) $$targ px4_savedefconfig; done
update_px4_ros_com:
@Tools/update_px4_ros2_bridge.sh --ws_dir ${ROS2_WS_DIR} --px4_ros_com
update_px4_msgs:
@Tools/update_px4_ros2_bridge.sh --ws_dir ${ROS2_WS_DIR} --px4_msgs
.PHONY: failsafe_web run_failsafe_web_server
failsafe_web:
@if ! command -v emcc; then echo -e "Install emscripten first: https://emscripten.org/docs/getting_started/downloads.html\nAnd source the env: source <path>/emsdk_env.sh"; exit 1; fi
@$(MAKE) --no-print-directory px4_sitl_default failsafe_test parameters_xml \
PX4_CMAKE_BUILD_TYPE=Release BUILD_DIR_SUFFIX=_failsafe_web \
CMAKE_ARGS="-DCMAKE_CXX_COMPILER=em++ -DCMAKE_C_COMPILER=emcc"
run_failsafe_web_server: failsafe_web
@cd build/px4_sitl_default_failsafe_web && \
python3 -m http.server
+4 -4
View File
@@ -4,14 +4,14 @@
[![Nuttx Targets](https://github.com/PX4/PX4-Autopilot/workflows/Nuttx%20Targets/badge.svg)](https://github.com/PX4/PX4-Autopilot/actions?query=workflow%3A%22Nuttx+Targets%22?branch=master) [![SITL Tests](https://github.com/PX4/PX4-Autopilot/workflows/SITL%20Tests/badge.svg?branch=master)](https://github.com/PX4/PX4-Autopilot/actions?query=workflow%3A%22SITL+Tests%22)
[![Slack](/.github/slack.svg)](https://join.slack.com/t/px4/shared_invite/zt-si4xo5qs-R4baYFmMjlrT4rQK5yUnaA)
[![Discord Shield](https://discordapp.com/api/guilds/1022170275984457759/widget.png?style=shield)](https://discord.gg/dronecode)
This repository holds the [PX4](http://px4.io) flight control solution for drones, with the main applications located in the [src/modules](https://github.com/PX4/PX4-Autopilot/tree/main/src/modules) directory. It also contains the PX4 Drone Middleware Platform, which provides drivers and middleware to run drones.
PX4 is highly portable, OS-independent and supports Linux, NuttX and MacOS out of the box.
* Official Website: http://px4.io (License: BSD 3-clause, [LICENSE](https://github.com/PX4/PX4-Autopilot/blob/master/LICENSE))
* [Supported airframes](https://docs.px4.io/main/en/airframes/airframe_reference.html) ([portfolio](http://px4.io/#airframes)):
* Official Website: http://px4.io (License: BSD 3-clause, [LICENSE](https://github.com/PX4/PX4-Autopilot/blob/main/LICENSE))
* [Supported airframes](https://docs.px4.io/main/en/airframes/airframe_reference.html) ([portfolio](https://px4.io/ecosystem/commercial-systems/)):
* [Multicopters](https://docs.px4.io/main/en/frames_multicopter/)
* [Fixed wing](https://docs.px4.io/main/en/frames_plane/)
* [VTOL](https://docs.px4.io/main/en/frames_vtol/)
@@ -75,7 +75,7 @@ The PX4 Dev Team syncs up on a [weekly dev call](https://docs.px4.io/main/en/con
* [Paul Riseborough](https://github.com/priseborough)
* Vision based navigation and Obstacle Avoidance
* [Markus Achtelik](https://github.com/markusachtelik)
* RTPS/ROS2 Interface
* DDS/ROS2 Interface
* [Nuno Marques](https://github.com/TSC21)
See also [maintainers list](https://px4.io/community/maintainers/) (px4.io) and the [contributors list](https://github.com/PX4/PX4-Autopilot/graphs/contributors) (Github).
+5
View File
@@ -31,6 +31,11 @@ then
set PARAM_FILE /dev/eeeprom0
fi
if mft query -q -k MTD -s MTD_PARAMETERS -v /mnt/qspi/params
then
set PARAM_FILE /mnt/qspi/params
fi
#
# Load parameters.
#
-2
View File
@@ -32,9 +32,7 @@
############################################################################
add_subdirectory(init.d)
add_subdirectory(mixers)
# TODO: make this configurable from the board config, or better combine
if("${PX4_BOARD}" MATCHES "sitl")
add_subdirectory(mixers-sitl)
add_subdirectory(init.d-posix)
endif()
@@ -36,7 +36,6 @@ add_subdirectory(airframes)
px4_add_romfs_files(
px4-rc.mavlink
px4-rc.params
px4-rc.rtps
px4-rc.simulator
rc.replay
rcS
@@ -9,8 +9,6 @@
. ${R}etc/init.d/rc.mc_defaults
param set-default SYS_CTRL_ALLOC 1
param set-default CA_AIRFRAME 0
@@ -32,6 +30,3 @@ param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
set MIXER skip
set MIXER_AUX none
@@ -1,12 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL
#
# @type Quadrotor Wide
#
# @maintainer Julian Oes <julian@oes.ch>
#
. ${R}etc/init.d/rc.mc_defaults
set MIXER quad_w
@@ -0,0 +1,32 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL jMAVSim
#
# @type Quadrotor Wide
#
# @maintainer Julian Oes <julian@oes.ch>
#
. ${R}etc/init.d/rc.mc_defaults
param set-default CA_AIRFRAME 0
param set-default CA_ROTOR_COUNT 4
param set-default CA_ROTOR0_PX 0.1515
param set-default CA_ROTOR0_PY 0.245
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX -0.1515
param set-default CA_ROTOR1_PY -0.1875
param set-default CA_ROTOR1_KM 0.05
param set-default CA_ROTOR2_PX 0.1515
param set-default CA_ROTOR2_PY -0.245
param set-default CA_ROTOR2_KM -0.05
param set-default CA_ROTOR3_PX -0.1515
param set-default CA_ROTOR3_PY 0.1875
param set-default CA_ROTOR3_KM -0.05
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
@@ -0,0 +1,33 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (foggy_lidar)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d/rc.mc_defaults
param set-default CA_AIRFRAME 0
param set-default CA_ROTOR_COUNT 4
param set-default CA_ROTOR0_PX 0.1515
param set-default CA_ROTOR0_PY 0.245
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX -0.1515
param set-default CA_ROTOR1_PY -0.1875
param set-default CA_ROTOR1_KM 0.05
param set-default CA_ROTOR2_PX 0.1515
param set-default CA_ROTOR2_PY -0.245
param set-default CA_ROTOR2_KM -0.05
param set-default CA_ROTOR3_PX -0.1515
param set-default CA_ROTOR3_PY 0.1875
param set-default CA_ROTOR3_KM -0.05
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
param set-default EKF2_RNG_A_HMAX 10
@@ -1,11 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (foggy_lidar)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
param set-default EKF2_RNG_A_HMAX 10
@@ -9,8 +9,6 @@
. ${R}etc/init.d/rc.mc_defaults
param set-default SYS_CTRL_ALLOC 1
param set-default CA_AIRFRAME 0
@@ -97,5 +95,3 @@ param set-default CA_METHOD 0
param set-default FD_FAIL_P 0
param set-default FD_FAIL_R 0
set MIXER skip
set MIXER_AUX none
@@ -1,19 +0,0 @@
#!/bin/sh
#
# @name IF750A SITL
# InspiredFlight 750 Auterion edition. Gazebo Only.
#
# @type Quadrotor
#
. ${R}etc/init.d/rc.mc_defaults
# EKF2: Multi GPS blending (as the model has 2 GPS's)
param set-default SENS_GPS_MASK 7
param set-default TRIG_INTERFACE 3
param set-default TRIG_MODE 4
param set-default MNT_MODE_IN 4
param set-default MNT_MODE_OUT 2
param set-default MNT_DO_STAB 2
set MIXER quad_x
@@ -0,0 +1,15 @@
#!/bin/sh
#
# @name PX4Vision SITL
# Holybro px4vision. Gazebo Only.
#
# @type Quadrotor
#
. ${R}etc/init.d/airframes/4016_holybro_px4vision
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
@@ -1,11 +0,0 @@
#!/bin/sh
#
# @name PX4Vision SITL
# Holybro px4vision. Gazebo Only.
#
# @type Quadrotor
#
. ${R}etc/init.d/airframes/4016_holybro_px4vision
set MIXER quad_x
@@ -1,23 +0,0 @@
#!/bin/sh
#
# @name QuadrotorX SITL for SIH
#
# @type Quadrotor
#
# @maintainer Romain Chiappinelli <romain.chiap@gmail.com>
#
. ${R}etc/init.d/rc.mc_defaults
set MIXER quad_x
# disable some checks to allow to fly:
# - with usb
param set-default CBRK_USB_CHK 197848
# - without real battery
param set-default CBRK_SUPPLY_CHK 894281
# - without safety switch
param set-default COM_PREARM_MODE 0
param set-default CBRK_IO_SAFETY 22027
param set SIH_VEHICLE_TYPE 0
@@ -0,0 +1,43 @@
#!/bin/sh
#
# @name QuadrotorX SITL for SIH
#
# @type Quadrotor
#
# @maintainer Romain Chiappinelli <romain.chiap@gmail.com>
#
. ${R}etc/init.d/rc.mc_defaults
PX4_SIMULATOR=${PX4_SIMULATOR:=sihsim}
PX4_SIM_MODEL=${PX4_SIM_MODEL:=quadx}
# disable some checks to allow to fly:
# - with usb
param set-default CBRK_USB_CHK 197848
# - without real battery
param set-default CBRK_SUPPLY_CHK 894281
# - without safety switch
param set-default COM_PREARM_MODE 0
param set-default CBRK_IO_SAFETY 22027
param set-default CA_ROTOR_COUNT 4
param set-default CA_ROTOR0_PX 0.15
param set-default CA_ROTOR0_PY 0.15
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX -0.15
param set-default CA_ROTOR1_PY -0.15
param set-default CA_ROTOR1_KM 0.05
param set-default CA_ROTOR2_PX 0.15
param set-default CA_ROTOR2_PY -0.15
param set-default CA_ROTOR2_KM -0.05
param set-default CA_ROTOR3_PX -0.15
param set-default CA_ROTOR3_PY 0.15
param set-default CA_ROTOR3_KM -0.05
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
param set SIH_VEHICLE_TYPE 0
@@ -1,33 +0,0 @@
#!/bin/sh
#
# @name Plane SITL for SIH
#
# @type Plane
#
# @maintainer Romain Chiappinelli <romain.chiap@gmail.com>
. ${R}etc/init.d/rc.fw_defaults
set MIXER AERT
# disable some checks to allow to fly:
# - with usb
param set-default CBRK_USB_CHK 197848
# - without real battery
param set-default CBRK_SUPPLY_CHK 894281
# - without safety switch
param set-default COM_PREARM_MODE 0
param set-default CBRK_IO_SAFETY 22027
param set-default BAT_N_CELLS 3
param set SIH_T_MAX 6.0
param set SIH_MASS 0.3
param set SIH_IXX 0.00402
param set SIH_IYY 0.0144
param set SIH_IZZ 0.0177
param set SIH_IXZ 0.00046
param set SIH_KDV 0.2
param set SIH_VEHICLE_TYPE 1 # sih as fixed wing
param set RWTO_TKOFF 1 # enable takeoff from runway (as opposed to launched)
@@ -0,0 +1,51 @@
#!/bin/sh
#
# @name Plane SITL for SIH
#
# @type Plane
#
# @maintainer Romain Chiappinelli <romain.chiap@gmail.com>
. ${R}etc/init.d/rc.fw_defaults
PX4_SIMULATOR=${PX4_SIMULATOR:=sihsim}
PX4_SIM_MODEL=${PX4_SIM_MODEL:=airplane}
# disable some checks to allow to fly:
# - with usb
param set-default CBRK_USB_CHK 197848
# - without real battery
param set-default CBRK_SUPPLY_CHK 894281
# - without safety switch
param set-default COM_PREARM_MODE 0
param set-default CBRK_IO_SAFETY 22027
param set-default BAT_N_CELLS 3
param set-default SIH_T_MAX 6.0
param set-default SIH_MASS 0.3
param set-default SIH_IXX 0.00402
param set-default SIH_IYY 0.0144
param set-default SIH_IZZ 0.0177
param set-default SIH_IXZ 0.00046
param set-default SIH_KDV 0.2
param set-default SIH_VEHICLE_TYPE 1 # sih as fixed wing
param set-default RWTO_TKOFF 1 # enable takeoff from runway (as opposed to launched)
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_SV_CS_COUNT 3
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_P 1.0
param set-default CA_SV_CS1_TYPE 3
param set-default CA_SV_CS2_TRQ_Y 1.0
param set-default CA_SV_CS2_TYPE 4
param set-default PWM_MAIN_FUNC3 201
param set-default PWM_MAIN_FUNC4 202
param set-default PWM_MAIN_FUNC5 203
param set-default PWM_MAIN_FUNC6 101
@@ -0,0 +1,69 @@
#!/bin/sh
#
# @name SIH Tailsitter Duo
#
# @type VTOL
#
# @maintainer Romain Chiappinelli <romain.chiap@gmail.com>
. ${R}etc/init.d/rc.vtol_defaults
PX4_SIMULATOR=${PX4_SIMULATOR:=sihsim}
PX4_SIM_MODEL=${PX4_SIM_MODEL:=xvert}
param set-default VT_ELEV_MC_LOCK 0
param set-default VT_TYPE 0
param set-default VT_FW_DIFTHR_EN 1
param set-default VT_FW_DIFTHR_S_Y 0.3
param set-default MPC_MAN_Y_MAX 60
param set-default MC_PITCH_P 5
param set-default MAV_TYPE 19
# disable some checks to allow to fly:
# - with usb
param set-default CBRK_USB_CHK 197848
# - without real battery
param set-default CBRK_SUPPLY_CHK 894281
# - without safety switch
param set-default COM_PREARM_MODE 0
param set-default CBRK_IO_SAFETY 22027
param set-default BAT_N_CELLS 3
param set-default SIH_T_MAX 2.0
param set-default SIH_Q_MAX 0.0165
param set-default SIH_MASS 0.2
# IXX and IZZ are inverted from the thesis as the body frame is pitched by 90 deg
param set-default SIH_IXX 0.00354
param set-default SIH_IYY 0.000625
param set-default SIH_IZZ 0.00300
param set-default SIH_IXZ 0.0
param set-default SIH_KDV 0.2
param set-default SIH_L_ROLL 0.145
# sih as tailsitter
param set-default SIH_VEHICLE_TYPE 2
param set-default CA_AIRFRAME 4
param set-default CA_ROTOR_COUNT 2
param set-default CA_ROTOR0_PX 0
param set-default CA_ROTOR0_PY 2
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX 0
param set-default CA_ROTOR1_PY -1
param set-default CA_ROTOR1_KM 0.05
param set-default CA_SV_CS_COUNT 2
param set-default CA_SV_CS0_TYPE 5
param set-default CA_SV_CS0_TRQ_P 0.5
param set-default CA_SV_CS0_TRQ_Y -0.5
param set-default CA_SV_CS1_TYPE 6
param set-default CA_SV_CS1_TRQ_P 0.5
param set-default CA_SV_CS1_TRQ_Y 0.5
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC5 201
param set-default PWM_MAIN_FUNC6 202
@@ -1,45 +0,0 @@
#!/bin/sh
#
# @name SIH Tailsitter Duo
#
# @type VTOL
#
# @maintainer Romain Chiappinelli <romain.chiap@gmail.com>
. ${R}etc/init.d/rc.vtol_defaults
param set-default VT_ELEV_MC_LOCK 0
param set-default VT_TYPE 0
param set-default VT_FW_DIFTHR_EN 1
param set-default VT_FW_DIFTHR_SC 0.3
param set-default MPC_MAN_Y_MAX 60
param set-default MC_PITCH_P 5
param set-default MAV_TYPE 19
set MAV_TYPE 19
set MIXER vtol_tailsitter_duo_sat
# disable some checks to allow to fly:
# - with usb
param set-default CBRK_USB_CHK 197848
# - without real battery
param set-default CBRK_SUPPLY_CHK 894281
# - without safety switch
param set-default COM_PREARM_MODE 0
param set-default CBRK_IO_SAFETY 22027
param set-default BAT_N_CELLS 3
param set SIH_T_MAX 2.0
param set SIH_Q_MAX 0.0165
param set SIH_MASS 0.2
# IXX and IZZ are inverted from the thesis as the body frame is pitched by 90 deg
param set SIH_IXX 0.00354
param set SIH_IYY 0.000625
param set SIH_IZZ 0.00300
param set SIH_IXZ 0.0
param set SIH_KDV 0.2
param set SIH_L_ROLL 0.145
# sih as tailsitter
param set SIH_VEHICLE_TYPE 2
@@ -0,0 +1,47 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Optical Flow)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d/rc.mc_defaults
param set-default CA_AIRFRAME 0
param set-default CA_ROTOR_COUNT 4
param set-default CA_ROTOR0_PX 0.1515
param set-default CA_ROTOR0_PY 0.245
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX -0.1515
param set-default CA_ROTOR1_PY -0.1875
param set-default CA_ROTOR1_KM 0.05
param set-default CA_ROTOR2_PX 0.1515
param set-default CA_ROTOR2_PY -0.245
param set-default CA_ROTOR2_KM -0.05
param set-default CA_ROTOR3_PX -0.1515
param set-default CA_ROTOR3_PY 0.1875
param set-default CA_ROTOR3_KM -0.05
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
# EKF2
param set-default EKF2_AID_MASK 2
param set-default EKF2_GPS_CTRL 0
param set-default EKF2_EVP_NOISE 0.05
param set-default EKF2_EVA_NOISE 0.05
# LPE: Flow-only mode
param set-default LPE_FUSION 242
param set-default LPE_FAKE_ORIGIN 1
param set-default MPC_ALT_MODE 2
param set-default SENS_FLOW_ROT 6
param set-default SENS_FLOW_MINHGT 0.7
param set-default SENS_FLOW_MAXHGT 3.0
param set-default SENS_FLOW_MAXR 2.5
@@ -1,24 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Optical Flow)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
# EKF2
param set-default EKF2_AID_MASK 2
param set-default EKF2_EVP_NOISE 0.05
param set-default EKF2_EVA_NOISE 0.05
# LPE: Flow-only mode
param set-default LPE_FUSION 242
param set-default LPE_FAKE_ORIGIN 1
param set-default MPC_ALT_MODE 2
param set-default SENS_FLOW_ROT 6
param set-default SENS_FLOW_MINHGT 0.7
param set-default SENS_FLOW_MAXHGT 3.0
param set-default SENS_FLOW_MAXR 2.5
@@ -0,0 +1,38 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (irlock)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d/rc.mc_defaults
param set-default CA_AIRFRAME 0
param set-default CA_ROTOR_COUNT 4
param set-default CA_ROTOR0_PX 0.1515
param set-default CA_ROTOR0_PY 0.245
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX -0.1515
param set-default CA_ROTOR1_PY -0.1875
param set-default CA_ROTOR1_KM 0.05
param set-default CA_ROTOR2_PX 0.1515
param set-default CA_ROTOR2_PY -0.245
param set-default CA_ROTOR2_KM -0.05
param set-default CA_ROTOR3_PX -0.1515
param set-default CA_ROTOR3_PY 0.1875
param set-default CA_ROTOR3_KM -0.05
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
# enable fusion of landing target velocity
param set-default LTEST_MODE 1
param set-default PLD_HACC_RAD 0.1
param set-default RTL_PLD_MD 2
# Start up Landing Target Estimator module
landing_target_estimator start
@@ -1,16 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (irlock)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
# enable fusion of landing target velocity
param set-default LTEST_MODE 1
param set-default PLD_HACC_RAD 0.1
param set-default RTL_PLD_MD 2
# Start up Landing Target Estimator module
landing_target_estimator start
@@ -0,0 +1,33 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (rplidar)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d/rc.mc_defaults
param set-default CA_AIRFRAME 0
param set-default CA_ROTOR_COUNT 4
param set-default CA_ROTOR0_PX 0.1515
param set-default CA_ROTOR0_PY 0.245
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX -0.1515
param set-default CA_ROTOR1_PY -0.1875
param set-default CA_ROTOR1_KM 0.05
param set-default CA_ROTOR2_PX 0.1515
param set-default CA_ROTOR2_PY -0.245
param set-default CA_ROTOR2_KM -0.05
param set-default CA_ROTOR3_PX -0.1515
param set-default CA_ROTOR3_PY 0.1875
param set-default CA_ROTOR3_KM -0.05
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
param set-default LPE_FUSION 242
@@ -1,11 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (rplidar)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
param set-default LPE_FUSION 242
@@ -10,6 +10,8 @@
# EKF2: Vision position and heading
param set-default EKF2_AID_MASK 24
param set-default EKF2_EV_DELAY 5
param set-default EKF2_EV_CTRL 15
param set-default EKF2_GPS_CTRL 0
# LPE: Vision + baro
param set-default LPE_FUSION 132
@@ -1,13 +0,0 @@
#!/bin/sh
#
# @name Solo
#
# @type Quadrotor
#
. ${R}etc/init.d/rc.mc_defaults
param set-default MC_PITCHRATE_P 0.1
param set-default MC_ROLLRATE_P 0.05
set MIXER quad_x
@@ -0,0 +1,34 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Obstacle Avoidance)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d/rc.mc_defaults
param set-default CA_AIRFRAME 0
param set-default CA_ROTOR_COUNT 4
param set-default CA_ROTOR0_PX 0.1515
param set-default CA_ROTOR0_PY 0.245
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX -0.1515
param set-default CA_ROTOR1_PY -0.1875
param set-default CA_ROTOR1_KM 0.05
param set-default CA_ROTOR2_PX 0.1515
param set-default CA_ROTOR2_PY -0.245
param set-default CA_ROTOR2_KM -0.05
param set-default CA_ROTOR3_PX -0.1515
param set-default CA_ROTOR3_PY 0.1875
param set-default CA_ROTOR3_KM -0.05
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
param set-default COM_OBS_AVOID 1
param set-default MPC_XY_CRUISE 5.0
@@ -1,12 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Obstacle Avoidance)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
param set-default COM_OBS_AVOID 1
param set-default MPC_XY_CRUISE 5.0
@@ -0,0 +1,40 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Optical Flow)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d/rc.mc_defaults
param set-default CA_AIRFRAME 0
param set-default CA_ROTOR_COUNT 4
param set-default CA_ROTOR0_PX 0.1515
param set-default CA_ROTOR0_PY 0.245
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX -0.1515
param set-default CA_ROTOR1_PY -0.1875
param set-default CA_ROTOR1_KM 0.05
param set-default CA_ROTOR2_PX 0.1515
param set-default CA_ROTOR2_PY -0.245
param set-default CA_ROTOR2_KM -0.05
param set-default CA_ROTOR3_PX -0.1515
param set-default CA_ROTOR3_PY 0.1875
param set-default CA_ROTOR3_KM -0.05
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
# EKF2
param set-default EKF2_AID_MASK 2
param set-default EKF2_GPS_CTRL 0
# LPE: Flow-only mode
param set-default LPE_FUSION 242
param set-default LPE_FAKE_ORIGIN 1
param set-default MPC_ALT_MODE 2
@@ -1,17 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Optical Flow)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
# EKF2
param set-default EKF2_AID_MASK 2
# LPE: Flow-only mode
param set-default LPE_FUSION 242
param set-default LPE_FAKE_ORIGIN 1
param set-default MPC_ALT_MODE 2
@@ -1,12 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Vision Velocity)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
# EKF2: Vision velocity and heading
param set-default EKF2_AID_MASK 272
param set-default EKF2_EV_DELAY 5
@@ -0,0 +1,33 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Dual GPS)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d/rc.mc_defaults
param set-default CA_AIRFRAME 0
param set-default CA_ROTOR_COUNT 4
param set-default CA_ROTOR0_PX 0.1515
param set-default CA_ROTOR0_PY 0.245
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX -0.1515
param set-default CA_ROTOR1_PY -0.1875
param set-default CA_ROTOR1_KM 0.05
param set-default CA_ROTOR2_PX 0.1515
param set-default CA_ROTOR2_PY -0.245
param set-default CA_ROTOR2_KM -0.05
param set-default CA_ROTOR3_PX -0.1515
param set-default CA_ROTOR3_PY 0.1875
param set-default CA_ROTOR3_KM -0.05
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
# EKF2: Multi GPS blending
param set-default SENS_GPS_MASK 7
@@ -1,11 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Dual GPS)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
# EKF2: Multi GPS blending
param set-default SENS_GPS_MASK 7
@@ -1,12 +0,0 @@
#!/bin/sh
#
# @name UUV
#
. ${R}etc/init.d/rc.uuv_defaults
# disable circuit breaker for airspeed sensor
param set-default CBRK_AIRSPD_CHK 162128
set MIXER_FILE etc/mixers-sitl/uuv_x_sitl.main.mix
set MIXER custom
@@ -0,0 +1,47 @@
#!/bin/sh
#
# @name Hippocampus UUV
#
. ${R}etc/init.d/rc.uuv_defaults
# disable circuit breaker for airspeed sensor
param set-default CBRK_AIRSPD_CHK 162128
param set-default CA_AIRFRAME 7
param set-default CA_ROTOR_COUNT 4
param set-default CA_R_REV 255
param set-default CA_ROTOR0_AX 1.0000
param set-default CA_ROTOR0_AY 0.0000
param set-default CA_ROTOR0_AZ 0.0000
param set-default CA_ROTOR0_KM 0.0000
param set-default CA_ROTOR0_PX 0.0000
param set-default CA_ROTOR0_PY -0.3000
param set-default CA_ROTOR0_PZ -0.3000
param set-default CA_ROTOR1_AX 1.0000
param set-default CA_ROTOR1_AY 0.0000
param set-default CA_ROTOR1_AZ 0.0000
param set-default CA_ROTOR1_KM 0.0000
param set-default CA_ROTOR1_PX 0.0000
param set-default CA_ROTOR1_PY 0.3000
param set-default CA_ROTOR1_PZ -0.3000
param set-default CA_ROTOR2_AX 1.0000
param set-default CA_ROTOR2_AY 0.0000
param set-default CA_ROTOR2_AZ 0.0000
param set-default CA_ROTOR2_KM 0.0000
param set-default CA_ROTOR2_PX 0.0000
param set-default CA_ROTOR2_PY 0.3000
param set-default CA_ROTOR2_PZ 0.3000
param set-default CA_ROTOR3_AX 1.0000
param set-default CA_ROTOR3_AY 0.0000
param set-default CA_ROTOR3_AZ 0.0000
param set-default CA_ROTOR3_KM 0.0000
param set-default CA_ROTOR3_PX 0.0000
param set-default CA_ROTOR3_PY -0.3000
param set-default CA_ROTOR3_PZ 0.3000
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
@@ -1,12 +0,0 @@
#!/bin/sh
#
# @name Hippocampus UUV
#
. ${R}etc/init.d/rc.uuv_defaults
# disable circuit breaker for airspeed sensor
param set-default CBRK_AIRSPD_CHK 162128
set MIXER_FILE etc/mixers-sitl/uuv_x_sitl.main.mix
set MIXER custom
@@ -8,7 +8,6 @@
# disable circuit breaker for airspeed sensor
param set-default CBRK_AIRSPD_CHK 162128
param set-default SYS_CTRL_ALLOC 1
param set-default CA_AIRFRAME 7
param set-default CA_ROTOR_COUNT 8
@@ -66,4 +65,3 @@ param set-default PWM_MAIN_FUNC6 106
param set-default PWM_MAIN_FUNC7 107
param set-default PWM_MAIN_FUNC8 108
set MIXER skip
@@ -0,0 +1,75 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
param set-default EKF2_MAG_ACCLIM 0
param set-default EKF2_MAG_YAWLIM 0
param set-default FW_LND_ANG 8
param set-default FW_L1_PERIOD 12
param set-default FW_PR_P 0.9
param set-default FW_PR_FF 0.5
param set-default FW_PR_I 0.5
param set-default TRIM_PITCH -0.15
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.5
param set-default FW_RR_P 0.3
param set-default FW_RR_I 0.5
param set-default FW_YR_FF 0.5
param set-default FW_YR_P 0.6
param set-default FW_YR_I 0.5
param set-default FW_SPOILERS_LND 0.4
param set-default FW_THR_MAX 0.6
param set-default FW_THR_MIN 0.05
param set-default FW_THR_TRIM 0.25
param set-default FW_T_CLMB_MAX 8
param set-default FW_T_SINK_MAX 2.7
param set-default FW_T_SINK_MIN 2.2
param set-default FW_W_EN 1
param set-default MIS_TAKEOFF_ALT 30
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
@@ -0,0 +1,81 @@
#!/bin/sh
#
# @name Plane SITL with camera
#
. ${R}etc/init.d/rc.fw_defaults
param set-default EKF2_MAG_ACCLIM 0
param set-default EKF2_MAG_YAWLIM 0
param set-default FW_LND_AIRSPD_SC 1
param set-default FW_LND_ANG 8
param set-default FW_L1_PERIOD 12
param set-default FW_PR_P 0.9
param set-default FW_PR_FF 0.5
param set-default FW_PR_I 0.5
param set-default TRIM_PITCH -0.15
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.5
param set-default FW_RR_P 0.3
param set-default FW_RR_I 0.5
param set-default FW_YR_FF 0.5
param set-default FW_YR_P 0.6
param set-default FW_YR_I 0.5
param set-default FW_SPOILERS_LND 0.4
param set-default FW_THR_MAX 0.6
param set-default FW_THR_MIN 0.05
param set-default FW_THR_TRIM 0.25
param set-default FW_T_CLMB_MAX 8
param set-default FW_T_SINK_MAX 2.7
param set-default FW_T_SINK_MIN 2.2
param set-default FW_W_EN 1
param set-default MIS_LTRMIN_ALT 30
param set-default MIS_TAKEOFF_ALT 30
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
# Camera trigger interface is MAVLink
param set-default TRIG_INTERFACE 3
# Distance trigger mode enabled
param set-default TRIG_MODE 4
@@ -1,12 +0,0 @@
#!/bin/sh
#
# @name Plane SITL with camera
#
. ${R}etc/init.d-posix/airframes/1030_plane
# Camera trigger interface is MAVLink
param set-default TRIG_INTERFACE 3
# Distance trigger mode enabled
param set-default TRIG_MODE 4
@@ -0,0 +1,78 @@
#!/bin/sh
#
# @name Plane SITL with catapult
#
. ${R}etc/init.d/rc.fw_defaults
param set-default EKF2_MAG_ACCLIM 0
param set-default EKF2_MAG_YAWLIM 0
param set-default FW_LND_AIRSPD_SC 1
param set-default FW_LND_ANG 8
param set-default FW_L1_PERIOD 12
param set-default FW_PR_P 0.9
param set-default FW_PR_FF 0.5
param set-default FW_PR_I 0.5
param set-default TRIM_PITCH -0.15
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.5
param set-default FW_RR_P 0.3
param set-default FW_RR_I 0.5
param set-default FW_YR_FF 0.5
param set-default FW_YR_P 0.6
param set-default FW_YR_I 0.5
param set-default FW_SPOILERS_LND 0.4
param set-default FW_THR_MAX 0.6
param set-default FW_THR_MIN 0.05
param set-default FW_THR_TRIM 0.25
param set-default FW_T_CLMB_MAX 8
param set-default FW_T_SINK_MAX 2.7
param set-default FW_T_SINK_MIN 2.2
param set-default FW_W_EN 1
param set-default MIS_LTRMIN_ALT 30
param set-default MIS_TAKEOFF_ALT 30
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
param set-default RWTO_TKOFF 0
@@ -1,9 +0,0 @@
#!/bin/sh
#
# @name Plane SITL with catapult
#
. ${R}etc/init.d-posix/airframes/1030_plane
param set-default RWTO_TKOFF 0
@@ -0,0 +1,60 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
param set-default FW_LND_ANG 5
param set-default FW_LND_FL_PMIN 9.5
param set-default FW_LND_FL_PMAX 20
param set-default FW_LND_FLALT 5
param set-default FW_L1_PERIOD 25
param set-default FW_PR_FF 0.40
param set-default FW_PR_I 0.05
param set-default FW_PR_P 0.05
param set-default FW_R_TC 0.45
param set-default FW_RR_FF 0.40
param set-default FW_RR_I 0.132
param set-default FW_RR_P 0.085
param set-default FW_W_EN 1
param set-default MIS_TAKEOFF_ALT 20
param set-default MIS_DIST_1WP 2500
param set-default MIS_DIST_WPS 10000
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default RWTO_PSP 8
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
@@ -1,9 +0,0 @@
#!/bin/sh
#
# @name Plane SITL with downward facing LIDAR.
#
. ${R}etc/init.d-posix/airframes/1030_plane
param set-default FW_LND_USETER 1
@@ -0,0 +1,59 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
param set-default FW_LND_ANG 5
param set-default FW_LND_FL_PMIN 9.5
param set-default FW_LND_FL_PMAX 20
param set-default FW_LND_FLALT 5
param set-default FW_L1_PERIOD 25
param set-default FW_PR_FF 0.40
param set-default FW_PR_I 0.05
param set-default FW_PR_P 0.05
param set-default FW_R_TC 0.45
param set-default FW_RR_FF 0.40
param set-default FW_RR_I 0.132
param set-default FW_RR_P 0.085
param set-default FW_W_EN 1
param set-default MIS_TAKEOFF_ALT 20
param set-default MIS_DIST_1WP 2500
param set-default MIS_DIST_WPS 10000
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default RWTO_PSP 8
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
@@ -1,43 +0,0 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
param set-default FW_LND_AIRSPD_SC 1.1
param set-default FW_LND_ANG 5
param set-default FW_LND_FL_PMIN 9.5
param set-default FW_LND_FL_PMAX 20
param set-default FW_LND_FLALT 5
param set-default FW_L1_PERIOD 25
param set-default FW_PR_FF 0.40
param set-default FW_PR_I 0.05
param set-default FW_PR_P 0.05
param set-default FW_R_TC 0.45
param set-default FW_RR_FF 0.40
param set-default FW_RR_I 0.132
param set-default FW_RR_P 0.085
param set-default FW_W_EN 1
param set-default MIS_LTRMIN_ALT 30
param set-default MIS_TAKEOFF_ALT 20
param set-default MIS_DIST_1WP 2500
param set-default MIS_DIST_WPS 10000
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default RWTO_MAX_PITCH 20
param set-default RWTO_PSP 8
param set-default RWTO_AIRSPD_SCL 1.8
set MIXER_FILE etc/mixers-sitl/plane_sitl.main.mix
set MIXER custom
@@ -0,0 +1,60 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
param set-default EKF2_MAG_ACCLIM 0
param set-default EKF2_MAG_YAWLIM 0
param set-default FW_LND_ANG 8
param set-default FW_L1_PERIOD 15
param set-default FW_P_TC 0.5
param set-default FW_PR_FF 0.40
param set-default FW_PR_I 0.05
param set-default FW_PR_P 0.05
param set-default FW_R_TC 0.7
param set-default FW_RR_FF 0.20
param set-default FW_RR_I 0.02
param set-default FW_RR_P 0.22
param set-default FW_L1_PERIOD 12
param set-default FW_W_EN 1
param set-default MIS_TAKEOFF_ALT 30
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
@@ -1,39 +0,0 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
param set-default EKF2_MAG_ACCLIM 0
param set-default EKF2_MAG_YAWLIM 0
param set-default FW_LND_AIRSPD_SC 1
param set-default FW_LND_ANG 8
param set-default FW_L1_PERIOD 15
param set-default FW_P_TC 0.5
param set-default FW_PR_FF 0.40
param set-default FW_PR_I 0.05
param set-default FW_PR_P 0.05
param set-default FW_R_TC 0.7
param set-default FW_RR_FF 0.20
param set-default FW_RR_I 0.02
param set-default FW_RR_P 0.22
param set-default FW_L1_PERIOD 12
param set-default FW_W_EN 1
param set-default MIS_LTRMIN_ALT 30
param set-default MIS_TAKEOFF_ALT 30
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
set MIXER_FILE etc/mixers-sitl/plane_sitl.main.mix
set MIXER custom
@@ -0,0 +1,60 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
param set-default FW_LND_ANG 5
param set-default FW_LND_FL_PMIN 9.5
param set-default FW_LND_FL_PMAX 20
param set-default FW_LND_FLALT 5
param set-default FW_L1_PERIOD 25
param set-default FW_PR_FF 0.40
param set-default FW_PR_I 0.05
param set-default FW_PR_P 0.05
param set-default FW_R_TC 0.45
param set-default FW_RR_FF 0.40
param set-default FW_RR_I 0.132
param set-default FW_RR_P 0.085
param set-default FW_W_EN 1
param set-default MIS_TAKEOFF_ALT 20
param set-default MIS_DIST_1WP 2500
param set-default MIS_DIST_WPS 10000
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default RWTO_PSP 8
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
@@ -1,41 +0,0 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
param set-default FW_LND_AIRSPD_SC 1.1
param set-default FW_LND_ANG 5
param set-default FW_LND_FL_PMIN 9.5
param set-default FW_LND_FL_PMAX 20
param set-default FW_LND_FLALT 5
param set-default FW_L1_PERIOD 25
param set-default FW_PR_FF 0.40
param set-default FW_PR_I 0.05
param set-default FW_PR_P 0.05
param set-default FW_R_TC 0.45
param set-default FW_RR_FF 0.40
param set-default FW_RR_I 0.132
param set-default FW_RR_P 0.085
param set-default FW_W_EN 1
param set-default MIS_LTRMIN_ALT 30
param set-default MIS_TAKEOFF_ALT 20
param set-default MIS_DIST_1WP 2500
param set-default MIS_DIST_WPS 10000
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default RWTO_MAX_PITCH 20
param set-default RWTO_PSP 8
param set-default RWTO_AIRSPD_SCL 1.8
set MIXER_FILE etc/mixers-sitl/plane_sitl.main.mix
set MIXER custom
@@ -8,17 +8,13 @@
param set-default EKF2_MAG_ACCLIM 0
param set-default EKF2_MAG_YAWLIM 0
param set-default FW_LND_AIRSPD_SC 1
param set-default FW_LND_ANG 8
param set-default FW_L1_PERIOD 12
param set-default FW_MAN_P_MAX 30
param set-default FW_PR_P 0.9
param set-default FW_PR_FF 0.2
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MAX 32
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.1
@@ -37,15 +33,35 @@ param set-default FW_T_TAS_TC 2
param set-default FW_W_EN 1
param set-default MIS_LTRMIN_ALT 30
param set-default MIS_TAKEOFF_ALT 30
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default FW_USE_NPFG 1
param set-default RWTO_TKOFF 1
set MIXER_FILE etc/mixers-sitl/plane_sitl.main.mix
set MIXER custom
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
@@ -0,0 +1,78 @@
#!/bin/sh
#
# @name Plane SITL with catapult
#
. ${R}etc/init.d/rc.fw_defaults
param set-default EKF2_MAG_ACCLIM 0
param set-default EKF2_MAG_YAWLIM 0
param set-default FW_LND_AIRSPD_SC 1
param set-default FW_LND_ANG 8
param set-default FW_L1_PERIOD 12
param set-default FW_PR_P 0.9
param set-default FW_PR_FF 0.5
param set-default FW_PR_I 0.5
param set-default TRIM_PITCH -0.15
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.5
param set-default FW_RR_P 0.3
param set-default FW_RR_I 0.5
param set-default FW_YR_FF 0.5
param set-default FW_YR_P 0.6
param set-default FW_YR_I 0.5
param set-default FW_SPOILERS_LND 0.4
param set-default FW_THR_MAX 0.6
param set-default FW_THR_MIN 0.05
param set-default FW_THR_TRIM 0.25
param set-default FW_T_CLMB_MAX 8
param set-default FW_T_SINK_MAX 2.7
param set-default FW_T_SINK_MIN 2.2
param set-default FW_W_EN 1
param set-default MIS_LTRMIN_ALT 30
param set-default MIS_TAKEOFF_ALT 30
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
param set-default FW_THR_TRIM 0.0
param set-default RWTO_TKOFF 0
@@ -1,9 +0,0 @@
#!/bin/sh
#
# @name Plane SITL with catapult
#
. ${R}etc/init.d-posix/airframes/1030_plane
param set-default FW_THR_TRIM 0.0
param set-default RWTO_TKOFF 0
@@ -39,6 +39,27 @@ param set-default RWTO_MAX_PITCH 20
param set-default RWTO_PSP 8
param set-default RWTO_AIRSPD_SCL 1.8
param set-default CA_AIRFRAME 1
set MIXER_FILE etc/mixers-sitl/plane_sitl.main.mix
set MIXER custom
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
@@ -1,6 +1,6 @@
#!/bin/sh
#
# @name Plane SITL
# @name Advanced Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
@@ -8,25 +8,19 @@
param set-default EKF2_MAG_ACCLIM 0
param set-default EKF2_MAG_YAWLIM 0
param set-default FW_LND_AIRSPD_SC 1
param set-default FW_LND_ANG 8
param set-default FW_THR_LND_MAX 0
param set-default FW_L1_PERIOD 12
param set-default FW_MAN_P_MAX 30
param set-default FW_PR_P 0.9
param set-default FW_PR_FF 0.2
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MAX 32
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.1
param set-default FW_RR_P 0.3
param set-default FW_SPOILERS_LND 0.4
param set-default FW_THR_MAX 0.6
param set-default FW_THR_MIN 0.05
param set-default FW_THR_TRIM 0.25
@@ -36,7 +30,6 @@ param set-default FW_T_SINK_MIN 2.2
param set-default FW_W_EN 1
param set-default MIS_LTRMIN_ALT 30
param set-default MIS_TAKEOFF_ALT 30
param set-default NAV_ACC_RAD 15
@@ -0,0 +1,82 @@
#!/bin/sh
#
# @name Standard VTOL
#
# @type Standard VTOL
#
. ${R}etc/init.d/rc.vtol_defaults
# TODO: Enable motor failure detection when the
# VTOL no longer reports 0A for all ESCs in SITL
param set-default FD_ACT_EN 0
param set-default FD_ACT_MOT_TOUT 500
param set-default CA_AIRFRAME 2
param set-default CA_ROTOR_COUNT 5
param set-default CA_ROTOR0_PX 0.1515
param set-default CA_ROTOR0_PY 0.245
param set-default CA_ROTOR0_KM 0.05
param set-default CA_ROTOR1_PX -0.1515
param set-default CA_ROTOR1_PY -0.1875
param set-default CA_ROTOR1_KM 0.05
param set-default CA_ROTOR2_PX 0.1515
param set-default CA_ROTOR2_PY -0.245
param set-default CA_ROTOR2_KM -0.05
param set-default CA_ROTOR3_PX -0.1515
param set-default CA_ROTOR3_PY 0.1875
param set-default CA_ROTOR3_KM -0.05
param set-default CA_ROTOR4_AX 1.0
param set-default CA_ROTOR4_AZ 0.0
param set-default CA_ROTOR4_PX 0.2
param set-default CA_SV_CS_COUNT 3
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
param set-default PWM_MAIN_FUNC5 105
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default FW_L1_PERIOD 12
param set-default FW_PR_FF 0.2
param set-default FW_PR_P 0.9
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.1
param set-default FW_RR_P 0.3
param set-default FW_THR_TRIM 0.25
param set-default FW_THR_MAX 0.6
param set-default FW_THR_MIN 0.05
param set-default FW_T_CLMB_MAX 8
param set-default FW_T_SINK_MAX 2.7
param set-default FW_T_SINK_MIN 2.2
param set-default MC_AIRMODE 1
param set-default MC_ROLLRATE_P 0.3
param set-default MC_YAW_P 1.6
param set-default MIS_TAKEOFF_ALT 10
param set-default MPC_ACC_HOR_MAX 2
param set-default MPC_XY_P 0.8
param set-default MPC_XY_VEL_P_ACC 3
param set-default MPC_XY_VEL_I_ACC 4
param set-default MPC_XY_VEL_D_ACC 0.1
param set-default NAV_ACC_RAD 5
param set-default VT_FWD_THRUST_EN 4
param set-default VT_F_TRANS_THR 0.75
param set-default VT_B_TRANS_DUR 8
param set-default VT_TYPE 2
@@ -9,7 +9,6 @@
param set-default MAV_TYPE 20
# param set-default SYS_CTRL_ALLOC 1
param set-default CA_AIRFRAME 4
param set-default CA_ROTOR_COUNT 4
@@ -44,11 +43,9 @@ param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_REV 96 # invert both elevons
param set-default FW_L1_PERIOD 12
param set-default FW_MAN_P_MAX 30
param set-default FW_PR_I 0.2
param set-default FW_PR_P 0.2
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MAX 32
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_P 0.2
param set-default FW_THR_TRIM 0.33
@@ -61,6 +58,7 @@ param set-default FW_T_SINK_MAX 2.7
param set-default FW_T_SINK_MIN 2.2
param set-default FW_T_TAS_TC 2
param set-default MC_AIRMODE 1
param set-default MC_ROLLRATE_P 0.3
param set-default MPC_ACC_HOR_MAX 2
@@ -72,12 +70,10 @@ param set-default MPC_XY_VEL_D_ACC 0.1
param set-default NAV_ACC_RAD 5
param set-default VT_FW_DIFTHR_EN 1
param set-default VT_FW_DIFTHR_SC 0.5
param set-default VT_FW_DIFTHR_S_Y 0.5
param set-default VT_F_TRANS_DUR 1.5
param set-default VT_F_TRANS_THR 0.7
param set-default VT_TYPE 0
param set-default WV_EN 0
set MIXER_FILE etc/mixers-sitl/quad_x_vtol.main.mix
set MIXER custom
@@ -9,7 +9,6 @@
param set-default MAV_TYPE 21
param set-default SYS_CTRL_ALLOC 1
param set-default CA_AIRFRAME 3
param set-default CA_ROTOR_COUNT 4
@@ -27,9 +26,7 @@ param set-default CA_ROTOR3_PY 0.1875
param set-default CA_ROTOR3_KM -0.05
param set-default CA_ROTOR0_TILT 1
param set-default CA_ROTOR1_TILT 2
param set-default CA_ROTOR2_TILT 3
param set-default CA_ROTOR3_TILT 4
param set-default CA_ROTOR2_TILT 2
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
@@ -37,11 +34,7 @@ param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS_COUNT 3
param set-default CA_SV_TL0_CT 0
param set-default CA_SV_TL1_CT 0
param set-default CA_SV_TL2_CT 0
param set-default CA_SV_TL3_CT 0
param set-default CA_SV_TL_COUNT 4
param set-default CA_SV_TL_COUNT 2
param set-default PWM_MAIN_FUNC1 101
param set-default PWM_MAIN_FUNC2 102
@@ -49,18 +42,14 @@ param set-default PWM_MAIN_FUNC3 103
param set-default PWM_MAIN_FUNC4 104
param set-default PWM_MAIN_FUNC5 204
param set-default PWM_MAIN_FUNC6 205
param set-default PWM_MAIN_FUNC7 206
param set-default PWM_MAIN_FUNC8 207
param set-default PWM_MAIN_FUNC9 201
param set-default PWM_MAIN_FUNC10 202
param set-default PWM_MAIN_FUNC11 203
param set-default PWM_MAIN_FUNC7 201
param set-default PWM_MAIN_FUNC8 202
param set-default PWM_MAIN_FUNC9 203
param set-default FW_L1_PERIOD 12
param set-default FW_MAN_P_MAX 30
param set-default FW_PR_FF 0.2
param set-default FW_PR_P 0.9
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MAX 32
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.1
param set-default FW_RR_P 0.3
@@ -71,23 +60,18 @@ param set-default FW_T_CLMB_MAX 8
param set-default FW_T_SINK_MAX 2.7
param set-default FW_T_SINK_MIN 2.2
param set-default MC_YAW_P 1.6
param set-default MC_AIRMODE 1
param set-default MC_YAWRATE_P 0.3
param set-default MC_YAWRATE_I 0.3
param set-default MIS_TAKEOFF_ALT 10
param set-default MPC_ACC_HOR_MAX 2
param set-default MPC_XY_P 0.8
param set-default MPC_XY_VEL_P_ACC 3
param set-default MPC_XY_VEL_I_ACC 4
param set-default MPC_XY_VEL_D_ACC 0.1
param set-default NAV_ACC_RAD 5
param set-default MIS_TAKEOFF_ALT 10
param set-default VT_B_TRANS_DUR 8
param set-default VT_FWD_THRUST_EN 4
param set-default VT_MOT_ID 1234
param set-default VT_FWD_THRUST_SC 0.6
param set-default VT_TILT_TRANS 0.6
param set-default VT_TYPE 1
set MIXER_FILE etc/mixers-sitl/tiltrotor_sitl.main.mix
set MIXER custom
@@ -12,7 +12,6 @@
param set-default FD_ACT_EN 0
param set-default FD_ACT_MOT_TOUT 500
# param set-default SYS_CTRL_ALLOC 1
param set-default CA_AIRFRAME 2
param set-default CA_ROTOR_COUNT 5
@@ -49,11 +48,9 @@ param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default FW_L1_PERIOD 12
param set-default FW_MAN_P_MAX 30
param set-default FW_PR_FF 0.2
param set-default FW_PR_P 0.9
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MAX 32
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.1
param set-default FW_RR_P 0.3
@@ -84,5 +81,13 @@ param set-default VT_FW_MOT_OFFID 1234
param set-default VT_B_TRANS_DUR 8
param set-default VT_TYPE 2
set MIXER_FILE etc/mixers-sitl/standard_vtol_sitl.main.mix
set MIXER custom
# Gimbal
param set-default PWM_MAIN_FUNC9 420
param set-default PWM_MAIN_FUNC10 421
param set-default PWM_MAIN_FUNC11 422
param set-default RC_MAP_AUX1 8
param set-default RC_MAP_AUX2 9
param set-default RC_MAP_AUX3 10
@@ -1,54 +0,0 @@
#!/bin/sh
#
# @name Standard VTOL
#
# @type Standard VTOL
#
. ${R}etc/init.d/rc.vtol_defaults
param set-default FW_L1_PERIOD 12
param set-default FW_MAN_P_MAX 30
param set-default FW_PR_FF 0.2
param set-default FW_PR_P 0.9
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MAX 32
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.1
param set-default FW_RR_P 0.3
param set-default FW_THR_TRIM 0.25
param set-default FW_THR_MAX 0.6
param set-default FW_THR_MIN 0.05
param set-default FW_T_ALT_TC 2
param set-default FW_T_CLMB_MAX 8
param set-default FW_T_HRATE_FF 0.5
param set-default FW_T_SINK_MAX 2.7
param set-default FW_T_SINK_MIN 2.2
param set-default FW_T_TAS_TC 2
param set-default MC_ROLLRATE_P 0.3
param set-default MC_YAW_P 1.6
param set-default MIS_TAKEOFF_ALT 10
param set-default MPC_ACC_HOR_MAX 2
param set-default MPC_XY_P 0.8
param set-default MPC_XY_VEL_P_ACC 3
param set-default MPC_XY_VEL_I_ACC 4
param set-default MPC_XY_VEL_D_ACC 0.1
param set-default NAV_ACC_RAD 5
param set-default VT_FWD_THRUST_EN 4
param set-default VT_F_TRANS_THR 0.75
param set-default VT_MOT_ID 1234
param set-default VT_FW_MOT_OFFID 1234
param set-default VT_B_TRANS_DUR 8
param set-default VT_TYPE 2
param set-default RC_MAP_AUX1 8
param set-default RC_MAP_AUX2 9
param set-default RC_MAP_AUX3 10
set MIXER_FILE etc/mixers-sitl/standard_vtol_sitl.main.mix
set MIXER custom
@@ -1 +0,0 @@
mixer append /dev/pwm_output0 etc/mixers-sitl/package_drop.aux.mix
@@ -0,0 +1,78 @@
#!/bin/sh
#
# @name Plane SITL with downward facing LIDAR.
#
. ${R}etc/init.d/rc.fw_defaults
param set-default EKF2_MAG_ACCLIM 0
param set-default EKF2_MAG_YAWLIM 0
param set-default FW_LND_AIRSPD_SC 1
param set-default FW_LND_ANG 8
param set-default FW_L1_PERIOD 12
param set-default FW_PR_P 0.9
param set-default FW_PR_FF 0.5
param set-default FW_PR_I 0.5
param set-default TRIM_PITCH -0.15
param set-default FW_PSP_OFF 2
param set-default FW_P_LIM_MIN -15
param set-default FW_RR_FF 0.5
param set-default FW_RR_P 0.3
param set-default FW_RR_I 0.5
param set-default FW_YR_FF 0.5
param set-default FW_YR_P 0.6
param set-default FW_YR_I 0.5
param set-default FW_SPOILERS_LND 0.4
param set-default FW_THR_MAX 0.6
param set-default FW_THR_MIN 0.05
param set-default FW_THR_TRIM 0.25
param set-default FW_T_CLMB_MAX 8
param set-default FW_T_SINK_MAX 2.7
param set-default FW_T_SINK_MIN 2.2
param set-default FW_W_EN 1
param set-default MIS_LTRMIN_ALT 30
param set-default MIS_TAKEOFF_ALT 30
param set-default NAV_ACC_RAD 15
param set-default NAV_DLL_ACT 2
param set-default RWTO_TKOFF 1
param set-default CA_AIRFRAME 1
param set-default CA_ROTOR_COUNT 1
param set-default CA_ROTOR0_PX 0.3
param set-default CA_SV_CS_COUNT 6
param set-default CA_SV_CS0_TRQ_R -0.5
param set-default CA_SV_CS0_TYPE 1
param set-default CA_SV_CS1_TRQ_R 0.5
param set-default CA_SV_CS1_TYPE 2
param set-default CA_SV_CS2_TRQ_P 1.0
param set-default CA_SV_CS2_TYPE 3
param set-default CA_SV_CS3_TRQ_Y 1.0
param set-default CA_SV_CS3_TYPE 4
param set-default CA_SV_CS4_TYPE 9
param set-default CA_SV_CS5_TYPE 10
param set-default PWM_MAIN_FUNC3 204
param set-default PWM_MAIN_FUNC4 205
param set-default PWM_MAIN_FUNC5 101
param set-default PWM_MAIN_FUNC6 201
param set-default PWM_MAIN_FUNC7 202
param set-default PWM_MAIN_FUNC8 203
param set-default PWM_MAIN_FUNC9 206
param set-default PWM_MAIN_REV 256
param set-default FW_LND_USETER 1
@@ -18,7 +18,6 @@ param set-default GND_THR_CRUISE 0.3
param set-default GND_THR_MAX 0.5
param set-default GND_THR_MIN 0
param set-default MIS_LTRMIN_ALT 0.01
param set-default MIS_TAKEOFF_ALT 0.01
param set-default NAV_ACC_RAD 0.5
param set-default NAV_LOITER_RAD 2
@@ -28,7 +27,6 @@ param set-default CBRK_AIRSPD_CHK 162128
param set-default GND_MAX_ANG 0.6
param set-default GND_WHEEL_BASE 2.0
param set-default SYS_CTRL_ALLOC 1
param set-default CA_AIRFRAME 5
param set-default CA_R_REV 1
@@ -37,4 +35,3 @@ param set-default PWM_MAIN_FUNC2 201
param set-default PWM_MAIN_FUNC6 101
param set-default PWM_MAIN_FUNC7 101
set MIXER_FILE skip

Some files were not shown because too many files have changed in this diff Show More