Compare commits

...

4308 Commits

Author SHA1 Message Date
Daniel Agar 700961daf2 ModuleBase add common base type and cleanup 2020-11-10 14:03:58 -05:00
Daniel Agar d33a48eb24 systemcmds/topic_listener: remove excludes
- this is a bit wasteful, but we can afford it for now everywhere listener is enabled
2020-11-10 13:46:48 -05:00
Daniel Agar c8dfcf7f0d Github Actions: break up MAVSDK SITL tests
- run only 1 vehicle type per location
2020-11-10 13:11:51 -05:00
SalimTerryLi 6728a3a05a boards: rename AirPi2 to PilotPi, add arm64 support, add to CI
* rename all
* add arm64 support
* change internal ist8310 onto I2C-1
2020-11-10 11:04:47 -05:00
Daniel Agar 38fbb452da vscode add navio2 variant and native debug launch 2020-11-10 10:38:46 -05:00
Nicolas Martin 1965cd38ba arm auth: add parameters migration
should be reverted in v1.13
2020-11-10 09:03:59 +01:00
Nicolas MARTIN 8b96ff57d7 arm auth: split COM_ARM_AUTH in 3 parameters
new params are:
- COM_ARM_AUTH_ID
- COM_ARM_AUTH_MET
- COM_ARM_AUTH_TO
2020-11-10 09:03:59 +01:00
Nicolas MARTIN 6579544fca arm_auth: use ack reception timestamp to compute authorization timeout 2020-11-10 09:03:59 +01:00
Nicolas MARTIN e89c21155a arm_auth: check authorization timestamp to skip old commands 2020-11-10 09:03:59 +01:00
David Sidrane defa437b88 Add HY-SRF05 ultrasonic sensor driver
* nxp_fmuk66-e: Use srf05 distance sensor
 * nxp_fmuk66-v3: Use srf05 distance sensor
2020-11-08 13:25:58 -05:00
Daniel Agar c60743b306 boards: NuttX increase file name max 32 -> 40 2020-11-08 12:51:59 -05:00
PX4 BuildBot 5ce0b5a32c Update submodule matrix to latest Sat Nov 7 19:38:27 EST 2020
- matrix in PX4/Firmware (0c3c9bea0f8466d0c14326d134fd0fa06f480cf5): https://github/commit/ce6b10b99af722a4e653387d40019a8428d2a54f
    - matrix current upstream: https://github/commit/a504b6e88152d88dba936bc74e449f2f281b84e2
    - Changes: https://github/compare/ce6b10b99af722a4e653387d40019a8428d2a54f...a504b6e88152d88dba936bc74e449f2f281b84e2

    a504b6e 2020-11-04 Mitchell-Lee-93 - precision of tol for float has been changed
2020-11-08 12:35:27 +01:00
stou-sandalski 6b23e28971 Fix for missing battery voltage from UAVCAN power modules (#16138)
It seems that battery.voltage_* is no longer used and QGC is getting voltage data from the cell voltage array instead.
2020-11-08 12:34:41 +01:00
Alex Mikhalev 91d1825fcf Fix non-determinstic boot hang with crashdumps
On boot, if board_hardfault_init finds a hardfault stored in BBSRAM, it
checks if there is any data available on stdin to see if there is
somebody there to respond to a prompt. But on boards such as cubeorange
where there is not a serial console by default, the ioctl fails and
bytesWaiting is uninitialized. So it will non-deterministally hang the
boot process with no outside feedback if that value is not zero.

Signed-off-by: Alex Mikhalev <alexmikhalevalex@gmail.com>
2020-11-05 12:41:01 -08:00
Adam Blazczak 149ac16bb4 add support for secondary GPS interface
Useful for navio2 or px4_raspberrypi when attaching a secondary (UART) GPS through one of the USB ports; the default navio2 onboard GPS is running on spi.

Example usage:
gps start -d /dev/spidev0.0 -i spi -e /dev/ttyACM0 -j uart -p ubx
2020-11-05 08:59:11 +01:00
Hamish Willee ffa38f1b4f module markdownout - explicit anchor not heading 2020-11-05 08:56:31 +01:00
Daniel Agar bde5cadba7 ROMFS: replay automatically create replay_params.txt 2020-11-04 11:47:01 -05:00
Daniel Agar 142452f80c replay: print parameter changes and error on mismatch 2020-11-04 11:47:01 -05:00
Daniel Agar 03aa2dd46c ROMFS: create NXP HoverGames airframe (SYS_AUTOSTART 4017)
Co-authored-by: igalloway <iaintravelgalloway@gmail.com>
2020-11-04 11:43:20 -05:00
Beat Küng e6ad321ab2 gps: add GPS_{1,2}_PROTOCOL param to select protocol, default to u-blox
u-blox is the most widely used GPS, so module detection should be a bit
faster in general.
2020-11-04 10:26:49 -05:00
Beat Küng ab43a94224 gps: keep track of RX data rate 2020-11-04 10:26:49 -05:00
Beat Küng c5c521f5e0 gps: add support for u-blox heading with 2 F9P devices 2020-11-04 10:26:49 -05:00
Julian Kent d7fa5c68aa Add support for alpha/beta/rc on the vendor version (#16112)
* Add support for versioning the vendor version

* Make regex only allow either alpha/beta/rc, or vendor versions
2020-11-04 13:48:19 +01:00
Beat Küng 8f72ea9577 Jenkins: push module documentation to PX4 user guide as well 2020-11-04 13:08:05 +01:00
David Sidrane f02d490e89 rddrone-uavcan146:Rename to ucans32k146 2020-11-04 03:37:06 -08:00
David Sidrane e0f6c220b1 hardfault_log:Sanity check stack before dumping it 2020-11-04 08:44:38 +01:00
Hamish Willee 425b8a1733 markdownout - change Firmware to PX4-Autopilot 2020-11-04 08:31:28 +01:00
Daniel Agar ea2fced6ad Tools/check_submodules.sh: always update if within vscode cmake configure
- the interactive portion of check_git_submodule with hang waiting for user input
2020-11-03 23:40:12 -05:00
Silvan Fuhrer 99833eb001 FW Position Control: remove duplicated position_sp_triplet update
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-11-03 15:47:57 +01:00
Daniel Agar ba5ef28f23 uORB_tests: add uORB::SubscriptionMultiArray tests 2020-11-03 09:10:54 -05:00
JaeyoungLim 9e5cf3a598 Enable multiple rover simulations (#15904)
This commit allows running multiple simulations with rovers
2020-11-03 14:55:32 +01:00
Lorenz Meier a39bead740 Update SITL (compile fix)
This fixes the linker command for protobuf libraries for plugins.
;
2020-11-02 18:39:31 -05:00
Silvan Fuhrer d4d02f449f Improve tailsitter tuning master (#16078)
* tailsitter SITL: improve hover tuning

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

* Add SITL testing for tailsitter VTOLs

This enables SITL testing for Tailsitter vehicles

Co-authored-by: Jaeyoung-Lim <jaeyoung@auterion.com>
2020-11-02 23:41:12 +01:00
Ricardo Marques fd90387270 README: Cleanup Maintenance Team structure
Changes current Maintenance Team structure in README.md in order to be more organized and with a standard.

Signed-off-by: Ricardo Marques <marques.ricardo17@gmail.com>
2020-11-02 23:31:29 +01:00
Avionics Anonymous 437a1c6db1 Use ModuleParams instead of old param funcs 2020-11-02 23:29:50 +01:00
Avionics Anonymous cc96468fad Extend UAVCAN light control
Adds automatic control of more light types via UAVCAN. Publishes
commands for beacon, strobe, nav, and landings lights. Each is
automatically controlled based on arming state and this behavior is
configurable per light type via params. For example, nav lights can be
set to be always on while beacons turn on when the system is prearmed
and strobes turn on only when armed.
2020-11-02 23:29:50 +01:00
Silvan Fuhrer 67a0e1993a FW Position controller: add option to swap throttle and pitch stick
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-11-02 22:49:05 +01:00
Martin Povišer ad0de67df7 dshot: fix build error
Fixes

  src/drivers/dshot/dshot.cpp:1408:9: error: declaration of
  'struct DShotOutput::custom_command(int, char**)::Command' shadows
  a previous local [-Werror=shadow]
2020-11-02 13:52:42 -05:00
Martin Povišer d2145917e7 setup: add Nix derivation with build environment 2020-11-02 13:52:42 -05:00
Martin Povišer b0a73b5144 platforms/nuttx: change bash references
There is a platform, NixOS Linux, on which '/bin/bash' is not available.
This commit changes the interpreter to '/usr/bin/env bash' in some
scripts essential to firmware building.
2020-11-02 13:52:42 -05:00
CUAVcaijie 77dfd111e2 boards: cuav/x7pro disable BDMA (#16056)
- currently causing a crash, disable for now
2020-11-02 13:14:44 -05:00
Daniel Agar 817285ec64 commander: gyro calibration use MedianFilter 2020-11-02 12:58:46 -05:00
Daniel Agar d14deb0e5a FFT add simple median filter 2020-11-02 12:58:46 -05:00
Daniel Agar 4578b8cdcc Update submodule ecl to latest Mon Nov 2 09:57:32 EST 2020
- ecl in PX4/Firmware (f87b19f31b9918f73d336d10e68d39c659037582): https://github/commit/48a8992caf7a95e09a5e17235133894c072b96bd
    - ecl current upstream: https://github/commit/a21092804a784d012939f96cc633e7da5f5e8cde
    - Changes: https://github/compare/48a8992caf7a95e09a5e17235133894c072b96bd...a21092804a784d012939f96cc633e7da5f5e8cde

    a210928 2020-11-01 Daniel Agar - EKF: remove virtual getters from estimator_interface
2020-11-02 12:44:14 -05:00
Beat Küng d83da4ded4 fix SubscriptionMultiArray: end() iterator needs to point past the end
And ensure not to dereference.
2020-11-02 09:00:04 +01:00
Daniel Agar a1ef4d1469 ekf2: only advertise immediately in multi-EKF mode 2020-11-01 15:48:35 -05:00
PX4 BuildBot 1dd3283fbb Update submodule ecl to latest Sat Oct 31 20:37:40 EDT 2020
- ecl in PX4/Firmware (6bb56ae2b3debb76669a04adb7c64bac74bb87f4): https://github/commit/d85e24d3ca767b48bdbb1594b564d30df5777769
    - ecl current upstream: https://github/commit/48a8992caf7a95e09a5e17235133894c072b96bd
    - Changes: https://github/compare/d85e24d3ca767b48bdbb1594b564d30df5777769...48a8992caf7a95e09a5e17235133894c072b96bd

    48a8992 2020-10-30 Daniel Agar - EKF: move small simple getters to header
defb35d 2020-10-29 Daniel Agar - EKF: pass imuSample by const reference
2020-10-31 21:11:44 -04:00
PX4 BuildBot 4df3931bd1 Update submodule sitl_gazebo to latest Thu Oct 29 20:40:02 EDT 2020
- sitl_gazebo in PX4/Firmware (6b9dde59d6): https://github.com/PX4/PX4-SITL_gazebo/commit/2451437c19ed9fcdf8a79990313e768c98aa15b6
    - sitl_gazebo current upstream: https://github.com/PX4/PX4-SITL_gazebo/commit/06e801fe8b5267e561f00d8847a6343cb2386ab6
    - Changes: https://github.com/PX4/PX4-SITL_gazebo/compare/2451437c19ed9fcdf8a79990313e768c98aa15b6...06e801fe8b5267e561f00d8847a6343cb2386ab6

    06e801f 2020-10-29 Nuno Marques - add missing generated models to git ignore (#644)
eafc98b 2020-10-28 JaeyoungLim - Move boat model to jinja templates (#641)
2020-10-29 22:00:05 -04:00
Daniel Agar 6b9dde59d6 update ecl to latest
- fmu-v5 debug and stackcheck builds now need to be CONSTRAINED_FLASH to fit
 - delete unused holybro_durandal-v1_stackcheck build (also CONSTRAINED_FLASH)
2020-10-29 18:56:52 -04:00
Daniel Agar 81aa8a914f boards: px4_fmu-v2 disable ver command line to save flash 2020-10-29 18:56:52 -04:00
Daniel Agar d5894bea5c cmake: NuttX debug skip SVD print if not found 2020-10-29 15:07:47 -04:00
Daniel Agar 216a0eb3a0 cmake: NuttX redirect libapps build stdout to log file 2020-10-29 15:07:47 -04:00
Daniel Agar b13422dd80 gitmodules update URLs to renamed PX4 repositories 2020-10-29 15:06:59 -04:00
Daniel Agar ecb462f325 ekf2: EKF2.cpp using matrix Eulerf, Quatf, Vector3f 2020-10-29 10:22:57 -04:00
Daniel Agar d1af095c0b ekf2: don't store vehicle_status_s 2020-10-29 10:22:57 -04:00
Daniel Agar d27573b797 ekf2: don't store vehicle_land_detected_s 2020-10-29 10:22:57 -04:00
Daniel Agar 7757aeda94 ekf2: don't store sensor_selection_s copy 2020-10-29 10:22:57 -04:00
Daniel Agar db5235b074 ekf2: avoid storing message copies 2020-10-29 10:22:57 -04:00
Daniel Agar 3f9f2c6fdf ekf2: multi ekf supports up to 4 IMUs 2020-10-28 20:50:58 -04:00
Daniel Agar cf082d7f1c Github actions: SITL tests upgrade MAVSDK v0.30.1 -> v0.33.1 2020-10-28 20:26:47 -04:00
Daniel Agar b5e00cd424 NuttX upgrade branches to px4_firmware_nuttx-10.0.0+ 2020-10-28 17:25:08 -04:00
David Sidrane ff87bc0fda fmu-v6x:Bootloader init NULL console 2020-10-28 14:25:25 -04:00
David Sidrane 39b1d827d2 cubeorange:Bootloader init NULL console 2020-10-28 14:25:25 -04:00
David Sidrane 1fa1f8c2c5 durandal-v1:Bootloader init NULL console 2020-10-28 14:25:25 -04:00
David Sidrane 962b90fd75 cuav:Bootloader init NULL console 2020-10-28 14:25:25 -04:00
David Sidrane 8797823333 px4_init:Split out console init to create null device to be used in non PX4 platform bsp (bootloadres) 2020-10-28 14:25:25 -04:00
David Sidrane 021bc284c1 nxp:imxrt ADC track Rev02 of ref manual change made in upstream 2020-10-28 14:25:25 -04:00
Daniel Agar 233949a377 NuttX upgrade to 10.0.0+ defconfig changes 2020-10-28 14:25:25 -04:00
David Sidrane 850e068aa3 Nuttx 10.0.0+ 2020-10-28 14:25:25 -04:00
Daniel Agar 2c874f1cd9 ekf2 selector fix SITL lockstep
- ekf2 selector don't register lockstep until first attitude publication
 - sensors module register lockstep component
 - enable multi-EKF2 in SITL
2020-10-28 09:42:41 -04:00
TSC21 b1dc1b1ecd msg: rtps: add IDs for missing estimator_* msgs 2020-10-28 11:58:35 +01:00
Thies Lennart Alff 82988b1912 airframes: added BlueROV2 (heavy configuration) airframe (#16004) 2020-10-28 11:07:31 +01:00
TSC21 5b7d1a0496 msg: rtps: add missing ID for orb_test_medium_wrap_around 2020-10-28 10:18:22 +01:00
Daniel Agar 69986affbf commander: calibration restore sleep after CAL_QGC_DONE_MSG/CAL_QGC_FAILED_MSG 2020-10-27 18:54:16 -04:00
Nicolas Martin 171bd6d784 positionControl: add check on sign before sqrtf 2020-10-27 18:52:23 -04:00
SalimTerryLi 05f1efd1a4 load_mon: get mem_usage by reading /proc/meminfo on Linux 2020-10-27 18:49:25 -04:00
Daniel Agar 91da194bd7 sensors/vehicle_gps_position: only register callbacks once topic published
- this avoids creating unnecessary uORB device nodes for GPS instances that might never exist
2020-10-27 18:40:57 -04:00
Daniel Agar df2f26ebdf rename vehicle_visual_odometry_aligned -> estimator_visual_odometry_aligned
- saves a small amount of work for the ekf2 selector in multi-EKF mode (visual_odometry_aligned now ignored)
 - helps to distinguish the origin/purpose from vehicle_odometry and vehicle_visual_odometry
2020-10-27 12:33:39 -04:00
Daniel Agar d5e68bc05a mathlib: NotchFilter delete unused update method 2020-10-27 12:30:59 -04:00
Mathieu Bresciani 050c9dcd3d HTE: fix variance prediction (#16016)
In the predition step, the process variance was erroneously
multiplied by dt instead of dt^2. The default values are adjusted
accordingly to keep the same tuning for the default loop rate of 50Hz
2020-10-27 16:56:32 +01:00
Daniel Agar f36f8928e3 distance_sensor/vl53l1x: fix code style 2020-10-27 11:43:11 -04:00
Alexey 2e98c64853 drivers/distance_sensor: new driver for ST VL53L1x
Co-authored-by: Alexey Matveev <>
2020-10-27 11:26:53 -04:00
Daniel Agar 0f411d6820 Multi-EKF support (ekf2)
- ekf2 can now run in multi-instance mode (currently up to 9 instances)
    - in multi mode all estimates are published to alternate topics (eg estimator_attitude instead of vehicle_attitude)
 - new ekf2 selector runs in multi-instance mode to monitor and compare all instances, selecting a primary (eg N x estimator_attitude => vehicle_attitude)
 - sensors module accel & gyro inconsistency checks are now relative to the mean of all instances, rather than the current primary (when active ekf2 selector is responsible for choosing primary accel & gyro)
 - existing consumers of estimator_status must check estimator_selector_status to select current primary instance status
 - ekf2 single instance mode is still fully supported and the default

Co-authored-by: Paul Riseborough <gncsolns@gmail.com>
2020-10-27 10:56:11 -04:00
Daniel Agar d5245a22d3 logger: limit default estimator_optical_flow_vel logging 2020-10-26 14:10:25 -04:00
bresch 109ed18a3a Flow: adjust default optical flow delay based on pmw3901
This is the correct value for the most common optical flow sensor
2020-10-26 14:10:25 -04:00
bresch 142724748a pmw3901: Adjust scale factor to match gyro data 2020-10-26 14:10:25 -04:00
bresch 09cc3120e2 OpticalFlow: add optical flow velocity logging
This is important to align the flow with the IMU data and verify that
the compensation is properly done
2020-10-26 14:10:25 -04:00
Matthias Grob 8e710294b3 FlightTaskManualAltitudeSmoothVel: fix parameter inheritance chain 2020-10-26 15:55:21 +01:00
Matthias Grob 7ba93d5452 FlightTasks: fix reActivate not calling the parent overrided method 2020-10-26 15:55:21 +01:00
FengShun eac9a6b68b Replace PublicationQueued with Publication to automatically configure ORB_QUEUE_LENGTH 2020-10-26 13:01:13 +01:00
FengShun 90c366f369 uORB::Publication*: template parameter automatically obtains the queue size according to the type 2020-10-26 13:01:13 +01:00
Nicolas Martin 948bed6b5c fix ekf2 saved mag bias comments (mGauss -> Gauss) 2020-10-26 00:43:20 -04:00
Daniel Agar 8435742dd5 logger: double actuator_controls_0 and vehicle_attitude_setpoint default log rate 2020-10-26 00:36:02 -04:00
Daniel Agar 6d2f592c16 logger: add vehicle_constraints to default set 2020-10-26 00:36:02 -04:00
PX4 BuildBot 53b5e2d863 Update submodule sitl_gazebo to latest Sun Oct 25 20:37:27 EDT 2020
- sitl_gazebo in PX4/Firmware (945c17bc3f): https://github.com/PX4/sitl_gazebo/commit/4f03afc7def0b958e7567a35093bacf93dcc824f
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/2451437c19ed9fcdf8a79990313e768c98aa15b6
    - Changes: https://github.com/PX4/sitl_gazebo/compare/4f03afc7def0b958e7567a35093bacf93dcc824f...2451437c19ed9fcdf8a79990313e768c98aa15b6

    2451437 2020-10-24 Igor Campos - fix #638 - geotagging plugin not working: subscribed to wrong topic
9f832e5 2020-10-09 JaeyoungLim - Add groundtruth plugin
dcae3ed 2020-09-29 JaeyoungLim - Switch tiltrotor to jinja templates
928169c 2020-09-28 JaeyoungLim - Move where the gps joint is being defined
60897b7 2020-08-24 JaeyoungLim - Fix tiltrotor model
9f82ad4 2020-10-22 JaeyoungLim - Move rover models to jinja templates (#629)
00d6f2f 2020-10-21 Thies Lennart Alff - Adding Model of BlueROV2 (heavy configuration) (#637)
b15784d 2020-10-19 Vojtech Spurny - gazebo_gps_plugin fix and enhancement (#635)
2020-10-25 23:54:33 -04:00
Daniel Agar 614a0ac2a2 experimental/gyro_fft: improve peak detection, add start parameter
- add new parameter `IMU_GYRO_FFT_EN` to start
 - add 75% overlap in buffer to increase FFT update rate
 - space out FFT calls (no more than 1 per cycle)
 - increase `IMU_GYRO_FFT_MIN` default
 - decrease main stack usage
2020-10-25 23:48:21 -04:00
Daniel Agar 945c17bc3f move subsystem_info entirely into commander and remove from uORB
* HealthFlags: define bitfield using 1<<X

Co-authored-by: Matthias Grob <maetugr@gmail.com>
2020-10-25 10:08:15 -04:00
Igor Mišić ea3d202370 spracing_h7extrem: Updated gyros to use icm20602 drivers. 2020-10-24 11:54:13 -04:00
Daniel Agar 6285e06fe2 mc_pos_control: split out header and name consistently 2020-10-23 15:06:04 -04:00
Matthias Grob 1fb4f960cd FlightTaskAuto: Lock down yaw when waypoint is reached
This is done to prevent yawing 180 degrees when switching
to hold mode with high velocity and the overshoot causing a 180°
yaw turn.

The yaw is unlocked on waypoint updates and the yaw
setpoint generation had to be put at the end because otherwise the
first yaw calculation is with the old waypoint and immediately
locks again.
2020-10-23 20:54:01 +02:00
Daniel Agar 81765bc06a commander: PreFlightCheck remove HIL special cases
- skipping these sensor checks in HIL no longer makes sense as each
sensor has a normal publication (sensor_accel/gyro/etc) regardless of
simulation
2020-10-23 11:25:50 -04:00
Matthias Grob 4378254182 Fix NuttX build under Cygwin
after NuttX 9.1.0+ upgrade #15139
2020-10-23 06:56:31 -07:00
David Sidrane d8a03d04a7 nxp_rddrone-uavcan146:Fixed wrong SPI CLK Pin 2020-10-23 09:18:24 +02:00
Beat Küng d2644a3bf7 distance_sensor/sf0x: rename to lightware_laser_serial 2020-10-22 11:30:50 -04:00
Beat Küng a68ac95399 distance_sensor/sf1xx: rename to lightware_laser_i2c 2020-10-22 11:30:50 -04:00
Beat Küng 6d2e306d50 sf1xx: use new protocol for LW20/c
benefits:
- read & validate product name
- sensor configuration with the output we want (raw distance data)
- get signal quality

Protocol description: http://support.lightware.co.za/sf20/#/commands

Other Lightware sensors can easily be moved over to that as well.
2020-10-22 11:30:50 -04:00
Beat Küng c0cf144a5a ll40ls: fix rotation -> orientation 2020-10-22 11:30:50 -04:00
JaeyoungLim 46d79d3050 Remove exception of actuator scaling for airships (#16011)
This removes the exception handling of airship type vehicles when scaling actuators for the simulator
2020-10-22 10:37:03 +02:00
Hamish Willee d91d7e3282 parameter markdown table - remove styling 2020-10-22 08:05:41 +02:00
Lorenz Meier b14d0e4326 Update MAVLink shell default device for modern Mac OS
The enumeration changed from usbmodem1 to usbmodem01 and this tracks this OS-level naming change.
2020-10-21 12:11:31 -04:00
Daniel Agar 0b74076265 msg: only include orb_test messages if PX4_TESTING enabled 2020-10-20 15:17:09 -04:00
Daniel Agar 2201424dfd micrortps_bridge: don't reuse msg_files variable (now global) 2020-10-20 11:05:47 -04:00
Daniel Agar 1eb3c59277 systemcmds/topic_listener: use msg_files list from msg/ 2020-10-20 11:05:47 -04:00
Daniel Agar 16119f0e8c mavlink debug messages disable on CONSTRAINED_FLASH boards
- mavlink messages DEBUG/DEBUG_FLOAT_ARRAY/DEBUG_VECT/NAMED_VALUE_FLOAT move to separate stream headers and don't include if CONSTRAINED_FLASH
 - mavlink receiver DEBUG/DEBUG_FLOAT_ARRAY/DEBUG_VECT/NAMED_VALUE_FLOAT handling excluded if CONSTRAINED_FLASH
 - msg: skip debug_array.msg, debug_key_value.msg, debug_value.msg, debug_vect.msg if CONSTRAINED_FLASH
2020-10-20 11:05:47 -04:00
Julian Kent d9b3db1082 Check that home position is valid in RTL (#15964) 2020-10-20 10:31:44 +02:00
Beat Küng 5f27407acd tests: don't run battery_simulator
The battery migration interferes with the tests.
2020-10-20 09:18:47 +02:00
Beat Küng f776997a07 battery: disable secondary module by default
Avoid a GCS showing 2 battery indicators.
Alternatively we could also check the 'connected' flag, but this is more
explicit.
2020-10-20 09:18:47 +02:00
Beat Küng 83b81fbbef battery: fix isFloatEqual(), use matrix::isEqualF
Fixes param migration, e.g. if BAT_N_CELLS is set, migrates to
BAT1_N_CELLS.
2020-10-20 09:18:47 +02:00
Beat Küng 6ae17eb13c fix EscBattery: remove _battery.publish();
updateBatteryStatus() already publishes
2020-10-20 09:18:47 +02:00
Daniel Agar be0f884dde commander: preflight check don't read mag device_id 2020-10-19 23:01:02 -04:00
Daniel Agar b08b83ba48 logger: logged topics support up to 4 accels/baros/gyros 2020-10-19 18:30:22 -04:00
Tomasz Domański 887486d4fa Tools/setup: Add apt-get update after adding gazebo list 2020-10-19 17:19:18 -04:00
Oleg Kalachev c302514a08 mavlink: expose kill switch status 2020-10-19 10:49:52 -04:00
Beat Küng d0fd60de8d output_limit: use add_library instead of px4_add_library
px4_add_library adds uorb dependencies, which since cf26f24387 added libm.
This in turn led to build failures for px4_io-v2 in the form of:
__aeabi_f2d' wf_sqrt.c:(.text.sqrtf+0x54): undefined reference to
__aeabi_ddiv'
2020-10-19 09:45:46 -04:00
FengShun d19b54481a fix: uORB topics lost messages when publications overflow 2020-10-19 08:52:55 +02:00
PX4 BuildBot b4a22437ab Update submodule sitl_gazebo to latest Sun Oct 18 08:37:29 EDT 2020
- sitl_gazebo in PX4/Firmware (224be8ba24): https://github.com/PX4/sitl_gazebo/commit/b943edaddee2b5e84e7bb489c43ebb13dd70495d
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/4f03afc7def0b958e7567a35093bacf93dcc824f
    - Changes: https://github.com/PX4/sitl_gazebo/compare/b943edaddee2b5e84e7bb489c43ebb13dd70495d...4f03afc7def0b958e7567a35093bacf93dcc824f

    4f03afc 2020-10-16 Apurva Joshi - Update typhoon_h480.sdf (#636)
2020-10-18 11:44:54 -04:00
Daniel Agar 224be8ba24 drivers/uavcan: RGB LED support (publish uavcan::equipment::indication::LightsCommand)
Co-authored-by: Alex Mikhalev <alexmikhalevalex@gmail.com>
2020-10-17 12:33:09 -04:00
CUAVcaijie 70b67ddbff Add a USB ardupilot * type 2020-10-17 11:36:36 -04:00
Jaeyoung-Lim 3c20580533 Add support for malolo flying wing in JSBSim SITL
This commit adds SITL target for malolo flying wing and updates the jsbsim_bridge submodule to include the necessary changes.
2020-10-16 13:31:09 +02:00
David Sidrane 7d6f8dc882 mtd:Allow a Board to set the partition sizes.
To define an N way split this define the following:

        #define BOARD_HAS_MTD_PARTITION_OVERRIDE {"/fs/mtd_params", "/fs/mtd_waypoints","/fs/equal_part" }

	OR
        To define a percentage split this define the following:
        #define BOARD_HAS_MTD_PARTITION_OVERRIDE {"/fs/mtd_params", "/fs/mtd_waypoints","/fs/tiny" }
        #define BOARD_MTD_PARTITION_TABLE_SIZES {50.0f, 49.0f, 1.0f}
2020-10-15 17:22:50 -04:00
David Sidrane d4ae3985b3 px4-alias.sh_in:Remove source and add R=${pwd}
px4-alias.sh_in:Remove sh alias
2020-10-15 17:11:08 -04:00
David Sidrane b846ddffd8 Tools:Use . for (source) and ${R} for pathing 2020-10-15 17:11:08 -04:00
David Sidrane b9319b3843 ROMFS:Use . for (source) and ${R} for pathing
init.d-posix:rcS Quiet Shell check warning
2020-10-15 17:11:08 -04:00
David Sidrane 78221ee3d2 s32k1xx:Add PWM LED Support 2020-10-15 12:52:38 -07:00
David Sidrane 37e711c3fd s32k1xx:io_timer: Enable output channels 2020-10-15 12:52:38 -07:00
David Sidrane ddc161a10a nxp_rddrone-uavcan146:Add init to start PWM 2020-10-15 12:52:38 -07:00
David Sidrane 6394e06173 nxp_rddrone-uavcan146:Compresed ROM FS and friends 2020-10-15 12:52:38 -07:00
David Sidrane 59213ed8f6 nxp_rddrone-uavcan146:Add the pwm and suppor 2020-10-15 12:52:38 -07:00
David Sidrane 254ad40ad8 nxp_rddrone-uavcan146:Init the timers 2020-10-15 12:52:38 -07:00
David Sidrane 4099d38ea8 nxp_rddrone-uavcan146: Add arch_io 2020-10-15 12:52:38 -07:00
David Sidrane d3fdb2b6ad nxp_rddrone-uavcan146 add board functions supporting pwm_out 2020-10-15 12:52:38 -07:00
David Sidrane d4fb063651 nxp_rddrone-uavcan146:boards Add KEEP on init_section 2020-10-15 12:52:38 -07:00
Jari van Ewijk 61f9996d6b S32K1XX: Report right MCU version 2020-10-15 12:52:38 -07:00
Jari van Ewijk 35dce9aff6 NXP UCANS32K: Add Support for PWM
S32K1XX HRT: Allow any channel of any FTM timer to be used

NXP UCANS32K: Enable additional FlexTimers and use FTM5 for HRT

NXP UCANS32K - Change FTM clocksource to system oscillator

NXP UCANS32K - Only need one FlexTimer and channel for PWM output

NXP UCANS32K will have only one PWM header by default

S32K1XX support FlexTimers beyond FTM3

S32K1XX io_timer.c - replace references to Kinetis

S32K1XX io_timer.c correct register names

S32K1XX input_capture.c and pwm_servo.c replace references to Kinetis
2020-10-15 12:52:38 -07:00
Silvan Fuhrer 4ed3ecea41 lis2mdl: reduce update rate from 50Hz to 20Hz to reduce spikes
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-10-15 09:55:40 +02:00
Daniel Agar d985887468 ekf2: use new Param<> reset method 2020-10-15 08:32:05 +02:00
Daniel Agar 7255f5feac parameters: add param_reset_no_notification()
- add reset() to Param<>
2020-10-15 08:32:05 +02:00
PX4 BuildBot d8448c0a76 Update submodule v2.0 to latest Wed Oct 14 19:19:57 EDT 2020
- v2.0 in PX4/Firmware (34ced0c26c): https://github.com/mavlink/c_library_v2/commit/894599e6cba3ca6e8a32a68065b15d1a91c35af2
    - v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/1eff57ee1e54fbed0b24617b1d4452d26d8b2221
    - Changes: https://github.com/mavlink/c_library_v2/compare/894599e6cba3ca6e8a32a68065b15d1a91c35af2...1eff57ee1e54fbed0b24617b1d4452d26d8b2221

    1eff57e 2020-10-14 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/162381c6d43db57afcf1f25de403d35c5f5db4b3
075f46c 2020-10-14 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/4413195381eb850aa33b18c539abd68437a9b3ac
e9813d0 2020-10-14 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/e9704daf9a34c64c47c8010033e1c22c0ceaa5a4
b156279 2020-10-14 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/4cf81ef0a3da38f43346ab263422363f6dbbf38b
47b8476 2020-10-13 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/bb1c55d1a598ddb487e309b7a35c70e65234b98b
da412c5 2020-10-11 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/52e3f7842e35c42ee4586fdbd1f1117714d3373c
2020-10-14 20:26:39 -04:00
PX4 BuildBot 22a817d1fc Update submodule nuttx to latest Wed Oct 14 19:20:05 EDT 2020
- nuttx in PX4/Firmware (8c8f594b24bddbb69c95772d80d51d3d62f4ad39): https://github.com/PX4/NuttX/commit/724aa6c1d3dda6cbb86f1461a79d2827870ece47
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/19c831f409c9d8e51e8b41e531cf658f2175a2e9
    - Changes: https://github.com/PX4/NuttX/compare/724aa6c1d3dda6cbb86f1461a79d2827870ece47...19c831f409c9d8e51e8b41e531cf658f2175a2e9

    19c831f 2020-10-14 David Sidrane - [BACKPORT] kinetis:flexcan fixed compile error clock_systimespec->clock_systime_timespec
2020-10-14 20:25:54 -04:00
JaeyoungLim 34ced0c26c Cleanup jsbsim run scripts (#15959)
* Cleanup startup scripts

This commit cleansup the run script for the jsbsim_bridge

* Update jsbsim_bridge submodule
2020-10-14 16:41:11 +02:00
David Sidrane 6416abc817 Nuttx with kinetis BP tix for socketcan 2020-10-14 09:50:24 -04:00
David Sidrane 1e0f3a1e9c px4_fmu-v5x base_phy_DP83848C:Use 32kHz clock for RTC 2020-10-14 14:55:55 +02:00
David Sidrane 7f804b5508 px4_fmu-v5x:Use 32kHz clock for RTC 2020-10-14 14:55:55 +02:00
mcsauder 047531b924 Add MavlinkStreamGPSStatus status class stream via GPS_STATUS.hpp and add PRN code to satellite_info.msg. 2020-10-14 08:26:42 +02:00
David Sidrane de6d31ef3e hardfault_log:Fix hard fault - while hard fault logging 2020-10-13 18:50:43 -04:00
Daniel Agar 8d1b99be31 mavlink: telemetry status only log simple HEARTBEAT validity
* delete telemetry_heartbeat msg
 * delete unused _telemetry_status_mutex
2020-10-13 13:37:10 -04:00
Daniel Agar d71ca37087 navigator: publish navigator mission item changes for logging
- new msg navigator_mission_item for inspecting navigator mission item processing
2020-10-13 12:12:03 -04:00
Jacob Dahl 74c9ba8d55 fix px_uploader bytes and char comparison & remove python 2 support (#15859) 2020-10-13 09:30:37 +02:00
Alex Mikhalev c2af7ba961 uavcan: gnss: Implement RTCM data for RTK (#15921)
Forwards messages on the gps_inject_data uORB topic as
uavcan::equipment::gnss::RTCMStream messages on the UAVCAN bus. This
enables differential/RTK GPS over UAVCAN to work.

Tested with CubePilot Cube Orange, Here+ base and Here3 rover.

Signed-off-by: Alex Mikhalev <alexmikhalevalex@gmail.com>
2020-10-13 09:28:25 +02:00
Daniel Agar 34ad85557e Revert "mavlink: increase stack 2650 -> 2848 bytes (#15821)"
This reverts commit e792c46f20.
2020-10-12 20:58:35 -04:00
Daniel Agar 5c2cc53134 Revert "logger: log_writer_file increase stack 1170 -> 1472 bytes (#15765)"
This reverts commit d676e65294.
2020-10-12 20:58:35 -04:00
David Sidrane 17ada7cf32 Nuttx with arm stack fix backport 2020-10-12 19:56:00 -04:00
Daniel Agar f557fa46e8 gyro_fft improve peak finding, parameterize min/max frequencies, remove debug logging
- add min/max frequency parameters for peak detection (IMU_GYRO_FFT_MIN, IMU_GYRO_FFT_MAX)
 - remove full FFT debug logging
 - fix Quinn's second estimator
 - log sensor_gyro_fft
 - fake_gyro use PX4Gyroscope
2020-10-12 15:19:39 -04:00
Beat Küng ff3008c051 calibration: add SYS_FAC_CAL_MODE parameter
If set, stores calibration parameters in separate storage /fs/mtd_caldata.
2020-10-12 15:22:26 +02:00
Beat Küng f1f6ca21cb rcS: try to load params from secondary storage if available 2020-10-12 15:22:26 +02:00
Beat Küng 3e9692c5bd param_import: add mark_saved argument
Behavior of the 'param import' command:
- if no file provided, parameters are marked as saved (differs from before)
- if a file is provided: parameters are not marked as saved
2020-10-12 15:22:26 +02:00
Beat Küng f6e8ddfaa0 param_export: add optional filter method 2020-10-12 15:22:26 +02:00
Beat Küng f927cacd9c v5x: enable eeprom storage on IMU board 2020-10-12 15:22:26 +02:00
Beat Küng c6cd0536d7 mtd: support multiple instances 2020-10-12 15:22:26 +02:00
Jacob Dahl 2b5b6b9430 fixed dps310 calibration coeffecient for c11 2020-10-12 09:35:27 +02:00
James Goppert 98c30dff44 Fixes for ROS based multi sim with jinja. (#15938) 2020-10-12 09:33:51 +02:00
Benjamin Perseghetti 8350fa702b Tools/setup/ubuntu.sh: fix for Ubuntu 20.04 - use gazebo11 2020-10-11 17:05:32 -04:00
Daniel Agar 0a985638e3 simulator: add inject failure messages for logging 2020-10-10 20:03:50 -04:00
Daniel Agar 76602b3a8f mavsdk_tests: longer climb (5 -> 10 seconds) in fly forward altctl/posctl tests 2020-10-10 20:03:50 -04:00
Daniel Agar da37f63bbd ROMFS: posix adjust standard vtol (1040) tuning 2020-10-10 20:03:50 -04:00
Daniel Agar 5fa1e8e8ba mavlink: stream rename GROUND_TRUTH -> HIL_STATE_QUATERNION 2020-10-10 19:49:41 -04:00
Daniel Agar cb4d974977 mavlink: move GROUND_TRUTH stream to separate file 2020-10-10 19:49:41 -04:00
Daniel Agar 283264603a mavlink: move PING stream to separate file 2020-10-10 19:49:41 -04:00
Daniel Agar 97dc988f86 mavlink: move ORBIT_EXECUTION_STATUS stream to separate file 2020-10-10 19:49:41 -04:00
Daniel Agar 826dfa1941 mavlink: move OBSTACLE_DISTANCE stream to separate file 2020-10-10 19:49:41 -04:00
PX4 BuildBot 68dca4b158 Update submodule sitl_gazebo to latest Sat Oct 10 16:43:28 UTC 2020
- sitl_gazebo in PX4/Firmware (dfbaf6607a): https://github.com/PX4/sitl_gazebo/commit/c3b15b7c9bf217c52f1e12fda0f861f6af5f31a9
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/6b9c8f15c24b9ca365f3b13978fe792aa31a2fa3
    - Changes: https://github.com/PX4/sitl_gazebo/compare/c3b15b7c9bf217c52f1e12fda0f861f6af5f31a9...6b9c8f15c24b9ca365f3b13978fe792aa31a2fa3

    6b9c8f1 2020-10-10 Daniel Agar - mavlink interface round double sim time when converting to microseconds
b4cebfc 2020-10-09 JaeyoungLim - Support HIL configurations for generated models (#625)
b4d2d58 2020-10-09 Daniel Agar - mavlink interface poll until actuator received (#631)
2020-10-10 19:12:40 -04:00
PX4 BuildBot 6097ea3fb3 Update submodule CMSIS_5 to latest Sat Oct 10 16:43:35 UTC 2020
- CMSIS_5 in PX4/Firmware (7fc24ccb599b7b890983ee58ab82fcef502851bc): https://github.com/ARM-software/CMSIS_5/commit/03a697980f808120f1b75bfe0a96c2dd31bafbbc
    - CMSIS_5 current upstream: https://github.com/ARM-software/CMSIS_5/commit/4ed5730787a0f98e8858c9998e406c608ab10b28
    - Changes: https://github.com/ARM-software/CMSIS_5/compare/03a697980f808120f1b75bfe0a96c2dd31bafbbc...4ed5730787a0f98e8858c9998e406c608ab10b28

    4ed573078 2020-05-28 Jonatan Antoni - Docs: Updated generated documentation for CMSIS-Zone 1.1.0
c5ff98f52 2020-04-23 Jonatan Antoni - Utilities: Readded PackChk and SVDConv (not using Git-LFS) - PackChk 1.3.89 - SVDConv 3.3.35
5c1547f5d 2020-04-22 Jonatan Antoni - Removed Git-LFS filter from .gitattributes
8be87e257 2020-04-09 Jonatan Antoni - Pack: Purged pre-built library binaries from repo.
a65b7c9a3 2020-04-09 Jonatan Antoni - Bump version and docs for release.
71cca2783 2020-04-09 Jonatan Antoni - Merge branch 'develop/upstream' into master/upstream
4a65d8801 2020-02-26 Jonatan Antoni - Updated published documentation: - Added CMSIS-Build 0.1.1 - Updated CMSIS logo - Reduced nav bar component names
79bc1e065 2019-12-13 Jonatan Antoni - Doc: Update generated documentation for - CMSIS-Zone 1.0.0 - CMSIS-Pack 1.6.1
b5f0603d6 2019-07-10 Jonatan Antoni - Pack: Fixup to version history.
c314b9028 2019-07-10 Jonatan Antoni - docs: Updated generated docs for release 5.6.0
288a1ae6a 2019-07-10 Jonatan Antoni - Merge branch 'develop/upstream' into master/upstream
ca8124215 2019-03-21 Jonatan Antoni - Fixed generated documentation for 5.5.1 - Added general version history.
382cb5993 2019-03-21 Jonatan Antoni - DoxyGen: Fixed version and history of CMSIS 5.5.1 in documentation overview.
08ffc1624 2019-03-20 Jonatan Antoni - Generated documentation for release 5.5.1.
decf9e99d 2019-03-20 Jonatan Antoni - Merge branch 'develop/upstream' into master/upstream
a82c293bf 2019-03-18 Jonatan Antoni - Updated generated documentation.
3c188c8c1 2019-03-18 Jonatan Antoni - Merge branch 'develop/upstream' into master/upstream
607099e7b 2019-03-16 Jonatan Antoni - Device: Fixed device files for Armv8.1-MML
11b17447c 2019-03-15 Joachim Krech - WiFi api definition: file doc added
7a3ff1bba 2019-03-15 Jonatan Antoni - Docs: Updated generated documentation for 5.5.0
9510c40cd 2019-03-15 Jonatan Antoni - Merge branch 'develop/upstream' into master/upstream
cb3fb9a70 2018-09-03 Jonatan Antoni - Revert "Changed 'Serial Viewer Output' to 'Serial Wire Output'"
85f971366 2018-08-23 Florian Behrens - Changed 'Serial Viewer Output' to 'Serial Wire Output'
74b68d2b5 2018-08-23 Robert Rostohar - Merge pull request #411 from ARM-software/revert-410-fix_define
f568cf95d 2018-08-23 Robert Rostohar - Revert "Fix define around EvrRtxKernelInitialized"
cb270c6a7 2018-08-23 Robert Rostohar - Merge pull request #410 from c1728p9/fix_define
707444066 2018-08-22 Russ Butler - Fix define around EvrRtxKernelInitialized
0b5217650 2018-08-01 Jonatan Antoni - Docs: Updated generated documentation for 5.4.0
d8515eb5a 2018-08-01 Jonatan Antoni - Merge branch 'develop/upstream' into master/upstream
49ac527aa 2018-02-22 Jonatan Antoni - Doxygen: Fixed broken link from general revision history to Core(A) history.
ca68d1caa 2018-02-22 Jonatan Antoni - Utilities: Fixed gen_pack.bat to copy genmodel (Javadoc) as part of Zone documentation.
d3be1443d 2018-02-22 Jonatan Antoni - Docs: Updated documentation for release 5.3.0.
1e50f4fb3 2018-02-22 Jonatan Antoni - Merge remote-tracking branch 'remotes/upstream/develop' into master/upstream
9c4c35760 2018-01-23 Jonatan Antoni - Doc: Adding temporary redirect for CMSIS-NN to develop preview on keil.com. This redirect is going to be overwritten with the full documentation at next full release.
80cc44bba 2017-11-16 Jonatan Antoni - Pack: Added release date for 5.2.0
a7da04c26 2017-11-16 Jonatan Antoni - Updated generated documentation for release.
72db7faf6 2017-11-16 Jonatan Antoni - Merge branch 'develop/upstream' into master/upstream
7cd3d4765 2017-09-19 Jonatan Antoni - Updated generated documentation for release 5.1.1
cbdfdd09f 2017-09-19 Jonatan Antoni - Fixed version history for release 5.1.1
8e8312d2b 2017-08-18 Vladimir Umek - RTX5: latest libraries (IAR)
4d4b37265 2017-08-18 Robert Rostohar - RTX5: latest libraries (ARM/GCC)
84e191728 2017-08-18 Robert Rostohar - RTX5: Corrected SysTick and SVC Interrupt Priority for Cortex-M.
c5d6156df 2017-08-04 Jonatan Antoni - CMSIS 5.1.0 online documentation
d92f477be 2017-08-04 Jonatan Antoni - Merge branch 'develop' for release 5.1.0
8a1d9d6ee 2017-02-08 Joachim Krech - updating prebuild documentation for 5.0.1
de96b11d4 2017-02-08 Joachim Krech - Merge branch 'develop' for version 5.0.1
6c0e0c157 2016-11-11 Joachim Krech - CMSIS 5.0.0 online documentation
2020-10-10 13:25:12 -04:00
Daniel Agar 28efc95e29 ROMFS: posix rcS remove airframe specific defaults being applied everywhere
- these need to be set per airframe
2020-10-10 12:49:09 -04:00
Daniel Agar dfbaf6607a sensors/vehicle_imu: continue integrating queued raw data if falling behind 2020-10-10 12:30:26 -04:00
Daniel Agar f26d4f2b6b mavlink: stop unnecessarily passing around time 2020-10-09 10:30:30 -04:00
Daniel Agar 97cf714c7a mavlink: move HIGH_LATENCY2 stream to streams folder in a single header 2020-10-09 10:30:30 -04:00
Daniel Agar 94146a7b16 mavlink: move RAW_RPM stream to separate file 2020-10-09 10:30:30 -04:00
Daniel Agar 9c4abf334b mavlink: move ESC_INFO stream to separate file 2020-10-09 10:30:30 -04:00
Daniel Agar 1ddfd61d34 mavlink: move ESC_STATUS stream to separate file 2020-10-09 10:30:30 -04:00
Daniel Agar b51322e160 mavlink: name existing stream headers consistently and add include guards 2020-10-09 10:30:30 -04:00
Daniel Agar 674cd1e3b5 mavlink: move EXTENDED_SYS_STATE stream to separate file 2020-10-09 10:30:30 -04:00
JaeyoungLim 85e8c4801b Add techpod SITL Gazebo target (#15919)
* Add techpod SITL target

This adds a SITL target forthe techpod fixedwing model

* Update sitl_gazebo submoudle

This submodule update includes the techpod UAV model
2020-10-09 16:20:01 +02:00
Beat Küng 274ccaf57c system: include shutdown lock to BOARD_INDICATE_ARMED_STATE
BOARD_INDICATE_ARMED_STATE was only set during arming, so an external
component might have reset the board during param save, leading to param
loss.

This extends the API to trigger the arming state also while the shutdown
lock is taken.
2020-10-09 08:23:47 +02:00
jaeyoung 908444bd68 Add boat default rc to ROMFS
This adds the missing rc.boat_defautls to ROMFS
2020-10-09 08:11:59 +02:00
Daniel Agar eecf2e7a1e sensors: allow up to 4 accels, gyros, and baros and add configurable rotations for accel & gyro 2020-10-08 19:01:44 -04:00
Daniel Agar 28956e0399 Github actions: MAVSDK SITL tests fix log upload on failure 2020-10-08 13:10:08 -04:00
Daniel Agar 88c4876bac Update submodule mavlink v2.0 to latest Thu Oct 8 12:40:37 UTC 2020
- mavlink v2.0 in PX4/Firmware (3332f77773460a2a1463d6d7a14e5613eab166e7): https://github.com/mavlink/c_library_v2/commit/cc4220a4d4dcdf02ff3521764c120e9a4e974285
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/894599e6cba3ca6e8a32a68065b15d1a91c35af2
    - Changes: https://github.com/mavlink/c_library_v2/compare/cc4220a4d4dcdf02ff3521764c120e9a4e974285...894599e6cba3ca6e8a32a68065b15d1a91c35af2

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-10-08 09:40:04 -04:00
PX4 BuildBot 9940937636 Update submodule sitl_gazebo to latest Thu Oct 8 12:40:32 UTC 2020
- sitl_gazebo in PX4/Firmware (3f56cfe66e): https://github.com/PX4/sitl_gazebo/commit/9f74919d4db31ca561f28c4c3b8402856c26f01d
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/e4e32117df1d8aba00b0685ebd0cc5ffc066a970
    - Changes: https://github.com/PX4/sitl_gazebo/compare/9f74919d4db31ca561f28c4c3b8402856c26f01d...e4e32117df1d8aba00b0685ebd0cc5ffc066a970

    e4e3211 2020-10-07 Daniel Agar - cmake: support ccache explicitly
97b90df 2020-10-07 Thies Lennart Alff - Add buoyancy in uuv_plugin (#627)
5e03a40 2020-10-07 JaeyoungLim - Deprecate xacro macros (#623)
30e3d6a 2020-10-07 JaeyoungLim - Only add accel/gyro turn on bias on startup (#626)
2020-10-08 09:39:06 -04:00
Daniel Agar 3f56cfe66e Update submodule mavlink v2.0 to latest Wed Oct 7 12:40:52 UTC 2020
- mavlink v2.0 in PX4/Firmware (d3ddca8bf3b409abcf7e0b7cc2b979a00cdbec73): https://github.com/mavlink/c_library_v2/commit/e3d00c443602ff81cc57123fbc3b50c250b3e9ad
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/cc4220a4d4dcdf02ff3521764c120e9a4e974285
    - Changes: https://github.com/mavlink/c_library_v2/compare/e3d00c443602ff81cc57123fbc3b50c250b3e9ad...cc4220a4d4dcdf02ff3521764c120e9a4e974285

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-10-07 14:13:11 -04:00
PX4 BuildBot deee2af7ae Update submodule ecl to latest Wed Oct 7 12:41:05 UTC 2020
- ecl in PX4/Firmware (6a18e45cf8225c6dab2e7c495ed687f449e8c44e): https://github.com/PX4/ecl/commit/4c2355a63821836bf8801e996d4651dcabe0287f
    - ecl current upstream: https://github.com/PX4/ecl/commit/f666ebb99552eed796e82a20bb60e813d45eee03
    - Changes: https://github.com/PX4/ecl/compare/4c2355a63821836bf8801e996d4651dcabe0287f...f666ebb99552eed796e82a20bb60e813d45eee03

    f666ebb 2020-10-06 Paul Riseborough - EKF: Code format fix - replace 1E-x with 1e-x
e82d0af 2020-10-06 Paul Riseborough - EKF: Improve code clarity - non functional change
1a7c68e 2020-10-06 Paul Riseborough - EKF: update change indicator
759d217 2020-10-05 Paul Riseborough - EKF: Improve protection for GSF weight collapse
7c81350 2020-10-04 Paul Riseborough - EKF: Don't yaw reset if not yaw induced nav failure
bf0d70f 2020-10-04 Paul Riseborough - EKF: Protect against collapse of GSF weights
2020-10-07 14:12:10 -04:00
Daniel Agar 378cb155d6 simulator: support accel/gyro instances and stuck failure
- expand simulator to 3 accels and gyros
 - PX4Accelerometer/PX4Gyroscope switch to old param usage due to copy constructor issues with ModuleParams
2020-10-07 13:20:13 -04:00
Daniel Agar c01fabaf11 FW move altitude first order hold (FOH) and loiter to position special cases from navigator to position controller
Co-authored-by: RomanBapst <bapstroman@gmail.com>
2020-10-06 16:57:12 -04:00
Daniel Agar 9838e340e0 systemcmds/tune_control: add play error documentation 2020-10-06 10:21:15 -04:00
JaeyoungLim e0dc9900aa Fix mavros tests by updating sdf version of the iris model
This commit switches the sdf version of the iris model from 1.7 to 1.6 so that it can be run on ROS melodic, which the MAVROS tests were running in
2020-10-06 09:56:32 -04:00
Silvan Fuhrer 84455ac9e3 logger: increase logging rate of airspeed_validated from 1Hz to 5Hz
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-10-06 09:31:58 +02:00
Silvan Fuhrer 5a184d2f5c Commenting and formating fixes
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-10-06 09:31:58 +02:00
Silvan Fuhrer 8f858d95e6 Rename equivalent airspeed (EAS) to calibrated airspeed (CAS)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-10-06 09:31:58 +02:00
Silvan Fuhrer f8d5b09b56 airspeed: remove duplicated comments from cpp (they should only be in header)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-10-06 09:31:58 +02:00
Daniel Agar f01c4e769f sensors/vehicle_imu: vehicle_imu_status add mean accel/gyro
- this makes it slightly easier to gather long term data for an Allan Variance
 - fixes https://github.com/PX4/Firmware/issues/6250
2020-10-05 22:18:03 -04:00
Daniel Agar 08bf71b73d drivers/tone_alarm and tune_control small improvements/cleanup
- drivers/tone_alarm: move to ModuleBase and purge CDev (/dev/tone_alarm0)
 - drivers/tone_alarm: only run on tune_control publication (or scheduled note) rather than continuously
 - drivers/tone_alarm: use HRT to schedule tone stop (prevents potential disruption)
 - msg/tune_control: add tune_id numbering
 - systemcmds/tune_control: add "error" special case tune_id
 - move all tune_control publication to new uORB::PublicationQueued<>
 - start tone_alarm immediately after board defaults are loaded to fix potential startup issues
 - for SITL (or other boards with no TONE output) print common messages (startup, error, etc)
2020-10-05 21:39:26 -04:00
jaeyoung c7072b61a3 Update jsbsim bridge to latest master
Update jsbsim bridge to latest master
2020-10-05 20:20:04 -04:00
jaeyoung b7c1f6a857 Update sitl_gazebo to latest master
Update sitl_gazebo to latest master
2020-10-05 20:18:59 -04:00
Daniel Agar 016ee6ea59 battery: fix duplicate uORB publish and minor cleanup
- run battery_status module on adc_report publications rather than a fixed schedule
2020-10-05 11:01:58 -04:00
Daniel Agar be28c4d309 lib/rc: dsm_bind() add debug output for binding
- trivial code style cleanup
2020-10-04 22:23:47 -04:00
Daniel Agar ddce711acb drivers/rc_input: command line bind use vehicle_command 2020-10-04 22:23:47 -04:00
Daniel Agar 1bf0218c87 boards: mRo Control Zero F7 fix RC input and cleanup sensors init 2020-10-04 22:23:47 -04:00
Daniel Agar eabbd19c1c commander: PreFlightCheck param_find all parameters immediately
- this ensures the relevant parameters are marked active immediately
before parameter sync
 - fixes https://github.com/PX4/Firmware/issues/15872
2020-10-03 14:43:21 -04:00
blazczak 57da61dc17 posix-configs/rpi: Fix mavlink over UART (/dev/ttyAMA0)
UART is the primary interface for telemetry radio: https://docs.emlid.com/navio2/ardupilot/hardware-setup/#uart-radio

Check first if /dev/ttyUSB0 exists (https://docs.emlid.com/navio2/ardupilot/hardware-setup/#usb-radio); if not, fall back to configuring over UART (/dev/ttyAMA0).

Use stricter check for character special file (-c) rather than just file (-f).

'console=serial0,115200' needs to be removed from /cmdline.txt as additional configuration step. This should be documented in the Navio2 section of docs.px4.io. Presumably, this is already performed as part of the Raspberry Pi OS prebuilt image Emlid spins.
2020-10-03 10:51:27 -04:00
Beat Küng 91fa2002e3 kakutef7: fix output ordering
Regression from d2254c2e44, I overlooked that they were defined in
reverse order.
2020-10-03 10:45:30 -04:00
Daniel Agar 8ee0c62e57 examples: add Gyro FFT using CMSIS 5 on Cortex-m (#15104)
- this is a work in progress experiment to compute real time FFTs from raw gyro FIFO data on Cortex-m hardware (stm32f4/f7/h7, etc)
2020-10-02 11:47:27 -04:00
Daniel Agar 23aa9ac70f cmake nuttx add STM32H7 debug helpers 2020-10-02 11:31:18 -04:00
Alex Mikhalev c648d52909 uavcan: Increase uavcan main stack size
I observed stack overflows when executing `uavcan params list`, so the
stack size probably needs to be increased.

Signed-off-by: Alex Mikhalev <alexmikhalevalex@gmail.com>
2020-10-02 01:31:27 -04:00
SalimTerryLi 25eca31e3a New board Scumaker AirPi HAT for Raspberry Pi B series 2020-10-01 11:22:47 -04:00
Nicolas MARTIN 967f741a0e commander: add parameter COM_REARM_GRACE to optionally disable re-arming grace period 2020-10-01 11:20:08 -04:00
Daniel Agar c1936dab1f commander: accel & gyro subsystem health set within IMU check 2020-09-30 12:17:48 -04:00
Daniel Agar 25c537bae9 commander: don't impose additional timeouts in sensor checks
- the sensors hub is responsible for sensor timeouts
2020-09-30 12:17:48 -04:00
CarlOlsson 98c8cbb27f ekf2: fix odom body rate sign bug 2020-09-30 11:34:37 -04:00
Julian Oes b454095776 commander: fix switch to loiter
Sometimes, the mission_result timestamp is the same as the
internal_state timestamp which would meant that we would not switch to
LOITER even though the takeoff is clearly done at that point.
2020-09-30 08:23:16 -04:00
David Sidrane 46f0388fc7 Reanable BL Update - Reverts b5267c06073023893d5a11b9011ef009b5291097 2020-09-29 23:44:24 -04:00
David Sidrane 68703135c3 bl_update:Respect page size if it matters
Track Changes in NuttX stm32h7 flash driver:
   The STM32H7 flash driver uses up_progmem_pagesize to
   describe minimum write size to satify the block size
   requierment for ECC.

   Therefore, the image size needs to be padded to a multiple
   of up_progmem_pagesize()
2020-09-29 23:44:24 -04:00
JaeyoungLim ff6b82cb6b Replace xacro macros to jinja templates for multivehicle (#15831)
This commit switches xacro macros to jinja templates for multivehicle simulations.
2020-09-29 15:45:57 +02:00
JaeyoungLim 9d3e159e65 Make mavsdk test runner handle generated sdf files (#15797)
Update sitl_gazebo
Fix indent errors
Fix syntax error
Fix indentation errors
Fix syntax errors
use autopep8
2020-09-29 15:44:58 +02:00
Daniel Agar c9c20666a2 sensors: sanity check differential pressure temperature (#15845)
- if valid temperature unavailable then use ICAO Standard Atmosphere 15 degrees celcius
2020-09-29 09:35:34 -04:00
Nicolas Martin da4d0e650a mc_pos_control: fix acc Z sign 2020-09-29 13:09:51 +02:00
Daniel Agar 24ffed827f ROMFS: 50000_generic_ground_vehicle remove fmu-v2 exclude
- this allows px4_fmu-v2_rover to function until we have a better mechanism for including or excluding ROMFS dependencies #15711
2020-09-28 22:43:28 -04:00
David Sidrane 59f20a26eb motor_params:Move to mixer_module
sensors having mixer_module creates a dependency on sensors for
   the param MOT_SLEW_MAX. Things that do not uses sensors.
   IE. PWM only device should not have to include them.
2020-09-28 20:47:40 -04:00
Daniel Agar f1feaf45d3 EKF2: move vehicle_odometry publish to method 2020-09-28 18:34:49 -04:00
Daniel Agar faccb0d948 Jenkins: HIL script minor improvements
- periodically send newline while checking for output or command completion (back to nsh prompt)
 - mtd test
 - fix adc test (now board_adc)
2020-09-28 16:41:28 -04:00
JaeyoungLim c342ab91b3 Fix the world path being corrupting when spawning none-default world
This fixes a bug, where the world file path was being corrupted when using non-default world paths
2020-09-28 13:07:29 -04:00
JaeyoungLim f7356d0286 Update jsbsim_bridge to latest master 2020-09-28 13:05:20 -04:00
Daniel Agar fe6a1ce882 simulator: fix airspeed temperature
- HIL_SENSOR temperature is only being sent with barometer data
2020-09-28 12:56:56 -04:00
Daniel Agar 828134c56f sensor_calibration: add link dependencies 2020-09-28 12:26:38 -04:00
David Sidrane 529d816a39 px4_fmu-v6x:Support ETM Hardware Trace 2020-09-28 10:59:39 -04:00
PX4 BuildBot 1822a678f6 Update submodule ecl to latest Mon Sep 28 12:39:19 UTC 2020
- ecl in PX4/Firmware (2b34fec0844646d13a57f78dbbed44b53813919e): https://github.com/PX4/ecl/commit/6b99ea2a6038c536f92aaa2b7d24ce7962e55df6
    - ecl current upstream: https://github.com/PX4/ecl/commit/4c2355a63821836bf8801e996d4651dcabe0287f
    - Changes: https://github.com/PX4/ecl/compare/6b99ea2a6038c536f92aaa2b7d24ce7962e55df6...4c2355a63821836bf8801e996d4651dcabe0287f

    4c2355a 2020-09-25 Daniel Agar - EKF: use GPS to lookup declination from WMM before full GPS checks pass
2020-09-28 10:58:33 -04:00
Daniel Agar cf26f24387 msg: add quaternion euler angle pretty print 2020-09-28 10:13:43 -04:00
justas- bb77f55f7b motor_test: Use 1-based motor indexing.
Motors in Px4 ecosystem are indexed using 1-based indexing (Airframe reference, dshot command, etc.) motor_test command is 0-based. This PR changes motor_test to use 1-based indexing.

This PR refers to Github issue #15721.
2020-09-28 10:59:41 +02:00
flochir ec7108892b batt_smbus: fix potential hardfault by checking buffer sizes (#15789)
* Added buffer length check to SMBus::block_read (triggered hardfault in batt_smbus module by writing beyond buffer end due to device returning longer byte_count than requested/expected)

Co-authored-by: Florian Olbrich <florian.olbrich@scarabot.de>
Co-authored-by: Daniel Agar <daniel@agar.ca>
Co-authored-by: BazookaJoe1900 <BazookaJoe1900@gmail.com>
Co-authored-by: Beat Küng <beat-kueng@gmx.net>
2020-09-28 09:41:40 +02:00
Daniel Agar 6a08e16351 Update submodule mavlink v2.0 to latest Sat Sep 26 15:30:19 UTC 2020
- mavlink v2.0 in PX4/Firmware (aab65cdc3261a4ca315d5b91d65e0dd3e39940d0): https://github.com/mavlink/c_library_v2/commit/09524c98db4eb389d3d50f7905a17805b216a9ea
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/e3d00c443602ff81cc57123fbc3b50c250b3e9ad
    - Changes: https://github.com/mavlink/c_library_v2/compare/09524c98db4eb389d3d50f7905a17805b216a9ea...e3d00c443602ff81cc57123fbc3b50c250b3e9ad

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-09-26 13:14:25 -04:00
PX4 BuildBot 6df50cb74f Update submodule ecl to latest Sat Sep 26 15:30:31 UTC 2020
- ecl in PX4/Firmware (5784cb6e5eb74fcf07f3da058692c7c2320851b9): https://github.com/PX4/ecl/commit/fab242a81f3836de716b0ed96fcc841360c3a867
    - ecl current upstream: https://github.com/PX4/ecl/commit/6b99ea2a6038c536f92aaa2b7d24ce7962e55df6
    - Changes: https://github.com/PX4/ecl/compare/fab242a81f3836de716b0ed96fcc841360c3a867...6b99ea2a6038c536f92aaa2b7d24ce7962e55df6

    6b99ea2 2020-09-24 Daniel Agar - ECL standalone build improve ECL_INFO/WARN/DEBUG
5879eaa 2020-09-25 bresch - ekf: fix variable length array error
99aafba 2020-09-14 Daniel Agar - README: remove obsolete build status
2020-09-26 13:13:51 -04:00
Tanja Baumann b5ebdb8e41 add system command to get and set system time
* add system_time command for all boards
2020-09-26 13:09:01 -04:00
PX4 BuildBot b5df4f76cc Update submodule nuttx to latest Sat Sep 26 15:30:26 UTC 2020
- nuttx in PX4/Firmware (59f5b841a6646a7ae514ae1139ba18c3f787ceb3): https://github.com/PX4/NuttX/commit/a8b7ca869e08e0ca58f20ae1e5732220ef98846f
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/0fe69f6cc0a6f202b61ff81be0560cafb8f3a89d
    - Changes: https://github.com/PX4/NuttX/compare/a8b7ca869e08e0ca58f20ae1e5732220ef98846f...0fe69f6cc0a6f202b61ff81be0560cafb8f3a89d

    0fe69f6cc0 2020-09-25 David Sidrane - [BACKPORT] stm32f7:serial Bug Fix: Ensure next buffer is processed
2020-09-26 09:47:03 -07:00
Jacob Dahl a24488328f Move GPS blending from ekf2 to sensors module
- new sensors work item that subscribes to N x sensor_gps and publishes vehicle_gps_position
 - blending is now configurable with SENS_GPS_MASK and SENS_GPS_TAU

Co-authored-by: Jacob Crabill <jacob@volans-i.com>
Co-authored-by: Jacob Dahl <dahl.jakejacob@gmail.com>
2020-09-25 23:28:31 -04:00
Daniel Agar e792c46f20 mavlink: increase stack 2650 -> 2848 bytes (#15821) 2020-09-25 21:42:02 -04:00
Daniel Agar f37d0a85e2 Jenkins: remove remaining SITL tests (MC_avoidance/MC_safe_landing)
- MC_avoidance and MC_safe_landing are currently failing intermittently and will be migrated to Github Actions
2020-09-25 12:28:26 -04:00
Daniel Agar 861e06dfd7 mavlink: handle receiving GENERATOR_STATUS
- only published (ORB_ID(generator_status)) and logged for now
2020-09-25 11:36:58 -04:00
Daniel Agar c57a48682e Tools: ecl analysis handle estimator_innovations/estimator_innovation_variances size inconsistencies 2020-09-25 10:35:01 -04:00
Daniel Agar 2ccf664e95 commander: disarm from safety relax land detector timeout
- ensure land detector is updated before safety is checked
2020-09-25 09:41:53 -04:00
jaeyoung 1dbd7df83b Switch VERBOSE to VERBOSE_SIM
This changes the environment variable `VERBOSE` to `VERBOSE_SIM`, to explicitly state that it configures the verbose output of the simulation
2020-09-25 10:42:35 +02:00
Daniel Agar 60252dde08 Jenkins: SITL tests disable ninja build to reduce build parallelism
- test slaves have limited memory
2020-09-24 15:56:57 -04:00
Daniel Agar bbdc57a662 cmake: remove sitl_gazebo build -j2
- allow ninja build to automatically determine parallelism
2020-09-24 15:56:57 -04:00
Matthias Grob bcbc761bf6 Revert "Change defaults for MPC_LAND_ALT"
This reverts commit 59bd3e9f6e.
2020-09-24 19:18:58 +02:00
Daniel Agar 0dc8bb9c86 uORB: increase ORB_MULTI_MAX_INSTANCES 4 -> 10
- put more realistic bounds on maximum number of battery instances, gps, etc
2020-09-24 11:01:28 -04:00
Daniel Agar f04f0c89ca boards: CUAV Nora/X7pro fix BOARD_DSHOT_MOTOR_ASSIGNMENT
- BOARD_DSHOT_MOTOR_ASSIGNMENT isn't needed if there's no remapping
2020-09-24 10:53:54 -04:00
Daniel Agar 762d925d20 boards: cubepilot orange/yellow fix BOARD_DSHOT_MOTOR_ASSIGNMENT 2020-09-24 10:53:54 -04:00
Matthias Grob 5d47a4c9e0 Commander: fix rc override threshold scaling (#15807)
Improve parameter description for threshold
and lower the threshold a bit.
2020-09-24 14:52:19 +02:00
Daniel Agar 0a607bdc67 boards: CUAV CAN_GPS v1.2 cannode (stm32f412) with UAVCAN bootloader 2020-09-23 14:30:54 -04:00
Daniel Agar 8579b5dd26 uORB: Subscription add copy/move constructor and assignment 2020-09-23 10:04:54 -04:00
Matthias Grob bf248746ce mavlink_messages: cast rotation types for assert 2020-09-23 09:08:23 -04:00
Daniel Agar d5295ef4e1 mavlink: add static asserts to keep MAV_SENSOR_ROTATION in sync with PX4 ROTATION 2020-09-22 11:10:31 -04:00
Daniel Agar 00e955cc3e rotations: sync rotation enum, SENS_BOARD_ROT, CAL_MAGx_ROT with MAV_SENSOR_ORIENTATION 2020-09-22 11:10:31 -04:00
Daniel Agar 8b26b84fd1 Jenkins: hardware disable holybro durandal bootloader update
- this is currently bricking the board
2020-09-21 22:51:11 -04:00
Daniel Agar 43903dcb79 Jenkins: temporarily disable catkin build on ROS workspace 2020-09-21 22:48:33 -04:00
Daniel Agar d676e65294 logger: log_writer_file increase stack 1170 -> 1472 bytes (#15765) 2020-09-21 22:17:31 -04:00
Yashom Dighe 5daca6c2c4 IntrusiveSortedList.hpp: let operator* return a reference
So that clang 12 does not complain:
loop variable 'child' is always a copy because the range of type 'List<ModuleParams *>' does not return a reference

Co-authored-by: Yashom Dighe <yashom7@gmail.com>
2020-09-21 16:55:04 -04:00
Daniel Agar e4a408bc55 cmake nuttx build modify copied nuttx repo .git to point to actual git dir
- this fixes builds that contain a px4io and use the Makefile generator rather than Ninja
2020-09-21 12:39:29 -04:00
Daniel Agar 4d97772756 vscode: SITL debug add gazebo world select 2020-09-21 11:56:25 -04:00
Daniel Agar 2728af4264 boards: cubeorange and cubeyellow disable serial console (used for ADSB on new carrier boards)
- add console builds (cubepilot_cubeorange_console) for hardware test rack and developers
2020-09-21 11:53:49 -04:00
bresch 1141cfa7c6 ekf2_main: reduce update mag bias minimum learning time to 30s
120 seconds of learning time in 3D fusion mode was too long for most normal flights. The learned bias is usually really good after a shorter period and was not used to update the parameters. 30s seems to be a good compromise.
2020-09-21 15:54:24 +02:00
Beat Küng 5ac0c7c799 List.hpp: let operator* return a reference
So that clang 12 does not complain:
loop variable 'child' is always a copy because the range of type 'List<ModuleParams *>' does not return a reference
2020-09-21 09:23:21 -04:00
Daniel Agar 09af5e0637 commander: mag calibration use expected WMM sphere radius to reject samples if GPS is available 2020-09-20 12:22:56 -04:00
bazooka joe 727b0cf530 moved posix airframe files to folder, same as in regullar init.d folder
and add some debugging info when succeeded/fail to find air-frame file
2020-09-19 21:31:39 -04:00
Daniel Agar 940dc9cca0 cmake NuttX build fix path to git dir
- this relative path was incorrect for the px4io when using the Makefile generator and built for inclusion within another build (eg px4_fmu-v5_default)
2020-09-18 21:18:36 -04:00
Daniel Agar abbd335e4e uavcannode: use correct PYTHON_EXECUTABLE and support stm32h7
- sync CMakeLists.txt with drivers/uavcan
2020-09-18 13:03:07 -04:00
Daniel Agar d61fd0e4ca update all px4-dev-base and px4-dev-nuttx container usage uniformly 2020-09-18 13:03:07 -04:00
Daniel Agar 41a2fe5bdf gitmodules update NuttX branches 2020-09-18 12:10:34 -04:00
Beat Küng 5fdff6a0e4 i2c drivers: add '-k' flag for keep_running directly to BusCLIArguments 2020-09-18 09:45:06 -04:00
Beat Küng 1bf030e8ba lps33hw: refactor and add -k flag to keep running even if no sensor found 2020-09-18 09:45:06 -04:00
jaeyoung 24adf36097 Add jsbsim multirotor targets to cmake 2020-09-18 10:25:52 +02:00
Beat Küng f106e6b266 param: add 'param show-for-airframe' command
- simplifies creation of an airframe config
- could be done from QGC, but it only knows if a param is non-default from
  metadata, which can be incorrect/missing information
- for the list of exceptions we could look at '@category', but we don't have
  that info in the build
- there might be some more exceptions to be added
2020-09-18 09:03:29 +02:00
JaeyoungLim 458420f9cb Add jsbsim bridge to enable jsbsim for px4 SITL on jsbsim (#15748)
* Add jsbsim bridge to enable jsbsim for px4 SITL/HIL on jsbsim

This is a PX4 HIL/SITL integration into JSBSim. JSBSim is an open source flight dynamics model (http://jsbsim.sourceforge.net/)

Currently there are three models available which is the rascal, quadrotor_x, hexarotor_x integrated into the bridge.

The simulation can be run with the firmware with the following command for example
```
make px4_sitl jsbsim_rascal
```

The visualization is done flightgear and is done by the bridge sending UDP packets to flightgear. To disable the visualization `HEADLESS=1` when running the make command.

The simulation can be configured through the configuration files under the `config` directory through a xml file. Senor configurations,  The xml file name should match the name of the model.

* Update Tools/sitl_run.sh

Co-authored-by: Beat Küng <beat-kueng@gmx.net>

Co-authored-by: Beat Küng <beat-kueng@gmx.net>
2020-09-17 20:32:42 +02:00
David Sidrane c5f479dac7 uvify_core: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 240dfaa515 spracing_h7extreme: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane c7642288db px4_fmu-v6x: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 1a51a84130 px4_fmu-v6x: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane b83fdfda37 px4_fmu-v5x: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 733c1b747b px4_fmu-v5x: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 075690af9d px4_fmu-v5: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 8e3ba3b0b3 px4_fmu-v5: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane d2e7542e39 px4_fmu-v5: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane dab2069f53 px4_fmu-v5: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane e3f5af4887 px4_fmu-v5: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 8a3f4f285a px4_fmu-v5: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane ccc439504d px4_fmu-v4pro: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane f5fca39253 px4_fmu-v4: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 3457c30ab3 px4_fmu-v4: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 7a50f00b00 px4_fmu-v4: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 347ab5daaa px4_fmu-v3: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane c620059076 px4_fmu-v3: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 42b466dc45 px4_fmu-v2: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 4bc698e8e3 omnibus_f4sd: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 65ddf98d76 nxp_rddrone-uavcan146: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 94b5c961bc nxp_fmurt1062-v1: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane a7365100f4 nxp_fmuk66-v3: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 1936ead0b4 nxp_fmuk66-v3: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 3f82b19fc7 nxp_fmuk66-e: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane afad60a0bc nxp_fmuk66-e: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 00b4807443 mro_x21: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 4f5c88fc89 mro_x21-777: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 1e55ce0839 mro_ctrl-zero-f7: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 05a415cf4a modalai_fc-v1: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 0727db04a3 intel_aerofc-v1: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 15c8a26a21 holybro_pix32v5: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane f77bf7f475 holybro_kakutef7: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 6681b1ac44 holybro_durandal-v1: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 5dc5ef664f holybro_durandal-v1: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane fc5caf382c cubepilot_cubeyellow: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 0d9d1e79e8 cubepilot_cubeorange: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 5c95d8876a cuav_x7pro: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 9bd88c34a9 cuav_nora: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 9106386613 bitcraze_crazyflie: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane aa463e31b4 av_x-v1: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane 34d1fcc704 airmind_mindpx-v2: Updates for NuttX 9.1.0+ External schedule_note 2020-09-16 21:32:04 -04:00
David Sidrane c17a0ebacf holybro_durandal-v1:Add support for DMA on SPI6 2020-09-16 21:32:04 -04:00
David Sidrane 848b0ea88c cuav_x7pro:Add support for DMA on SPI6 2020-09-16 21:32:04 -04:00
David Sidrane 2745ffe946 cuav_nora:Add support for DMA on SPI6 2020-09-16 21:32:04 -04:00
David Sidrane 72c681134d px4_fmu-v6x:Add support for DMA on SPI6 2020-09-16 21:32:04 -04:00
David Sidrane 768ed297f2 uavcan_stm32h7:Support is by Family Not Chip/pacakge 2020-09-16 21:32:04 -04:00
David Sidrane f0b8bc9dd6 run-shellcheck appease shell check 2020-09-16 21:32:04 -04:00
David Sidrane f3c2ed5eb6 ROMFS/CMakeLists appease shell check 2020-09-16 21:32:04 -04:00
David Sidrane 6e1078c96e NuttX-Posix least bad LGD
Nuttx now supports sh and source (.)
   sh will open a new process for each invocation.
   This means the child can not modify the parent
   env. So we must use . to matain how nuttx worked.

   Since rc.vehicle_setup is used in both we use
   source and alis as we did with sh.
2020-09-16 21:32:04 -04:00
David Sidrane 323dd389fe vehicle_imu:VehicleIMU Fix style issues 2020-09-16 21:32:04 -04:00
David Sidrane d437379142 spracing_h7extreme:qspi Fix style issues 2020-09-16 21:32:04 -04:00
David Sidrane 59ba09d73c CI use 2020-08-14 with gcc 9.3.1 2020-09-16 21:32:04 -04:00
David Sidrane 760f2ecb22 LoadMon:track upstream malloc changes 2020-09-16 21:32:04 -04:00
David Sidrane c948d41284 up_cxxinitialize:is now automatic in task start 2020-09-16 21:32:04 -04:00
David Sidrane 185ffe9e13 nsh scripting:source (.) cmd supported 2020-09-16 21:32:04 -04:00
David Sidrane df30f29a55 NuttX/Make.defs.in Support PROBEs 2020-09-16 21:32:04 -04:00
David Sidrane fbf110f6be Use EXTRAFLAGS instead of EXTRADEFINES 2020-09-16 21:32:04 -04:00
David Sidrane b2a31e15da common:board_crashdump.c track upstream API change 2020-09-16 21:32:04 -04:00
David Sidrane f77fc690c7 hott:Fix compiler error array bound is unknown
This fixes error: variable-length array bound is unknown [-Werror=vla-larger-than=]
   with gcc 9.1
2020-09-16 21:32:04 -04:00
David Sidrane e3e7cb4158 PX4 add compiler dependent: disable no-stringop-truncation 2020-09-16 21:32:04 -04:00
David Sidrane c49c767d78 NuttX add compiler dependent: disable no-stringop-truncation 2020-09-16 21:32:04 -04:00
David Sidrane 4d64065422 NuttX:Make.defs.in fix macro to not kill flock 2020-09-16 21:32:04 -04:00
David Sidrane 852d5ceb22 NuttX CMakeLists build .version file in build 2020-09-16 21:32:04 -04:00
David Sidrane 68e3fd9f37 cpuload Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane 06d030b6d9 px4iofirmware Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane b32aab2d0f platform Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane 97c17d5d4a uvify_core Updates for NuttX 9.1.0-
uvify_core: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane f9adf861dc spracing_h7extreme Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane 8cb1fe5a54 px4_io-v2 Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane f870594f1d px4_fmu-v6x Updates for NuttX 9.1.0-
px4_fmu-v6x: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane acea295d5a px4_fmu-v5x Updates for NuttX 9.1.0-
px4_fmu-v5x: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane b52e10720e px4_fmu-v5 Updates for NuttX 9.1.0-
px4_fmu-v5: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane f98d10bf15 px4_fmu-v4pro Updates for NuttX 9.1.0-
px4_fmu-v4pro: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 9986f63321 px4_fmu-v4 Updates for NuttX 9.1.0-
px4_fmu-v4: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 0da14887d0 px4_fmu-v3 Updates for NuttX 9.1.0-
px4_fmu-v3: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 77ce7b2457 px4_fmu-v2 Updates for NuttX 9.1.0-
px4_fmu-v2: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 9a19340dc3 omnibus_f4sd Updates for NuttX 9.1.0-
omnibus_f4sd: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 1285c79b6b kinetis uavcan_drivers Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane ddacf357a7 nxp_rddrone-uavcan146 Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane 5698bc254a nxp_fmurt1062-v1:Track PX4 Sensor changes 2020-09-16 21:32:04 -04:00
David Sidrane 1abe88df61 nxp_fmurt1062-v1 Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane aa67fbdbcb nxp_fmuk66-e: Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane 8a673c8a3d nxp_fmuk66-v3 Updates for NuttX 9.1.0-
nxp_fmuk66-v3: defconfig MMCSD enable multiblock

nxp_fmuk66-v1:Disable multiblock as it fails
2020-09-16 21:32:04 -04:00
David Sidrane aa1cb370e4 mro_x21 Updates for NuttX 9.1.0-
mro_x21: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane c9a323ebcc mro_x21-777 Updates for NuttX 9.1.0-
mro_x21-777: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 2550d6f7c1 mro_ctrl-zero-f7 Updates for NuttX 9.1.0-
mro_ctrl-zero-f7: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane c8ef85c090 modalai_fc-v1 Updates for NuttX 9.1.0-
modalai_fc-v1: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 20398c3933 intel_aerofc-v1 Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane c2419e7f3d holybro_pix32v5: Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane abe9f1a768 holybro_kakutef7 Updates for NuttX 9.1.0-
holybro_kakutef7: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 59f914427c holybro_durandal-v1 Updates for NuttX 9.1.0-
holybro_durandal-v1: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane f21925f976 cubepilot_io-v2: Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane e8e463b875 cubepilot_cubeyellow Updates for NuttX 9.1.0-
cubepilot_cubeyellow: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 5691bf1dee cubepilot_cubeorange Updates for NuttX 9.1.0-
cubepilot_cubeorange: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane e16efd9643 cuav_x7pro Updates for NuttX 9.1.0-
cuav_x7pro: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 93e3b52515 cuav_nora Updates for NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
David Sidrane b8db1e6380 bitcraze_crazyflie Updates for NuttX 9.1.0-
bitcraze_crazyflie: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane e487833347 av_x-v1 Updates for NuttX 9.1.0-
av_x-v1: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane 8e97ae323e airmind_mindpx-v2 Updates for NuttX 9.1.0-
airmind_mindpx-v2: defconfig MMCSD enable multiblock
2020-09-16 21:32:04 -04:00
David Sidrane c57024e6bb NuttX 9.1.0- 2020-09-16 21:32:04 -04:00
Julian Oes 720784b9e9 workflows: update MAVSDK used for SITL test 2020-09-16 12:51:56 -04:00
Julian Oes 44b4a6eb74 mavsdk_tests: increase time for manual tests 2020-09-16 12:51:56 -04:00
Julian Oes 9ed07a7873 simulator: fix temperature setting after rebase 2020-09-16 12:51:56 -04:00
Julian Oes e7651c94f6 mavsdk_tests: use custom rootfs, reset it
Instead of messing with existing params, use a separate rootfs for
tests, as suggested by @bkueng.
2020-09-16 12:51:56 -04:00
Julian Oes 517114042a failure: use time literal 2020-09-16 12:51:56 -04:00
Julian Oes a37b839e27 simulator: add missing timestamp 2020-09-16 12:51:56 -04:00
Julian Oes b1219811c5 mavlink: SYS_FAILURE_EN is just a bool
Thanks @bkueng for the review comment.
2020-09-16 12:51:56 -04:00
Julian Oes 012763e5f1 mavsdk_tests: fly forward a bit longer
Hopefully, that's long enough for slow VTOLs.
2020-09-16 12:51:56 -04:00
Julian Oes b4ac50ced4 failure: add missing command usage docstring 2020-09-16 12:51:56 -04:00
Julian Oes 58b4135ab0 mavsdk_tests: wait even longer
Again, hopefully that's enough.
2020-09-16 12:51:56 -04:00
Julian Oes a299e2c57d mavsdk_tests: fly forward even longer
Hopefully that's enough.
2020-09-16 12:51:56 -04:00
Julian Oes 4c00c1f561 mavsdk_tests: add missing switch to POSCTL 2020-09-16 12:51:56 -04:00
Julian Oes bbef07bc80 mavsdk_tests: init RC with throttle centered 2020-09-16 12:51:56 -04:00
Julian Oes c26b769cc0 mavsdk_tests: add missing type annotation 2020-09-16 12:51:56 -04:00
Julian Oes d2cb27e0de mavsdk_tests: try with faster RC rate 2020-09-16 12:51:56 -04:00
Julian Oes f8f03835ad mavsdk_tests: increase timeouts yet again
This is after using PX4 time to check for timeouts.
2020-09-16 12:51:56 -04:00
Julian Oes 3135b94980 mavsdk_tests: use PX4 time for timeouts
This way we are less dependent on CPU load of the host.
2020-09-16 12:51:56 -04:00
Julian Oes ca0f26a003 mavsdk_tests: added posctl/altctl test 2020-09-16 12:51:56 -04:00
Julian Oes 0a7dcf26d5 mavsdk_tests: clean up includes 2020-09-16 12:51:56 -04:00
Julian Oes 630a6f3810 mavsdk_tests: clear params between test cases 2020-09-16 12:51:56 -04:00
Julian Oes a5a577a6c4 mavsdk_tests: use speed factor, increase timeouts
We had not actually properly adjusted the timeout to the lockstep speed
factor. Once we did that, we had to increase the timeouts quite a bit to
have the tests pass.
2020-09-16 12:51:56 -04:00
Julian Oes 4eb1ea10f0 mavsdk_tests: don't block inside of callback
This is required with MAVSDK v0.29.0 and later!
2020-09-16 12:51:56 -04:00
Julian Oes 8d3f1e63f0 mavsdk_tests: use all os env vars by default 2020-09-16 12:51:56 -04:00
Julian Oes 55d2bdc438 mavsdk_tests: adapt to changed inject API
We now need to say which instance, for now it's all instances.
2020-09-16 12:51:56 -04:00
Julian Oes 06ad0de5eb workflows: move to MAVSDK v0.29.0 2020-09-16 12:51:56 -04:00
Julian Oes ed357cf356 mavsdk_tests: move math things to separate header 2020-09-16 12:51:56 -04:00
Julian Oes 1eaceb17dc mavsdk_tests: adjust timeouts by lockstep speed up 2020-09-16 12:51:56 -04:00
Julian Oes 4d76ed34f3 simulator: update temperature in sync with baro
This fixes the case where the baro was not rejected if stuck because the
temperature still varied.
2020-09-16 12:51:56 -04:00
Julian Oes 20621e6744 mavsdk_tests: add tests for GPS as height source 2020-09-16 12:51:56 -04:00
Julian Oes c31246e13a mavsdk_tests: add test for stuck mag 2020-09-16 12:51:56 -04:00
Julian Oes afcfa2fbe0 mavsdk_tests: check for stuck baro 2020-09-16 12:51:56 -04:00
Julian Oes a05ad9c64c mavsdk_tests: add wildcards for case filtering 2020-09-16 12:51:56 -04:00
Julian Oes c4efcbf895 mavsdk_tests: check for baro failure in mission 2020-09-16 12:51:56 -04:00
Julian Oes 8d6ebf15b6 mavsdk_tests: test for losing mag during mission 2020-09-16 12:51:56 -04:00
Julian Oes ef7e4531f9 mavsdk_tests: enable GPS lost test for VTOL
This is in multicopter mode only for now though.
2020-09-16 12:51:56 -04:00
Julian Oes 3c499fc3a2 mavsdk_tests: add first GPS lost failsafe test 2020-09-16 12:51:56 -04:00
Julian Oes db87ba3a1c systemcmds: add new failure command
This adds a new systemcmd to inject failures into the system.
2020-09-16 12:51:56 -04:00
Julian Oes a9c4f269bd simulator: use failure injection to block GPS
This uses the new failure injection system using vehicle_commands
instead of specific parameters. For now it implements GPS only.
2020-09-16 12:51:56 -04:00
Julian Oes 53b14233a2 mavlink: handle failure injection commands
This adds handling of MAVLink failure injection commands. An
additional parameter is added as a guard to prevent triggering any
failures by accident.
2020-09-16 12:51:56 -04:00
Daniel Agar 12ab762adc sensor_calibration: silence error if priority is -1 (uninitialized parameter value) 2020-09-16 12:32:40 -04:00
Daniel Agar 033f74b1c8 sitl_run.sh remove xtrace leftover from debugging 2020-09-16 10:43:29 -04:00
Peter van der Perk aaea6b3f3b Add FMUK66-V3 RTPS target to CI 2020-09-16 09:42:34 -04:00
Peter van der Perk 0caad08dd5 Added RTPS target for FMUK66-V3 2020-09-16 09:42:34 -04:00
Beat Küng abf5c2b301 ROMFS/CMakeLists.txt: change dependencies
- moves process airframe deps to the tar generation, to ensure whenever
  airframes are processed, the tar is extracted first.
  This is required, because if the airframe processing is done on pruned
  ROMFS, it's missing the tags.
- avoid using init.d/rcS in dependencies, use a separate file instead.
  This is because pruning modifies the rcS, and the next rebuild was
  seeing a changed rcS, resulting in unnecessary regeneration.
2020-09-16 09:30:58 -04:00
Daniel Agar 2b18b05a8a vscode updates and improvements
- fix gazebo SITL debug
     - now prompts you to select vehicle
 - devcontainer.json container support https://code.visualstudio.com/docs/remote/containers
     - this allows you to jump straight into working within a container (px4-dev-nuttx) on a fresh machine
     - also helps with Codespaces https://github.com/features/codespaces
 - plugin updates
    - cpp extension pack, spell checking, CTest support
 - cleanup intellisense
     - the backup tag parser was a resource hog and didn't work very well
 - fix problemMatcher support so that you can click on a build failure
2020-09-16 09:07:54 -04:00
Nicolas MARTIN 504730386a fix COM_ARM_AUTH comment 2020-09-15 22:12:55 -04:00
Daniel Agar 0e9a4cc65f boards: px4/sitl sync all build variants and fix none default package 2020-09-15 21:13:04 -04:00
Daniel Agar 5e4e4a4573 boards: aerotenna ocpoc fix package (new ROMFSROOT was missing) 2020-09-15 21:13:04 -04:00
Daniel Agar c41f053c7b vehicle_imu/vehicle_magnetometer add calibration indicator to message
- vehicle_imu/vehicle_magnetometer add monotonically increasing `calibration_count` field so that downstream subscribers are aware of calibration changes
2020-09-15 13:12:57 -04:00
Daniel Agar 87471a988d land_detector: use hover thrust if it was valid recently
- the hover thrust estimate will often invalidate upon ground contact, but before the land detector ground_contact triggers
 - use same time throughout call to avoid subtle timing surprises
2020-09-15 10:17:25 -04:00
Daniel Agar dc507ee544 sensors: add SENS_MAG_MODE to optionally publish all magnetometers 2020-09-15 10:15:39 -04:00
Daniel Agar a04412fc1f sensors: add SENS_IMU_MODE to optionally skip IMU voting/selection 2020-09-15 10:15:39 -04:00
Mirko Denecke 5ebc4d31da CubeOrange and CubeYellow IMU heating fix 2020-09-15 10:08:58 -04:00
Beat Küng ef55680ab1 sitl: enable EMBEDDED_METADATA to add parameter metadata to ROMFS 2020-09-15 09:30:16 +02:00
Beat Küng 0a061160f7 cmake px4_add_board: add EMBEDDED_METADATA
Allowing to put additional metadata into the ROMFS, the first is
parameters.json.gz.
2020-09-15 09:30:16 +02:00
Beat Küng d5b8f6cdf9 sitl_run.sh: cleanup, kill jmavsim only if $program == jmavsim 2020-09-15 09:30:16 +02:00
Beat Küng 055fa768d8 posix: enable ROMFSROOT
This will copy the ROMFS into the build directory under etc/, and thus
needs a change of the PX4 startup parameters and mixer paths.
2020-09-15 09:30:16 +02:00
Beat Küng d3362f38d1 parameters: add parameters.json.gz as output 2020-09-15 09:30:16 +02:00
Beat Küng 809d05053b posix: add support for ROMFSROOT
- add missing ROMFS files to CMakeLists.txt
- rename genromfs to etc, so that it's clearer for SITL use
2020-09-15 09:30:16 +02:00
SalimTerryLi 28a6e82698 Introduce new generic ADC driver for ADS1115 chip (#14437) 2020-09-14 11:03:40 -04:00
Ricardo Marques c15efea429 mavlink: publish ESC_INFO and ESC_STATUS
Signed-off-by: Ricardo Marques <marques.ricardo17@gmail.com>
2020-09-14 09:38:44 -04:00
flbernier 0ece66dc80 Add a internal start for rgbled_ncp5623c on fmu-v2 v3 v4pro 2020-09-14 09:31:31 -04:00
JaeyoungLim 0592f6ba6e Support gliding setpoints for autonomous soaring (#14643)
* Enable offboard gliding position setpoints

Adds a capability to make the vehicle glide when given position setpoints.

Gliding setpoints are enabled by setting POSITION_TARGET_TYPEMASK_Z_IGNORE, POSITION_TARGET_TYPEMASK_VZ_IGNORE,  POSITION_TARGET_TYPEMASK_AZ_IGNORE on the typemask of position setpoints.
Include zero cruising throttle
Invalid setpoints with nan

* Handle nans for curise_throttle
2020-09-14 10:56:29 +02:00
PX4 BuildBot 8bc512dc93 Update submodule sitl_gazebo to latest Mon Sep 14 00:39:41 UTC 2020
- sitl_gazebo in PX4/Firmware (ac732cdeba): https://github.com/PX4/sitl_gazebo/commit/78bba3f25e7e240bf70878bd007dfd77b33440c1
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/9d2b19784cb34bf8f397ab2e2f368f682f2d5d5a
    - Changes: https://github.com/PX4/sitl_gazebo/compare/78bba3f25e7e240bf70878bd007dfd77b33440c1...9d2b19784cb34bf8f397ab2e2f368f682f2d5d5a

    9d2b197 2020-09-12 JaeyoungLim - Use jinja templates for standard_vtol and plane model (#590)
01587e6 2020-09-12 Lorenz Meier - Include GLib2 properly The previous approach did not actually search for glib2 in the system but hardcoded the name.
e49fac5 2020-09-12 bazooka joe - cleanups: rename class vars to be with underscore
6fb9bd9 2020-09-12 bazooka joe - move initializers to h file
29999c6 2020-09-12 JaeyoungLim - Update boat gps sensor (#595)
a208640 2020-09-09 petertheprocess - fix the rudder deflection bug. (#588)
2020-09-13 21:41:22 -04:00
PX4 BuildBot 1ad2e85475 Update submodule ecl to latest Mon Sep 14 00:39:58 UTC 2020
- ecl in PX4/Firmware (3011684f9154975f4db1581d9466524a02d4cbf3): https://github.com/PX4/ecl/commit/a204c599903e6a462cab17bee061d4418a8b6b53
    - ecl current upstream: https://github.com/PX4/ecl/commit/fab242a81f3836de716b0ed96fcc841360c3a867
    - Changes: https://github.com/PX4/ecl/compare/a204c599903e6a462cab17bee061d4418a8b6b53...fab242a81f3836de716b0ed96fcc841360c3a867

    fab242a 2020-09-06 Daniel Agar - python generation add shebang, mark executable, ignore cache
2020-09-13 21:37:01 -04:00
Daniel Agar 2b04ae3a05 Update submodule mavlink v2.0 to latest Mon Sep 14 00:39:47 UTC 2020
- mavlink v2.0 in PX4/Firmware (8d63bbe7d06ac13a5e78905886cfa51a53d0de92): https://github.com/mavlink/c_library_v2/commit/efc2a1fa7e1c7814ca7b65f484f6e9968cb8f1c8
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/09524c98db4eb389d3d50f7905a17805b216a9ea
    - Changes: https://github.com/mavlink/c_library_v2/compare/efc2a1fa7e1c7814ca7b65f484f6e9968cb8f1c8...09524c98db4eb389d3d50f7905a17805b216a9ea

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-09-13 21:23:46 -04:00
Daniel Agar 13db2ebb2b accel/gyro/mag calibration set default priority uninitialized
- this allows the default priority to be set differently for internal/external sensors
 - accel and gyro initialize default priority like mag in preparation for fully supporting external sensors
 - fixes #15652
2020-09-13 21:02:53 -04:00
Daniel Agar d70e183f5b commander: sensor calibration check parameter save success 2020-09-13 21:00:40 -04:00
Daniel Agar 04214a347e lib/sensor_calibration: check param save success and comment helpers 2020-09-13 21:00:40 -04:00
Mirko Denecke ac732cdeba STM32H7 CAN: fix uninitialized pending variable 2020-09-13 18:58:57 -04:00
Beat Küng 2b0396d5df gps: use px4::atomic instead of volatile 2020-09-13 18:31:37 -04:00
Beat Küng e906106ea2 gps: fix memory leak on module exit (delete _helper) 2020-09-13 18:31:37 -04:00
Beat Küng 2956aa340e module: increase max timeout for stopping modules from 2s to 5s
The gps module might take up to 4s to stop (if stopped during module
configuration).
2020-09-13 18:31:37 -04:00
Thies Lennart Alff 531242468e fixed erroneous task_spawn 2020-09-13 18:31:02 -04:00
Daniel Agar 198466306e boards: airmind mindpx-v2 fix internal qmc5883l rotation 2020-09-13 18:28:31 -04:00
Morten Fyhn Amundsen cfe4982023 mavlink_messages: Subscribe to all distance_sensor instances
This will make all distance_sensor messages be published to
mavlink. Previously, if you ran multiple distance_sensor publishers,
typically multiple distance sensors, then you'd only get one of them
on mavlink.

The modifications to MavlinkStreamDistanceSensor are based on
MavlinkStreamBatteryStatus, which already exists with multi-instance
subscription and streaming to mavlink.

Use SubscriptionMultiArray

Co-authored-by: Daniel Agar <daniel@agar.ca>
2020-09-13 12:42:07 -04:00
Jaeyoung-Lim 0d4d21cd67 Allow gzserver verbose options through command line
Allows verbose option for gzserver with VERBOS=1 on command line.
2020-09-12 20:19:21 +02:00
CarlOlsson 2128679ab3 rename templates/module to templates/template_module 2020-09-11 09:21:33 +02:00
Quentin PERROT 9116acc431 change message critical state for arm authorization 2020-09-09 08:59:21 +02:00
Matthias Grob c6e2722b8f param: remove reset_nostart
Since we have reset_excludes and SYS_AUTOSTART and SYS_AUTOCONFIG
can be excluded like every other parameter.
2020-09-08 12:03:41 +02:00
Matthias Grob ce9954a919 param: enable reseting specific parameters from shell
Renaming previous "param reset" to "param reset_all".
2020-09-08 12:03:41 +02:00
Matthias Grob f70dda12a6 failureDetectorCheck: remove string manipulation 2020-09-08 11:42:30 +02:00
Matthias Grob 5eba25d2b5 Commander: remove duplicate flag changes 2020-09-08 11:42:30 +02:00
Matthias Grob ab17b6bad4 failureDetectorCheck: revise messageing 2020-09-08 11:42:30 +02:00
Matthias Grob 981e05c633 FailureDetector: move esc topic check into esc status update 2020-09-08 11:42:30 +02:00
Matthias Grob c180e09b9a FailureDetector: replace resetAttitudeStatus 2020-09-08 11:42:30 +02:00
Matthias Grob 390edb770d Commander: separate failure detector cases
One case could lead to the action for the other!
2020-09-08 11:42:30 +02:00
Matthias Grob f47bb95b26 FailureDetector: remove obsolete bit switch checks 2020-09-08 11:42:30 +02:00
Matthias Grob c9b81eaf08 FailureDetector: simplify updated/changed check 2020-09-08 11:42:30 +02:00
Matthias Grob 2bb5917188 FailureDetector: refactor naming, member order 2020-09-08 11:42:30 +02:00
Matthias Grob 25cdb383c6 Commander: simplify main failure detector condition 2020-09-08 11:42:30 +02:00
SalimTerryLi c037dbef21 Rename and move src/drivers/adc to src/drivers/adc/board_adc 2020-09-07 23:09:20 -04:00
avionicsanonymous df38e3798c UAVCAN Rangefinder Support (#15097) 2020-09-07 19:22:08 -04:00
David Sidrane 6c4a1d01c1 NuttX Critical STM32H7 Interrupt Storm on I2C 2020-09-07 15:15:52 -04:00
Dusan Zivkovic fa1a0b848b FlightTaskAuto: update waypoints on every iteration when in offtrack state 2020-09-07 19:25:10 +02:00
bresch db25f20120 ekf2: move "using" keywords to cpp 2020-09-07 09:42:56 -04:00
Daniel Agar 60d613ea04 sensors: sensor_preflight_imu -> sensors_status_imu and run continuously
- inconsistency checks now run continuously instead of only preflight
 - keep inconsistencies for all sensors
 - add per sensor data validator state as overall health flag
2020-09-06 22:06:13 -04:00
PX4 BuildBot d4ecf24bf2 Update submodule ecl to latest Sun Sep 6 12:39:41 UTC 2020
- ecl in PX4/Firmware (2a6181e31fd47fc99f42c6fea4d2186cda1196f0): https://github.com/PX4/ecl/commit/264c8c4e8681704e4719d0a03b848df8617c0863
    - ecl current upstream: https://github.com/PX4/ecl/commit/a204c599903e6a462cab17bee061d4418a8b6b53
    - Changes: https://github.com/PX4/ecl/compare/264c8c4e8681704e4719d0a03b848df8617c0863...a204c599903e6a462cab17bee061d4418a8b6b53

    a204c59 2020-09-05 rjgritter - WindEstimator: Fix incorrect _state accessing, clarify enums (#906)
2020-09-06 20:08:41 -04:00
Daniel Agar 4e8775a584 Jenkins: temporarily disable MC safe landing SITL test
- the MC safe landing SITL test continues to fail intermittently so I'm disabling it for now
2020-09-06 19:47:10 -04:00
Daniel Agar ca9b6bc137 commander: quick mag cal with fixed heading use MAV_CMD_FIXED_MAG_CAL_YAW message
- use proper Mavlink MAV_CMD_FIXED_MAG_CAL_YAW command for initiating magnetometer quick cal
 - MAV_CMD_FIXED_MAG_CAL_YAW allows specifying the yaw and optionally latitude and longitude if the vehicle doesn't have GPS
2020-09-06 19:25:11 -04:00
Daniel Agar 1ac31100cc commander: HITL skip auto disarm if lockdown
- auto disarm when locked down was added in #14766 to prevent user confusion in regular usage, but also breaks HITL where lockdown is enabled for safety
 - fixes #15686
2020-09-06 18:38:05 -04:00
Daniel Agar 3fa9ff6d20 boards: px4_fmu-v5_debug increase LPWORK stack 1632 -> 1728 bytes 2020-09-06 18:36:30 -04:00
Daniel Agar dfa82b58fd msg/tools/uorb_to_ros_msgs.py set executable 2020-09-06 23:31:52 +02:00
Daniel Agar cea1a19fe6 NuttX sched notes add C linkage 2020-09-06 19:18:42 +02:00
SalimTerryLi af84f449c7 isentek/ist8310: support starting with custom i2c address 2020-09-06 09:06:05 -04:00
Daniel Agar 023f6d3983 NuttX cpuload monitoring optimization
- Nuttx only process all suspend & resume scheduling notes when top is running, otherwise only track IDLE
 - convert cpuload and print load to c++
 - delete unused fields from print_load struct
 - update hrt_store_absolute_time (previous unused)
2020-09-05 14:35:50 -04:00
Nicolas MARTIN a9798454cd temperature compensation: change sensor id not found message 2020-09-05 13:27:42 -04:00
Nicolas MARTIN 4addf8ec3e thermal calibrtation: do not calibrate sensor without temperature sensor 2020-09-05 13:27:42 -04:00
Jonathan Hahn 7e5e8259f3 fw_pos_control_l1: fix swapped TECS time parameters (#15685)
Co-authored-by: Jonathan Hahn <hahn@wingcopter.com>
2020-09-04 15:11:31 -04:00
Daniel Agar f7c364de37 Jenkins hardware print estimator and sensor messages 2020-09-04 10:48:26 -04:00
Daniel Agar e5879f1bb6 estimator_sensor_bias: add bias variance 2020-09-04 10:48:26 -04:00
Daniel Agar c54a0ff0c7 estimator_status: add device ids for accel/baro/gyro/mag 2020-09-04 10:48:26 -04:00
Daniel Agar 20c2fe6d28 estimator messages add explicit timestamp_sample
- timestamp is uORB publication metadata
 - this allows us to see what the system saw at publication time plus the latency in estimation
2020-09-04 10:48:26 -04:00
Daniel Agar 09666c324f msg: add mag device id pretty print decode 2020-09-04 10:48:26 -04:00
Daniel Agar 9215fb57a2 ekf2: advertise immediately to ensure consistent uORB instance numbering 2020-09-04 10:48:26 -04:00
Daniel Agar 9ccc1db649 estimator_status split out estimator_states 2020-09-04 10:48:26 -04:00
Daniel Agar 33a7fed240 ekf2: split out header and rename 2020-09-04 10:48:26 -04:00
Daniel Agar 4879a4e2ef ekf2: use single uORB::Subscription, but change instance 2020-09-03 15:41:33 -04:00
Daniel Agar 59e66e5be9 sensors/vehicle_acceleration: use single uORB::Subscription, but change instance 2020-09-03 15:41:33 -04:00
Daniel Agar ee88561a33 sensors/vehicle_angular_velocity: use single uORB::Subscription, but change instance 2020-09-03 15:41:33 -04:00
Daniel Agar 94f7b50970 uORB: add Subscription method to change instance 2020-09-03 15:41:33 -04:00
Beat Küng 787f9c1213 i2c: use board-specific bus numbering for '-X -b <bus>' CLI
As boards don't have their external buses labeled consistently, it was not
useful to use an abstraction.
2020-09-03 15:32:35 -04:00
David Sidrane fdcd9b2de1 npx_fmurt1062-v1:CONFIG_BOARD_CRASHDUMP is not supported 2020-09-03 14:55:09 +02:00
David Sidrane 5d5a767143 npx_fmuk66:CONFIG_BOARD_CRASHDUMP is not supported 2020-09-03 14:55:09 +02:00
David Sidrane 7f91e41f67 hardfault_log:Add Fault Status registers 2020-09-03 14:55:09 +02:00
Daniel Agar bf41574b1d isentek/ist8308: set sensor_mag error count and fix bitwise AND 2020-09-03 07:50:43 +02:00
Daniel Agar 19b43b5e9c uORB:: SubscriptionMultiArray fix construction argument
- uORB::SubscriptionInterval construction requires the interval THEN the instance
2020-09-03 07:49:57 +02:00
Daniel Agar 24125b3da4 magnetometer/qmc5883l: cleanup/rewrite driver (#14384) 2020-09-02 13:16:27 -04:00
Daniel Agar 7569722821 iSentek IST8310 magnetometer rewrite
- simple state machine to reset, configure, etc
 - checked register mechanism (sensor will reset itself on configuration error)
 - configured in 16 bit mode (1320 LSB/Gauss instead of 330 LSB/Gauss)
 - adjusted orientation handling in driver to match datasheet as closely as possible
     - in many external compass units the rotation was wrong and very difficult to actual determine how to set correctly
2020-09-02 13:14:45 -04:00
Daniel Agar 6ff361479c uORB: introduce SubscriptionMultiArray for working with multi-instances 2020-09-02 12:46:47 -04:00
oneWayOut 71f381ada9 add gazebo VTOL tiltrotor debug target for VSCode SITL 2020-09-02 11:41:01 -04:00
Daniel Agar 5017a7e33a simulator: publish 2 instances of accel/baro/gyro/mag 2020-09-02 10:42:02 -04:00
Daniel Agar 668c16da83 px4_work_queue: reset statistics after each status print 2020-09-02 10:09:13 -04:00
Nuno Marques 86e10afd76 microRTPS agent deploy: split commit subjects and delete src and idl folders before updating them (#15672) 2020-09-02 15:11:25 +02:00
Daniel Agar 7c2bb6a983 Jenkins: hardware increase timeout 2020-09-02 09:00:34 -04:00
TSC21 ba7d19033e replace 'python' with '.' to run the uORB to ROS conversion Python script 2020-09-02 13:38:04 +02:00
TSC21 5ae0291c13 reactivate ROS-related builds 2020-09-02 11:47:34 +02:00
TSC21 ad2b4c81fd update container tags to focal:2020-08-20 2020-09-02 11:47:34 +02:00
gitfishup f3579e473b boards: CUAV Nora enable UAVCAN 2020-09-01 21:16:17 -04:00
Daniel Agar e56dfe6497 rover_pos_control: revert sensor_combined purge
- sensor_combined is only used for scheduling in this module under certain circumstances and should be reviewed and replaced 
 - fixes https://github.com/PX4/Firmware/issues/15628
2020-09-01 21:09:33 -04:00
Daniel Agar dd9676b73e boards: px4/fmu-v5_debug increase interrupt stack 512 -> 768 bytes 2020-09-01 20:04:06 -04:00
Matthias Grob 1d562aaf4a battery: switch to PublicationMulti for battery_status 2020-09-01 10:25:03 +02:00
Matthias Grob d06425d131 analog_battery: fix missing stdio include
This was not a problem before because battery.h
included the adc driver and implicitly snprintf
was defined through there.
2020-09-01 10:25:03 +02:00
Matthias Grob 5bc1df60a2 commander_params: remove some double spaces 2020-09-01 10:25:03 +02:00
Matthias Grob 180c6faf4a syslink_main: remove empty lines and struct keyword 2020-09-01 10:25:03 +02:00
Matthias Grob d82f325f8d ina226/voxlpm: make sure parameter sub is reset
The subscription to parameter updates has to get
copied otherwise the change detection will not get
reset for next time.
2020-09-01 10:25:03 +02:00
Matthias Grob 9c4e26c00c battery: fix parameter migration and clarify 2020-09-01 10:25:03 +02:00
Matthias Grob 0db4881413 BatterySimulator: remove SimulatorBattery
It loads the battery parameters but then overwrites them
with hardcoded values and it breaks the ModuleParams
parent/child hierarchy. Both is undesired.
2020-09-01 10:25:03 +02:00
Daniel Agar 978e35478f logger: add_topic_multi optional specify max multi-instance (#15647) 2020-09-01 09:36:32 +02:00
Daniel Agar cbf21959ab Update submodule mavlink v2.0 to latest Tue Sep 1 00:39:26 UTC 2020
- mavlink v2.0 in PX4/Firmware (0b0d23e8fa): https://github.com/mavlink/c_library_v2/commit/5ad778dea329d40f3cd128aae988986de79d830c
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/7d6be862bca8f733a854bfd6c97f1bb25cdb477c
    - Changes: https://github.com/mavlink/c_library_v2/compare/5ad778dea329d40f3cd128aae988986de79d830c...7d6be862bca8f733a854bfd6c97f1bb25cdb477c
2020-08-31 22:30:52 -04:00
Daniel Agar 0b0d23e8fa process_sensor_caldata.py: skip accel or gyro if temperature is NAN 2020-08-31 07:59:03 -04:00
Daniel Agar fe391c0af8 perf: combine duplicate Knuth/Welford recursive mean 2020-08-31 10:03:56 +02:00
Oleg 172a4e3557 batterry_status: fix checking default v_div 2020-08-30 11:09:59 -04:00
Daniel Agar 9feea0e2fd commander: accel calibration fail early on bad rotations 2020-08-29 11:02:37 -04:00
Daniel Agar 28d52aef1f bosch/bmi088: minor cleanup and consistency improvements
- track consecutive failures and trigger reset aggressively
 - only count missed drdy interrupts, not time
 - reset wait times consistent with other drivers
 - accel improve FIFO count check if DRDY isn't available
2020-08-29 11:01:09 -04:00
Daniel Agar a04d79b810 bosch/bmi055: minor cleanup and consistency improvements
- track consecutive failures and trigger reset aggressively
 - only count missed drdy interrupts, not time
 - reset wait times consistent with other drivers
2020-08-29 11:01:09 -04:00
Daniel Agar 08ad7850fc rotation: combine duplicates 2020-08-28 18:29:09 -04:00
Daniel Agar 08cfea0b6f commander: mag calibration auto rotation skip all duplicates
- add simple rotation test with corresponding blacklist
2020-08-28 18:29:09 -04:00
Nicolas MARTIN 1dec1e6262 process_sensor_caldata.py: add regularly weighted over temperature fit
the option '--no_resample' allows to disable resampling and have the
previous behavior
2020-08-28 16:39:11 -04:00
Daniel Agar eb46a42400 bosch/bmi055: fix accel temperature reading
- single register output is in 2's complement
2020-08-28 16:01:08 -04:00
CUAVcaijie 536877cf0a boards: add UAVCAN timer override mechanism and CUAV X7 add CAN (#15348)
* X7Pro adds CAN driver
* UAVCAN timer selection moved to default.cmake
* Modify some details about @CUAVcaijie UAVCAN timer selection moved to default.cmake
* Put some timer parameters to micro_hal.h from board_config.h. Fix all h7 boards

Co-authored-by: honglang <honglang@cuav.net>
2020-08-28 12:16:48 -04:00
bresch 8c0671e93d ll40ls: set default rotation to downwards facing
All the other distance sensors have their default rotation to downwards
facing as well
2020-08-28 12:00:47 -04:00
bresch 644ede5698 distance_sensor: allow setting no rotation (-R 0) 2020-08-28 12:00:47 -04:00
TSC21 98f53c2bc4 microRTPS: extend verbose arg to the timesync 2020-08-28 09:22:36 +02:00
TSC21 d09cb8d1f0 microRTPS: reduce the number of streams on the bus 2020-08-28 09:22:36 +02:00
TSC21 603a4d8955 microRTPS: transport: fix parsing 2020-08-28 09:22:36 +02:00
Oleg a18f22bd91 batterry_status: fix checking default a_per_v 2020-08-27 21:47:27 -04:00
Daniel Agar 8869cb5e4a Update submodule mavlink v2.0 to latest Fri Aug 28 00:39:46 UTC 2020
- mavlink v2.0 in PX4/Firmware (8e37063c7be7279b004a2eb584144e8a080422a9): https://github.com/mavlink/c_library_v2/commit/171ae1da5e1799235ea7e35f6d34bfe3897d9a9a
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/5ad778dea329d40f3cd128aae988986de79d830c
    - Changes: https://github.com/mavlink/c_library_v2/compare/171ae1da5e1799235ea7e35f6d34bfe3897d9a9a...5ad778dea329d40f3cd128aae988986de79d830c
2020-08-27 21:43:47 -04:00
PX4 BuildBot 8ba7bbf3af Update submodule jMAVSim to latest Fri Aug 28 00:39:40 UTC 2020
- jMAVSim in PX4/Firmware (8eb46b0eb8): https://github.com/PX4/jMAVSim/commit/14ce7868fb29b8b05cdecf4e9a76b318839302e9
    - jMAVSim current upstream: https://github.com/PX4/jMAVSim/commit/358b6cca4093646eb96e0cb075e45efa8f4a0c48
    - Changes: https://github.com/PX4/jMAVSim/compare/14ce7868fb29b8b05cdecf4e9a76b318839302e9...358b6cca4093646eb96e0cb075e45efa8f4a0c48

    358b6cc 2020-08-24 Hamish Willee - Merge pull request #122 from farhangnaderi/patch-1
42b5cd3 2020-08-23 FARHANG - Update README.md
2020-08-27 21:42:36 -04:00
PX4 BuildBot 67c134303c Update submodule nuttx to latest Fri Aug 28 00:39:53 UTC 2020
- nuttx in PX4/Firmware (f0555571047b18fa503eeac18da586f2dd360c12): https://github.com/PX4/NuttX/commit/925b7b513b8f7b683bfea43923a8beb2a0ad5a61
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/863ed53e3fb1cebbb0832ec28fbc11e16566e89e
    - Changes: https://github.com/PX4/NuttX/compare/925b7b513b8f7b683bfea43923a8beb2a0ad5a61...863ed53e3fb1cebbb0832ec28fbc11e16566e89e

    863ed53e3f 2020-06-15 David Sidrane - [BACKPORT] kinetis:Ethernet fixed & better interrupt management
2020-08-27 21:41:09 -04:00
PX4 BuildBot e54df5c57a Update submodule matrix to latest Fri Aug 28 00:40:08 UTC 2020
- matrix in PX4/Firmware (5d014729e6cce9ca5814b5b803347ea561743cec): https://github.com/PX4/Matrix/commit/25c04553488bb86470592a1cdccac56979bf59bb
    - matrix current upstream: https://github.com/PX4/Matrix/commit/ce6b10b99af722a4e653387d40019a8428d2a54f
    - Changes: https://github.com/PX4/Matrix/compare/25c04553488bb86470592a1cdccac56979bf59bb...ce6b10b99af722a4e653387d40019a8428d2a54f

    ce6b10b 2020-08-27 Julian Oes - Fix clang-tidy warnings
13f092a 2020-08-26 Kamil Ritz - sparse quadratic form
3a5bfb2 2020-08-25 Julian Oes - matrix: inline to prevent multiple definitions (#147)
e101edc 2020-08-24 Julian Oes - Matrix: fix warning if M == N (#146)
cd8ad15 2020-08-24 Morten Fyhn Amundsen - Make wrap() work with integer types (#145)
2020-08-27 21:40:26 -04:00
PX4 BuildBot 10e2ccc1cd Update submodule ecl to latest Fri Aug 28 00:40:03 UTC 2020
- ecl in PX4/Firmware (110860c85d6eaca3f5ac5c38a8a65066fc1e0c31): https://github.com/PX4/ecl/commit/bd0c5fbb976b3ae6fb5eff80da5df3d50f18ffbe
    - ecl current upstream: https://github.com/PX4/ecl/commit/264c8c4e8681704e4719d0a03b848df8617c0863
    - Changes: https://github.com/PX4/ecl/compare/bd0c5fbb976b3ae6fb5eff80da5df3d50f18ffbe...264c8c4e8681704e4719d0a03b848df8617c0863

    264c8c4 2020-08-20 bresch - mag_fusion: mag heading and 3d modes are mutually exclusive
9797e4d 2020-08-22 kamilritz - updateYawInRotMat with hidden rotation sequence handling
419b70e 2020-08-17 kamilritz - Add tests for shouldUse321RotationSequence
4fb4e0c 2020-08-17 kamilritz - Clean euler321 and euler312 code and comment
2be738e 2020-08-15 Kamil Ritz - Add helper function to alter heading in rotation matrices
fdc86c2 2020-08-15 Kamil Ritz - add functions to compute yaw (321 and 312 sequence)
15afa8a 2020-08-15 Kamil Ritz - shouldUse321RotationSequence(const Dcmf& R)
4872f2a 2020-08-15 Kamil Ritz - Remove not used code
0fafd4d 2020-08-15 Kamil Ritz - precompute cos and sin of yaw once before mutliple use
114516b 2020-08-15 Kamil Ritz - Use new added matrix functions
1f637af 2020-08-15 Kamil Ritz - Add const modifier
aa2c77f 2020-08-22 kamilritz - Small cleanup in velposfusion
644e903 2020-08-22 kamilritz - Apply measurementUpdate function
404edde 2020-08-22 kamilritz - Add measurementUpdate function
f6252ff 2020-08-22 kamilritz - small cleanup  in limitDeclination
f62662e 2020-08-21 Daniel Agar - update change_indication for newer WMM tables
802a6d9 2020-08-21 PX4 BuildBot - Update geo_lookup WMM  to latest Fri Aug 21 11:48:14 UTC 2020
2020-08-27 21:38:56 -04:00
Oleg Evseev 8eb46b0eb8 mavlink: check type on instance getting by device or network port
otherwise serial mavlink running in first will occupy default net port 14556 and could be wrongly used for stream configuring instead or udp mavlink running in first will occupy default serial "/dev/ttyS1"and could be wrongly used for stream configuring instead

issue #15558
2020-08-27 17:28:12 +02:00
Matthias Grob 16776ff6fb MultirotorMixer: hotfix [-1,1] scaling
After it was mistakenly rescaled in
26bac78eaf274cf58aacbc239cc8f2e865ba864c#diff-899d35a48340c6065702d4fa77b70f0d
#15563
2020-08-26 20:52:16 -04:00
Matthias Grob d4296dbd3f thoneflow: remove unsupported parameter from getopt optsting 2020-08-26 20:25:31 -04:00
Kabir Mohammed c319bbd6f7 drivers/optical_flow: Thoneflow 3901U Driver
* srcparser.py: Add optical flow subcategory for module docs
* thoneflow : Initial support
2020-08-26 13:10:38 -04:00
David Sidrane 8d2ce355f2 Nuttx Backport add RTR 2020-08-26 13:05:23 +02:00
David Sidrane 622903f7de Nuttx Backport add extern C under cpp 2020-08-26 13:05:23 +02:00
Beat Küng 4088c2581f i2c_spi_buses: add '-q' for quiet startup flag (#14969)
* [WIP] i2c_spi_buses: add '-q' for quiet startup flag

And enable for optional board sensors.

* ROMFS: rc.sensors try starting all optional I2C sensors quietly

Co-authored-by: Daniel Agar <daniel@agar.ca>
2020-08-26 08:46:35 +02:00
SalimTerryLi 407ca0a5d3 mavlink command: new option to completely disable hardware flow control (-Z) (#15566) 2020-08-26 08:40:55 +02:00
Daniel Agar 60a7f7f9f2 isentek/ist8308: small style and consistency cleanup 2020-08-25 13:46:04 -04:00
Daniel Agar fb149045e3 drivers/imu/invensense: new ICM42605 IMU driver 2020-08-25 13:07:59 -04:00
Daniel Agar 0ae6da4bb0 Jenkins: microRTPS agent fetch git tags for versioning 2020-08-25 11:12:38 -04:00
Daniel Agar 0e64baa93b parameters: delete unused PARAM_TYPE_STRUCT 2020-08-25 09:59:29 -04:00
Beat Küng b7b23a521a sdp3x: remove reset during init
It is not playing nice with other devices on the same bus.
In particular with the FreeFly RTK GPS: once the reset is sent, the whole
bus is blocked and becomes unusable.
Current understanding is that this device contains another chip on the bus
(apart from the mag+baro+led).

I don't see much use for it either, as we configure everything there is to
configure (just the mode).
2020-08-24 17:55:05 -04:00
Anton Erasmus 1ae579b5d5 Update sitl_run to check for -gen.sdf files (#15232)
Co-authored-by: Anton Erasmus <antonerasm@gmail.com>
2020-08-24 17:01:11 +02:00
Hamish Willee 979243f38f params: make parameter units more consistent (#15502) 2020-08-24 11:33:08 +02:00
px4dev 9cebf3b969 Sbus comment fix, found by George-avy in issue 15253 2020-08-24 09:24:53 +02:00
Daniel Agar 1d0188fc07 logger: add vehicle_acceleration to default topics 2020-08-23 17:38:27 -04:00
Daniel Agar 53b3dfa64e rover_pos_control: remove unused sensor_combined subscription 2020-08-23 17:38:27 -04:00
Daniel Agar a368c7cded muorb: delete unused sensor_combined.h include 2020-08-23 17:38:27 -04:00
Daniel Agar 57721cad9b mavlink: replace sensor_combined with selected vehicle_imu
- check all ORB_MULTI_MAX_INSTANCES possible instances for future expansion
2020-08-23 17:38:27 -04:00
Daniel Agar 1d2e424c4c commander: calibration replace sensor_combined with vehicle_acceleration 2020-08-23 17:38:27 -04:00
Daniel Agar 2c450280d2 examples/uuv_example_app: replace sensor_combined with vehicle_acceleration 2020-08-23 17:38:27 -04:00
Daniel Agar e8a074dc03 examples/px4_simple_app: replace sensor_combined with vehicle_acceleration 2020-08-23 17:38:27 -04:00
Daniel Agar 1bb4c9d05f frsky_telemetry: replace sensor_combined with vehicle_acceleration 2020-08-23 17:38:27 -04:00
JaeyoungLim 5c040582db Update sitl_gazebo 2020-08-21 21:49:42 +02:00
Daniel Agar 64f5c64ce9 Update submodule mavlink v2.0 to latest Fri Aug 21 12:39:56 UTC 2020
- mavlink v2.0 in PX4/Firmware (b1cdf94b680613a982d2d2450d91e27205872030): https://github.com/mavlink/c_library_v2/commit/cc7ed13f41931335c1902da445bbdf12f4d66e63
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/171ae1da5e1799235ea7e35f6d34bfe3897d9a9a
    - Changes: https://github.com/mavlink/c_library_v2/compare/cc7ed13f41931335c1902da445bbdf12f4d66e63...171ae1da5e1799235ea7e35f6d34bfe3897d9a9a
2020-08-21 14:22:25 -04:00
PX4 BuildBot 0f27395979 Update submodule ecl to latest Fri Aug 21 12:40:08 UTC 2020
- ecl in PX4/Firmware (a6682c0ce863694761557482556c67747b5d7eeb): https://github.com/PX4/ecl/commit/3ae934544f8b2de01b868d0defea992b1000acc3
    - ecl current upstream: https://github.com/PX4/ecl/commit/bd0c5fbb976b3ae6fb5eff80da5df3d50f18ffbe
    - Changes: https://github.com/PX4/ecl/compare/3ae934544f8b2de01b868d0defea992b1000acc3...bd0c5fbb976b3ae6fb5eff80da5df3d50f18ffbe

    bd0c5fb 2020-08-20 kamilritz - Update change indication for ekf gsf
2020-08-21 14:04:56 -04:00
Angel 3dd9d2e6db Add copyright info to ina226.h 2020-08-21 13:11:39 -04:00
Daniel Agar 2c3441aa90 boards: reduce CONFIG_NFILE_DESCRIPTORS 15 -> 12
- reduced now that calibration uses uORB::Subscription
 - can likely be reduced further (perhaps < 8) with additional testing
2020-08-21 10:12:13 -04:00
Daniel Agar 4dee5d6a1c commander: level calibration print changes 2020-08-21 10:12:13 -04:00
Daniel Agar ea13bf271d lib/sensor_calibration: Magnetometer catch and fix invalid rotations
- improve status print
2020-08-21 10:12:13 -04:00
Daniel Agar c76cdaf8a8 commander: mag calibration add simple offset only quick cal using GPS & attitude 2020-08-21 10:12:13 -04:00
Daniel Agar f6ad9bdb64 commander: don't set RC lost during calibration 2020-08-21 10:12:13 -04:00
Daniel Agar 5242160a26 commander: accel calibration reduce status length
- this keeps the string within a single Mavlink STATUSTEXT
 - fixes #14829
2020-08-21 10:12:13 -04:00
Daniel Agar d824706571 commander: mag calibration keep manually configured special rotations
- ROTATION_PITCH_9_YAW_180 and ROTATION_ROLL_90_PITCH_68_YAW_293 are
kept if manually configured
2020-08-21 10:12:13 -04:00
Daniel Agar 0bb6ad01bd commander: mag calibration rotation also compare other internal mags 2020-08-21 10:12:13 -04:00
Daniel Agar 07d727a4a8 commander: mag calibration auto rotation simplify applying calibration and rotation 2020-08-21 10:12:13 -04:00
Daniel Agar 1a6eb7859c commander: mag calibration auto rotation improvements
- skip rotations that are identical or very close
 - compute mean squared error (MSE) to skip a sqrt
2020-08-21 10:12:13 -04:00
Daniel Agar bc6e4c8a92 commander: accel calibration use all queued data
- print each calibration when finished
2020-08-21 10:12:13 -04:00
Daniel Agar f9aca05ede commander: gyro calibration use all queued data
- print calibration status when finished
2020-08-21 10:12:13 -04:00
Daniel Agar f2c9865c9b sensor mag add minimal queue and calibration check all
- mag calibration acceptance check sphere/ellipsoid fit status
2020-08-21 10:12:13 -04:00
Daniel Agar b2e8f6839f commander: mag calibration improve console and debug output 2020-08-21 10:12:13 -04:00
Daniel Agar 2bb04f2261 commander: increase COM_ARM_MAG_ANG 35 -> 45 degrees
- in practice this is mostly useful for identifying incorrect rotations
which we mostly have in 45 degree increments
 - handling a vehicle on the ground can easily disturb one mag by more than 30 degrees, so this is often distracting noise
2020-08-21 10:12:13 -04:00
Daniel Agar 44c877c603 sensors: size sensor error_count consistently (uint32_t) 2020-08-21 10:12:13 -04:00
Daniel Agar e6fd5a43bc commander: magnetometer calibration automatically set the rotation of external magnetometers relative to the first internal
- see #15120 for more detail
2020-08-21 10:12:13 -04:00
Daniel Agar 27f23ac290 move initial sensor priority to parameters and purge ORB_PRIORITY
- CAL_ACCx_EN -> CAL_ACCx_PRIO
 - CAL_GYROx_EN -> CAL_GYROx_PRIO
 - CAL_MAGx_EN -> CAL_MAGx_PRIO
2020-08-21 10:12:13 -04:00
Daniel Agar 971b1e4b4d sensors: move mag aggregation to new VehicleMagnetometer WorkItem
- purge all reminaing magnetometer IOCTL usage
 - mag calibration add off diagonal (soft iron) scale factors
2020-08-21 10:12:13 -04:00
Daniel Agar ad148af2fd commander: mag_calibration move to Magnetometer calibration helper 2020-08-21 10:12:13 -04:00
Daniel Agar 1867e540b0 lib/sensor_calibration: add Magnetometer helper 2020-08-21 10:12:13 -04:00
Daniel Agar d92ddffa5d commander: add simple accelerometer quick calibration 2020-08-21 10:12:13 -04:00
Daniel Agar e3e8c55e82 accel & gyro calibration helpers 2020-08-21 10:12:13 -04:00
Daniel Agar bae2589fed Jenkins delete Mac compile (replaced by Github Actions) 2020-08-20 18:53:26 -04:00
Julian Kent 7958586f35 Only use roll/pitch not centered for RC override, and increase override threshold 2020-08-20 11:50:16 -04:00
JaeyoungLim cbbde2e4a2 Update sitl_gazebo (#15586) 2020-08-20 15:45:16 +02:00
Julian Kent e2e72fd81e Fix map distortion due to high latitudes (#15449) 2020-08-19 09:55:15 +02:00
TSC21 7b4ae7c658 Jenkins: deploy: build the rtps target before commiting microRTPS agent changes 2020-08-19 08:59:22 +02:00
modaltb d9bbed767c modalai_fc-v1 - power_monitor/voxlpm: add support for voxlpm v3 (INA231 sensors) 2020-08-19 00:01:31 -04:00
Daniel Agar 841f650be4 github actions temporarily remove linux hardware (navio2) test
- until connectivity issues are resolved
2020-08-18 23:55:13 -04:00
bazooka joe 190b96a46c SMbus battery driver - a lot of updates and optimizations
- added support for BQ40Z80 based battery
- added performance counter for interface errors
- added SMART_BATTERY_INFO mavlink message
- general code cleanups and optimization
- fixed: void flooding the log in case of interface error
- fixed: using _batt_startup_capacity instead of _batt_capacity for discharged_mah
- update: read manufacture_date
- update: get _cell_count from parameter and not const 4
- update: avoid re-reading data that has already been read and stored on class already
- currently the battery type defined by BAT_SMBUS_MODEL parameter and not by auto detection
2020-08-18 21:41:19 -04:00
Daniel Agar 372866a22b uORB::DeviceNode replace SubscriptionData with uORB::SubscriptionInterval 2020-08-18 20:48:30 -04:00
Travis Bottalico e325ca25bb modalai-fc-v1 - update default MAVLink configuration 2020-08-18 20:45:20 -04:00
isidroas f4e147964b Tools/setup: ubuntu.sh added jmavsim dependency 2020-08-18 15:09:16 -04:00
PX4 BuildBot 16cd7cc4e9 Update submodule ecl to latest Tue Aug 18 16:42:33 UTC 2020
- ecl in PX4/Firmware (9e9b068f564250f1085954316de789176732ed96): https://github.com/PX4/ecl/commit/1e6c6f2d3ccaed470996c9efe88457299608f1d6
    - ecl current upstream: https://github.com/PX4/ecl/commit/3ae934544f8b2de01b868d0defea992b1000acc3
    - Changes: https://github.com/PX4/ecl/compare/1e6c6f2d3ccaed470996c9efe88457299608f1d6...3ae934544f8b2de01b868d0defea992b1000acc3

    3ae9345 2020-08-17 kamilritz - Add change indication for ekf_gsf_reset
fd849e0 2020-08-16 Paul Riseborough - EKF: Fix specific force observation noise variance
76f393d 2020-08-16 Paul Riseborough - EKF: Use const reference instead of local copy
c43307b 2020-08-16 Paul Riseborough - EKF: convert drag fusion from Matlab to SymPy generated auto-code
2020-08-18 15:07:39 -04:00
TSC21 1eb7809eb5 Jenkins CD: add deploy stage for the microRTPS agent 2020-08-18 17:16:04 +02:00
TSC21 ac9c8bcc09 microRTPS: cmake: fix relative path for IDL files 2020-08-18 17:16:04 +02:00
TSC21 a091a70470 microRTPS: split the microRTPS client and agent dest directories for better visbility and handling 2020-08-18 17:16:04 +02:00
TSC21 cc4cc05dd7 CI/CD: add auto deploy of the microRTPS agent source code to the respective repository 2020-08-18 17:16:04 +02:00
Daniel Agar e9e9556130 ROMFS: remove leftover MC_TPA parameters 2020-08-17 17:07:21 -04:00
Daniel Agar 26bac78eaf mixers: Multirotor remove text roll, pitch, yaw scaling and idle speed 2020-08-17 16:37:08 -04:00
PX4 BuildBot 4afb27411c Update submodule ecl to latest Mon Aug 17 12:39:41 UTC 2020
- ecl in PX4/Firmware (84aeb53ee5847866ecf7698591f00278d12ba770): https://github.com/PX4/ecl/commit/ec934908900b23ee273d1a9f82364b7b38423200
    - ecl current upstream: https://github.com/PX4/ecl/commit/1e6c6f2d3ccaed470996c9efe88457299608f1d6
    - Changes: https://github.com/PX4/ecl/compare/ec934908900b23ee273d1a9f82364b7b38423200...1e6c6f2d3ccaed470996c9efe88457299608f1d6

    1e6c6f2 2020-08-16 Paul Riseborough - EKF: update all output states when aligning output time horizon filter
3bd9415 2020-07-26 kamilritz - Make delayed output stayed not a member variable
da9bfe4 2020-07-26 kamilritz - Update interface of applyCorrectionsToOuputStates
64ab2b0 2020-08-15 Paul Riseborough - EKF: Only record successful sideslip fusion when states updated
0fa7ef3 2020-08-15 Paul Riseborough - EKF: Use ecl::powf for integer exponents
168dbdf 2020-08-15 Paul Riseborough - EKF: Convert sideslip fusion to use SymPy generated auto-code
06aa78a 2020-08-15 Paul Riseborough - EKF: Only record airspeed fusion event when states are updated
486a461 2020-08-15 Paul Riseborough - EKF: airspeed fusion derivation test comparison cleanup
ede6204 2020-08-15 Paul Riseborough - EKF: airspeed fusion cleanup
a5a43db 2020-08-13 Paul Riseborough - EKF: Convert airspeed fusion to use SymPy generated auto-code
5907e81 2020-08-15 Paul Riseborough - EKF: optflow fusion cleanup
7fa9a19 2020-08-15 Paul Riseborough - EKF: optflow fusion cleanup
0e74f3e 2020-08-15 Paul Riseborough - EKF: optflow fusion cleanup
6e992a1 2020-08-15 Paul Riseborough - EKF: optflow fusion cleanup
1ad042d 2020-08-13 Paul Riseborough - EKF: Use ecl::powf in comparison test
274523b 2020-08-13 Paul Riseborough - EKF: Use ecl::powf for integer exponents
f20a5d8 2020-08-13 Paul Riseborough - EKF: Remove redundant tilt check
1592db8 2020-08-13 Paul Riseborough - EKF: Convert optical flow fusion to use SymPy generated equations
1f386c1 2020-08-15 Paul Riseborough - EKF: Add yaw estimate SymPy generated code files
510d938 2020-08-11 Paul Riseborough - EKF: move yaw estimator derivation into main filter derivation
f89c52e 2020-08-13 Paul Riseborough - EKF: use ecl::powf for integer exponents
0aa2f17 2020-08-13 Paul Riseborough - EKF: Convert GPS yaw observation method to use SymPy generated code (#880)
21cc46e 2020-08-11 Paul Riseborough - EKF: Convert magnetic field observation methods to use SymPy generated code (#879)
2020-08-17 16:30:52 -04:00
Daniel Agar 0ff4fad95c rm3100: remove read error message 2020-08-17 09:36:05 -04:00
Daniel Agar 38db7c8b00 lis3mdl: remove read error message 2020-08-17 09:36:05 -04:00
Daniel Agar 84895724cd lis2mdl: remove read error message 2020-08-17 09:36:05 -04:00
TSC21 56a105e322 logger: by default, log the onboard_computer_status topic 2020-08-17 13:24:12 +02:00
Daniel Agar 33e3456de2 mpu9250: accumulated minor improvements and cleanup
- perform reset as per the datasheet (disable I2C immediately, set power mode, wait for appropriate time, etc)
 - remove interrupt perf counter and instead only count misses
 - minor style changes to stay in sync with the other Invensense drivers
2020-08-16 19:01:56 -04:00
Daniel Agar 6b4c14a15c mpu6500: accumulated minor improvements and cleanup
- perform reset as per the datasheet (disable I2C immediately, set power mode, wait for appropriate time, etc)
 - only track consecutive errors (not total) to trigger full reset if necessary
 - remove interrupt perf counter and instead only count misses
 - minor style changes to stay in sync with the other Invensense drivers
2020-08-16 19:01:56 -04:00
Daniel Agar 19adf805d4 mpu6000: accumulated minor improvements and cleanup
- perform reset as per the datasheet (disable I2C immediately, set power mode, wait for appropriate time, etc)
 - only track consecutive errors (not total) to trigger full reset if necessary
 - remove interrupt perf counter and instead only count misses
 - minor style changes to stay in sync with the other Invensense drivers
2020-08-16 19:01:56 -04:00
Daniel Agar 8adea51131 icm42688p: accumulated minor improvements and cleanup
- perform reset as per the datasheet (wakeup accel/gyro and wait before proceeding)
 - add register bank selection (not yet used)
 - track consecutive errors to trigger full reset if necessary
 - remove interrupt perf counter and instead only count misses
 - minor style changes to stay in sync with the other Invensense drivers
2020-08-16 19:01:56 -04:00
Daniel Agar a903eb7411 icm40609d: accumulated minor improvements and cleanup
- perform reset as per the datasheet (wakeup accel/gyro and wait before proceeding)
 - add register bank selection (not yet used)
 - track consecutive errors to trigger full reset if necessary
 - remove interrupt perf counter and instead only count misses
 - minor style changes to stay in sync with the other Invensense drivers
2020-08-16 19:01:56 -04:00
Daniel Agar 50228a05e1 icm20948: accumulated minor improvements and cleanup
- remove interrupt perf counter and instead only count misses
 - minor style changes to stay in sync with the other Invensense drivers
2020-08-16 19:01:56 -04:00
Daniel Agar 473b0456db icm20649: accumulated minor improvements and cleanup
- perform reset as per the datasheet (disable I2C immediately, set power mode, wait for appropriate time, etc)
 - remove interrupt perf counter and instead only count misses
 - minor style changes to stay in sync with the other Invensense drivers
2020-08-16 19:01:56 -04:00
Daniel Agar 146c8a6610 icm20689: accumulated minor improvements and cleanup
- perform reset as per the datasheet (disable I2C immediately, set power mode, wait for appropriate time, etc)
 - only track consecutive errors (not total) to trigger full reset if necessary
 - remove interrupt perf counter and instead only count misses
 - minor style changes to stay in sync with the other Invensense drivers
2020-08-16 19:01:56 -04:00
Daniel Agar 8c8677758a icm20608g: accumulated minor improvements and cleanup
- update copyright year
 - perform reset as per the datasheet (disable I2C immediately, set power mode, wait for appropriate time, etc)
 - only track consecutive errors (not total) to trigger full reset if necessary
 - remove interrupt perf counter and instead only count misses
 - minor style changes to stay in sync with the other Invensense drivers
2020-08-16 19:01:56 -04:00
Daniel Agar e3b1315df5 icm20602: accumulated minor improvements and cleanup
- perform reset as per the datasheet (disable I2C immediately, set power mode, wait for appropriate time, etc)
 - track consecutive errors and trigger full reset if necessary
 - remove interrupt perf counter and instead only count misses
 - minor style changes to stay in sync with the other Invensense drivers
 - read FIFO count along with full transfer as a sanity check
2020-08-16 19:01:56 -04:00
Daniel Agar ad3e6ee5dd wq:attitude_ctrl increase stack by 16 bytes (again) 2020-08-16 18:16:16 -04:00
Daniel Agar 91ad8473ab boards: cubepilot/cubeorange small fixes and improvements
- defconfig UART sync with cube yellow (and other boards)
 - manually start ak09916 (Here2) on I2C2 with proper rotation
2020-08-16 17:45:47 -04:00
Daniel Agar 65ab7cef2e boards: cubepilot/cubeyellow small fixes and improvements
- fix UART config (GPS1, etc)
 - TELEM2 enable TX DMA
 - init simplify (sync with CubeOrange)
 - amber LED use for armed state
 - manually start ak09916 (Here2) on I2C2 with proper rotation
2020-08-16 17:45:47 -04:00
Daniel Agar d3a1225c98 Tools: Ubuntu setup remove "set -e" to prevent grep early exit
- the gcc version grep was causing the script to exit early
2020-08-15 23:40:20 +02:00
Daniel Agar fe06eaf8d9 Tools: Ubuntu setup update arm-none-eabi-gcc to 9-2020-q2-update 2020-08-15 23:40:20 +02:00
David Sidrane 22a7bf6ec7 px4_fmu-v6x Fix BOARD_TYPE 2020-08-14 11:23:16 -04:00
David Sidrane 157aa36c1e NuttX based bootloader:Track QGC change in sequnsing
It appear that QGC is now resyncing between operation.
   This was causing the bl_state to be reset to STATE_PROTO_GET_SYNC
   and loosing the state of (STATE_PROTO_GET_SYNC|STATE_PROTO_GET_DEVICE)
2020-08-14 10:58:23 -04:00
David Sidrane 13246bdb2c common/shutdown:All FMU's not stying in bootloader
Fixes bug, wehre reboot -b would not stay in bootloader.
   Call was passing bit mask (=4) not integer value of 1.
2020-08-14 14:11:45 +02:00
Daniel Agar 877c19704a rm3100: cleanup device interface on destruction 2020-08-14 09:25:47 +02:00
Daniel Agar f1e5b1d284 qmc5883: cleanup device interface on destruction 2020-08-14 09:25:47 +02:00
Daniel Agar 8252fea95b lis3mdl: cleanup device interface on destruction 2020-08-14 09:25:47 +02:00
Daniel Agar 03efea9d73 lis2mdl: cleanup device interface on destruction 2020-08-14 09:25:47 +02:00
Daniel Agar f8241f144c hmc5883: cleanup device interface on destruction 2020-08-14 09:25:47 +02:00
Daniel Agar 0c91a29c3f wq:attitude_ctrl increase stack 2020-08-13 13:32:07 -04:00
Beat Küng ba5d7773f8 mavlink_timesync: print sender comp id for 'RTT too high for timesync' msg (#15539)
helps with debugging
2020-08-13 10:58:25 +02:00
Daniel Agar 0bb5f2c2af uavcan: libuavcan submodule remove redundant libuavcan_drivers 2020-08-12 15:34:10 -04:00
Thies Lennart Alff d7d8aa9b64 uuv_att_control: removed redundant code, switched to new uORB API 2020-08-12 13:16:28 -04:00
Daniel Agar 6937dbc5fd boards: add CUAV Nora support 2020-08-12 13:02:16 -04:00
Daniel Agar 942eb83184 sensors: keep legacy params active (BAT_V_DIV/BAT_A_PER_V) for QGC SITL
- fixes https://github.com/PX4/Firmware/issues/15505
2020-08-12 11:57:34 -04:00
Daniel Agar f19a20dc43 commander: preflight power check ignore module count if USB connected
- this check isn't relevent during bench testing
2020-08-12 11:48:38 -04:00
RomanBapst 355e3ea986 vtol_type: use correct pwm device path in init function
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-08-12 08:55:23 +02:00
RomanBapst 01535a726a vtol_type: reset quadchute filter states if TECS is not running
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-08-12 08:55:23 +02:00
Daniel Agar faeaa411d0 Update submodule mavlink v2.0 to latest Wed Aug 12 00:39:35 UTC 2020
- mavlink v2.0 in PX4/Firmware (49e83b6ae4): https://github.com/mavlink/c_library_v2/commit/cdcea1c68565e435d18f88c12a4d5db20b070df1
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/cc7ed13f41931335c1902da445bbdf12f4d66e63
    - Changes: https://github.com/mavlink/c_library_v2/compare/cdcea1c68565e435d18f88c12a4d5db20b070df1...cc7ed13f41931335c1902da445bbdf12f4d66e63
2020-08-11 23:47:35 -04:00
SalimTerryLi 49e83b6ae4 load_mon: add linux support 2020-08-11 18:33:44 -04:00
David Sidrane 329ed6e273 px4_fmu-v5/v5x: Re-enable TXDMA 2020-08-11 12:27:28 -04:00
David Sidrane c46d5e8535 Nuttx with TX DMA fix 2020-08-11 12:27:28 -04:00
kritz 9d962cdfbc Pr update matrix (#15520)
* Update submodule Matrix

* replace deprecated matrix functions

* update submodule ECL

* Update Matrix submodule

* Use absolute value of loiter radius

* Update ECL submodule
2020-08-11 10:08:41 +02:00
Claudio Micheli 75ab105605 cm8jl65: avoid flooding console with errors if errno is EAGAIN
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2020-08-11 08:14:47 +02:00
Jahir Argote bc98a41d54 Comment typo 2020-08-10 17:39:40 -04:00
Daniel Agar b7f9ff6747 mc_att_control: don't use auto for primitive types
Co-authored-by: Mathieu Bresciani <brescianimathieu@gmail.com>
2020-08-10 14:07:42 -04:00
Daniel Agar 0781fdd813 mc_att_control: don't store vehicle_status copy 2020-08-10 14:07:42 -04:00
Daniel Agar 8c42c38650 mc_att_control: don't store full vehicle_land_detected copy 2020-08-10 14:07:42 -04:00
Daniel Agar 41a1675c53 AttitudeControl: only normalize attitude setpoint once on update 2020-08-10 14:07:42 -04:00
Daniel Agar 1c42d12491 mc_att_control: don't keep att copy and avoid unnecessary Quatf construction and copies 2020-08-10 14:07:42 -04:00
Daniel Agar 5e739f66d6 mc_att_control: inline control attitude call and rate publication
- this makes it clear that we didn't need to keep local copies of the rate setpoint
2020-08-10 14:07:42 -04:00
Daniel Agar 14f734ac15 mc_pos_control: use local position timestamp for dt 2020-08-10 10:51:52 -04:00
Daniel Agar c5eb084236 mc_rate_control: use angular velocity timestamp for dt 2020-08-10 10:51:52 -04:00
Daniel Agar 45ee16d236 mc_att_control: use attitude timestamp for dt 2020-08-10 10:51:52 -04:00
Daniel Agar 9992bd05db fw_att_control: pass time through from run 2020-08-10 10:51:52 -04:00
Daniel Agar 560c22e612 fw_pos_control_l1: pass time through from run 2020-08-10 10:51:52 -04:00
Katrin Moritz 258e5ca5c9 Rename of the DF Robot Rover Airframe 2020-08-10 09:46:36 -04:00
Daniel Agar 97fc1db768 vehicle_local_position: rename yaw -> heading and add reset logic
- vehicle_global_position yaw removed (redundant)
2020-08-10 11:42:03 +02:00
bresch 33fb9d0c62 Commander: update home position yaw in case of EKF yaw reset
This makes sure the drone lands in the correct orientation
during RTL even if the initial yaw at takeoff was wrong.
2020-08-10 11:42:03 +02:00
bresch 0ad3ddd864 Tko ramp: fix takeoff issue with large tko ramp time
Because the velocity starts with a positive value (down) to ramp-up
slowly the motors, the position setpoint (integral) was going down into
the ground, canceling the input of the velocity controller during the
early takeoff phase.
Instead of a smooth ramp, the behavior was a delay followed by a quick
takeoff or a land detection.
Setting the current altitude setpoint with the current altitude during
this phase avoids the canceling effect and creates a takeoff purely
velocity-based.
2020-08-10 10:39:56 +02:00
Daniel Leonard Robinson fa4818e467 vehicles: add new vehicle type: Airship (#14862)
Co-authored-by: Anton Erasmus <anton@flycloudline.com>
Co-authored-by: Beat Küng <beat-kueng@gmx.net>
2020-08-10 08:52:51 +02:00
Daniel Agar 454433c2ef mpu9250: mag relax scheduling and checks 2020-08-09 14:24:49 -04:00
Daniel Agar fbc8e1b09e boards: mRo X2.1-777 fixes
- ardupilot bootloader compatibility (first 3 sectors)
 - clock tree fixes
 - start mavlink
 - start mpu9250 magnetometer (only onboard mag)
 - fixes https://github.com/PX4/Firmware/issues/15466
2020-08-09 14:24:49 -04:00
Daniel Agar e16c8fa345 boards: add new Holybro Pix32v5 2020-08-09 11:48:38 -04:00
SungTae Moon 9707ac5316 implement gazebo simulation based on RTPS for multiple UAVs (#15463)
- add t option for target
   - add iris_rtps model (PX4/sitl_gazebo#558)
2020-08-08 13:19:19 +02:00
Daniel Agar 3002e74b4f mavlink: publish telemetry_status per instance with all HEARTBEATS from the same system
- one telemetry_status publication per mavlink instance
 - each telemetry_status has an array of HEARTBEATS
2020-08-07 12:23:52 -04:00
Thies Lennart Alff f950fe8a38 uuv_att_control: added bodyrate setpoint to the geometric controller
* added bodyrate setpoint to the geometric controller
* started switching to new uORB API
2020-08-06 10:40:44 -04:00
Beat Küng 0f68121ae0 kopis 2 airframe: enable frsky telemetry 2020-08-06 00:08:23 -04:00
Beat Küng bc9be2d040 frsky_telemetry: add support for inverted single-wire S.Port on F7 2020-08-06 00:08:23 -04:00
Beat Küng b6052fbb11 nuttx: update submodule 2020-08-06 00:08:23 -04:00
Daniel Agar 3345bf39b8 cdev: remove unnecessary virtuals and increase opt level
- poll, poll_notify, register_class_devname, unregister_class_devname aren't virtual
 - increase max optimization level on platforms that aren't flash constrained (MAX_CUSTOM_OPT_LEVEL)
2020-08-05 19:07:32 -04:00
JacobCrabill b164174037 uavcan: stm32h7: Fix improper loopback handling
Fixes #15305
2020-08-05 12:42:27 -04:00
Daniel Agar f9c8d38e44 gitattributes eol=lf for nearly all file types
- even windows notepad supports eol=lf these days, so I believe this is the right thing to do for sanity across cygwin, WSL, etc
2020-08-05 11:32:26 -04:00
Daniel Agar de59d6c788 flight_tasks: pass previous setpoint as const reference
- perform setpoint checks in place to simplify and avoid copy
2020-08-05 10:50:15 -04:00
Beat Küng e28395a58b TRIG_MODE: update description to support 78 2020-08-05 09:02:58 +02:00
Hamish Willee 8c6bb697d8 Update json param field names 2020-08-05 07:35:01 +02:00
Igor Mišić f5283e0da1 spracing_h7extreme: OSD enabled with added internal SPI bus flag 2020-08-04 19:07:15 -04:00
Daniel Agar b6a17a6538 new IntrusiveSortedList container used for uORB, WorkQueues, and WorkItems
- new intrusive linked list container (c++ template) that sorts on insertion
 - primarily for convenience inspecting things in the system like uORB or WorkQueues
 - uorb status or top sorted alphabetically 
 - work_queue status threads sorted by priority, then items sorted alphabetically within each
2020-08-04 11:09:41 -04:00
Beat Küng dfc2160489 commander: update vehicle_status with at least 2Hz
So we're sure it's logged.
2020-08-04 10:53:20 -04:00
Beat Küng 5f8c6512b3 vehicle_status: add latest arming/disarming reason
Makes it easier to debug.
2020-08-04 10:53:20 -04:00
Daniel Agar 1f5d0cd2d0 Update submodule mavlink v2.0 to latest Tue Aug 4 12:39:39 UTC 2020
- mavlink v2.0 in PX4/Firmware (b62b12460195df9f4cfe7d8424e79b2f47f9e599): https://github.com/mavlink/c_library_v2/commit/57be0ae2af8d020fe50d716e5ecfab7100d14816
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/cdcea1c68565e435d18f88c12a4d5db20b070df1
    - Changes: https://github.com/mavlink/c_library_v2/compare/57be0ae2af8d020fe50d716e5ecfab7100d14816...cdcea1c68565e435d18f88c12a4d5db20b070df1
2020-08-04 10:47:52 -04:00
PX4 BuildBot 201a3a19ff Update submodule ecl to latest Tue Aug 4 12:39:50 UTC 2020
- ecl in PX4/Firmware (78d30efcf77284b21c130fd31061844ee561aa64): https://github.com/PX4/ecl/commit/77b11129fa567160a2ec442438ed513cb9de89e7
    - ecl current upstream: https://github.com/PX4/ecl/commit/7eb2b08eedb70817779bc7968cf34a4cf6f01fa0
    - Changes: https://github.com/PX4/ecl/compare/77b11129fa567160a2ec442438ed513cb9de89e7...7eb2b08eedb70817779bc7968cf34a4cf6f01fa0

    7eb2b08 2020-07-27 kamilritz - Yaw measurement jacobian to Vector4f
15d360f 2020-07-27 kamilritz - saved_mag_ef_cov to Squarematrix2f
7609bc6 2020-07-27 kamilritz - drag innov member variables to Vector2f
960b80e 2020-07-26 kamilritz - Do not update output filter a second time after reset to flow.
2020-08-04 10:47:15 -04:00
Daniel Agar c40cf9a626 uORB: remove lost message count per DeviceNode
- update 'uorb status' to print basic info for all advertised DeviceNodes
 - report vehicle_command gaps in commander, navigator, mavlink
2020-08-04 10:34:11 -04:00
Beat Küng 4282b3dd47 TRIG_PINS: allow triggering on 78 while still using the lower 6 pins for pwm 2020-08-04 13:37:40 +02:00
Beat Küng ca189fefb7 v5x: use board-specific camera capture pin PI0 2020-08-04 13:37:40 +02:00
Beat Küng 316085c154 camera_capture: remove board-specific ifdef 2020-08-04 13:37:40 +02:00
Beat Küng 46208edfac fix camera_trigger: no need to check for '_pins[i] < num_gpios'
_pins[i] >= num_gpios is a valid config.
2020-08-04 13:37:40 +02:00
Beat Küng 002e671d3f fix pwm_out,dshot: set _num_outputs to 5 for mode_pwm5 2020-08-04 13:37:40 +02:00
Beat Küng 78e918ff3a fix pwm_out: respect _num_outputs for calling up_pwm_servo_set()
_num_outputs is set according to the mode_pwmX call, which is required
for camera triggering.
This fixes camera triggering via PWM, as it avoids overwriting the channel.
2020-08-04 13:37:40 +02:00
Silvan Fuhrer 7a71cbb9bf FlightTask Auto: use yaw setpoint from Navigator if disable_weather_vane is true
When disable_weather_vane is true, the vehicle is aligning for the transition waypoint
(VTOL) and thus the yaw setpoint from Navigator should be used.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-08-04 11:45:08 +02:00
Daniel Agar a93052f9b2 boards/spracing/h7extreme: delete unused stackcheck build 2020-08-03 15:56:33 -04:00
Daniel Agar 834dcbeb3d add spracing_h7extreme_default to builds 2020-08-03 15:56:33 -04:00
Igor Mišić 7eaa48e36f New board: SP Racing H7 Extreme
Authored-by: igor.misic <igor.misic@rimac@automobili.hr>
2020-08-03 15:32:58 -04:00
Daniel Agar ba640acfcc mc_hover_thrust_estimator: validity flag and other small improvements/fixes
- track and publish validity based on hover thrust variance, innovation test ratio, and hysteresis
 - only publish on actual updates or becoming inactive
 - fix dt (previous timestamp wasn't being saved)
 - use local position timestamp (corresponding) to accel data rather than current time to avoid unnecessary timing jitter
 - check local position validity before using
 - mc_hover_thrust_estimator: move from wq:lp_default -> wq:nav_and_controllers to ensure the hover thrust estimator runs after the position controller and uses the same vehicle_local_position data
 - land_detector: check hover thrust estimate validity and adjust low throttle thresholds if hover thrust is available
 - mc_pos_control: only use hover thrust estimate if valid
2020-08-03 10:30:52 -04:00
Hamish Willee 958d5a36ec params: generate param metadata as MAVLink-compatible JSON component info (#15389) 2020-08-03 12:00:37 +02:00
Daniel Agar 6923d9eb64 Update submodule mavlink v2.0 to latest Sun Aug 2 16:36:28 UTC 2020
- mavlink v2.0 in PX4/Firmware (71c633fabbc7a00f263ff8dc3d624afa73d80c4d): https://github.com/mavlink/c_library_v2/commit/cf6e8cb415d0e4e1a6722f8d0026de85f18f3057
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/57be0ae2af8d020fe50d716e5ecfab7100d14816
    - Changes: https://github.com/mavlink/c_library_v2/compare/cf6e8cb415d0e4e1a6722f8d0026de85f18f3057...57be0ae2af8d020fe50d716e5ecfab7100d14816

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-08-02 13:41:14 -04:00
PX4 BuildBot d3a14b3ff1 Update submodule sitl_gazebo to latest Sun Aug 2 16:36:22 UTC 2020
- sitl_gazebo in PX4/Firmware (1191a0efe6): https://github.com/PX4/sitl_gazebo/commit/ce1eca2bd0bedf9305d09b622454fa21962d50ba
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/037ce1b3b88b1c25abc1f525fbbbec84589d090d
    - Changes: https://github.com/PX4/sitl_gazebo/compare/ce1eca2bd0bedf9305d09b622454fa21962d50ba...037ce1b3b88b1c25abc1f525fbbbec84589d090d

    037ce1b 2020-07-24 Jan-Hendrik Ewers - Oversight fix from #544 (#553)
2020-08-02 13:40:34 -04:00
Daniel Agar f5f2897486 land_detector: multicopter ground contact fixes, improvements, and cleanup
- if "landed" and "maybe_landed" states are false then both the "hit_ground" and the "low_thrust" condition need to be true in order to detect landing
 - ground contact MC NAN setpoint workaround
 - ground contact additionally check acceleration setpoint
 - schedule with vehicle_local_position updates (most updates require valid local position)
 - don't allow LNDMC_Z_VEL_MAX to exceed MPC_LAND_SPEED
 - ground contact horizontal movement checks default to failed if estimates aren't available
2020-08-02 13:37:23 -04:00
Daniel Agar 63a23957b1 rc/dsm: decode improvements
- always check system field for validity
 - reject any data outside of "servo position" valid range from Spektrum specification
 - properly support XPlus channels (12+)
 - debug message if channel count changes
2020-08-02 12:52:16 -04:00
Daniel Agar 1191a0efe6 Update ecl to geo_lookup, SymPy covariance, bugfixes
Co-authored-by: Matthias Grob <maetugr@gmail.com>
2020-08-02 12:26:48 -04:00
David Sidrane e2a9b68fc7 kinetis:Add kinetis_gpiosetevent in PX4 layer
Adds a compatible gpiosetevent interface. The helper call the
   low level functions while providing a consistent API with
   xxxx_ gpiosetevent(uint32_t pinset, bool risingedge,
                      bool fallingedge, bool event, xcpt_t func,
                      void *arg);

   This wrapper was rjected upstream.
2020-07-31 09:46:27 -04:00
David Sidrane 726b1aa8bb Add nxp_fmuk66-e to CI 2020-07-31 09:46:27 -04:00
David Sidrane e67486d603 nxp:Add support for rev E HW nxp_fmuk66-e 2020-07-31 09:46:27 -04:00
David Sidrane f8b6de24c7 nxp_fmurt1062-v1:Assign board_id 2020-07-31 09:46:27 -04:00
Steve Nogar 48bf9268c3 rename Mixer to MixerBase to resolve case-insensitivity on mac 2020-07-31 09:37:49 -04:00
TSC21 342b1c5ded microRTPS: client: properly set task/thread naming 2020-07-31 14:13:10 +01:00
TSC21 162e0c7675 microRTPS: client: reserve the minimum required stack to the send/receive tasks 2020-07-31 14:13:10 +01:00
TSC21 0b41aa3ecd microRTPS: client: dynamically allocate the uORB pub/subs 2020-07-31 14:13:10 +01:00
TSC21 398f104918 microRTPS: transport: do not discard message from rx_buffer if a CRC error occurs 2020-07-31 14:13:10 +01:00
TSC21 1ab193f548 microRTPS: remove the need for the eClock util 2020-07-31 14:13:10 +01:00
TSC21 acc3866ac9 generate_microRTPS_bridge: make sure that the ROS2 version of FastRTPS is grabbed in a colcon build 2020-07-31 14:13:10 +01:00
TSC21 311a8144e1 microRTPS: client: use structs for pub/subs to avoid increasing the stack usage 2020-07-31 14:13:10 +01:00
TSC21 3db9307dfb microRTPS: transport: make seq_number non-atomic 2020-07-31 14:13:10 +01:00
TSC21 08e72b29b3 microRTPS: micrortps_timesync: reduce max RTTI to 50ms 2020-07-31 14:13:10 +01:00
TSC21 c01bcd41f7 microRTPS: minor adjustements so to improve the readings; add more baud rate options
Co-authored-by: Andrew Wedemier <andrew.wedemier@gmail.com>
2020-07-31 14:13:10 +01:00
TSC21 0124ca6e41 microRTPS: add debug verbose option '-v'; use while loop for reads; ease the RTTI check on timesync 2020-07-31 14:13:10 +01:00
TSC21 2f4eff4c38 microRTPS: add possibility to set HW or SW flow control; improve verbosity aesthetics 2020-07-31 14:13:10 +01:00
TSC21 b2845c60d3 microRTPS: move buffer size to transport 2020-07-31 14:13:10 +01:00
TSC21 407bd8860f microRTPS: transport: hotfix to skip data packets that that don't fit the buffer and continue the readings 2020-07-31 14:13:10 +01:00
TSC21 25d2236cce microRTPS: fix FastRTPS version check on agent templates 2020-07-31 14:13:10 +01:00
Daniel Agar 9b12647ac4 px4io: delete broken test and unnecessary limit
- delete broken px4io test and if_test
 - delete px4io limit (a fixed 400 Hz limit was always set at boot)
2020-07-30 10:29:07 -04:00
Koby Aizer 60d767406a PAW3902: document that the driver is also compatible with PAW3903 module 2020-07-30 10:05:49 -04:00
Matthias Grob a6777e2650 Subscription: correct doxygen comment 2020-07-30 09:56:01 -04:00
Daniel Agar e4fa7597f4 logger: SDLOG_PROFILE remove estimator replay from default to minimize log rate
- log full sensor_combined by default for now
 - small decrease to input_rc rate (manual_control_setpoint is no longer filtered)
 - sensor_correction can be logged at full rate (low publication rate)
2020-07-29 15:07:42 -04:00
Daniel Agar 1b30bd328e logger: decrease try subsribe interval 1000 ms -> 20 ms 2020-07-29 13:36:22 -04:00
Daniel Agar 7b46efaa6b logger: record message gaps 2020-07-29 13:36:22 -04:00
Daniel Agar f7415c3354 optical_flow/paw3902: silence info output (info -> debug) 2020-07-29 11:58:54 -04:00
Daniel Agar 86365949f6 Update submodule mavlink v2.0 to latest Wed Jul 29 00:38:22 UTC 2020
- mavlink v2.0 in PX4/Firmware (0b2d4a8ae765f36f984e7b6ddd12a7b17b767ed2): https://github.com/mavlink/c_library_v2/commit/f90ef7c95aeaf953f7b0f6766929fa56d37e6ec7
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/cf6e8cb415d0e4e1a6722f8d0026de85f18f3057
    - Changes: https://github.com/mavlink/c_library_v2/compare/f90ef7c95aeaf953f7b0f6766929fa56d37e6ec7...cf6e8cb415d0e4e1a6722f8d0026de85f18f3057
2020-07-28 23:50:02 -04:00
Katrin a448e82798 Rover Airframe 50004_dfrobot_gpx_asurada: Changing of physical parameter
- the values of the parameters GND_MAX_ANG and GND_WHEEL_BASE are outdated. They belonged to another Rover setup.
 - in the mixer file rover_diff_and_servo.main.mix the steering was controlled by roll, but in PX4 rover steering is controlled by yaw. And this was the reason why the attitude control did not work correctly
 - the DF Robot GPX:Asurada rover has actual a steering angle of 60 degrees. And and wheel base of 0.17m. Parameter values in the airframe file are changed to this values
2020-07-28 21:34:12 -04:00
pengl-aee09 18eccb0cbd PAW3902: align mode change logic with the spec
1. The spec specifies that the mode change condition should be met for 10
   consecutive frames before changing to the next mode.
2. The spec (and comment) says that "PAW3902JF should not operate with Shutter < 0x01F4 in Mode 2" -
   however the if condition checked the reverse condition

Signed-off-by: Koby Aizer <koby.aizer@tg-17.com>
2020-07-28 21:29:43 -04:00
bazooka joe 8a3a71caed simplify the code to calculate signal_quality 2020-07-28 23:45:38 +01:00
bazooka joe 4d1c7b734c don't set quality to 0 for lidar lite v3hp, because the strength data is valid even for short distance 2020-07-28 23:45:38 +01:00
Daniel Agar ca33bb1c01 load_mon: slightly longer cpu average (300 -> 500 ms) 2020-07-28 13:41:50 -04:00
Julian Oes b108adc5f1 Tools: retry gz model if gzserver is not ready yet
This should prevent the race between gzserver and gz model and fix the
integration tests which sometimes timeout because the model is not
spawned correctly.

This patch also changes the shebang to what's generally recommended.
2020-07-28 11:51:51 +02:00
stmoon 71b7647ca1 fix the return type problem of RTPS 2020-07-27 16:22:46 +01:00
stmoon b457122489 remove unnecessary stderr msg when checking ldconfig 2020-07-27 16:21:58 +01:00
Daniel Agar 7354e39893 Jenkins HIL remove mRo Control Zero
- there are issues with the particular harware on the rack (an early prototype)
2020-07-26 19:36:44 -04:00
Daniel Agar cfbf69f2a7 boards: rename Hex -> CubePilot
- hex_cube-orange_default -> cubepilot_cubeorange_default
 - hex_cube-yellow_default -> cubepilot_cubeyellow_default
2020-07-26 13:55:41 -04:00
Daniel Agar 62fe6d59cc boards: hex cube yellow fix STM32F7 selection (STM32F765II -> STM32F777VI) 2020-07-24 12:03:25 -04:00
Hamish Willee 4ade24869f parameters: move XML injection to the group level (#15403)
So that they are also in the markdown and json output.
2020-07-24 13:45:53 +02:00
Matthias Grob 400d97e60c math: add unit tests for everything in Functions.hpp 2020-07-24 11:31:15 +02:00
Matthias Grob 0b391fdcfc mc_att_control: add gradual3 function to cover hover thrust rescaling 2020-07-24 11:31:15 +02:00
Daniel Agar aa7735c1c0 pwm_out: limit actuator control callbacks to primary groups
- add backup schedule at minimum PWM rate
 - fixes #15043
2020-07-23 09:45:04 -04:00
Daniel Agar 0586079a84 mixer_module: add subscription option to limit additional actuator_control callbacks
- optionally only register callbacks for primary control groups (if used)
2020-07-23 09:45:04 -04:00
Daniel Agar 9426c68a13 cmake: only allow gold linker for posix builds
- the gold linker doesn't currently work for NuttX builds
 - NuttX skip --print-memory-usage if using the GOLD linker
 - fixes #15400
2020-07-23 09:41:35 -04:00
Mirko Denecke 7ac66bae4f hex io firmware remove double definition of GPIO_HEATER_OFF 2020-07-23 09:41:05 -04:00
Mirko Denecke b7389119b3 px4 io firmware remove double definition of GPIO_HEATER_OFF 2020-07-23 09:41:05 -04:00
Julian Oes 26021b01cb Tools: abort SITL start if gzserver fails
Sometimes gzserver seems to not start or not start fast enough. In this
case, instead of stalling forever, it would be nice to abort.
2020-07-23 07:42:09 +02:00
Mirko Denecke 01e9599e93 HEX Cube Yellow: enable platform-specific IO firmware with inverted heater pin. 2020-07-22 10:50:47 -04:00
Mirko Denecke 44e2c326e0 HEX Cube Orange: enable platform-specific IO firmware with inverted heater pin. 2020-07-22 10:50:47 -04:00
Mirko Denecke 57968c6e27 Add platform-specific IO firmware for HEX autopilots. 2020-07-22 10:50:47 -04:00
Mirko Denecke 2581badabd Add ifdef to invert heater pin for px4 IO firmware. 2020-07-22 10:50:47 -04:00
xdwgood f014d0de8e Correctly set the FW_ARSP_MODE parameter value 2020-07-22 10:43:46 -04:00
Lorenz Meier 3b1be7dcd3 Revert "mavlink: GLOBAL_POSITION_INT send without lat/lon availability"
This reverts commit ad14796b5f.
2020-07-22 10:34:18 -04:00
Daniel Agar e4f65f81f7 vtol_att_control: limit excessive scheduling
- this is to prevent vtol_att_control running at absurdly high rates (kilohertz) from every single actuator controls publication from both the multicopter and fixed wing controllers
 - I don't really like this solution, but it works for now until there are larger VTOL architectural changes in place
2020-07-21 11:40:04 -04:00
Matthias Grob 5c5005fa58 ROMFS: remove remaining RC_FLT_CUTOFF
The parameter was removed in #14896 and I forgot to remove it from
all the configurations.
2020-07-21 11:28:18 -04:00
Matthias Grob aad7e88af2 setup scripts: install dmidecode before using it
On normal desktop distributions dmidecode is preinstalled
and I was assuming it's part of the core tools. Thanks to a hint
https://github.com/PX4/Firmware/pull/15241#issuecomment-659395458
I found out it's not and am installing the package before using it.
2020-07-21 10:22:52 -04:00
Daniel Agar b8b19f6166 cdev: posix remove std::map usage
- this is to make things a little easier for platforms like QuRT (voxl snapdragon) where there are libstdc++ complications
2020-07-21 10:17:55 -04:00
Daniel Agar 81f57bccb6 px4io: servorail_status -> px4io_status and log all flags 2020-07-21 09:56:13 -04:00
Julian Oes 962b865301 Makefile: fix mavsdk_tests invocation
The config file was missing and a speed factor of 20 is much more
realistic.
2020-07-21 13:52:47 +02:00
Matthias Grob 9ba2539e60 FlightTaskOrbit: reset approach if radius gets changed 2020-07-21 10:27:05 +02:00
Matthias Grob e9498064ef StraightLine: allow resetting reached flag 2020-07-21 10:27:05 +02:00
Matthias Grob 5823101f07 FlightTaskOrbit: reset reached when new parameters are set
such that they get applied to the straight line trajectory class
and the drone starts approaching the new orbit.
2020-07-21 10:27:05 +02:00
Matthias Grob 8e4509c0a9 FlightTaskOrbit: simplify tangential yaw_setpoint and pi wrap 2020-07-21 09:44:21 +02:00
Matthias Grob 4d0aadbcd0 FlightTaskOrbit: set initial heading for every new command 2020-07-21 09:44:21 +02:00
Matthias Grob abf6f4fa0a FlightTaskOrbit: move start_to_circle to more local scope & const reference parameters 2020-07-21 09:44:21 +02:00
Matthias Grob b8b46f8493 FlightTaskOrbit: use yaw setpoint from Altitude task with RC yaw mode 2020-07-21 09:44:21 +02:00
Matthias Grob 1b7349339e FlightTaskOrbit: move line break causing comments before 2020-07-21 09:44:21 +02:00
xdwgood 7ecccf01c2 tailsitter.cpp:ensure input quaternions are exactly normalized 2020-07-21 08:21:41 +02:00
Daniel Agar 730af406a6 ROMFS: remove unnecessary parameter zero padding 2020-07-21 08:11:22 +02:00
Jan-Hendrik Ewers 0b50f85096 Update gazebo_sitl_multiple_run.sh (#15382)
If `make px4_sitl_default` is run, and not `make px4_sitl_default gazebo` then each model instance will throw the following errors:
```
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_gps_plugin.so: libgazebo_gps_plugin.so: cannot open shared object file: No such file or directory
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_multirotor_base_plugin.so: libgazebo_multirotor_base_plugin.so: cannot open shared object file: No such file or directory
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_motor_model.so: libgazebo_motor_model.so: cannot open shared object file: No such file or directory
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_motor_model.so: libgazebo_motor_model.so: cannot open shared object file: No such file or directory
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_motor_model.so: libgazebo_motor_model.so: cannot open shared object file: No such file or directory
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_motor_model.so: libgazebo_motor_model.so: cannot open shared object file: No such file or directory
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_groundtruth_plugin.so: libgazebo_groundtruth_plugin.so: cannot open shared object file: No such file or directory
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_magnetometer_plugin.so: libgazebo_magnetometer_plugin.so: cannot open shared object file: No such file or directory
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_barometer_plugin.so: libgazebo_barometer_plugin.so: cannot open shared object file: No such file or directory
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_mavlink_interface.so: libgazebo_mavlink_interface.so: cannot open shared object file: No such file or directory
[Err] [Plugin.hh:178] Failed to load plugin libgazebo_imu_plugin.so: libgazebo_imu_plugin.so: cannot open shared object file: No such file or directory
```
2020-07-21 09:36:15 +09:00
Daniel Agar 2adc23fd97 sensors/vehicle_imu: initially schedule conservatively
- this lowers the load immediately at boot while still allowing each VehicleIMU instance to properly measure the actual accel/gyro data rates
 - for lockstep builds this is ignored and VehicleIMU initially runs with every new sensor_accel/sensor_gyro publication
2020-07-20 10:05:11 -04:00
Matthias Grob ed7732eaec rc_loss_alarm: remove unimplemented declaration 2020-07-20 09:36:47 -04:00
Matthias Grob 987826f1d4 mixer_module/tap_esc: fix usage of constrain() on input
I changed the input constraint in #15349 but screwed up the usage
because I was convinced it's püass by reference. I'll double check
for sure next time.
2020-07-20 09:23:42 +02:00
PX4 BuildBot 650b601206 Update submodule matrix to latest Sun Jul 19 12:40:00 UTC 2020
- matrix in PX4/Firmware (20d5e7acd6d7be141de802ad155592e7be4c9f77): https://github.com/PX4/Matrix/commit/9a30828a0a1d79e87fd09653bb9f936d7ca0ba17
    - matrix current upstream: https://github.com/PX4/Matrix/commit/0fd99c59f1740a7aa2ead03168705b4211bf29e8
    - Changes: https://github.com/PX4/Matrix/compare/9a30828a0a1d79e87fd09653bb9f936d7ca0ba17...0fd99c59f1740a7aa2ead03168705b4211bf29e8

    0fd99c5 2020-07-14 Matthias Grob - Switch operator() to return a const reference
8a59b46 2020-07-17 kamilritz - Quaternion: Use template type instead of single hardcoded type
2020-07-19 12:25:55 -04:00
Daniel Agar 459abcd035 uORB: print individual bits of fields
- applies to messages with names containing "flags" or "bits" and unsigned fixed width integer type (uint8, uint16, uint32)
2020-07-19 12:25:15 -04:00
rolandash b8f3b97bad Enable PMW3901 on MindPX/MindRacer. (#15375)
* enable pmw3901 on MindPX/MindRacer.

* remove useless line.
2020-07-19 16:09:57 +01:00
PX4 BuildBot 11614f789d Update submodule sitl_gazebo to latest Sun Jul 19 12:39:36 UTC 2020
- sitl_gazebo in PX4/Firmware (f4d7052bec): https://github.com/PX4/sitl_gazebo/commit/629e5f5c239d88421edab12b4a7e2e3c3ea7e8fc
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/ce1eca2bd0bedf9305d09b622454fa21962d50ba
    - Changes: https://github.com/PX4/sitl_gazebo/compare/629e5f5c239d88421edab12b4a7e2e3c3ea7e8fc...ce1eca2bd0bedf9305d09b622454fa21962d50ba

    ce1eca2 2020-07-19 Daniel Leonard Robinson - New vehicle type: Airship (#490)
df186d2 2020-07-18 TSC21 - use 'EnableC++XX' and remove duplicated compiler sets
60e5d4e 2020-07-18 TSC21 - remove the check for the 'px4' binary (it's never found since it's built in parallel with sitl_gazebo)
a3b5c5e 2020-07-19 JaeyoungLim - Fix moment calculation (#545)
07820ee 2020-07-19 JaeyoungLim - Fix gimbal imu sensors intefering with each other (#549)
2020-07-19 15:46:53 +01:00
PX4 BuildBot fb2ebc9379 Update submodule nuttx to latest Sun Jul 19 12:39:45 UTC 2020
- nuttx in PX4/Firmware (2624730b02ea71fa2bbd28cc424d9bade5766356): https://github.com/PX4/NuttX/commit/61742342ec979867dbe4b85c89a6821656090ee2
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/dc10293feb724d50f6a0a64a068b47cb8cdae631
    - Changes: https://github.com/PX4/NuttX/compare/61742342ec979867dbe4b85c89a6821656090ee2...dc10293feb724d50f6a0a64a068b47cb8cdae631

    dc10293feb 2020-05-25 Claudio Micheli - [BACKPORT] stm32l4: extend CAN ioctrl with NART/ABOM. Add RTR to CAN header
5735f765e2 2020-05-25 Claudio Micheli - [BACKPORT] stm32: extend CAN ioctrl with NART/ABOM. Add RTR to CAN header
4dc9ae05f5 2020-05-25 Claudio Micheli - [BACKPORT] stm32f7: Add the option to include RTR in CAN header
bdd9e786e1 2020-04-21 Beat Küng - [BACKPORT] stm32f7: add CANIOC_SET_NART and CANIOC_SET_ABOM ioctl's to can driver
2020-07-19 06:47:11 -07:00
Nuno Marques f4d7052bec Update submodule mavlink v2.0 to latest Sat Jul 18 12:39:32 UTC 2020
- mavlink v2.0 in PX4/Firmware (b54dea0ccd): https://github.com/mavlink/c_library_v2/commit/f608801c1bdfbc1ddf71a243444d27dd7b45f8c6
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/f90ef7c95aeaf953f7b0f6766929fa56d37e6ec7
    - Changes: https://github.com/mavlink/c_library_v2/compare/f608801c1bdfbc1ddf71a243444d27dd7b45f8c6...f90ef7c95aeaf953f7b0f6766929fa56d37e6ec7
2020-07-18 14:29:02 -04:00
Daniel Agar 3dd7d0c292 boards: fmu-v5 debug variant disable unnecessary modules to save flash
- partially sync with fmu-v5 stackcheck build
2020-07-18 13:41:26 -04:00
Daniel Agar b54dea0ccd wq:attitude_ctrl: small stack increase to silence warning 2020-07-17 19:51:48 -04:00
Daniel Agar 42493b3d59 logger: add full commander and safety logging by default
- increase battery_status rate to be useful
2020-07-17 17:27:15 -04:00
Daniel Agar 94a5a97dcc drivers/safety_button: only publish safety at 1 Hz or immeidately on change 2020-07-17 17:27:15 -04:00
Daniel Agar c6aafed9d0 px4io: only publish safety at 1 Hz or immeidately on change 2020-07-17 17:27:15 -04:00
Daniel Agar bdb4251fa4 fw_pos_control_l1: if using air data (baro) copy every cycle
- vehicle_air_data won't necessary have an update every iteration and these adjusted throttle values aren't stored
 - this only would have worked in the past because the vast majority of systems were using the ms5611 barometer with a publication rate that's faster than the controller
2020-07-17 17:14:45 -04:00
Daniel Agar e3d31a881e boards: NuttX disable posix message queues 2020-07-17 17:00:21 -04:00
Julian Oes 9723b26d72 workflows: OSX.sh is now called macos.sh 2020-07-17 14:58:31 -04:00
Julian Oes 7c49afa716 setup: only install homebrew if not already there 2020-07-17 14:58:31 -04:00
Julian Oes 7667298c86 setup: move the OSX.sh script to macos.sh
It's called macOS for a while now, and no longer OSX.
2020-07-17 14:58:31 -04:00
Julian Oes 6acf279085 setup: we no longer need Java 8
However, Java 11 or 14 depending on the Ubuntu version are just fine.
2020-07-17 14:58:31 -04:00
Julian Oes 000c0c5905 setup: mark Ubuntu 16.04 as unsupported
Ubuntu was already unsupported, now that 20.04 is out, however, the
change was not reflected yet in this script.
2020-07-17 14:58:31 -04:00
Julian Oes cece343cf7 setup: Java 14 is fine now 2020-07-17 14:58:31 -04:00
Julian Oes aed114465e setup: clean up macOS setup script
- Spaces -> tabs.
- Remove "brew install python" because it's already a dependency of the
  px4-dev tap.
- Remove "brew install ccache" as we can also add it to the px4-dev tap.
- Don't try to update pip installation, it works fine as is.
- Install pip dependencies as user, no need for system-wide install.
2020-07-17 14:58:31 -04:00
Daniel Agar ad14796b5f mavlink: GLOBAL_POSITION_INT send without lat/lon availability
- the altitude and velocity portions of this message are still relevant
without GPS lat/lon
2020-07-17 10:46:06 -04:00
Julian Oes 9d97148ce8 commander: fix takeoff and land CI test
This fixes the takeoff and land CI test where we do a takeoff and land
without RC connected.

In my opinion it does not make sense to go into RC lost failsafe if
a datalink is still available.
Of course, this can be dangerous if someone has a companion computer
connected which gets detected as "data link" but actually has no
connection to the ground station.
2020-07-17 10:30:13 -04:00
Daniel Agar e79ccd1333 Jenkins: hardware print vehicle_air_data 2020-07-17 09:42:19 -04:00
Daniel Agar 9a1ca00285 fw_pos_control_l1: replace sensor_baro with vehicle_air_data
- controllers shouldn't be accessing raw sensor data directly
2020-07-17 09:42:19 -04:00
Daniel Agar 1394b5d7bc sensor_baro add separate timestamp_sample field
- the timestamp is uORB message publication metadata
2020-07-17 09:42:19 -04:00
Daniel Agar 19059a80bd sensors: throttle vehicle_air_data publication (SENS_BARO_RATE)
- don't bother running baro aggregator if SYS_HAS_BARO disabled
2020-07-17 09:42:19 -04:00
bresch 67ae40e922 FlightTaskAuto: fix yaw reset issue during takeoff
During takeoff, Navigator is sending a constant yaw value.
However, there is always a reset at 1.5m of the yaw estimate in EKF2
that is not handled by Navigator that produces a glitch in the rate
controller. Given that in FlightTask, the yaw
is already computed and properly corrected in case of an estimator reset
event, we just ignore the yaw value sent by navigator during takeoff.
2020-07-17 10:51:01 +02:00
Daniel Agar 8020d6407f load_mon: remove obsolete rate comment in description 2020-07-16 15:11:53 -04:00
Daniel Agar f0ceb44f6c Jenkins: hardware print cpuload 2020-07-16 15:11:53 -04:00
Daniel Agar 392eb123fc load_mon: split out header 2020-07-16 15:11:53 -04:00
Daniel Agar fd66d42906 load_mon updates
- increase rate
 - cpu load calculation grab timestamp atomically
 - only check one task per cycle (but cycle at a higher rate)
 - decrease available FD threshold
 - minor cleanup
2020-07-16 15:11:53 -04:00
Matthias Grob 413cf8b7c4 FlightTasks: Sticks methods naming refactor according to comments 2020-07-16 19:01:22 +02:00
Matthias Grob 0d56035a46 FlightTaskAutoMapper: clarify influence of sticks 2020-07-16 19:01:22 +02:00
Matthias Grob 079c5a11c2 FlightTaskAuto: allow rc assist to stop descend
Before the autohority was only enough to slow down the descend but not
stop to zero vertical velocity.
2020-07-16 19:01:22 +02:00
Matthias Grob 91c0f19121 FlightTaskAuto: use new Sticks class for assisted land speed 2020-07-16 19:01:22 +02:00
Matthias Grob 4366898f11 FlightTasks: make gear switch independent of sticks 2020-07-16 19:01:22 +02:00
Matthias Grob 4667693f37 mixer_module: use math:constrain 2020-07-16 16:55:33 +02:00
Oleg b2af2f32d4 mavlink_ftp: close session without activity
10s inactivity timeout to close session
2020-07-16 14:49:44 +02:00
Daniel Agar 1bf0c58537 Update submodule mavlink v2.0 to latest Thu Jul 16 00:39:38 UTC 2020
- mavlink v2.0 in PX4/Firmware (b5ffdc6d35): https://github.com/mavlink/c_library_v2/commit/d87878bce48d49fc3ab7305b7ffc907590f3468e
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/f608801c1bdfbc1ddf71a243444d27dd7b45f8c6
    - Changes: https://github.com/mavlink/c_library_v2/compare/d87878bce48d49fc3ab7305b7ffc907590f3468e...f608801c1bdfbc1ddf71a243444d27dd7b45f8c6

    f608801c 2020-07-15 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/4eee4b83c2ad711615d43e99d93a55f247ba9aa9

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-07-16 00:07:17 -04:00
PX4 BuildBot b5ffdc6d35 Update submodule sitl_gazebo to latest Wed Jul 15 12:39:34 UTC 2020
- sitl_gazebo in PX4/Firmware (d791c8baad): https://github.com/PX4/sitl_gazebo/commit/1af7e29dbb1ecce7b0b191c9deb24ab1f13916ab
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/629e5f5c239d88421edab12b4a7e2e3c3ea7e8fc
    - Changes: https://github.com/PX4/sitl_gazebo/compare/1af7e29dbb1ecce7b0b191c9deb24ab1f13916ab...629e5f5c239d88421edab12b4a7e2e3c3ea7e8fc

    629e5f5 2020-07-15 Morten Fyhn Amundsen - Barometer drift (#544)
4ec5caa 2020-04-26 JaeyoungLim - Make wind plugin a world plugin
2020-07-15 12:42:11 -04:00
Daniel Agar e74c0b0ef6 Update submodule mavlink v2.0 to latest Wed Jul 15 12:39:39 UTC 2020
- mavlink v2.0 in PX4/Firmware (a06326f99a6964295550176855bd7b93b55ebc9e): https://github.com/mavlink/c_library_v2/commit/d5538ea0da8b09da6e9ef1399041c7d67ac31f8f
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/d87878bce48d49fc3ab7305b7ffc907590f3468e
    - Changes: https://github.com/mavlink/c_library_v2/compare/d5538ea0da8b09da6e9ef1399041c7d67ac31f8f...d87878bce48d49fc3ab7305b7ffc907590f3468e
2020-07-15 12:41:13 -04:00
stmoon 4418179a92 fix the fastrtps version problem in case of v1.10.0 2020-07-15 16:30:58 +01:00
Ricardo Marques d0c74712b5 Fix comment typo in mavlink_receiver.cpp 2020-07-15 10:47:52 -04:00
PX4 BuildBot cfcdab3992 Update submodule nuttx to latest Wed Jul 15 12:39:46 UTC 2020
- nuttx in PX4/Firmware (fbc4fa04c372960894766a69c8ea35dfafcb0c4d): https://github.com/PX4/NuttX/commit/f5925e194e82b0658b0176a9657820a396674642
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/61742342ec979867dbe4b85c89a6821656090ee2
    - Changes: https://github.com/PX4/NuttX/compare/f5925e194e82b0658b0176a9657820a396674642...61742342ec979867dbe4b85c89a6821656090ee2

    61742342ec 2020-07-09 Beat Küng - [BACKPORT] gpio: extend gpio_pintype_e for pulldown/up and opendrain
2020-07-15 09:59:37 -04:00
Daniel Agar fe84bdac6e README: remove broken jenkins build status badge 2020-07-15 09:54:30 -04:00
Julian Kent 435c2fe438 Fix rarely flakey test on Github Actions 2020-07-15 09:50:58 -04:00
Julian Oes 5f2abb66a4 mavsdk_tests: add workaround to prevent failsafe
This workaround should fix the test failure where we disarm before
taking off because we accidentally switched to failsafe mode right
before taking off because we were still in Manual mode and not Hold yet.
2020-07-15 09:38:06 -04:00
Julian Oes 4ad7ea6c1a mavsdk_tests: increase the poll time resolution
With only 10 steps for e.g. 60 seconds we are likely to miss updates.
2020-07-15 09:38:06 -04:00
Daniel Agar d791c8baad mavlink: mission manager fix signed sequence debug print type 2020-07-14 12:47:57 -04:00
Matthias Grob 1e56eed2aa Remove FlightTaskManual from the inheritance structure 2020-07-14 18:07:09 +02:00
Matthias Grob 9daff24e79 FlightTasks: move stick handling into library 2020-07-14 18:07:09 +02:00
Pandacoolcool 49a543e1b2 systemcmds/tests: Ignore unused but set parameter warnings 2020-07-14 10:05:55 -04:00
Matthias Grob ced91f135b posix rcS: remove various SITL custom settings
because we need to have SITL simulation as realistic as possible
compared to a real flight with default settings such that we
either fix the problems or adjust the defaults already in SITL testing.
2020-07-14 09:58:46 -04:00
Daniel Agar fa44cd5cd5 px4_work_queue: rename navigation_and_controllers -> nav_and_controllers
- keep the thread within the current NuttX max length
2020-07-14 09:48:47 -04:00
Julian Kent 78ff7c608f Expand tracking error for straight line test 2020-07-14 11:34:14 +02:00
Julian Kent 14e2603bc4 Pull out matrix math primitives into anon functions 2020-07-14 11:34:14 +02:00
Julian Kent 6ce2769342 Pull out point-to-line distance calc, getting local mission coords 2020-07-14 11:34:14 +02:00
Julian Kent ff4be5d815 Set rate when subscribing to velocity, specify units 2020-07-14 11:34:14 +02:00
Julian Kent e6c5771c59 Add 'corridor check' which makes sure 3D tracking is along mission 2020-07-14 11:34:14 +02:00
Julian Kent db361d7a59 Add straight-line MAVSDK test 2020-07-14 11:34:14 +02:00
Matthias Grob 624d8a58e9 FlightTaskOrbit: correct acceleration feed-forward
The acceleration setpoint gets implicitly inherited from the altitude
flight task since #14212. This feed-forward adds an unwanted
acceleration when the right stick is deflected. Instead I'm using it
to command the expected centripetal acceleration when flying
in a circle for better orbit tracking.
2020-07-14 09:02:38 +02:00
David Jablonski 589aff7e0d Orbit: Add RC controlled yaw mode
For the RC controlled yaw behaviour, we do a yaw setpoint according to
the stick expo. The uncontrolled yaw behaviour behaves undefined.
Switching between yaw behaviours makes the drone stand still for a
moment, which probably can be improved.
2020-07-13 20:26:13 +02:00
David Jablonski 21f2e9b654 Orbit: Adjust yaw setpoint on circle approach 2020-07-13 20:26:13 +02:00
David Jablonski 037c6f592f Orbit: add more yaw behaviours 2020-07-13 20:26:13 +02:00
Matthias Grob 40883a06cf Commader: save 53 unnecessary characters of output string 2020-07-13 10:34:17 -04:00
daniele f01195c13f make kill switch engaged a warning only if the vehicle is flying 2020-07-13 10:34:17 -04:00
daniele be043d24a0 commander: rephrase or change message importance for some errors/warnings that happen often 2020-07-13 10:34:17 -04:00
Oleg 0c376ed518 fix sed unknown option to s'
when building with windows toolchain from eclipse
2020-07-13 10:23:44 -04:00
Daniel Agar aec1b9243a systemcmds/tests: microbench hrt run both regular and atomic hrt_elapsed_time 2020-07-10 10:59:50 -04:00
Daniel Agar 6bdcca6a85 systemcmds/tests: add simple atomic microbenchmark 2020-07-10 10:59:50 -04:00
George Anderson 94326a29bb FW attitude control scaling fixes and cleanup (#15256)
* FW attitude control scaling fixes and cleanup

This commit aligns the scaling better with the derivations in
https://dev.px4.io/master/en/flight_stack/controller_diagrams.html#airspeed-scaling

Integrator terms now scale with IAS^2 (all three axes)

To match the roll and pitch controllers:
- Yaw integrator scale is now applied during accumulation, not to
  integral value (so now FW_YR_IMAX is respected more intuitively)
- Yaw FF term now scale with IAS instead of IAS^2

Also made a number of small changes to make the three files
  (roll, pitch, yaw) 3-way diffable to be clearer about what the
  differences among them are.

* Remove unused yaw coordination method

- "Coordination method" open vs. closed code removed, since closed
  is never used and not actually implemented.
- No change to behavior

* Remove PX4_WARN messages

Co-authored-by: george <george@campsix.com>
2020-07-10 15:54:39 +02:00
RomanBapst f792cc7b6b publish battery_dangerous message if battery level is dangerous
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-07-10 09:37:23 -04:00
Daniel Agar e2ad1bbc91 bmi055: accel periodically read temperature 2020-07-09 18:03:29 -04:00
JaeyoungLim fa0ca7e65c Update mavlink with cellular status message fixes
This Commit includes a update of the mavlink submodule

since the CELLULAR_STATUS message was updated, the necessary changes were done together
Add enums
2020-07-09 15:12:02 -04:00
Matthias Grob 480cd5ed4e mavsdk_tests: load all os environment variables for gazebo client
such that OpenGL options are also used for mavsdk_tests when the GUI
is enabled.
2020-07-09 16:43:34 +02:00
Silvan Fuhrer 57cbf212be PreFlightchecks: remove duplicated VTOL mode prearm check
This removes the check for the current position of the VTOL swtich, as arming is already prevented if in transition mode,
plus also if VTOL and in fixed-wing mode (unless CBRK_VTOL_ARMING is set).

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-07-09 10:41:43 -04:00
Roman Dvořák f70b3046e9 mavlink: publish RAW_RPM 2020-07-09 10:35:16 -04:00
Thomas Stauber 6d1ce57362 Add Land as Geofence Action 2020-07-09 10:32:10 -04:00
Daniel Agar f3d923f226 sensors: VehicleIMU improve scheduling
- schedule on interval multiple of sensor_gyro publications without increasing the configured integration rate
 - IMU_INTEG_RATE add enums to guide appropriate selection
 - add average calculation bounds to prevent incorrect calculation and force monitoring again if there are consecutive gaps in data
2020-07-09 10:29:04 -04:00
Daniel Agar fa8ba09f50 drivers/imu/bosch/bmi055: remove interrupt latch
- the latch would actually cause more problems if the backup schedule hit
 - this reduces the number of cycles where the FIFO is actually empty at max rate (when there's only 1 sample in the FIFO expected)
2020-07-09 10:15:33 -04:00
Daniel Agar 194029d010 drivers/imu: Invensense & Bosch remove transfer perf counters
- we already have nearly equivalent data in every sensor publication with the (publication) timestamp and timestamp_sample
2020-07-09 10:12:37 -04:00
Daniel Agar 6bc1af7680 sensors/vehicle_air_data: only publish primary if error free
- cleanup failover related messaging
 - store previous failover count to prevent unecessary checks
 - check for parameter update initially to minimize work after fetching
fresh sensor data
2020-07-09 10:11:23 -04:00
Daniel Agar 6d52772d30 sensors/vehicle_air_data: move to sensors namespace
- move params to end of class
2020-07-09 10:11:23 -04:00
Beat Küng 405cb5038d sdp3x: introduce State enum
to avoid blocking the work queue during configuring.
2020-07-08 11:43:21 -04:00
Beat Küng fc1be6e0b1 sdp3x: add '-k' option to keep retrying even if probing fails
we have a setup where the sensor is connected via magnets, so the system
could boot without sensor initially attached.
2020-07-08 11:43:21 -04:00
Beat Küng 3cc394e6c7 sdp3x: improve robustness, try to reconfigure on transfer error 2020-07-08 11:43:21 -04:00
Daniel Agar 38fa913fed Jenkins: holybro durandal-v1 switch to generic multicopter with dshot 2020-07-07 18:59:04 -04:00
Daniel Agar 8763d71bf0 Jenkins: set IMU_GYRO_RATEMAX to 4kHz on holybro_durandal-v1_default 2020-07-07 01:29:48 -04:00
Daniel Agar 2af72c05b5 Jenkins: set IMU_GYRO_RATEMAX to 2kHz on px4_fmu-v5_default 2020-07-06 22:17:17 -04:00
Daniel Agar 96a6b5c914 load_mon: decrease warning threshold for stack check builds
- enabling stack check increases stack usage and will assert if there's
any overflow
2020-07-06 11:13:15 -04:00
Daniel Agar 0f0706be91 platforms/nuttx: init.cmake skip config lines with empty values 2020-07-06 11:13:15 -04:00
Daniel Agar b277840233 boards: create px4_fmu-v5_debug build with assertions enabled 2020-07-06 11:13:15 -04:00
Beat Küng 2bcc2f4ccc mag params: add missing mag rotations according to rotation.h 2020-07-06 10:16:17 -04:00
Beat Küng 795b9e938e drivers: add ST LPS33HW baro driver
Note: only tested on I2C
2020-07-06 10:13:11 -04:00
Julian Oes aea94ff57b jMAVSim: try new libs with newer Java versions
This is an attempt to get jMAVSim to run with Java9+.
2020-07-06 13:07:11 +01:00
Beat Küng 03e51076b0 v5x: fix icm20602 sensor orientation
and reorder baro startup, so that the other one is used by default.
2020-07-06 11:02:48 +02:00
Matthias Grob 03735f12a2 FlightTask: correct activate() doxygen comment 2020-07-04 12:29:10 +02:00
Thomas Stauber 3702c8b481 [VTOL] impose minimum transition duration
* VT_F_TR_OL_TM would silently reduce VT_TRANS_MIN_TM when VT_F_TR_OL_TM was smaller
2020-07-03 13:19:02 -04:00
Stone White 400c44b5ef Raname DJI Airframe name to Provent Large PWM_MIN for normal ESCs 2020-07-03 09:08:22 +02:00
Daniel Agar d3157f4266 sensors/vehicle_acceleration: apply calibration before filtering 2020-07-02 12:35:17 -04:00
JaeyoungLim 692cb717b7 Add windy world target (#14737) 2020-07-02 15:49:09 +02:00
Claudio Micheli 743898d574 Commander: failure detector, automatically disarm on a ESC failure
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2020-07-01 08:55:54 +02:00
Claudio Micheli a7f2f2908b Commander: make optional tilt-check after takeoff (failure detector).
- Introduced COM_LKDOWN_TKO parameter
    - Introduced auto disarm for lockdown state
    - Do not trigger flight termiantion if system is in lockdown

Signed-off-by: Claudio Micheli <claudio@auterion.com>
2020-07-01 08:55:54 +02:00
Claudio Micheli 6358dd400a failure detector: added esc failures detection
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2020-07-01 08:55:54 +02:00
Daniel Agar 7398d174d2 Update submodule sitl_gazebo to latest Tue Jun 30 14:39:57 UTC 2020 (#15248)
- sitl_gazebo in PX4/Firmware (38588f0c37): https://github.com/PX4/sitl_gazebo/commit/309f7b0ace2d6d0afea59fe5edf3356b26d996c9
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/1af7e29dbb1ecce7b0b191c9deb24ab1f13916ab
    - Changes: https://github.com/PX4/sitl_gazebo/compare/309f7b0ace2d6d0afea59fe5edf3356b26d996c9...1af7e29dbb1ecce7b0b191c9deb24ab1f13916ab

    1af7e29 2020-06-25 JaeyoungLim - Do not validate r1_rover
5e8ddfb 2020-06-25 Benjamin Perseghetti - fixes for R1 SDF https://github.com/PX4/sitl_gazebo/issues/533 (#534)
726c066 2020-06-23 Supakorn Suttiruang - Remove the incorrect force generated by moment (#532)

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-06-30 15:44:38 -04:00
Daniel Agar ff002f1fd7 Update submodule mavlink v2.0 to latest Tue Jun 30 14:40:02 UTC 2020
- mavlink v2.0 in PX4/Firmware (2be1588438e198b465ff5d320720d1fba3406588): https://github.com/mavlink/c_library_v2/commit/413964fb05c7f296542d8f87b05ea71cd9795fc7
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/bd80020a6ce7686922aac2b389767e23cf0605ac
    - Changes: https://github.com/mavlink/c_library_v2/compare/413964fb05c7f296542d8f87b05ea71cd9795fc7...bd80020a6ce7686922aac2b389767e23cf0605ac

    bd80020a 2020-06-29 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/527abe53c4c9bf6fe811d5f8b236d6ecc73ded67

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-06-30 15:44:27 -04:00
PX4 BuildBot 19d2de0726 Update submodule matrix to latest Tue Jun 30 14:40:13 UTC 2020
- matrix in PX4/Firmware (a1043f6ce068cc4d039d6808ef98fd8c3f379582): https://github.com/PX4/Matrix/commit/f529358e9ac28b0809572c14a964ba7ba691adc4
    - matrix current upstream: https://github.com/PX4/Matrix/commit/9a30828a0a1d79e87fd09653bb9f936d7ca0ba17
    - Changes: https://github.com/PX4/Matrix/compare/f529358e9ac28b0809572c14a964ba7ba691adc4...9a30828a0a1d79e87fd09653bb9f936d7ca0ba17

    9a30828 2020-06-30 Julian Kent - Add explicit matrix + scalar test
f3cf615 2020-06-30 Julian Kent - Do += -= and scalar *= /= in place
2020-06-30 11:11:45 -04:00
Daniel Agar e3eeb150b1 Jenkins: limit metadata generation to master 2020-06-30 11:05:22 -04:00
PX4 BuildBot 38588f0c37 Update submodule ecl to latest Tue Jun 30 00:38:47 UTC 2020
- ecl in PX4/Firmware (bd4d3f2b9929271b2616d2e1d6952059a7e8bc72): https://github.com/PX4/ecl/commit/e4b44f704bb641fa93bedc81734c5249fcd9ed42
    - ecl current upstream: https://github.com/PX4/ecl/commit/5356077a3244a9a29adfae4aeaaab900cd28e9e8
    - Changes: https://github.com/PX4/ecl/compare/e4b44f704bb641fa93bedc81734c5249fcd9ed42...5356077a3244a9a29adfae4aeaaab900cd28e9e8

    5356077 2020-06-21 kamilritz - Make flow_innov/-var a matrix Vector2f
c2801eb 2020-06-21 kamilritz - Add const modifier and increase matrix library usage
d9afc2f 2020-06-21 kamilritz - Remove repeated division by same value
d16b43a 2020-06-21 kamilritz - Get rid of non functional piece of code
c3653e6 2020-06-21 kamilritz - Add const modifier
48f0eb1 2020-06-21 kamilritz - Remove uninformative comments
4a69b41 2020-06-21 kamilritz - Increase matrix library usage even more
630be60 2020-06-21 kamilritz - Increase matrix library usage
22274b1 2020-06-21 kamilritz - Add const modifier
61c139e 2020-06-21 kamilritz - Remove unused variable
afd4f3f 2020-06-21 kamilritz - Fix typo
a3706fd 2020-06-21 kamilritz - Make relative wind computation more compact
b8f9376 2020-06-21 kamilritz - Make mag_innov/-var a Matrix::Vector3f
0ea7cd8 2020-06-25 Kamil Ritz - Attempt to fix CI firmware build test
2927132 2020-06-25 Daniel Agar - clang-format set BreakBeforeBraces to Linux style
b96c62e 2020-06-25 sevenbill - Optionalized build dependency on git
794e6ec 2020-06-25 Bill Morris - Enforce tabs via editorcofig
2020-06-29 21:50:55 -04:00
Matthias Grob 547bd4c667 ubuntu.sh: add fix for gazebo's OpenGL problem in VMs
That makes gazebo crash in VMWare 3D graphics accelration.
2020-06-29 19:21:56 -04:00
Matthias Grob 9fed9f534e ubuntu.sh: style, 20.04 comment and message wording 2020-06-29 19:21:56 -04:00
Matthias Grob c9b82ad184 ubuntu.sh: source .profile before checking for ARM GCC
to avoid downloading and installing ARM GCC again if the script is
reran immediately after e.g. because it failed the first time.
2020-06-29 19:21:56 -04:00
Matthias Grob c8d7027546 ubuntu.sh: don't upgrade pip outside of system package manager
This can lead to inconsistency with the installed package.
E.g. also if the package is remove the upgraded pip stays
but the symbolic links are gone.
2020-06-29 19:21:56 -04:00
Matthias Grob 47de2419a3 setup: don't require exact matplotlib version
Because this older version fails to install on Ubuntu 20.04
and makes the entire setup script fail.
2020-06-29 19:21:56 -04:00
TSC21 dc69d99764 add support to FastRTPS 2.0.0 (Fast-DDS) 2020-06-29 22:56:00 +02:00
dominiknatter d8831c5133 ekf2: Ignore optical flow samples with too large integration time spans. Fixes #14165
Within ekf2, optical flow messages (amongst others) are fused to the state estimates. It might occur that optical flow sensors report unreliable and unrealistic spikes. In that case, the state estimator went crazy so far and just ignored optical flow values from that moment on.

The common thread for all these spikes seems to be a too high integration time span. Therefore, this fix adds a simple logic that ignores unrealistically high integration time spans. As a threshold, 1 second was chosen.

Reported-by: Dominik Natter <dominik.natter@gmail.com>
2020-06-29 12:00:29 -04:00
Daniel Agar d360919789 Jenkins: hardware mRo Control Zero skip tests for now
- not quite ready for this one
2020-06-29 11:14:22 -04:00
Jari van Ewijk fe7fcb101f NXP FMUK66 - Fix VDD_3V3_SENSORS_EN polarity 2020-06-29 07:45:47 -07:00
Beat Küng 0c4fd2bfa0 param: also show unused params for 'param show -c'
I find this generally useful for debugging.
2020-06-29 09:49:56 -04:00
Beat Küng d22bbde7c5 logger: fix hardfault for invalid SDLOG_PROFILE setting
If some bits are set but no topic was added, _subscriptions was null but
later accessed.

During normal use this only happens when switching between different
firmware versions with different SDLOG_PROFILE definition (with custom
config).
2020-06-29 09:49:56 -04:00
Daniel Agar 1ea416f6de Github Actions MacOS skip SITL tests for now
- there's an intermittent crash when running these tests on Github Actions MacOS infrastructure (10.15)
 - see https://github.com/PX4/Firmware/issues/15225 for more detail
2020-06-28 20:52:50 -04:00
PX4 BuildBot b463a2f0d5 Update submodule matrix to latest Sun Jun 28 12:38:27 UTC 2020
- matrix in PX4/Firmware (2337b7e2f7b4eecddbb9103ab7672fac2c741fc5): https://github.com/PX4/Matrix/commit/674bd99f3b9284e1088d100d765b3a09cf0c192f
    - matrix current upstream: https://github.com/PX4/Matrix/commit/f529358e9ac28b0809572c14a964ba7ba691adc4
    - Changes: https://github.com/PX4/Matrix/compare/674bd99f3b9284e1088d100d765b3a09cf0c192f...f529358e9ac28b0809572c14a964ba7ba691adc4

    f529358 2020-06-27 kamilritz - Add missing const modifier
2020-06-28 19:55:06 -04:00
Daniel Agar e67fdb401c Update submodule mavlink v2.0 to latest Sun Jun 28 12:38:13 UTC 2020
- mavlink v2.0 in PX4/Firmware (51eaedeb72403a6915c64cce5bb824aaf6ffa13b): https://github.com/mavlink/c_library_v2/commit/be9923365f42dcece409de9467d263e56102e226
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/413964fb05c7f296542d8f87b05ea71cd9795fc7
    - Changes: https://github.com/mavlink/c_library_v2/compare/be9923365f42dcece409de9467d263e56102e226...413964fb05c7f296542d8f87b05ea71cd9795fc7

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-06-28 19:54:40 -04:00
bresch 1761ef3952 FlightTaskAuto: Update prev and next waypoint depending on validity
This fixes the corner case where a NAV_DELAY command changes the
validity of the next WP but not the rest of the triplet. The logic in
FlightTask was ignoring this change because the check was only based on
WP position change.
2020-06-26 09:48:22 -04:00
Benjamin Perseghetti 3302a6965d Add EOL for 1062 2020-06-25 12:59:10 -04:00
Benjamin Perseghetti eee82635be added EOL to mixer, changed tf-r1 to 1062 and to use properly named sitl mixer 2020-06-25 12:59:10 -04:00
Benjamin Perseghetti 165fdaa6c8 removed 1061 name collision, made rover mixing explicit to sitl 2020-06-25 12:59:10 -04:00
Benjamin Perseghetti e19ca62a0a fixes for R1 mixer https://github.com/PX4/sitl_gazebo/issues/533 2020-06-25 12:59:10 -04:00
RomanBapst 120f188ada rtl: do not use cone logic for vehicle flying as fixed wing
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-06-25 09:17:23 -04:00
Julian Oes 620916e4c1 mavsdk_tests: add test back in
This failed with other frames but seems to pass with iris and
standard_vtol.
2020-06-24 10:44:56 -04:00
Julian Oes 5e21eb3b78 mavsdk_test: remove flaky tests
Tests for both of these models did not pass for me locally. Therefore,
I'm removing them for now. It's up to the stakeholders of these models
to add them again.
2020-06-24 10:44:56 -04:00
Daniel Agar 55808ed2f9 simulator: break out standalone battery simulator module
- this is a small step towards unifying SITL & HITL
2020-06-24 10:39:21 -04:00
JaeyoungLim ae4ed87a31 Simplify getting sim PID
Follow up of https://github.com/PX4/Firmware/pull/15206#pullrequestreview-436356707
2020-06-24 10:13:37 +02:00
PX4 BuildBot 6dd0932158 Update submodule ecl to latest Wed Jun 24 00:39:40 UTC 2020
- ecl in PX4/Firmware (fff83fdee69789ec9da259b564bbfe67585a4b5f): https://github.com/PX4/ecl/commit/a8bb8ea99fc92389a5cdd44cd7108416e0c49fb6
    - ecl current upstream: https://github.com/PX4/ecl/commit/e4b44f704bb641fa93bedc81734c5249fcd9ed42
    - Changes: https://github.com/PX4/ecl/compare/a8bb8ea99fc92389a5cdd44cd7108416e0c49fb6...e4b44f704bb641fa93bedc81734c5249fcd9ed42

    e4b44f7 2020-06-23 PX4 BuildBot - Update geo_lookup WMM  to latest Tue Jun 23 14:15:04 UTC 2020
4b746a3 2020-06-23 bresch - GPS Yaw: add consts and remove fusion starting message
2bafe9d 2020-06-22 bresch - GPS Yaw: wait to fuse at yaw at least once before declaring it faulty
51cd63d 2020-06-22 bresch - GPS Yaw: fall back to other yaw aiding source in case of bad data
fe2a9d3 2020-06-22 bresch - GPS Yaw: move isfinite checks in control.cpp
3c6790f 2020-06-22 bresch - GPS Yaw: Always reset Yaw when GPS Yaw fusion is starting
ff8b5ec 2020-06-21 kamilritz - Extract general functions into utils
fda30d8 2020-06-15 Daniel Agar - geo_lookup: expand latitude to +-80 degrees
109eca5 2020-06-15 Daniel Agar - geo_lookup: create simple python script to update tables
41b9e4f 2020-06-15 Daniel Agar - geo_lookup: move tables to separate file
2020-06-24 08:29:20 +02:00
JaeyoungLim 3ef852c8e3 sitl: enable spawning different vehicle types for multivehicle SITL in gazebo (#15147)
This can be run with the command `Toos/gazebo_multiple_sitl_run.sh -s plane:3,iris:1
2020-06-24 08:23:16 +02:00
Daniel Agar 27cf3c7c75 Jenkins hardware add mRo Ctrl Zero F7 2020-06-23 23:40:43 -04:00
JaeyoungLim 481b23c811 Use SIM_PID for gzserver, not gzmodel 2020-06-23 22:44:16 +01:00
Daniel Agar c25b2e11fe Github Actions start migrating Jenkins metadata (airframe, parameter, etc) jobs 2020-06-23 13:41:57 -04:00
Daniel Agar e6f6d39198 Tools/setup: ubuntu updates to sync with px4io/px4-dev-base container 2020-06-23 12:53:34 -04:00
Beat Küng fe9a971f0e logger: use subscription interval also in polling mode
Now that replay uses lockstep scheduling we don't need that work-around
anymore.
2020-06-23 11:53:55 -04:00
Beat Küng a3d1c94aa4 logger: reduce poll timeout to 20ms
Just to ensure even if the topic is not updated, logger will still update
regularly.
2020-06-23 11:53:55 -04:00
Beat Küng 157ef43e28 replay: use lockstep scheduler 2020-06-23 11:53:55 -04:00
Beat Küng 71dcf8d619 sitl: use lockstep components API
- avoids the need for ekf2_timestamp publications by q and lpe
- adds logger to the lockstep cycle and makes it poll on ekf2_timestamps
  or vehicle_attitude. This avoids dropped samples (required for replay).
2020-06-23 11:53:55 -04:00
Beat Küng 5378d1468f lockstep_scheduler: add generic lockstep component API
allows components to register and ensure the lockstep cycle waits for
all components to be updated.
2020-06-23 11:53:55 -04:00
Beat Küng 55d06241b3 fix unit tests: do not stub pthread_cond_wait
and fix the tests instead.
Some unit tests depend on pthread_cond_wait to work as expected.
2020-06-23 11:53:55 -04:00
Beat Küng 283453b3a5 px4-alias.sh_in: allow for spaces in 'set' alias
Required for expressions like:
set LOGGER_ARGS "${LOGGER_ARGS} -f"
2020-06-23 11:53:55 -04:00
Daniel Agar e46d605a49 Jenkins drop cppcheck and clang analyzer
- these only run in master and the output isn't really visible/known
2020-06-23 11:53:04 -04:00
Daniel Agar 4b45b70e7a Github Actions remove MacOS homebrew cache
- it's large and takes as much time saving/restoring the cache as it saves
2020-06-23 10:48:22 -04:00
Daniel Agar 5951b79fc4 Update submodule mavlink v2.0 to latest Tue Jun 23 13:30:26 UTC 2020
- mavlink v2.0 in PX4/Firmware (0568be40b9f89ae0f09f001d2ee0441dbcd70b68): https://github.com/mavlink/c_library_v2/commit/8c6d26ee990b7837197091fa9e33cfeeb226136f
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/be9923365f42dcece409de9467d263e56102e226
    - Changes: https://github.com/mavlink/c_library_v2/compare/8c6d26ee990b7837197091fa9e33cfeeb226136f...be9923365f42dcece409de9467d263e56102e226
2020-06-23 10:35:44 -04:00
Daniel Agar 32887193d6 systemcmds/tests: remove autodeclination test (moving to PX4/ecl) 2020-06-23 10:34:25 -04:00
Beat Küng bb36b4a63f {dshot,pwm_out}: allow mode_pwm4 for boards with 5 outputs
Required on durandal if camera triggering is enabled.
2020-06-23 09:32:13 -04:00
David Sidrane df73662d66 nxp_fmuk66-v3:Add Full networking support 2020-06-22 18:43:03 -04:00
Daniel Agar 7404e886fe Github Actions MacOS add homebrew caching 2020-06-22 15:42:14 -04:00
Daniel Agar 033c5d0110 Github Actions add MacOS build and fix Tools/setup/OSX.sh
- Tools/setup/OSX.sh wasn't installing px4-dev on fresh run
2020-06-22 15:23:29 -04:00
Daniel Agar 3b4a3d7d03 Github Actions add unit test coverage 2020-06-22 15:05:36 -04:00
Daniel Agar e1161e3f6f Github Actions don't allow the ecl analsysi script to fail the build 2020-06-22 14:54:12 -04:00
Daniel Agar 1d43ca5bea Github Actions limit checks to Ubuntu 20.04 2020-06-22 14:15:44 -04:00
Daniel Agar 5cd8c26cae Github Actions remove redundant VTOL standard mission 2020-06-22 14:00:12 -04:00
Daniel Agar b15ea156c8 move clang-tidy from Jenkins to Github Actions 2020-06-22 13:37:38 -04:00
Mirko Denecke 147fb0afa4 Hex/Proficnc CubeOrange: fix default config for IMU heating 2020-06-22 13:12:08 -04:00
Mirko Denecke d9f813a443 Hex/Proficnc CubeYellow: fix default config for IMU heating 2020-06-22 13:12:08 -04:00
Daniel Agar 43fdc770c7 mavsdk_tests: temporarily disable offboard position control test 2020-06-22 13:04:39 -04:00
TSC21 bc2b118e48 mavsdk_tests: add iris_dual_gps tests 2020-06-22 12:46:40 -04:00
Matthias Grob e9eae1bd76 Refactor: Name manual_control_setpoint the same way everywhere 2020-06-22 12:06:27 -04:00
Daniel Agar c6dd8bfcd6 imu/invensense/icm20649: minor cleanup to keep in sync with icm20948 2020-06-22 10:11:22 -04:00
Daniel Agar 4bcee8e13f magnetometers/akm: new standalone AKM AK8963 & AK09916 drivers 2020-06-22 10:11:22 -04:00
Daniel Agar 8c34f47b3d imu/invensense/mpu9250: sync with other recent invensense improvements
- clenaup ak8963 with simplifed setup and health check
2020-06-22 10:11:22 -04:00
Daniel Agar 22daa26955 msgs/sensor_mag: remove unused raw, add timestamp_asmple, shrink error count
- move mpu9250 sensitivity handling back to driver (this isn't common)
2020-06-22 10:11:22 -04:00
Daniel Agar d9102ce54c imu/invensense/icm20948: sync with other recent invensense improvements
- clenaup ak09916 with simplifed setup and health check
2020-06-22 10:11:22 -04:00
Daniel Agar e50f92805b mavlink: mission minor whitespace fixes and initialization
- it's safer to zero any struct being send over mavlink to prevent
extension field surpries later
2020-06-21 11:26:02 -04:00
Daniel Agar 80c1f4e5e6 mavlink: send MISSION_CURRENT respect signed sequence number
- current_seq -1 indicates nothing currently active
2020-06-21 11:26:02 -04:00
JaeyoungLim d677b9460b Update sitl_gazebo 2020-06-21 11:31:03 +01:00
JaeyoungLim f54f03bd9d Add plane_catapult to matrix 2020-06-21 11:10:33 +01:00
JaeyoungLim 82a6047506 Update sitl_gazebo 2020-06-21 11:10:33 +01:00
JaeyoungLim 59c70a5811 Add plane_catapult test for testing hand/catapult launch for fw
This adds the plane_catapult model to the test for testing fw hand /catapult takeoff
2020-06-21 11:10:33 +01:00
Daniel Agar 3e95b28222 github actions don't allow bloaty output to fail compile job
The bloaty output is for monitoring and review, but shouldn't be allowed to fail the overall compile job if something goes wrong.
2020-06-21 01:22:21 -04:00
Daniel Agar b8d43b5a88 move Jenkins MAVROS SITL tests entirely to Github Actions 2020-06-21 00:01:35 -04:00
Daniel Agar c7e8957f2e Jenkins delete obsolete configurations 2020-06-20 22:17:16 -04:00
Daniel Agar 763a885dfe Jenkinsfile merge remaining 1st & 2nd stages 2020-06-20 21:07:34 -04:00
Daniel Agar b6292a1a2d posix rcS fix shellcheck SC2236 2020-06-20 20:42:09 -04:00
Daniel Agar 32c2064673 migrate Jenkinsfile checks to Github Actions 2020-06-20 20:42:09 -04:00
Daniel Agar 0daf712c3e SITL MAVROS tests move AddressSanitizer and Coverage variants to Github Actions 2020-06-20 20:00:03 -04:00
Daniel Agar c1fc638ac3 github actions use build type for ccache key and fix coverage check 2020-06-20 19:17:13 -04:00
Daniel Agar 34864cc704 github actions build and run emlid navio2 on hardware 2020-06-20 19:03:15 -04:00
Daniel Agar d927d80509 Jenkins hardware ignore nxp_fmuk66-v3 status failures
- this particular hardware on the test rack has a flaky console
2020-06-20 18:53:10 -04:00
Daniel Agar 5616914e75 start migrating MAVROS SITL tests to Github Actions 2020-06-20 18:25:24 -04:00
Daniel Agar 3092d9e1f9 github actions run SITL tests in parallel
- temporarily disable iris dual gps
2020-06-20 17:44:57 -04:00
Daniel Agar 37817dd0af github actions build and run tests as separate steps 2020-06-20 17:44:57 -04:00
Daniel Agar e0ce12ad27 github actions limit SITL tests to Ubuntu Focal 2020-06-20 17:44:57 -04:00
TSC21 6c558260e9 update submodule Tools/sitl_gazebo 2020-06-20 22:37:33 +01:00
TSC21 b3bbc351ca mavlink: DISTANCE_SENSOR: propagate signal_quality metric 2020-06-20 22:25:37 +01:00
Daniel Agar d34b5f86cc Jenkins compile keep in sync with Github Actions NuttX build
- jenkins is still responsible for master/beta/stable S3 uploads
2020-06-20 14:22:54 -04:00
Daniel Agar 19a125dacb github actions cleanup
- merge bloaty into regular NuttX builds
 - give SITL unique cache key
2020-06-20 14:19:12 -04:00
Daniel Agar 745e72e18d github actions delete "C/C++ CI"
- this was the original github actions test build that's been superseded by many others
2020-06-20 14:05:07 -04:00
Daniel Agar 3fd07cb1d5 delete circleci simple build example
- github actions is an easier replacement
2020-06-20 14:05:07 -04:00
Daniel Agar 7016660445 github actions update actions/cache@v1.1.0 -> actions/cache@v2 2020-06-20 13:31:57 -04:00
Daniel Agar 652036e29f github actions SITL tests upload logs to flight review on failure 2020-06-20 13:22:57 -04:00
Daniel Agar 32828c99fd github actions get ccache working 2020-06-20 13:18:06 -04:00
David Sidrane a641982ce7 Makefile:Create check_{px4,nxp,nuttx,linux} targets from .github/workflows
Apply the principles of third normal form for check targets.
   The list of check is not sourced from the yaml files in
   .github/workflows
2020-06-20 11:24:39 -04:00
PX4 BuildBot 76d3e2374b Update submodule v2.0 to latest Sat Jun 20 00:38:42 UTC 2020
- v2.0 in PX4/Firmware (657b674b96200f5c306fed684bef8621c5e0c853): https://github.com/mavlink/c_library_v2/commit/205ffa4132107b728d62e101c05249895339a572
    - v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/8c6d26ee990b7837197091fa9e33cfeeb226136f
    - Changes: https://github.com/mavlink/c_library_v2/compare/205ffa4132107b728d62e101c05249895339a572...8c6d26ee990b7837197091fa9e33cfeeb226136f

    8c6d26ee 2020-06-19 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/62a73ec05bed94ab5726ea93bd98abb41bee2204
2020-06-20 12:35:00 +01:00
Lum f3e5a42ccd Remove mixer for virtual elevator and add pitch control mixer to elevons 2020-06-20 12:17:54 +01:00
David Sidrane 28a695dce4 px4_fmu-v6x:imu/bmi088->imu/bosch/bmi088 2020-06-19 19:13:20 -04:00
David Sidrane 07accb8403 Added px4_fmuv6x to .github workflows 2020-06-19 19:13:20 -04:00
Daniel Agar 6dad4a3359 SITL VTOL tiltrotor disable airspeed 2020-06-18 22:25:35 -04:00
Daniel Agar b1e360e332 simulator: only use temperature if baro updated 2020-06-18 21:34:58 -04:00
PX4 BuildBot 0d68e1316e Update submodule sitl_gazebo to latest Fri Jun 19 00:38:14 UTC 2020
- sitl_gazebo in PX4/Firmware (6b343c1f5e): https://github.com/PX4/sitl_gazebo/commit/97106007eb5c934b902a5329afb55b45e94d5063
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/846190e8a33063a62997f2ad18c9de5c5233d9f9
    - Changes: https://github.com/PX4/sitl_gazebo/compare/97106007eb5c934b902a5329afb55b45e94d5063...846190e8a33063a62997f2ad18c9de5c5233d9f9

    846190e 2020-06-18 Daniel Agar - cmake set build type and C/C++ standard
1cd16d7 2020-06-18 JaeyoungLim - Set GPS utc time to use utc time (#522)
2020-06-18 21:01:48 -04:00
Daniel Agar 9cd1f27fb5 Update submodule mavlink v2.0 to latest Fri Jun 19 00:38:19 UTC 2020
- mavlink v2.0 in PX4/Firmware (e975515ddeec2aef87185dfcd2fb118f10b9695f): https://github.com/mavlink/c_library_v2/commit/f69d7331cae381b8886ec070abccb53d76d30173
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/205ffa4132107b728d62e101c05249895339a572
    - Changes: https://github.com/mavlink/c_library_v2/compare/f69d7331cae381b8886ec070abccb53d76d30173...205ffa4132107b728d62e101c05249895339a572
2020-06-18 20:51:06 -04:00
Daniel Agar 3f19335f08 drivers/imu/invensense: FIFO_MAX_SAMPLES include sensor_accel_fifo in sample size limit 2020-06-18 20:49:15 -04:00
Daniel Agar 0eea814ca1 decrease all wq:SPIx stack 2020-06-18 20:49:15 -04:00
Daniel Agar 56c86e77bd replace FIFOSample -> sensor_accel_fifo/sensor_gyro_fifo 2020-06-18 20:49:15 -04:00
Daniel Agar 6b343c1f5e cmake: sitl_gazebo build limit to 2 cores (-j2) 2020-06-18 20:10:25 -04:00
Daniel Agar 87250ca47f move ecl L1, TECS, and data validator to PX4/Firmware 2020-06-18 19:26:30 -04:00
JacobCrabill 78650bdbab UAVCAN: Fix STM32H7 message RAM for FDCAN2 2020-06-18 18:55:21 -04:00
JacobCrabill 62799d9aca UAVCAN: Add STM32H7 FDCAN Driver
Took the existing uavcan_stm32 driver and replaced all bxCAN code with
the equivalent for FDCAN following ST Reference Manual RM0433.

Note: There is still a bug somewhere in regards to FDCAN2 (probably
incorrect setup of the message RAM? Not sure.)  But (FD)CAN1 is fully
functional (Classic CAN only, no CAN-FD).

Also TODO: Configure CAN filters.  Right now there are no filters; all
incoming messages are accepted.
2020-06-18 18:55:21 -04:00
JacobCrabill 08d2226043 CubeOrange: Move console back to CONS (UART7) 2020-06-18 18:55:21 -04:00
Daniel Agar 0a63df25a6 create fake_magnetometer "driver" to publish magnetic field in body frame
- this can be helpful for orienting new unknown magnetometers
 - requires attitude and GPS position
2020-06-18 16:21:30 -04:00
Daniel Agar 6afa7e4368 mavlink: HIL_SENSOR receiver respect fields_updated
- keep in sync with the simulator module
2020-06-18 09:54:00 -04:00
Daniel Agar be2081a2a2 wq:attitude_ctrl small stack increase 2020-06-18 01:36:29 -04:00
Daniel Agar f55ed0992c accel and gyro calibration refactor and cleanup
- remove all remaining IOCTLs for accel and gyro and handle all calibration entirely in sensors module with parameters
 - sensor_accel and sensor_gyro are now always raw sensor data
 - calibration procedures no longer need to first clear existing values before starting
 - temperature calibration (TC) remove all scale (SCL) parameters
    - gyro and baro scale are completely unused
    - regular accel calibration scale can be used (CAL_ACC*_xSCALE) instead of TC scale
2020-06-17 22:50:09 -04:00
Matthias Grob 588d551098 mc_pos_control_params: set the ground slow down speed to the default maximum speed
This results in no change with defaults but a slow down to 10m/s if the maxiumum speed is set higher than that.
2020-06-17 11:47:41 -04:00
Matthias Grob bcd771d832 Update ecl and adapt to new AlphaFilter location 2020-06-17 09:29:35 -04:00
hanyang2013212 4209101333 Update uuv_att_control.cpp
Modified the thruster value to be accessed from attitude setpoint message instead of parameters
2020-06-16 19:27:54 -04:00
TSC21 24ae8f601d mavsdk_tests: add iris_dual_gps to the test pipeline 2020-06-16 13:03:44 +01:00
TSC21 28c4446eae init.d-posix: if750a: add GPS blending 2020-06-16 09:57:05 +01:00
TSC21 6add0fff7f add iris_dual_gps config and the possibility of testing GPS blending through simulation 2020-06-16 09:57:05 +01:00
JaeyoungLim 39b803a9dc Remove gps noise multiplier parameter (#15108)
This removes the gps noise multiplier parameter that can be set on the firmware side
2020-06-15 22:32:32 +02:00
Daniel Agar 6c78c62d9d BMI088: accel get max rate from PX4Accelerometer 2020-06-15 10:19:14 -04:00
Daniel Agar e819f99064 new Bosch BMI055 IMU driver using FIFOs and DRDY
- accel & gyro FIFOs enabled
 - FIFO watermark on data ready interrupt
 - sensor side filtering completely disabled
 - gyro now respects `IMU_GYRO_RATEMAX` (up to 2 kHz)
 - saves a few % cpu (at default rate)
2020-06-15 10:19:14 -04:00
Daniel Agar daf75e40eb drivers/imu/invensense: simplify gyro range configuration 2020-06-15 09:36:21 -04:00
Matthias Grob 1efc8c27eb FlightTaskAuto: check yawspeed saturation before constraining
to avoid possible numerical float equality issues.
2020-06-15 10:40:48 +02:00
bresch 12449c23c5 FlightTaskAuto: add missing wrap_pi and do not override yaw_sp_aligned 2020-06-15 10:40:48 +02:00
bresch 7a401e5ca3 FlightTaskAuto: Create artificial yaw speed sp for feedforward 2020-06-15 10:40:48 +02:00
Matthias Grob c165327c9f INA226: revise read() and collect() error handling
to allow negative currents and simplify unnecessary redundancy.
2020-06-15 10:26:10 +02:00
Matthias Grob da9feeb699 INA226: refactor spacing and return codes 2020-06-15 10:26:10 +02:00
dino d98cf2f719 Fixe for wrong perf counter increment in ina226 driver 2020-06-15 10:26:10 +02:00
Jonathan Hahn e6bec31890 add GNU screen to NUTTX dependencies in ubuntu setup 2020-06-15 10:16:08 +02:00
JaeyoungLim 58ca389634 Fix tiltrotor range to use normalized actuator inputs in SITL (#14751)
This adds fixes to use the normalized actuator setpoints for simulating tiltrotor in sitl
2020-06-15 08:51:26 +02:00
PX4 BuildBot eee87cd605 Update submodule ecl to latest Mon Jun 15 00:38:18 UTC 2020
- ecl in PX4/Firmware (adc733932566f0198a8892c3cebe9e5c8345e391): https://github.com/PX4/ecl/commit/38cbd1a18211f1702b403915ab37d5e22626432f
    - ecl current upstream: https://github.com/PX4/ecl/commit/e835bc34c4c84b526941db418f5c9d00d35cbe12
    - Changes: https://github.com/PX4/ecl/compare/38cbd1a18211f1702b403915ab37d5e22626432f...e835bc34c4c84b526941db418f5c9d00d35cbe12

    e835bc3 2020-06-06 Kamil Ritz - remove inline modifier
74780aa 2020-06-06 Kamil Ritz - Refactor gps fusion commencing
2020-06-14 22:14:14 -04:00
PX4 BuildBot f89dac03f3 Update submodule matrix to latest Sun Jun 14 12:39:39 UTC 2020
- matrix in PX4/Firmware (18f14ebefad29873ddeef6396c7c3a728c90b996): https://github.com/PX4/Matrix/commit/2bee0d078cb6b0e6205d17145899ccbb15dbe380
    - matrix current upstream: https://github.com/PX4/Matrix/commit/674bd99f3b9284e1088d100d765b3a09cf0c192f
    - Changes: https://github.com/PX4/Matrix/compare/2bee0d078cb6b0e6205d17145899ccbb15dbe380...674bd99f3b9284e1088d100d765b3a09cf0c192f

    674bd99 2020-06-11 kamilritz - Add operator* and operator/ for slice with type
38b3acc 2020-06-11 Nicolas MARTIN - fix conjugate_inversed comment
2020-06-14 11:18:00 -04:00
CUAVcaijie 1c02c37955 boards/cuav/x7pro: RC03 RM3100 moved from SPI1 to SPI2 2020-06-11 21:38:55 -04:00
CUAVcaijie dee56e78aa boards/cuav/x7pro: fix X7 LED SAFETY configuration
* keep the naming identical to the pinout
2020-06-11 21:32:53 -04:00
Beat Küng ab060cdab0 bmi088 accel: use IMU_GYRO_RATEMAX to configure sampling rate (with 800 max)
Primarily for logging the fifo topic @400 Hz.
2020-06-11 12:25:13 -04:00
Beat Küng 16323256bc gyro calibration: add median filter to motion detection
The bmi088 has a bit more noise and tends to trigger it.
This improves reobustness against noise, and increases the threshold
slightly.
2020-06-11 12:25:13 -04:00
Daniel Agar 13e34b32e6 new Bosch BMI088 IMU driver using FIFOs and DRDY 2020-06-11 12:25:13 -04:00
CUAVcaijie b6ec00c079 boards/cuav/x7pro: Fix HIPOWER enabled state 2020-06-11 12:05:37 -04:00
CUAVcaijie 9270b26c63 IO's RGB status light is modified to PWM breathing light 2020-06-11 12:02:49 -04:00
CUAVcaijie 67554acf9e x7 add led_pwm driver 2020-06-11 12:02:49 -04:00
CUAVcaijie 8aed6b2240 STM32H7 adds led_pwm driver 2020-06-11 12:02:49 -04:00
Julian Oes be4e253e63 mavsdk_tests: bump library from v0.24.0 to v0.27.0 2020-06-11 15:18:57 +02:00
Ricardo Marques a4927606ed Fix SENS_EN_SF1XX max value
Signed-off-by: Ricardo Marques <marques.ricardo17@gmail.com>
2020-06-10 14:37:23 -04:00
Matthias Grob 7ff25373e4 powerCheck: add power redundancy check
A parameter spcifies what the redundancy level for 5V rail supply
needs to be and a check makes sure that it's available before
taking off such that the user is aware of a broken or disconnected
redundant power module.
2020-06-10 10:13:51 -04:00
CUAVcaijie 37fb4dbb64 Enable safety button 2020-06-10 09:14:25 -04:00
Mirko Denecke 10afcdce2e Hex/Proficnc Cube Yellow: align firmware location in flash memory to be able to use the default bootloader 2020-06-10 09:08:11 -04:00
Daniel Agar 6f6efd60b7 boards: centralize optional external I2C sensor start
- configured with new parameter SENS_EXT_I2C_PRB
2020-06-10 09:04:13 -04:00
PX4 BuildBot 13d983d305 Update submodule ecl to latest Tue Jun 9 20:35:44 UTC 2020
- ecl in PX4/Firmware (af11fa456d7282e324d662a452c71ae85ee59d9b): https://github.com/PX4/ecl/commit/b3dc06d0cb572931000705ac04807eeae5e2401a
    - ecl current upstream: https://github.com/PX4/ecl/commit/38cbd1a18211f1702b403915ab37d5e22626432f
    - Changes: https://github.com/PX4/ecl/compare/b3dc06d0cb572931000705ac04807eeae5e2401a...38cbd1a18211f1702b403915ab37d5e22626432f

    38cbd1a 2020-06-09 Matthias Grob - AlphaFilter: prevent setParameters division by zero
b7d54b5 2020-06-04 RomanBapst - gps: fixed filter initialization bug around gps - do not gps reference altitude to zero in case gps checks pass before the filter initialized - reset the filtered gps position and position derivative filters in case we are in air or there is movement on the ground
8f533cb 2020-06-03 bresch - terrain_estimator: fix sensor aid selection
821e1fa 2020-06-03 bresch - terrain_estimator: add unit tests
aa96fa6 2020-06-03 bresch - Random style fixes in the code
5d6a72e 2020-06-03 bresch - sensor_simulator: add possibility to set GPS position rate
2020-06-09 17:21:49 -04:00
PX4 BuildBot 3f995efae9 Update submodule sitl_gazebo to latest Tue Jun 9 20:35:27 UTC 2020
- sitl_gazebo in PX4/Firmware (0fcb873636): https://github.com/PX4/sitl_gazebo/commit/3ba325b00f5e9c7a0645c6af3937f394dc806c9f
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/e2bf962b5e46b89093696338794a201c7fc990ba
    - Changes: https://github.com/PX4/sitl_gazebo/compare/3ba325b00f5e9c7a0645c6af3937f394dc806c9f...e2bf962b5e46b89093696338794a201c7fc990ba

    e2bf962 2020-06-08 JaeyoungLim - Fix typhoon h480 internals (#512)
2020-06-09 17:21:17 -04:00
Daniel Agar b8dda62b4d Update submodule mavlink v2.0 to latest Tue Jun 9 20:35:34 UTC 2020
- mavlink v2.0 in PX4/Firmware (febd2d855e4e25e38ff9222ccca7134f612ecb23): https://github.com/mavlink/c_library_v2/commit/5f1d5d8338ff15108bd11137fc6970282f369246
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/f69d7331cae381b8886ec070abccb53d76d30173
    - Changes: https://github.com/mavlink/c_library_v2/compare/5f1d5d8338ff15108bd11137fc6970282f369246...f69d7331cae381b8886ec070abccb53d76d30173
2020-06-09 17:20:56 -04:00
Beat Küng 0fcb873636 logger: add raw FIFO high-rate IMU logging profiles
Minimum requirement to use: set IMU_GYRO_RATEMAX to 400.

Logging rate of a single topic: ~85 KB/s. If multiple should be logged,
a really good SD card has to be used.
2020-06-09 09:58:15 -04:00
Beat Küng 590b65ebfb Revert "kakutef7 spi: disable IMU drdy"
This reverts commit 2069576a6e.

PR #15004 fixed the problem.
2020-06-09 09:11:51 -04:00
David Sidrane 82b87adfb3 px4_fmu-v6x:default phy is LAN8742 2020-06-09 08:14:22 +02:00
David Sidrane bcc505db3c Jenkinsfile-compile Change name to px4_fmu-v5x_p2_base_phy_LAN8742Ai 2020-06-09 08:12:44 +02:00
David Sidrane 4e014a0aed github:workflows Change name to px4_fmu-v5x_p2_base_phy_LAN8742Ai 2020-06-09 08:12:44 +02:00
David Sidrane 0bb8d7a065 px4_fmu-v5x p4 (-06) default to suporting LAN8742Ai 2020-06-09 08:12:44 +02:00
Daniel Agar 5e7d2e830d boards: delete old board.h boilerplate 2020-06-08 19:10:33 -04:00
Daniel Agar a83e75ee10 ROMFS: microsd prevent MacOS and Ubuntu trash and indexing files 2020-06-08 16:57:28 -04:00
Daniel Agar 5507c15bdc boards: move rgbled_pwm startup to appropriate boards 2020-06-08 16:49:46 -04:00
Mirko Denecke cf02b88d51 Initial Hex/Proficnc Cube Yellow support 2020-06-08 08:22:40 -04:00
PX4 BuildBot ee32ded222 Update submodule sitl_gazebo to latest Mon Jun 8 00:39:29 UTC 2020
- sitl_gazebo in PX4/Firmware (39a33a35ae): https://github.com/PX4/sitl_gazebo/commit/20e8dbe115028721b1918069dc7afd9145c7483c
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/3ba325b00f5e9c7a0645c6af3937f394dc806c9f
    - Changes: https://github.com/PX4/sitl_gazebo/compare/20e8dbe115028721b1918069dc7afd9145c7483c...3ba325b00f5e9c7a0645c6af3937f394dc806c9f

    3ba325b 2020-06-03 Julian Oes - geotagged_images: actually report number of images
92453d1 2020-05-21 JaeyoungLim - Cleanup
9aef888 2020-05-21 JaeyoungLim - Translate yaw to point at the right direction
2020-06-08 08:19:56 -04:00
Matthias Grob c36c8d161c MulticopterLandDetector: remove arbitrary maximum altitude based on battery percentage 2020-06-08 10:41:19 +02:00
Daniel Agar 39a33a35ae sensors/vehicle_imu: pause computing publication update rate 2020-06-07 11:23:22 -04:00
Daniel Agar 786733cd1a sensors/vehicle_imu: only publish status at 10 Hz (or on change) 2020-06-07 11:23:22 -04:00
Daniel Agar 8890ea23b7 sensors/vehicle_imu: only apply corrections once before publication 2020-06-07 11:23:22 -04:00
RomanBapst af5c48b869 navigator: always make sure that we set target lat/lon for fixed wing
takeoff

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-06-05 21:52:12 -04:00
Daniel Agar 5286ed3a11 imu/invensense/mpu6000: minor improvements
- at start perform full sensor signal path reset and wait for max time
 - issue full sensor reset on any error
 - only allocate DRDY perf counter if GPIO is available
 - allow running faster than accel ODR (safe limit of 2 kHz in place)
2020-06-05 21:28:37 -04:00
Daniel Agar 01f4486b32 imu/invensense/icm20689: minor improvements and potential fixes
- perform full sensor signal path reset and wait for max time (100 ms)
 - issue full sensor reset on any error
 - always read FIFO count before transfersj
 - only allocate drdy perf counter if GPIO is available
2020-06-05 21:28:37 -04:00
Daniel Agar ff3b040d3c imu/invensense/icm20608g: minor improvements and potential fixes
- perform full sensor signal path reset and wait for max time (100 ms)
 - issue full sensor reset on any error
 - always read FIFO count before transfersj
 - only allocate drdy perf counter if GPIO is available
2020-06-05 21:28:37 -04:00
David Sidrane 626895eadc px4_fmu-v5x:Wrong Bit was being tested for mode.
@TSC21  - this will fix you build
2020-06-05 18:59:48 -04:00
Matthias Grob b607630ee7 battery_params: relax maximum for capacity thresholds 2020-06-05 09:55:24 -04:00
Daniel Agar a1b0634258 Jenkins HIL test fix sensor timeouts
- stop logger when running tests
 - decrease test priorities
 - hrt test don't flush output
2020-06-04 22:09:07 -04:00
PX4 BuildBot b5a5e8e45b Update submodule ecl to latest Fri Jun 5 00:39:52 UTC 2020
- ecl in PX4/Firmware (d4fcf77c546c31c4c0b813e5034c66581b3b2877): https://github.com/PX4/ecl/commit/c91c78dcf67dee85225ada6621b6fd19ec008fd5
    - ecl current upstream: https://github.com/PX4/ecl/commit/b3dc06d0cb572931000705ac04807eeae5e2401a
    - Changes: https://github.com/PX4/ecl/compare/c91c78dcf67dee85225ada6621b6fd19ec008fd5...b3dc06d0cb572931000705ac04807eeae5e2401a

    b3dc06d 2020-05-25 Roman Bapst - Added height above ground source bitmask indicating which sensor is used
62e15cb 2020-06-03 bresch - sensor_simulator: set IMU rate to 200Hz as this is the new value used in the Firmware
6126c19 2020-06-03 bresch - sensor_simulator: update EKF at IMU rate
59183f7 2020-06-02 Paul Riseborough - EKF: Reduce EKF-GSF vulnerability to large yaw gyro bias errors (#831)
d0ddda8 2020-05-29 Matthias Grob - tecs: fix typo init(i)alized
86fc94b 2020-05-24 Kamil Ritz - Remove tilt align from position innovation check
b024cdd 2020-05-25 Mathieu Bresciani - unit test: check that the accel bias is only learned when observable (#827)
2020-06-04 21:15:59 -04:00
Daniel Agar 31fe7af454 selectively increase optimization -Os -> -O2
- targetted at modules/libraries that benefit without drastically
increasing flash usage
 - ignored on boards with CONSTRAINED_FLASH set
2020-06-04 20:59:52 -04:00
Beat Küng 7f73b9a131 kopis2: update tuning and filter parameters 2020-06-04 20:58:40 -04:00
Beat Küng fa567e93d8 4050_generic_250: update default filter parameters
A racer should have have to use a filter of 30Hz.
2020-06-04 20:58:40 -04:00
Beat Küng 32642b78bf gyro filtering: apply IMU_GYRO_CUTOFF also to D-term
Greatly improves the noise on the d-term on a Kopis 2. Apparently the order
of filtering vs differentiating matters.

Also disables the DGYRO filter by default, as the D-term now already has
a default filter of 30Hz applied.
2020-06-04 20:58:40 -04:00
Beat Küng 2069576a6e kakutef7 spi: disable IMU drdy
It cause bad transfers on a Kopis 2, though not on a bench KakuteF7 unit.
Not sure if this is a single case.

nsh> icm20689 status
INFO  [SPI_I2C] Running on SPI Bus 4
INFO  [icm20689] FIFO empty interval: 1000 us (1000.000 Hz)
icm20689: transfer: 46375 events, 6790549us elapsed, 146.43us avg, min 54us max 1709us 81.564us rms
icm20689: bad register: 0 events
icm20689: bad transfer: 4284 events
icm20689: FIFO empty: 0 events
icm20689: FIFO overflow: 1 events
icm20689: FIFO reset: 2 events
icm20689: DRDY interval: 375585 events, 124.93us avg, min 99us max 250us 2.322us rms
INFO  [drivers_accelerometer] /dev/accel device instance: 0
INFO  [drivers_accelerometer] calibration scale: 1.02174 0.99918 0.98338
INFO  [drivers_accelerometer] calibration offset: 0.76124 -0.00725 -0.16437
INFO  [drivers_gyroscope] /dev/gyro device instance: 0
INFO  [drivers_gyroscope] calibration offset: -0.08153 0.02432 0.00050
2020-06-04 20:58:40 -04:00
Beat Küng 5ce006dd8b SYS_HITL: reserve value -1 for external HITL 2020-06-04 20:58:40 -04:00
Beat Küng 867453eada posix rcS: always set IMU_INTEG_RATE
If this is wrong, the startup just hangs.
2020-06-04 20:58:40 -04:00
Daniel Agar d1c12ac7cf boards: mRo Control Zero fix IMU rotations 2020-06-04 11:34:31 -04:00
Mirko Denecke 4a637a5c54 Hex CubeOrange: enable DMA for SPI1 2020-06-04 10:25:52 -04:00
Mirko Denecke 61a2dd8ec6 Hex CubeOrange: limit slew rate so IMU works with DMA 2020-06-04 10:25:52 -04:00
Daniel Agar f6aa29a10f Jenkins: SITL temporarily disable failing offboard tests 2020-06-03 21:59:31 -04:00
Daniel Agar 8eecaf5cfb Jenkins temporarily disable Catkin and Colcon builds 2020-06-03 21:37:59 -04:00
Mirko Denecke b4e39f91a4 Hex CubeOrange: no LSE available 2020-06-03 21:09:50 -04:00
Mirko Denecke 3e4179cc88 Hex CubeOrange: fix comment calc of PLL 2020-06-03 21:09:50 -04:00
David Sidrane 920355e851 bmi088 remove dump of registers that causes driver to fail 2020-06-03 21:09:08 -04:00
David Sidrane 29d4d7c9fe Update NuttX with stm32h7 sdmmc backport 2020-06-03 12:51:25 -04:00
Julian Oes c37ba26a2f mavlink: remove outdated comment 2020-06-03 17:57:12 +02:00
Julian Oes 2c5b8a9491 mavlink: handle stream not updated
Our answer does not just depend on whether the stream was found but
whether we actually were able to send out an update.
2020-06-03 17:57:12 +02:00
Julian Oes efb10a2fbc mavlink: address review comments 2020-06-03 17:57:12 +02:00
Julian Oes 7d1b451e39 mavlink: add missing copyright header, pragma once 2020-06-03 17:57:12 +02:00
Julian Oes afafc541d8 mavlink: use send() instead of using reset flag
I think we can just directly use send() and don't need to use the
workaround of resetting the send flag to trigger one send.

Also, we don't need to override it if we don't need to check any params.
2020-06-03 17:57:12 +02:00
Julian Oes b54c44bd37 mavlink: don't send streams with interval 0
We only need to send them immediately if the interval is < 0 meaning
unlimited.
2020-06-03 17:57:12 +02:00
Julian Oes 3815e608f4 mavlink: create stream if needed and trigger once
Instead of creating the stream and deleting it again, we now create it
with a rate of 0 and trigger it once.

This should avoid heap fragmentation by continous allocations.
2020-06-03 17:57:12 +02:00
Julian Oes acdc15e2cd mavlink: create stream even if rate is 0
This allows to send a message exactly once if requested.
2020-06-03 17:57:12 +02:00
Julian Oes bb032a9c46 mavlink: remove incorrect outdated comment
Default is -2, so the comments seems wrong.
2020-06-03 17:57:12 +02:00
Julian Oes 80f91b0f6a mavlink: add support for legacy requests back in 2020-06-03 17:57:12 +02:00
Julian Oes b4cbd93b7c mavlink: new args to request message, omit param1
We can omit param1 because it is already used for the message_id, so
it's basically duplicate information and won't get used anywhere.
2020-06-03 17:57:12 +02:00
Julian Oes 27b6c209e0 mavlink: Move request message logic to function 2020-06-03 17:57:12 +02:00
David Jablonski 62bf0a6cf8 added streams to mavlink messages 2020-06-03 17:57:12 +02:00
David Jablonski edbe7e3ef0 added FLIGHT_INFORMATION stream 2020-06-03 17:57:12 +02:00
David Jablonski e1f4a70c0e added AUTOPILOT_VERSION and PROTOCOL_VERSION streams 2020-06-03 17:57:12 +02:00
David Jablonski aef2a5755e moving storage_information stream to separate file 2020-06-03 17:57:12 +02:00
David Jablonski 9ce9fe38de use storage_id 1 2020-06-03 17:57:12 +02:00
David Jablonski fd09198c7e implemented MAV_CMD_REQUEST_MESSAGE for STORAGE_INFORMATION 2020-06-03 17:57:12 +02:00
Julian Oes 25bfcf0497 README: remove experimental/legacy boards 2020-06-03 10:13:43 -04:00
Julian Oes 08e1532bd0 README: fix 404 link 2020-06-03 10:13:43 -04:00
Daniel Agar 6c96748e54 boards: pixhawk mini add unused MPU9250 CS & DRDY pins 2020-06-03 04:03:27 -07:00
Daniel Agar 9e509a4bec navigator: RTL minor whitespace and style fixes 2020-06-02 22:08:55 -04:00
Daniel Agar aca6be8b5c navigator: RTL destination throttle dataman access 2020-06-02 22:08:55 -04:00
David Sidrane 7aac0c5ac3 platforms/nuttx/NuttX/nuttx back ports for H7 2020-06-02 13:02:51 -04:00
David Sidrane 73bb18a053 px4_fmu-v6x: Limit Slew rate So IMU works with DMA
The defualt in NuttX is OSPEED of 50Mhz. This is realy a slew
   rate control. At the default high slew rate the overshoot was
   .7 Volts. On a ICM20649 this was causing the device to output
   garbage. All 0s

   N.B. A passive scope or Logic analyser's probes load will mask
   the failure. Useed a FET probe to verify the issue.
2020-06-02 13:02:51 -04:00
David Sidrane 5d90c31632 Added PX4 FmuV6X 2020-06-02 13:02:51 -04:00
David Sidrane 9beca65600 stm32_common:board_mcu_version expand to include STM32H7[4|5]
Todate I have not fould a way to differentiate a 74 from a 75.
   as all parts map to Device ID 0x450: STM32H742, STM32H743/753
   and STM32H750.

   One the CPU is fully differentiate in Nuttx, this can be a
   #ifdef.
2020-06-02 13:02:51 -04:00
David Sidrane 19cf2f47ac stm32h7:adc read & clear EOC on init 2020-06-02 13:02:51 -04:00
David Sidrane bd1f69fb76 stm32_common:board_hw_rev_ver Support 16 Bit ADC 2020-06-02 13:02:51 -04:00
David Sidrane 2c9a522f71 stm32_common:adc read & clear EOC on init 2020-06-02 13:02:51 -04:00
David Sidrane 37c1837ceb PX4:stm32_common/ToneAlarmInterfacePWM.cpp Extend for STM32H7 2020-06-02 13:02:51 -04:00
Daniel Agar 11585dfb67 ekf2: decrease default GPS horizontal velocity noise 2020-06-02 08:18:12 -04:00
Julian Oes 8d47b36f1e Makefile: fix j for clang-tidy calls 2020-06-02 13:17:37 +02:00
Julian Oes 6afdc2c376 build: use ninja default for -jN unless set
It makes sense to trust ninja on selecting the number of cores. This is
also sensible in order not to change existing setups.
2020-06-02 13:17:37 +02:00
Julian Oes 0ec9287457 build: actually pass number of cores to ninja
Without this ninja supposedely builds with the default of the system
which is 10 for my 4 core, 8 thread CPU. With this argument, you can now
actually set it.

This has the benefit that the Gazebo plugins can be built with less
cores in order to avoid running out of RAM.
2020-06-02 13:17:37 +02:00
Julian Oes 340e651d97 Build: properly read -j argument
The previous check for the -j argument was not actually working.
Therefore, the build always used 4 cores, unless when building with
ninja when presumably the ninja default was used.
2020-06-02 13:17:37 +02:00
Dusan Zivkovic 08fdc90175 mission: keep current heading if close to ROI while heading sp is invalid 2020-06-02 12:04:23 +02:00
Daniel Agar a9dacae57e sensors/vehicle_angular_velocity: limit scheduling to IMU_GYRO_RATEMAX 2020-06-01 15:08:50 -04:00
Daniel Agar 96f043cd62 sensors/vehicle_acceleration: limit scheduling to IMU_INTEG_RATE 2020-06-01 15:08:50 -04:00
Daniel Agar b36845330e ms5611: prevent starting as ms5607 type on ms5611 hardware
- an ms5611 using the ms5607 calculations will return impossibly high barometric pressure (~2000 mbar)
2020-06-01 11:31:55 -04:00
Daniel Agar b139f48fef sensors: throttle mavlink emergency log messages
- in rare situations sending these messages multiple times in close succession can actually cause a loop of additional sensor timeouts
2020-06-01 11:25:12 -04:00
Daniel Agar 51a36f0b61 sensors/vehicle_imu: improve initial sensor interval monitoring
- add perf counters for monitoring
2020-05-31 21:41:37 -04:00
Daniel Agar e34bdb4be9 move IMU integration out of drivers to sensors hub to handle accel/gyro sync
- IMU integration move from drivers (PX4Accelerometer/PX4Gyroscope) to sensors/vehicle_imu 
 - sensors: voted_sensors_update now consumes vehicle_imu
 - delete sensor_accel_integrated, sensor_gyro_integrated
 - merge sensor_accel_status/sensor_gyro_status into vehicle_imu_status
 - sensors status output minor improvements (ordering, whitespace, show selected sensor device id and instance)
2020-05-30 11:07:54 -04:00
Mirko Denecke 86cd1d0802 Hex CubeOrange: fix comment for TONE_ALARM_CHANNEL pin 2020-05-29 23:44:17 +01:00
Mirko Denecke b5ff82bccc Hex CubeOrange: remove CAN Silence Silent mode pins 2020-05-29 23:44:17 +01:00
Mirko Denecke fd600d7eed Hex CubeOrange: remove LSM303D 2020-05-29 23:44:17 +01:00
Beat Küng 43279f18ba bmp388: fix variable shadowing warning 2020-05-29 09:54:18 -04:00
Julian Oes 9b2527549b mavsdk_tests: relax timeout for offboard goto
This probably makes sense because we ask for more accuracy, so it will
take longer to reach a position.
2020-05-29 11:46:14 +02:00
Julian Oes bc1960ef2b mavsdk_tests: make offboard tests more accurate
By making the acceptance radius smaller we should potentially also be
more accurate while landing and fail less.
2020-05-29 11:46:14 +02:00
Julian Oes dd95498379 mavsdk_tests: at normal speed RTL can take a while 2020-05-29 11:46:14 +02:00
Julian Oes 76b7d462ae mavsdk_tests: relax requirement to land at home
Hopefully, this will fix CI.
2020-05-29 11:46:14 +02:00
Julian Oes d43e4d88c3 mavsdk_tests: wait until home is set properly
Otherwise we might have NaN stored as home.
2020-05-29 11:46:14 +02:00
Julian Oes 73dda496ef mavsdk_tests: more verbose output on fail 2020-05-29 11:46:14 +02:00
Julian Oes 160aca9207 mavsdk_tests: more debug info 2020-05-29 11:46:14 +02:00
Julian Oes 1a25cdf7b2 mavsdk_tests: remove intermittently failing tests
We can bring them back when they work consistently.
2020-05-29 11:46:14 +02:00
Julian Oes a1bf1bdd9d mavsdk_tests: prevent exception if log_fd is None 2020-05-29 11:46:14 +02:00
Julian Oes 262341455b mavsdk_tests: map stderr to stdout
That way we don't need to collect it separately.
2020-05-29 11:46:14 +02:00
Julian Oes eba1cf08f8 mavsdk_tests: also use sleep workaround locally
However, don't sleep as long as in CI.
2020-05-29 11:46:14 +02:00
Julian Oes 1cb706c411 px4_log: flush each line
Without this fix all PX4 output is buffered and presented at the very
end of a scripted MAVSDK test which makes the log hard to read.
2020-05-29 11:46:14 +02:00
Julian Oes 76750fc8a6 mavsdk_tests: collect buffered up stdout output
Somehow only subprocess.stdout.readline() works at a time. In order not
to miss out on some of the stdout output, we need to collect it all at
the end. Also, we can stop using readline() for processes that have quit
already.
2020-05-29 11:46:14 +02:00
Dusan Zivkovic 1f57d63503 precland: set the previous position setpoint to invalid, in the position setpoint triplet 2020-05-29 09:18:43 +02:00
Dusan Zivkovic 7eee9deb4c mission: handle precision landing inactivation properly 2020-05-29 09:11:01 +02:00
Dusan Zivkovic a758ea1220 RTL: enable precision landing at the end of RTL, configurable by parameter 2020-05-29 09:11:01 +02:00
Dusan Zivkovic ed9e504695 precland: add a method to check if precland is activated 2020-05-29 09:11:01 +02:00
TSC21 ad4d4287fa mavlink odometry: properly set the frame id fields 2020-05-28 15:45:13 +01:00
TSC21 562d57fee8 mavlink: fix odometry frames of reference setup 2020-05-28 15:45:13 +01:00
Daniel Agar 0ec48cfef3 ekf2: increase default baro noise 2 -> 3.5 m 2020-05-28 08:35:07 -04:00
Beat Küng 07b39ec7c0 bmp388: some cleanup
- avoid unnecessary sensor readout cycle during init
- check status register for data ready
2020-05-28 08:34:38 -04:00
Hamish Willee 14853539e3 CBRK_FLIGHTTERM: Does not affect takeoff failure safety detection (#14972)
* CBRK_FLIGHTTERM: Clarify does not affect takeoff failure safety detection

* FD_FAIL_P FD_FAIL_R - clarify apply on takeoff

* Improve param text

Co-authored-by: Mathieu Bresciani <brescianimathieu@gmail.com>
2020-05-28 08:30:48 +02:00
Daniel Agar 05856c1029 ROMFS: holybro s500 decrease filter defaults 2020-05-27 12:25:51 -04:00
David Sidrane 46276e11b5 NuttX with stm32h7 backports 2020-05-27 10:56:32 -04:00
Pandacoolcool 664c79742b navigator_main.cpp: don't reset wv enable status (#14901)
* navigator_main.cpp: don't reset wv enable status

* fix review
2020-05-27 15:49:04 +03:00
Daniel Agar c0bf5cc94c systemcmds/gpio: add module documentation 2020-05-27 07:35:27 +02:00
Daniel Agar 094fe269dc systemcmds/gpio: move usage description to bottom and fix formatting 2020-05-27 07:35:27 +02:00
Matthias Grob d92e66863a mc_pos_control: migrate MPC_*_VEL_* parameter to acceleration scaling
Before #14212 the velocity control gains used in the multicopter
position controller were defined as a scale between velocity error in
one axis (or it's integral and derivative respectively) and the unit
thrust vector. The problem with this is that the normalization of the
unit thrust vector changes per vehicle or even vehicle configuration
as 0 and 100% thrust get a different physical response. That's why
the gains are now defined as scale between velocity error
(integral/derivative) and the output acceleration in m/s².
2020-05-26 14:44:41 +02:00
Matthias Grob e482081f91 mc_att_control: grab attitude setpoint before processing estimate reset 2020-05-26 15:07:45 +03:00
Matthias Grob 12ee75700a mc_att_control: adapt setpoint on estimation reset
There was a gap where the attitude controller already used the estimate
with a new reference but the last known attitude setpoint was still based
on the old reference. This leads to a big glitch on reset because until
the attitude setpoint gets updated the error is wrong and as large as the
attitude delta of the reset.
2020-05-26 15:07:45 +03:00
Matthias Grob cf658494ad mc_attitude_control: keep last attitude setpoint as member
The last attitude setpoint that is known from the position controller
is now kept inside the AttitudeControl class such that we don't
keep the whole vehicle_attitude_setpoint struct and always copy over from
there to run an update step.
2020-05-26 15:07:45 +03:00
RomanBapst bd154bf33c FixedWingAttitudeControl: removed parachute from gimbal control group
- parachute is handled separately based on flight termination in px4io

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-05-25 11:44:35 -04:00
Daniel Agar ade8a13203 commander: CMD_COMPONENT_ARM_DISARM don't block disarm if maybe_landed 2020-05-25 11:43:14 -04:00
Matthias Grob 7b41ce4711 simulator: rename parameter variable according to convention 2020-05-25 11:04:24 +02:00
Matthias Grob 88c21337fa Make all battery sensor drivers report their sample interval
To make use of the time abstraction in the leaky integrator.
2020-05-25 11:04:24 +02:00
Matthias Grob 4dc9ca69ab battery: use AlphaFilter class
Replace the filtered value calculations with calls to the class.
This will allow time abstraction.
2020-05-25 11:04:24 +02:00
BazookaJoe1900 cd8850b43b mavlink: bring class LogListHelper into MavlinkLogHandler (#14452)
This is in order to avoid dynamic allocation of LogListHelper when downloading logs.
2020-05-25 10:08:25 +02:00
Daniel Agar 1c0925a189 Hex/Proficnc Cube Orange support
Co-authored-by: Jacob Dahl <dahl.jakejacob@gmail.com>
Co-authored-by: Jacob Crabill <jacob@flyvoly.com>
2020-05-23 18:31:46 -04:00
Daniel Agar e577c3b610 fxos8701cq: sample at nyquist rate, drop duplicates, throttle temperature updates 2020-05-23 13:23:03 -04:00
Daniel Agar e73380f726 fxas21002c: sample at nyquist rate, drop duplicates, throttle temperature updates 2020-05-23 13:23:03 -04:00
PX4 BuildBot 10d67efd13 Update submodule ecl to latest Sat May 23 12:39:43 UTC 2020
- ecl in PX4/Firmware (1d49243ee21930dc1c0ba1f08a4c03284c4713c1): https://github.com/PX4/ecl/commit/600240d95f6dc08f82e5310b13e9406c4df0f00f
    - ecl current upstream: https://github.com/PX4/ecl/commit/c91c78dcf67dee85225ada6621b6fd19ec008fd5
    - Changes: https://github.com/PX4/ecl/compare/600240d95f6dc08f82e5310b13e9406c4df0f00f...c91c78dcf67dee85225ada6621b6fd19ec008fd5

    c91c78d 2020-05-21 Paul Riseborough - EKF: Allow reset of yaw to EKF-GSF later in flight
2020-05-23 13:18:36 -04:00
Daniel Agar 8ee0a5d328 px4_work_queue: minor status changes
- only record start time on first run rather than init
 - increase name length
 - round average interval to nearest microsecond
 - basic formatting consistency (google style guide)
2020-05-23 11:51:23 -04:00
Julian Kent dd9c82eb20 systemcmds/gpio: Add nsh command to manipulate/read GPIO
* Add basic GPIO test app for R/W on pins from nuttx shell
* Add gpio command to fmu-v3 and fmu-v4
* Sanitize gpio commands by pin configs, --force to override
2020-05-23 11:47:40 -04:00
JaeyoungLim b5e23f544e Tune down solo attitude rate controller
This removes visible oscillations of the vehicle
2020-05-23 11:46:16 -04:00
David Sidrane 04db5391fc px4_fmu-v5x:Fix PG11 assignment 2020-05-23 11:46:00 -04:00
David Sidrane b2153c7f2f px4_fmu-v5x:PG6 is free GPIO 2020-05-23 11:46:00 -04:00
David Sidrane 7f84ed57dd px4_fmu-v5x:Using SE050 not A71CH 2020-05-23 11:46:00 -04:00
David Sidrane 637578b8be px4_fmu-v5x:Correct trace connector description 2020-05-23 11:46:00 -04:00
David Sidrane ef664f3c23 stm32_common:board_hw_rev_ver Fix printing of REV/VER = 10 2020-05-23 11:45:24 -04:00
David Sidrane 0139acacfd adc:Restore ADC test's usefulness 2020-05-23 11:43:04 -04:00
Dusan Zivkovic b7ebdab7fd mavlink_receiver: handle LANDING_TARGET message: publish irlock_report when landing target position invalid 2020-05-23 11:42:21 -04:00
Daniel Agar 951969ba00 drivers/imu/invensense: new ICM20948 driver on SPI with AK09916 mag 2020-05-22 00:09:30 -04:00
Silvan Fuhrer 504794eddc VTOL: reject transition command in certain flight modes 2020-05-20 15:54:31 -04:00
PX4 BuildBot a4c77056f6 Update submodule ecl to latest Wed May 20 16:46:07 UTC 2020
- ecl in PX4/Firmware (73de85e258590461b6fe14668df8de1fc9c54cb7): https://github.com/PX4/ecl/commit/24f2e60b7eff664d0035d5f75f410073be28d894
    - ecl current upstream: https://github.com/PX4/ecl/commit/600240d95f6dc08f82e5310b13e9406c4df0f00f
    - Changes: https://github.com/PX4/ecl/compare/24f2e60b7eff664d0035d5f75f410073be28d894...600240d95f6dc08f82e5310b13e9406c4df0f00f

    600240d 2020-05-20 Daniel Agar - EKF: resetGpsAntYaw() fix double promotion
39c09b8 2020-05-19 kamilritz - add basic gps yaw fusion test
21f49c2 2020-05-16 Kamil Ritz - Use resetQuatStateYaw during gps yaw reset
7f21364 2020-05-20 Carl Olsson - EKF: use initial wind uncertainty with no airspeed sensor (#823)
bf78044 2020-05-20 kritz - EKF: fix initialization of local position validity 2 (#820)
716caa5 2020-05-19 kritz - Refactor position resets (#822)
37d9cef 2020-05-19 Mathieu Bresciani - ekf: disable xy accel bias learning before takeoff (#818)
9788c3b 2020-05-15 Mathieu Bresciani - ekf: split accel bias learning in independant xyz components (#817)
19bbea7 2020-05-14 Paul Riseborough - Fix GPS altitude not fused if GPS checks fail and GPS is primary height source (#813)
2020-05-20 15:48:27 -04:00
Matthias Grob 27586db93e rc_update: remove obsolete RC filtering 2020-05-20 19:30:19 +02:00
Matthias Grob 17d4fd064f FlightTaskManualAltitude: add an optional stick tilt input filter 2020-05-20 19:30:19 +02:00
Matthias Grob 1a3c692e4e mc_att_control: add an optional stick tilt input filter 2020-05-20 19:30:19 +02:00
Beat Küng 6c16a29d26 mavlink: remove unneeded TIMESYNC stream from MAVLINK_MODE_EXTVISION
set in MAVLINK_MODE_EXTVISIONMIN by fallthrough
2020-05-20 09:12:50 +02:00
Beat Küng 9c6f42a867 v5x defconfig: increase TELEM2 UART TX buffer size to 3000
Required for very high-rate log streaming @3MBit baudrate.
2020-05-20 09:12:50 +02:00
Beat Küng 107ab16e96 mavlink: reorder streams to optimize latency
In particular this together with the previous commit reduces timesync
round-trip time spikes by more than 10ms, and makes it generally more
stable.

Other streams are reordered according to onboard priority.
2020-05-20 09:12:50 +02:00
Beat Küng fa8def903d mavlink: move ulog handling after stream updates
reduces latency for the mavlink streams
2020-05-20 09:12:50 +02:00
Beat Küng d0ad308eda serial_test: fix build for linux 2020-05-20 09:12:50 +02:00
David Jablonski e409ec0038 install bc for all simulations 2020-05-20 09:04:41 +02:00
Beat Küng 982d2a3180 ubuntu.sh: minor simplifications 2020-05-20 08:57:37 +02:00
Julian Oes f2e2ac5def gps: workaround spurious GCC 10.1 warning
This is a workaround for a warning in GCC 10.1:
src/drivers/gps/devices/src/ubx.cpp:520:8: error: writing 4 bytes into a
region of size 0 [-Werror=stringop-overflow=]

Also see:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91707
2020-05-19 10:10:19 -04:00
Julian Oes 44be9d5568 controllib: fix implicit cast warn with clang 10 2020-05-19 09:58:43 -04:00
Michal Stasiak 4f82f028e7 airspeed_calibration: Fix FD leak 2020-05-19 13:48:43 +02:00
Julian Oes 793eb82153 navigator: allow mission items with same position
This reverts the addition of a check against mission items that have the
same position. This breaks existing MAVSDK implementations where a
LOITER_TIME item is set right after a WAYPOINT with the same
coordinates. It is an interim hack to allow the vehicle to hold still
during a photo is captured.

This leaves the check in place for gates where we need to be able to
calculate the direction between gate and waypoint.
2020-05-19 08:51:21 +02:00
Matthias Grob a605444462 board_comnmon: indent BOARDBRICK_VALID_LIST to correct level
to avoid other people getting confused as well.
2020-05-18 10:52:26 -04:00
Julian Oes d4de0e1219 Tools: fix ubuntu setup script
This fixes the error:
line 149: [: missing `]'
2020-05-18 11:53:26 +02:00
Silvan Fuhrer b5cc3c4ef5 mavlink_messages: send EAS instead of IAS (#14858)
Send equivalent_airspeed_m_s instead of indicated_airspeed_m_s for HUD on groundstation.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-05-18 10:34:39 +02:00
JaeyoungLim e670d5f1e2 Fix interactive shell with roslaunch (#14919)
Fixes the interactive shell that was not working previously when starting px4 sitl with roslaunch
2020-05-17 23:39:02 +02:00
JacobCrabill 328477f0be UavcanNode: Add sensor_type to range_sensor pub. 2020-05-15 16:45:52 +01:00
bresch 76de299302 Offboard temp cal: add support for 3rd baro 2020-05-14 09:16:37 +02:00
bresch a103c4305b Offboard temp cal: check topic instance
Not checking the id can lead to sensor ordering swap
2020-05-14 09:16:37 +02:00
Matthias Grob 22cdf80293 i2c_spi_buses.h: work around astyle version inconsistency 2020-05-14 08:32:07 +02:00
Matthias Grob 03bafd5581 powerCheck: make 5V warning threshold 0.1V lower
Because of warnings on every flight on setups without
any need for concern. Some even high quality supply voltage regulators
that are rated for 5V can with tolerances and load get lower than 4.9V.
2020-05-13 11:37:20 -04:00
ealdaz c96b5246ff Improved Hold behaviour
Added local position as a valid source of position
2020-05-13 13:08:41 +02:00
kritz 3897030c6f Support odometry velocity in body and local frame (#14703)
* Update submodule ECL

* increase lower bound on EVV param
2020-05-13 12:43:02 +02:00
Hamish Willee 8804dae480 Ubuntu.sh - report Ubuntu 20.04 in setup 2020-05-12 13:13:36 +02:00
Daniel Agar 05886e053f mavlink_log_info: always print to console and merge with mavlink_and_console_log_info 2020-05-12 08:53:51 +02:00
PX4 BuildBot b933557f56 Update submodule ecl to latest Tue May 12 00:39:54 UTC 2020
- ecl in PX4/Firmware (286bf4f0b911fcc040788117ea79c432f6a95a83): https://github.com/PX4/ecl/commit/97b437233e6aad5ddb8a4511697a38ced7bc9b87
    - ecl current upstream: https://github.com/PX4/ecl/commit/03191847f9c162dedc2cb45ff775b75cbc9c8b36
    - Changes: https://github.com/PX4/ecl/compare/97b437233e6aad5ddb8a4511697a38ced7bc9b87...03191847f9c162dedc2cb45ff775b75cbc9c8b36

    0319184 2020-05-11 kritz - Fix ev_pos_obs_var(1) entry (#809)
440383f 2020-05-09 Kamil Ritz - Increase matrix library usage and remove white line
2020-05-11 22:11:19 -04:00
斯东Stone c07b687753 Set Power Monitor to a Neutral Position for PX4 Vision
Reference manual in box, and Holybro's website.
2020-05-11 14:27:03 -04:00
Daniel Agar b461066ac5 bmi055/bmi088: remove TIMER_REDUCTION, sample at Nyquist rate 2020-05-11 12:59:34 -04:00
Daniel Agar 19b2d7fe9a bmi088: fix accel schedule interval 2020-05-11 12:59:34 -04:00
Daniel Agar 08d65280f1 bmi055: fix accel schedule interval 2020-05-11 12:59:34 -04:00
Daniel Agar 56211864b8 bmi088: accel & gyro don't publish duplicated reads 2020-05-11 12:59:34 -04:00
Daniel Agar e0fc404f91 bmi055: gyro don't publish duplicates 2020-05-11 12:59:34 -04:00
Daniel Agar c5cbc7725d msg: timestamp_sample print elapsed from timestamp 2020-05-11 12:58:52 -04:00
Daniel Agar 2bbdef205e sensors/vehicle_angular_velocity: don't remove bias twice 2020-05-10 15:30:37 -04:00
Daniel Agar ec2cd3b1be sensors: use sensor_gyro timestamp_sample for sensor_combined timestamp
The timestamp actually used by ekf2 is the sensor_combined timestamp, so we should be setting it with the actual data sample timestamp, rather than the aggregated sensors topic publication metadata.

Later the sensor_combined message will be replaced with vehicle_imu that carries a separate publication timestamp and raw sample timestamp.
2020-05-10 15:24:32 -04:00
PX4 BuildBot 49981627dd Update submodule ecl to latest Sun May 10 12:39:42 UTC 2020
- ecl in PX4/Firmware (43bf631832ab836534f2197c286c1fd380872625): https://github.com/PX4/ecl/commit/12835b999e756ef631111c4fdd0ac1c72d68694d
    - ecl current upstream: https://github.com/PX4/ecl/commit/97b437233e6aad5ddb8a4511697a38ced7bc9b87
    - Changes: https://github.com/PX4/ecl/compare/12835b999e756ef631111c4fdd0ac1c72d68694d...97b437233e6aad5ddb8a4511697a38ced7bc9b87

    97b4372 2020-05-08 bresch - ekf: remove unused function
26d4fbc 2020-05-08 bresch - EKF: reduce scope of variable and remove redeclaration of member
edc8a88 2020-05-08 bresch - yaw_fusion: remove useless initialization
75c49b2 2020-05-08 bresch - ekf_helper: fuse double if
0e3bf28 2020-05-08 bresch - EKFGSF_yaw: cleanup initialization of member variables
2020-05-10 11:51:31 -04:00
Daniel Agar d53bb581c2 navigator: check _navigation_mode_array before run 2020-05-09 11:46:39 -04:00
Daniel Agar da186877c9 gps: only use injected data if copy successful 2020-05-09 11:46:39 -04:00
Samuel Garcin b12a655c5b Notch filter Direct Form I implementation that support dynamic change of frequencies
* New NotchFilter methods ahead of RPMFilter implementation.
 * Added Direct Form I implementation that support dynamic change of frequencies.
 * Added update method to update frequency on an existing filter.
 * Added setCoefficients method to easily and efficiently create clones of a filter.
 * LowSide, HighSide, Onnotch and array tests testing the applyDF1 method.
2020-05-08 12:00:27 -04:00
Silvan Fuhrer 0c75385395 replace IAS with EAS in FW attitude controller (#14868)
The EAS is the calibrated airspeed corrected with a scaling factor to account for sensor error/placement of pitot.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-05-08 10:46:24 +02:00
Daniel Agar 678c3fe8e4 boards: px4_fmu-v5_optimized don't build all mags 2020-05-07 15:21:15 -04:00
Daniel Agar 1cce549b2b boards: holybro_durandal-v1_stackcheck don't build all mags 2020-05-07 15:21:15 -04:00
Daniel Agar 8d48e49ef9 cmake build lis2mdl with all magnetometers 2020-05-07 15:21:15 -04:00
Beat Küng 7c4b5a03f6 drivers: add lis2mdl mag driver 2020-05-07 15:21:15 -04:00
Daniel Agar 6d846143dc pwm_out: update pwm outputs up to twice as fast as actual pwm frequency
- this is done to minimize real end-to-end latency
 - actual pulse width only updated for next period regardless of output module
 - add cycle interval perf counter
2020-05-07 13:18:09 -04:00
Daniel Agar aa380f351f uORB: SubscriptionInterval last update shift forward with interval 2020-05-07 13:18:09 -04:00
Daniel Agar 297e4dd589 Jenkins hardware uORB top print all once 2020-05-07 09:31:15 +02:00
Daniel Agar 7cf8a7ca64 uORB top readd initial clear screen 2020-05-07 09:31:15 +02:00
Daniel Agar a2d170d850 uORB: top output improvements
- sleep slightly longer than 1s to capture 1 Hz topics
 - round msg rate calculation
 - add topic size to outpu
 - by default only print topics with subscribers
 - clear previous output (past cursor)
2020-05-07 09:31:15 +02:00
Daniel Agar 41660c3550 commander: update EKF accel & gyro bias arming limits
- these should have been rescaled when the ecl/EKF filter update period changed from 8 ms -> 10 ms
2020-05-07 01:21:47 -04:00
PX4 BuildBot fa64c3862d Update submodule matrix to latest Thu May 7 00:38:16 UTC 2020
- matrix in PX4/Firmware (b14143229d5aa79e060c2bf65a2eb35f36b7a38c): https://github.com/PX4/Matrix/commit/d613055462bcbeacfd188cbd53de56c1dbc7b94d
    - matrix current upstream: https://github.com/PX4/Matrix/commit/2bee0d078cb6b0e6205d17145899ccbb15dbe380
    - Changes: https://github.com/PX4/Matrix/compare/d613055462bcbeacfd188cbd53de56c1dbc7b94d...2bee0d078cb6b0e6205d17145899ccbb15dbe380

    2bee0d0 2020-05-06 Matthias Grob - Quaternion: refactor multiplication to matrix multiplication style
2020-05-06 22:27:07 -04:00
Daniel Agar 7207301e56 simulator: temperature only updated with baro 2020-05-06 15:34:21 -04:00
Daniel Agar 9963bb6c40 parameters: lock shutdown earlier in param_save_default()
- this ensures the parameter file is closed properly before shutdown
2020-05-06 13:53:54 -04:00
Daniel Agar 10b289b43c commander: only report manual control lost if found once 2020-05-06 13:53:54 -04:00
Daniel Agar 7bb256f4b7 commander: skip continuous preflight check if calibrating 2020-05-06 13:53:54 -04:00
Daniel Agar 6705ac3e3b commander: reject PREFLIGHT_CALIBRATION and PREFLIGHT_STORAGE if armed or shutting down 2020-05-06 13:53:54 -04:00
Daniel Agar 04113b4d57 commander: changes when USB connected
- skip avionics rail voltage check when USB connected
 - skip forced reboot on USB disconnect if circuit breaker set
 - avionics voltage preflight check don't silently fail if system_power unavailble
     - explicitly set supply check circuit breaker (CBRK_SUPPLY_CHK)
2020-05-06 13:53:54 -04:00
Daniel Agar 746a8f5cf9 commander: reboot/shutdown usability fixes
- always check with state machine before reboot/shutdown
 - respect BOARD_HAS_POWER_CONTROL (shutdown from command, low battery, power button)
 - px4_shutdown_request add optional delay and always execute from HPWORK
 - px4_shutdown_request split out px4_reboot_request
2020-05-06 13:53:54 -04:00
Silvan Fuhrer 45ebbb895a Airspeed Selector: do not run it within the first 2s after system boot
This is to prevent a wrong (false positive) failure detection of the airspeed
shortly after system boot due to delays in driver and/or estimator startup (seen in SITL).

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-05-06 12:46:22 -04:00
Daniel Agar 604258ec71 Jenkins: hardware rack show df, mount, sensor_combined, vehicle_imu per board 2020-05-06 10:51:59 -04:00
Beat Küng 8d722ac74b bmm150: add self-test 2020-05-06 09:37:56 -04:00
Beat Küng 71b942392d bmm150: cleanup, slightly increase data accuracy
- increased REP_XY and REP_Z: improves accuracy a bit, while increasing
  measurement time (still allows to go to 50Hz, previous max was 100Hz)
- avoid extra transfer in measure()
- extend regdump output
- general code style cleanup
2020-05-06 09:37:56 -04:00
Beat Küng 1175c08829 bmm150: more explicit data conversion & reduce to 30Hz
- 30Hz is the sensors max update rate in continous mode
  (though not in forced mode as we are using it)
- 30Hz allows to increase the quality of the measurements
2020-05-06 09:37:56 -04:00
Daniel Agar b5e25c2218 sensors: checkFailover() remove verbose failure messages
- in certain circumstances this additional logging can actually cause
further timeouts and failure
2020-05-06 09:31:09 -04:00
Daniel Agar 29f4fca7bf sensors: failover don't print remaining disabled sensors 2020-05-06 09:31:09 -04:00
Daniel Agar 692aaada31 sensors: refresh parameters on sensor init 2020-05-06 09:31:09 -04:00
Daniel Agar cb180427cd sensors: inconsistency checks explicitly skip disabled 2020-05-06 09:31:09 -04:00
kamilritz 5bd0df422d Speed up mavsdk sitl tests 2020-05-06 09:25:03 +02:00
kamilritz af1a445031 Vision test can be speed up 2020-05-06 09:25:03 +02:00
Daniel Agar 2a2d9e9eba logger: keep typical log path within a single mavlink message 2020-05-06 08:31:40 +02:00
PX4 BuildBot 495dc7f8d0 Update submodule sitl_gazebo to latest Wed May 6 00:44:20 UTC 2020
- sitl_gazebo in PX4/Firmware (ca998c1822): https://github.com/PX4/sitl_gazebo/commit/d76ac7f9f9813fd52acf0b9f344edbf72d3b4406
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/2736a9134d7fed0cae7b7836d4370f9a4dfef439
    - Changes: https://github.com/PX4/sitl_gazebo/compare/d76ac7f9f9813fd52acf0b9f344edbf72d3b4406...2736a9134d7fed0cae7b7836d4370f9a4dfef439

    2736a91 2020-05-05 JaeyoungLim - Add aion_robitcs_r1_rover model (#394)
2020-05-05 23:31:55 -04:00
PX4 BuildBot ce0e531d45 Update submodule ecl to latest Wed May 6 00:44:34 UTC 2020
- ecl in PX4/Firmware (476a51f32c96fe886edb70f7c7e0bf15f7ec67ad): https://github.com/PX4/ecl/commit/cda74868976d0f806d821960e71f58d0b2c40051
    - ecl current upstream: https://github.com/PX4/ecl/commit/12835b999e756ef631111c4fdd0ac1c72d68694d
    - Changes: https://github.com/PX4/ecl/compare/cda74868976d0f806d821960e71f58d0b2c40051...12835b999e756ef631111c4fdd0ac1c72d68694d

    12835b9 2020-05-01 Daniel Agar - cmake update CXX standard 11 -> 14
2020-05-05 23:31:23 -04:00
Daniel Agar ca998c1822 IMU: parameterize IMU integration time (IMU_INTEG_RATE)
- default integration rate now 200 Hz (5000 us interval)
 - set update rate for all drivers and simulators using PX4Accelerometer/PX4Gyroscope
2020-05-05 20:34:09 -04:00
Daniel Agar 682aa700bb px4_work_queue: increase wq:attitude_ctrl stack 2020-05-05 12:53:18 -04:00
JaeyoungLim b10cbd2892 Fix shibang of r1_rover airframe config
The shibang was missing in the previous commit where this file was added
2020-05-05 10:01:26 -04:00
kritz 33dc0fd146 Add vision velocity integration test (#14818) 2020-05-05 11:14:30 +02:00
JaeyoungLim cae28cd59a Add aion robotics r1 rover sitl target (#14652)
This adds a sitl target and aiframe configs for the r1_rover, which is a differential rover example for SITL rover. The model is based on the aion robotics r1 rover
2020-05-05 11:07:02 +02:00
Matthias Grob cdf37ca557 PositionControl: deconflict hover thrust estimator, acceleration control
- Avoid constantly adjusting the velocity gains with the HTE
- Make sure the hover thrust integral update doesn't break
  even though its unit is acceleration and not unit thrust anymore

We need to convert the velocity gains to not contain/depend on the
hover thrust. In horizontal direction it doesn't make sense to scale
them with the hover thrust and in vertical direction the adjustments are
already done in the acceleration to collective thrust conversion.
2020-05-04 22:17:56 +02:00
Daniel Agar 466b5db36f uORB::Publication improvements and cleanup (#14784)
- create common uORB::PublicationBase
 - uORB::PublicationQueued types are now type aliases
 - ORB_PRIO use enum type everywhere to avoid accidental misuse
 - PX4Accelerometer/PX4Gyroscope/etc driver libs explicitly advertise on construction, unadvertise on destruction. This is a workaround for any potential issues that might appear when accel/gyro cdev and uORB indexing doesn't align.
2020-05-04 11:09:30 -04:00
Matthias Grob 8e2c52a31a mc_pos_control: suppress vertical acceleration feed-forward during takeoff ramp
Because the takeoff ramp is a vertical velocity limit ramp for the
nice user experience but the acceleration feed-forward can
add on top of the output and depending on trajectory generation
result in unwanted thrust changes during the ramp.
2020-05-04 16:10:36 +02:00
Beat Küng bcce75e691 icm20948+mpu9250: add support to configure the high bus speed 2020-05-04 09:49:23 +02:00
rfu 0becd29b46 fix mpu9250: wrong buffer size 2020-05-04 09:49:23 +02:00
rfu f8db9c4f1b fix mpu6000: wrong buffer size 2020-05-04 09:49:23 +02:00
rfu adb032d2e5 drivers: up_udelay -> px4_usleep 2020-05-04 09:49:23 +02:00
rfu 8787780de4 some printf format and conversion fixes 2020-05-04 09:49:23 +02:00
rfu 90c3819df5 fxos8701cq + fxas21002c: add support for I2C 2020-05-04 09:49:23 +02:00
David Jablonski 09180b9d4a mavlink: increment cmd confirmation field (#14808) 2020-05-04 09:21:01 +02:00
kamilritz 960ad0693f fix format 2020-05-03 18:25:00 +01:00
kamilritz 9137813472 Received quaternion represents body to world 2020-05-03 18:25:00 +01:00
JaeyoungLim 4282832222 Update flightgear bridge (#14816)
Fix vehicle spawning issue with updating the submodule paths
2020-05-03 17:09:22 +02:00
Daniel Agar 6dfe12d122 Revert "drivers/pwm_out: cleanup for multi-platform use" (#14812)
This reverts commit 0c8dcf94bc.
2020-05-02 23:42:51 -04:00
JaeyoungLim cd59f95565 Add additional flap channel in mixer
Since sitl gazebo is unable to control to joints from a single channel, an additional mixer is defined
2020-05-01 21:01:33 -04:00
baumanta 545b8118a8 change solo mag rotation to new convention 2020-05-01 21:00:55 -04:00
baumanta 200d905b63 delete ROTATION_YAW_293_PITCH_68_ROLL_90 as usage implies it is the same as ROTATION_ROLL_90_PITCH_68_YAW_293 2020-05-01 21:00:55 -04:00
baumanta 38a6304d53 cleanup unneccessary complicated formulations 2020-05-01 21:00:55 -04:00
baumanta c758da2391 add test for rotations, add new rotations, fix old rotations 2020-05-01 21:00:55 -04:00
baumanta c37424aff2 sort enum by mavlink MAV_SENSOR_ORIENTATION 2020-05-01 21:00:55 -04:00
kamilritz 0cdf2c2e29 Use ground truth uorb topic for ground truth mavlink message 2020-05-01 21:00:24 -04:00
Daniel Agar 28d2aca699 boards: include all procfs entries on boards that aren't flash constrained 2020-05-01 20:59:57 -04:00
Daniel Agar 8d0c92003a boards: remove all CONFIG_NXFONTS_DISABLE* 2020-05-01 20:59:57 -04:00
Daniel Agar d89b7804f7 boards: initial CUAV X7Pro support (not complete)
- this is booting and functional, but still missing a few things
 - still needs full PWM output, verification of all sensor rotations and IO, etc
2020-05-01 20:59:28 -04:00
Daniel Agar 0c8dcf94bc drivers/pwm_out: cleanup for multi-platform use 2020-05-01 20:53:35 -04:00
Hamish Willee 0a4e7142ee ubuntu setup script: add gstreamer1.0-libav
This was needed in order to display video in QGC
2020-05-01 10:35:10 -04:00
PX4 BuildBot c5341da813 Update submodule ecl to latest Fri May 1 00:39:52 UTC 2020
- ecl in PX4/Firmware (838a470e922076d18ad67a580b9cbab65e8e1f14): https://github.com/PX4/ecl/commit/8b6d665a1331f94091caf2f262e09d508eb8975c
    - ecl current upstream: https://github.com/PX4/ecl/commit/cda74868976d0f806d821960e71f58d0b2c40051
    - Changes: https://github.com/PX4/ecl/compare/8b6d665a1331f94091caf2f262e09d508eb8975c...cda74868976d0f806d821960e71f58d0b2c40051

    cda7486 2020-04-30 Paul Riseborough - EKF: Prevent yaw reset to GPS caused by loss of GPS data (#805)
2020-04-30 21:24:33 -04:00
PX4 BuildBot 3135f7e1cf Update submodule flightgear_bridge to latest Fri May 1 00:39:36 UTC 2020
- flightgear_bridge in PX4/Firmware (3ea52fecd3): https://github.com/PX4/PX4-FlightGear-Bridge/commit/f7eb676108c41edea5b9424f29a74a517a1dfd48
    - flightgear_bridge current upstream: https://github.com/PX4/PX4-FlightGear-Bridge/commit/13dde0b4a42be19e9e9dbbb1c2527fab634112af
    - Changes: https://github.com/PX4/PX4-FlightGear-Bridge/compare/f7eb676108c41edea5b9424f29a74a517a1dfd48...13dde0b4a42be19e9e9dbbb1c2527fab634112af

    13dde0b 2020-04-30 JaeyoungLim - Test build without flightgear (#2)
566c7c3 2020-04-30 JaeyoungLim - Add simple build test with github actions (#1)
2020-04-30 21:06:34 -04:00
Pedro Roque 3ea52fecd3 Added Roll Pitch Yawrate Thrust offboard test. Testing... 2020-04-30 17:43:25 -04:00
Daniel Agar 76cfd8fa39 boards: add nxp fmuk66-v3 and rddrone-uavcan146 socketcan builds 2020-04-30 15:04:08 -04:00
Daniel Agar 3e5f85b47b uavcannode: add distance_sensor (all possible instances) 2020-04-30 14:52:06 -04:00
Daniel Robinson d20bca095d Update CONTRIBUTING.md
- typo
2020-04-29 22:49:30 +01:00
JaeyoungLim 35ebbd7202 Switch flightgear bridge submodule to px4 organization (#14789)
This brings the flightgear bridge submodule under the px4 organization
2020-04-29 23:20:25 +02:00
Beat Küng 8bc72fe771 gps drivers: update submodule (M9N support) 2020-04-29 11:39:32 -04:00
Matthias Grob 81e576b63a rotation conversion: deconfuse roll 90 yaw 90 2020-04-29 10:12:50 +02:00
Jakub Kákona dfa5ca1710 FlightGear simulator support (#14539)
- Add flightgear_bridge submodule.
- Add traget px4_sitl_nolockstep with disabled  LOCKSTEP simulation.
- Add flightgear viewer targets and startup scripts
- Add a few possible vehicles plane (rascal), autogyro (tf-g1), and rover (tf-r1))

Co-authored-by: Vit Hanousek <vithanousek@seznam.cz>
2020-04-29 08:46:59 +02:00
Mohammed Kabir 5ffe88672e vehicle_odometry: add timestamp_sample field for latency monitoring 2020-04-28 13:58:43 -04:00
kritz ccaa103164 ekf2: Stop getting velocity variance from pose covariance matrix (#14779) 2020-04-28 10:05:30 -04:00
ealdaz-seesai efa0e1bf0f Rover land detection (#13769)
* Land Enabled

* Declared Subscriptor in header as originally intended.

In the header it caused SIGSEGV in my machine so that's why it was moved
to .cpp

* Code Style fixed

* Removed confusing comments

* Comment update

Co-authored-by: Julian Oes <julian@oes.ch>
2020-04-28 10:59:24 +02:00
Silvan Fuhrer f78847b26f VTOL: Pusher assist: add configuration for enabling it in LAND /disable below some altitude (#14706)
* VTOL type: add new parameter VT_FWD_TRHUST_EN for customizing pusher/tilt assist

Depending on the setting of this param, the pusher assist is:
-completely disabled (default)
-enabled in pos, alt and auto mode (except LAND)
-enabled in pos, alt and auto mode if above MPC_LAND_ALT1
-enabled in pos, alt and auto mode if above MPC_LAND_ALT2
-enabled in pos, alt and auto mode
(before it was always disabled in LAND mode)

-change default of VT_FWD_THRUST_SC from 0 to 0.7

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-04-28 10:44:57 +02:00
Julian Oes 48c60d354d mavlink: move tune publication to separate class
This makes it easier to allocate in MavlinkReceiver.
2020-04-28 08:45:39 +02:00
Julian Oes 2d5184fcfe mavlink: copy tune to buffer to play later
Instead of blocking the receiver thread while playing a tune we now copy
the tune to a buffer and check if we can play the next note on each
iteration of the receiver thread.

The buffer and tune object is only created on the heap if we receive a
tune to play once and doesn't use resources otherwise.
2020-04-28 08:45:39 +02:00
Julian Oes 6f707bf7b5 mavlink: add support for PLAY_TUNE_V2 2020-04-28 08:45:39 +02:00
Julian Oes 5f676b6795 mavlink: move tune publication to a method 2020-04-28 08:45:39 +02:00
Julian Oes 06f40042e9 mavlink: use static_cast instead of C-style cast 2020-04-28 08:45:39 +02:00
Julian Oes 18b39545ab mavlink: add missing uORB publication of tunes
The old tune device interface is not working anymore and we need to
publish to uORB tune_control.

This solution is not optimal though because blocks the receiving thread.
2020-04-28 08:45:39 +02:00
baumanta 48cf38d623 support mag power compensation with battery_status instance 1 2020-04-28 08:36:44 +02:00
baumanta 503bd15b82 change python script to calculate right params 2020-04-28 08:36:44 +02:00
Daniel Agar 326d8efc16 move attitude controllers to new wq:attitude_ctrl 2020-04-27 21:34:35 -04:00
PX4 BuildBot 97bdfd9cec Update submodule ecl to latest Mon Apr 27 12:39:40 UTC 2020
- ecl in PX4/Firmware (27232514fcaf04924ecb405e144615c23ac6e2e0): https://github.com/PX4/ecl/commit/8a9d961f0d7b0cf6371ab1fcd6d0d2ccb581d3d1
    - ecl current upstream: https://github.com/PX4/ecl/commit/8b6d665a1331f94091caf2f262e09d508eb8975c
    - Changes: https://github.com/PX4/ecl/compare/8a9d961f0d7b0cf6371ab1fcd6d0d2ccb581d3d1...8b6d665a1331f94091caf2f262e09d508eb8975c

    8b6d665 2020-04-26 kamilritz - Avoid subtraction of two uint
70d65ea 2020-04-16 kamilritz - Test:Increase GPS jump need for rejection
c19f40e 2020-04-15 Kamil Ritz - Add reset position test for GPS and VISION
78a6b9f 2020-04-15 Kamil Ritz - SensorSimulator: Fix GPS horizontal position step
050298f 2020-04-08 Kamil Ritz - Improve matrix library usage
5749273 2020-04-08 Kamil Ritz - refactor resetPosition
2020-04-27 10:19:22 -04:00
Beat Küng 34c75f2d36 boards: temporarily disable UART TX DMA
work-around for https://github.com/PX4/Firmware/issues/14659.
This can be reverted when fixed properly.
2020-04-27 08:47:46 -04:00
JaeyoungLim e669e999e2 Add options to spawn multiple vehicles in different worlds (#14764)
Since SITL gazebo now has the ability to spawn vehicles to different worlds, this can be done for simulating multiple vehicles
2020-04-27 11:57:47 +02:00
RomanBapst 2b276a3ad8 FixedWingPositionControl: set waypoint straight ahead for front transition
- this fixes the case where the navigator publishes a loiter waypoint or any
waypoint which is too close to the vehicle.

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-04-26 22:59:07 -04:00
RomanBapst 0779a0502c takeoff: only set _can_loiter_at_sp if takeoff position has been set
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-04-26 22:59:07 -04:00
Lorenz Meier b3afb325d8 Update Gazebo to latest
This includes a relevant compile fix for a recent MAVLink update.
2020-04-26 22:55:51 -04:00
Daniel Agar 8cd848fcd6 temperature_compensation: enable parameters set reboot_required
- min/max are unnecessary with boolean
2020-04-26 22:38:35 -04:00
Daniel Agar cc62a52553 PX4Rangerfinder: delete unused CDev 2020-04-26 22:36:46 -04:00
Daniel Agar 5739cf27e5 boards: delete obsolete commented config systemcmd 2020-04-26 22:34:34 -04:00
Daniel Agar 3832214145 PX4Accelerometer/PX4Gyroscope: fix calibration offset for integrated FIFO case
This is a quick follow up fix to to a bug introduced by #14752. In the case of FIFO data (new IMU drivers) the calibration offset wasn't being applied correctly to the result of integrating the FIFO samples.

This slipped through basic sanity testing (simple bench testing, the test rack, and SITL CI) due to the calibration offsets being zeroed.
2020-04-26 13:24:51 -04:00
Daniel Agar 37d5d1b4d2 PX4Accelerometer/PX4Gyroscope: integrated data avoid loss of numerical precision 2020-04-26 14:28:50 +02:00
PX4 BuildBot 70329ce396 Update submodule nuttx to latest Sat Apr 25 12:38:14 UTC 2020
- nuttx in PX4/Firmware (2c938af28051250f90baf7c411179b9b01dc5d0c): https://github.com/PX4/NuttX/commit/7fffab1610d2ea08a95383febd0579e0037b6b51
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/66b4f2c4f2128994f8e8a908d4888f6d37565cfd
    - Changes: https://github.com/PX4/NuttX/compare/7fffab1610d2ea08a95383febd0579e0037b6b51...66b4f2c4f2128994f8e8a908d4888f6d37565cfd

    66b4f2c4f2 2020-04-21 Peter van der Perk - [Backport] Added S32K1XX progmem driver to use the FlexNVM memory
1b3fc1c668 2020-04-10 Peter van der Perk - Added net_trylock so we can call can_input while being in a interrupt handler
2020-04-25 09:14:39 -04:00
David Jablonski a0f5002685 navigator: fix loiter_time for FW missions 2020-04-25 09:13:09 -04:00
Roman Dvořák 75fe3bee8c drivers/rpm: add simple RPM message simulator (dummy publisher) 2020-04-25 09:10:11 -04:00
Beat Küng 44537ccd1a sdp3x: reduce verbosity when no device on the bus 2020-04-24 12:59:50 +02:00
Beat Küng d3dd5e9da1 i2c_spi_buses: improve info output for external buses 2020-04-24 12:59:50 +02:00
xdwgood d922678ea0 tailsitter: remove unused code 2020-04-24 13:33:51 +03:00
Daniel Agar 31f3a21849 update ecl/EKF with improved covariance prediction stability and change default IMU integration period 4000 us -> 2500 us
- bring in PX4/ecl#795 "EKF: Improve covariance prediction stability"
    - the ecl/EKF filter update period has changed from 8 ms to 10 ms
 - change default integration period 4000 us -> 2500 us (aligns with new EKF filter update period)
2020-04-23 13:55:34 -04:00
Konstantin Petrykin 5819c82678 vmount: Fixes max AUX number for MNT_MAN_ROLL, MNT_MAN_PITCH and MNT_MAN_YAW parameters. 2020-04-23 08:55:29 +02:00
Silvan Fuhrer 172e435ec0 VTOL: add parameter to set the PWM_OUTPUT_DEVICE_PATH (#14732)
The device path is needed to apply PWM limits on the motors that are not
used for FW flight (switch them off). With this parameter the device path can be set
to either IO or FMU, depending on whether the motors are on the IO or FMU port.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-04-22 20:42:23 +02:00
bresch d29344cb9c MCLandDetector: fix low thrust detection in stabilized mode
HTE runs based on the position controller so, even if we whish to use
the estimate, it is only available in altitude and position modes.
Therefore, we need to always initialize the hoverThrottle using the hover
thrust parameter in case we fly in stabilized
2020-04-22 11:07:04 -04:00
Mathieu Bresciani be2bb4a479 FlightTask: Fix ekf2 reset race condition during task switch (#14692)
* FlightTask: Fix ekf2 reset race condition during task switch

During a loss of GPS data when using GPS as primary height source,
the height is reset to baro and the local position gets invalid at the
same time. This triggers a switch to altitude flight task and a setpoint
reset.
This combination of events had the effect to ignore the height reset,
the large sudden height error could create an abrupt change of altitude
or even a crash.
The ekf2 reset is now done at the beginning of each update call.
2020-04-22 13:18:35 +02:00
Jin Chengde e82880d6d7 add new rotation (#14512)
* add new rotation  ROLL_270_YAW_180

fix compile error

fix rotation

modify roatation

* modify enum to 41
2020-04-22 09:03:55 +02:00
PX4 BuildBot a96bc6a145 Update submodule sitl_gazebo to latest Wed Apr 22 00:38:48 UTC 2020
- sitl_gazebo in PX4/Firmware (c5eefc6b2e): https://github.com/PX4/sitl_gazebo/commit/2f83192e70a590e4af87535b605f7aaa806a52f5
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/c2d7d2609f3801ca9a0a03643942b10da50d090d
    - Changes: https://github.com/PX4/sitl_gazebo/compare/2f83192e70a590e4af87535b605f7aaa806a52f5...c2d7d2609f3801ca9a0a03643942b10da50d090d

    c2d7d26 2020-04-12 JaeyoungLim - Incorporate wind in lift calculation and airspeed measurements (#375)
2020-04-21 22:39:59 -04:00
Daniel Agar b1b54fd4ec Update submodule mavlink v2.0 to latest Wed Apr 22 00:38:54 UTC 2020
- mavlink v2.0 in PX4/Firmware (9686525575a08acccacd15af8d977882d8a88301): https://github.com/mavlink/c_library_v2/commit/0f9e4218df24b9fa0e922307cad68e2d0e18f286
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/c6e18fb3389eb29ee9993829e775a903e003d92a
    - Changes: https://github.com/mavlink/c_library_v2/compare/0f9e4218df24b9fa0e922307cad68e2d0e18f286...c6e18fb3389eb29ee9993829e775a903e003d92a
2020-04-21 22:39:26 -04:00
Daniel Agar c5eefc6b2e new InvenSense ICM20649 IMU driver 2020-04-21 11:25:37 -04:00
Matthias Grob 809b45eac8 FlightTasks: do not adjust tilt limit of the position control
Adjusting the tilt limit can lead to diverging position control
and should only be used by setting a sanity limit for the controller
and not to adjust during the descent phase of a Land or RTL.
Otherwise it leads to flyaways in important failsafe modes when
there's stronger disturbance e.g. wind.
2020-04-21 09:35:52 +02:00
Hamish Willee 95779ea670 ubuntu.sh: No automatic removal of modemmanager 2020-04-21 09:34:05 +02:00
TSC21 c3ebb1a584 px4.py: signal it as being used by the PX4 Homebrew formulae 2020-04-21 09:21:56 +02:00
TSC21 4923e5ce3a px4.py: case the script is run outside of the cloned repo, get it from remote 2020-04-21 09:21:56 +02:00
TSC21 18df0240df px4.py: get release version from Git 2020-04-21 09:21:56 +02:00
Hamish Willee 8236b8da81 Fix up doc links to point to master branch 2020-04-21 08:58:40 +02:00
JaeyoungLim 75054f11df Add px4vision sitl target
- Use px4vision parameters
2020-04-20 18:08:41 -04:00
bresch c05b70bf86 MPC: initialize hover thrust with parameter even if using HTE
The hover thrust estimator (HTE) starts to run after the first thrust
setpoint is published. Until then, the feedforward of the vertical
velocity controller was unitialized (= 0). This is now set to hover
thrust parameter until the estimate is available.
2020-04-20 20:54:31 +02:00
avionicsanonymous c8df77b3d2 UAVCAN Air Data Support 2020-04-20 11:24:24 -04:00
Beat Küng 3177b8d763 fix nuttx submodule: point to px4_firmware_nuttx-8.2 branch 2020-04-20 10:07:45 +02:00
Beat Küng c48c1c4cef Tools/px_uploader: exit if unsuitable board is connected
Avoids endless looping, and is mostly useful when used in automated
upload scripts.
2020-04-20 09:05:57 +02:00
JaeyoungLim 6e18cb85b1 Add plane lidar model
Add model that can test terrain estimated landing
2020-04-19 17:09:42 -04:00
Daniel Agar a3ad710623 restore UAVCAN bootloader support
- essentially reverting #7878 minus the obsolete board support
2020-04-19 16:10:09 -04:00
Todd Colten 7c533e5a53 commander: Clarify airspeed calibration failure warning msg 2020-04-18 13:02:29 -04:00
Matthias Grob ffa9fdbd56 posix rcS: always disable CPU load check 2020-04-17 18:25:07 +02:00
Daniel Agar d96a841050 List: handle re-inserting
- clear sibling on removal
 - add reinsertion test case to test_list
2020-04-17 11:56:24 -04:00
Daniel Agar d6df3036cb tests: IntrusiveQueue test re-insert case
- test for the bug found and fixed in https://github.com/PX4/Firmware/pull/14423
2020-04-17 11:56:24 -04:00
Daniel Agar d9dfedb4f1 drivers/lights: blinkm, rgbled, rgbled_ncp5624c add missing I2CSPIDriver address
- fixes https://github.com/PX4/Firmware/issues/14686
2020-04-17 11:54:22 -04:00
Daniel Agar 2502a7e5df github actions limit bloaty comparisons to new Ubuntu 20.04 containers 2020-04-17 11:46:28 -04:00
flbernier 2fca03e1bd Update default rover parameters Ki and Kd 2020-04-17 08:18:10 +02:00
flbernier 3b0f2a4d43 Swap Ki and Kd in rover related airframes 2020-04-17 08:18:10 +02:00
flbernier 45e88aa8d3 Correct Ki and Kd inversion in rover pid_set_parameters 2020-04-17 08:18:10 +02:00
Daniel Agar 7bbb7e6b24 Jenkins: hardware print more status and cleanup SD card
- /proc meminfo and uptime
 - gps status, ekf2 status, attitude, local position
 - try to force update px4io on a few boards
 - set SDLOG_DIRS_MAX 1 on board cleanup to minimize usage
2020-04-16 16:01:50 -04:00
Beat Küng 4817e299f1 nuttx: update submodule 2020-04-16 14:39:16 -04:00
Matthias Grob 630af7fb58 FlightTaskOffboard: fix header comment 2020-04-16 14:38:32 -04:00
Matthias Grob 8b76c0c023 PreFlightCheck: add checks for CPU and RAM load 2020-04-16 11:45:50 +02:00
Daniel Agar 9ae2f0ea96 bmi160: cleanup 2020-04-15 23:33:41 -04:00
Daniel Agar 06478d9997 delete obsolete SENSORIOCSPOLLRATE/SENSORIOCRESET and systemcmds/config 2020-04-15 23:33:41 -04:00
Daniel Agar 6867947033 irlock: remove ioctl(), read(), and RingBuffer 2020-04-15 23:33:41 -04:00
Daniel Agar 47098f026a bma180: move to PX4Accelerometer and cleanup 2020-04-15 23:33:41 -04:00
Daniel Agar 9f7c3b9f06 sf1xx: move to PX4Rangerfinder and cleanup 2020-04-15 23:33:41 -04:00
Daniel Agar f51715c7ab lps22hb: move to PX4Barometer and cleanup 2020-04-15 23:33:41 -04:00
Daniel Agar 7c7ee115e3 boards: px4_io-v2 defconfig optimizations to save memory
* disable CONFIG_ARMV7M_MEMCPY to save flash
* disable CONFIG_LIB_BOARDCTL
* remove unnecessary pthread and task settings
* reduce preallocated watchdogs
* reduce console buffer size
* reduce IDLE thread stack
* reduce user main stack

Co-Authored-By: David Sidrane <David.Sidrane@Nscdg.com>
2020-04-15 23:17:44 -04:00
mcsauder 6548fde024 Whitespace cleanup to quiet new blank line at EOF git hook. 2020-04-15 23:00:39 -04:00
Daniel Agar 5634b68354 Jenkins: hardware print px4io status, pwm info for all outputs, pwm_out status 2020-04-15 22:48:24 -04:00
Daniel Agar 1ac6230758 boards: always change default IMU_GYRO_RATEMAX on px4_fmu-v2/v3 and mro_x21
- this can lower cpu usage considerably on older boards
2020-04-15 21:52:02 -04:00
Julian Oes d67ecc971c commander: add check for VTOL airfame on fmu-v2 (#14633)
* commander: add check for VTOL airfame on fmu-v2

This adds a preflight check when a VTOL airframe is configured
on a fmu-v2 where VTOL is no longer included.

* commander: address code review comments
2020-04-15 21:20:42 +02:00
Daniel Agar b761060c9b perf counters fix perf free and cleanup naming 2020-04-15 16:22:06 +02:00
Daniel Agar dc2254aa34 WIP: mavlink send hacks 2020-04-15 16:22:06 +02:00
baumanta 050d5de93b add home pos check into global pos check 2020-04-15 11:02:48 +02:00
baumanta 9710289f5f PreFlightCheck: check for RC action switches 2020-04-15 11:02:48 +02:00
Daniel Agar d5e0a52f3f Jenkins: increase history for remaining builds 2020-04-14 19:14:10 -04:00
Julian Oes e2b8fd7b11 commander: fix preflight check spam 2020-04-14 10:17:43 -04:00
Beat Küng 0c5fbf5954 fix param_translation: set address to 0 only on NuttX
On Linux it can be non-zero.
2020-04-14 10:16:01 -04:00
RomanBapst 338dd45022 vtol: do not control deceleration during backtransition manual, acro or stabilized
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-04-14 11:25:09 +02:00
Daniel Agar 588195f46c boards: px4/fmu-v4pro cleanup rc.board_sensors
- board has either an icm20602 or icm20608g, not both
 - probe all typical externally compasses
2020-04-13 15:52:45 -04:00
Daniel Agar aad2856872 tests: microbench uorb add sensor_gyro_fifo copy
- gives an idea of the cost of copying a large message
2020-04-13 14:49:39 -04:00
Daniel Agar 6c1e9c60ed tests: microbenchmarks reduce iterations and sleep inbetween 2020-04-13 14:49:39 -04:00
Daniel Agar 60836eabd5 Jenkins HIL remove px4_fmu-v4_optimized
- this was interesting to monitor, but slows down the entire build with only one pixracer on the test rack
2020-04-13 13:48:28 -04:00
Daniel Agar 66eacd24bc px4_fmu-v5_stackcheck: update stack sizes and add to Jenkins
- increase stack sizes to run cleanly under stackcheck
     - this is likely overkill for most boards, but using stackcheck to set our minimum ensures we have a very safe margin on regular builds and it's something we can currently afford
 - remove holybro_durandal-v1_stackcheck from test rack (there's only one unit)
2020-04-11 21:16:10 -04:00
Daniel Agar 7b4f6b6918 sensors/vehicle_angular_velocity: check filter based on time threshold instead of samples
- fixes #14303
2020-04-11 16:07:11 -04:00
Daniel Agar 276b2cad5a boards: fmu was renamed pwm_out 2020-04-11 14:18:55 -04:00
Daniel Agar 751b3497a0 icm20608g/icm20689: force FIFO count check sooner
The InvenSense icm20608g and icm20689 don't have a FIFO watermark interrupt, but they do have a data ready interrupt and the ability to get the current FIFO count in the same large transfer as the actual FIFO data. So instead of manually checking the FIFO count before every transfer (costs ~ 1-3% cpu) we trust the data ready counts, verify things are in sync after the large transfer (fifo count + fifo contents), and force a manual check before the next transfer if necessary.

As a precaution this change lowers the threshold for forcing a manual FIFO count check before the large transfer. Forcing the check if out of sync by 2 (or more) samples makes sense because we always do transfers in multiples of 2 (gyro samples per accel).

The other small cosmetic changes are keeping the icm20608g and icm20689 in sync (they're nearly identical).
2020-04-11 12:17:40 -04:00
PX4 BuildBot 3a2c4094be Update submodule sitl_gazebo to latest Fri Apr 10 12:39:18 UTC 2020
- sitl_gazebo in PX4/Firmware (ed0c25a562): https://github.com/PX4/sitl_gazebo/commit/e4f6bff206922d8ab85c68ece20c223812979560
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/2f83192e70a590e4af87535b605f7aaa806a52f5
    - Changes: https://github.com/PX4/sitl_gazebo/compare/e4f6bff206922d8ab85c68ece20c223812979560...2f83192e70a590e4af87535b605f7aaa806a52f5

    2f83192 2020-04-09 Ricardo Marques - Remove uuv_hippocampus from uuv_hippocampus world (#455)
bab4880 2020-04-08 JaeyoungLim - Remove boat from boat world (#454)
7cb466c 2020-04-07 JaeyoungLim - Remove rubble and uneven world
a928906 2020-04-02 JaeyoungLim - Fix race condition in gimbal controller
2020-04-10 13:06:01 -04:00
Daniel Agar 322671ea27 mc_pos_control: align updates with ekf2 2020-04-10 13:04:06 -04:00
Julian Oes 474c3c45f0 platforms: don't catch floating point errors
When this triggered it actually just kept printing
"floating point exception" and never recovered. By removing this we can
at least catch it with a core dump, in CI as well as locally.
2020-04-10 14:55:18 +02:00
Julian Oes dc95b4487c workflows: file within docker not accessible
Therefore, let's try with v2-preview.
2020-04-10 14:55:18 +02:00
Julian Oes 4aebf9f02c workflows: upload can't access outside of docker 2020-04-10 14:55:18 +02:00
Julian Oes 14a111f5bd workflows: upload px4 coredump and binary 2020-04-10 14:55:18 +02:00
Julian Oes cc0b834d15 mavsdk_tests: don't fail if DISPLAY is not set 2020-04-10 14:55:18 +02:00
Julian Oes 28ec3744a6 workflows: add core dumps and backtrace to CI 2020-04-10 14:55:18 +02:00
Daniel Agar ed0c25a562 Update submodule mavlink v2.0 to latest Thu Apr 9 20:22:33 UTC 2020
- mavlink v2.0 in PX4/Firmware (bad9b64ca281d2e8c0863738263c75888da63e38): https://github.com/mavlink/c_library_v2/commit/4b493591c4c8125c3592d406197b3b0efbe311af
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/0f9e4218df24b9fa0e922307cad68e2d0e18f286
    - Changes: https://github.com/mavlink/c_library_v2/compare/4b493591c4c8125c3592d406197b3b0efbe311af...0f9e4218df24b9fa0e922307cad68e2d0e18f286

    0f9e4218 2020-04-09 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/d3d37b6ebc02ff434279864a7e146b5cd365a083

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-04-09 17:19:14 -04:00
Daniel Agar b64a5783bb Update submodule NuttX-apps to latest Thu Apr 9 20:22:38 UTC 2020
- NuttX-apps in PX4/Firmware (cf2b0a47ce64ea50e9539689b1b704cd536b9558): https://github.com/PX4/NuttX-apps/commit/91b6ad6a0d00ac107088b18588cd54d40e3cb796
    - NuttX-apps current upstream: https://github.com/PX4/NuttX-apps/commit/95e105548a2037f42bf2f13b214ae083b921ff03
    - Changes: https://github.com/PX4/NuttX-apps/compare/91b6ad6a0d00ac107088b18588cd54d40e3cb796...95e105548a2037f42bf2f13b214ae083b921ff03

95e10554 2020-03-30 Peter van der Perk - [Backport] Add CONFIG_NET_CAN support to netinit.c
e17eeb31 2020-03-28 Peter van der Perk - [Backport] netutils SocketCAN suport & candump, cansend tool
2020-04-09 17:18:33 -04:00
Daniel Agar 55fc0cbdc7 boards/px4/fmu-v4: fix internal hmc5883 start 2020-04-09 15:54:10 -04:00
Matthias Grob 38093e4887 mc_pos_control: correct sign of acceleration state
Non-functional change, just change the sign in the correct place to
avoid further confusion.
2020-04-09 17:15:46 +02:00
Daniel Agar 74e99faedf imu/invensense: minor cleanup
- remove leftover Start()
 - remove "reset" from command line (stop + start is sufficient)
2020-04-09 09:47:30 -04:00
Beat Küng 8338f4e543 uvify/core: enable tx dma on telem2 2020-04-09 14:59:28 +02:00
Beat Küng 31937c280d px4/v4: enable tx dma on telem2 2020-04-09 14:59:28 +02:00
Beat Küng cbed023334 px4/v{2,3}: enable tx dma on telem2 2020-04-09 14:59:28 +02:00
Beat Küng 68e1172bb5 px4/v5x: enable tx dma on telem2 2020-04-09 14:59:28 +02:00
baumanta 8b89cfc498 change RC action switch thresholds 2020-04-09 14:41:09 +02:00
Hamish Willee 0a2c48c69a airframe markdown script: Improve header text. 2020-04-09 08:21:25 +02:00
daniele 38e635e386 navigator_main: allow altitude change when the current lat and lon are still nan
This is a corner case that happens when the user wants to command an
altitude change just after a takeoff. Takeoff doesn't set the current
lat and lon therefore the user had to change altitude twice to get it working.
The first time to set the current lat and lon and the second time to
actually change altitude.
2020-04-08 21:16:31 -04:00
daniele 6ea60b5165 geofence: reposition to current location when violating geofence in hold mode
This can only happen if the vehicle is executing a go to.
2020-04-08 21:16:31 -04:00
daniele d53dccc319 reposition (goto): add check if goto location is outside the geofence
Before this check we were free to fly outside of a geofence with a goto
command. With this check we ignore the command if the location of the goto
is outside the fence. If this is the case we send back a mavlink warning to
the ground station.
2020-04-08 21:16:31 -04:00
daniele 6b97361c92 add dummy if statement to avoid messing up the pr review 2020-04-08 21:16:31 -04:00
Silvan Fuhrer 4e3f65e376 disable spinup tilt sequence if spinup tilt parameter is set to 0
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-04-08 21:12:53 -04:00
Silvan 7e4a53f292 VTOL tiltrotor: introduce spin up time with spin up tilt angle
As some tiltrotor systems need a certain tilt angle of their motors in oder to spin up freely,
this commit introduces an additional parameter VT_TILT_SPINUP and sets the motor tilt to
this value if disarmed or within 1s since arming.

The spinup consists of 2 phases:
    1st phase fixed tilt (duration hardcoded to 1s)
    2nd phase transition from spinup tilt to multicopter tilt (hardcoded to 0.5s)

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-04-08 21:12:53 -04:00
Daniel Agar 746b3124ab Update submodule matrix to latest Wed Apr 8 12:39:43 UTC 2020
- matrix in PX4/Firmware (222e0636c4b53ea18013f2bf0d35a798fab6ae76): https://github.com/PX4/Matrix/commit/a32892926c69ea0bad031fd9d7bfc915cc5e9b68
    - matrix current upstream: https://github.com/PX4/Matrix/commit/d613055462bcbeacfd188cbd53de56c1dbc7b94d
    - Changes: https://github.com/PX4/Matrix/compare/a32892926c69ea0bad031fd9d7bfc915cc5e9b68...d613055462bcbeacfd188cbd53de56c1dbc7b94d

d613055 2020-04-06 kamilritz - Add more assignment operators for slices
976ada4 2020-03-21 Matthias Grob - Matrix: min max comments and test style
fa7153e 2020-03-21 Matthias Grob - Matrix: omit min max nan case with same result
2020-04-08 16:25:00 -04:00
Beat Küng c713ce721e KakuteF7: enable SPI DMA for SPI 4
DMA for SPI 1 left disabled because the SD card does not work when enabling
it.
2020-04-08 15:31:51 -04:00
Lorenz Meier 18e78261ab Commander: Add more documentation around USB reboots
If the user disconnects USB we reboot the system to bring it back into a nominal condition before arming. Otherwise we would either have the USB stack running without a cable connected (code running for no reason, which is violating the principle of not running unnecessary code in aviation). Or we would not allow to arm at all if USB was ever connected, which can be confusing if the system is powered off a battery.
2020-04-08 14:11:09 -04:00
Daniel Agar a89bba470a boards: STM32F76xxx/STM32F77xxx linker add ITCM RAM and .ramfuncs handling
- this doesn't currently change anything, but gets us ready to start
experimenting with using the small amount of instruction tightly memory
on STM32F7
 - the .ramfuncs section works with NuttX CONFIG_ARCH_RAMFUNCS
2020-04-08 13:20:54 -04:00
Matthias Grob c9e64988b9 GPS Dynamic model default <1g
Only have it higher for VTOL and fixed wing.
Multicopter position controlled flight is in our experience always <1g.
Acrobatic flying definitely exceeds the acceleration but if control
doesn't rely on the GPS velocity and position there shouldn't be any
problem.
2020-04-08 11:52:38 -04:00
Nico van Duijn 59bd3e9f6e Change defaults for MPC_LAND_ALT 2020-04-08 11:52:01 -04:00
Nico van Duijn df07eed1a4 PX4Vision: tune MPC_LAND_ALT 2020-04-08 11:52:01 -04:00
Julian Oes 9764c32b55 mavsdk_tests: only apply workaround in GitHub CI 2020-04-08 16:56:52 +02:00
Julian Oes 54fe3c5fd5 mavsdk_tests: remove waitforgz helper, add sleep
This is an attempt to workaround the gz spawn timeout in CI.
Let's just hard-code a sleep before spawning the model.
2020-04-08 16:56:52 +02:00
Matthias Grob 0a7cde4819 arch.sh: use binary repository for gazebo
This makes installation a lot faster and less error prone.
2020-04-08 16:33:49 +02:00
Beat Küng 6b0a2649c0 commander: set home position on takeoff
instead of when arming and on takeoff.

It is set on the first takeoff or if there was a disarm event between the
last and the current takeoff.
2020-04-08 14:59:26 +02:00
Beat Küng 80f0892de5 fix commander: set _was_landed before _land_detector topic update
Before _was_landed was set to the same value as the current
_land_detector.landed, thus outside of the update condition,
_was_landed && !_land_detector.landed could never be true.

This affects setting the home position, which is now set upon arming AND
upon takeoff.
2020-04-08 14:59:26 +02:00
Beat Küng aa6f9280e1 fix commander: set _have_taken_off_since_arming when !landed upon arming
If arming and already !landed, _have_taken_off_since_arming will not be set
and thus auto-disarm after 10s will be triggered (with default config).

This can only happen due to quick state changes, as land detector generally
sets landed=true if !armed.
2020-04-08 14:59:26 +02:00
baumanta 8709fc3cf9 fix SITL attctl test for less drag 2020-04-08 10:39:56 +02:00
baumanta 0d8c011d91 update sitl_gazebo to include realistic iris drag coeff 2020-04-08 10:39:56 +02:00
Daniel Agar cf37be8c44 ekf2 handle accelerometer clipping
- track clipping per IMU axis and pass through to ecl/EKF
 - update ecl/EKF to include delta velocity clipping changes (PX4/ecl#663)
2020-04-07 20:11:08 -04:00
JacobCrabill 74aa3201ce uavcannode: Fix Kelvin/Celcius in RawAirData pub 2020-04-07 18:31:10 +02:00
TSC21 4f718086ea microRTPS: fix topic name when ROS2 is not being used 2020-04-07 16:34:30 +01:00
Beat Küng 4e0441ab0b logger: add data format version tag 2020-04-07 09:59:12 -04:00
Daniel Agar 7aa7f0ed95 switch remaining boards to new InvenSense IMU drivers 2020-04-07 09:59:12 -04:00
Julien Lecoeur 7b12a21565 mavlink: Enable offboard attitude for coaxial airframes 2020-04-07 09:23:03 -04:00
PX4 BuildBot 3d27c7313c Update submodule nuttx to latest Tue Apr 7 03:33:04 UTC 2020
- nuttx in PX4/Firmware (3cee71918ad35d155fcdd5f32770dad98619eb84): https://github.com/PX4/NuttX/commit/09f0aee3520ae69eb57aa9e7f41e9d17dc3a9045
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/ec417d7466666801e911e50d72766225ca7790a1
    - Changes: https://github.com/PX4/NuttX/compare/09f0aee3520ae69eb57aa9e7f41e9d17dc3a9045...ec417d7466666801e911e50d72766225ca7790a1

    ec417d7466 2020-04-06 Peter van der Perk - [Backport] FMUK66 SocketCAN driver & Configurable Bitrate support
a3132cf3b7 2020-03-30 Peter van der Perk - [Backport] SocketCAN support
2020-04-07 00:16:52 -04:00
Jacob Dahl d682ddb510 UAVCAN differential pressure sensor support
* added airspeed handling (differential pressure) to uavcan and uavcannode

Co-authored-by: Jacob Crabill <jacob@flyvoly.com>
2020-04-07 00:15:31 -04:00
Daniel Agar a67847aef1 Update submodule mavlink v2.0 to latest Tue Apr 7 03:32:57 UTC 2020
- mavlink v2.0 in PX4/Firmware (8eaf36226f125d8b577a1a9c4d6c6f6985a95210): https://github.com/mavlink/c_library_v2/commit/11589a51bec0e96ffe80366c387997f7c44cffa3
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/4b493591c4c8125c3592d406197b3b0efbe311af
    - Changes: https://github.com/mavlink/c_library_v2/compare/11589a51bec0e96ffe80366c387997f7c44cffa3...4b493591c4c8125c3592d406197b3b0efbe311af
2020-04-07 00:12:36 -04:00
Daniel Agar ff74a2a48b new mpu6000/mpu6500/mpu9250 always schedule backup cycle if using data ready 2020-04-06 23:32:04 -04:00
Daniel Agar 0860a61fa6 new InvenSense IMU drivers review temperature sensitivities and offsets 2020-04-06 22:53:16 -04:00
Daniel Agar da383064c6 NuttX update with STM32H7 SPI DMA support
- holybro durdandal enable SPI DMA
2020-04-06 22:08:45 -04:00
AlexKlimaj d8c140be04 UAVCAN Smart Battery Improvements 2020-04-06 21:09:02 -04:00
Beat Küng 08bfeb3dc7 mavlink: fix potential busy loop upon USB disconnect
When disconnecting USB poll returns successfully, but the read returns
-1 with ENOTCONN.
In addition this also ensures there's no busy loop when poll returns an
error.

MAVLink continues to work after reconnecting USB.
2020-04-06 12:42:10 -04:00
Claudio Micheli 4cdc58ce8d EscBattery: only publish data if all the ESCs are online
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2020-04-06 15:56:54 +02:00
Julian Oes c1884975ed esc_battery: several review fixes
Thanks @bkueng.
2020-04-06 15:56:54 +02:00
Julian Oes 5927bb3635 battery: add requirements to ESCs as battery 2020-04-06 15:56:54 +02:00
Julian Oes cafd52647c msg: fix battery source enum 2020-04-06 15:56:54 +02:00
Julian Oes ae219c3272 esc_battery: fix timeout check 2020-04-06 15:56:54 +02:00
Julian Oes f650b91718 battery: check source param inside battery lib
This moves the handling of the BAT%d_SOURCE param inside of the battery
library. Users of the library now pass the source instead of the flag
whether to publish. The battery library then checks if the source is
selected using the param and publishes accordingly.

Since we removed the strange system_source flag, we now need to look at
all batteries in commander.
For current estimation - I think - it makes sense to sum them up.
2020-04-06 15:56:54 +02:00
Julian Oes 641612468b ROMFS: start esc_battery if param is set 2020-04-06 15:56:54 +02:00
Julian Oes b01cdafcf6 boards: add esc_battery to build 2020-04-06 15:56:54 +02:00
Julian Oes 509b8b6b4b First skeleton for esc_battery module 2020-04-06 15:56:54 +02:00
Julian Oes dcd34ed08d battery: add ESCs source, remove wrong unit 2020-04-06 15:56:54 +02:00
Julian Oes 5beb293a6a msg: fix typo 2020-04-06 15:56:54 +02:00
Daniel Agar ad559a66a1 examples: add simple work_item example module 2020-04-06 09:43:55 -04:00
Daniel Agar 1d164c0dbd px4_work_queue: sem_wait add loop as the wait may be interrupted by a signal 2020-04-06 10:30:35 +02:00
Julian Kent 9404b19906 Fix bezier scaling 2020-04-06 09:02:12 +02:00
David Sidrane 025799248c holybro_durandal-v1:Ensure SDMMC power seqensing is clean 2020-04-04 09:39:53 -04:00
stmoon 9a0c50325b remove exception in case that ROS is not installed 2020-04-04 08:20:35 +01:00
stmoon aaa72b2a25 change how to get ros2 version 2020-04-04 08:20:35 +01:00
Hyon Lim 5f86ea71bc UVify bootloader was not recognized properly because of wildcard string format in upload.sh.
It has more generalized to recognize UVify bootloader properly.
2020-04-03 13:18:31 -04:00
TSC21 144c65c92f microRTPS: only use '-typeros2' FastRTPSGen option for Dashing and later ROS2 distros 2020-04-03 18:03:26 +01:00
Julian Oes e34b452bab setup: only run usermod if $USER is available
This always triggered an error when using in docker as root.
2020-04-03 10:10:02 -04:00
Julian Oes be9f125c3d mavsdk_tests: raise timeout for czspawn
And provide better output about what happened.
2020-04-03 11:45:35 +02:00
Julian Oes 9c04f66f06 mavsdk_tests: raise overall timeouts
This might prevent some false positives when CI is running slowly or
intermittently.
2020-04-03 11:45:35 +02:00
Julian Oes 28f4dc10ae mavsdk_tests: make sure all log output is printed
This fixes the issue where the last lines of the log output was not
printed in case of error or on the verbose setting. This meant that
essentially the actual test error was not printed.

The fix involves two parts:
1. Firstly collect the output again even if a process has exited.
2. Collect all lines at once and not one line per iteration.
2020-04-03 11:45:35 +02:00
Claudio Micheli dc29a994b7 msg: extend field definition in msg/esc_report (arming & failure states)
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2020-04-03 09:16:43 +02:00
Julian Oes 4e091a369d uavcannode: fix format 2020-04-03 09:08:33 +02:00
Jacob Dahl ff1e5a595d uavcannode: battery info publishing 2020-04-03 01:30:31 -04:00
RomanBapst 0d8d4cd6e0 SITL configs: improve L1 tracking and increase backtransition duration
-decrease L1 period for tighter mission tracking in fw mode
- increase backtransition duration, we can now do this is we have active
deceleration control

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-04-02 23:54:48 -04:00
Daniel Agar 40b1043e12 NuttX boards minor lpwork and init stack increases 2020-04-02 23:39:17 -04:00
Beat Küng dfb5b5d7d9 fix param import transition
* fix param import transition for MC_DTERM_CUTOFF

The previous implementation did not work, as there was a check for
param_find_no_notification() returning PARAM_INVALID for IMU_DGYRO_CUTOFF,
and therefore would not call param_modify_on_import().

This moves param_modify_on_import() before the check and makes it modify
the bson node directly.

* parameters: fix param import transition when testing is enabled

BUILD_TESTING is used for unit test builds, PX4_TESTING is used to enable additional test material within PX4

Co-authored-by: Daniel Agar <daniel@agar.ca>
2020-04-02 18:41:00 -04:00
Matthias Grob 2baa5ca4d7 minor build fixes and ignored warnings for GCC 9 (#14159)
- px4io task_main_trampoline add return
 - iridiumsbd main_loop_helper add return
 - drivers/uavcan ignore Wcast-align, Wdeprecated-copy, and Waddress-of-packed-member for now
 - flashparams ignore Wvla-larger-than
 - test_time fix printf type
2020-04-02 10:24:36 -04:00
TSC21 e9aba642fe CI: bump container tags to 2020-04-01 2020-04-02 14:28:38 +01:00
TSC21 2020b77a43 microRTPS: use FastRTPSGen '-typeros2' option to generate the typenaming required to interface the bridge with ROS2 topics 2020-04-02 14:28:38 +01:00
Matthias Grob ab6606aa46 PreFlightCheck: fix magnometer typo 2020-04-02 13:53:47 +02:00
RomanBapst 2522435f9c vtol_att_control: got rid of VT_B_DEC_SP
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-04-02 13:45:52 +03:00
Roman Bapst 47f0e91076 Apply suggestions from code review
Co-Authored-By: Mathieu Bresciani <brescianimathieu@gmail.com>
2020-04-02 13:45:52 +03:00
RomanBapst 005bc97959 tiltrotor: enable l1 and deceleration control during transition
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-04-02 13:45:52 +03:00
RomanBapst a916cc2a26 better comments
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-04-02 13:45:52 +03:00
RomanBapst 0184d8196f vtol_type: calculate backtransition acceleration in forward direction
- use track angle to calculate the current forward acceleration

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-04-02 13:45:52 +03:00
RomanBapst 47b5d51369 vtol_type: added explicit control over deceleration during backtransition
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-04-02 13:45:52 +03:00
RomanBapst baf5e86f81 transition flighttask: don't control yaw and altitude during trans
Signed-off-by: RomanBapst <bapstroman@gmail.com>

# Conflicts:
#	src/lib/flight_tasks/tasks/Transition/FlightTaskTransition.cpp
2020-04-02 13:45:52 +03:00
RomanBapst b6a80253d7 run l1 during transition 2020-04-02 13:45:52 +03:00
Beat Küng 1f60a86d32 fix commander: need to copy all battery states in a cycle
Previously if in a cycle only a disconnected battery status updated, the
battery health state would switch to unhealthy during that time.

Fixes intermittent 'Arming denied! Check battery' preflight failures on
v5x with 1 power module connected.
2020-04-02 12:42:00 +02:00
Matthias Grob 70c28c7274 mc_pos_control_params: update MPC_POS_MODE description
- remove deprecated sport mode
- clarify wording
2020-04-02 11:52:44 +02:00
Daniel Agar 15332a7e56 boards: reduce CONFIG_NFILE_DESCRIPTORS 20 -> 15 2020-04-01 16:17:14 -04:00
Daniel Agar aa2f3a6624 sensors: complete move to uORB::Subscription 2020-04-01 16:17:14 -04:00
Daniel Agar 7c8ab49eb9 boards: mro_ctrl-zero-f7 fix i2c
- STM32_HSI_FREQUENCY 24 MHz -> 16 MHz (required for NuttX stm32f7 i2c)
2020-04-01 14:27:33 -04:00
Daniel Agar 02f4ad61ec I2C/SPI require device type in constructor 2020-04-01 12:24:22 -04:00
Daniel Agar 04bf9afd1b CDev delete unused pub_blocked 2020-04-01 11:23:26 -04:00
Daniel Agar b3fe235129 drv_mag: delete unused MAGIOCSRANGE, MAGIOCCALIBRATE, MAGIOCEXSTRAP, MAGIOCSTEMPCOMP 2020-04-01 10:07:08 -04:00
Daniel Agar cfc087c6ad rm3100: move to PX4Magnetometer and cleanup 2020-04-01 10:07:08 -04:00
Daniel Agar a59aa865da qmc5883: move to PX4Magnetometer and cleanup 2020-04-01 10:07:08 -04:00
Daniel Agar ade52d612b lsm9ds1_mag: minor cleanup 2020-04-01 10:07:08 -04:00
Daniel Agar c9c08d00c3 lsm303agr: move to PX4Magnetometer and cleanup 2020-04-01 10:07:08 -04:00
Daniel Agar 5f6f1c554b lis3mdl: move to PX4Magnetometer and cleanup 2020-04-01 10:07:08 -04:00
Daniel Agar cf12969a29 ist8310: move to PX4Magnetometer and cleanup 2020-04-01 10:07:08 -04:00
Daniel Agar 1c333cb664 isentek/ist8308: minor cleanup 2020-04-01 10:07:08 -04:00
Daniel Agar 7e173048bb ak09916: minor cleanup 2020-04-01 10:07:08 -04:00
Daniel Agar 613168b598 hmc5883: move to PX4Magnetometer and cleanup 2020-04-01 10:07:08 -04:00
Daniel Agar 9899748d12 bmm150: move to PX4Magnetometer and cleanup 2020-04-01 10:07:08 -04:00
Daniel Agar 09ba9d62eb PX4Magnetometer: add external() getter and default temperature to NAN 2020-04-01 10:07:08 -04:00
Daniel Agar 1cc8e4dc1a distance_sensor/vl53l0x: move to PX4Rangefinder and cleanup 2020-04-01 10:06:08 -04:00
bresch 3f15ccd2dd Update ECL
Add "Fly without magnetometer" and some interface changes
2020-04-01 11:47:39 +02:00
kamilritz a70aa6349a ECL interface: output vector quantities by return-by-value 2020-04-01 11:47:39 +02:00
Julian Oes 07d172dc9c tools: present nicer error for missing packaging
This makes the error more user friendly and suggests what to do to fix
it.
2020-04-01 10:42:18 +01:00
Daniel Agar baa50a1985 boards: omnibus/f4sd add board_dma_map.h 2020-04-01 10:42:09 +02:00
Daniel Agar 2e2b9a97d3 pwm_out: delete fake() test command
- we have better motor test facilities these days
2020-03-31 19:12:31 -04:00
Daniel Agar ca81175b07 rename drivers/px4fmu -> drivers/pwm_out
- split out header
2020-03-31 19:12:31 -04:00
Hyon Lim 3bcd8c63f8 SMBus battery (a.k.a. smart battery) enhancement. (#14496)
* Enhancement: State of health, and max_error value is added. Both shows battery health of SMBUS smart battery.
 * Enhancement: BAT_C_MULT parameter is introduced. This is for high-current capable SMBUS-based battery.
As SMBUS only provides 16-bit for current, it could only be +-32768mA which is about +-32A.
But with proper treatment, it could be extended with little accuracy loss.
This factor can be set for individual battery system with available information.
    * Relative SOC introduced. Proper SMBUS battery should provide percentage of remaining battery
directly. Therefore it does not have to be computed like before.
    * State of Health introduced. Proper SMBUS battery should provide SOH value.
    * Max error: this shows estimation error of BMS.
 * Enhancement: With smart battery, precise estimation of time remaining is provided
with impedance track. It is unit of minute, so 60 seconds multiplied.
Update rate of this is not fast, but very useful.

Co-authored-by: Hyon Lim <lim@uvify.com>
2020-03-31 17:28:22 -04:00
Daniel Agar 39b47e63b5 boards: airmind mindpx-v2 switch to new mpu6000 and mpu6500 drivers 2020-03-31 16:28:45 -04:00
Daniel Agar 2b82b471c1 sensor_accel_fifo increase to 32 samples 2020-03-31 13:26:50 -04:00
Julian Oes 2a37321293 mavsdk_tests: wait a bit longer for gazebo command
Otherwise this triggers in CI sometimes.
2020-03-31 14:37:37 +02:00
Julian Oes 0edc2aa334 mavsdk_tests: don't stall on timeout 2020-03-31 14:37:37 +02:00
Silvan Fuhrer 477092fa24 Fw pos control move to local pos: minimal changes to make it compile
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-03-31 15:03:23 +03:00
Daniel Agar 59a7262c31 FW use lpos 2020-03-31 15:03:23 +03:00
David Jablonski d303b73bc3 respected reviewer comments 2020-03-31 09:23:52 +02:00
David Jablonski 12687f7d8f use memcpy instead of strncpy 2020-03-31 09:23:52 +02:00
David Jablonski a0bf7425ae Implemented multipart status message 2020-03-31 09:23:52 +02:00
Matthias Grob 49d22edc33 battery: cell voltage fill refactor 2020-03-31 09:14:50 +02:00
Timothy Scott 14a61a6695 Fixed reporting of battery voltages in uORB 2020-03-31 09:14:50 +02:00
Hamish Willee d609639367 roboclaw: Link to user manual updated 2020-03-31 08:36:38 +02:00
JacobCrabill 46aab317d5 uavcan: bug fix sensor bridge init failure
Fixes case where a UAVCAN SensorBridge has callback channels available,
but NuttX / uORB does not have an additional driver / topic instance
available.
2020-03-30 22:44:25 -04:00
mohammad 531efc2d53 mavlink: add ACTUATOR_CONTROL_TARGET1 to stream list
- closes https://github.com/PX4/Firmware/issues/14369
2020-03-30 18:33:34 -04:00
Beat Küng a556a44a57 i2c_spi_buses: print an error if a driver does not pass the I2C address 2020-03-30 15:55:24 -04:00
Beat Küng 82c7908a2d fix ist8310: pass I2C address to I2CSPIDriver
since it is configurable.
2020-03-30 15:55:24 -04:00
Beat Küng cc6ae7ad41 fix omnibus/f4sd: bmp280 start 2020-03-30 15:52:41 -04:00
Beat Küng fc3b497b41 omnibus/f4sd: switch over mpu6000 driver
I'm seeing 'mpu6000: FIFO empty: 49 events' increasing, but that is
epxected as there's no DRDY.
2020-03-30 15:52:41 -04:00
TSC21 1f90a65265 update submodule micro-CDR 2020-03-30 20:02:35 +01:00
Roman Dvořák b02e209507 Remove duplicite data from RPM message and enable logging of RPM message 2020-03-30 13:08:53 -04:00
David Jablonski 536cd6cb1a allow DO_CONTROL_VIDEO in missions 2020-03-30 17:10:36 +02:00
David Jablonski 6bd191a24e Mavlink: Implemented SET_CAMERA_ZOOM 2020-03-30 17:10:36 +02:00
TSC21 73f7243bc8 add links on tokens for the Github Actions pages 2020-03-30 14:59:53 +01:00
Daniel Agar a38d4192ab boards: airmind mindpx-v2 fix L3GD20 DRDY pin 2020-03-30 09:21:00 -04:00
TSC21 a71df40a8e Github Actions: update workflow naming 2020-03-30 13:56:42 +01:00
TSC21 f52739cc09 add Github Actions build status token to Nuttx targets and SITL Tests 2020-03-30 13:56:42 +01:00
TSC21 5b03f80376 Github Actions: improve the container matrix usage 2020-03-30 09:51:57 +01:00
TSC21 40a99f940a bump container tags to 2020-03-29 2020-03-30 09:51:57 +01:00
TSC21 43440b9797 ci: github: sitl_tests: add matrix for parallel build in Ubuntu Bionic and Focal 2020-03-30 09:51:57 +01:00
TSC21 ad143f5801 ci: github: bloaty: add matrix for parallel build in Ubuntu Bionic and Focal 2020-03-30 09:51:57 +01:00
TSC21 92e0a301ba ci: github: build_tests: add matrix for parallel build in Ubuntu Bionic and Focal 2020-03-30 09:51:57 +01:00
TSC21 cdbdb2f72c ci: github: ccpp: use 'matrix' to set the containers to run 2020-03-30 09:51:57 +01:00
TSC21 947219db7f ci: github: ccpp: add Ubuntu Focal build job 2020-03-30 09:51:57 +01:00
Matthias Grob bda072512a rc.vtol_defaults: reduce maximum jerk to 4.5 m/s³ based on testing feedback
@fury1895 reported very valuable feedback from testing
the acceleration feed-forward on VTOL:
> MPC_JERK_MAX 4.5 (from 5 on it felt too aggressive)
> MPC_JERK_AUTO 4
> some hovering, some transitions, and a mission. Everything good.
> I'd say you feel the difference in position mode and you see it in
> Auto modes. Great improvement!
2020-03-30 09:58:39 +02:00
Matthias Grob f6ceb08522 FlightTaskTransition: don't overwrite setpoints with estimates
Previously acceleration setpoints were not executed and just used
to pass a possible rough initialization value for the next task. Now
they get executed by the multicopter controller and hence
overwriting them with rough estimates doesn't work anymore.
2020-03-30 09:58:39 +02:00
Matthias Grob 58fd3e2ddc PositionControl: fix horizontal integral anti-windup 2020-03-30 09:58:39 +02:00
Matthias Grob 91057fe024 FlighTasks: remove FlightTaskSport
This mode was just kept as an example after
its usage in a single case. It's basically untested
and doesn't make much sense anymore since it's
incompatible with the jerk limited trajectory
implementations. It's implementation only switched
hte configuration parameter of the velocity resulting
from maximum stick deflection to be
MPC_XY_VEL_MAX instead of MPC_VEL_MANUAL.
This is according to todays understanding undesired
because when hitting that limit the position
controller has no room for corrections anymore.

Also it saves some flash space on omnibus to remove
the task at this point and makes romm for the
acceleration feed-forward.
2020-03-30 09:58:39 +02:00
Matthias Grob bc2579f3be mc_pos_control_params: lower jerk configuration
because of tighter tracking with acceleration feed-forward.
2020-03-30 09:58:39 +02:00
Matthias Grob b79b095ce7 FlightTasks: adapt to acceleration based control 2020-03-30 09:58:39 +02:00
Matthias Grob b3d7445059 PositionControl: acceleration based control strategy 2020-03-30 09:58:39 +02:00
Matthias Grob 1d2ac41edc ControlMath: adding limitTilt() helper function
which takes care of limiting the lilt angle of a "body" vector with
respect to a "world" vector. Both vectors have to be unit length!
2020-03-30 09:58:39 +02:00
Matthias Grob aa53cabaa4 PositionControl: remove confusing uMin uMax alias 2020-03-30 09:58:39 +02:00
JaeyoungLim a938410c15 Add world targets and update submodules
Add world names as make targets and include the worlds by updating the submodules
2020-03-29 13:29:07 +01:00
Matthias Grob 6602e8d16b Support python3 only systems
Ubuntu 20.04 and latest Cygwin come with no Python 2 and no link
from python to python3. To not mess with the system we detect
python3 for seamless support.
2020-03-28 17:02:24 +00:00
Matthias Grob b8576cccc8 AttitudeControlTest: add scale testing for yaw weight 2020-03-28 17:51:59 +01:00
Matthias Grob 96bbc63eb1 AttitudeControl: let the user set yaw weight directly via parameter
instead of infering the yaw weight from the gains which can lead to
unexpected results depending on the particular vehicle tuning.
2020-03-28 17:51:59 +01:00
user.name 5b28847ecc Tracking commit in libuavcan submodule to set submodule branch to legacy-v0 2020-03-28 11:39:59 -04:00
Peter van der Perk 9490f41f85 rddrone-uavcan146 removed shared clock between hrt & rtc
Removed non-existing SW2 button
Fixed SW3 button pinmux
Added FlexCAN pin definition
hrt use external sirc clock
rtc use 32khz lpo clock
2020-03-28 06:31:11 -07:00
Hyon Lim eb1bad0185 A comment is added for TFmini valid minimum parameter. 2020-03-27 09:59:05 -04:00
Hyon Lim 7e7506ec52 Enhancement: 0.3 for TFMini was too low, as TFmini outputs slightly more than 0.3 when it is very near to the ground.
This cause EKF not fallback to barometer in worst case.
2020-03-27 09:59:05 -04:00
Beat Küng e5dd2e7a19 mag_compensation.py: some minor fixes + indentation 2020-03-27 11:07:50 +01:00
Dusan Zivkovic 26a8707298 flight task auto: set acceptance radius when setting loiter as a responce to invalid setpoint 2020-03-26 21:02:20 +01:00
Daniel Agar 28dc225015 add SENS_EN_PAW3902 to start paw3902 optical flow sensor 2020-03-26 13:08:59 -04:00
Beat Küng 2b360bfd48 rcS: fixes for SYS_USE_IO=0
rc.io is called from 2 places in rc.interface:
- if [ $OUTPUT_MODE = io -o $OUTPUT_MODE = uavcan_esc ]:
  - 'set OUTPUT_MODE io' is only set within USE_IO=yes, so removing
    the check in rc.io has no effect.
  - in case of UAVCAN, we also want the IO for RC, now covered in the next
    case.
- Further down ('Start IO for RC input if needed.').
  This is intended to start IO for RC only, when fmu is already started.
  However the previous check '$USE_IO = yes' in rc.io prevented that.

In addition we don't start rc_input in case of $USE_IO = no.

Fixes no RC on Pixhawk 2 with SYS_USE_IO=0.
2020-03-26 10:33:27 -04:00
Julian Oes b895a356aa cmake: fix warning
When not building for testing, test_mixer_multirotor is not available
and causes a waraning with cmake 3.17:

  This project specifies custom command DEPENDS on files in the build tree
  that are not specified as the OUTPUT or BYPRODUCTS of any
  add_custom_command or add_custom_target:

   test_mixer_multirotor
2020-03-26 14:32:03 +01:00
Travis Bottalico e898b7f110 - Remove RC_SERIAL_SINGLEWIRE, this broke Spektrum radio on last commit
- set FSYNC INT pins to 0 to be safe
2020-03-26 13:54:12 +01:00
Anurag Sai Vempati bcfe56b297 replay: apply replay module params before starting ekf2 (#14478) 2020-03-26 10:02:15 +01:00
bresch dc38930bb2 AutoSmoothVel: desynchronize XY from Z for small changes in speed
This fixes the issue that makes the drone slow-down even in straight
lines due to the Z component being constrained to a really small value
2020-03-26 08:31:09 +01:00
baumanta 2103b8f7de fmu-v5_optimized: disable esc_calib 2020-03-26 08:00:30 +01:00
baumanta 7fd77fedaa add python script for offline param identification 2020-03-26 08:00:30 +01:00
baumanta 22ceeccc26 add library for current- or thrust-based mag compensation 2020-03-26 08:00:30 +01:00
Daniel Agar 44bec269b0 boards: update all NuttX configs CONFIG_NSH_MAXARGUMENTS 12 -> 15 2020-03-25 17:59:22 -04:00
Peter van der Perk a4e6f96365 rddrone-uavcan146: HRT & RTC timer support 2020-03-25 16:37:28 -04:00
Dusan Zivkovic 3d44077f2c camera_trigger: lower the polling rate from 200Hz to 20Hz to reduce the CPU load 2020-03-25 16:23:11 -04:00
Hyon Lim 2b54e19adf Script: As recent driver refactoring checkes start argument first, we change script accordingly. 2020-03-25 16:16:45 -04:00
Hyon Lim fd0ea29fc6 Board support: UVify Core. As Core is not using SPI4 as external, SPI4 external interface related code removed.
Also, PMW3901 flow sensor is added on SPI2 bus.
2020-03-25 16:16:45 -04:00
Hyon Lim 0b3624ab5f To make UVify device compatible with upload script, we changed device name to be more generalized. 2020-03-25 16:16:45 -04:00
Hyon Lim 1161dac875 Script update: PMW3901 driver argument has changed. so we change scripts and SPI interface. 2020-03-25 16:16:45 -04:00
Hyon Lim e8f0c8e239 NSH argument stack increased. Specific MAVLink configuration requires more than 12 parameters. 2020-03-25 16:16:45 -04:00
Hyon Lim afcf0960df IFO-S RGB LED app setting has been changed. 2020-03-25 16:16:45 -04:00
Hyon Lim 1a23b7c609 IFO-S parameter updated. 2020-03-25 16:16:45 -04:00
Hyon Lim 15f997d337 Airframe: IFO-S setup is added. 2020-03-25 16:16:45 -04:00
JacobCrabill f0dde45303 BMI055: Bug fix scheduling interval. 2020-03-25 10:25:59 +01:00
JacobCrabill a645822ac6 BMI088: Bug fix scheduling interval. 2020-03-25 10:25:59 +01:00
Hamish Willee 1288db9314 ekf2_params.c: EKF2_MAG_TYPE: Info about yaw without mag 2020-03-25 09:41:54 +01:00
Daniel Agar efceccd91d posix: micro_hal.h add empty px4_arch_gpiosetevent to build new Invensense drivers on linux 2020-03-25 01:05:38 -04:00
Daniel Agar 404e781cd9 px4_work_queue: increase SPI stack uniformly to silence warnings 2020-03-25 01:05:38 -04:00
Daniel Agar f4e2cd36d4 add new invensense/mpu6500 driver for airmind mindpx 2020-03-25 01:05:38 -04:00
Daniel Agar 75370ebf42 invensense/mpu9250 add ak8963 support and other minor improvements
- mag enabled with -M when starting
 - always check FIFO count before transfer
 - interupt pin set active low and latch
 - relax retry timeout if configure failed
 - improve configured empty rate (sample rate) rounding
 - fix RegisterCheck
 - check FIFO count as part of full transfer and reset or adjust timing if necessary
 - rename DRV_MAG_DEVTYPE_MPU9250 -> DRV_MAG_DEVTYPE_AK8963
2020-03-25 01:05:38 -04:00
Daniel Agar d55c3d80f3 invensense/mpu6000 refactor to be consistent with new icm20602, icm20608g, etc
- always check FIFO count before transfer even with data ready
 - interupt pin set active low and latch
 - relax retry timeout if configure failed
 - improve configured empty rate (sample rate) rounding
 - check FIFO count as part of full transfer and reset or adjust timing if necessary
2020-03-25 01:05:38 -04:00
Daniel Agar 279d06ee50 invensense/icm42688p driver minor improvements
- change default FIFO empty rate to 1 kHz (consistent with other drivers)
 - relax retry timeout if configure failed
 - improve configured empty rate (sample rate) rounding
 - check interupt status and FIFO count as part of full transfer and reset or adjust timing if necessary
2020-03-25 01:05:38 -04:00
Daniel Agar 669d2ec10b invensense/icm40609d driver minor improvements
- change default FIFO empty rate to 1 kHz (consistent with other drivers)
 - relax retry timeout if configure failed
 - improve configured empty rate (sample rate) rounding
 - check interupt status and FIFO count as part of full transfer and reset or adjust timing if necessary
2020-03-25 01:05:38 -04:00
Daniel Agar c6825aa177 invensense/icm20689 driver minor improvements
- interupt pin set active low and latch
 - relax retry timeout if configure failed
 - improve configured empty rate (sample rate) rounding
 - fix RegisterCheck
 - check FIFO count as part of full transfer and reset or adjust timing if necessary
2020-03-25 01:05:38 -04:00
Daniel Agar f5fe50f839 invensense/icm20608g driver minor improvements
- interupt pin set active low and latch
 - relax retry timeout if configure failed
 - improve configured empty rate (sample rate) rounding
 - fix RegisterCheck
 - check FIFO count as part of full transfer and reset or adjust timing if necessary
 - rename DRV_IMU_DEVTYPE_ICM20608 -> DRV_IMU_DEVTYPE_ICM20608G
2020-03-25 01:05:38 -04:00
Daniel Agar c4fbea32c1 invensense/icm20602 driver minor improvements
- interupt pin set active low and latch
 - relax retry timeout if configure failed
 - improve configured empty rate (sample rate) rounding
 - fix RegisterCheck
2020-03-25 01:05:38 -04:00
JaeyoungLim e2d2ae29a9 Add sonoma raceway world 2020-03-24 19:32:12 +00:00
TSC21 c4f8f39ca9 microRTPS: templates: use full version comparison when checking for version 1.7 2020-03-24 17:47:39 +00:00
TSC21 1b453ed849 microRTPS: templates: check only the major and minor of FastRTPS to set the 'discovery_config' namespace 2020-03-24 16:43:12 +00:00
Daniel Agar a13e8e573e boards: fmu-v2/v3 rc.board_sensors remove obsolete hmc5883 argument
- try to keep fmu-v2/v3 mostly in sync
2020-03-24 09:46:20 -04:00
Beat Küng 81dc73b752 fmu-v5_optimized: disable bl_update
to reduce FLASH usage
2020-03-24 09:46:20 -04:00
Beat Küng 7ea8dff8db spi: do not deselect other chip-selects
And make sure on reset & init everything is deselected.

Reduces CPU load on a pixhawk cube by almost 1%.
2020-03-24 09:46:20 -04:00
Beat Küng 1612f4c2ed SPI: disable SPI locking where possible
It's not possible for buses that run both NuttX and PX4 drivers, e.g.
Pixracer.

Reduces CPU load:
- v5x: 2.5%
- v3 (pixhawk cube): 4.4%
2020-03-24 09:46:20 -04:00
Beat Küng 6a41c9e417 refactor fxos8701cq: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 5fa4cd1019 refactor fxas21002c: use driver base class 2020-03-24 09:46:20 -04:00
Daniel Agar 6fd027c4dd refactor icm40609d: use driver base class 2020-03-24 09:46:20 -04:00
Daniel Agar 6e9bc50bec refactor icm42688p: use driver base class 2020-03-24 09:46:20 -04:00
Daniel Agar 974cb30b6d nxp_rddrone-uavcan146 ignore i2c for now (platform support is incomplete) 2020-03-24 09:46:20 -04:00
Daniel Agar 532ccd18ad refactor qmc5883: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng b156fe5787 boards: remove deprecated SPI + I2C defines from board_config.h
chip-selects are deselected in stm32_spiinitialize()
2020-03-24 09:46:20 -04:00
Beat Küng f4ab1b8a78 fix px4moduledoc: typo in 'External I2C bus(es)' 2020-03-24 09:46:20 -04:00
Beat Küng 2ca49cc718 differential_pressure drivers: add module subcategory documentation 2020-03-24 09:46:20 -04:00
Beat Küng f74474dd55 fmuk66-v3: fix spi bus numbering passing to px4_spibus_initialize
Fixes an error on bootup ([boot] FAILED to initialize SPI port 0). Other
than that, everything was working.
2020-03-24 09:46:20 -04:00
Beat Küng 04cffce992 refactor aerofc_adc: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 842f656143 mtd.cpp: remove use of PX4_I2C_BUS_ONBOARD 2020-03-24 09:46:20 -04:00
Beat Küng ee49e500e7 refactor ist8308: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 030ba24f53 refactor pca9685: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 6588dd0861 refactor icm20948: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 924f46ee28 refactor icm20608g: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng c4a19c8852 refactor icm20689: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 1df0fe03d7 refactor mpu6000: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 571451942d refactor mpu9250: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 609eafd4cd refactor l3gd20: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 6cf4de9e02 refactor lsm303d: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 3423809cd9 refactor ism330dlc: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 2d6a9ae1fb lsm9ds1: cleanup + consistency with other drivers 2020-03-24 09:46:20 -04:00
Beat Küng 00280d55c2 refactor rm3100: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 2fa289bbad lsm9ds1_mag: cleanup + consistency with other drivers 2020-03-24 09:46:20 -04:00
Beat Küng 74db018012 refactor lsm303agr: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 4d511868e6 refactor lis3mdl: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 785f18ebf8 refactor bmi160: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 54da4997ad refactor bmi088: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng aad6fe6f03 refactor bma180: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 17761acd49 refactor adis16497: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 1f152d7d43 refactor adis16477: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng d15fa82841 refactor adis16448: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 7626be0485 refactor mpu9250: use driver base class 2020-03-24 09:46:20 -04:00
Beat Küng 6ad5357d1a SPI+I2C: remove unused defines and printf's 2020-03-24 09:46:20 -04:00
Beat Küng 2f3174abb0 refactor icm20602: use driver base class 2020-03-24 09:46:20 -04:00
TSC21 975227c52a Tools: setup: add 'packaging' to the requirements list 2020-03-24 13:31:41 +00:00
Matthias Grob 6570e1fe40 appveyor: switch to Cygwin toolchain v0.9
to have packaging python 3 package.
See https://github.com/PX4/windows-toolchain/releases/tag/v0.9
2020-03-24 13:31:41 +00:00
TSC21 6598ce5a46 CI: bump container tags to 2020-03-16 2020-03-24 13:31:41 +00:00
TSC21 1ea5280299 microRTPS: use package.version to compare FastRTPS lib versions 2020-03-24 13:31:41 +00:00
bresch 1f4b2d1d53 Commander: replace deprecated warnx by PX4_WARN 2020-03-23 13:45:00 +01:00
bresch c23ef0af4b Flight termination: lockdown if failure is detected on takeoff
During the first few seconds after takeoff, the failure detector is allowed to
trigger motor lockdown.
This is done for safety reasons to detect tipping-over or unstable
tuning gains
2020-03-23 13:45:00 +01:00
bresch 5babf644f0 MPC: limit tilt to maximum safe value of 89 degrees
The algorithm fails at 90 degrees due to tanf being INF
2020-03-23 13:36:23 +01:00
JaeyoungLim 315135c07e Fix indentation in run script and update submodule 2020-03-23 10:55:13 +01:00
Julian Oes 103bfd0d30 mavsdk_tests: fix wait script output 2020-03-23 10:55:13 +01:00
Julian Oes 29c102b205 mavsdk_tests: wait for gz to run for model spawn 2020-03-23 10:55:13 +01:00
JaeyoungLim b1d3b95ebf Add gzmdoelspawning to mavsdk tests 2020-03-23 10:55:13 +01:00
JaeyoungLim 2ef37cd065 Spawn models separately from gazebo models
Detach model spawning process from the world description file, so that the same model can be used with different worlds
2020-03-23 10:55:13 +01:00
Daniel Agar 8738c26426 boards: enable NuttX SPI DMA buffers
- update to NuttX with stm32f4 and stm32f7 SPI DMA internal buffers
 - remove explicit DMA buffer allocations from new IMU drivers
 - restore original BOARD_DMA_ALLOC_POOL_SIZE
 - decrease SPI DMA thresholds based on fmu-v2/v3/v4/v5 bench testing
2020-03-22 19:24:26 -04:00
Daniel Agar b73ec18abb boards: add px4_fmu-v4 and px4_fmu-v5 optimized (-O3) build variants 2020-03-22 17:50:17 -04:00
JacobCrabill 1e5784609f UAVCAN Sensors: Improve error handling
Also add new 'generic' device types for UAVCAN sensors

Other misc. cleanup and style changes.
2020-03-21 12:39:29 -04:00
Jacob Crabill 693a47fca3 Update src/drivers/uavcan/sensors/baro.cpp
Use absolute-zero constant instead of 273.15f

Co-Authored-By: Daniel Agar <daniel@agar.ca>
2020-03-21 12:39:29 -04:00
JacobCrabill 4c8cfa140a UAVCAN: Overhaul SensorBridge drivers
Supposedly multiple sensor callbacks were supported; in reality, this
was not the case, as the mag SensorBridge in particular can only
calibrate one compass, leading to a race condition on which compass
appears first on the bus to get published and calibrated (with no
warning to the user that the 'wrong' compass is being used).

For sensors with existing generic driver classes (baro and mag) the
sensor bridges use these classes for the driver registration, and uORB
publication, and calibration interface (ioctl) handling.
2020-03-21 12:39:29 -04:00
JacobCrabill 79dc313260 uavcan: Add device IDs to baro, flow publishers
Can now see proper UAVCAN bus and unique device ID for barometer
instances; optical flow will also have the UAVCAN node ID assigned as
sensor ID.
2020-03-21 12:39:29 -04:00
JacobCrabill 71e4a36ba4 UAVCAN: GNSS sensor bridge: Support multiple pubs
UavcanGnssBridge did not support more than 1 GNSS callback/publisher.
This has now been fixed; it works the same as the baro, mag, and flow
sensor bridges.  The EKF2 still doesn't support more than 2 GPS
publishers, however.
2020-03-21 12:39:29 -04:00
Beat Küng 1fe79818d9 fix IntrusiveQueue::remove: several bugs that led to improper state of the queue
We also have to set removeNode->next to null, as it is used to test if the
item is in the queue.
2020-03-21 12:00:09 -04:00
Beat Küng 336745f9f7 tfmini: reduce sampling rate from 10kHz to 143Hz
10kHz sampling seems excessive, given that the sensor is expected to output
at 100Hz.

Also don't reschedule immediately in case we have not received any data.
2020-03-21 12:00:09 -04:00
bazooka joe ad2d65df8d return with error from _log_request_list() in case of failed allocation 2020-03-21 16:50:46 +01:00
Jacob Dahl b566de2c36 uavcannode: GPS add timestamp, covariance, and corrected integer overflow on lat/lon 2020-03-21 11:43:56 -04:00
TSC21 341dd6ba26 update submodule src/lib/ecl 2020-03-20 23:18:04 +01:00
rolandash 7d7fe9e4da Add onboard qmc5883 support for MindPX/MindRacer. 2020-03-20 13:19:53 -04:00
Daniel Agar 1be959cba8 InvenSense ICM-40609-D IMU driver
This is another new InvenSense sensor with max output data rate of 32 kHz (both accel & gyro), on board anti-aliasing filter, and accel range 32G. Overall quite similar to the ICM-42688-P added in #14420, but with doubled accel range and without the optional high resolution output or clock sync.
2020-03-20 13:02:13 -04:00
Daniel Agar 46e5364580 InvenSense ICM-42688-P IMU driver
This is a new InvenSense sensor with max output data rate of 32 kHz (both accel & gyro), on board anti-aliasing filter, optional higher resolution output (18 bit accel, 19 bit gyro), and clock sync.
2020-03-20 13:01:02 -04:00
Nico van Duijn 240aad1aef mavlink_mission: beautify mission download error
This commit makes the IGN REQUEST LIST: Busy message more user-oriented
and actionable.
2020-03-20 12:54:00 +01:00
Nico van Duijn 849d3a1b54 mavlink_mission: robustify against dropped ack
This commit handles incoming MISSION_REQUEST_LIST messages such that
they are no longer ignored if the previously requested mission has
sent all mission items but the ack has never been received.

This was the cause for frequent "IGN REQUEST LIST: Busy" warnings
2020-03-20 12:54:00 +01:00
SalimTerryLi dc8e775d8f ADC: replace ioctl with uorb message (#14087) 2020-03-20 11:23:32 +01:00
Beat Küng 40af5b0fbe logger: fix initial subscribing to topics
write_all_add_logged_msg() requires at least some subscriptions to be added
initially, as this message is used to separate ULog header from data.
2020-03-20 11:21:32 +01:00
Daniel Agar fb27d96ca1 Update submodule mavlink v2.0 to latest Fri Mar 20 00:38:07 UTC 2020
- mavlink v2.0 in PX4/Firmware (0213fd662a): https://github.com/mavlink/c_library_v2/commit/82bef70f12492a4fb17456534a3ce068f4647502
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/11589a51bec0e96ffe80366c387997f7c44cffa3
    - Changes: https://github.com/mavlink/c_library_v2/compare/82bef70f12492a4fb17456534a3ce068f4647502...11589a51bec0e96ffe80366c387997f7c44cffa3

    11589a51 2020-03-19 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/5a18bf9101863e020ddb18617b2d210258c9069f

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-03-19 21:21:08 -04:00
Daniel Agar 6c513cf29d Update submodule GPS devices to latest Fri Mar 20 00:38:17 UTC 2020 (#14432)
- GPS devices in PX4/Firmware (daf8a9fb12097b09fa1291b16cfe88f10a53b193): https://github.com/PX4/GpsDrivers/commit/c25a8f22c43e22b7c23106470b08fb17678042ef
    - GPS devices current upstream: https://github.com/PX4/GpsDrivers/commit/0cd890ac60dbf6e535ccd966f98b85a33eddcc72
    - Changes: https://github.com/PX4/GpsDrivers/compare/c25a8f22c43e22b7c23106470b08fb17678042ef...0cd890ac60dbf6e535ccd966f98b85a33eddcc72

    0cd890a 2020-03-19 Daniel Agar - ubx: fix whitespace

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-03-19 21:20:38 -04:00
bresch 0213fd662a update ecl 2020-03-19 20:27:39 +03:00
bresch 0f2f72a757 Ekf2: Add bitmask to select terrain estimator aiding sources 2020-03-19 20:27:39 +03:00
Daniel Agar e5d30c4413 Mavlink: split ESTIMATOR_STATUS and VIBRATION streams 2020-03-19 11:17:31 -04:00
bazooka joe 7b37f329f0 batt_smbus fixes
fixed wrong calculation of max_cell_voltage
adding missed max_cell_voltage_delta
some code beautify
2020-03-19 09:34:02 +01:00
bazooka joe 53bc5fddad smbus return with error if failed transfer 2020-03-19 09:34:02 +01:00
Julian Oes 6d654cb50b mavsdk_tests: improve usage text
These are improvements based on the review by @hamishwillee
in https://github.com/PX4/Devguide/pull/982.
2020-03-19 08:53:21 +01:00
Matthias Grob d0349fcf07 mc_pos_control: allow zero thrust during takeoff and landing
Otherwise the takeoff ramp doesn't start with zero thrust and
the land thrust cut cannot cut to zero.
2020-03-18 20:36:05 +01:00
Matthias Grob 5027c68c0a mc_pos_control: handle takeoff and landing thrust limit the same way
The landing thrust limit was after the position controller and
could be inconsistent with what the takeoff limit did. This
resulted in different thrust values sequentially getting applied
during landing.
2020-03-18 20:36:05 +01:00
Matthias Grob 3049a3d14d mc_pos_control: prevent takeoff with thrust setpoint
This was only necessary for stabilized mode before #10805.
The  unit length thrust setpoint will anyways not be available
anymore soon because it gets replaced with the acceleration
setpoint in m/s².
2020-03-18 20:36:05 +01:00
Matthias Grob 1f98ebdb47 mc_pos_control: switch order of setpoint amendment
to make sure the takeoff limitation is always done last.
2020-03-18 20:36:05 +01:00
bresch a8063ac948 HTE: enable by default 2020-03-18 19:47:30 +01:00
Julian Oes 89599f345f mavsdk_tests: c++ test_runner is now mavsdk_tests 2020-03-18 17:57:41 +00:00
Julian Oes ade39481ad mavsdk_tests: only env vars that are set
Otherwise this raises a KeyError.
2020-03-18 17:57:41 +00:00
Julian Oes 5ea40c57c6 workflows: add more tests outside of Europe 2020-03-18 17:57:41 +00:00
Julian Oes 759e3d6a04 mavsdk_tests: pass PX4_HOME_ env variables on
This way tests can be run at different locations.
2020-03-18 17:57:41 +00:00
Julian Oes 4a91d791b1 mavsdk_tests: remove commented out code 2020-03-18 17:57:41 +00:00
Julian Oes 9d124c2b1a mavsdk_tests: a timeout of 5min should be enough 2020-03-18 17:57:41 +00:00
Julian Oes 23a3002178 github: try to get latest tools using pip 2020-03-18 17:57:41 +00:00
Julian Oes 6dfe0c3d72 github: new check for MAVSDK tester Python scripts 2020-03-18 17:57:41 +00:00
Julian Oes eb1141bbea mavsdk_tests: remove unused import 2020-03-18 17:57:41 +00:00
Julian Oes c6160d4e3f mavsdk_tests: fix error for Python < 3.8 2020-03-18 17:57:41 +00:00
Julian Oes 41341cd985 mavsdk_tests: name files consistently 2020-03-18 17:57:41 +00:00
Julian Oes b5048a3414 mavsdk_tests: add header and fix style 2020-03-18 17:57:41 +00:00
Julian Oes 9b61ce1006 Tools: check style of mavsdk_tests files 2020-03-18 17:57:41 +00:00
Julian Oes 4905ac5e2c mavsdk_tests: add filter for cases 2020-03-18 17:57:41 +00:00
Julian Oes 79387428c6 mavsdk_tests: fix missing space after number 2020-03-18 17:57:41 +00:00
Julian Oes 3f1990b083 mavsdk_tests: print where to find logfiles 2020-03-18 17:57:41 +00:00
Julian Oes 188177cef6 mavsdk_tests: print error on failure 2020-03-18 17:57:41 +00:00
Julian Oes ab2186f126 mavsdk_tests: improve and fix colors/result 2020-03-18 17:57:41 +00:00
Julian Oes b1ceef5b93 mavsdk_tests: add combined log 2020-03-18 17:57:41 +00:00
Julian Oes 814d79cb32 mavsdk_tests: improve log file folder structure 2020-03-18 17:57:41 +00:00
Julian Oes 8283d19682 mavsdk_tests: print overall results 2020-03-18 17:57:41 +00:00
Julian Oes a208129921 mavsdk_tests: satisfy mypy type checks 2020-03-18 17:57:41 +00:00
Julian Oes 12252c97c5 mavsdk_tests: further argument cleanup, some types 2020-03-18 17:57:41 +00:00
Julian Oes ff64d87ae6 mavsdk_tests: import naming, easier coloring 2020-03-18 17:57:41 +00:00
Julian Oes 11a28840f3 mavsdk_tests: split up Python script
Otherwise, the script will get a tangled mess.
2020-03-18 17:57:41 +00:00
Julian Oes b281d87b4a mavsdk_tests: initialize Tester class in ctor 2020-03-18 17:57:41 +00:00
Julian Oes e2c80e546d mavsdk_tests: properly exit on Ctrl+C
With threads we need to manually take care of it, otherwise it gets
messy and we need to press Ctrl+C multiple times.
2020-03-18 17:57:41 +00:00
Julian Oes 2c2e314ffe mavsdk_tests: improve output, allow log and stdout
This makes it possible to write to logfiles and at the same time print
everything to console in verbose mode.
2020-03-18 17:57:41 +00:00
Julian Oes d7eb600b59 mavsdk_tests: improve test name/description 2020-03-18 17:57:41 +00:00
Julian Oes b2e300ad1f mavsdk_tests: improve test output readability 2020-03-18 17:57:41 +00:00
Julian Oes 54645268ed mavsdk_tests: only print error on failure 2020-03-18 17:57:41 +00:00
Julian Oes 911cdc8774 mavsdk_tests: output less verbose unless needed 2020-03-18 17:57:41 +00:00
Julian Oes 0989e90b4a Tools: exit as straightaway with DONT_RUN set 2020-03-18 17:57:41 +00:00
Julian Oes bfef243dba mavsdk_tests: write output to logs folder
And create folder if it doesn't exist already.
2020-03-18 17:57:41 +00:00
Julian Oes 5ba28d417a mavsdk_tests: try using tags as intended
The tags should enable use to assemble the tests in various ways. This
will probably require some iterations though.
2020-03-18 17:57:41 +00:00
Julian Oes 512faa6ebe mavsdk_tests: use CHECK if we don't need to abort 2020-03-18 17:57:41 +00:00
Julian Oes 821f7c3cd9 mavsdk_tests: remove unused/not working test
We can add it again once fixedwing is supported. Until then, this is
just confusing.
2020-03-18 17:57:41 +00:00
Julian Oes fb5b05ec39 mavsdk_tests: add missing unit 2020-03-18 17:57:41 +00:00
Julian Oes a5d1ce91e4 mavsdk_tests: consolidate level of abstraction
This moves the CHECK/REQUIRE inside of AutopilotTester.
2020-03-18 17:57:41 +00:00
Julian Oes 6a4a4bd0d6 workflows: adapt to mavsdk_tests cli changes 2020-03-18 17:57:41 +00:00
Julian Oes 70eb444f17 mavsdk_tests: improve naming of argument
We abort when we already failed so this makes more sense.
2020-03-18 17:57:41 +00:00
Julian Oes 41b2362dcf mavsdk_tests: add more config into JSON 2020-03-18 17:57:41 +00:00
Julian Oes c61cd10db5 mavsdk_tests: without speedup the VTOL takes time 2020-03-18 17:57:41 +00:00
Julian Oes b4916fdecb mavsdk_tests: move config into json file 2020-03-18 17:57:41 +00:00
Julian Oes 44a556717d mavsdk_tests: remove plane tests
We can put them back once it's supported.
2020-03-18 17:57:41 +00:00
Julian Oes ae2032d29f mavsdk_tests: use the min of the speed factors
Facepalm.
2020-03-18 17:57:41 +00:00
Julian Oes 86f24f5121 mavsdk_tests: remove opt_flow test
It doesn't actually seem to work.
2020-03-18 17:57:41 +00:00
Julian Oes b7e8837562 mavsdk_tests: add max speed factor
This is required because some tests don't work at more than 1x.
2020-03-18 17:57:41 +00:00
Julian Oes 795e000c2b simulator: remove redundant semicolon 2020-03-18 17:57:41 +00:00
Julian Oes d8b6c864cd mavsdk_tests: PEP8 fixes 2020-03-18 17:57:41 +00:00
Julian Oes e8e8b79322 mavsdk_tests: MAVSDK is required
Without the library installed, we can't build and run the tests.
Silently ignoring this just leads to confusion.
2020-03-18 17:57:41 +00:00
PX4 BuildBot 32a6a4e8d8 Update submodule ecl to latest Wed Mar 18 12:38:43 UTC 2020
- ecl in PX4/Firmware (e34351229b4d9de251c495ee49e7c709a93b2521): https://github.com/PX4/ecl/commit/f1aa53db8a8053e5f27a698084a7362f727ce375
    - ecl current upstream: https://github.com/PX4/ecl/commit/ee5e3c479b85876dcb7bf451884e40c72a716fd7
    - Changes: https://github.com/PX4/ecl/compare/f1aa53db8a8053e5f27a698084a7362f727ce375...ee5e3c479b85876dcb7bf451884e40c72a716fd7

    ee5e3c4 2020-03-18 CarlOlsson - ekfgsf: fix formatting
f20fc08 2020-03-17 Mathieu Bresciani - ekf2: centralize mag covariance reset (#693)
2020-03-18 12:39:33 -04:00
Daniel Agar b703ffa188 Update submodule mavlink v2.0 to latest Wed Mar 18 12:38:27 UTC 2020
- mavlink v2.0 in PX4/Firmware (d6bb5b3b9e): https://github.com/mavlink/c_library_v2/commit/e8bdbcfbacccd79fc678f5c6755c8fb680021199
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/82bef70f12492a4fb17456534a3ce068f4647502
    - Changes: https://github.com/mavlink/c_library_v2/compare/e8bdbcfbacccd79fc678f5c6755c8fb680021199...82bef70f12492a4fb17456534a3ce068f4647502

Co-authored-by: PX4 BuildBot <bot@px4.io>
2020-03-18 12:06:25 -04:00
PX4 BuildBot 640c245c44 Update submodule devices to latest Wed Mar 18 12:38:39 UTC 2020
- devices in PX4/Firmware (5ba8a9f62ff93843185979b3881eb7125ffc42cc): https://github.com/PX4/GpsDrivers/commit/781d4f125580d88d24add83b97017e6d771d757f
    - devices current upstream: https://github.com/PX4/GpsDrivers/commit/c25a8f22c43e22b7c23106470b08fb17678042ef
    - Changes: https://github.com/PX4/GpsDrivers/compare/781d4f125580d88d24add83b97017e6d771d757f...c25a8f22c43e22b7c23106470b08fb17678042ef

    c25a8f2 2020-03-16 Nicolas Martin - ubx: fix baud rate search
2020-03-18 12:05:16 -04:00
Daniel Agar 0da7040cf5 beaglebone blue add empty px4_spi_buses 2020-03-18 11:55:11 -04:00
Daniel Agar df5fe85cf6 github actions add linux builds 2020-03-18 11:55:11 -04:00
Julian Oes 3233e0794d navigator: fix edge case with valid idle setpoint
This is an attempt to fix an edge case in the triplet publication which
can lead to crashes on autopilots with slow SD cards.

The sequence of events before this patch is:
1. Switch to POSCTL when disarmed. At this point current valid with
   setpoint idle is published.
2. Arm, takeoff, and fly using joystick/RC.
3. Switch to RTL (or trigger RTL using RC loss). At this point the
   setpoint is valid but still idle and the motors will shut off.
4. Once navigator has published the new setpoint (which can take up to
   1.5 seconds on slow SD cards) we will hopefully recover.

With this patch we omit this edge case, so we never publish this idle
setpoint when landed. The assumption is that this idle setpoint is no
longer required with the current flight task code, however, that needs
to be further verified.
2020-03-18 10:50:03 -04:00
CarlOlsson 58ded8d4c0 ekf2: remove unused function declatation 2020-03-18 14:33:11 +01:00
Beat Küng d6bb5b3b9e i2c spi buses: enforce drivers to set default SPI/I2C bus frequency
Not a lot of drivers use the global default, which is somewhat arbitrary.
2020-03-17 23:31:17 -04:00
Beat Küng 8ebde51648 refactor hmc5883: use driver base class
Removes the calibration on startup, as these values were overwritten by
the system calibration values anyway.
So the only difference is that if all calibration scales were equal to 1,
the driver startup would have failed.
2020-03-17 23:31:17 -04:00
Beat Küng 8f3ba81c4a refactor atxxxx: use driver base class
and increase update rate to 20Hz
2020-03-17 23:31:17 -04:00
Beat Küng 20db735d77 refactor ak09916: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 47b329cc54 refactor bmm150: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng e4bf535595 refactor bst telemetry: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng fb6ce09dc4 refactor pcf8583: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng bb4ff04caf refactor irlock: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 1710cd9648 refactor px4flow: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng b6119c71df refactor paw3902: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 82f92b56db batt_smbus: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng ec2de33547 lights: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 692d262e0e refactor voxlpm: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 832ccd262e refactor ina226: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng d6b9cfa3e2 pga460: fix documentation 2020-03-17 23:31:17 -04:00
Beat Küng 68ef14002a differential_pressure drivers: allow multiple instances of each driver
- the device path needs to be removed, as startup fails if it already
  exists
- sdp3x broadcasts a reset on startup, so do it only for the first I2C
  address
2020-03-17 23:31:17 -04:00
Beat Küng 3b7b2dc871 differential_pressure sensors: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 0924ff7fcf refactor vl53lxx: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 83b367f000 refactor teraranger: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 5a26f06f8a fix sf0x: check if device port is given
otherwise we risk dereferencing a null pointer
2020-03-17 23:31:17 -04:00
Beat Küng bbe15aa61a refactor srf02: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng a6ddf0e4b9 refactor sf1xx: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng f743585160 refactor mb12xx: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 7e3f40d1c2 refactor mappydot: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 1b1e1ba31f refactor ll40ls: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng df99555132 refactor ll40ls: split I2C and PWM into separate drivers
- there was almost nothing shared
- it will fit better into the updated I2C driver structure
2020-03-17 23:31:17 -04:00
Beat Küng 081ab729aa refactor lps25h: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng dc5ffb43a3 refactor mpl3115a2: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng d81fedfcfa refactor lps22hb: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 83a3deb9da refactor dps310: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 985bb2adc9 refactor bmp388: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng aeadf54a74 refactor bmp280: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng dbb53044ce refactor ms5611: use driver base class
Also: remove device type auto-detection as it will not work with
together with the new SPI board config (which specifies a specific
device type)
2020-03-17 23:31:17 -04:00
Beat Küng 22a38453ab refactor bmi055: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 969a77f889 refactor mpu6000: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng be0a205438 refactor ist8310: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 3e71914fae refactor lsm9ds1+lsm9ds1_mag: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 58f386a81c refactor pmw3910: use driver base class 2020-03-17 23:31:17 -04:00
Beat Küng 2f4080f47b i2cdetect: remove use of PX4_I2C_BUS_EXPANSION 2020-03-17 23:31:17 -04:00
Beat Küng 971897b9ed mtd: switch to c++ and use px4_find_spi_bus 2020-03-17 23:31:17 -04:00
Beat Küng f555fe309c fmu-v5: change external i2c bus ordering to match with the label 2020-03-17 23:31:17 -04:00
Beat Küng 83b6f6456b refactor I2CSPIInstance: store running instances in a global linked list
instead of a static per-driver array.

Reduces BSS RAM usage by a couple of 100 Bytes (linear increase with num
drivers).

Downsides:
- a bit more runtime overhead
- less isolation, locking required
- a bit more complex
2020-03-17 23:31:17 -04:00
Beat Küng e7f04109d9 i2c spi init + custom methods: use WorkItemSingleShot
Use it for custom methods as well (like reset), and run by default on the
work queue, since they typically access the bus.
2020-03-17 23:31:17 -04:00
Beat Küng 8c41025565 px4_work_queue: add WorkItemSingleShot
To run a specific method on a work queue and wait for it to return.
2020-03-17 23:31:17 -04:00
Beat Küng 87cd20180c i2c spi: add unittests for BusCLIArguments 2020-03-17 23:31:17 -04:00
Beat Küng 134413233a i2c spi: extend BusCLIArguments to handle common driver arguments 2020-03-17 23:31:17 -04:00
Beat Küng d1f5b23a5a module docs: add PRINT_MODULE_USAGE_PARAMS_I2C_{SPI_DRIVER,ADDRESS}
For SPI/I2C driver default options
2020-03-17 23:31:17 -04:00
Beat Küng f851f65f8d i2c spi: add type to I2CSPIInstance
Needed to distinguish runtime instance types of the same driver (e.g.
bmi055 accel vs gyro).
2020-03-17 23:31:17 -04:00
SalimTerryLi b70289c536 move __PX4_LINUX out of px4_impl_os.cmake 2020-03-17 13:20:32 -04:00
Matthias Grob fb1b6a0ab9 mc_pos_control: hotfix for takeoff ramp stuck with NAN
Reported by @dusan19 in #13973.
2020-03-17 16:19:35 +01:00
Matthias Grob eb3b0f6b55 mathlib: get rid of now duplicate sign() function
Instead use the one that was copied to the matrix library in
https://github.com/PX4/Matrix/pull/116/
2020-03-17 10:01:42 +01:00
Matthias Grob d313b0417a AttitudeControl: Take advantage of Quaternion.canonical()
Introduced by @kamilritz in
https://github.com/PX4/Matrix/pull/116/
2020-03-17 10:01:42 +01:00
Lorenz Meier 9275937b44 Commander: Exclude shell commands for constrained flash
These are convenience commands for developers and are not required for flash constrained targets.
2020-03-17 00:17:11 +01:00
Lorenz Meier 9119f13ff7 Commander: Do not print health flags on constrained flash
Boards with constrained flash are not classic development targets and do not need this.
2020-03-17 00:17:11 +01:00
Lorenz Meier e951123cff Health Flags: Optimize flash usage
Changing from a define to a function for reporting to safe space.
2020-03-17 00:17:11 +01:00
Lorenz Meier aea68f06f9 Commander: Streamline preflight and arming checks
The checks did previously only report the first failure (to not overload the radio link). As we are moving to buffered messages and higher bandwidth links this design choice is not any more in the best interest of the drone operator. We are now reporting all detected failures. To ensure architectural consistency more checks have been moved from the commander mainloop into the respective classes.
2020-03-17 00:17:11 +01:00
Lorenz Meier bf3b55cac7 Commander: Add function to print health flags consistently
This enables us to have better situational awareness during development and when inspecting a system in the field as to which subsystem is currently faulty. These flags are from standard MAVLink and are not sufficient nor do they match well the actual critical path to a safe flight. This will be addressed in a second step with the addition of a new MAVLink message and new flags.
2020-03-17 00:17:11 +01:00
Lorenz Meier 9d5aebd235 Commander: Run continuous pre-flight checks silently
As we are checking the current pre-flight state and validate wether the system could be armed, we do not want to spam the console or user with continously failing checks. These checks are reported to the GCS separately and are processed and displayed there.
2020-03-17 00:17:11 +01:00
Lorenz Meier 21435bd32b Report preflight and pre-arm checks from period checks
With this change we are reporting any issues we find with the periodic check.

Co-Authored-By: Beat Küng <beat-kueng@gmx.net>
2020-03-17 00:17:11 +01:00
Lorenz Meier ed0a01d5da Commander: Add reporting of preflight and prearming state
This is essential for the operator to know if the system is ready to fly.
2020-03-17 00:17:11 +01:00
Lorenz Meier 4f1749541c ROMFS: Exclude uncommon board configs (Generic 250) 2020-03-16 23:40:29 +01:00
Lorenz Meier cff36315c4 ROMFS: Exclude uncommon board configs (Beta75x) 2020-03-16 23:40:29 +01:00
Lorenz Meier f7455db20c ROMFS: Exclude uncommon board configs (Reaper) 2020-03-16 23:40:29 +01:00
Lorenz Meier 98c9e558ca ROMFS: Exclude uncommon board configs (3DR Quad) 2020-03-16 23:40:29 +01:00
Lorenz Meier 48d1c355c3 ROMFS: Exclude uncommon board configs (Solo) 2020-03-16 23:40:29 +01:00
Lorenz Meier 4c8866059d ROMFS: Exclude uncommon board configs (HK Micro) 2020-03-16 23:40:29 +01:00
Lorenz Meier ebf52a988a ROMFS: Exclude uncommon board configs (HB PX4 Vision) 2020-03-16 23:40:29 +01:00
Lorenz Meier 2e63a43ea1 ROMFS: Exclude uncommon board configs (HB S500) 2020-03-16 23:40:29 +01:00
Lorenz Meier f2037876a4 ROMFS: Exclude uncommon board configs (S500) 2020-03-16 23:40:29 +01:00
Lorenz Meier bf02b8cc72 ROMFS: Exclude uncommon board configs (QAV250) 2020-03-16 23:40:29 +01:00
Lorenz Meier 0808bc7243 ROMFS: Exclude uncommon board configs (QAVR5) 2020-03-16 23:40:29 +01:00
Lorenz Meier f660c495cb ROMFS: Exclude uncommon board configs (TBS Caipi) 2020-03-16 23:40:29 +01:00
Lorenz Meier 992adfed58 ROMFS: Exclude uncommon board configs (Parrot Disco) 2020-03-16 23:40:29 +01:00
Lorenz Meier 23bf4d5e1b ROMFS: Exclude uncommon board configs (Pigeon Airframe) 2020-03-16 23:40:29 +01:00
Lorenz Meier d397543262 ROMFS: Exclude uncommon board configs (Viper) 2020-03-16 23:40:29 +01:00
Lorenz Meier a304ce0d59 ROMFS: Exclude uncommon board configs (FX79) 2020-03-16 23:40:29 +01:00
Lorenz Meier c08128e917 ROMFS: Exclude uncommon board configs (Wing Wing) 2020-03-16 23:40:29 +01:00
Lorenz Meier 5f64efb87d ROMFS: Exclude uncommon board configs (Skywalker) 2020-03-16 23:40:29 +01:00
Lorenz Meier dd22b51606 ROMFS: Exclude uncommon board configs (Phantom) 2020-03-16 23:40:29 +01:00
Lorenz Meier 72cb9f2c1b ROMFS: Exclude uncommon board configs (Camflyer) 2020-03-16 23:40:29 +01:00
Lorenz Meier 936f93eb3a ROMFS: Exclude uncommon board configs (Generic Wing) 2020-03-16 23:40:29 +01:00
Lorenz Meier a2e2e4069b ROMFS: Exclude uncommon board configs (Dodeca Cox) 2020-03-16 23:40:29 +01:00
Lorenz Meier 47f21e42ba ROMFS: Exclude uncommon board configs (Mini Talon) 2020-03-16 23:40:29 +01:00
Lorenz Meier a1878cd1ab ROMFS: Exclude uncommon board configs (Albatross) 2020-03-16 23:40:29 +01:00
Lorenz Meier 3b7922b788 ROMFS: Exclude uncommon board configs (Maja) 2020-03-16 23:40:29 +01:00
Lorenz Meier 456958dd15 ROMFS: Exclude uncommon board configs (Standard Plane) 2020-03-16 23:40:29 +01:00
Lorenz Meier ffc718c0c2 ROMFS: Exclude uncommon board configs (AutoG2) 2020-03-16 23:40:29 +01:00
Lorenz Meier 3ab6cfe701 ROMFS: Exclude uncommon board configs (Helicopter) 2020-03-16 23:40:29 +01:00
Lorenz Meier e2429c8a7a ROMFS: Exclude uncommon board configs (Coax Heli) 2020-03-16 23:40:29 +01:00
Lorenz Meier f5db720e78 ROMFS: Exclude uncommon board configs (Tri Y-) 2020-03-16 23:40:29 +01:00
Lorenz Meier 31e776d570 ROMFS: Exclude uncommon board configs (Tri Y) 2020-03-16 23:40:29 +01:00
Lorenz Meier c4c39940de ROMFS: Exclude uncommon board configs (S250) 2020-03-16 23:40:29 +01:00
Lorenz Meier 21bcf2ff04 ROMFS: Exclude uncommon board configs (QAV250) 2020-03-16 23:40:29 +01:00
Lorenz Meier 60a1309b07 ROMFS: Exclude uncommon board configs (Kopis 2) 2020-03-16 23:40:29 +01:00
Lorenz Meier 733d3d0f13 ROMFS: Exclude uncommon board configs (DJI Matrice 100) 2020-03-16 23:40:29 +01:00
Lorenz Meier 61f4f25530 ROMFS: Exclude uncommon board configs (Aero) 2020-03-16 23:40:29 +01:00
Lorenz Meier 9e770c609d ROMFS: Exclude uncommon board configs (IFO) 2020-03-16 23:40:29 +01:00
Lorenz Meier db9f2700f6 ROMFS: Exclude uncommon board configs (Draco) 2020-03-16 23:40:29 +01:00
Lorenz Meier 7b94a2da80 ROMFS: Exclude uncommon board configs (ZMR250) 2020-03-16 23:40:29 +01:00
Lorenz Meier 41f9df6cf8 ROMFS: Exclude uncommon board configs (Nanomind) 2020-03-16 23:40:29 +01:00
Lorenz Meier 59ee1f0a29 ROMFS: Exclude uncommon board configs (Tilt Quad) 2020-03-16 23:40:29 +01:00
Lorenz Meier b5daf5799d ROMFS: Exclude uncommon board configs (Teal) 2020-03-16 23:40:29 +01:00
Lorenz Meier ed4ed50786 ROMFS: Exclude uncommon board configs (Clover4) 2020-03-16 23:40:29 +01:00
Lorenz Meier 4ee4b830ab ROMFS: Exclude uncommon board configs (Crazyflie) 2020-03-16 23:40:29 +01:00
Lorenz Meier d8ed4c7b3d ROMFS: Exclude uncommon board configs (Generic Ground) 2020-03-16 23:40:29 +01:00
Lorenz Meier 428ce42966 ROMFS: Exclude uncommon board configs (Axialracing AX10) 2020-03-16 23:40:29 +01:00
Lorenz Meier a394a68e47 ROMFS: Exclude uncommon board configs (Traxxas Stampede) 2020-03-16 23:40:29 +01:00
Lorenz Meier 8bc3418892 ROMFS: Exclude uncommon board configs (AION Robotics) 2020-03-16 23:40:29 +01:00
Lorenz Meier ebd188bca9 ROMFS: Exclude uncommon board configs (DFrobot GPX Asurada) 2020-03-16 23:40:29 +01:00
Lorenz Meier 37cc9604bc ROMFS: Exclude uncommon board configs (Quad +) 2020-03-16 23:40:29 +01:00
Lorenz Meier fd73580db8 ROMFS: Exclude uncommon board configs (UUV Generic) 2020-03-16 23:40:29 +01:00
Lorenz Meier 56de232bae ROMFS: Exclude uncommon board configs (UUV HippoCambus) 2020-03-16 23:40:29 +01:00
Lorenz Meier 54c3e72f0c ROMFS: Exclude uncommon board configs (Hexa X) 2020-03-16 23:40:29 +01:00
Lorenz Meier d68caed742 ROMFS: Exclude uncommon board configs (Draco R) 2020-03-16 23:40:29 +01:00
Lorenz Meier 942097a0ce ROMFS: Exclude uncommon board configs (Hexa +) 2020-03-16 23:40:29 +01:00
Lorenz Meier 7b0c8ec3fc ROMFS: Exclude uncommon board configs (Octo X) 2020-03-16 23:40:29 +01:00
Lorenz Meier e93d23985c ROMFS: Exclude uncommon board configs (Octo +) 2020-03-16 23:40:29 +01:00
Lorenz Meier 75491ed298 ROMFS: Exclude uncommon board configs (VTOL Tailsitter) 2020-03-16 23:40:29 +01:00
Lorenz Meier a3419a0130 ROMFS: Exclude uncommon board configs (VTOL Octo) 2020-03-16 23:40:29 +01:00
Lorenz Meier 4176627539 ROMFS: Exclude uncommon board configs (Babyshark) 2020-03-16 23:40:29 +01:00
Lorenz Meier f7666a8b74 ROMFS: Exclude uncommon board configs (Convergence) 2020-03-16 23:40:29 +01:00
Lorenz Meier 65ea2bc981 ROMFS: Exclude uncommon board configs (Claire) 2020-03-16 23:40:29 +01:00
Lorenz Meier 8d0f9d8601 ROMFS: Exclude uncommon board configs (Ranger) 2020-03-16 23:40:29 +01:00
Lorenz Meier 1300930d85 ROMFS: Exclude uncommon board configs (QuadRanger) 2020-03-16 23:40:29 +01:00
Lorenz Meier f663515f49 ROMFS: Exclude uncommon board configs (VTOL AAVVT) 2020-03-16 23:40:29 +01:00
Lorenz Meier 207ae6d83c ROMFS: Exclude uncommon board configs (VTOL Standard Delta) 2020-03-16 23:40:29 +01:00
Lorenz Meier 1e1762401e ROMFS: Exclude uncommon board configs (VTOL AAERT) 2020-03-16 23:40:29 +01:00
Lorenz Meier dc41771c1a ROMFS: Exclude uncommon board configs (Quad+) 2020-03-16 23:40:29 +01:00
Lorenz Meier 6cd669836c ROMFS: Exclude uncommon board configs (Firefly 6) 2020-03-16 23:40:29 +01:00
Lorenz Meier af9b073c9a ROMFS: Exclude uncommon board configs (Steadidrine Mavrik) 2020-03-16 23:40:29 +01:00
Lorenz Meier 440067870a ROMFS: Exclude uncommon board configs (Octo COX) 2020-03-16 23:40:29 +01:00
Lorenz Meier f3e4aec45a ROMFS: Exclude uncommon board configs (Hexa COX) 2020-03-16 23:40:29 +01:00
Lorenz Meier 079772823a ROMFS: Exclude uncommon board configs (TBS Endurance) 2020-03-16 23:40:29 +01:00
Lorenz Meier 65052717fe ROMFS: Exclude uncommon board configs (Steadidrone Q4D) 2020-03-16 23:40:29 +01:00
Lorenz Meier 83c0d4607e ROMFS: Exclude uncommon board configs (3DR Iris) 2020-03-16 23:40:29 +01:00
Lorenz Meier df49d1d815 ROMFS: Exclude uncommon board configs (TBS Dicovery) 2020-03-16 23:40:29 +01:00
Daniel Agar 1a9452e411 fw_att_control: move ecl/attitude_fw into fw_att_control module
- ecl/attitude_fw was never maintained as a standalone library
 - moving ecl/attitude_fw library into the fw_att_control module to ease further development
2020-03-15 14:14:59 -04:00
Daniel Agar 4e4fb2232e CI move NuttX bloaty checks from Jenkins to Github Actions 2020-03-15 14:06:05 -04:00
bresch 6ccf55b6fd MPC: add updateHoverThrust function
This function updates the vertical velocity integrator with the change
in hover thrust to avoid propagating discontinuities through the
controller when changing the hover thrust.
This is also important when using the hover thrust estimator as its
estimate has unconstrained dynamics and can cause drops or kicks when
the estimate updates faster than the velocity integrator.
2020-03-15 13:57:02 -04:00
bresch 1bf791ba3f MC_HTE: Stability improvements
- Use a low-passed value of the signed innovation test ratio to trigger
the state variance boost. The threshold of 0.2 has been chosen using log
replay and simulation scenarii.
- Do not reset the learned accel noise during a state variance boost.
After a few tests, this does not seem to help at all.
- Continue to learn the accel noise even if the measurement got rejected
to avoid ignoring sudden changes of noise
- Lower the acceleration noise time constant and increase min/max
values to avoid learning quickly a small variance that could temporarly
destabilize the filter
- Update filter time constants. Increasing the speed of the residual lpf
improves the quality of the learned accel noise
2020-03-15 13:57:02 -04:00
PX4 BuildBot 20a8a0231b Update submodule nuttx to latest Sun Mar 15 12:39:29 UTC 2020
- nuttx in PX4/Firmware (048c47d7e2cc686fdd4037cb33bb86ca0ac62c17): https://github.com/PX4/NuttX/commit/db7fb6b6c07120fe97c5c7c1b2fdb46f32b190bc
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/befe53e7f1ed557b7239c9ed564acae7cc72a900
    - Changes: https://github.com/PX4/NuttX/compare/db7fb6b6c07120fe97c5c7c1b2fdb46f32b190bc...befe53e7f1ed557b7239c9ed564acae7cc72a900

    befe53e7f1 2020-03-12 Jari van Ewijk - [BACKPORT] NXP RDDRONE-UAVCAN boards (S32K1XX) - Clean up clock config (#557)
09a23ebf7f 2020-03-12 Jari van Ewijk - [BACKPORT] NXP S32K1XX EVB boards - clock config cleanup (#556)
6c95d5fc33 2020-03-12 Jari van Ewijk - [BACKPORT] NXP S32K1XX peripheral clock fixes (#555)
2020-03-15 13:42:45 -04:00
PX4 BuildBot ed7d97bdeb Update submodule sitl_gazebo to latest Sun Mar 15 12:39:22 UTC 2020
- sitl_gazebo in PX4/Firmware (64c7b4d489): https://github.com/PX4/sitl_gazebo/commit/458e58f7973df2e211648e78b7277deefa59eca6
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/11b6409df9f2087c6069ba4db29ae8cef33622da
    - Changes: https://github.com/PX4/sitl_gazebo/compare/458e58f7973df2e211648e78b7277deefa59eca6...11b6409df9f2087c6069ba4db29ae8cef33622da

    11b6409 2020-03-13 JaeyoungLim - Update usv dynamics headers to Apache
5d0356a 2020-03-13 JaeyoungLim - Fix typhoon not taking off
2020-03-15 17:39:32 +00:00
Paul Riseborough ab92b46e69 Update ecl to add ability to recover from bad magnetic yaw
* msg: Add EKF-GSF yaw estimator logging data
* ecl: update to version with EKF-GSF yaw estimator
* ekf2: Add param control and logging for EKF-GSF yaw estimator
* logger: Add logging for EKF-GSF yaw esimtator
2020-03-15 12:57:25 -04:00
Daniel Agar 422e89b1c0 iSentek IST8308 magnetometer driver 2020-03-15 12:27:01 -04:00
Daniel Agar 64c7b4d489 parameters: handle MC_DTERM_CUTOFF -> IMU_DGYRO_CUTOFF migration 2020-03-15 09:31:45 +01:00
Lorenz Meier 3aec557b42 Gazebo: Do not run verbose
There is no need in day-to-day development to run verbose and it is preventing regular PX4 status output from properly rendering
2020-03-15 09:29:34 +01:00
Daniel Agar 5fcd7932e9 mavlink: replace MavlinkOrbSubscription with uORB::Subscription
* uORB orb_stat() and update(uint64_t *time, void *dst) are now obsolete and have been deleted
 * mavlink messages add more advertised checks in streams get_size() check to improve data rate calculation across different scenarios
2020-03-14 12:52:46 -04:00
Lorenz Meier 4f2d39cb15 SITL plane: Do not configure trigger
We have a plane_cam configuration for survey applications instead.
2020-03-14 17:50:40 +01:00
Lorenz Meier 35ed5607b4 Mission feasibility checker: Prevent zero-length trajectories
The mission logic depends in a number of locations on being able to calculate the direction from one waypoint to another. Missions that have waypoints that are in the same physical location do not make sense and need to be rejected (the GCS / SDK generating them needs to be fixed). By enforcing this we can work with a reasonable and simpler state machine while executing the mission.
2020-03-14 17:50:40 +01:00
Lorenz Meier 76d20be29d Mission block: Gate math cleanup and checks
This change simplifies the gate calculation.
2020-03-14 17:50:40 +01:00
Lorenz Meier 4876e7bd6b Navigator: Improve documentation of mission block
The default for the gate check condition is to pass and this needed to be explicitly documented
2020-03-14 17:50:40 +01:00
Lorenz Meier 5e7ff47aac Navigator: Improve code readibility
This diff does not contain any functional changes but just makes the code more readable and adds comments.
2020-03-14 17:50:40 +01:00
Lorenz Meier 417d172a72 Navigator: Warn only for non-zero missions
Previously a zero-length mission that failed checks
(e.g. because a mandatory element was not present) would lead to a
warning.
2020-03-14 17:50:40 +01:00
Lorenz Meier 39e473f988 Gazebo plane model: Enable tighter turns
This helps to fly smaller / faster test missions.
2020-03-14 17:50:40 +01:00
Lorenz Meier 027e52d402 Camera trigger: Improve code readability
This helps to trace the code, no functional changes.
2020-03-14 17:50:40 +01:00
Lorenz Meier 8a6d444467 Enable Gazebo mock optical flow 2020-03-14 17:50:40 +01:00
Lorenz Meier f1f185d209 Mission feasibility checker: Handle mission with zero elements silently
A mission with zero elements is invalid but should not lead to a warning. Previously a fixed wing aircraft without a mission did emit warnings about a missing land item.
2020-03-14 17:50:40 +01:00
Lorenz Meier 09595f88fc Mission block: Style improvement
Boolean logic improvement to avoid double assignment of true
2020-03-14 17:50:40 +01:00
Lorenz Meier 76b3c18625 Add dedicated survey camera plane model
This is to allow us to test triggering properly in SITL
2020-03-14 17:50:40 +01:00
Lorenz Meier 320cc8bae6 POSIX SITL: Enable trigger control in plane model
This allows to test plane survey missions with the camera trigger included in SITL.
2020-03-14 17:50:40 +01:00
Lorenz Meier 5936844595 Update to latest mission API 2020-03-14 17:50:40 +01:00
Lorenz Meier b405c7e9bd Navigator: Add ability to wait for a position gate with executing the mission
This enables the navigator to wait for a specific gate coordinate to pass orthogonally to the current trajectory. This is particularly helpful for payload / camera handling in missions and avoids a dependency of payload handling on navigation waypoints.
2020-03-14 17:50:40 +01:00
Lorenz Meier ed8cb1c5a7 MAVLink: Add support for new gate command
This enables the vehicle to be able to wait with executing the next item until a position has been passed.
2020-03-14 17:50:40 +01:00
Lorenz Meier 8842977d80 Camera trigger: Handle trigger distance handling better 2020-03-14 17:50:40 +01:00
Lorenz Meier cb63fcdcc4 Vehicle command: Add mission item to gate mission execution on line orthogonal to current trajectory 2020-03-14 17:50:40 +01:00
BazookaJoe1900 5e343b104e logger: using ModuleParams (#14316)
and some cleanups on main()
2020-03-13 11:31:43 +01:00
Daniel Agar 0eca583ecf sensors: move baro aggregation to new sensors/vehicle_air_data 2020-03-12 19:06:34 -04:00
Daniel Agar 093e9ba1ce mc_rate_control: use vehicle_angular_acceleration topic instead of differentiating
* mc_rate_control: use vehicle_angular_acceleration topic
* IMU_DGYRO_CUTOFF change default to 30 Hz
* improve IMU_DGYRO_CUTOFF param documentation (updated from MC_DTERM_CUTOFF)
2020-03-12 15:07:03 -04:00
Daniel Agar 2b03aa3d1b px4_fmu-v2: disable vtol_att_control to save flash 2020-03-12 14:10:39 -04:00
Matthias Grob 2dccc0dcfc posix.h: remove duplicate stdint.h include 2020-03-12 17:49:37 +00:00
TSC21 69b38c9ced RTPS: add IDs to 'orb_test' related multitopics 2020-03-12 11:10:50 +00:00
PX4 BuildBot 2da38ae81c Update submodule matrix to latest Thu Mar 12 00:38:40 UTC 2020
- matrix in PX4/Firmware (db0c95ed5620e8ffad3dd3281b511cf5f9ee7848): https://github.com/PX4/Matrix/commit/649c837b6b53fcc8b6fedb047dcc757b8cbaf44b
    - matrix current upstream: https://github.com/PX4/Matrix/commit/4873dc1c1e74f492ec0fcd5b493c9b500f2784fa
    - Changes: https://github.com/PX4/Matrix/compare/649c837b6b53fcc8b6fedb047dcc757b8cbaf44b...4873dc1c1e74f492ec0fcd5b493c9b500f2784fa

    4873dc1 2020-03-04 kritz - Analytic inverse implementation (#122)
2020-03-12 00:01:38 -04:00
Daniel Agar a89b69b0ea vehicle_global_position: remove velocity fields (duplicates of local vx, vy, vz)
* attitude_estimator_q: get velocity from local position (if available)
2020-03-11 23:57:43 -04:00
Daniel Agar 5d33b9e999 delete Outback Challenge (OBC) AUTO_RTGS (datalink loss) and AUTO_RCRECOVER (rc loss) 2020-03-11 22:45:55 -04:00
Daniel Agar 0ce9e113ff boards: stm32f4/f7 enable SPI_DMATHRESHOLD=32 2020-03-11 22:08:37 -04:00
Beat Küng 179c89b6bd board configs: extend board_dma_map.h with a table 2020-03-11 22:08:37 -04:00
Daniel Agar aeff85322d px4_fmu-v2: leave SPI DMA disabled for now (flash space) 2020-03-11 22:08:37 -04:00
Daniel Agar c8509892a6 intel_aerofc-v1: add board_dma_map.h and enable SPI1 DMA 2020-03-11 22:08:37 -04:00
Daniel Agar 8c2ba5f39f mro_x21-777: add board_dma_map.h and enable SPI1 DMA 2020-03-11 22:08:37 -04:00
Daniel Agar 38a10fc7fc mro_x21: add board_dma_map.h and enable SPI1 DMA 2020-03-11 22:08:37 -04:00
Daniel Agar f309e3a5ba mro_ctrl-zero-f7: add board_dma_map.h and enable SPI1/SPI5 DMA 2020-03-11 22:08:37 -04:00
Daniel Agar 5660ea0fd2 av_x-v1: add board_dma_map.h and enable SPI1/SPI2 DMA 2020-03-11 22:08:37 -04:00
Daniel Agar 98108bc4da airmind_mindpx-v2: add board_dma_map.h and enable SPI1 DMA 2020-03-11 22:08:37 -04:00
Daniel Agar e24fcee214 modalai_fc-v1: add board_dma_map.h and enable SPI1/SPI2 DMA 2020-03-11 22:08:37 -04:00
Daniel Agar 01b90fefaf uvify_core: add board_dma_map.h and enable SPI1 DMA
- synced with px4_fmu-v4
2020-03-11 22:08:37 -04:00
Daniel Agar 772ddd7f5e px4_fmu-v2/v3: add board_dma_map.h and enable SPI1/SPI4 DMA 2020-03-11 22:08:37 -04:00
Daniel Agar bd16c2b4f6 px4_fmu-v5x: add board_dma_map.h and enable SPI{1,2,3} DMA 2020-03-11 22:08:37 -04:00
Daniel Agar 6ed4b6978e px4_fmu-v5: add board_dma_map.h and enable SPI1 DMA 2020-03-11 22:08:37 -04:00
Daniel Agar 6834f089cc px4_fmu-v4pro: cleanup board_dma_map.h 2020-03-11 22:08:37 -04:00
Daniel Agar 147e37ac88 px4_fmu-v4: cleanup board_dma_map.h 2020-03-11 22:08:37 -04:00
Daniel Agar f9794e99f8 move hover_thrust_estimator to new module (mc_hover_thrust_estimator)
* MC_HTE: unitialize with hover_thrust parameter
* MC_HTE: constrain hover thrust setter between 0.1 and 0.9
* MC_HTE: integrate with land detector and velocity controller
* MCHoverThrustEstimator: Always publish an estimate even when not fusing measurements. This is required as the land detector and the position controller need to receive a hover thrust value.

* MC_HTE: use altitude agl threshold to start the estimator
local_position.z is relative to the origin of the EKF while dist_bottom
is above ground

Co-authored-by: bresch <brescianimathieu@gmail.com>
2020-03-11 21:20:54 -04:00
David Sidrane 4b9e6964f4 uavcan:Support runtime setting of CAN interfaces 2020-03-11 20:36:58 -04:00
David Sidrane 82ab1413fc px4_fmu-v5:Add Manifest Entries for UAVCAN interfaces 2020-03-11 20:36:58 -04:00
Daniel Agar 46a09b711f boards: increase STDIO buffer size where we can afford it 2020-03-11 17:19:44 -04:00
Daniel Agar 9cd8bb4f88 sensors: move to WQ
Running the sensors module out of the same WQ thread as the estimator, position, and attitude controllers is a bit safer and prevents potential priority and starvation issues. There is a very small increase in latency (~50 us) between sensors and ekf2 execution (on average). This also saves a little bit of memory (~ 3 kB) and cpu (~1-1.5% depending on the board).
2020-03-11 11:34:04 -04:00
TSC21 2b8eb736e1 microRTPS: timesync: fix comment indentation 2020-03-11 15:13:07 +00:00
TSC21 21f0d99145 microRTPS: RtpsTopics: code specialization simplification 2020-03-11 15:13:07 +00:00
TSC21 e9bc675bfa microRTPS: agent: simplify Publisher code specialization 2020-03-11 15:13:07 +00:00
TSC21 296714a00a microRTPS: agent: simplify Subscriber code specialization 2020-03-11 15:13:07 +00:00
TSC21 99f96437c3 microRTPS: timesync: add getters and setter to generalize interface 2020-03-11 15:13:07 +00:00
TSC21 7612879ffd microRTPS: use FastRTPS version instead of FastRTPSGen version to generate conditional code 2020-03-11 15:13:07 +00:00
TSC21 c7d86b73d4 microRTPS: RtpsTopics: generalize types and member functions access 2020-03-11 15:13:07 +00:00
Daniel Agar 4afd7a53e8 Update submodule mavlink v2.0 to latest Wed Mar 11 12:38:12 UTC 2020
- mavlink v2.0 in PX4/Firmware (ff9249f48e191abb173469acfadf79b0771de4d1): https://github.com/mavlink/c_library_v2/commit/a66fd2081d4ff64f2bc32573b585d0c00dfef59e
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/e8bdbcfbacccd79fc678f5c6755c8fb680021199
    - Changes: https://github.com/mavlink/c_library_v2/compare/a66fd2081d4ff64f2bc32573b585d0c00dfef59e...e8bdbcfbacccd79fc678f5c6755c8fb680021199
2020-03-11 09:46:57 -04:00
PX4 BuildBot 190ee042eb Update submodule sitl_gazebo to latest Wed Mar 11 12:38:07 UTC 2020
- sitl_gazebo in PX4/Firmware (88c9761f1f): https://github.com/PX4/sitl_gazebo/commit/8569aec5bb709acb2fec7ccb5a5a4405f0cdec2a
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/458e58f7973df2e211648e78b7277deefa59eca6
    - Changes: https://github.com/PX4/sitl_gazebo/compare/8569aec5bb709acb2fec7ccb5a5a4405f0cdec2a...458e58f7973df2e211648e78b7277deefa59eca6

    458e58f 2020-03-10 JaeyoungLim - Fix sweep cosine (Continuing #302) (#429)
ea2568d 2019-12-27 JaeyoungLim - Increase rudder angle limit
8b905c9 2019-12-27 JaeyoungLim - Add rudder control to sitl
08f8e6f 2020-03-10 Jan-Hendrik Ewers - Update README.md
de10edd 2020-03-10 iwishiwasaneagle - Fixes PX4/sitl_gazebo#424 for arch and ubuntu
4f596be 2020-03-10 Christian Clauss - Remove unused function isstring() in scripts/names.py (#346)
89db01c 2020-03-09 Matej Frančeškin - Handle MAV_CMD_SET_CAMERA_MODE
dae26ba 2020-03-08 JaeyoungLim - Handle videostream info and status
c13057d 2020-03-07 JaeyoungLim - Clear formatting and cleanups
639a6bb 2020-03-07 JaeyoungLim - Add parachute plugin
42d05bd 2020-03-09 RomanBapst - standard vtol: decrease rotorDragCoefficient to more realistic values
5669e5c 2020-03-07 leftytechie - Version check (#418)
82657d3 2020-03-07 Lorenz Meier - Fix geotagged images GPS position The GPS position was invalid, leading to incorrectly displayed geotag markers and to incorrect geotags in images.
8794a70 2020-03-02 Julian Oes - cmake: remove warning
7aba744 2020-02-26 TSC21 - gazebo_mavlink_interface: use class enum; use binary notation with the bitmask operations
0dc43a4 2020-02-26 TSC21 - gazebo_mavlink_interface: make sure to always send gyro and accel data in the HIL_SENSOR msgs
0c954a2 2020-02-25 TSC21 - mavlink_interface: split groundtruth stream from sensor stream; only apply rotations where needed
bc92d96 2020-02-25 TSC21 - set baro rate at 50Hz (averaging the PX4 baro drivers ODR)
94d16e6 2020-02-25 TSC21 - update magnetometer rate to 100Hz (fitting the ODR in most of the support PX4 mag drivers)
6cae120 2020-02-25 TSC21 - mavlink_interface: send HIL_SENSOR messages with the bitmask correctly defined IOT set each sensor stream rate separately
2020-03-11 09:45:35 -04:00
PX4 BuildBot 249ad0ced1 Update submodule nuttx to latest Wed Mar 11 12:38:18 UTC 2020
- nuttx in PX4/Firmware (ac11b36e74e27ef7054d6386f0fce62108b5f614): https://github.com/PX4/NuttX/commit/bf646dcf46ac4a18c29b1cab4aa5e7a54280782e
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/db7fb6b6c07120fe97c5c7c1b2fdb46f32b190bc
    - Changes: https://github.com/PX4/NuttX/compare/bf646dcf46ac4a18c29b1cab4aa5e7a54280782e...db7fb6b6c07120fe97c5c7c1b2fdb46f32b190bc

    db7fb6b6c0 2020-03-05 Jari van Ewijk - [BACKPORT] S32K1xx boards - Remove unused files (should have been renamed)
2020-03-11 09:45:00 -04:00
modaltb 707c840fd9 boards/modalai/fc-v1: Maintenance Updates
* Add Drotek RM3100 mag to board_sensors
 * update to single wire
 * Fix inverted FMU outputs from https://github.com/PX4/Firmware/commit/451af074726e1c43f2b1c9bb82f3cde50cd74c5c
 * digital power module update for https://github.com/PX4/Firmware/commit/e9890d01d94a75b0926a116243ae3920766bde00
 * board doesn't have battery monitoring through ADC or GPIO, rather through I2C only
2020-03-11 09:25:17 -04:00
Daniel Agar 9585055e9e uORB: add bitset for faster orb_exists check and remove uORB::Subscription lazy subscribe hack/optimization
- add PX4 bitset and atomic_bitset with testing
 - add uORB::Subscription constructor to take ORB_ID enum
 - move orb test messages into msg/
2020-03-11 09:06:33 -04:00
Julian Kent 88c9761f1f Add ccache to github actions 2020-03-11 11:13:49 +01:00
Daniel Agar ab3670e02b github actions upload binaries for NuttX boards (.px4 file) 2020-03-10 13:07:49 -04:00
Daniel Agar 505afc6063 boards: increase LPWORKSTACKSIZE 1536 -> 1600 2020-03-10 12:53:01 -04:00
TSC21 bdb1ae14f5 Jenkins: fix timesync filenames 2020-03-10 14:21:40 +00:00
Beat Küng 335623e11d SPI config: use enum to specify bus 2020-03-10 10:11:43 -04:00
Beat Küng 37846a177c omnibusf4sd: disable landing_target_estimator
to reduce FLASH size
2020-03-10 10:11:43 -04:00
Beat Küng e627fed117 fmu-v2: disable perf command and some airframes
to reduce FLASH size
2020-03-10 10:11:43 -04:00
Beat Küng a2b2605443 param: fix param_get_cplusplus type check 2020-03-10 10:11:43 -04:00
Beat Küng b54e5a1c23 param: automatically update calibration ID params on import
This avoids the need for recalibration, and also cleans up other driver
ID's (merge separate accel/gyro).

The SPI address was previously set to a board-specific (arbitrary) value,
and is now set to 0. This will allow extending for multiple sensors of the
same type on the same bus.
2020-03-10 10:11:43 -04:00
Beat Küng 1851665fab boards: add new spi+i2c config
Chip-select and SPI initialization uses the new config, whereas the drivers
still use the existing defines.

The configuration in board_config.h can be removed after all drivers are
updated.
2020-03-10 10:11:43 -04:00
Beat Küng 06712450a7 i2c+spi: add module base class and bus iterators 2020-03-10 10:11:43 -04:00
Beat Küng af15c7d945 i2c+spi: extend hw_description for I2C + SPI 2020-03-10 10:11:43 -04:00
TSC21 a2c270e484 update files for microRTPS_timesync 2020-03-10 13:12:09 +00:00
TSC21 7c5ec8f8fd add deployment of microRTPS_timesync to px4_ros_com 2020-03-10 12:51:33 +00:00
TSC21 04ec2041e3 microRTPS: timesync: cleanup and style fix 2020-03-10 12:15:18 +00:00
TSC21 512c405834 microRTPS_timesync.h: fix comments notation so to be properly generated in EmPy 2020-03-10 12:15:18 +00:00
TSC21 1893c9e37e microRTPS_timesync.h: add description to functions 2020-03-10 12:15:18 +00:00
TSC21 a3487ab8a3 microRTPS: timesync: fix unit conversion 2020-03-10 12:15:18 +00:00
TSC21 59869b2350 microRTPS_timesync.cpp: fix style 2020-03-10 12:15:18 +00:00
TSC21 7de8bee29e microRTPS: timesync: interpolate 2020-03-10 12:15:18 +00:00
TSC21 2568d9ae20 mavlink: timesync: readd timesync_status uORB to report Mavlink timesync 2020-03-10 12:15:18 +00:00
TSC21 250b6b24ab microRTPS: timesync: properly apply offsets 2020-03-10 12:15:18 +00:00
TSC21 67491b473c microRTPS: add timesync handshake 2020-03-10 12:15:18 +00:00
TSC21 e3e607f600 microRTPS: client: add client response to timesync 2020-03-10 12:15:18 +00:00
TSC21 2ec8958351 microRTPS: microRTPS_timesync: fix template indentation 2020-03-10 12:15:18 +00:00
TSC21 6dea2dd97d microRTPS: agent: make sure that is able to subscribe a timesync stream from itself 2020-03-10 12:15:18 +00:00
TSC21 cfd8e368df microRTPS: timesync: template generalization for both ROS2 and non-ROS2 2020-03-10 12:15:18 +00:00
TSC21 01518bd009 microRTPS: delete run() functions as they are not needed 2020-03-10 12:15:18 +00:00
TSC21 db7d98c16f microRTPS: use char-by-char comparison instead of stringstream comparison 2020-03-10 12:15:18 +00:00
TSC21 80c658c1ae microRTPS: make sure that Sub/Pubs do not exchange data in loop (i.e. for the same entity) 2020-03-10 12:15:18 +00:00
TSC21 441e6290eb microRTPS: timesync: apply offset atomically 2020-03-10 12:15:18 +00:00
TSC21 170835f3f8 microRTPS: add timesync for the agent side 2020-03-10 12:15:18 +00:00
Roman Dvořák 152427ecdc Ability to disable airspeed scaling (#14334) 2020-03-10 12:57:36 +01:00
Roman Dvořák 05caa1f2d4 Update README, add autogyro to supported airframes 2020-03-10 08:56:33 +01:00
RomanBapst 4ddf0f9dc1 ekf2_main.cpp: fixed bug in the calculation of the mag bias calibration time
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-03-10 08:54:04 +01:00
Roman Dvořák e43aa4e287 logger: add RPM sensor messages 2020-03-09 18:34:06 -04:00
Alexey Matveev baf3cd5c30 Up stack for frsky_telemetry 2020-03-09 17:02:54 -04:00
Beat Küng 3fef401e81 uorb callbacks: fix unregister ordering to avoid race conditions
The order should be: first unregister, then remove the item from the
runnable queue.
2020-03-09 08:06:00 -04:00
Beat Küng 18bc6cf872 ScheduledWorkItem::ScheduleClear: remove item from runnable queue
The existing behavior is unexpected: if the work item is already on the
runnable queue, it will still be triggered after a call to ScheduleClear().
This can lead to race conditions.
2020-03-09 08:06:00 -04:00
Beat Küng 977b80cee9 omnibus: enable DMA on SPI2 (SD Card)
Reduces CPU load by ~10%, and allows to comfortably run the rate loop at
2kHz.
2020-03-09 12:47:43 +01:00
Julian Kent eab88294f8 Add documenation to uORB message 2020-03-09 09:51:49 +01:00
Julian Kent 36c307a39e Provide a dummy avoidance for flash constrained boards
Part of this: move ObstacleAvoidance to a library
2020-03-09 09:51:49 +01:00
Julian Kent 4bf34a75db Indicate that omnibus_f4sd is constrained in flash 2020-03-09 09:51:49 +01:00
Julian Kent 5169cfcc45 Add bezier trajectory tracking in obstacle avoidance 2020-03-09 09:51:49 +01:00
Julian Kent d2507e831e Add mavlink parsing for bezier message 2020-03-09 09:51:49 +01:00
Julian Kent 6e1185d4f2 Add uORB messages for bezier curve trajectories 2020-03-09 09:51:49 +01:00
Julian Kent 5b8aa20c2f Bezier trajectory functions to get position, velocity, accel on trajectory 2020-03-09 09:51:49 +01:00
Matej Frančeškin b8970673c6 Fixed Mavlink FTP tests 2020-03-08 21:43:54 +01:00
Matej Frančeškin ef865a091f Added FileNotFound error code according to new Mavlink FTP specification 2020-03-08 21:43:54 +01:00
Katrin 116de6d25f Airframe and mixer for rover DF Robot GPX:Asurada (#14244)
Added Airframe and mixer for rover DF Robot GPX:Asurada

Co-authored-by: Julian Oes <julian@oes.ch>
Co-authored-by: Lorenz Meier <lorenz@px4.io>
2020-03-08 14:35:24 +01:00
bazooka joe 887d846f7a remove one space from string sent with the logger filename
now the full file name is sent, and not missing the last seconds digit
2020-03-08 12:07:51 +01:00
JacobCrabill b186614857 airframes srcparser.py: Allow non-param comments
Add a "@desc" tag that gets ignored by the parameter parser.  This
allows you to add (multi-line) documentation to airframe init files.
2020-03-08 12:00:29 +01:00
斯东Stone 032b9909fa Fix a typo in Ubuntu setup script 2020-03-08 11:56:33 +01:00
Dusan Zivkovic d7a9b123e6 logger: fix thread deadlock 2020-03-06 13:37:34 +01:00
Daniel Agar 4698a09b98 delete unmaintained outback challenge (OBC) bottle drop example 2020-03-05 14:09:31 -05:00
David Sidrane 25c12d8b9e px4_fmu-v5x:Add Serial test 2020-03-05 13:40:11 -05:00
Silvan Fuhrer b9fab04adb tiltrotor: improve comments and renaming of one variable
This is to point out that also rear motor can be used in FW flight and not only the front motors

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-03-05 11:49:42 +03:00
bresch 2d009e2e7a ecl: update submodule
- reduce CPU load
- fix earth rate gyro compensation
- make test with clang
- use switch statements in controlHeightFusion

Diff:
https://github.com/PX4/ecl/compare/3fa5f501ae7edc4a793f0973e156706afcc8b419..230c865fa9c02b07b0371df050b339bc37ce0c29
2020-03-04 23:59:24 +01:00
CarlOlsson 8de1f5229b EKF2: use fixed time constant for GPS blending
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2020-03-04 16:46:20 +01:00
CarlOlsson 357700aa8d EKF2 GPS blending: fall out of blending if one module lose 3D fix
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2020-03-04 16:46:20 +01:00
CarlOlsson a10a228092 EKF2 GPS blending: reset relative position offsets if blending not feasible
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2020-03-04 16:46:20 +01:00
Julian Oes 2b087a92c2 commander: increment is 1 for int params 2020-03-04 09:35:14 +01:00
Julian Oes 874c6f385b commander: unify offboard timeouts
The implementation before this change had two timeouts, a hard-coded
timeout of 0.5 seconds as well as a by param configurable timeout with
certain failsafe actions set.

This change aims to fix two problems:
1. The hard-coded offboard timeout can be triggered easily with sped up
   lockstep simulation. Since i t is hard-coded it can't be adapted to
   the speed factor.
2. The offboard signal can time out but no action will be taken just
   yet. This means we end up in an in-between stage where no warning or
   failsafe action has happened yet, even though certain flags are set
   to a timeout state.

This patch aims to fix this by unifying the two timeouts to the existing
configurable param. The convoluted double timeout logic is replaced by a
simple hysteresis.

For anyone that has previously not changed the default timeout param (0),
the param will now be changed to 0.5 seconds which reflects the
previously hardcoded time. For anyone with a specific timeout
configured, the behaviour should remain the same.

Also, going forward, timeouts lower than 0.5 seconds should be possible.
2020-03-04 09:35:14 +01:00
Daniel Agar fca7700746 Update submodule nuttx to latest Wed Mar 4 01:36:16 UTC 2020
- nuttx in PX4/Firmware (b7a83e23c5e50896bb137266cf89ff928dfaae42): https://github.com/PX4/NuttX/commit/d509b1edd736cb7db509a9c86e7ffcde10c4fd45
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/bf646dcf46ac4a18c29b1cab4aa5e7a54280782e
    - Changes: https://github.com/PX4/NuttX/compare/d509b1edd736cb7db509a9c86e7ffcde10c4fd45...bf646dcf46ac4a18c29b1cab4aa5e7a54280782e

    bf646dcf46 2020-03-03 Daniel Agar - [BACKPORT] stm32h7: spi_exchange (no dma) available with CONFIG_STM32H7_SPI_DMATHRESHOLD
    f2a7ef0ade 2020-03-03 Daniel Agar - [BACKPORT] stm32f7: spi_exchange (no dma) available with CONFIG_STM32F7_SPI_DMATHRESHOLD
    7ffc59ba3d 2020-03-03 Daniel Agar - [BACKPORT] stm32: spi_exchange (no dma) available with CONFIG_STM32_SPI_DMATHRESHOLD
    d1c8fdb5fb 2020-03-02 Daniel Agar - [BACKPORT] arm/stm32h7 add STM32H7_SPI_DMATHRESHOLD
    fa8d636118 2020-03-02 Daniel Agar - [BACKPORT] stm32f76xx77xx_dma.h fix DMAMAP_SPI2_RX_2/DMAMAP_SPI2_TX_2
    762d80b217 2020-03-02 Daniel Agar - [BACKPORT] arm/stm32f7 add STM32F7_SPI_DMATHRESHOLD
    4f4bbbbf1c 2020-03-02 Daniel Agar - [BACKPORT] arm/stm32 add STM32_SPI_DMATHRESHOLD

Co-authored-by: PX4 Build Bot <bot@px4.io>
2020-03-03 20:56:48 -05:00
Julian Oes 581b92dd3f attitude_estimator_q: enable lockstep without LPE
When lockstep is enabled and LPE is not running, the
attitude_estimator_q needs to publish ekf2_timestamps in order to signal
to the simulator module that it has fully run.

This essentially fixes flying in lockstep when SYS_MC_EST_GROUP is 3.
2020-03-03 09:31:52 +01:00
David Sidrane ee220a5086 px4_fmuv5x:Update manifest for USB not present 2020-03-02 19:59:36 -05:00
David Jablonski ff4ec31d29 templated creation of stream list items
and constexpr for get_id_static and get_name_static in mavlink streams
2020-03-02 19:56:16 -05:00
David Jablonski f57c5ef4a7 Mavlink: implemented SCALED_PRESSURE streams 2020-03-02 19:56:16 -05:00
PX4 BuildBot 862cb2052c Update submodule ecl to latest Mon Mar 2 12:39:50 UTC 2020
- ecl in PX4/Firmware (43aab81fdebc5c70d8ddb9285ee1e5005f4ee8a1): https://github.com/PX4/ecl/commit/05d391c7852c3591b606af9ae78301eff933eacc
    - ecl current upstream: https://github.com/PX4/ecl/commit/3fa5f501ae7edc4a793f0973e156706afcc8b419
    - Changes: https://github.com/PX4/ecl/compare/05d391c7852c3591b606af9ae78301eff933eacc...3fa5f501ae7edc4a793f0973e156706afcc8b419

    3fa5f50 2020-02-27 Carl Olsson - EKF: dont check gps_check_fail_status in velocity reset (#761)
71d4d22 2020-02-21 Daniel Agar - EKF: covariances() helper return const reference and fix code style
8b91856 2020-02-21 bresch - ekf: fix angle wrapping in realignYawGPS
00872fc 2020-02-18 Daniel Agar - EKF: ImuDownSampler pass imuSample as const reference
81c6d66 2020-02-13 bresch - ekf: clean uncorrelateQuatStates function
c6d5a74 2020-02-12 Julian Kent - Update change indicator
2020-03-02 14:03:21 -05:00
Julian Kent 770c724f17 Adapt run-clang-tidy.py to Python3 2020-03-02 13:26:03 -05:00
Julian Kent 50577732b7 Fix run-clang-tidy.py path 2020-03-02 13:26:03 -05:00
David Sidrane 431f7c16c8 NuttX with PX4 Contrib backported imxrt:Call out to board to set up FlexRAM 2020-03-02 10:20:33 -08:00
David Sidrane cad3a811d2 nxp_fmurt1062-v1:Run from OCRAM 2020-03-02 10:20:33 -08:00
David Sidrane e12bce3a20 px4_add_board:Add Optional LINKER_PREFIX 2020-03-02 10:20:33 -08:00
David Sidrane 3ed643f3d7 fmurt1062-v1:Update imxrt_flexspi_nor_boot configurable 2020-03-02 10:20:33 -08:00
Julian Kent e173df80a1 Improve readibility of ternary 2020-03-02 18:10:52 +01:00
Martina Rivizzigno 678e32caf7 CollisionPrevention remove mavlink_log outputs 2020-03-02 16:49:56 +01:00
Martina Rivizzigno a9491dfaf7 run avoidance also in Loiter 2020-03-02 16:49:56 +01:00
Martina Rivizzigno aee1e70642 check avoidance status in commander and set sys status
remove mavlink log
2020-03-02 16:49:56 +01:00
Martina Rivizzigno 48b7cd926e mavlink_messages: add frame field to obstacle distance and correct typo 2020-03-02 16:49:56 +01:00
Martina 9d06bd1383 mavlink_main: add osbstacle_distance stream to extvisionmin mode 2020-03-02 16:49:56 +01:00
Martina a4acb6b92a CollisionPrevention: set frame for obstacle_distance_fused topic 2020-03-02 16:49:56 +01:00
baumanta 7801ed129f Add safety measure and test for missing sensor data 2020-03-02 16:49:56 +01:00
baumanta 67d0f5c5d1 CollisionPrevention: No movement if FOV is zero 2020-03-02 16:49:56 +01:00
TSC21 39317e9207 update submodule Tools/jMAVSim 2020-03-02 14:59:45 +00:00
Silvan Fuhrer 9edb1179d0 VTOL: run vtol state update not only when mc or fw sp are updated, but always
This change is necessary to give the pilot the ability to switch VTOL state
even if for some reason no attitude sp are published anymore.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-03-02 14:10:58 +03:00
Lorenz Meier 3a2f15eba1 License: It is 2020 now
This is not significant, but it is always a good idea to show that things are actively maintained.
2020-03-02 08:27:40 +01:00
Daniel Agar 60cd6f9e90 vscode: possible improvements for cpp extension cpu usage 2020-03-01 12:44:13 -05:00
David Sidrane 64cf310c8a Uavcan:Fix null pointer defrefenence 2020-02-29 11:26:35 +01:00
TSC21 993755b24b bitmask.h: compile only if in POSIX/LINUX platforms 2020-02-28 10:59:50 +00:00
TSC21 f5000a9691 px4_platform_common: add bitmask.h for templated type safe bitmask operations 2020-02-28 10:59:50 +00:00
TSC21 8a999fecfc update submodule Tools/sitl_gazebo 2020-02-28 10:59:50 +00:00
TSC21 d1cefe9e65 simulator: move enum declaration out of preprocessor condition 2020-02-28 10:59:50 +00:00
TSC21 b3ea28c8e4 update submodule Tools/sitl_gazebo 2020-02-28 10:59:50 +00:00
TSC21 bcb6056a12 simulator: make sensor update rate dependent of the HIL_SENSOR bitmask 2020-02-28 10:59:50 +00:00
Daniel Agar e6ab5fc2a8 HIL test runner temporarily disable uORB test and fix typo 2020-02-28 10:03:39 +01:00
Florian Achermann be35f5555c Add comment to explain iridium exception in the mavlink module 2020-02-28 07:54:25 +01:00
Florian Achermann eb215358fc Fix crashing for the mavlink in the iridium mode
Special handling in the mavlink_open_uart function if mavlink is in the iridium mode.
2020-02-28 07:54:25 +01:00
Daniel Agar d7e502ec72 uORB_tests increase stack 2020-02-27 21:12:49 +01:00
Matthias Grob f90d3671c0 vehicle_attitude_setpoint: get rid of unused q_d_valid flag 2020-02-27 09:17:52 +01:00
Julian Oes b53bd2b77f LPE: make compatible with lockstep simulation
This fixes SITL with lockstep when using LPE and q estimator.

The required changes are:
- Publish ekf2_timestamps because simulator_mavlink expects them.
- Run LPE at 250 Hz instead of 80 Hz in order to keep everything in
  lockstep running at 250 Hz.
2020-02-26 15:46:58 +01:00
Julian Oes 3be8b3d177 logger: style fix 2020-02-26 14:52:39 +01:00
Julian Kent 18754225c9 Update matrix library 2020-02-26 10:27:32 +01:00
Matthias Grob 46f76cb621 Commander: enable RC override in takeoff
and remaining auto modes which are used more rarely.
2020-02-26 10:22:33 +01:00
Paul Riseborough d9ae242760 logger: fix unused variable build error 2020-02-26 18:44:20 +11:00
Daniel Agar 2a0fe169e6 logger: disable logger_status publiation in replay builds
- this is disabled in replay builds to ensure all data in ekf2 replay logs only contains the same time range, otherwise the plots can be unreadable using common tools
 - fixes #14230
2020-02-26 18:44:20 +11:00
CarlOlsson 7e00dcd382 EKF2: Fix GPS blending time jitter 2020-02-26 07:39:47 +01:00
JaeyoungLim a38b167614 Update: sitl_gazebo 2020-02-26 07:29:16 +01:00
Martina Rivizzigno abe33af5b3 map mavlink orientation enum to uorb distance_sensor orientation 2020-02-26 07:27:09 +01:00
Daniel Agar 779ba0fda5 px4_fmu-v4/v4pro: switch to new InvenSense icm20602/icm20608g IMU drivers
* 8 kHz gyro, 4 kHz accel
 * DLPF disabled
 * scheduled using data ready interrupts
 * FIFO is emptied at 1 kHz by default, but can adjusted via IMU_GYRO_RATEMAX from 250 Hz - 2000 kHz.
 * On both px4_fmu-v4 and px4_fmu-v4pro the secondary IMU is an mpu9250 with the same driver
2020-02-26 01:19:12 +01:00
Julian Kent 5bf2648c1f Add debugger options for mavsdk test runner 2020-02-25 17:15:40 +01:00
Beat Küng 77b854b7c3 omnibus: enable SPI dma + use new ICM-20602 driver (disabled DLPF) 2020-02-25 09:59:52 +01:00
Beat Küng d386591d0c logger: reduce rate_ctrl_status rate to 50 Hz for high-rate logging
The integral does not need to be logged at full rate
2020-02-25 09:59:52 +01:00
BazookaJoe1900 27471d90ca Jenkins: hardware test exit from failed hardware check with error, so the check will fail 2020-02-25 09:58:02 +01:00
Julian Oes f3fefd7d93 mavlink: support mission transfer cancellation (#14139)
This adds support for MAV_MISSION_OPERATION_CANCELLED which can be used
to cancel an ongoing upload or download of mission/geofence/rally items.
2020-02-24 07:47:08 +01:00
Silvan Fuhrer 6c8f39c5d8 MC rate controller: limit K and P values of PID controller to in pitch and roll (#14210) 2020-02-23 11:45:07 +01:00
Daniel Agar af6213e85e invensense icm20689 improvements and fixes
- refactor Run() into simple state machine
 - perform reset and configuration in sensor bus thread
 - when using data ready interrupt skip checking FIFO count
 - fix periodic temperature sampling (rate limit to 1 Hz)
2020-02-22 12:15:52 -05:00
Daniel Agar 5ab4cf3d62 invensense mpu9250 improvements and fixes
- refactor Run() into simple state machine
 - perform reset and configuration in sensor bus thread
 - when using data ready interrupt skip checking FIFO count
 - fix periodic temperature sampling (rate limit to 1 Hz)
2020-02-22 12:15:52 -05:00
Daniel Agar 4bd665d169 invensense icm20608g improvements and fixes
- refactor Run() into simple state machine
 - perform reset and configuration in sensor bus thread
 - when using data ready interrupt skip checking FIFO count
 - fix periodic temperature sampling (rate limit to 1 Hz)
2020-02-22 12:15:52 -05:00
Daniel Agar afc59f843c invensense icm20602 improvements
- refactor Run() into simple state machine
 - perform reset and configuration in sensor bus thread
 - when using data ready interrupt skip checking FIFO count
2020-02-22 12:15:52 -05:00
Beat Küng 0c6d558c50 bmp388: fix double free in case the driver probing fails
'interface' is freed in BMP388's destructor.
2020-02-22 10:51:42 -05:00
Beat Küng c5a0d9077b bmp388: remove dead code 2020-02-22 10:51:42 -05:00
Timothy Scott 4c1adc088f Removed all swapping of uORB instances 2020-02-21 22:38:26 -08:00
Timothy Scott 6452b7e014 Changed commander to check every battery publication for prearm checks 2020-02-21 22:38:26 -08:00
Julian Oes 43a1257843 ROMFS: prevent auto-disarm before takeoff in CI
Sometimes in CI for VTOL we saw disarms before the spoolup and ramp were
over and the takeoff would actually happen. By raising the auto-disarm
time we should be able to work around this and get CI less flaky.
2020-02-21 09:58:21 -05:00
SalimTerryLi 77a9135036 ADC driver report back vref alone with sample count (#14136)
* Introduce "px4_arch_adc_reference_v"

* Revert "Introduce "px4_arch_adc_reference_v""

This reverts commit 93691fbbd55a1b8da8c190e225b318067d90399b.

* use structure to return sample count and vref at the same time

* Revert "use structure to return sample count and vref at the same time"

This reverts commit 9cfd1c173cda51495f766a3f678c2202d67725fd.

* Revert "Revert "Introduce "px4_arch_adc_reference_v"""

This reverts commit edb7f7603e4471163ffb0fc6fc62ad2e30336e91.

* fix missed reference

* remove unecessary channel specific vref

* Update src/drivers/drv_adc.h

Co-Authored-By: David Sidrane <David.Sidrane@Nscdg.com>

* Update src/drivers/drv_adc.h

Co-Authored-By: David Sidrane <David.Sidrane@Nscdg.com>

* Introduce BOARD_ADC_POS_REF_V

Co-authored-by: David Sidrane <David.Sidrane@Nscdg.com>
2020-02-21 06:52:45 -08:00
JaeyoungLim e0d6f94318 Add boat(usv) sitl target 2020-02-21 00:30:15 -08:00
Morten Fyhn Amundsen 0ac300f77a Rename generate virtual RC setter/getter
The old names were unclear to me, especially when
used in the mavlink_receiver.
2020-02-21 09:23:35 +01:00
Matthias Grob 1d89351149 Commander: clarify the rc override message
Message says novice understanable what happened.
2020-02-20 17:25:53 +01:00
Beat Küng 116a094e31 commander: fix broken 'commander arm/disarm' CLI
Regression from https://github.com/PX4/Firmware/pull/13613.

VEHICLE_CMD_COMPONENT_ARM_DISARM from CLI would enter the
ARMING_STATE_IN_AIR_RESTORE logic. This was never intended for disarming
(and leads to state machine transition failures), and IMO it is also not
intended for commands from CLI.
2020-02-20 10:06:07 -05:00
Julian Oes 20276d4ff8 simulator: improve misleading TCP message
Proposed first by @lovettchris.
2020-02-20 12:10:43 +01:00
Julian Oes e46635b1de simulator: remove strange disarmed PWM
Before that we would send -0.1 instead of just 0.0.

First proposed by @lovettchris.
2020-02-20 12:10:43 +01:00
Julian Oes a006d82abf simulator: add flag to indicate lockstep
This depends on:
https://github.com/mavlink/mavlink/pull/1311

First proposed by @lovettchris.
2020-02-20 12:10:43 +01:00
Beat Küng ef1f677541 fix mavlink_log_handler: close file descriptor if still open in destructor 2020-02-20 10:31:41 +01:00
Julian Oes e7c655ba52 rc_update: make specific RC loss check only on PPM
This makes the check more specific, so it's only active on PPM input.
2020-02-20 09:02:30 +01:00
bozkurthan 3f16eba3f7 RC Failsafe fix for RFD 868+/900 Modems
RC Failsafe isn't triggered when PPM signal is valid. These changes
update Failsafe trigger logic for RC input. RF Modules keep sending
valid PPM signal when the RC Transmitter is lost.
RF Modules which are in the air send PPM signal with same type when lost
the signal from ground.
2020-02-20 09:02:30 +01:00
Nicolas de Palezieux a570aa9fac Commander: fix preflight check condition to fail if not in HIL mode 2020-02-20 08:46:30 +01:00
Daniel Agar ffc3373492 invensense icm20689 improvements
- checked register mechanism and simple watchdog
   - driver checks for errors gradually and can reconfigure itself
 - respect IMU_GYRO_RATEMAX at the driver level
 - fixed sensor INT16_MIN and INT16_MAX handling (y & z axis are flipped before publishing)
2020-02-19 19:01:41 -05:00
JaeyoungLim 01b280f7ae Limit the number of vehicles 2020-02-19 14:23:17 +01:00
JaeyoungLim c89766c8ab Fix gcs udp port to support more vehicles in multivehicle sitl
Limit remote udp port to 14549


Fix


Cleanup port handling


Fix bash syntax


Fix
2020-02-19 14:23:17 +01:00
Daniel Agar 1d226ad2ca invensense icm20608g improvements
- checked register mechanism and simple watchdog
  - driver checks for errors gradually and can reconfigure itself
 - respect IMU_GYRO_RATEMAX at the driver level
 - fixed sensor INT16_MIN and INT16_MAX handling (y & z axis are flipped before publishing)
2020-02-18 22:48:32 -05:00
Daniel Agar 89d4d6e4a9 invensense mpu9250 improvements
- checked register mechanism and simple watchdog
    - driver checks for errors gradually and can reconfigure itself
 - respect IMU_GYRO_RATEMAX at the driver level
 - fixed sensor INT16_MIN and INT16_MAX handling (y & z axis are flipped before publishing)
2020-02-18 19:21:20 -05:00
Daniel Agar 22499effb9 invensense icm20602 improvements
- checked register mechanism and simple watchdog
    - driver checks for errors gradually and can reconfigure itself
 - respect IMU_GYRO_RATEMAX at the driver level
 - fixed sensor INT16_MIN and INT16_MAX handling (y & z axis are flipped before publishing)
 - increased sensor_gyro_fifo max size (enables running the driver much slower, but still transferring all raw data)
 - PX4Accelerometer/PX4Gyroscope remove unnecessary memsets
2020-02-18 19:21:20 -05:00
Daniel Agar 40921241e7 Update submodule mavlink v2.0 to latest Tue Feb 18 12:38:11 UTC 2020
- mavlink v2.0 in PX4/Firmware (396c1080e40bd84a2e1381f666041f7d147b718b): https://github.com/mavlink/c_library_v2/commit/1847cbbff5863db71bf7e3de8c5e8136da784152
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/a66fd2081d4ff64f2bc32573b585d0c00dfef59e
    - Changes: https://github.com/mavlink/c_library_v2/compare/1847cbbff5863db71bf7e3de8c5e8136da784152...a66fd2081d4ff64f2bc32573b585d0c00dfef59e

Co-authored-by: PX4 Build Bot <bot@px4.io>
2020-02-18 18:26:46 -05:00
Julian Oes cf47c2155f platforms: prevent stackoverflow for ekf2 sideslip
It turns out that ekf2 needs more stack when sideslip fusion fails.
Sideslip fusion is currently only enabled for fixedwing by default and
not executed in testing.
2020-02-18 16:42:16 -05:00
JaeyoungLim 7a1464d992 Revert port change (#14177)
Reverts #14126 and #14176 until CI failures can be resolved
2020-02-18 14:56:04 +01:00
Julian Kent e7aa899746 AutoLineSmoothVel: don't use _velocity_setpoint for constraints
Unfortunately the constraints cannot be implemented using the
_constraints because the controller uses that directly. This
causes discontinuities in the velocity and/or accel at various
points of the flight. In particular this was used in Takeoff.

Instead this was done by changing target accel/velocity in the
jerk-optimal velocity planner for Z.
2020-02-18 13:59:58 +01:00
JaeyoungLim b365fbf1e9 Fix bash syntax 2020-02-18 13:55:24 +01:00
JaeyoungLim 30cc3a1243 Cleanup port handling 2020-02-18 13:06:46 +01:00
JaeyoungLim fc61d1c43d Limit remote udp port to 14549
Fix
2020-02-18 13:06:46 +01:00
JaeyoungLim 2bcd8490ff Fix gcs udp port to support more vehicles in multivehicle sitl 2020-02-18 13:06:46 +01:00
Morten Fyhn Amundsen 86bf4b2289 FlightTaskManualAltitude: Fix sign error in terrain hold setpoint reset
The modified statements are intended to

1. Set a new Z position setpoint that is equivalent to the current distance
to ground setpoint,

and

2. Set a new distance to ground setpoint that is equivalent to the current Z
position setpoint.

They are only called in terrain hold mode, when activating/deactivating the
holding (typically when coming to a stop and when starting to move again).

The setpoints take the current control error into account, but because the
control error is added, not subtracted, the result is that the new setpoint
is 2 times the control error off from the old setpoint, instead of being
at the same spot as the old setpoint.
2020-02-17 15:18:04 +01:00
Daniel Agar d7c3e1066a uavcannode updates and px4_fmu-v4_cannode example
- drivers/uavcannode add baro, mag, gps publications
 - delete old px4_cannode-v1 board
 - add stripped down simple rcS for CAN nodes
2020-02-16 12:11:54 -05:00
Silvan Fuhrer 342e0da796 VTOL land detector: extend fall_detection from multicopter land detector and disable in fixed-wing mode
Extend the get_freefall_state() from MC land detector to have a VTOL-specific
one that just enables free fall detection if in rotary wing or transition mode.
This is done to prevent wrong free-fall detected warnings while doing low-G maneuvers
(parabolic flights). Land detection is anyway disabled in FW flight for VTOL so
no logic change.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-02-14 17:46:30 +03:00
Silvan Fuhrer dad9c154a3 VTOL Land Detector: move to airspeed_validated
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-02-14 17:46:30 +03:00
Julian Oes 9a96ca14be Tools: make Python import error more readable
The problem with printing the exception was that starting with
Python 3.6 the ImportError is yet another (sub) exception called
ModuleNotFoundError which can't be printed as a string and then triggers
another exception:

```
Traceback (most recent call last):
  File "/home/julianoes/src/Firmware/Tools/serial/generate_config.py", line 11, in <module>
    import jinja2
ModuleNotFoundError: No module named 'jinja2'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/julianoes/src/Firmware/Tools/serial/generate_config.py", line 13, in <module>
    print("Failed to import jinja2: " + e)
TypeError: must be str, not ModuleNotFoundError
```

As per @bkueng's suggestion the easiest is to cast the exception to str
and that way prevent the second exception.
2020-02-14 11:40:05 +01:00
Nuno Marques 7cafbc824e simulator: add support for multi-distance_sensor instances (#14143)
* simulator: add support for multi-distance_sensor instances

* update submodule Tools/sitl_gazebo

* sitl_gazebo: add updated iris_obs_avoid; simulator: cleanup distance_sensor topic init

* update submodule Tools/sitl_gazebo

* simulator: delete _dist_pubs uORB::PublicationMulti<distance_sensor_s> in simulator destructor
2020-02-14 11:32:28 +01:00
Julian Oes abd2bb4eb7 cmake: fix Python 3 libs name
This was just wrong. `devel` might be correct on Fedora but no on Ubuntu
:).
2020-02-13 09:20:26 -05:00
Nico van Duijn 55372d7cbe Parameterize timeout for radio status 2020-02-13 08:52:27 -05:00
BazookaJoe1900 c78572b471 px4io: fix array regs[] size (#14135)
may cause memory override if _max_controls larger then _max_actuators
2020-02-13 13:01:12 +01:00
Beat Küng 5e3796324c px4io: fix argv index & avoid empty 'unknown argument: ' warning 2020-02-13 03:49:16 -08:00
Beat Küng ccf2078c66 nxp/fmurt1062-v1: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 6b1ee7bbe2 io_timer_init.h: avoid using timer_channel, as imxrt does not have it 2020-02-13 03:49:16 -08:00
Beat Küng ef36d70cb4 px4_arch imxrt: add hw description constexpr util methods 2020-02-13 03:49:16 -08:00
Beat Küng 8cd9afc19a imxrt io_timer: remove some fields from io_timers_t and split out channel indexes
IOMUX uses different enumeration from GPIO pin + port, so we cannot use
.gpio_out, and add a .gpio_portpin.
2020-02-13 03:49:16 -08:00
Beat Küng d74d094940 nuttx configs: disable nuttx timers which are used for PWM output
These are not required, and to be consistent we enforce disabling them now.
2020-02-13 03:49:16 -08:00
Beat Küng b380278f02 uvify/core: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 40898ba237 px4/fmu-v5x: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng a0bfb7ad8e px4/fmu-v4pro: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng d53153bb9b px4/fmu-v3: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 4599c30817 px4/fmu-v2: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng ba4be76bcc omnibus/f4sd: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 03210f5386 mro/x21: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng bd3fe62fcf mro/x21-777: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng b3fe4a6691 mro/ctrl-zero-f7: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 451af07472 modalai/fc-v1: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 93106836df intel/aerofc-v1: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng d2254c2e44 holybro/kakutef7: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng ebbcc01f12 av/x-v1: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 366e2b9dc9 airmind/mindpx-v2: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 6cdf368776 stm32 io_timer: add support for 16 PWM outputs 2020-02-13 03:49:16 -08:00
Beat Küng 2b0f7e514e io-v2: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng f7637ebf8f fmu-v5: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng d1e690a036 fmu-v4: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng c01f6811d0 nxp/fmuk66-v3: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 5319a98fec durandal-v1: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 4fd431b5e5 crazyflie: use hw description methods for timer configuration 2020-02-13 03:49:16 -08:00
Beat Küng 3217b539c6 px4_arch: add hw description constexpr util methods
These will be used in the board configurations.
2020-02-13 03:49:16 -08:00
Beat Küng 418262a131 px4_micro_hal: add PX4_MAKE_GPIO_INPUT and PX4_MAKE_GPIO_OUTPUT
Instead of using macros defined in the board config.
2020-02-13 03:49:16 -08:00
Beat Küng 685be9b3d1 io pins: avoid using GPIO_GPIOx_OUTPUT, use timer_io_channels instead
The whole system now uses timer_io_channels, which will allow the redundant
GPIO_GPIOx_OUTPUT definitions to be removed.
2020-02-13 03:49:16 -08:00
Beat Küng 62b4f3487a io timer: remove some fields from io_timers_t and split out channel indexes
- reduces amount of board configuration required
- removes the cyclic dependency between io_timers_t and timer_io_channels_t

Fixes a bug in the fmuk66-v3 config: the 2. timer has 3 channels associated
not 2.
Fixes a bug in the modelai config: the 2. timer has 4 channels associated.
2020-02-13 03:49:16 -08:00
Beat Küng 8020e82c1c MultirotorMixer: allow for longer mixer geometry names (16 instead of 8) 2020-02-13 03:49:16 -08:00
Beat Küng 73bd90ddd5 crazyflie: fix PWM channel ordering
Channels belonging to a certain timer were not all grouped together.
This is required by the .first_channel_index and .last_channel_index data
members.

We introduce a new mixer geometry to solve the problem.
2020-02-13 03:49:16 -08:00
bresch 17ab617877 ecl update: contains important fixes for accel bias instabilities 2020-02-12 22:34:17 +01:00
David Sidrane 2193cce50b rddrone-uavcan146:Board Added 2020-02-12 10:29:27 -05:00
David Sidrane 80ac80b5e4 s32k1xx:Add stubbed out chip and arch 2020-02-12 10:29:27 -05:00
Daniel Agar 0d36e5094b px4_io-v2 add to vscode variants and fix SVD file find 2020-02-10 09:40:39 +01:00
Daniel Agar 8cdbc4c593 px4iofirmware: add PX4IO_PERF define to completely disable perf counters 2020-02-10 09:40:39 +01:00
Daniel Agar 2015cc2b39 logger: restore buffer statistics update
- this was accidentally dropped during a rebase of #14050
2020-02-10 00:17:28 -05:00
Daniel Agar e6d7612997 cmake jlink add path hints for macos 2020-02-09 23:24:44 -05:00
Daniel Agar c54a09974c vscode improvements 2020-02-09 23:24:44 -05:00
stmoon 8b273b46aa fix the encoding problem for subprocess.check_output 2020-02-09 10:12:15 +00:00
Daniel Agar 6c76f99fe5 Update submodule mavlink v2.0 to latest Sat Feb 8 12:38:03 UTC 2020
- mavlink v2.0 in PX4/Firmware (8df22541ef): https://github.com/mavlink/c_library_v2/commit/a62c13922547033d8dd0e3ef9da9edcce909a05d
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/1847cbbff5863db71bf7e3de8c5e8136da784152
    - Changes: https://github.com/mavlink/c_library_v2/compare/a62c13922547033d8dd0e3ef9da9edcce909a05d...1847cbbff5863db71bf7e3de8c5e8136da784152
2020-02-08 18:28:34 -05:00
Daniel Agar 13a6d57703 Makefile/cmake remove legacy target naming transition helpers 2020-02-08 14:38:56 -05:00
PX4 BuildBot c6c7f963ac Update submodule nuttx to latest Sat Feb 8 12:38:09 UTC 2020
- nuttx in PX4/Firmware (4b356c91f2be41dfdadb38270fab01ddb337d3c7): https://github.com/PX4/NuttX/commit/7b36108b548642f1a8513dcf00eb4913f8558ccf
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/fdf1837077104e80912a2c46ff159fdacc8b06f9
    - Changes: https://github.com/PX4/NuttX/compare/7b36108b548642f1a8513dcf00eb4913f8558ccf...fdf1837077104e80912a2c46ff159fdacc8b06f9

    fdf1837077 2020-02-07 Peter van der Perk - [BACKPORT] S32K add support for Nxp drone boards (#224)
f479b26c98 2020-02-07 Peter van der Perk - [BACKPORT] imxrt added missing i2c prescale mask
26dd187034 2020-02-07 Peter van der Perk - [BACKPORT] Kinetis renamed TJA1100 to TJA110X registers
2020-02-08 13:59:26 -05:00
Daniel Agar f2eefb4e7a codecov: remove notifications until we can address false reporting
I don't think we're quite ready for codecov reporting on every PR. The initial report seems to work fine, but there are various issues that result in bogus reporting when additional commits are added or after a rebase.
2020-02-08 13:26:21 -05:00
David Sidrane 254b05d377 px4_fmu-v5x:P2 Base migrating to LAN8742Ai phy 2020-02-08 06:39:10 -08:00
Daniel Agar 8df22541ef sensors: filter sample rate calculate with simple interval average instead of perf count
- the perf counter intervals aren't numerically stable over extended periods (https://github.com/PX4/Firmware/pull/14046)
2020-02-07 13:04:02 -05:00
Silvan Fuhrer a3710fcdef VTOL: flight task auto: disable weather vane when not stationary
Use yawrate setpoint from weather vane only if velocity setpoint is small
(smaller than half the cruise velocity)

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-02-07 16:46:29 +01:00
Silvan Fuhrer 98aee29ddc VTOL: Manual Pos Flight Task: do not use yawrate sp from weather vane if position isn't locked
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-02-07 16:46:29 +01:00
Silvan Fuhrer 9ba0d5b706 tiltrotor tilt support: fix thrust compensation constraining
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-02-07 16:43:44 +01:00
Silvan Fuhrer 4c9dba8692 VTOL type and tiltrotor: use math::constrain() for constraining
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-02-07 16:43:44 +01:00
Silvan Fuhrer e3310796ce tiltrotor: limmit the adapted thrust for tilt to [0,1]
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-02-07 16:43:44 +01:00
Silvan Fuhrer a26e914ef4 VTOL pusher/tilt support: addressed review comments:
- remove gloabl variable and instead give back forward_thrust from function
 - give back increased vertical thrust from fct thrust_compensation_for_tilt()

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-02-07 16:43:44 +01:00
Silvan Fuhrer 5ae4ca8ff1 VTOL: Make pusher assist generic to enable also for tiltrotor
-move pusher assist functionality into vtol_type class and adapt it to also
work for tiltrotor VTOLs (pitch rotors down to accelerate forward)
-for tiltrotor: compensate for lost lift due to tilt by increasing the throttle
-enable pusher / tiltassist also in altitude mode

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-02-07 16:43:44 +01:00
bresch ca0b5700ab uorb_rtps_message_ids: add hover_thrust_estimate msg 2020-02-07 11:52:52 +01:00
bresch 7ca13a67b3 ZeroOrderHoverThrustEstimatorTest: add hover thrust jump test case
This is done to test the recovery function of the estimator in case
of divergence or sudden extreme hover thrust change.

Also specify seed of random generator
2020-02-07 11:52:52 +01:00
bresch e15e94b00a HoverThrustEstimator: Add convergence tests
With noisy accel and thrust in hover, climb and descent conditions.
2020-02-07 11:52:52 +01:00
bresch 0f1c7590e9 HoverThrustEstimator: add a new single state estimator
with measurement noise auto-tuning

The purpose of this estimator is to improve land detection and vertical
velocity feedforward

Recovery strategy:
This is required when the setpoint suddenly changes in air or that the
EKF is diverging. A lowpassed test ratio is used as a trigger for the recovery logic
Also, a lowpassed residual is used to estimate the steady-state value
and remove it when estimating the accel noise to avoid increasing the
accel noise when the redisual is caused by an offset.
2020-02-07 11:52:52 +01:00
CarlOlsson a61f1647ad replay: remove GPS relative timestamps
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2020-02-07 08:19:22 +01:00
Beat Küng b399698306 ist8310: remove calibration code
- it does nothing useful
- increases boot time by 2 seconds on pixhawk 4 due to a poll timeout:
IST8310 on I2C bus 3 at 0x0e (bus: 100 KHz, max: 400 KHz)
WARN  [ist8310] ERROR: TIMEOUT 2
2020-02-06 12:39:39 -05:00
Ricardo Marques 225a3a0cba Update sitl_gazebo submodule to latest 2020-02-06 09:38:35 +00:00
Daniel Agar 05b075984f Jenkins hardware clear hardfault log and board cleanup 2020-02-06 09:50:33 +01:00
Daniel Agar 1aa514a8ea Update submodule ecl to latest Wed Feb 5 12:39:46 UTC 2020
- ecl in PX4/Firmware (ad3865207f22e26534e04cde8825a07eda4399b5): https://github.com/PX4/ecl/commit/a3e1eb9d509d55c2c476ec093cf24d84da9798e5
    - ecl current upstream: https://github.com/PX4/ecl/commit/ed260c4f1db8545d8ad3aa7f05d951857436ef87
    - Changes: https://github.com/PX4/ecl/compare/a3e1eb9d509d55c2c476ec093cf24d84da9798e5...ed260c4f1db8545d8ad3aa7f05d951857436ef87

ed260c4 2020-02-03 Daniel Agar - validation: remove unused vibration metric
e52e2b8 2020-02-01 kritz - Sensor Replay (#717)
da752c9 2020-01-28 kamilritz - Hot flow fusion fix
ee859e0 2020-01-28 kritz - Robustify timestamp checks (#729)
f20726d 2020-01-23 kamilritz - Expand auto-format coverage and tiny style changes
fbdd75d 2020-01-27 kritz - Update CONTRIBUTING.md
5d38b73 2020-01-24 kamilritz - Update description of Firmware build tests
e3af91c 2020-01-24 bresch - Ekf: use helper functions to centralize the checks of horizontal aiding (gps, flow, ev_pos, ev_vel)
2020-02-05 14:24:38 -05:00
CarlOlsson 37db7d3bba ekf2: define max number of range finders seperate from max number of mutli uORB topics
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2020-02-05 08:03:23 +01:00
Daniel Duecker 36f836be79 add support for unmanned underwater vehicles (#14079)
* add support for unmanned underwater vehicles:
* airframe uuv_generic + uuv_hippocammpus including mav_type = 12 for submarines
* mixer for UUVs with X-shaped thruster setup similar to quadcopter
* add module  uuv_att_control for underwater robot attitude control
* add rc.uuv_defaults/apps for autostarting e.g. ekf2 and uuv_att_control app
2020-02-04 23:24:37 -05:00
Daniel Agar a82428c5fd codecov: try to relax notifications 2020-02-04 11:03:33 -05:00
Daniel Agar 36c6e36b9d sensors: refactor common corrections and rotation code 2020-02-04 09:44:40 -05:00
Hamish Willee ca96b6b0ea CBRK_AIRSPD_CHK: Doc driver not started 2020-02-04 09:22:18 +01:00
bresch c80593a144 FlightTaskManualAltitude: Rename _min_speed_down -> _max_speed_down as it is the maximum allowed downward speed 2020-02-03 18:05:17 +01:00
bresch c0d1aa1654 FlightTaskManualAltitude: Follow altitude limit given by the estimator 2020-02-03 18:05:17 +01:00
Daniel Agar 36b37189ba drivers/rpm/pcf8583: minor cleanup
- split out header and main
 - move to ModuleParams
 - add copyright header to all new files
 - don't store unnecessary state
2020-02-03 10:01:40 -05:00
Nico van Duijn 7778cbd463 Mavlink: Add MAV_x_RADIO_CTL parameter to disable RADIO_STATUS flow control
* Add param for software flow ctl on 3DR radios
* Dont reset telemetry type on radio timeout
* Treat 3DR radio as generic link type
* Rename 3DR to SiK radio
2020-02-03 09:49:47 -05:00
SalimTerryLi 9612e40464 purge drivers/linux_sbus
- rc_input now provides reliable parsing for SBUS on Linux platform. linux_sbus can be fully removed.
2020-02-03 08:40:27 -05:00
SalimTerryLi 20ad3a0ded fix batt_smbus build error
fix `error: variable-sized object ‘lifetime_block_one’ may not be initialized`
2020-02-03 08:22:43 +01:00
fnoop 86eff44a5e Honour PYTHON_EXECUTABLE environment variable if set and pass to cmake #14077 2020-02-03 07:40:11 +01:00
Daniel Agar 3dc23afb3e fw_pos_control_l1: move to px4::params 2020-02-02 21:04:21 -05:00
SalimTerryLi e0abe7090e SBUS on Linux: replace termios with termios2 and add UNKNOWN UART WQ 2020-02-02 14:06:27 -05:00
Roman Dvořák c8a58c5c9d drivers: add PCF8583 RPM sensor (#14018) 2020-02-02 12:10:20 -05:00
JaeyoungLim 6dc3cbbd95 SITL add catapult plane target for new gazebo model (plane_catapult) 2020-02-02 11:59:17 -05:00
Travis Bottalico 9d2a37b35d Fix hardware detection of Flight Core standalone configuration 2020-02-01 13:06:41 -05:00
Travis Bottalico 9e38fee1c6 [BACKPORT] hrt needs to be running for ADC time out.
From commit 5a1c46deeb
2020-02-01 13:06:41 -05:00
Nicolas Martin cfa74b9106 logger: choose logged instances by logger_topics file
new versions of logger does not allow to log multiple instances of a topic when using 'logger_topics.txt'

This commit restores the default behavior (log all instances of a topic) and ad the option to specify an instance to log
2020-01-31 09:43:29 +01:00
Julian Oes a8c3944485 setup: select Java 8 after installation 2020-01-30 22:45:29 -05:00
Julian Oes 733e73e185 Tools: check for Java 8 on Linux
This allows us to print an error message instead of a weird Java failure
further down the road.

Better yet would be if this would take down everything, so a user does
not have to scroll up to read the message.
2020-01-30 22:45:29 -05:00
Daniel Agar 035c3e6f6a commander params fix whitespace 2020-01-30 22:31:50 -05:00
Daniel Agar d089bacb1b codecov notification changes
- require the reporting of 5 builds to try and prevent Github actions + Jenkins race condition
 - don't report if there's no change
2020-01-30 21:50:59 -05:00
Hamish Willee 1acb947124 commander_params: subedit com_rc_override 2020-01-30 19:30:17 -05:00
David Sidrane 514e1a3744 px4_fmu-v4pro:Fix USART6 RX DMA Assignment 2020-01-30 16:20:49 -05:00
Daniel Agar e49112d406 invensense/icm20608-g: delete unnecessary perf counters 2020-01-30 13:07:44 -05:00
Daniel Agar aad27c4f94 invensense/icm20602: use watermarak interrupt instead of data ready and remove unnecessary perf counters 2020-01-30 13:07:44 -05:00
Daniel Agar ca4b8e4e76 invensense/mpu9250: delete redundant interval perf counter 2020-01-30 13:07:44 -05:00
Daniel Agar 6fe35d522a new icm20689 driver using FIFOs and raw sampling (8 kHz gyro, 4 kHz accel) 2020-01-30 13:07:44 -05:00
Daniel Agar 3910028fc5 new mpu6000 driver using FIFOs and raw sampling (8 kHz gyro, 1 kHz accel) 2020-01-30 13:07:44 -05:00
Hamish Willee 9886b11f99 EKF params - clarify body frame origin/orientation 2020-01-30 07:29:11 -05:00
Matthias Grob 69af6386b3 mc_pos_control_main: remove obsolete input setpoint assignments
These assignments were temporary for correct logging of the input
setpoint which now properly also comes out of the controller again.

This is reverting the hotfix from:
dee8d200d8
2020-01-30 07:28:18 -05:00
Matthias Grob b75c1308f9 PositionControl: replace interfacemapping checks
Removing the skip_controller and interfaceMapping
concept and replacing it with a single method checking
if the position control update was successful and
return the result in the PositionControl.update().
2020-01-30 07:28:18 -05:00
Matthias Grob e06fff94bb PositionControl: handle yaw NAN inputs 2020-01-30 07:28:18 -05:00
Matthias Grob dcc0339773 PositionControl: calculate velocity integral once using Vector3f 2020-01-30 07:28:18 -05:00
Matthias Grob 9109d22c28 PositionControl: simplify horizontal thrust limiting 2020-01-30 07:28:18 -05:00
Matthias Grob 83653d6581 PositionControl: readd direct thrust setpoint support
This restores original horizontal thrust setpoint execution
that I intentionally broke three commits ago. It's necessary
for correct stick to tilt mapping of FlightTaskManualAltitude.
2020-01-30 07:28:18 -05:00
Matthias Grob 282d46efcb PositionControl: add feed-forwards with addIfNotNan() 2020-01-30 07:28:18 -05:00
Matthias Grob 62fb06bd58 PositionControl: calculate velocity PID once using Vector3f 2020-01-30 07:28:18 -05:00
Matthias Grob 5bd8da2286 PositionControl: temporarily remove direct thrust setpoint support
This commit temporarily breaks direct horizontal thrust setpoint execution
which is used by FlightTaskManualAltitude. This is necessary to allow for
PositionControl cleanup namely calculating the whole velocity PID in one
Vector3f formula.

Having this in a separate commit is useful since it reduces indentation
of a bigger code block.
2020-01-30 07:28:18 -05:00
Matthias Grob e53ae45188 ControlMath: add addIfNotNan helper functions 2020-01-30 07:28:18 -05:00
Lorenz Meier eb50e89d87 Add flow tests to MAVSDK tests (#14039)
* workflows: remove unneeded pip dep and comments

* mavsdk_tests: simple test using flow/offboard

This adds a first proof of concept of a test using flow and offboard.

* Flow MAVSDK test: check against ground truth

* CleanUp

* workflows: use latest docker image with psutil

* mavsdk_tests: fix PEP8 issues

* Add VTOL CI tests back

* switch to non-rendering flow mockup

* workflows: install mavsdk from GitHub release .deb

* Add vision test and disable VTOL temporarlly

* Fist draft of combining test coverage and test in one workflow

* Add VTOL mavsdk tests back in CI

Co-authored-by: Julian Oes <julian@oes.ch>
Co-authored-by: kritz <kritz@ethz.ch>
2020-01-30 11:57:48 +01:00
PX4 BuildBot a141e4062b Update submodule sitl_gazebo to latest Thu Jan 30 00:37:59 UTC 2020
- sitl_gazebo in PX4/Firmware (931a3f2684): https://github.com/PX4/sitl_gazebo/commit/029722989e945f0a78d5a2322788b34a3ca99ab6
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/dfbc28badcffd734c6a5f1b084d7da44f0d19685
    - Changes: https://github.com/PX4/sitl_gazebo/compare/029722989e945f0a78d5a2322788b34a3ca99ab6...dfbc28badcffd734c6a5f1b084d7da44f0d19685

    dfbc28b 2020-01-29 kamilritz - Reduce airspeed noise
55d74c3 2020-01-11 JaeyoungLim - Add plane catapult model
2020-01-29 23:31:40 -05:00
Daniel Agar 116716ad22 new mpu9250 driver using FIFOs and raw sampling (8 kHz gyro, 4 kHz accel)
- currently disabled by default
2020-01-29 22:53:21 -05:00
Daniel Agar 931a3f2684 logger: publish initial logger_status orb message 2020-01-29 17:29:30 -05:00
Daniel Agar 2410b31662 sensors: move accel filtering to sensors/vehicle_acceleration
I've added a queue depth of 4 for sensor_accel and sensor_gyro. This is initially added because it's not always possible for the `vehicle_acceleration` to keep up with every publication of the primary accelerator as it runs in the same thread as ekf2, various controllers, etc. 

Later this mechanism will be used in a few areas
 - rate limit `vehicle_angular_velocity` and `vehicle_acceleration` without missing any raw data
 - move IMU integration to `vehicle_imu` and out of the actual driver threads, eliminating the need for sensor_accel_integrated and sensor_gyro_integrated
 - integrate raw gyro synchronized with optical flow measurements
2020-01-29 16:13:38 -05:00
David Sidrane 22c422d017 Update platforms/nuttx/NuttX/nuttx: imxrt backports merged 2020-01-29 13:54:20 -05:00
David Sidrane 2f1bc6676e imxrt:Add critmon 2020-01-29 13:54:20 -05:00
David Sidrane 78c7f98ef1 nxp_fmurt1062-v1:Memory Reorg 2020-01-29 13:54:20 -05:00
David Sidrane 962716a7c3 nxp_fmurt1062-v1:Performance tuning 2020-01-29 13:54:20 -05:00
David Sidrane a8720057fd nxp_fmurt1062-v1:RC is on LPUART6 ttyS5 2020-01-29 13:54:20 -05:00
David Sidrane eb30041958 nxp_fmurt1062-v1:PROBES:carry includes and path needed 2020-01-29 13:54:20 -05:00
David Sidrane 37995793f4 Updateded NuttX with backports of PX4 imxrt contrib 2020-01-29 13:54:20 -05:00
David Sidrane 304bef3554 iimxr:Needed more margin on minimum reload. 2020-01-29 13:54:20 -05:00
David Sidrane ef5ed2e43c nxp_fmurt1062-v1:OC remove Pull up - OC have series 47K 2020-01-29 13:54:20 -05:00
David Sidrane ec0f004a7b fmurt1062-v1:Correct SPI1_DRDY4_ICM20602 2020-01-29 13:54:20 -05:00
David Sidrane 1fd2f27493 fmurt1062-v1:Add SPI4 RESET and SYNC 2020-01-29 13:54:20 -05:00
David Sidrane 1346312012 fmurt1062-v1:Add GPIO info 2020-01-29 13:54:20 -05:00
David Sidrane 5202724f19 fmurt1062-v1:Add nARMED Support 2020-01-29 13:54:20 -05:00
David Sidrane 08ac209674 fmurt1062-v1:Set BAT ADC scaling 2020-01-29 13:54:20 -05:00
David Sidrane a223899e3e imxrt:ToneAlarmInterface Reset mode is dependant on Chan 1 2020-01-29 13:54:20 -05:00
David Sidrane 453c39230f fmurt1062-v1:Consistently use ONE/ZERO on inital OUTPUT settings 2020-01-29 13:54:20 -05:00
David Sidrane 1d2187528b fmurt1062-v1:Fix LPUART8 RX, TX pin definitions 2020-01-29 13:54:20 -05:00
David Sidrane a4e9498260 fmurt1062-v1:Fix LPUART3 CTS Pin definition 2020-01-29 13:54:20 -05:00
David Sidrane 2cbec89e2b fmurt1062-v1:Fix and enable support for debut Probes 2020-01-29 13:54:20 -05:00
David Sidrane 2385e1091d fmurt1062-v1:Correct ttyS usage 2020-01-29 13:54:20 -05:00
David Sidrane e5bf0710b5 fmurt1062-v1:Support imxrt_lpi2c_reset uses GPIO with SION 2020-01-29 13:54:20 -05:00
David Sidrane f44f8a95e1 fmurt1062-v1:Update board modules ==FMUv5 2020-01-29 13:54:20 -05:00
David Sidrane 625429d3b7 fmurt1062-v1:Support configurations to fine tune LPI2C Timeouts. 2020-01-29 13:54:20 -05:00
David Sidrane 59d17b053f fmurt1062-v1:Support clock setting for SPI and I2C from board.h 2020-01-29 13:54:20 -05:00
David Sidrane 94dbf3176a fmurt1062-v1:Update board modules ==FMUv5 2020-01-29 13:54:20 -05:00
David Sidrane 51f0bc9788 fmurt1062-v1:Remove EVK build options 2020-01-29 13:54:20 -05:00
David Sidrane a8e0c29161 fmurt1062-v1:Invert USDHC CD 2020-01-29 13:54:20 -05:00
David Sidrane be14fa084b fmurt1062-v1 Build for BB Rev A 2020-01-29 13:54:20 -05:00
David Sidrane b4b597251f fmurt1062-v1:Rev to match Rev A HW 2020-01-29 13:54:20 -05:00
David Sidrane 59693dc48e Adding NXP fmurt1062-v1
Add nxp_fmurt1062-v1 to CI
2020-01-29 13:54:20 -05:00
David Sidrane 490fe8256f Add nxp imxrt device support 2020-01-29 13:54:20 -05:00
kritz 92e75452f5 Flow mockup (#14054)
* Add optical flow mockup model

* Update Tools.sitl_gazebo
2020-01-29 14:06:46 +01:00
Julian Oes 00728dab18 workflows: build pull requests and master
With this change pull requests from forks are also built.
We yet need to verify if tags/releases are built or if we need to
specify the tags as well.
2020-01-28 22:09:50 -05:00
Julian Oes a2e95f171f mavsdk_tests: fix model name of plane
However, the test does not pass yet, so I'm leaving it commented out.
2020-01-28 20:35:25 +01:00
Julian Oes bb1c08fdd1 mavsdk_tests: enable VTOL, fix TEST_CASE name
We can't use commas in the TEST_CASE name. With the comma, the test did
not run and displayed:

Filters: Takeoff, transition and RTL
No test cases matched 'Takeoff'
No test cases matched 'transition and RTL'
==========================================
No tests ran
2020-01-28 20:35:25 +01:00
Julian Oes 01f29a51a8 mavsdk_tests: DISPLAY env for gazebo, --verbose 2020-01-28 20:35:25 +01:00
RomanBapst 3ef6eba34c prearmCheck: vtol cleanup
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-01-28 10:14:32 -05:00
Silvan Fuhrer 8de675ec88 mission feasibilty check: fix for VTOL backtransition and land waypoint
Prior this fix VTOL missions get rejected if they have a DO_LAND_START marker, but then do
not end with a LAND waypoint but a VTOL transition and land.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-01-28 10:13:41 -05:00
Lorenz Meier b14e5568d3 Codecov: Adjust target to current range
This is required to enable CI.
2020-01-28 08:59:25 +01:00
Lorenz Meier a88234e6db Disable Coveralls service
We are covered by Codecov.
2020-01-28 08:59:25 +01:00
Lorenz Meier f9e0f6f494 Coverage: Ignore examples and unused apps
These paths are unused code that is not part of the supported set.
2020-01-28 08:59:25 +01:00
Lorenz Meier 06db4b9227 MAVSDK tests: Enable coverage testing
This enables minimal coverage testing for multicopters.
2020-01-28 08:59:25 +01:00
Lorenz Meier dadcee1a5d Makefile: Improve the error message if a target is not found
The previous error message was misleading. The new more verbose error indicates that either the target does not exist or the ordering is wrong.
2020-01-28 08:59:25 +01:00
Lorenz Meier d468388643 Coverage: Run lcov separate to fix paths
Without this the paths of the different compile units do not match up.
2020-01-28 08:59:25 +01:00
Lorenz Meier 7e39ef8b8f MAVLink sim: Start faster
This reduces test times across the board.
2020-01-28 08:59:25 +01:00
Lorenz Meier 7b44f5d069 Tests: Add VTOL test
This is a first initial VTOL test.
2020-01-28 08:59:25 +01:00
Lorenz Meier 480e67fcd4 Plane tester: Complement test
Prepare wider plane test.
2020-01-28 08:59:25 +01:00
Lorenz Meier de8fadf1f5 Test runner: Terminate all px4 apps correctly
Without this change an aborted run leaves zombie processes running.
2020-01-28 08:59:25 +01:00
Lorenz Meier 7b5b1dcd47 Clang: Force absolute paths
This helps with some diagnostics tools as we have various compile units in different paths.
2020-01-28 08:59:25 +01:00
Lorenz Meier 60bc043698 Coverage: Fix build for Mac OS
These changes are needed for Mac OS.
2020-01-28 08:59:25 +01:00
Lorenz Meier 0d8ac51bcc Coverage tests: Run faster
We want the coverage tests to run at the maximum speedup factor the CI machine can deliver.
2020-01-28 08:59:25 +01:00
Daniel Agar dc5e10c3b1 airframes: delete 4004 H4 680mm
- this doesn't include any actual airframe configuration
2020-01-28 07:43:26 +01:00
Daniel Agar b95442b38f airframes: delete 4012 quad x can 2020-01-28 07:43:26 +01:00
Daniel Agar 4ac3ce9f54 airframes: delete 4002 quad x mount
- the mount can be enabled via parameter
2020-01-28 07:43:26 +01:00
Daniel Agar 0a0ed1eb33 px4_fmu-v2_fixedwing: disable vmount to save flash 2020-01-27 21:19:18 -05:00
Silvan Fuhrer 4fa64f686a pre arm check: add circuit breaker for the VTOL arming in fixed-wing mode prevention
Added a new circuit breaker that, if set, enables arming in fixed-wing mode for VTOLs.

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-01-28 00:30:24 +01:00
Silvan Fuhrer f4df3fb5f2 pre arm check: VTOL: do not allow arming if not in multicopter mode
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2020-01-28 00:30:24 +01:00
Daniel Agar 1237402fa4 sensors: compute and publish vehicle_angular_acceleration
- introduces parameter IMU_DGYRO_CUTOFF to configure the angular acceleration low pass filter
 - the angular acceleration is computed by differentiating angular velocity after the notch filter (IMU_GYRO_NF_FREQ & IMU_GYRO_NF_BW) is applied

Co-authored-by: Julien Lecoeur <jlecoeur@users.noreply.github.com>
2020-01-27 16:44:01 -05:00
Roman Dvořák 497ab07daf airframes: add ThunderFly Auto-G2 autogyro (#14015) 2020-01-27 16:21:52 +01:00
Daniel Agar 24f0c2d72a sensors: move gyro filtering to sensors/vehicle_angular_velocity
- gyro filtering (low-pass and notch) only performed on primary gyro in `sensors/vehicle_angular_velocity` instead of every gyro in `PX4Gyroscope`
 - sample rate is calculated from actual updates (the fixed value was slightly wrong in many cases, and very wrong in a few)
 - In the FIFO case the array is now averaged and published in `sensor_gyro` for filtering downstream. I'll update this in the future to use the full FIFO array (if available), but right now it should be fine.
2020-01-27 10:05:33 -05:00
kamilritz 0d2e5f1c50 Update sitl_gazebo: Vision fix 2020-01-27 14:09:45 +00:00
JaeyoungLim 15835ce7a3 Add standard_vtol as supported model for multivehicle sim gazebo
Fix
2020-01-27 09:16:24 +01:00
Daniel Agar 3545ba97ca commander: don't run preflightCheck during calibration on reconnect 2020-01-27 09:10:22 +01:00
Daniel Agar 10410fc868 msg: rename sensor_bias -> estimator_sensor_bias 2020-01-27 09:03:27 +01:00
Beat Küng db49e5abcd fix commander: run preflight checks on GCS connection
Regression from 6dec451bab, leading to
preflight failures not being reported at all. Only after a failed arming
attempt the messages would be sent. And for GPS check failures, in case
they are set to optional (default), arming would be possible, but switching
to position would be rejected w/o error.

We need to run the preflight checks periodically, but this at least restores
the previous behavior.
2020-01-25 11:17:33 +01:00
Beat Küng 2a67d22ac7 commander powerCheck: simplify logic
refactoring only
2020-01-25 11:17:33 +01:00
Beat Küng 9e7dcd4b06 commander: fix prearm flag to preflightCheck
This was inverted, i.e. set to false in most cases, whereas it should be
true.

As a consequence, both powerCheck and airspeed.confidence checks were not
executed.
2020-01-25 11:17:33 +01:00
Daniel Agar 4fef3dd7d5 simulated sensors minor cleanup
- mavlink receiver use PX4Accelerometer/PX4Gyroscope for hil_sensor and hil_state_quaternion
 - simulator module remove unnecessary fake scaling
 - sih module remove unnecessary fake scaling
2020-01-24 12:50:22 -05:00
RomanBapst 27e9b1e3d4 updated ecl 2020-01-24 16:49:17 +03:00
kamilritz 5a5b3a44ee Update flow interface 2020-01-24 16:49:17 +03:00
Julian Oes ab133b41b2 workflows: Install mavsdk from GitHub release 2020-01-24 12:04:47 +01:00
Beat Küng 0542ac0e5f fix simulator_mavlink: orb_copy requires a valid data pointer
orb_copy() just returns if data==nullptr.

Fixes lockstep for ekf2. estimator_status.time_slip now stays constant
after startup, even with high speedup factor and high system load.
2020-01-24 12:04:47 +01:00
Julian Oes 30edcad752 Revert "Simulator: Remove EKF2 based wait"
This reverts commit 1834c156d2.
2020-01-24 12:04:47 +01:00
Julian Oes 30188d2884 Revert "Simulation: Set scheduling policy RR for lockstep"
This reverts commit 742b1839d5.
2020-01-24 12:04:47 +01:00
Julian Oes f64a0982c7 mavsdk_tests: fix build instructions 2020-01-24 12:04:47 +01:00
Julian Oes 0f77e3ba44 mavsdk_tests: actually use chosen model
This does not work for plane yet, and VTOL only acts as multicopter for
now, so doesn't make much sense just yet.
2020-01-24 12:04:47 +01:00
Julian Oes 5589812104 mavsdk_tests: refactor/cleanup
This splits the main function which has become way too long.
2020-01-24 12:04:47 +01:00
mohammad f5a81f5793 capture.result
Boolean indicating success (1) or failure (0) while capturing this image.
2020-01-24 11:42:03 +01:00
Julian Oes 1280351feb mavlink: forward everything except what is for us
The previous forwarding rules exclude another onboard MAVLink node to
send messages to a specific target.

E.g. a message from a companion computer with sysid 1 (same as
autopilot) with target sysid 190 (for the ground station) was not
forwarded.

With the new rules, anything that is not specifically addressed to the
autopilot's sysid and compid is forwarded.
2020-01-24 11:14:44 +01:00
Jacob Dahl 562062b303 batt_smbus: fix potential buffer overrun bug (#13904) 2020-01-24 11:01:25 +01:00
Beat Küng 5cacf17e47 navigator mission: simplify reset logic
This can be simplified because we now only activate Mission while armed.
2020-01-24 08:42:16 +01:00
Beat Küng 92aa341c18 navigator: do not set a mode while disarmed
This avoids premature state machine execution, most notably for missions.

In particular this fixes these issues:
- when landed, and the vehicle has a valid mission: switching to mission
  would execute the first item.
- after executing a mission with a land waypoint, the mission is reset
  and the first item is executed.

In case the first waypoint is a takeoff, it would print a user message:
"Takeoff to x meters above home.". If it was a vehicle command, it would
execute that.
Note that because the vehicle is disarmed, the vehicle would not actually
do anything (except for commands that are accepted while disarmed).
2020-01-24 08:42:16 +01:00
Beat Küng e939f60a9e FlightTaskAuto: accept invalid triplet_setpoint (and interpret as loiter)
This will allow navigator to not output any setpoints while disarmed.
Otherwise the position controller outputs warnings in the form of:
Auto activation failed with error: Activation Failed

The risk here is that it could hide problems, where navigator sends invalid
triplets when it should not.
2020-01-24 08:42:16 +01:00
Beat Küng c0352027fb mc_pos_control: do not warn when going into failsafe while disarmed
It's possible to get invalid or no setpoints from navigator while disarmed.
2020-01-24 08:42:16 +01:00
Beat Küng d68e595514 vehicle_control_mode: fix invalid comment for flag_armed 2020-01-24 08:42:16 +01:00
kritz 47cab3dba5 Update external vision interface (#13989)
* Update external vision interface

* Update ECL Version
2020-01-23 15:36:08 +01:00
kamilritz 9554f8f98b Update ECL version 2020-01-23 13:27:30 +01:00
kamilritz 8d25dcd543 Update EKF auxiliary velocity interface 2020-01-23 13:27:30 +01:00
kamilritz 9d184ea3d6 Update EKF range finder interface 2020-01-23 13:27:30 +01:00
kamilritz 230d7f2558 Update EKF airspeed interface 2020-01-23 13:27:30 +01:00
kamilritz 8772e09963 Update EKF gps interface 2020-01-23 13:27:30 +01:00
kamilritz 19b7421f86 Update EKF baro interface 2020-01-23 13:27:30 +01:00
kamilritz 439a20bfcb Update EKF mag interface 2020-01-23 13:27:30 +01:00
Daniel Agar 009ba638f5 PX4Accelerometer/PX4Gyroscope update FIFO case to trapezoidal integration 2020-01-22 18:35:41 -05:00
Daniel Agar 697dbfb9f8 sensors/vehicle_imu: incremental step towards multi-EKF 2020-01-22 18:04:29 -05:00
RomanBapst 0e90448e52 navigator: add position setpoint reset helper with safe defaults
- use in reset_triplets()
2020-01-22 18:03:25 -05:00
Daniel Agar 98042bf58f uORB: introduce SubscriptionBlocking
- uORB::SubscriptionBlocking is a specialized uORB::Subscription that allows you to do a blocking read
 - this is intended to be an easy to use, hard to misuse replacement for the typical orb fd + poll pattern we've relied on historically
2020-01-22 17:56:28 -05:00
Daniel Agar 036a45377d boards rename auav_x21 -> mro_x21 2020-01-22 15:33:02 -05:00
SalimTerryLi 3ed8e876b7 New pca9685 pwm output driver 2020-01-22 15:19:47 -05:00
Daniel Agar 693d532bba mRo x2.1 777 board support 2020-01-22 15:02:55 -05:00
Claudio Micheli 421a06685c BMM150: Fix priority assignment
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2020-01-22 12:26:49 -05:00
Beat Küng db36edffe8 commander: fix mission topic publication
The local scope caused the topic to be unadvertised, which in turn caused
a copy() failure in navigator and 'mission update failed' printf error.
2020-01-22 12:08:32 -05:00
Beat Küng c61e44f55b commander: fix variable naming 2020-01-22 12:07:51 -05:00
Beat Küng 8bfbfa033c fix commander: avoid LED printf errors on every SITL startup 2020-01-22 12:07:51 -05:00
Beat Küng 67f3234b5b posix cdev_platform: set errno on px4_open failure 2020-01-22 12:07:51 -05:00
Daniel Agar 21a8d7db7f WorkItem modules: Run() shouldn't be public 2020-01-22 12:03:03 -05:00
Martina Rivizzigno 8162b1095b send obstacle distance data in onboard mode such that they are
received by the gcs when using mavlink router
2020-01-22 16:22:32 +01:00
Beat Küng d865d9e64e safety_button: fix missing return when module exits 2020-01-22 09:49:20 -05:00
Beat Küng 35fc51de92 safety_button: add support for pairing command (3x pressing the button) 2020-01-22 09:49:20 -05:00
Tal Zaitsev 65aaf5170c microRTPS: Fix C++11 remnant 2020-01-22 00:30:47 -05:00
Daniel Agar b47eaa6061 update C++ standard (c++11 -> c++14)
- temporarily disable snapdragon builds until toolchain is updated
2020-01-21 21:49:10 -05:00
Daniel Agar cf195b0755 commander: safety button disarm require land detector
- landed, maybe_landed, or ground_contact required before the safety
button is able to disarm
 - this reduces the risk of a faulty safety button triggering in regular
flight
2020-01-21 23:35:25 +01:00
Daniel Agar 4f868fc565 commander: use arm_disarm() helper for safety button disarm 2020-01-21 23:35:25 +01:00
Claudio Micheli 624fcc3adb v5x target: Fix wrong FD for TELEM3
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2020-01-21 23:27:59 +01:00
Daniel Agar 350268ee68 navigator: mission WORK_ITEM_TYPE_MOVE_TO_LAND altitude isn't relative 2020-01-21 23:27:22 +01:00
Daniel Agar fcbf8b6bcd platforms/nuttx: fix fmu-v4pro jlink debug device helper 2020-01-21 22:24:58 +01:00
Daniel Agar b2f4dae2c4 boards: fmu-v2/v3 limit rate loop by default 2020-01-21 19:16:27 +01:00
Roman Bapst fa83f3799a navigator: set acceptance radius even for IDLE position setpoint 2020-01-21 11:14:43 -05:00
kamilritz 04e09d772e Add missing mag calibration biases 2020-01-21 13:36:08 +03:00
kamilritz a3d2254e44 Move mag downsampling to ECL lib 2020-01-21 13:36:08 +03:00
kamilritz 4e8665082e Move baro downsampling and dynamic pressure comp to ECL lib 2020-01-21 13:36:08 +03:00
Daniel Agar 6704c90354 px4/fmu-v4: restore SPIDEV integers from stable v1.10 (and earlier) 2020-01-20 22:31:30 -05:00
Daniel Agar dc05ceaad2 create temperature_compensation module
- this is a new module for temperature compensation that consolidates the functionality previously handled in the sensors module (calculating runtime thermal corrections) and the events module (online thermal calibration)
 - by collecting this functionality into a single module we can optionally disable it on systems where it's not used and save some flash (if disabled at build time) or memory (disabled at run time)
2020-01-20 21:42:42 -05:00
PX4 BuildBot dedb4e8267 Update submodule sitl_gazebo to latest Tue Jan 21 00:39:16 UTC 2020
- sitl_gazebo in PX4/Firmware (635ceccfdb): https://github.com/PX4/sitl_gazebo/commit/a5b33417f72be371843e12c5ea77cd32733684f4
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/2f4b32723c68a3424d24fd99fa4ef305a7c5ad49
    - Changes: https://github.com/PX4/sitl_gazebo/compare/a5b33417f72be371843e12c5ea77cd32733684f4...2f4b32723c68a3424d24fd99fa4ef305a7c5ad49

    2f4b327 2019-10-21 Martina Rivizzigno - typhoon sonar fix rotation such that the reported orientation metches the gazebo model
7db52d7 2019-10-18 Martina Rivizzigno - typhoon_h480: rotate sonar such that is forward facing
2020-01-20 21:01:45 -05:00
Daniel Agar e863dd317e Update submodule ecl to latest Tue Jan 21 00:39:21 UTC 2020
-  ecl in PX4/Firmware (ac205456f93857f447595eb0005c954a78461778): https://github.com/PX4/ecl/commit/011b4c2e4e9c39723250ed6805daa5b0aac3a1d4
    - ecl current upstream: https://github.com/PX4/ecl/commit/950e75e484519a6f719cbfd9d2ca2a29bfd06bfa
    - Changes: https://github.com/PX4/ecl/compare/011b4c2e4e9c39723250ed6805daa5b0aac3a1d4...950e75e484519a6f719cbfd9d2ca2a29bfd06bfa

950e75e 2020-01-18 Matthias Grob - EKF_ringbuffer: minor missing space for style
26125c2 2020-01-17 kamilritz - Switch from jenkins to github actions
2020-01-20 21:01:02 -05:00
Daniel Agar 635ceccfdb land_detector: relax data timeouts uniformly
* if we're hitting these timeouts there are much larger problems in the system
2020-01-20 17:14:00 -05:00
Daniel Agar d1260aa28c logger: add safety (switch) at minimal rate 2020-01-20 14:30:24 -05:00
stmoon 44cac04abe fix the bug for none of recv_topics 2020-01-20 12:33:47 +00:00
Daniel Agar c270e75156 vehicle_local_position: delete unused and redundant dist_bottom_rate 2020-01-18 12:50:57 -05:00
Julian Oes 98f0ba33d2 setup: prevent prompt during install
This should prevent debconf from asking questions during install.
Presumably, the exported env variable DEBIAN_FRONTEND is not taken into
account in a sudo command, hence we need to add it every time.
2020-01-18 11:10:55 +01:00
Julian Oes 09c3fc3e71 setup: add pyros-genmsg, sort list 2020-01-18 11:10:55 +01:00
Julian Oes ca7327056c setup: prevent debconf asking about tzdata 2020-01-18 11:10:55 +01:00
Julian Oes 83ccc4e61e setup: fix script fail if check fails 2020-01-18 11:10:55 +01:00
Julian Oes 7a0ba7f0ca setup: remove duplicate 2020-01-18 11:10:55 +01:00
Julian Oes 26d4169b7c setup: remove unused dependencies 2020-01-18 11:10:55 +01:00
Julian Oes 8353d609cb setup: don't forget to install wheel 2020-01-18 11:10:55 +01:00
Julian Oes d764cfcb6d setup: remove unusual Python dependencies
As far as I know these dependencies are only ever required when doing
analysis in ECL. At that point developers should be confident to add
what is required.
2020-01-18 11:10:55 +01:00
Julian Oes fcbf2e8f9e setup: remove Python 2 requirements for Ubuntu 2020-01-18 11:10:55 +01:00
Julian Oes ac6d7e6730 setup: another try to install pip dependencies 2020-01-18 11:10:55 +01:00
Julian Oes 8112a5c417 setup: fix call to pip/pip3
This should prevent the error:
Traceback (most recent call last):
  File "/usr/bin/pip3", line 9, in <module>
      from pip import main
      ImportError: cannot import name 'main'

As described in:
https://github.com/pypa/pip/issues/5447#issuecomment-407693701
2020-01-18 11:10:55 +01:00
Julian Oes bac4854424 setup: stop on error 2020-01-18 11:10:55 +01:00
Julian Oes 126b7a5642 setup: we need a newer pip 2020-01-18 11:10:55 +01:00
Julian Oes bf62b0f5e6 setup: use pip as user, don't forget python3-dev
In my opinion we should not mess with someones system Python
dependencies.
2020-01-18 11:10:55 +01:00
Matthias Grob 1e06f6bbd2 mc_pos_control: fix derivative spike when regaining velocity estimate
When having no velocity estimate the derivative was updated with zero.
When losing the velocity estimate this is fine since the resulting
derivative spike doesn't get used and acceleration is set to NAN.
But when regaining the velocity estimate the spike from zero to
the first estimated velocity gets used as acceleration in the position
controller and results in a twitch.

To solve this I use the derivative reset I introduced in pr #13522
commit b64abf48b2
2020-01-18 10:57:12 +01:00
Matthias Grob a6cc972b5c mc_pos_control: do not use invalid vz estimate 2020-01-18 10:57:12 +01:00
Matthias Grob 4d83170746 mc_pos_control: do not ignore EKF vz with terrain following
This caused bad altitude control performance when enabling
terrain following. It even leads to complete vertical control
instability in case dist_bottom is inaccurate.

Relying on the estimator states is the way to go instead of
silently using one altitude source as state.
2020-01-18 10:57:12 +01:00
Daniel Agar bb465ca5b7 sensor accel/gyro message cleanup
- split out integrated data into new standalone messages (sensor_accel_integrated and sensor_gyro_integrated)
 - publish sensor_gyro at full rate and remove sensor_gyro_control
 - limit sensor status publications to 10 Hz
 - remove unused accel/gyro raw ADC fields
 - add device IDs to sensor_bias and sensor_correction
    - vehicle_angular_velocity/vehicle_acceleration: check device ids before using bias and corrections
2020-01-18 01:15:00 -05:00
Daniel Agar 1d932f6ec9 IMU drivers using FIFOs increase max length to 16 and sync similar implementations
- this provides some extra space when the FIFO transfers don't align perfectly
 - I've also made an effort to keep the different drivers (icm20602, icm20608g, ism330ldc) in sync so we can factor out the common portions later once we've confident in the pattern.
2020-01-17 22:06:09 -05:00
Low Orbit Ion Cannon 7dd949edb1 ADSB traffic avoidance improvements using UTM_GLOBAL_POSITION (#13159)
* Treat UAVS diffrently from manned aviation 
 * Added fake_traffic testing functionality,
 * Added NAV_TRAFF_AVOID Hold and Landmode
 * Added Behavior: HOLD Position to collision avoidance mode and implemented Landmode to collision avoidance.

Boards where no Hardware GUID is defined will send 0 as GUID.

Right now collision avoidance for more than one FMU without Hardware GUID is not possible.
We should consider adding a randomly generated HW GUID as a placeholder for legacy Boards
2020-01-17 14:58:28 -05:00
Nicolas de Palezieux 8d0402f274 land detector: fix ordering of hysteresis updates to ensure we report LANDED only if also MAYBE LANDED and GROUND CONTACT, and MAYBE LANDED only if also GROUND CONTACT 2020-01-17 20:46:17 +01:00
RomanBapst 3e90cbe686 mission: explicitly set backtransition mission item altitude
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-01-17 12:59:36 -05:00
TSC21 1cbb3ebd4f microRTPS bridge: clean build warnings; improve verbosity 2020-01-17 12:19:00 +00:00
Julian Oes 3387c9599c mavsdk_tests: don't constrain speed factor to int
Speed factors slower than 1 should also be possible.
2020-01-17 10:32:21 +01:00
Julian Oes 735749e341 Revert "SITL shell: Do math using the shell"
This reverts commit be35c4857b.

This would only work for integer math, so for simulation speed-up. For
speeds slower than realtime we need floating point.
2020-01-17 10:32:21 +01:00
Daniel Agar e1ae1c3d9f Update submodule mavlink v2.0 to latest Fri Jan 17 00:39:17 UTC 2020
- mavlink v2.0 in PX4/Firmware (9647bc3783): https://github.com/mavlink/c_library_v2/commit/dbcc725631ce695e0f00a6f6ae1eae2c46cc214c
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/a62c13922547033d8dd0e3ef9da9edcce909a05d
    - Changes: https://github.com/mavlink/c_library_v2/compare/dbcc725631ce695e0f00a6f6ae1eae2c46cc214c...a62c13922547033d8dd0e3ef9da9edcce909a05d
2020-01-16 21:19:56 -05:00
PX4 BuildBot 6beecafbad Update submodule matrix to latest Fri Jan 17 00:39:22 UTC 2020
- matrix in PX4/Firmware (b9c304e461b8fe9a8060110a902fce7eac0eea8d): https://github.com/PX4/Matrix/commit/3b581fb5998c7a15b741947e6a139b9e3f99fe38
    - matrix current upstream: https://github.com/PX4/Matrix/commit/a37b91c96a9726cd8336af2d3463e717007e60a5
    - Changes: https://github.com/PX4/Matrix/compare/3b581fb5998c7a15b741947e6a139b9e3f99fe38...a37b91c96a9726cd8336af2d3463e717007e60a5

    a37b91c 2020-01-13 kamilritz - Type cast remaining integer
2020-01-16 20:34:06 -05:00
Julian Oes 9647bc3783 travis: change coverity to run on master
This change goes with disabling:
- Build pushed branches
- Build pushed pull requests

And adding a cron job on travis-ci to build master weekly.
2020-01-16 13:31:41 -05:00
Daniel Agar 6630087654 TECS: remove height rate complementary filter 2020-01-16 11:04:28 -05:00
Timothy Scott e9890d01d9 Fixed digital power module validity check 2020-01-16 10:43:23 -05:00
Julian Oes 75c8fb12e4 cmake: add custom error messsage about Python 3
This should be helpful as developers need to migrate to Python 3.
2020-01-16 16:25:26 +01:00
Julian Oes c77816aef2 cmake: move jinja2 check to Python modules
This removes the cmake check for jinja2 and moves it to the respective
Python scripts.
2020-01-16 16:25:26 +01:00
Julian Oes b04f68553e Tools: use Python 3, improve import checks
In more detail:
- Change shebang to Python 3.
- Suggest installation using pip3 as user.
2020-01-16 16:25:26 +01:00
Julian Oes e98fa891fe msg/tools: remove unused import, check for six 2020-01-16 16:25:26 +01:00
Julian Oes 0a2b42b25d msg/tools: improve Python dependency note
We now check individually for empy and genmsg.

Also, my recommendation is to use pip3 as a user to install the
dependencies as this is least intrusive and should work on all
platforms.
2020-01-16 16:25:26 +01:00
Daniel Agar 13fc6fa04c Update submodule sitl_gazebo to latest Thu Jan 16 00:39:21 UTC 2020 (#13784)
- sitl_gazebo in PX4/Firmware (d6cff809f3): https://github.com/PX4/sitl_gazebo/commit/5b031e10199810c7a930032beface82f1aa9e0cc
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/a5b33417f72be371843e12c5ea77cd32733684f4
    - Changes: https://github.com/PX4/sitl_gazebo/compare/5b031e10199810c7a930032beface82f1aa9e0cc...a5b33417f72be371843e12c5ea77cd32733684f4

    a5b3341 2019-12-22 Lorenz Meier - MAVLink interface: Fix init
484bc8d 2020-01-15 Lorenz Meier - Only support Mac OS Mojave
62fdd48 2020-01-14 Julian Oes - travis: use pip3 as user
bb9b3f7 2020-01-14 Julian Oes - travis: unlink Python2, install Python3
5d27757 2020-01-13 Lorenz Meier - Fix Mac OS CI
193a4d2 2020-01-13 Gus Grubba - Update gazebo_video_stream_widget.h
7cb9e2e 2020-01-07 Morten Fyhn Amundsen - gazebo_lidar_plugin: Rename class to LidarPlugin
6f5d19b 2020-01-06 bozkurthan - Update typhoon_h480.sdf
32fa459 2020-01-06 bozkurthan - Update gazebo_gst_camera_plugin.h
0058204 2020-01-06 bozkurthan - Change udpDstIP -> udpHost
b443319 2020-01-06 bozkurthan - Update typhoon_h480.sdf
0d98f07 2020-01-06 bozkurthan - Update gazebo_gst_camera_plugin.cpp
1a94d78 2020-01-06 bozkurthan - Update gazebo_gst_camera_plugin.h
57c829c 2020-01-06 bozkurthan - Update typhoon for custom IP

Co-authored-by: PX4 Build Bot <bot@px4.io>
2020-01-16 09:08:28 +01:00
TSC21 d6cff809f3 uorb_rtps_message_ids.yaml: onboard_computer_status to be received 2020-01-15 19:40:09 +00:00
TSC21 8505dddba3 Jenkins: move "Cppcheck" stage to ROS Melodic container, as cppcheck-hmtlreport requires Python (2) pygments 2020-01-15 10:16:59 +00:00
Hamish Willee 84f3cb74aa px4_simple_app: UPdate copyright to last modification 2020-01-15 08:14:43 +01:00
Julian Oes 5aa696839d jMAVSim: link to devguide instead of issue
This should be less confusing and point to a source of truth rather than
a long discussion.
2020-01-14 22:56:20 +01:00
Julian Oes d4d90e0488 jMAVSim: accept AdoptOpenJDK Java version
This should work with AdoptOpenJDK installed via brew:
    brew tap adoptopenjdk/openjdk
    brew cask install adoptopenjdk8
2020-01-14 22:56:20 +01:00
Claudio Micheli 288725684c Commander: remove variable duplication for geofence and rc override
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2020-01-14 22:54:16 +01:00
TSC21 4f362f5835 Jenkins: reactivate ROS2-related deployment 2020-01-13 21:48:35 +00:00
TSC21 88a32cb680 mission_test: fix px4tools func import 2020-01-13 21:48:35 +00:00
TSC21 13c0c618f3 px4modulesdoc: move to Python3 2020-01-13 21:48:35 +00:00
TSC21 502be605fd update submodule sitl_gazebo 2020-01-13 21:48:35 +00:00
TSC21 e15a512f6f Jenkins: export PYTHONPATH before Catkin build 2020-01-13 21:48:35 +00:00
TSC21 dd11a1c5ba don't specifically export PYTHONPATH 2020-01-13 21:48:35 +00:00
TSC21 ed974d83f5 run mission_test over python2 2020-01-13 21:48:35 +00:00
TSC21 abda56b7a2 Jenkins: update snapdragon container tag 2020-01-13 21:48:35 +00:00
TSC21 e789010295 rostests: add PYTHONPATH export path so to find Python 2 packages 2020-01-13 21:48:35 +00:00
Julian Oes 3818b18314 beaglebone: treat robotcontrol as system include
This should ignore compiler warnings from the includes.
2020-01-13 21:48:35 +00:00
Julian Oes 065fa1244d Update Snapdragon docker tag 2020-01-13 21:48:35 +00:00
Julian Oes e64c38fa25 CI: update all docker tags 2020-01-13 21:48:35 +00:00
TSC21 c9fc6f8dd1 if building with catkin, don't specifically look for Python 3 2020-01-13 21:48:35 +00:00
Julian Oes 19bd7b29d6 Tools: use Python3 for upload_log.py 2020-01-13 21:48:35 +00:00
Julian Oes 8897c69c8f Tools: use Python 3 in validate_yaml.py 2020-01-13 21:48:35 +00:00
Julian Oes f9ab38f1bc mission_test: let's try to run this with Python 3 2020-01-13 21:48:35 +00:00
Julian Oes 157811acc7 circleci: update to latest docker tag 2020-01-13 21:48:35 +00:00
Julian Oes 18f85ea520 Jenkins: bump docker tags 2020-01-13 21:48:35 +00:00
Julian Oes 02ecc04583 workflows: update docker tag
This should enable the docker images with Python 3 as default.
2020-01-13 21:48:35 +00:00
TSC21 8e30c4a291 fix rebase issue 2020-01-13 21:48:35 +00:00
Julian Oes c5fb0e77cd Tools: update sitl_gazebo submodule 2020-01-13 21:48:35 +00:00
Julian Oes a2e74836bd Jenkins: update all docker tags 2020-01-13 21:48:35 +00:00
Julian Oes 1842708ef2 Jenkins: updated all docker tags 2020-01-13 21:48:35 +00:00
Matthias Grob 322e773250 appveyor: switch to toolchain version 0.8
which has the python package pyros-genmsg
installed.
2020-01-13 21:48:35 +00:00
TSC21 d447f15ac6 bump Docker container tags to 2019-11-25 2020-01-13 21:48:35 +00:00
TSC21 0cb1b250e9 px_generate_uorb_topic_files.py: update import error recommendation message 2020-01-13 21:48:35 +00:00
TSC21 2be7ca08ba msg: generation and parsing scripts: add Python3 support 2020-01-13 21:48:35 +00:00
Julian Oes 4329de9e3b Use Python 3 everywhere
Since Python 2 is retired in 4 months, we should move everything to 3.
2020-01-13 21:48:35 +00:00
TSC21 3ea62ff53b bump Docker container tags to 2019-11-22 2020-01-13 21:48:35 +00:00
TSC21 2e9a4d89ee msg: remove gencpp and genmsh submodules; remove gencpp imports 2020-01-13 21:48:35 +00:00
Matthias Grob 98a3910b06 mavlink battery_status: report actual cell voltages 2020-01-13 21:29:40 +01:00
Daniel Agar de4f594937 DriverFramework purge
The bulk of this change was tightly coupled and needed to be deleted in one pass. Some of the smaller changes were things that broke as a result of the initial purge and subsequently fixed by further eradicating unnecessary platform differences. Finally, I deleted any dead code I came across in the related files I touched while going through everything.

 - DriverFramework (src/lib/DriverFramework submodule) completely removed
 - added dspal submodule in qurt platform (was brought in via DriverFramework)
 - all df wrapper drivers removed
 - all boards using df wrapper drivers updated to use in tree equivalents
 - unused empty arch/board.h on posix and qurt removed
 - unused IOCTLs removed (pub block, priv, etc)
 - Integrator delete methods only used from df wrapper drivers
 - commander: sensor calibration use "NuttX version" everywhere for now
 - sensors: update to px4_{open, read, close} instead of DevMgr wrapper (adc open for analog differential pressure)
 - battery_status: update to px4_{open, read, close} instead of DevMgr wrapper (adc open for analog differential pressure)
 - cdev cleanup conflicting typedefs and names with actual OS (pollevent_t, etc)
 - load_mon and top remove from linux boards (unused)
 - delete unused PX4_MAIN_FUNCTION
 - delete unused getreg32 macro
 - delete unused SIOCDEVPRIVATE define
 - named each platform tasks consistently
 - posix list_devices and list_topics removed (list_files now shows all virtual files)
2020-01-13 14:07:03 -05:00
joevn 04ba05f5a0 PAW3902: fix mode change shutter thresholds
According to PixArt datasheet
2020-01-13 14:05:26 -05:00
romain-chiap ba28ef5809 jmavsim_run.sh: add -o flag for SIH display only 2020-01-13 16:09:40 +01:00
tzai fb0bf26787 logger: refactor start_stop_logging
Cleans up function by reducing duplicate code and local variable count

Signed-off-by: Tal Zaitsev <tal@corvus-robotics.com>
2020-01-13 13:19:47 +05:30
Daniel Agar 718ca1dc50 emlid/navio2: navio_rgbled run in lp_default instead of hp_default 2020-01-12 22:25:27 -05:00
Daniel Agar 756b0148d6 platforms: split posix hrt for qurt
- this keeps the per platform libraries contained to their respective directories and minimizes the ifdef mess
2020-01-12 22:09:34 -05:00
Daniel Agar 98c5c31aa1 Update submodule nuttx to latest Mon Jan 13 00:39:44 UTC 2020
- nuttx in PX4/Firmware (3459f0a99de671e03a894e5bb44f615c9184d702): https://github.com/PX4/NuttX/commit/4c2da2935399ca17eae0c9ad4e8822cb8efc2b0d
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/c6ba2c13c799dcb18b53aaf63978925473cab7ce
    - Changes: https://github.com/PX4/NuttX/compare/4c2da2935399ca17eae0c9ad4e8822cb8efc2b0d...c6ba2c13c799dcb18b53aaf63978925473cab7ce

c6ba2c13c7 2019-12-24 David Sidrane - [BACKPORT] STM32F7 and STM32H7 SDMMC internal pull up usage fixed
a14d2cec3b 2019-12-22 David Sidrane - [REJECTED] Add check_format tooling
30e1808bc3 2019-12-22 David Sidrane - [REJECTED] nxstyle - output compiler like error format
2020-01-12 21:20:41 -05:00
Daniel Agar 97bd668e52 navio_sysfs_rc_in: only publish input_rc if connected and all channels are non-zero 2020-01-12 21:19:53 -05:00
Daniel Agar 65c0882f97 lsm9ds1_mag: fix orientation (#13925)
- X is aligned with -X of lsm9ds1 accel/gyro
 - Z is up (RHC), flip z for publication
2020-01-12 20:35:21 -05:00
hzsu f758a9f29d Update gps.cpp
'BeiDou' is a navigation satellite system from China, while 'Baidu' is a search engine.
So it is supposed to change it from 'Baidu' to 'BeiDou'.
2020-01-11 22:27:17 +05:30
tzai b9d85c7176 logger: Refactor new boot_bat logic into separate function
Implements suggested fixes.

Signed-off-by: Tal Zaitsev <tal@corvus-robotics.com>
2020-01-11 22:27:00 +05:30
tzai 1c2f95697c logger: Add support for logging only on bat power
Will not start logging from boot if battery is not connected

Signed-off-by: Tal Zaitsev <tal@corvus-robotics.com>
2020-01-11 22:27:00 +05:30
Daniel Agar d1e3ff553b platforms: remove unnecessary i2c platform abstraction 2020-01-11 11:55:06 -05:00
qlliu 54e4b65daa free allocated variable by perf_alloc 2020-01-11 11:12:18 +01:00
Daniel Agar bd111c9f42 px4_work_queue: revert inherited sched attr and run wq:manager and max priority
Setting PTHREAD_EXPLICIT_SCHED was necessary on linux to create WQ threads with priorities relative to max, but unfortunately we can't rely pthread_attr_setinheritsched as it's dependent on system ulimit configuration or running privileged. Instead we can create the wq:manager at the maximum desired priority and allow each WQ thread to have a relative priority.
2020-01-10 17:57:51 -05:00
Julian Oes 3527870333 Tools: fix 'Assistive technology not found error'
On Ubuntu we often saw the error
Assistive technology not found AWTError when starting jMAVSim.

This should be fixed by appending this cli argument to java.

As suggested in https://github.com/PX4/containers/issues/206
2020-01-10 17:30:28 -05:00
Daniel Agar ceec0238c4 replace mag_report with sensor_mag_s 2020-01-10 12:15:18 -05:00
stmoon e19e0bd616 serach and insert rtps path if there is no {FASTRTPSGEN_DIR} 2020-01-10 16:48:21 +00:00
Daniel Agar a08b54b8e1 px4_work_queue: don't inherit pthread attributes from creating thread
- this is necessary on linux so that the WQ threads priorities are set relative to max, and not relative to the wq:manager thread
2020-01-10 11:02:49 -05:00
RomanBapst 4d4481a384 gazebo_sitl_multiple_run.sh: fixed comment
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2020-01-10 16:51:33 +01:00
JaeyoungLim 528141a78e Make more space between vehicles 2020-01-10 16:51:33 +01:00
JaeyoungLim 0324889cf7 Add support for plane 2020-01-10 16:51:33 +01:00
JaeyoungLim eb7cdb4c4e Use sdf files instead of urdf files
Fix
2020-01-10 16:51:33 +01:00
TSC21 f0651663bb reverse adding 'master' build for deploy 2020-01-10 14:05:24 +00:00
TSC21 f1cb3f2eac Jenkins: re-enable microRTPS bridge templates and scripts deployment 2020-01-10 13:38:12 +00:00
TSC21 722f287281 msg: urtps: change the topic Data Type name to match expected on ROS2 2020-01-10 13:42:36 +01:00
Daniel Agar 23e17aec42 atlflight/eagle: minor fixes to get it running again
- fixed df_ltc2946_wrapper battery dependency
 - fixed px4::atomic fetch_add for QuRT
 - updated PX4 QuRT SPI wrapper to set bus frequency
 - renamed "qurt-default" configs to just "qurt"
2020-01-09 18:09:06 -05:00
Daniel Agar e3de7e62ea drivers/rc_input: port to linux for testing 2020-01-09 16:16:23 -05:00
Matthias Grob 6184f4691a commander_params: remove duplicate rc override title
I merged the duplicate title because the pr was from
a private fork branch and already delayed.
2020-01-09 18:39:04 +01:00
Tal Zaitsev d54ab5f6eb Change RC override to affect offboard mode as well
-Defines COM_RC_OVERRIDE as a bitmask
-Changes RC override to affect auto modes, offboard mode, or both
2020-01-09 18:26:39 +01:00
tzai fee7f69d63 commander: fix regression issue preventing RC override from working
Boolean variable name was refactored to represent the opposite state
without a change in logic.
2020-01-09 18:26:39 +01:00
Daniel Agar 4ac5b00a06 navio_sysfs_rc_in: move to PX4 WQ and cleanup 2020-01-09 12:08:14 -05:00
Daniel Agar 793d1d7889 github actions: temporarily disable SITL Tests (Code Coverage) 2020-01-09 10:57:15 -05:00
Daniel Agar 2bbf73097b aerfofc_adc: move to PX4 WQ and cleanup 2020-01-09 10:44:42 -05:00
Daniel Agar d32a80df3a simulator: replace gpssim with simple orb publication
- this is one of the last pieces of the system that still depend on DriverFramework
 - add new SIM_GPS_NOISE_X parameter for optionally increasing the GPS noise multiplier (was previously a gpssim command line option)
 - add SIM_x_BLOCK parameters to block sensor publication
   - SIM_GPS_BLOCK
   - SIM_ACCEL_BLOCK
   - SIM_GYRO_BLOCK
   - SIM_MAG_BLOCK
   - SIM_BARO_BLOCK
   - SIM_DPRES_BLOCK
2020-01-09 10:30:20 -05:00
SalimTerryLi faec9fe579 boards px4/raspberrypi: fix upload AUTOPILOT_HOST 2020-01-09 09:51:47 -05:00
kamilritz 32a4e3a942 Update ekf vision parameter description 2020-01-09 10:36:10 +01:00
kamilritz e95e5abdf6 Update ECL 2020-01-09 10:36:10 +01:00
kamilritz 593895293a Transform vision covariances 2020-01-09 10:36:10 +01:00
kamilritz 1560309687 Checking all used vision data for being finite 2020-01-09 10:36:10 +01:00
kamilritz 90aa4bb852 Support 3d auxvel fusion 2020-01-09 10:36:10 +01:00
kamilritz a67229e60e Use full variance of vision data 2020-01-09 10:36:10 +01:00
Daniel Agar 5f1121c216 rc_input: move to PX4 WQ 2020-01-08 13:00:59 -05:00
Daniel Agar ef9a930816 ulanding_radar: move to PX4Rangefinder and cleanup 2020-01-08 12:42:56 -05:00
Daniel Agar eef508cc4a teraranger: move to PX4Rangefinder and cleanup 2020-01-08 12:36:42 -05:00
David Jablonski 3d60ef9383 FW: Allow counterclockwise loiter
Before, this check was always true, thus always falling back to
NAV_LOITER_RAD, which can't be negative.
2020-01-08 12:30:50 -05:00
Daniel Agar 253296eec7 vehicle_status_flags: remove unused circuit_breaker_engaged_gpsfailure_check 2020-01-08 12:29:50 -05:00
David Sidrane 7cf1bb7f7f px4_fmu-v5:Support Nuttx SDIO Fixes 2020-01-08 12:23:01 -05:00
David Sidrane 351c3f7c22 px4_fmu-v5x:Support Nuttx SDIO Fixes 2020-01-08 12:23:01 -05:00
David Sidrane 4e04781d1f mro_ctrl-zero-f7:Support Nuttx SDIO Fixes 2020-01-08 12:23:01 -05:00
David Sidrane 8d7bfa805b modalai_fc-v1:Support Nuttx SDIO Fixes 2020-01-08 12:23:01 -05:00
David Sidrane 4f1790864d av_x-v1:Support Nuttx SDIO Fixes 2020-01-08 12:23:01 -05:00
David Sidrane 9c1543c33f Nuttx with PX4 Contrib for SDIO PU fix 2020-01-08 12:23:01 -05:00
CarlOlsson 13a9b552c5 Remove unused GPS fail circuit breaker
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2020-01-08 10:50:26 -05:00
kamilritz 92adc5afaa Update ECL to newest version 2020-01-08 09:42:14 +01:00
Daniel Agar 298d6d8703 ST LSM9DS1 9DOF IMU driver
- this is a replacement for df_lsm9ds1_wrapper on the Emlid Navio2 once DriverFramework is removed
2020-01-07 21:58:31 -05:00
Daniel Agar f3cd5b19c8 emlid navio2: update RGB LED driver (move away from DriverFramework)
- delete unused linux gpio wrapper
2020-01-07 17:47:15 -05:00
Daniel Agar ace1acca3c Jenkins hardware print power topics 2020-01-07 16:10:46 -05:00
Daniel Agar b7a63bfdf3 drivers/adc: move to ModuleBase and split out header 2020-01-07 14:04:13 -05:00
Daniel Agar d19f18d40b linux boards (ocpoc, bbblue, navio2) replace custom adc drivers with simple px4_arch implementation 2020-01-07 14:04:13 -05:00
Julian Oes fc9df31653 platforms: link libatomic only on emlid navio2 (raspberry pi)
Linking to libatomic is only required for targets such as Raspberry Pi but not on for normal x86/x86_64 Linux builds.
2020-01-06 20:15:39 -05:00
Jacob Dahl d08ec05bab PWM automatic trigger system (ATS) for parachutes (#13726)
* parameter and logic to commander for triggering failsafe from external automatic trigger system.
* logic to startup script for enabling ATS. Added uORB publishing to pwm_input module.
* Refactored out CDev usage from pwm_input and ll40ls. Refactored out ll40ls specifics from pwm_input and cleaned up dead code.
2020-01-06 20:14:06 -05:00
Kabir Mohammed 5d110101b5 adis16497: add sensor model autodetection (#13863)
The sensor comes in three variants with different gyro measurement ranges. This patch allows auto-detection of the model at startup and sets the scale factor associated with the particular model.
2020-01-06 18:17:41 -05:00
Daniel Agar 7166b867e1 NuttX stackcheck exclude PX4 Matrix and Param
- instrumenting PX4 Matrix and Param methods is too burdensome
 - partially restore px4_fmu-v5_stackcheck and holybro_durandal-v1_stackcheck to match default configs
2020-01-06 18:15:55 -05:00
Mathieu Bresciani 5adf23a6a8 Add gyroscope notch filter - IMU_GYRO_NF_(FREQ|BW)
* NotchFilter: add NotchFilter template and test for float type
* NotchFilterTest: add test for Vector3f notch filter
* PX4Gyroscope: add notch filter with IMU_GYRO_NF_(FREQ|BW) parameters to
set the notch center frequency and bandwidth
2020-01-06 16:53:36 -05:00
Nicolas MARTIN 031680a520 commander: remove ekf2 preflight ratio param units
Innovation ratios have no unit: it is a ratio of to squared base unit.
For example:
[COM_ARM_EKF_VEL] = [vel_innov]**2 / ([GATE_SIZE]**2 * [VEL_VAR])
= [m/s]**2 / ([1]**2 * [m/s]**2)
= [1]
2020-01-06 11:30:43 -05:00
Julian Oes 9e239e47c4 mavsdk_tests: fix PEP8 issues 2020-01-06 11:15:43 -05:00
Daniel Agar e29acea509 posix hrt add latency buckets 2020-01-06 16:26:56 +01:00
Julian Oes 25ff013418 vmount: fix float casting, simplify loop 2020-01-06 16:24:36 +01:00
Julian Oes 30cadf5903 vmount: properly initialize last_active
If last_active is initialized at 0 it means that input via mavlink is
already enabled but that's generally not the case.
2020-01-06 16:24:36 +01:00
Julian Oes 7a69b85850 vmount: fix input for test command
It is most convenient to use a yaw angle relative to body for testing.
Also, we set stabilize_axis to true for testing.
2020-01-06 16:24:36 +01:00
Julian Oes 4753e02364 vmount: fix implicit double promotion 2020-01-06 16:24:36 +01:00
Julian Oes 14133380e2 vmount: set all DO_MOUNT_CONFIGURE params
We previously did not set param2 to param7 of DO_MOUNT_CONFIGURE.
2020-01-06 16:24:36 +01:00
Julian Oes 5836edc586 vmount: first step to support absolute angles
The mavlink spec now supports absolute angles as well, see:
https://github.com/mavlink/mavlink/pull/944
2020-01-06 16:24:36 +01:00
Matthias Grob 1484dfed6a FlightTasks: remove deprecated AutoLine mission task 2020-01-06 15:39:07 +01:00
Julian Kent bb410ca0db Fix compile error, save some bytes by removing redundant checks 2020-01-06 15:39:07 +01:00
Julian Kent af961f2391 Avoidance interface should be a stop point 2020-01-06 15:39:07 +01:00
Julian Kent 33702be3e4 Fix bad assumption: _position_setpoint is normally at _target 2020-01-06 15:39:07 +01:00
Julian Kent 603a993380 Improve comments 2020-01-06 15:39:07 +01:00
Julian Kent 75d7a049c1 Use the new trajectory constraints to synchronize and limit velocities 2020-01-06 15:39:07 +01:00
Julian Kent 025c044530 Add trajectory constraints helpers 2020-01-06 15:39:07 +01:00
Daniel Agar 89693258a9 landing_target_estimator: initialize all fields
- fixes Coverity CID 253911
2020-01-05 22:59:49 -05:00
Daniel Agar 738b57c945 pxh: initialize all fields
- fixes Coverity CID 309151
2020-01-05 22:59:49 -05:00
Daniel Agar 4b96eb569d flight_tasks: getPositionSetpoint() initialize entire vehicle_local_position_setpoint_s
- this isn't strictly necessary (all used fields are set), but doesn't hurt
 - fixes Coverity CID 268659
2020-01-05 22:59:49 -05:00
Daniel Agar 0f3bb94ff7 uORB_test: initialize timings storage
- fixes Coverity CID 341740
2020-01-05 22:59:49 -05:00
Daniel Agar aabc89b2d0 vscode: commit auto added c++ header associations 2020-01-05 22:43:14 -05:00
Daniel Agar b60a519cbc drivers accel & gyroscope: use float for integrator accumulation
- fixes Coverity CID 352841 and CID 352840
2020-01-05 21:30:40 -05:00
Daniel Agar 44f9de5e37 delete parrot bebop board support
This target was never fully supported and is heavily dependent on a number of DriverFramework drivers that have no in tree equivalents (bebop bus, flow, rangefinder, etc). Deleting this will make it easier to fully drop DriverFramework shortly.
2020-01-05 19:46:51 -05:00
Daniel Agar ce1e9762b0 deprecate df_hmc5883_wrapper and replace with in tree hmc5883
- deprecate DriverFramework hmc5883 driver (df_hmc5883_wrapper)
 - update aerotenna ocpoc and snapdragon flight eagle boards to use in tree hmc5883
2020-01-05 15:17:26 -05:00
Daniel Agar 7241eebd80 cmake merge linux cross compile targets (cross + native) and cleanup
- consolidate cross and native variants (only a single default is needed)
   - beaglebone_blue_cross + beaglebone_blue_native => beaglebone_blue_default
   - emlid_navio2_cross + emlid_navio2_native => emlid_navio2_default
   - px4_raspberrypi_cross + px4_raspberrypi_native => px4_raspberrypi_default
 - move upload helpers to cmake/upload.cmake
2020-01-05 14:03:57 -05:00
Daniel Agar aaf5670e7d deprecate df_bmp280_wrapper and replace with in tree bmp280
- deprecate DriverFramework bmp280 driver (df_bmp280_wrapper)
 - update beaglebone blue and snapdragon flight eagle boards to use in tree bmp280
 - update posix (really just linux) and qurt I2C wrappers
 - tested on beaglebone blue
2020-01-05 13:33:12 -05:00
Daniel Agar 1da7209fe1 lps25h: move to PX4Barometer and cleanup 2020-01-05 10:35:13 -05:00
Mohammed Kabir bf9e193062 collision_prevention: fix sensor range float rounding 2020-01-05 20:22:51 +05:30
Daniel Agar a96dc9c0c8 navio2 adc fix strncpy size 2020-01-04 22:03:43 -05:00
Daniel Agar b292b04ac1 platforms posix link atomic 2020-01-04 22:03:43 -05:00
Daniel Agar bf23b1d0d8 linux_pwm_out: fix strncpy length and task main signature 2020-01-04 22:03:43 -05:00
Daniel Agar dcbb03b785 bmp280: fix device id (device type not set) 2020-01-04 13:16:08 -05:00
Daniel Agar 091c111f4f mpu9250: more small fixes and cleanup
- delete unused _checked_bad
 - delete unused "good transfers" perf counter
 - delete unused "bad transfers" perf counter
 - use proper register names in transfer structures
 - mpu9250 don't transfer unused status register
 - mpu9250 mag (ak8963) check overflow
 - mpu9250 mag (ak8963) pass data as const references
 - mpu9250 mag fix mag errors perf count
 - delete obsolete whoami checks
2020-01-04 12:38:22 -05:00
Lorenz Meier 093a982f49 Reduce speed factor in SITL CI tests
- With profiling enabled it is over-comitting the system.
2020-01-04 12:17:12 -05:00
Lorenz Meier b0cb29ed82 MAVSDK tests: Add minimal plane example
This will add coverage for baseline plane controllers.
2020-01-04 12:17:12 -05:00
Daniel Agar 5dfc8f1362 mpu9250: main handle init and alloc failures separately 2020-01-04 11:41:56 -05:00
Daniel Agar 25cbcca84a mpu9250: fix error return on reset fail 2020-01-04 11:41:56 -05:00
Daniel Agar 45937fb70a srf02: move to PX4Rangefinder and cleanup 2020-01-04 11:23:17 -05:00
Jin Chengde 91e4da8885 fix compile error 2020-01-04 10:55:25 -05:00
Jin Chengde 57f3be3a69 fix bug if speed reach minium during ramp 2020-01-04 10:55:25 -05:00
PX4 BuildBot a986a63504 Update submodule matrix to latest Sat Jan 4 12:39:31 UTC 2020
- matrix in PX4/Firmware (1cee4d3b0de55e2a7b874dfdaf7a9975a099195c): https://github.com/PX4/Matrix/commit/d18be0d0fa17d9a0b60ab34bad3e33160f907b09
    - matrix current upstream: https://github.com/PX4/Matrix/commit/3b581fb5998c7a15b741947e6a139b9e3f99fe38
    - Changes: https://github.com/PX4/Matrix/compare/d18be0d0fa17d9a0b60ab34bad3e33160f907b09...3b581fb5998c7a15b741947e6a139b9e3f99fe38

    3b581fb 2020-01-01 Lorenz Meier - Update .travis.yml
efa5580 2020-01-01 Lorenz Meier - Update CMakeLists.txt
20a9e91 2019-12-31 Lorenz Meier - Fix CMake configuration for coverage tests on Mac OS
2020-01-04 10:43:35 -05:00
SalimTerryLi 5f5a2e12fb mpu9250: improve AK8963 init (fixes raspberry pi support) 2020-01-03 22:29:46 -05:00
Daniel Agar 16bd1088fa mpl3115a2: move to PX4Barometer and cleanup 2020-01-03 16:53:09 -05:00
Daniel Agar 0c9161f004 sf0x: move to PX4Rangefinder and cleanup 2020-01-03 11:01:48 -05:00
Daniel Agar d5fb7f47c2 sf0x: split into separate header, implementation, and main 2020-01-03 11:01:48 -05:00
Daniel Agar 156cf16265 logger: log all raw sensor data at a minimal rate 2020-01-02 13:15:02 -05:00
Daniel Agar 1edfee4fdd mavsdk_tests: build should be independant of px4 2020-01-01 22:05:29 -05:00
Daniel Agar 7775dfbc56 mavsdk_test_runner.py remove verbose gazebo output 2020-01-01 21:55:42 +01:00
Daniel Agar 9df06ffdea posix main wait_to_exit() fix and catch SIGTERM
- wait_to_exist() shouldn't depend on lockstep (px4_usleep)
2020-01-01 21:55:42 +01:00
Daniel Agar f7cf1ffc41 drivers/uavcan: remove MAVLINK header dependency 2019-12-31 21:01:21 -05:00
Daniel Agar 35073d093f gitignore update for in tree cmake builds 2019-12-31 12:37:22 -05:00
Daniel Agar 04efd91840 leddar_one: split into separate header, implementation, and main
- remove default serial port
2019-12-31 10:51:28 -05:00
Daniel Agar 213c6a1923 deprecate df_ms5611_wrapper and df_ms5607_wrapper (replaced with in tree ms5611 driver) 2019-12-31 10:37:29 -05:00
Daniel Agar e48b8b1abe drivers/adc: start WQ cycle on init 2019-12-31 13:42:42 +01:00
Daniel Agar ef12e63af2 ms5611: move to PX4Barometer and cleanup 2019-12-30 18:00:52 -05:00
SalimTerryLi 87e5da189b ms5611: fix start_bus() logic to work on linux and add RPi I2C bus config (#13814) 2019-12-30 16:16:56 -05:00
Daniel Agar c8fb3c589a posix I2C::init() should also probe() (sync with NuttX) 2019-12-30 10:37:07 -05:00
Daniel Agar cc7a0cd69d beaglebone blue: build librobotcontrol with cmake 2019-12-29 17:32:06 -05:00
PX4 BuildBot b3889e6187 Update submodule matrix to latest Sun Dec 29 00:38:26 UTC 2019
- matrix in PX4/Firmware (82244037f4f4be591cf1c8b9a25bb4969d0d33a9): https://github.com/PX4/Matrix/commit/e81483a808ce7b0217c11d3dc0fce90685f44353
    - matrix current upstream: https://github.com/PX4/Matrix/commit/d18be0d0fa17d9a0b60ab34bad3e33160f907b09
    - Changes: https://github.com/PX4/Matrix/compare/e81483a808ce7b0217c11d3dc0fce90685f44353...d18be0d0fa17d9a0b60ab34bad3e33160f907b09

    d18be0d 2019-12-28 kritz - Fix AngleAxis constructors (#117)
2019-12-28 20:25:33 -05:00
Daniel Agar 5c8ff4e680 Update submodule mavlink v2.0 to latest Sun Dec 29 00:38:12 UTC 2019
- mavlink v2.0 in PX4/Firmware (0fc4c66994d6164b60fdee818307d37ba5cf12d1): https://github.com/mavlink/c_library_v2/commit/412bad674e07535563e85565ba88f2d2c69ed378
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/dbcc725631ce695e0f00a6f6ae1eae2c46cc214c
    - Changes: https://github.com/mavlink/c_library_v2/compare/412bad674e07535563e85565ba88f2d2c69ed378...dbcc725631ce695e0f00a6f6ae1eae2c46cc214c
2019-12-28 20:24:25 -05:00
modaltb 9b707eebc7 bmp388: use default stack size of 2048, fixes stack check failure 2019-12-28 19:21:05 -05:00
Mathieu Bresciani 226169192a ekf2check: add COM_ARM_MAG_STR to en/disable mag field strength preflight check 2019-12-28 14:06:14 -05:00
Silvan Fuhrer 7bb952baed update airspeed usage to airspeed_validated (#13710)
* Mavlink: subscribe to airspeed_validated instead of airspeed topic

	This e.g. changes the way QGC displays the airspeed in case of an
	airspeed failure (0 instead of the last valid airspeed). It will
	always display the airspeed that's used currently in the control
	modules.

* FW land detector: move to subscribe to airspeed_validated instead of airspeed topic
	- the land detector checks further if the airspeed is NAN, in which case
	it sets the airspeed to 0 (min groundspeed, vz  and accel checks still
	have to pass.

* Fixed-wing land detector use airspeed_vaidated: addressed review comments
	- replaced ternary by conditional
	- set airspeed to 0 if airspeed_validated stops publishing

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-12-28 12:32:41 -05:00
Timothy Scott fc1341208f INA226: Integrate with PX4 (#12673)
* Publish I2C battery data as battery_status
2019-12-28 12:30:11 -05:00
Silvan Fuhrer 574b482fdb Navigator: make weather vane work in all auto modes, not just mission (#13761)
- rename of flag in position sp: from allow_weather_vane to disable_weather_vane
 - flag now doesn't have to be set for all auto modes, meaning that weather vane is also active outside of mission
 - flag is set before front transition to align with wp, and unset after alignment is over

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-12-28 12:13:15 -05:00
Daniel Agar 89e1f478ac PX4Accelerometer and PX4Gyroscope add vibration metrics and always publish status 2019-12-27 20:54:50 -05:00
Daniel Agar e189733bb9 l3gd20: split into separate header, implementation, and main 2019-12-27 17:29:04 -05:00
Daniel Agar 30a73416dc mavsdk SITL testing code coverage and upload to codecov.io 2019-12-26 14:31:33 -05:00
Lorenz Meier 2120c87d1e Update ccpp.yml
The checkout action is not recursive, leading to build issues. Rely on auto-checkout on make instead.
2019-12-26 16:31:30 +01:00
Lorenz Meier f8ab98b5de GH Actions: Remove submodules
The checkout action is not recursive, leading to build issues. Rely on auto-checkout on make instead.
2019-12-26 16:31:10 +01:00
Lorenz Meier 81472b9a6b Disable ROS2 in Jenkins due to Python3
We will bring this back when Python 3 is back operational.
2019-12-26 15:09:13 +01:00
Lorenz Meier 9d5c6c0baa Update SITL Github Action
Github doesn't check out recursively, which breaks the build. We rely on the auto-checkout in our build system instead.
2019-12-26 13:24:40 +01:00
Lorenz Meier 9ef0d7a6b6 Update compile_nuttx.yml
Fix submodule usage in CI.
2019-12-26 13:17:05 +01:00
Lorenz Meier 1f63408aa0 SITL Github Action: Document Grind config in-place
This helps anyone needing it to find and set the correct grind iteration parameter.
2019-12-26 13:00:59 +01:00
Lorenz Meier eda1459140 Add access token to SITL test Github Action
This is needed for downstream adopters. We want them to re-use our CI tests so that contributions already are pre-tested when they are submitted.
2019-12-26 12:59:09 +01:00
Lorenz Meier 77951c1e07 Add access token to NuttX Github Action
This is necessary for downstream adopters. We want them to run these actions as well so that contributions are already pre-tested.
2019-12-26 12:57:58 +01:00
Lorenz Meier 993938c0b1 Add access token to C++ build test
This is necessary for downstream adopters.
2019-12-26 12:57:08 +01:00
Lorenz Meier d86a308f76 Add access token to build_tests.yml (#13789)
Add access token to build_tests.yml

This is necessary to enable GH Actions for downstream adopters. This also enables the explicit submodule checkout.
2019-12-26 12:54:56 +01:00
Matthias Grob ffff35a597 Unit tests: use EXPECT_FLOAT_EQ for float comparisons
as precaution to prevent failing tests because of small potential
rounding errors on certain platforms or compilares.
2019-12-26 12:53:07 +01:00
Matthias Grob ee62d0296f ControlMathTest: consistent short float literal notation 2019-12-26 12:53:07 +01:00
Matthias Grob ad148fdfad ControlMathTest: switch back to direct EXPECT_EQ calls for Vectors
Since the google test calls matrix::operator==()
which calls matrix::isEqual().
2019-12-26 12:53:07 +01:00
JaeyoungLim d5100b10dc Update comments 2019-12-26 12:03:32 +01:00
RomanBapst eeb47f6148 gazebo multiple sim script: cleanup
- make sure to kill all px4 instances and gazebo client when exiting
- add arguments to specify number of vehicles and vehicle model
- exit for now if vehicle model is not iris, since needs changes in
sitl_gazebo submodule

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-12-26 12:03:32 +01:00
JaeyoungLim 876f42c171 Source environment inside the script 2019-12-26 12:03:32 +01:00
JaeyoungLim 155a212109 Update comments 2019-12-26 12:03:32 +01:00
JaeyoungLim f653be75c0 gazebo multiple sim: use xacro from the sitl_gazebo repository
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-12-26 12:03:32 +01:00
JaeyoungLim 0b649326c3 Support multi vehicle sitl gazebo without ros 2019-12-26 12:03:32 +01:00
Lorenz Meier aaf033044d GH Actions: Only build on push
This still captures all commits, but does not cover the merged state of the PR. All PRs need to be up-to-date before merging/rebasing, which is better practice anyway.
2019-12-26 10:16:58 +01:00
Lorenz Meier adf7aee762 Harden autostart logic for non-existent airframe values
This ensures that the user is pushed back to the airframe configuration stage.
2019-12-26 10:16:58 +01:00
Lorenz Meier f5ce40e434 FMUv2: Exclude some multicopter targets
These are rarely used airframes that should not be missed.
2019-12-26 10:16:58 +01:00
Lorenz Meier 0c85c5d18e FMUv2: Exclude some fixed wing targets
These are rarely used airframes that should not be missed.
2019-12-26 10:16:58 +01:00
Lorenz Meier 02119c1832 FMUv2: Exclude rover targets
This is reasonable as these boards are very old and rovers are a new area of activity.
2019-12-26 10:16:58 +01:00
Lorenz Meier be35c4857b SITL shell: Do math using the shell
Bash or zsh from the last 10 years or so do math using the $((a + b)) syntax. This saves us from having bc as dependency.
2019-12-26 10:16:58 +01:00
Lorenz Meier 26d01b876c GH Actions: Enable grind option
This allows to run the script in grind mode to find CI failures that are triggered through e.g. race conditions.
2019-12-26 10:16:58 +01:00
Lorenz Meier 73edc21667 Tests: Add further instrumentation 2019-12-26 10:16:58 +01:00
Lorenz Meier 1834c156d2 Simulator: Remove EKF2 based wait
This is cleaner and needs testing.
2019-12-26 10:16:58 +01:00
Lorenz Meier 742b1839d5 Simulation: Set scheduling policy RR for lockstep
This should ensure that all processes do still run at full load.
2019-12-26 10:16:58 +01:00
Lorenz Meier 663436fd47 Integration tests: Add Makefile target
This enables unfamiliar users to run the tests quickly without having to memorize all commandsline options.
2019-12-26 10:16:58 +01:00
Lorenz Meier cd75cc08d3 Add baseline SITL environment via Github actions 2019-12-26 10:16:58 +01:00
Julian Oes 81809d8234 ROMFS: prevent high accel bias in SITL 2019-12-26 10:16:58 +01:00
Julian Oes 3a228622b9 mavsdk_tests: fix verbose output 2019-12-26 10:16:58 +01:00
Julian Oes 16da8466e3 posix: exit if the startup script is not ok
In general, if anything goes wrong in the startup script, we
should fail entirely because things might not work as expected.

In particular, this prevents that we have to press Ctrl+C twice if the
simulator start call is hung waiting for the simulator to appear and
start communicating. We now press Ctrl+C once and exit straightaway
whereas before we would press it once to get the warning:
"Startup script returned with return value: 2",
and then finally exit on the second press.
2019-12-26 10:16:58 +01:00
Julian Oes 8817f172ea simulator: cleanup and wait for startup
Unfortunately this commit contains two things:
1. Some cleanup and renaiming.
2. An additional wait until lockstep has been initialized.
   By waiting until HIL_SENSOR messages arrive including timestamps we
   stop the startup script and prevent other modules from running until
   time is set up. This should resolve some busy waiting by various
   modules and prevent races on initialization (e.g. the landing state
   being subscribed by mavlink before being published by the land
   detector).
2019-12-26 10:16:58 +01:00
Julian Oes 99fbadac70 mavsdk_tests: remove output to logfile for now 2019-12-26 10:16:58 +01:00
Julian Oes 6e0cb7859e mavsdk_tests: add option for gzclient GUI 2019-12-26 10:16:58 +01:00
Julian Oes 698731e4f5 mavsdk_tests: don't use SIGINT, just terminate 2019-12-26 10:16:58 +01:00
Julian Oes f5cc6b7dcf mavsdk_tests: end the logfiles with .log 2019-12-26 10:16:58 +01:00
Julian Oes d32e3919dd mavsdk_tests: return error if not ready 2019-12-26 10:16:58 +01:00
Julian Oes b6e6d66616 mavsdk_tests: env vars need to be strings 2019-12-26 10:16:58 +01:00
Julian Oes 7ff4bd8289 mavsdk_tests: use subprocess instead of sys stdout 2019-12-26 10:16:58 +01:00
Julian Oes eef57f93ae mavsdk_tests: fix bugs in readyness checks 2019-12-26 10:16:58 +01:00
Julian Oes 580ea06fb7 mavsdk_tests: restart SITL after each test case 2019-12-26 10:16:58 +01:00
Julian Oes c363a15ad8 mavsdk_tests: enable VTOL tests as well 2019-12-26 10:16:58 +01:00
Julian Oes cc249f980b mavsdk_tests: check if build everything is built 2019-12-26 10:16:58 +01:00
Julian Oes 0a3152786b mavsdk_tests: use SIGINT before SIGTERM 2019-12-26 10:16:58 +01:00
Julian Oes 79a4bde155 mavsdk_tests: rename C++ executable
The executable contains all tests, so the name was a poor choice.
2019-12-26 10:16:58 +01:00
Julian Oes 90c79493f2 mavsdk_tests: print overall result 2019-12-26 10:16:58 +01:00
Julian Oes dde7530df6 mavsdk_tests: properly handle timeout 2019-12-26 10:16:58 +01:00
Julian Oes ce9aa119ff mavsdk_tests: option for speed factor
And we also need to communicate the speed factor for the px4 executable,
otherwise it can't adapt the timeouts accordingly.
2019-12-26 10:16:58 +01:00
Julian Oes 22bac037ed mavsdk_tests: better process management
We now error if px4 or gzserver are already running on startup, and we
also make sure to terminate what we started if interrupted.
2019-12-26 10:16:58 +01:00
Julian Oes 2bbe4dac25 mavsdk_tests: run test runner, speed up sim 2019-12-26 10:16:58 +01:00
Julian Oes 728a0b033e mavsdk_tests: add termination/kill, custom log dir 2019-12-26 10:16:58 +01:00
Julian Oes 09d63f5531 mavsdk_tests: added test runner 2019-12-26 10:16:58 +01:00
Julian Oes 956bd1b7b1 Move mavsdk_tests into test 2019-12-26 10:16:58 +01:00
Julian Oes 97d7925431 mavsdk_tests: add to PX4 Makefile/CMakeLists.txt 2019-12-26 10:16:58 +01:00
Julian Oes 5f67075481 mavsdk_tests: raise timeout for realtime sim speed 2019-12-26 10:16:58 +01:00
Julian Oes 64fa7e3fdc mavsdk_tests: add manual RTL after mission 2019-12-26 10:16:58 +01:00
Julian Oes 50892cec9c mavsdk_tests: wait until mission is done 2019-12-26 10:16:58 +01:00
Julian Oes 217ba4f981 mavsdk_tests: Split tests and test main 2019-12-26 10:16:58 +01:00
Julian Oes 70d461bc6d Added first two simple MAVSDK tests 2019-12-26 10:16:58 +01:00
Daniel Agar 49e315f2e2 Jenkins temporarily disable "PX4 ROS msgs" in master
- re-enable once the python issues are resolved
2019-12-24 14:49:47 -05:00
Daniel Agar 6c6ae6842a github actions compile all nuttx configs 2019-12-24 14:21:37 -05:00
bresch dab17d628d PreFlightChecker: update unit tests 2019-12-24 13:18:47 -05:00
bresch 8080615191 PreFlightChecker: add spike limit argument for innovation check and
increase optical flow test limits.
2019-12-24 13:18:47 -05:00
PX4 BuildBot b6b8a9a76e Update submodule matrix to latest Tue Dec 24 12:39:27 UTC 2019
- matrix in PX4/Firmware (0aa62a3bfff12d854d6a8e378a518bd8646a9f4b): https://github.com/PX4/Matrix/commit/4f3565da94d00c4cd1feb560f1f72a81296522f8
    - matrix current upstream: https://github.com/PX4/Matrix/commit/e81483a808ce7b0217c11d3dc0fce90685f44353
    - Changes: https://github.com/PX4/Matrix/compare/4f3565da94d00c4cd1feb560f1f72a81296522f8...e81483a808ce7b0217c11d3dc0fce90685f44353

    e81483a 2019-12-18 kritz - Catch quaternion canonical corner cases (#116)
2019-12-24 13:15:42 -05:00
RomanBapst 4c35b3aadc navigator: do not use fixed wing acceptance readius if in rotary wing mode
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-12-24 12:52:10 -05:00
Lorenz Meier 2e7221cd22 Style check commit hook: Ensure that formatted files need to be re-added. 2019-12-24 15:16:26 +01:00
Daniel Agar 0e70578052 commander: move most static variables and parameters to class 2019-12-23 23:38:10 -05:00
Daniel Agar 386673e6c3 fix flt_cutoff_min -> flt_cutoff_max 2019-12-23 23:47:34 +01:00
Daniel Agar 93d392ff80 Update src/modules/rc_update/rc_update.cpp
Co-Authored-By: Beat Küng <beat-kueng@gmx.net>
2019-12-23 23:47:34 +01:00
Daniel Agar 607cb97758 Update src/modules/rc_update/rc_update.cpp
Co-Authored-By: Beat Küng <beat-kueng@gmx.net>
2019-12-23 23:47:34 +01:00
Daniel Agar 57fc98812d rc_update: cleanup parameter usage 2019-12-23 23:47:34 +01:00
Lorenz Meier acd18adc18 Tests: Speed up boot
The previous boot configuration took at minimum one second to boot. This is in particular significant in tests when the system is often started and stopped
2019-12-23 23:08:05 +01:00
Lorenz Meier 9ac68abd5c Fix float accuracy in ControlMathTest
The test was testing the result of 3D float vector operations with binary equality of the floating point numbers, which is not a valid assumption to make for floating point math. This change switches to proper comparisons with float accuracy and compares vectors using the norm of their difference.
2019-12-23 22:29:09 +01:00
Silvan Fuhrer e6b18fe2da mission feasibility checker: move checks for VTOL landing into separate function
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-12-23 21:47:16 +01:00
Julian Oes 3a37d0b560 navigator: improve if structure for vtol/mc/fw 2019-12-23 21:47:16 +01:00
Julian Oes f9aa12eaa9 navigator: don't allow Land together with RTL item
This is a check to protect a user from upload a mission which includes a
land_start marker as well as a RTL mission item.

This works around the problem that we experienced where the navigator
would switch to mission mode on RTL and start with land_start, and then
continue to the RTL item. At this point, navigator would send the
vehicle_command for RTL to commander which would deny it because it is
already in RTL mode. Thus navigator won't (re)set any items to actually
do RTL and it means the vehicle will just head to whatever setpoint it
received last.
2019-12-23 21:47:16 +01:00
Julian Oes f8c10b706a navigator: check fixedwing mission for VTOL
A VTOL mission can also contain a fixedwing landing. Therefore, I think,
it makes sense to run the fixedwing checks as well, however, don't check
for a landing start necessarily.
2019-12-23 21:47:16 +01:00
Matthias Grob de95e3d274 commander: remove manual mode before geofence handling 2019-12-23 12:18:27 -05:00
Jin Chengde 34121e655b FW runway takeoff: add negative for min to support tricycle landing gear
- if we used tricycle landing gear, we need the wheel to  touch the ground to control the direction
2019-12-23 11:47:11 -05:00
Daniel Agar 176d7ef62d Jenkins PX4 ROS2 bridge don't specify python binary 2019-12-23 11:06:50 -05:00
dino 49cb21016a Ddded cli check for ism330dlc startup to prevent hardfault if no options are given. 2019-12-20 16:40:18 +01:00
Julian Kent e4a526e3b2 Don't sleep in middle of mavlink message reception 2019-12-19 11:43:03 -08:00
Julian Oes a9ca16cafe Fix a couple of flake8 Python warnings (#13763)
* Tools: fix flake8 error

* platforms: fix flake8 error

This is just guessed.
2019-12-19 07:36:16 -08:00
Christian Clauss 6dc55f97d4 More fixes for Python 3 compatibility (#13008)
* More fixes for Python 3 compatibility

* Workaround if the six module is not pip installed

* Lose the semicolons
2019-12-19 02:05:55 -08:00
David Sidrane 2a848c365c holybro_durandal-v1:GPIO_VDD_5V_{HIPOWER|PERIPH}_OC remove Pull up - OC have series 47K 2019-12-18 12:21:33 -08:00
Daniel Agar 7fd4db1881 commander: skip all mag checks if SYS_HAS_MAG is 0 2019-12-18 11:54:40 -08:00
Matthias Grob a46add9a93 PositionControl: isolate skip controller, leave away unnecessary include 2019-12-18 15:57:48 +01:00
Matthias Grob 8441bdb9b5 PositionControl: remove complicated internal control flags 2019-12-18 15:57:48 +01:00
Matthias Grob 83e51ad192 PositionControl: remove speed_xy constraint since it's anyways unused 2019-12-18 15:57:48 +01:00
Matthias Grob a4a9d50a97 ControlMath: refactor thrustToAttitude calculation 2019-12-18 15:57:48 +01:00
Matthias Grob 1a5b06d0cf FlightTasks: refactor NAN initializations, spacing 2019-12-18 15:57:48 +01:00
Matthias Grob ab4473319a Takeoff: add proper unit test 2019-12-18 15:57:48 +01:00
Matthias Grob 42dbddb156 mc_pos_control: adopt to module internal include convention 2019-12-18 15:57:48 +01:00
Matthias Grob 2303071df4 PositionControl: simplify constraint conditions 2019-12-18 15:57:48 +01:00
Matthias Grob 121d743049 PositionControl: clear setter interface naming, order, description 2019-12-18 15:57:48 +01:00
Chris Lovett 01818b505f posix server: switch from fcntl(..., F_SETLK, ...) to flock(...) (#13718)
- Required for Windows
- Add better diagnostic output in some places.
- close the lock file descriptor where we don't need to keep it open
2019-12-18 09:53:07 +01:00
bazooka joe eac7b43f3e Remove rescaling Lat and Lon on VEHICLE_CMD
relevant to VEHICLE_CMD_DO_REPOSITION and VEHICLE_CMD_NAV_TAKEOFF
its done on mavlink_receiver already
2019-12-18 09:48:30 +01:00
Beat Küng e10a4c5002 refactor logger: move subscription initialization into separate class 2019-12-17 21:22:30 -08:00
Beat Küng 738ceab0ee Logger: dynamic number of subscriptions
Keep a fixed-size array of 250 requested topics on the stack, then allocate
an array with LoggerSubscription with the exact required size.
2019-12-17 21:22:30 -08:00
Beat Küng 2757647897 refactor logger: reduce required size of WrittenFormats
by keeping only recursive topics in there. The rest is checked by looking
at previous _subscriptions.

Reduces stack size requirements when increasing MAX_TOPICS_NUM.
2019-12-17 21:22:30 -08:00
David Sidrane 5bb82a9f93 px4_fmu-v5x:GPIO_VDD_5V_{HIPOWER|PERIPH}_nOC remove Pull up - OC have series 47K 2019-12-17 18:33:20 -08:00
David Sidrane a5be0bb3d8 px4_fmu-v5:GPIO_VDD_5V_{HIPOWER|PERIPH}_OC remove Pull up - OC have series 47K 2019-12-17 18:33:20 -08:00
David 020215f146 commander: don't allow arming during VTOL transition 2019-12-17 12:21:11 -08:00
Daniel Agar 3d56f37606 vscode debug and ekf2 replay improvements
- create new px4_sitl_replay config specifically for replay
 - ekf2 replay don't launch gazebo
 - add px4_sitl_test cmake variant
 - px4_sitl_test bring into sync with px4_sitl_default
 - vscode replace hard coded build path with cmake setting
2019-12-17 10:19:56 -08:00
Beat Küng 46a7b27127 kakutef7: fix baro startup
The bmp280 is on the expansion bus (that is both internal & external)
2019-12-17 09:57:32 -08:00
Timothy Scott 7abadabc19 Added support for MAV_CMD_REQUEST_MESSAGE for mavlink streams 2019-12-16 06:45:53 -08:00
JaeyoungLim 4bcdf560be airframes: add config for px4vision devkit drone (#13683)
* Added configuration file for Pixhawk Vision

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-12-16 08:21:17 +01:00
kamilritz 2a707cf669 Debug log replays with gdb in vscode 2019-12-15 10:28:04 -05:00
JaeyoungLim 94e05362e1 Make cellular status logging default 2019-12-14 21:56:12 +11:00
Ricardo Marques 86d3453343 Fix rover_sitl mixer call in CMakeLists.txt 2019-12-12 13:43:08 -05:00
Daniel Agar f769b80fde cmake px4_add_romfs_files FATAL_ERROR if file doesn't exist 2019-12-12 13:42:30 -05:00
PX4 BuildBot 6f4b9f93fd Update submodule nuttx to latest Thu Dec 12 14:57:56 UTC 2019
- nuttx in PX4/Firmware (327c7f3672ee5f066ec53dfe1554a02d1aa610da): https://github.com/PX4/NuttX/commit/2e55ce8ec97d37b3d3c46b1aaab0a09364fcf254
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/9331fda0d7f7220de33982e8a641c671b1f09c8e
    - Changes: https://github.com/PX4/NuttX/compare/2e55ce8ec97d37b3d3c46b1aaab0a09364fcf254...9331fda0d7f7220de33982e8a641c671b1f09c8e

    9331fda0d7 2019-12-10 David Sidrane - [BACKPORT] IMXRT106x USDHC: Support regular GPIO for CD and inversion.
91c80c708b 2019-12-05 David Sidrane - [BACKPORT] imxrt106x:pinout add ALT 8 GPIO_GPT1_CAPTURE[1|2]
32f758f0e9 2019-12-03 David Sidrane - [BACKPORT] stm32f7:Add Serial Tx DMA
2019-12-12 10:23:29 -05:00
Daniel Agar de9e4dda4c battery: delete unused armed 2019-12-12 09:48:45 -05:00
Timothy Scott 11bbc8ae34 Code cleanup 2019-12-12 04:39:53 -08:00
Daniel Agar 77cf081925 holybro_durandal-v1 don't manually start pmw3901 2019-12-11 21:08:22 -05:00
Silvan Fuhrer 1617997dde VTOL: instantly do VTOL mode changes if landed and disarmed
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-12-11 20:10:25 -05:00
bresch d6ffdc09b8 FlightTaskManualPosition: use new Matrix available functions to cast
from a vector of 4 elements to Vector2f and from Vector2f to Vector3f.
2019-12-11 17:21:57 +02:00
bresch d0bdd80129 FlightTaskManualPosition: Remove MPC_ACC_HOR_ESTM parameter. This was
used back in time when no soothing was done to avoid large steps when
the estimator stops sending a maximum velocity (e.g.:GPS gained during
optical flow flight). Since smoothing is applied later, this is not
required anymore.
2019-12-11 17:21:57 +02:00
Matthias Grob a3d30fc970 mc_pos_control/FlightTask: apply nit-pick review findings 2019-12-11 14:03:16 +01:00
bresch 82b4e766a5 AutoMapper2: re-introduce gradual vertical speed limitation during landing between alt1 and alt2 2019-12-11 14:03:16 +01:00
bresch 4d0786d5b4 FlightTask: use centralized _dist_to_ground computed in FlightTask instead of
recomputing it in AutoMapper, AutoMapper2 and AutoLine
2019-12-11 14:03:16 +01:00
bresch 4ba672a7ba ManualPosition: Limit horizontal speed during landing 2019-12-11 14:03:16 +01:00
David Jablonski 944bf54d84 Use correct params for DO_MOUNT_CONTROL
If MAV_MOUNT_MODE is GPS_POINT, the mavlink documentation recommends to
use params4-6. In the current implementation params1-3 were used
instead.
2019-12-11 09:00:17 +01:00
Daniel Agar 2b792c0225 px4_raspberrypi cleanup configs and add to Jenkins 2019-12-10 11:10:24 -05:00
Daniel Agar 505e922b08 Update submodule mavlink v2.0 to latest Tue Dec 10 00:39:06 UTC 2019
- mavlink v2.0 in PX4/Firmware (f9e8f615e3): https://github.com/mavlink/c_library_v2/commit/75ab59ddc1660c136fdec5553f622a603558b8cd
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/412bad674e07535563e85565ba88f2d2c69ed378
    - Changes: https://github.com/mavlink/c_library_v2/compare/75ab59ddc1660c136fdec5553f622a603558b8cd...412bad674e07535563e85565ba88f2d2c69ed378
2019-12-09 20:45:08 -05:00
PX4 BuildBot 4e75f54fcf Update submodule matrix to latest Tue Dec 10 00:39:17 UTC 2019
- matrix in PX4/Firmware (478a27ee8843a9bd91a0254f6b01a6a9c01946a4): https://github.com/PX4/Matrix/commit/a8009a36a3668da0cbab0cb028b6997cd8179dc1
    - matrix current upstream: https://github.com/PX4/Matrix/commit/4f3565da94d00c4cd1feb560f1f72a81296522f8
    - Changes: https://github.com/PX4/Matrix/compare/a8009a36a3668da0cbab0cb028b6997cd8179dc1...4f3565da94d00c4cd1feb560f1f72a81296522f8

    4f3565d 2019-12-09 kritz - Add asserts (#115)
2f63981 2019-12-06 kritz - Add several functions that are useful for coavriance matrices: (#114)
5cbcf60 2019-12-05 kritz - Set Matrix's col amd row to single value (#113)
ef442fa 2019-12-05 kritz - Getter function for the diag elements of slice (#112)
de6a2d3 2019-12-04 kritz - Slice assign value (#111)
2019-12-09 20:42:39 -05:00
Daniel Agar f9e8f615e3 holybro_kakutef7 sync INTERRUPTSTACK, HPWORKSTACKSIZE, and LPWORKSTACKSIZE with v5x 2019-12-09 18:45:27 -05:00
Daniel Agar bb09ac0c6d modalai_fc-v1 sync NFILE_DESCRIPTORS, HPWORKSTACKSIZE, and LPWORKSTACKSIZE with v5x 2019-12-09 18:45:27 -05:00
Daniel Agar b4fa915c86 uORB_tests: fix queue simulation and cleanup initializations 2019-12-09 16:50:33 -05:00
David Sidrane 1298f6840f px4io:Lower Police light activation 2019-12-09 16:23:16 -05:00
David Sidrane 74b6cc5bce px4_fmu-v5:Use Serial TX DMA on Telem 2 2019-12-09 16:23:16 -05:00
Daniel Agar 1d3f722201 px4_work_queue: increase hp_default stack 1800 -> 1900 bytes 2019-12-09 12:41:11 -05:00
modaltb c5de2cfe0d modalai_fc-v1: Add support for VOXL Flight board defaults, handle default MAVLink setups (#13677)
- Handle out of box config for Flight Core and VOXL Flight
- Handle AUTOCNF use case
- Hard code TELEM2 MAVLink Instace 1 for VOXL Flight
2019-12-09 12:39:17 -05:00
Julian Oes abf174282f navigator: fix VTOL RTL corner case
This fixes a corner case for VTOL RTL with RTL_TYPE 1.
RTL_TYPE 1 means that the VTOL skips all waypoints on RTL and jumps to
the land waypoint at the end.

During a mission in fixedwing mode it will continue to fly in fixedwing
mode and then do a transition before landing.

However, if RTL is engaged right at the moment of the front transition,
the transition waypoint is not inserted and the VTOL will try to land in
fixedwing mode at the mission land location.

This corner case is fixed in this patch by also considering the
"transition after takeoff" state.
2019-12-09 12:27:46 -05:00
Matthias Grob 904ab16558 Fix trailing whitespace, EOF newline, indentation 2019-12-09 13:22:19 +01:00
Morten Fyhn Amundsen 1d3da86abb mavlink_receiver: Set distance_sensor id field equal to mavlink msg
The id field should be copied from the mavlink message, not
simply set to MAV_DISTANCE_SENSOR_LASER (which is 0).
2019-12-09 09:53:32 +01:00
Julian Oes 2c73aefafe tests: workaround against astyle 3.1 bug
This prevents astyle 3.1 from changing these 3 matrices without a good
reason.
2019-12-09 09:28:27 +01:00
Daniel Agar 0a59d8a36d Jenkins hardware leave RGB LED defaults 2019-12-07 20:48:10 -05:00
Beat Küng fbcc6a96bc fix mavlink: fixes for mavlink on USB instance
Open the UART after adding the instance: mavlink_open_uart() might block,
and in that case the parent task waiting for mavlink to be started times
out.

And while waiting for the USB UART device to come up:
- check for _task_should_exit
- check for check_requested_subscriptions()

Side-effects when USB is not plugged in during boot:
- reduces boot duration by 100ms
- fixes duplicate instance name in 'top':
 201 mavlink_if0                     1  0.000  1328/ 2572 100 (100)  w:sig  3
 204 mavlink_if0                   572  4.221  1632/ 2540 100 (100)  w:sig  4
- 'mavlink stop-all' now stops the usb instance as well
2019-12-06 01:00:06 -05:00
Beat Küng e003b1ce79 mavlink: remove unused get_uart_fd(unsigned index) method 2019-12-06 01:00:06 -05:00
Timothy Scott 993fa5bd37 Refactored to work with new battery_status module 2019-12-05 16:38:04 +01:00
Timothy Scott d7bb5d46bb Created new AnalogBattery class 2019-12-05 16:38:04 +01:00
Timothy Scott bff1df7080 Refactored battery library for multiple instances 2019-12-05 16:38:04 +01:00
kamilritz d7b95870b9 Update to merged ECL commit 2019-12-05 11:29:29 +01:00
kamilritz 24efc1b79c Set not yet supported estimator_innovations fields to zero 2019-12-05 11:29:29 +01:00
kamilritz 5d0965e83a Log height innovation sensor specific 2019-12-05 11:29:29 +01:00
kamilritz 61b569245b Reorder innovations in LPE 2019-12-05 11:29:29 +01:00
kamilritz b73c80428e ECL: Clean velPos logging, deprecate ekf2_innovations msg 2019-12-05 11:29:29 +01:00
Daniel Agar 22e4e85eeb collision_prevention: don't unadvertise mavlink_log in destructor 2019-12-05 07:04:50 +01:00
mcsauder bd98a4eebb Add camera_capture module build to raspberry pi cross.cmake. 2019-12-04 00:48:52 -05:00
Daniel Agar 5af8286739 Jenkins hardware board cleanup/reset at end of test 2019-12-04 00:43:44 -05:00
Daniel Agar 709961ec8c InvenSense ICM20602 and ICM20608-G: new standalone optimized drivers
- uses the FIFO and SPI DMA to transfer full raw data (8 kHz gyro, 4 kHz accel)
 - new sensor messages for better visibility
   - sensor_{accel, gyro}_fifo: full raw data for optional logging and analysis
   - sensor_{accel, gyro}_status: metadata, clipping, etc
 - currently not enabled by default
2019-12-03 23:21:32 -05:00
David Sidrane 2badea316f systemcmds/serial_test: linux-serial-test ported to run on nuttx (#13662) 2019-12-03 20:51:17 -05:00
Daniel Agar 4a75840b33 Jenkins temporarily disable fmu-v5x (obsolete prototype on test rack) 2019-12-03 17:43:55 -05:00
David Sidrane feaa657172 px4_fmu-v5x:SE050 Assert Reset on board_init, and release in appinit 2019-12-03 16:16:49 -05:00
David Sidrane 949ab563ef px4_fmu-v5x:Drop netinit task priority below LP work 2019-12-03 16:16:49 -05:00
David Sidrane c9cb59fdd8 px4_fmu-v5x:Init Network in background (no monitor CONFIG_NETINIT_MONITOR is not set) 2019-12-03 16:16:49 -05:00
dino 34f53c14bf Fixed sensor orientation 2019-12-03 16:16:49 -05:00
dino 0dbd6d70d5 Fixed gyro com errors. Error check was triggering if board was not moved 2019-12-03 16:16:49 -05:00
David Sidrane 213174fc74 px4_fmu-v5x:Set IP 192.168.0.123 GW:192.168.0.254 2019-12-03 16:16:49 -05:00
David Sidrane ea69fde02a px4_fmu-v5x:Add SPI6_nRESET_EXTERNAL1 2019-12-03 16:16:49 -05:00
David Sidrane 3b88142744 px4_fmu-v5x:rc.board_sensors Add Second BMP388 2019-12-03 16:16:49 -05:00
David Sidrane 996ee49868 fmu-v5x:SPI4 is not used BMM150 moved to I2C4 2019-12-03 16:16:49 -05:00
David Sidrane 0399d689ce px4_fmu-v5x:Start MS5611 on Base I2C3 2019-12-03 16:16:49 -05:00
David Sidrane cada41f027 WorkQueueManager:Fix low stack warning introduced by stism330 2019-12-03 16:16:49 -05:00
David Sidrane 31456419e9 px4_fmu-v5x:Add 4096 for ism330dlc to BOARD_DMA_ALLOC_POOL_SIZE
ISM330DLC uses 4096 of memory allocated from DMA pool.
   This depleted the pool to the point the next allocation
   for FAT would fail. Unfortuanly this is the logger
   on a later open.
2019-12-03 16:16:49 -05:00
Daniel Agar 1a395fb6d9 ST ISM330DLC IMU driver 2019-12-03 16:16:49 -05:00
David Sidrane eb560e8a0f fmu-v5x:Properly reset SPI 2019-12-03 16:16:49 -05:00
David Sidrane 14b592d0c6 px4fmuv5x:Add Sync pin to board config 2019-12-03 16:16:49 -05:00
Beat Küng e2a2654628 level calibration: speedup & check for motion
- instead of resetting existing calibration on start and having to wait
  until the estimator converges, keep existing calibration applied and
  subtract it.
- reduce calibration time from 5s to 500ms, and check for motion during
  that time.
- repeat if there was motion
- fix an uorb resource leak
2019-12-03 13:58:38 -05:00
Beat Küng b4eaa6696e refactor accelerometer_calibration: using namespace matrix 2019-12-03 13:58:38 -05:00
RomanBapst 634e8d206a tiltrotor SITL config: increase transition time from 1.5 to 5 seconds
- avoids tilting the motors forward too fast

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-12-03 13:57:58 +03:00
SalimTerryLi 2ec1c53679 Add upload command support for Raspberry Pi build. 2019-12-03 08:03:27 +01:00
Daniel Agar 9b66cbd2d9 Infineon DPS310 Barometer
- used as the primary barometer on the mRo Control Zero F7
2019-12-02 00:51:01 -05:00
Daniel Agar fd72e5e795 mRo ctrl zero updates
- add ICM20602 and ICM20648 data ready interrupts
 - enable Bosch BMI088 IMU
 - move HRT_TIMER to TIM3 (same timer as PPM channel)
2019-12-01 17:43:15 -05:00
Daniel Agar a859a6b57c VSCode SITL debug improvements
- added gazebo VTOL tailsitter debug target
 - improved jmavsim debug target and helper tasks to work properly (build and launch directly instead of through the jmavsim_run.sh script)
 - improved output console handling for helper tasks (eg gazebo and jmavsim build and run, followed by cleanup after debug)
 - added miniterm.py as a task
2019-12-01 15:47:29 -05:00
Daniel Agar 4e7dedede7 bloaty show full demangle, increase number of lines, and combine segments + sections 2019-11-30 23:24:26 -05:00
Daniel Agar 6d8d9ea513 navio_sysfs_rc_in minor initialization cleanup 2019-11-30 22:55:53 -05:00
Daniel Agar 97c6a28a70 replace unnecessary perf_alloc_once usage 2019-11-30 21:17:15 -05:00
Daniel Agar cceec434f2 Revert "linux_pwm_out update orb usage"
This reverts commit 25acd40ef0.
2019-11-30 21:16:49 -05:00
PX4 BuildBot 5e95820e14 Update submodule nuttx to latest Sun Dec 1 00:38:57 UTC 2019
- nuttx in PX4/Firmware (22a005c9f4): https://github.com/PX4/NuttX/commit/2d7920055f96f5734d5166e2c58daa16c6dff2f5
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/398a59aaa4df2b32af2fdc1e3dd566f88d7eea38
    - Changes: https://github.com/PX4/NuttX/compare/2d7920055f96f5734d5166e2c58daa16c6dff2f5...398a59aaa4df2b32af2fdc1e3dd566f88d7eea38

    398a59aaa4 2019-11-29 David Sidrane - [BACKPORT] stm32f7:ethernet: Add some delays so that ifup() does not hog the CPU.
2019-11-30 21:16:33 -05:00
Daniel Agar dc06e644d8 simulator: fix distance_sensor ORB_ID() 2019-11-30 20:17:17 -05:00
Daniel Agar 22a005c9f4 delete module's redundant print_status()
- we can already get the running status from ModuleBase and the other misc information is already available through perf or uORB
2019-11-30 18:22:19 -05:00
PX4 BuildBot db904839c3 Update submodule matrix to latest Sat Nov 30 21:21:29 UTC 2019
- matrix in PX4/Firmware (572fb4751b6e01512ec358b00aa795b234179d85): https://github.com/PX4/Matrix/commit/dba84236cb55cf30a8730f77c71a000babf6d204
    - matrix current upstream: https://github.com/PX4/Matrix/commit/a8009a36a3668da0cbab0cb028b6997cd8179dc1
    - Changes: https://github.com/PX4/Matrix/compare/dba84236cb55cf30a8730f77c71a000babf6d204...a8009a36a3668da0cbab0cb028b6997cd8179dc1

    a8009a3 2019-11-26 Daniel Agar - Quaternion multiply inline return
2019-11-30 17:58:08 -05:00
Daniel Agar 903b6881ac Update submodule mavlink v2.0 to latest Sat Nov 30 21:21:24 UTC 2019
- mavlink v2.0 in PX4/Firmware (faae5feecc): https://github.com/mavlink/c_library_v2/commit/1d680ab4ef56ded58a3f4e4a4433faa71e822873
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/75ab59ddc1660c136fdec5553f622a603558b8cd
    - Changes: https://github.com/mavlink/c_library_v2/compare/1d680ab4ef56ded58a3f4e4a4433faa71e822873...75ab59ddc1660c136fdec5553f622a603558b8cd
2019-11-30 17:55:44 -05:00
Daniel Agar faae5feecc vmount update orb usage 2019-11-30 15:52:53 -05:00
Daniel Agar c04713f4a8 simulator update orb usage 2019-11-30 15:52:53 -05:00
Daniel Agar b418f937a3 sih update orb usage 2019-11-30 15:52:53 -05:00
Daniel Agar c1c9895462 rpi_rc_in update orb usage 2019-11-30 15:52:53 -05:00
Daniel Agar 7306767a9d roboclaw update orb_publish usage to uORB::PublicationMulti<> 2019-11-30 15:52:53 -05:00
Daniel Agar 55a3128c7d qshell update orb usage 2019-11-30 15:52:53 -05:00
Daniel Agar 7759a5dc82 voxlpm update orb usage 2019-11-30 15:52:53 -05:00
Daniel Agar fca029c84a ina226 update orb_publish_auto usage to uORB::PublicationMulti<> 2019-11-30 15:52:53 -05:00
Daniel Agar 92933d988b px4flow update orb_publish usage to uORB::PublicationMulti<> 2019-11-30 15:52:53 -05:00
Daniel Agar 25acd40ef0 linux_pwm_out update orb usage 2019-11-30 15:52:53 -05:00
Daniel Agar 2a6e889b28 irlock update orb_publish usage to uORB::PublicationMulti<> 2019-11-30 15:52:53 -05:00
Daniel Agar 349739b812 gps driver update orb_publish usage to uORB::PublicationMulti<> 2019-11-30 15:52:53 -05:00
Daniel Agar 6f512cc2f1 differential_pressure drivers update orb_publish usage to uORB::PublicationMulti<> 2019-11-30 15:52:53 -05:00
Daniel Agar ec5730bb89 navio_sysfs_rc_in orb_publish usage to uORB::PublicationMulti<> 2019-11-30 15:52:53 -05:00
Daniel Agar 6a539a3836 crazyflie syslink update orb_publish to uORB::PublicationMulti<> 2019-11-30 15:52:53 -05:00
Daniel Agar e951531b12 camera_feedback: move to WQ callback and uORB::Subscription 2019-11-30 15:49:55 -05:00
Daniel Agar 0420a4386d deprecate px4 esc-v1 and drivers/uavcanesc 2019-11-30 14:55:01 -05:00
Daniel Agar 5200cae3a3 deprecate thiemar s2740vc-v1 board support 2019-11-30 14:55:01 -05:00
daniele ffd010b42d add yaw_absolute to mount_orientation 2019-11-30 19:06:30 +01:00
David Sidrane 44c7b90a7b stm32h7:Bootloader fix assertion caused by USB running
USB was still running in transition to Firmware. This
   resets the USB
2019-11-30 19:05:22 +01:00
Daniel Agar 0cc250194d VTOL: explicitly start all FW & MC controllers in VTOL mode 2019-11-30 12:58:36 -05:00
Daniel Agar e50a50876f Jenkins add px4_io-v2 bloaty (flash usage) 2019-11-30 12:16:29 -05:00
Daniel Agar 60f9e9410b Jenkins: compile px4_io-v2_default directly and archive 2019-11-29 22:32:43 -05:00
Beat Küng b973b2ca64 mag calibration: improve 4 and 2 side calibration
- if less than 6 sides are calibrated, keep the existing calibration and
  update the offsets and scales
- if 2 sides are calibrated, estimate the offsets only (as this is enough
  if a full calibration was done already, and the problem is not
  constrained enough to estimate scales and offsets)
2019-11-29 14:14:00 -05:00
Beat Küng 1d78f02733 mag calibration: keep time and number of points per side constant
So it is independent from the number of configured sides.
Previously, each side would take longer if less than 6 sides were
calibrated.

Also fixes a bug: calibration_sides was used before it was updated, leading
to different behavior on consecutive calibrations with <6 sides.
2019-11-29 14:14:00 -05:00
Beat Küng 991a0d3592 fix mag calibration: remove px4_ioctl(fd, MAGIOCCALIBRATE, fd); call
Fixes a serious bug in combination with the HMC5883 driver (also used for
HMC5983): this driver estimates a scale in MAGIOCCALIBRATE and applies it.
The calibration routine does the calibration with that scale applied, and
then overwrites it, without considering it in any way.

Most other mag drivers only do some measurements and perform some checks
in MAGIOCCALIBRATE (but the result is just ignored).
2019-11-29 14:14:00 -05:00
Beat Küng f30e01ec02 calibration: shorten too long messages 2019-11-29 14:14:00 -05:00
Beat Küng 5ff83ef740 gyro calibration: remove unused scale parameters 2019-11-29 11:28:17 -05:00
Beat Küng 4ca5770f36 gyro calibration: slightly stricter motion detection check
From 0.573 deg to 0.4.

And some cleanup.
2019-11-29 11:28:17 -05:00
Beat Küng 1cbcb445ab gyro calibration: speedup from 20s to 1s
It's not required to take that many samples, 1 second is enough.
This is confirmed by looking at the standard deviation over 10 calibrations:
it is in the same order as with 20 seconds (the effect of temperature
increase has a bigger effect).
2019-11-29 11:28:17 -05:00
RomanBapst 133a6e38cc commander: make battery warning state sticky while armed
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-11-29 10:23:08 +03:00
RomanBapst e360dd34f9 battery: make battery states not sticky
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-11-29 10:23:08 +03:00
baumanta 1c30b10585 prevent vmount from publishing mount orientation if smart gimbal is attached 2019-11-29 07:40:16 +01:00
Beat Küng 0f42ecc5c7 durandal-v1: enable dshot 2019-11-29 07:39:08 +01:00
Beat Küng d5b655bad6 dshot: sync with fmu module 2019-11-29 07:39:08 +01:00
Beat Küng cf4e97b71c fmu-v5x: enable DShot
Only the first 6 FMU pins support it.
DMA conflict with UART8, which is the GPS2 port.
2019-11-29 07:39:08 +01:00
Beat Küng 7aa905eb21 fix fmu-v5x: use correct GPS2 serial port 2019-11-29 07:39:08 +01:00
Daniel Agar e1af47f4ca Jenkins ccache don't reset previous statistics (only print) 2019-11-28 18:37:20 -05:00
PX4 BuildBot fda7d71d16 Update submodule matrix to latest Thu Nov 28 12:39:45 UTC 2019
- matrix in PX4/Firmware (f2d08df777): https://github.com/PX4/Matrix/commit/de85dcff9760b77ad0d2cd06682f44b3f3c9716c
    - matrix current upstream: https://github.com/PX4/Matrix/commit/dba84236cb55cf30a8730f77c71a000babf6d204
    - Changes: https://github.com/PX4/Matrix/compare/de85dcff9760b77ad0d2cd06682f44b3f3c9716c...dba84236cb55cf30a8730f77c71a000babf6d204

    dba8423 2019-11-28 Daniel Agar - Vector3f cross product directly return result (#109)
2019-11-28 12:45:52 -05:00
Matthias Grob 633469dd8c FixedWingPositionControl: ommit */ with ///< doxygen comments 2019-11-28 11:21:05 -05:00
Daniel Agar f2d08df777 Update submodule mavlink v2.0 to latest Thu Nov 28 00:39:47 UTC 2019
- mavlink v2.0 in PX4/Firmware (f8c45c4914): https://github.com/mavlink/c_library_v2/commit/3ce744ec3e636b00afbb583b69e7838d1326f703
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/1d680ab4ef56ded58a3f4e4a4433faa71e822873
    - Changes: https://github.com/mavlink/c_library_v2/compare/3ce744ec3e636b00afbb583b69e7838d1326f703...1d680ab4ef56ded58a3f4e4a4433faa71e822873
2019-11-28 00:39:54 -05:00
Daniel Agar 580308ff07 Update submodule matrix to latest Thu Nov 28 00:39:53 UTC 2019
- matrix in PX4/Firmware (1618e9d38fb8f0c76e6b5b7dfc25da565c22bbee): https://github.com/PX4/Matrix/commit/a172c3cdac9260369fb5805fcce19067121566e5
    - matrix current upstream: https://github.com/PX4/Matrix/commit/de85dcff9760b77ad0d2cd06682f44b3f3c9716c
    - Changes: https://github.com/PX4/Matrix/compare/a172c3cdac9260369fb5805fcce19067121566e5...de85dcff9760b77ad0d2cd06682f44b3f3c9716c

    de85dcf 2019-11-26 Matthias Grob - Vector: switch read only functions to const (#108)
2019-11-28 00:37:17 -05:00
mcsauder 0f2ba84f0a Add rangefinder module dependency to tfmini CMakeLists.txt. 2019-11-27 20:52:04 -05:00
Daniel Agar 419787cb93 ulanding: move to UART WQ 2019-11-27 20:44:32 -05:00
Daniel Agar 5c9732f08c tfmini: move to UART WQ 2019-11-27 20:44:32 -05:00
Daniel Agar d22f2fafd9 sf0x: move to UART WQ 2019-11-27 20:44:32 -05:00
Daniel Agar f7ea3fac90 leddar_one: move to UART WQ 2019-11-27 20:44:32 -05:00
Daniel Agar 223bc2df0b cm8jl65: move to UART WQ 2019-11-27 20:44:32 -05:00
Daniel Agar 071f159794 PX4 work queue: extend to UARTs 2019-11-27 20:44:32 -05:00
Daniel Agar f8c45c4914 Jenkins hardware add modalai_fc-v1 and refactor 2019-11-27 16:24:45 -05:00
David Sidrane c93d358145 fmuk66-v3:Add Ethernet Support 2019-11-27 20:29:35 +01:00
Morten Fyhn Amundsen 214e9c8244 ll40ls: Fix rotation argument parse bug
Before (introduced in 7b16c3482d), there was no colon after
the `R` argument in the options specification string (ab:R).

The R should be followed by a colon, because in indicates that
the R option requires an argument, which it does.

So I added a colon.
2019-11-27 11:21:39 -05:00
Julian Oes d27694728b mavlink: remove implicit cast from int to bool
It confused me that we used an int result and casted it into a boolean.

This doesn't change the logic but makes handling the return value explicit.
2019-11-27 10:10:07 -05:00
Julian Oes c5b9ccdc85 mavlink: don't interfere in ongoing transfers
As a convenience we send down the amount of do jumps left to do.
However, we should not send the mission item if happen to be in the
middle of another transfer.
2019-11-27 10:10:07 -05:00
Julian Oes 96fc68ebef mavlink: fix warning on do jump
This fixes the warning:
Mission storage: Unable to read from microSD
which appeared on do jump mission items. The reason was that the
_mission_type can be set to rally or geofence if that was the last
transfer which had happened earlier. Therefore, it would then try to
read a certain rally item from dataman when really a mission item was
supposed to be read.
2019-11-27 10:10:07 -05:00
Daniel Agar b1099379ae mavlink: delete SERVO_OUTPUT_RAW_{2, 3} 2019-11-27 09:30:22 -05:00
Daniel Agar 657138aeb0 mavlink: temporarily disable ACTUATOR_CONTROL_TARGET{1, 2, 3} 2019-11-27 09:30:22 -05:00
bresch 09c8c8f706 ekf: use PDOP instead of GDOP as TDOP (part of GDOP) is not given by the GNSS receiver 2019-11-27 10:33:27 +01:00
bresch 20705e3c53 ekf2_main: simplify "if true else false" with direct boolean assignment 2019-11-27 10:33:27 +01:00
bresch f6a72663fa ekf2_main: extract gps mgs fill 2019-11-27 10:33:27 +01:00
bresch 5d6e0587db ekf_main: fill gps gdop topic with pdop (combination of hdop and vdop) 2019-11-27 10:33:27 +01:00
daniele 07938692d4 fix for issue where flight_uuid in flight_information mavlink message wouldn't update at every disarm because the param update was not notified 2019-11-27 07:48:57 +01:00
Daniel Agar a7fbaefd83 NuttX cmake small debug helper improvements 2019-11-26 15:39:02 -05:00
PX4 BuildBot 30fcb14156 Update submodule gencpp to latest Tue Nov 26 12:38:15 UTC 2019
- gencpp in PX4/Firmware (d5fb89ee02): https://github.com/PX4/gencpp/commit/7e446a9976916a7b6fc7266098c67fc6f73a76e0
    - gencpp current upstream: https://github.com/PX4/gencpp/commit/ff6c9f3e8ee0a63be994e0b7dfc7a36cb0c1d8c7
    - Changes: https://github.com/PX4/gencpp/compare/7e446a9976916a7b6fc7266098c67fc6f73a76e0...ff6c9f3e8ee0a63be994e0b7dfc7a36cb0c1d8c7

    ff6c9f3 2019-11-11 Jochen Sprickerhof - Two patches to make the generated headers reproducible (#42)
e12443e 2019-03-18 Dirk Thomas - 0.6.2
d227d17 2019-03-18 Dirk Thomas - update changelog
e233144 2019-03-15 Martin Pecka - Added plugins the ability to also generate free functions. (#40)
40559af 2019-03-04 Dirk Thomas - 0.6.1
96ec7f1 2019-03-04 Dirk Thomas - update changelog
2019-11-26 09:02:39 -05:00
PX4 BuildBot df0e4bfc62 Update submodule genmsg to latest Tue Nov 26 12:38:20 UTC 2019
- genmsg in PX4/Firmware (4f4e9c36fe3d0ecf547d50de9ca6b274e0f7ab65): https://github.com/PX4/genmsg/commit/5736b1f7ad037fb5811a3100ba9da2db0ec1f20a
    - genmsg current upstream: https://github.com/PX4/genmsg/commit/1ad8e136cd6311c6af12256fc39362334ca23988
    - Changes: https://github.com/PX4/genmsg/compare/5736b1f7ad037fb5811a3100ba9da2db0ec1f20a...1ad8e136cd6311c6af12256fc39362334ca23988

    1ad8e13 2019-08-13 Dirk Thomas - Python 3 compatibility (#86)
ae81617 2019-08-12 AlexV - Rosimport improvements (#83)
f9dad2f 2019-03-04 Dirk Thomas - 0.5.12
0b2c12a 2019-03-04 Dirk Thomas - update changelog
2019-11-26 08:48:18 -05:00
bys1123 d5fb89ee02 Make all boards url link to user guide master branch 2019-11-26 13:19:00 +01:00
斯东Stone 2b9285787e Update Supported Hardware in README.md
1. Move Pixhawk Mini to FMUv3, due to it's using Rev.3 chip, has 2MB flash, and fmuv3 bootloader.
2. Add CUAV V5+ to FMUv5
3. Add CUAV v5 nano
4. Add CUAV Pixhack v3 to FMUv3

Make sure is the hardware URL only on user guide master branch or not
2019-11-26 13:19:00 +01:00
TSC21 806b0ad10d remove microRTPS_client_dummy.cpp as it's not being used 2019-11-26 09:01:52 +01:00
TSC21 c9aab6319f microRTPS: update headers licenses 2019-11-26 09:01:52 +01:00
TSC21 a48c5942a7 remove 'update_time_ms' CLI option as it's not being used anymore 2019-11-26 09:01:52 +01:00
TSC21 54cd8f1856 microRTPS_client.cpp.em: fix double conversions 2019-11-26 09:01:52 +01:00
PX4 BuildBot 4964b633b2 Update submodule sitl_gazebo to latest Tue Nov 26 00:39:55 UTC 2019
- sitl_gazebo in PX4/Firmware (63e99db29b): https://github.com/PX4/sitl_gazebo/commit/2637a94816f5e3cbb9d4a10f831985b2685fc880
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/073da14f6e62d3b3c45e40eda556c0523f86d870
    - Changes: https://github.com/PX4/sitl_gazebo/compare/2637a94816f5e3cbb9d4a10f831985b2685fc880...073da14f6e62d3b3c45e40eda556c0523f86d870

    073da14 2019-11-25 Saifullah - Fix for issue #359. (#362)
2019-11-25 20:30:03 -05:00
bresch 63e99db29b ecl update 2019-11-25 21:15:55 +01:00
bresch 12177cb33b commander: add pre-flight check and parameter for magnetic field strength 2019-11-25 21:15:55 +01:00
Daniel Agar a8ea55d9b6 remove all <cmath> usage
* the NuttX c++ library is incomplete, let's avoid including it until we have a real standard library in place
2019-11-25 10:04:04 -05:00
Matthias Grob 4a28c8180b FlightTaskManualAltitude: yawspeed filter remove line with no effect, comments
FlightTaskManualAltitude: declaration order

Addressing @bkueng's review comments.
2019-11-25 11:55:47 +01:00
bresch cd2b5e7479 FlightTaskManualAltitude: Use dedicated member variable for yawspeed filter state insted of using the previous setpoint 2019-11-25 11:55:47 +01:00
bresch ffee103ae0 FlightTask: add 1st order lpf on yawrate satepoint for smooth motion 2019-11-25 11:55:47 +01:00
TSC21 4c5e5acefe micro-CDR: bump submodule version and update CMake and src code 2019-11-24 19:36:00 -05:00
TSC21 d80da97ef5 micrortps_client: more cleanup 2019-11-24 21:39:01 +00:00
TSC21 ec0803815e microRTPS_client: use updated uORB API; improve usage 2019-11-24 21:39:01 +00:00
Daniel Agar bc182e94e6 sensors split rc_update into new standalone module 2019-11-24 13:25:11 -05:00
Matthias Grob 28755d5bbf att_control: remove resetting the attitude setpoint
since the position controller publishes them again already when disarmed.
2019-11-24 11:06:03 -05:00
Matthias Grob d3bd251ffc mc_pos_control: start flight task already when disarmed
such that the controller always publishes attitude setpoints and there are no initialization issues.
2019-11-24 11:06:03 -05:00
Daniel Agar a69e6b92c9 mpu6000: remove unnecessary CDev 2019-11-23 19:20:44 -05:00
Daniel Agar 76bdeca263 rgbled_pwm: remove unnecessary CDev 2019-11-23 19:20:44 -05:00
Daniel Agar 284c9afe32 px4iofirmware delete unused i2c and hx_stream 2019-11-23 18:58:43 -05:00
Daniel Agar d82f9590c6 vtol_att_control: apply_pwm_limits() don't spam error 2019-11-23 17:23:30 -05:00
Daniel Agar dbed772316 Jenkins hardware select quadcopter airframe for holybro_durandal-v1_stackcheck 2019-11-23 17:23:30 -05:00
Daniel Agar d74cc5ba8c holybro_durandal-v1_stackcheck limit to primary IMU only 2019-11-23 17:23:30 -05:00
Daniel Agar 2811307293 px4_work_queue: increase wq:hp_default stack 1500->1800 bytes (found by stackcheck) 2019-11-23 17:23:30 -05:00
Daniel Agar 92559f7a85 Bosch bmp280 barometer cleanup 2019-11-23 15:31:22 -05:00
Julian Oes cbea76f62a navigator: fix triplet resetting/publication logic (#13534)
The navigator has a notion of resetting the triplets which means the
triplet setpoints are set to invalid and therefore not to be used by
downstream modules such as flight tasks.

However, before this patch, the triplets were not published if invalid
meaning that a valid triplet would stay the truth until a new valid
triplet would get published.

E.g. this lead to the corner case case where we publish a valid triplet
with an IDLE setpoint on ground in HOLD and then don't update the
triplet while flying in POSCTL mode. Later, when RTL is engaged, the
flight task will use IDLE until navigator (which runs slower) has
published the next triplet.

The fix involves two main changes:
- Publish invalid triplets to avoid stale triplets.
- Avoid publishing the triplet on every iteration in manual modes by not
  setting `_pos_sp_triplet_published_invalid_once = false`.

When testing this I realized that a mission upload during RTL would stop
RTL. This is because the mission is updated while the mission navigation
mode is not active and reset_triplets() is called from there. This is
now only done for the case where we are actually in mission navigation
mode. The fact that a mission is updated when not active also seems
wrong and is something to fix another time.
2019-11-23 10:29:41 -05:00
Beat Küng 86eb91fc18 uorb: do not open a node exclusively for an advertiser
Exclusive open is not required, but we now need to ensure the queue size
is set atomically.

It avoids a race condition between 2 single-instance advertisers,
where one of them would fail to open the node with -EBUSY.
2019-11-23 10:10:05 -05:00
Beat Küng 6c8048d057 uorb: fix several race conditions during topic initialization
Possible race conditions (they all happen between the check of existence
of a topic and trying to create the node):
- single instance, with multiple advertisers during the first advertise:
  both advertisers see the topic as non-existent and try to advertise it.
  One of them will fail, leading to an error message.
  This is the cause for telemetry_status advert failure seen in SITL in
  rare cases.
- multi-instance: subscription to non-existing instance -> px4_open fails,
  and the subscriber tries to create the node. If during that time a
  publisher publishes that instance, the subscriber will get (instance+1)
  (or fails if the max number of instances is exceeded).
  This is a race that goes pretty much unnoticed.
- multi-instance: 2 publishers can get the same instance (if is_published()
  is false in case both have not published data yet).
  This can also go unnoticed.
  Therefore the patch changes where _advertised is set: it is now set
  directly during the advertisement instead of during publication.
2019-11-23 10:10:05 -05:00
Beat Küng 63b2befeed refactor uorb: rename published to advertised
No semantic change (yet)
2019-11-23 10:10:05 -05:00
Beat Küng 0f6f795aca uORBDeviceNode: use px4::atomic instead of volatile for _generation
_generation is read in a multi-threaded context w/o locking.
2019-11-23 10:10:05 -05:00
Daniel Agar d648d52ac3 Update submodule GpsDrivers to latest Sat Nov 23 12:39:59 UTC 2019
- GpsDrivers in PX4/Firmware (0913ec7e6df0dfa84203b9a6fed72b1230157d9f): https://github.com/PX4/GpsDrivers/commit/085a85c48aafff6e388f8ce8d15c1371f8556a35
    - GpsDrivers current upstream: https://github.com/PX4/GpsDrivers/commit/781d4f125580d88d24add83b97017e6d771d757f
    - Changes: https://github.com/PX4/GpsDrivers/compare/085a85c48aafff6e388f8ce8d15c1371f8556a35...781d4f125580d88d24add83b97017e6d771d757f

    781d4f1 2019-11-22 Daniel Agar - remove all <cmath> usage
2019-11-23 09:04:20 -05:00
PX4 BuildBot 879e4a5b16 Update submodule sitl_gazebo to latest Sat Nov 23 00:38:19 UTC 2019
- sitl_gazebo in PX4/Firmware (3f92bc26ce): https://github.com/PX4/sitl_gazebo/commit/ec3a32a60441f5238fe91a46ddc2696799450d84
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/2637a94816f5e3cbb9d4a10f831985b2685fc880
    - Changes: https://github.com/PX4/sitl_gazebo/compare/ec3a32a60441f5238fe91a46ddc2696799450d84...2637a94816f5e3cbb9d4a10f831985b2685fc880

    2637a94 2019-11-18 JaeyoungLim - Address comments
94d479c 2019-11-15 Jaeyoung-Lim - Handle camera zoom mavlink message
2019-11-23 10:19:24 +00:00
Silvan Fuhrer 3f92bc26ce airspeed_selector: fix airspeed subscription
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-11-22 18:25:22 -05:00
Daniel Agar 75da6e351b mixer: organize by type 2019-11-22 16:48:10 -05:00
Daniel Agar f271efaf62 local_position_estimator: move to WQ and delete unused SubscriptionPollable 2019-11-22 16:02:54 -05:00
Daniel Agar db69ff0a6e attitude_estimator_q: move to WQ, module base and module params 2019-11-22 16:02:54 -05:00
Daniel Agar c8211dee28 drv_mixer.h - delete unused MIXERIOCGETOUTPUTCOUNT 2019-11-22 15:00:25 -05:00
Daniel Agar a255789be4 mixer: px_generate_mixer use static constexpr 2019-11-22 15:00:25 -05:00
Daniel Agar cc7807c066 mixer: update to List<> container 2019-11-22 15:00:25 -05:00
Daniel Agar 79dc676c8f mixer: move MixerGroup out of Mixer hierarchy and delete mixer.h header 2019-11-22 15:00:25 -05:00
Daniel Agar 011186b8a5 mixer: delete copy constructors and operators 2019-11-22 15:00:25 -05:00
Daniel Agar a172858db2 mixer: move scale() and scale_check() to SimpleMixer 2019-11-22 15:00:25 -05:00
Daniel Agar 9a572b0cf2 mixer: delete unused SimpleMixer::pwm_input() 2019-11-22 15:00:25 -05:00
Daniel Agar 37ec78dc2a mixer library split into separate headers and name consistently 2019-11-22 15:00:25 -05:00
Matthias Grob 6589aa5f71 posix rcS: remove overwriting default altitude 2019-11-22 13:36:05 -05:00
Matthias Grob ccb21e3c4b navigator: remove double member initialization 2019-11-22 13:36:05 -05:00
Matthias Grob 06f667a8b3 vtol_att_control: convert angle in one line 2019-11-22 13:36:05 -05:00
Matthias Grob 9f545ae3cf navigator: convert to radians in configuration getter 2019-11-22 13:36:05 -05:00
Julian Oes 334a599b2d vmount: tell user how to use vmount test
This confused me, so hopefully it will help the next user, e.g. me.
2019-11-22 16:48:17 +01:00
Julian Oes a36a3d6c5c vmount: remove commented out code 2019-11-22 16:48:17 +01:00
Julian Oes 1e8ebe20d1 vmount: set correct MAV_MOUNT_MODE 2019-11-22 16:48:17 +01:00
David Sidrane bbd37ada41 holybro_durandal-v1: update cdcacm product id 2019-11-22 09:39:15 -05:00
TSC21 16f53ec18d msg: add a deprecated uORB msgs list to CMake 2019-11-22 15:00:53 +01:00
David Sidrane 7ca8a8dbaa durandal-v1:Bootloader
Change PID to 0x4b:
     Holybro obtained their own PID and VID but APM did not follow
     the PX4 convention of makeing the board_id (0x8b) match the PID)

   Incorporated the Upstream Bootloader state sequencing checking change.

   Change the usb cout to send all chars in 1 write.
2019-11-22 14:32:56 +01:00
Silvan Fuhrer 5b235c34c2 Rally Points: enable rally points always, except for RTL type == RTL_MISSION
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-11-22 08:18:25 +01:00
Daniel Agar 5aaf1b100b delete unused md25 driver 2019-11-21 18:56:24 -05:00
Daniel Agar 8c38176d77 boards: alphabetize and sync common drivers and modules 2019-11-21 18:56:24 -05:00
Matthias Grob dee8d200d8 mc_pos_control: fix position setpoints being logged as zero when NAN (#13557)
This issue was found by @khabir and reported over slack.
It resulted from the split up of the big pr #12072 into #13262.
I took over the interface while the internal states still stayed the
hard to understand internal ones. One of the follow up refactors will
fix this completely and the entire legacy setpoint restore block can
be removed.
2019-11-21 16:03:13 -05:00
Silvan Fuhrer ebdc29bc5f Airspeed Selector: enable airspeed_validated in control modules (#12887)
* FW attitude controller, FW position controller and VTOL attitude controller subscribe to airspeed_validated topic
* add possibility to switch off the airspeed valid checks
* remove airspeed valid checks from commander
* clean up of VTOL transition logic
* Airspeed Selector: remove dynamic allocation of airspeed validators (depending on number of connected sensors) but do it statically for the maximum number allowed. Check for number of connected sensors not only during start up, but always when vehicle is disarmed.
* Airspeed Selector: change work queue from lp to att_pos_ctrl as this module is safety-critical
* add airspeed selector to px4_fmu-v2 defaults
2019-11-21 14:14:25 -05:00
Julien Lecoeur a46581987c Update matrix submodule and add pseudoinverse tests (tests matrix) 2019-11-21 13:06:59 -05:00
Tanja Baumann 5d3a6d8213 collision_prevention: improve behavior in case of range data loss
* add test for no incoming range data
2019-11-21 11:13:28 -05:00
Daniel Agar 45b32b5eaa dataman: add read and write perf counters 2019-11-21 11:10:35 -05:00
Julien Lecoeur 053ede6ca5 SITL: create a parameter file for each airframe 2019-11-21 15:55:49 +00:00
Julien Lecoeur be99064133 SITL: add SYS_AUTOCONFIG support 2019-11-21 15:55:49 +00:00
Beat Küng 1371887578 board config: add define for adc voltage scaling 2019-11-21 08:19:59 +01:00
Beat Küng b7a7ba8cfc README: update list of supported boards 2019-11-21 08:19:59 +01:00
Beat Küng 4b290c4903 voltage & current scaling: use px4_arch_adc_dn_fullcount() instead of 4096
Fixes the scaling on h7 boards (the ADC has 16 bits resolution).
2019-11-21 08:19:59 +01:00
Matthias Grob b63044393e PositionControl: remove unwanted debug printfs 2019-11-21 00:52:09 +01:00
Daniel Agar 1af7af02db bmp388: cleanup main and add to px4_fmu-v5x board_config.h 2019-11-20 13:12:03 -05:00
Daniel Agar 3f05a7724d navigator: run immediately on vehicle_status updates
- this allows navigator to process any nav_state changes as soon as possible
2019-11-20 12:40:55 -05:00
Jannik Beyerstedt 4ce03dfc1e Add support for offboard ActuatorControl set points to RoverPositionControl (fixes #13192) (#13314)
* fix formatting

* RoverPositionControl: Support Actuator Control Setpoints (fixes #13192)

* RoverPositonControl: remove control modes, that aren't currently implemented

* RoverPositionControl: use new Publication API
2019-11-20 15:01:51 +01:00
TSC21 16f663ad52 microRTPS bridge: fix UART baudrate set 2019-11-20 11:38:34 +00:00
Matthias Grob 1bef35d843 PositionControl: correct float initialization literals
according to @bresch's review
2019-11-20 11:42:09 +01:00
Matthias Grob bd491c8511 PositionControl: add unit tests for directions and limits 2019-11-20 11:42:09 +01:00
Matthias Grob 25a445d5f8 PositionControl: remove parameter dependency
to make the class easier to understand,
more modular and easily unit testable
2019-11-20 11:42:09 +01:00
Daniel Agar 84fe64b1c2 create new multicopter rate controller module (mc_rate_control) split out of mc_att_control 2019-11-19 17:03:11 -05:00
Matthias Grob b64abf48b2 mc_pos_control: reset velocity derivatives 2019-11-19 22:18:01 +01:00
Daniel Agar b213e30597 mpu9250: fully remove dead interval perf counter 2019-11-19 13:43:37 -05:00
Daniel Agar bf2a10496c Update submodule mavlink v2.0 to latest Tue Nov 19 12:39:27 UTC 2019
- mavlink v2.0 in PX4/Firmware (bbc028a9e9): https://github.com/mavlink/c_library_v2/commit/8d10911ec19dd8b9de628eb6c75c224a403aacc5
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/3ce744ec3e636b00afbb583b69e7838d1326f703
    - Changes: https://github.com/mavlink/c_library_v2/compare/8d10911ec19dd8b9de628eb6c75c224a403aacc5...3ce744ec3e636b00afbb583b69e7838d1326f703
2019-11-19 11:17:17 -05:00
Daniel Agar 515e896cde navigator: set position setpoint timestamp 2019-11-19 10:24:52 -05:00
Daniel Agar a2bd65460d commander: add vehicle-status nav_state change timestamp 2019-11-19 10:24:52 -05:00
Daniel Agar 01c7a475ff gitmodules update NuttX to px4_firmware_nuttx-8.2 2019-11-19 07:59:53 -05:00
Jannik Beyerstedt bbc028a9e9 RoverPositionControl: make offboard attitude usable without GPS 2019-11-19 10:05:25 +01:00
Beat Küng a543169f1e CollisionPrevention: avoid unnecessary cast from uint16_t to int 2019-11-19 09:32:30 +01:00
Nik Langrind c34b7019a4 Fix mistake in previoust commit, which could the "hil" argument to
be ignored if px4io were to be started with two or more optional arguments
2019-11-19 08:31:31 +01:00
Daniel Agar 1c4a8e7c11 cmake NuttX fix generated launch.json (vscode debug) 2019-11-18 13:21:33 -05:00
Daniel Agar 82fac4a0a7 cmake NuttX linker print memory usage 2019-11-18 12:36:29 -05:00
David Sidrane 67f27eb26c NuttX @ Offical release of 8.2 2019-11-17 04:06:49 -08:00
Jannik Beyerstedt 38103654e9 RoverPositionContro: Enable driving backwards in attitude control 2019-11-17 11:29:45 +01:00
Claudio Micheli ba99ef0d3b Commander: Add COM_ARM_AUTH_REQ for enabling Arm Authorization
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-11-17 11:22:36 +01:00
Nik Langrind ba5efa5642 px4io: When running HITL, don't publish actuator_outputs. Fixes #13471.
When running in HITL mode, pwm_out_sim publishes actuator_outputs.

px4io unconditionally publishes the uOrb actuator_outputs. When HITL
is configured, the px4io copy of the uOrb has all zeros.

The result is that there are two publications, one valid, and one
all-zeros. This causes the HIL_ACTUATOR_CONTROLS mavlink message
to be incorrect (all-zeros) and the SERVO_OUTPUTS_RAW mavlink
message to be inconsistent, as it takes the data from one or the
other uOrb randomly each cycle.

The fix is to let px4io know that HITL is in effect when it is
started, and modify px4io to suppress publication in this case.

This is a bigger more complicated fix than I would like, but I
think it is conceptually correct.

Signed-off-by: Nik Langrind <langrind@gmail.com>
2019-11-17 11:19:35 +01:00
Daniel Agar 8ce2f30aa6 NuttX cmake improve dependencies between configure and runtime
- attempting to make the build slightly more robust to incomplete configures or other bad states.
2019-11-16 18:30:52 -05:00
Daniel Agar ea79bd733d cmake add a few include guards
- this is a minor cmake configure time optimization
2019-11-16 16:27:36 -05:00
Daniel Agar df73a6667d NuttX cmake improvements
- fix temporary Make.defs copy
 - implement custom macros for COMPILE, COMPILEXX, ASSEMBLE, ARCHIVE to enable ccache properly (if available and enabled)
 - fix NuttX mkdeps
 - fix libapps race condition with context
2019-11-16 15:42:19 -05:00
Daniel Agar b5e7e4bc17 add holybro_durandal_stackcheck build and run on Jenkins 2019-11-16 11:43:42 +01:00
Daniel Agar caca3e93e7 Jenkins hardware add holybro_durandal-v1 2019-11-16 11:43:42 +01:00
Daniel Agar a694f0bbdd bl_update: build and include board bootloader if config available 2019-11-16 11:43:42 +01:00
David Sidrane 850821f47f [REVISIT] Support upstream DSHOT Revist!
The Addition of PX4_ARCH_DCACHE_LINESIZE is fundamentally wrong.
   It asserst that an STM32F4 has a cache and it does not.
   This should be #if defined() on CONFIG_ARMV7M_DCACHE
2019-11-16 11:43:42 +01:00
Daniel Agar 2bb7a1f3c7 holybro_durandal-v1 delete extra defconfig copy 2019-11-16 11:43:42 +01:00
Daniel Agar 2af262ed1d NuttX cmake build wrapper thorough dependencies 2019-11-16 11:43:42 +01:00
Daniel Agar 99aae8b891 NuttX use toolchain math.h and avoid empty drivers/Kconfig 2019-11-16 11:43:42 +01:00
David Sidrane a8e7ddd44e durandal-v1:Use Holybro USB PID 2019-11-16 11:43:42 +01:00
David Sidrane b2f28c977d durandal-v1 Nuttx Based PX4 bootloader
durandal bootloader:Run at 480 Mhz

durandal-v1:bootloader use VBUS detection

Add Durandal bootloader to build
2019-11-16 11:43:42 +01:00
David Sidrane 4836fc0719 Added board support for holybro_durandal-v1
Durandal:Fix PLL settings

durandal-v1:Move I2C123, I2C4 to HSI.

   Not liking using HSI but, F7 has, and in reality there is no
  requerment for accuracy.

durandal-v1:board config set 400kHz on card probe

durandal-v1:Board SDMMC Clock Not greater then 25 mHz

durandal-v1:Fix PLL3 configuration typo and value

CI build config for holybro_durandal-v1

durandal-v1:Kconfig - add knob to ensure ARCH_MATH_H is kept

   Upstream changes added ARCH_HAVE_MATH_H to protect from archs
   without math.h from causing isses for users setting
   CONFIG_ARCH_MATH_H and getting errors. PX4 provides a math.h
   and we need CONFIG_ARCH_MATH_H set. So this Selects
   ARCH_HAVE_MATH_H perserving CONFIG_ARCH_MATH_H a defconfig

Track master LED removal

durandal-v1: bmi055 -> bmi088

bmi088 is what the board uses

durandal-v1:add PX4IO support

durandal-v1 rc.board_sensors: start baro

durandal-v1: remove segway module

durandal:Run at 480 Mhz

durandal-v1: build thermal control module

durandal-v1: enable IMU thermal control by default

durandal-v1:Track upstream adc start moved to rc.board_sensors

durandal-v1:Track upstream mavlink start moved to rc.board_mavlink
2019-11-16 11:43:42 +01:00
David Sidrane 15f25a4e02 fmuk66-v3:Remove MMC support - NuttX detection is broken 2019-11-16 11:43:42 +01:00
David Sidrane 5c0aada220 fmuk66-v3:Remove CONFIG_EXAMPLES_MOUNT 2019-11-16 11:43:42 +01:00
David Sidrane 65a26ec060 nxp_fmuk66-v1:Port to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 2faa2c5e19 uvify:core BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 5bb272387a thiemar:s2740vc-v1 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 148215c114 px4:io-v2 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 26b9b0371f px4:fmu-v5x BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 7e979676ee px4_fmuv5_stackcheck:Remove bl_update to fit 2019-11-16 11:43:42 +01:00
David Sidrane 0ebe285201 px4:fmu-v5 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 7ce4f06470 px4:fmu-v4pro BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 40a3e47712 px4:fmu-v4 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 2c13883e56 px4:fmu-v3 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 47bbb36575 px4_fmuv2_multicopter:Remove bl_update to fit 2019-11-16 11:43:42 +01:00
David Sidrane ab1c8850fe px4:fmu-v2 BSP Updated to NuttX 8.1+
px4/fmu-v2 disable events and work_queue systemcmd
2019-11-16 11:43:42 +01:00
David Sidrane 208c23c826 px4:esc-v1 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 25a6a45640 px4:cannode-v1 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 8b33d1fcda omnibus:f4sd BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane d534349dfe nxp:fmuk66-v3 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 9032b64eaa mro:ctrl-zero-f7 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 4d021fcd42 modalai:fc-v1 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane f5fefee57f intel:aerofc-v1 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane ca45b1ee12 holybro:kakutef7 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane f62c6442a4 bitcraze:crazyflie BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 8bc8ea0ea2 av:x-v1 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 724f66399a auav:x21 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 12a70402ad airmind:mindpx-v2 BSP Updated to NuttX 8.1+ 2019-11-16 11:43:42 +01:00
David Sidrane 4ebc00b22e kakutef7:Remove Duplicate goio header 2019-11-16 11:43:42 +01:00
David Sidrane fa79283602 px4/fmu-v4: update nuttx config 2019-11-16 11:43:42 +01:00
Mohammed Kabir 00d00fdca9 drivers: heater: fix module build and startup
- Startup was broken due to unnecessary cyclic check probably introduced during transition to work_queues
- Module never used other than on Teal One which had a hacky heater input GPIO, this enables usage on general boards

drivers: heater: reduce verbosity and simplify commandline options

- We prefer the linux way of only reporting errors and staying quiet when everything is functioning as designed
- Most of the commandline options just read out the values of the system parameters, and one can just check the parameter values directly.

sensor_params: make thermal control parameters system parameters

heater_params: make thermal control parameters system parameters

drivers: heater: remove pin control hacks

- px4_arch_configgpio(GPIO_HEATER_OUTPUT) directly inits the heater pin to OFF, and as a PUSHPULL (TTL totem pole) OUTPUT

drivers: heater: set default device ID to 0
2019-11-16 11:43:42 +01:00
David Sidrane 69694ab000 px4io-v2:Resonable Def config memory - verified by inspection 2019-11-16 11:43:42 +01:00
Beat Küng d965b928f8 px4iofirmware: convert atomic macro into methods
Reduces flash size by 744 bytes.
CPU (loop time) is not affected.
2019-11-16 11:43:42 +01:00
David Sidrane 0f2a7ad2b7 bl_update:STM32H7 use AIXRAM 2019-11-16 11:43:42 +01:00
David Sidrane 645b6c3fbc bl_update:STM32H7 use 128K 2019-11-16 11:43:42 +01:00
David Sidrane e847698c9f PX4 System changes Supporting STM32H7
stm32:ToneAlarmInterfacePWM TIM15-TIM17 have a BDTR Register

common:board_crashdump Add H7 support

stm32/board_mcu_version:Support H7

PX4 ADC:Use 32 interface and resoution abstraction

Added PX4 stm32h7 ADC driver

stm32h7:adc fix ADC ready check

fmu: handle BOARD_HAS_PWM==5

cmake: improve error handling for NuttX olddefconfig failures

WorkQueueManager:Quiet loadmon stack warning

camera_trigger:GPIO support < 6 GPIO

Adjust stack sizes (under hw stack check)

PX4 System changes Supporting STM32H7 PX4IO Driver

aerotenna_ocpoc:ADC add px4_arch_adc_dn_fullcount

init.cmake:Track Upstream change needing Make.def at config time

PX4 System changes Supporting STM32H7

NuttX CMakeLists.txt Track upstream changes

Common board_crashdump add header and px4 config

NuttX simplify callinb make libapps

Use UINT32_MAX for error return

drivers:uavcannode NuttX chip is now hardware

drivers:uavcanesc NuttX chip is now hardware

px4io:Avoid Race on AP to PX4 IO upgrade
2019-11-16 11:43:42 +01:00
Beat Küng 58799dc7d1 px4/fmu-v5: update nuttx config
px4_fmuv5:Needed PROGMEM

fmu-v5:Kconfig - add knob to ensure ARCH_MATH_H is kept

    Upstream changes added ARCH_HAVE_MATH_H to protect from archs
    without math.h from causing isses for users setting
    CONFIG_ARCH_MATH_H and getting errors. PX4 provides a math.h
    and we need CONFIG_ARCH_MATH_H set. So this Selects
    ARCH_HAVE_MATH_H perserving CONFIG_ARCH_MATH_H a defconfig
2019-11-16 11:43:42 +01:00
Beat Küng 694ae56afe px4/io-v2: update nuttx config
px4_io - add knob to ensure ARCH_MATH_H is kept

   Upstream changes added ARCH_HAVE_MATH_H to protect from archs
   without math.h from causing isses for users setting
   CONFIG_ARCH_MATH_H and getting errors. PX4 provides a math.h
   and we need CONFIG_ARCH_MATH_H set. So this Selects
   ARCH_HAVE_MATH_H perserving CONFIG_ARCH_MATH_H a defconfig
2019-11-16 11:43:42 +01:00
David Sidrane 36a75b79a4 uavcan:Changes to support Nuttx 7.31+
libuavcan:Update with Kinetis NuttX 8.1+ support

Traking master uavcan changes
2019-11-16 11:43:42 +01:00
David Sidrane 522ed2d99b NuttX based PX4 bootloader
stm32h7 booloader:Obey VBUS input

stm32h7 booloader:Fully deinit systic
2019-11-16 11:43:42 +01:00
Beat Küng 78944a70c3 Upgrade NuttX to 8.2
Nuttx with PX4 contrib of bbsram fix

Nuttx 8.31+ with BBSRAM disable dcache

Nuttx 8.2-
2019-11-16 11:43:42 +01:00
David Sidrane 11287712f8 fmuk66-v3:Fix hang on SDIO card removal/reinsertion
The interrupt driven card detect logic was enabled
   but the auto mounter was not. That interrupt was
   calling mmcsd_mediachange.

   There is a reentrancy issues in the kinetis callback logic.
   Toplevel calls mmcsd_mediachange calls SDIO_CALLBACKENABLE
   that calls kinetis_callbackenable that calls kinetis_callback
   that calls mmcsd_mediachange.
2019-11-15 11:13:38 -05:00
Daniel Agar 11b1573961 mpu9250: cleanup main 2019-11-15 10:18:41 -05:00
BazookaJoe1900 cc41e5be20 mavlink: stream battery status fields (#13420)
* Implement battery status "charge state" on mavlink battery status message
2019-11-15 09:25:30 -05:00
Daniel Agar 452657face hmc5883: build on linux and qurt 2019-11-14 21:02:52 -05:00
Claudio Micheli 9364393e9d mavlink_receiver: Reject own autopilot messages for battery status.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-11-14 22:20:22 +01:00
PX4 BuildBot 6369ae858a Update submodule matrix to latest Wed Nov 13 22:07:30 UTC 2019
- matrix in PX4/Firmware (d3184c866c3012105c8950a9f6652a9722fa3296): https://github.com/PX4/Matrix/commit/93d42947b612733d2bd05e66ae093ada3e35ba12
    - matrix current upstream: https://github.com/PX4/Matrix/commit/cd185c995b6b28c12e06d20a2743a94bd68be7c2
    - Changes: https://github.com/PX4/Matrix/compare/93d42947b612733d2bd05e66ae093ada3e35ba12...cd185c995b6b28c12e06d20a2743a94bd68be7c2

    cd185c9 2019-11-13 Daniel Agar - add braces around statements and cleanup formatting (#107)
38e966c 2019-11-12 kritz - Add min, max, constrain function for Matrix (#105)
2019-11-13 19:07:24 -05:00
Daniel Agar 99a7491cde bmp280: build on linux and qurt 2019-11-13 15:16:24 -05:00
TSC21 d4ddabdf52 SITL: adds 'iris_rtps' target 2019-11-13 18:24:11 +00:00
Daniel Agar bcfa2eecd8 ms5611: build on linux (navio2) 2019-11-13 13:01:00 -05:00
Daniel Agar 7996ee496c lib: name folders consistently 2019-11-13 09:29:21 -05:00
Daniel Agar c5520cbaca mpu9250: start building "NuttX" driver for Linux and QuRT 2019-11-13 09:21:02 -05:00
JaeyoungLim 6bd4273b9c mavlink: handle cellular_status messages for logging 2019-11-13 09:19:02 -05:00
Matthias Grob 675af4f5f9 uavcan_kinetis: fix flexcan code style
* flexcan: fix code style
* flexcan: exclude from style check to avoid that a different version of astyle breaks indentation again
2019-11-12 20:50:54 -05:00
Daniel Agar 52554f1efa px4_fmu-v4pro: cleanup SPI devs 2019-11-12 11:18:57 -05:00
Daniel Agar 9183f44243 px4_fmu-v4: deprecate boscch pixracer variant and cleanup SPI devs 2019-11-12 11:18:57 -05:00
Julian Oes 00a7ac013c ak09916: fix mag spikes
This fixes spuriously occuring mag spikes in the external mag of Here2.

The reason for the spikes was that the fact that the I2C registers were
not read out correctly as suggested in the datasheet.

Before we were reading out ST1, data, and ST2 in one pass and ignoring
the data ready bit (DRDY) in ST1. This meant that we could run into race
conditions where the data was not ready when we started reading and
being updated as the registers are read.

Instead, we need to check the read the ST1 register first to check the
data ready bit and then read the data and ST2 if the data is ready. By
reading ST2 we then trigger the next measurement in the chip.
2019-11-12 10:04:35 -05:00
Julian Oes 035e81e084 ak09916: cleanup only
Note: the author name was removed because this file has almost no
resemblence with the code written by that author 4 years ago, has been
copied to new places, and was initially commited without author anyway.

Also, my opinion is that the version control system should take care of
attribution, and not outdated comments.
2019-11-12 10:04:35 -05:00
Oleg Kalachev 942cdb1fa5 Add COEX Clover 4 airframe 2019-11-11 22:45:52 -05:00
Oleg Kalachev 17a84a691f mavlink_receiver: simplify and fix statustext.severity handling 2019-11-11 17:12:37 -05:00
Daniel Agar 668984b6b0 boards: start adc in rc.board_sensors 2019-11-11 17:08:24 -05:00
bazooka joe f06a6ba898 set TC_ as 'system' parameters 2019-11-11 15:13:01 -05:00
Daniel Agar 1c4e854f93 cmake don't build param "c" files and remove param defines
- these aren't actual source code
2019-11-11 10:25:42 -05:00
xdwgood f984c4e450 ROMS: delete caipirinha_vtol.main.mix and instead use vtol_tailsitter_duo.main.mix 2019-11-11 10:40:20 +01:00
Pandacoolcool ec0244906f fix yaw control error 2019-11-11 10:40:20 +01:00
Pandacoolcool 5c7da88265 remove unuse param 2019-11-11 10:40:20 +01:00
PX4 BuildBot 4dfe3e199e Update submodule matrix to latest Sat Nov 9 00:39:54 UTC 2019
- matrix in PX4/Firmware (c475bb84b7274d041065fc3fd673127ae2438f4d): https://github.com/PX4/Matrix/commit/9f464839510a2779b9418ffbc2303a31f155e851
    - matrix current upstream: https://github.com/PX4/Matrix/commit/93d42947b612733d2bd05e66ae093ada3e35ba12
    - Changes: https://github.com/PX4/Matrix/compare/9f464839510a2779b9418ffbc2303a31f155e851...93d42947b612733d2bd05e66ae093ada3e35ba12

    93d4294 2019-11-08 kritz - Add test for setting Quaternion to Identity (#104)
2019-11-09 00:51:44 -05:00
Peter van der Perk 991399f105 Added syncronization to t_send worker thread
Which avoids possible deadlocks
2019-11-08 18:58:38 +01:00
PX4 BuildBot f0d22d3962 Update submodule sitl_gazebo to latest Fri Nov 8 12:40:23 UTC 2019
- sitl_gazebo in PX4/Firmware (0527f278cb): https://github.com/PX4/sitl_gazebo/commit/169d48217df89922e9fae72ef34fa46ce2e209dd
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/036bcee25f178cef9350107b4283f05e334adc1b
    - Changes: https://github.com/PX4/sitl_gazebo/compare/169d48217df89922e9fae72ef34fa46ce2e209dd...036bcee25f178cef9350107b4283f05e334adc1b

    036bcee 2019-11-06 Jaeyoung-Lim - Add element to set home position from sdf
2019-11-08 11:50:46 -05:00
Daniel Agar fa5a825401 Update submodule mavlink v2.0 to latest Fri Nov 8 12:40:28 UTC 2019
- mavlink v2.0 in PX4/Firmware (b7469f0f6d50a32bc57bbfe6ce0a7101ea5dbad2): https://github.com/mavlink/c_library_v2/commit/7c0ec61677d378320c2ee33a2e8db842d6fb4bc2
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/8d10911ec19dd8b9de628eb6c75c224a403aacc5
    - Changes: https://github.com/mavlink/c_library_v2/compare/7c0ec61677d378320c2ee33a2e8db842d6fb4bc2...8d10911ec19dd8b9de628eb6c75c224a403aacc5
2019-11-08 10:22:34 -05:00
Daniel Agar 1fc85da4b0 Update submodule GPSDrivers to latest Fri Nov 8 12:40:32 UTC 2019
- GPSDrivers in PX4/Firmware (085bdd14b41ac3977d612a1cae27f111de7fe4fb): https://github.com/PX4/GpsDrivers/commit/011959b4dabc6edbc1b22f5e0fa42a62d137e993
    - GPSDrivers current upstream: https://github.com/PX4/GpsDrivers/commit/085a85c48aafff6e388f8ce8d15c1371f8556a35
    - Changes: https://github.com/PX4/GpsDrivers/compare/011959b4dabc6edbc1b22f5e0fa42a62d137e993...085a85c48aafff6e388f8ce8d15c1371f8556a35

    085a85c 2019-10-15 Andreas Antener - sbf: invalidating gps position when invalid data is received We have encountered a case where do-not-use values were being reported in velocity fields without a corresponding error code or fix-type 0. This adds a check for known invalid data and sets the appropriate flags.
2019-11-08 09:43:53 -05:00
Beat Küng 073298bc8e batt_smbus: fix incorrect CLI description 2019-11-08 13:52:23 +01:00
LP 0527f278cb Update create.py to support Python3.x
file() -> open()
dict_obj_A.keys() + dict_obj_B.keys() -> list(dict_obj_A.keys()) + list(dict_obj_B.keys())
2019-11-08 10:10:17 +01:00
Jacob Dahl b943bd72ab commander: Added a parameter to control the timeout period for disarming after the kill switch is engaged. (#13325) 2019-11-07 10:03:59 -05:00
Daniel Agar 1896c758d0 [SQUASH ME] trivial style fix 2019-11-07 15:57:29 +01:00
Mike Wiatt 3595941554 Reposition landing gear check so that it is not overwritten by setpoint operations. 2019-11-07 15:57:29 +01:00
Daniel Agar 7fe257c0c0 Jenkins SITL tests always upload to logs.px4.io 2019-11-07 08:55:51 -05:00
Tanja Baumann b60a955501 ColPrev: No direction change if no obstacle (#13398)
* only change direction if in other bin
2019-11-07 14:21:12 +01:00
Beat Küng a5af1c8afc batt_smbus: add missing PRINT_MODULE_USAGE_DEFAULT_COMMANDS() 2019-11-07 10:56:27 +01:00
Beat Küng f94236dcc9 batt_smbus: fix getopt arguments (-A does not have an argument) 2019-11-07 10:56:27 +01:00
Beat Küng ce1ae3fcb7 batt_smbus: exit/continue correctly when no device is on the bus 2019-11-07 10:56:27 +01:00
Beat Küng 72e62a62cb batt_smbus: make bus_options const and rename to smbus_bus_options
as it is a global name.
2019-11-07 10:56:27 +01:00
Beat Küng adad11f247 batt_smbus: remove unused defines 2019-11-07 10:56:27 +01:00
Beat Küng b487920cf4 fix batt_smbus: add bound checks when accessing argv 2019-11-07 10:56:27 +01:00
Beat Küng 60f55a4fa1 fix batt_smbus: check if module running for custom_command 2019-11-07 10:56:27 +01:00
Beat Küng f63b55b219 fix batt_smbus: do not block the work queue while suspended 2019-11-07 10:56:27 +01:00
Beat Küng 3f3304fefc batt_smbus: variable init cleanup + remove unused declarations 2019-11-07 10:56:27 +01:00
Beat Küng 32359168d6 smbus: fix invalid memory access in read_word()
read_word() expected 3 bytes (uint16_t + PEC byte), but was passed an
address to an uint16_t value.

write_word() is changed to be type-safe as well.
2019-11-07 10:56:27 +01:00
Beat Küng e772ddf012 motor_test: remove note about supported drivers
This is now supported by all main output drivers.
2019-11-07 10:40:03 +01:00
Beat Küng 6622f04feb uavcan drivers: update code style
Pure refactoring, just running 'make format'.
2019-11-07 10:40:03 +01:00
Beat Küng 6049a95073 uavcan drivers: remove unused code for other OSs/bare metal 2019-11-07 10:40:03 +01:00
Beat Küng 5dff065ec5 uavcan: move to work queue and use MixingOutput
Main UAVCAN protocol handling and ESC updates run on the same thread/wq as
before. There are 2 WorkItems for separate scheduling of the 2, so that
ESC updates run in sync with actuator_control updates. UAVCAN is scheduled
at a fixed rate of 3ms (previously the poll timeout) and on each UAVCAN
bus event.
This leads to roughly the same behavior as before. CPU & RAM usage are
pretty much the same (tested on Pixhawk 4).

Testing done: Motors still work (with feedback), param changes and a
UAVCAN optical flow sensor.
2019-11-07 10:40:03 +01:00
Beat Küng b7a480b45b refactor uavcan: add stm32 and kinetis drivers directly 2019-11-07 10:40:03 +01:00
Beat Küng 6854b14dd6 esc_report: remove unused fields to reduce message size
esc_setpoint in UAVCAN was just wrong, this is what it really is:
uint7 power_rating_pct      # Instant demand factor in percent
(percent of maximum power); range 0% to 127%.
2019-11-07 10:40:03 +01:00
Beat Küng 0db0981b1b uavcan: remove actuator_direct (no publisher) 2019-11-07 10:40:03 +01:00
Daniel Agar 06f20ad892 sensors: ensure angular velocity publication on selected sensor update 2019-11-07 09:53:44 +01:00
Julian Oes 60343cc168 mavlink: warning for actuator offboard & lockstep
Currently actuator offboard control interferes with SITL lockstep.
Therefore, the least we can do is to warn a user and inform them how to
workaround the issue.
2019-11-06 12:30:30 -05:00
Daniel Agar 02271a471d vscode extensions update cmake-tools (now from microsoft) 2019-11-05 21:13:36 -05:00
JaeyoungLim b999581d2f Rover: Handle velocity frames correctly for offboard velocity control 2019-11-05 16:29:04 -05:00
Daniel Agar d263811eef Jenkins move raspi and bebop builds to regular armhf toolchain 2019-11-05 15:56:24 -05:00
Daniel Agar 5ec74af421 ADIS IMU drivers cleanup and standardize main 2019-11-05 11:58:43 -05:00
Matthias Grob 1a79f75f94 Commander: start pulling arming related parts into separate folder
* PreFlightCheck: remove unused reportFailures flag
* Commander: pull all pre flight checks together on the PreFlightCheck class
* PreFlightCheck: separate checks into their own files
2019-11-05 11:25:59 -05:00
Peter van der Perk 08a27492b4 Introduced condition variable in ROS2 subscriber to solve 500ms latency spikes 2019-11-05 15:09:44 +00:00
Julian Oes ef475fa9d8 mixer_module: fix poll error in SITL lockstep
This fixes the case where the mixer_module would subscribe and use its
own test_motor publication which was created only to make sure the
topic is advertised and subsequent updates will work properly.

This happened in SITL lockstep because the timestamp would be 0 at the
very beginning, and hence elapsed time would be 0 as well.
This lead to an actuator publication which would then get lockstep out
of sync causing poll errors on the Gazebo side.
2019-11-05 09:33:14 -05:00
Matthias Grob b6de83117e PositionControl: fix attitude setpoint timestamp
The plot of the attitude setpoint in the log did not show any values
because the message timestamp that the position control module sets
was overwritten by the PositionControl attitude generation.
2019-11-05 13:05:16 +01:00
Matthias Grob c6cc9f0902 mc_pos_control: fix cutting thrust when landed
by applying it directly to the attitude setpoint which is the output of
the position controller.

The problem was that before the input to the attitude setpoint generation
was adjusted to generate a level attitude with zero thrust keeping the
heading. I refactored the PositionControl class in #13262 to directly
generate the attitude setpoint output. So here I'm adjusting the attitude
setpoint to do the exact same thing as before but without interleaving
with the PositionControl logic.
2019-11-05 13:05:16 +01:00
Beat Küng a203475489 BlockingList: fix unsafe getLockGuard() API
getLockGuard relies on copy elision to work correctly, which the compiler
is not required to do (only with C++17).
If no copy elision happens, the mutex ends up being unlocked twice, and the
CS is executed with the mutex unlocked.

The patch also ensures that the same pattern cannot be used again.
2019-11-05 12:14:20 +01:00
Julian Oes 4ff4f5c77f commander: fix capitalization of mavlink messages 2019-11-05 10:40:30 +01:00
Julian Oes 24c58db9e6 commander: fix battery failsafe without GPS
This fixes the battery failsafe for the following corner cases:
- Battery failsafe set to Return but we can't do RTL because we don't
  have a global position or home position. In this case we now switch to
  Land. Land might end up in Descend in the failsafe state machine
  later.
- Battery failsafe set to Land but we can't land because we don't have a
  local position. In this case we switch to land anyway and then fall
  back to descend in the failsafe state machine later.

The "fix" involves ignoring using the main_state_transition and
implementing the guards in place. This is a hack for now but should
cover the corner case until a more thorough refactor.

The different failsafe state machines have involved over time from
requirements and learnings based on developed solutions and products.
The implementations in various places will need to get consolidated in
the future.

Tested in SITL for Return and Land with and without GPS.
2019-11-05 10:40:30 +01:00
PX4 BuildBot 6e395fe885 Update submodule matrix to latest Tue Nov 5 00:38:36 UTC 2019
- matrix in PX4/Firmware (dca3f78e198f89510890fbb8b305d2fa1c3caa69): https://github.com/PX4/Matrix/commit/92d1c8761ec8e5dbe9ba3f756cebd5e90956a1b2
    - matrix current upstream: https://github.com/PX4/Matrix/commit/9f464839510a2779b9418ffbc2303a31f155e851
    - Changes: https://github.com/PX4/Matrix/compare/92d1c8761ec8e5dbe9ba3f756cebd5e90956a1b2...9f464839510a2779b9418ffbc2303a31f155e851

    9f46483 2019-11-04 Julian Kent - Fix GCC-4.8 bug
445f58d 2019-11-01 Julian Kent - Fix weird C preprocessor conflicts (#101)
215203f 2019-10-23 Julian Kent - Automatic Differentiation 'Dual' Type (#100)
2019-11-04 20:05:43 -05:00
Oleg Kalachev 7b83da708a mavlink_receiver: write STATUSTEXT messages from the same system to log 2019-11-04 15:33:22 -05:00
Matthias Grob 2416d0fc63 mc_pos_control: remove unused function declarations 2019-11-04 15:07:06 -05:00
Daniel Agar 7f930f875e Jenkins store SITL unit test results 2019-11-04 14:04:40 -05:00
Julian Kent b8b7527d05 Fix off-track tracking in AutoLineSmoothVel (#13321)
* Use position instead of last setpoint

This calculates the target velocities better taking into account disturbances along
the flight route. Previously entry angles and more were calculated assuming the flight path
originates directly from the direction of the previous waypoint. This corrects this assumption
to instead make the direction come from the vehicle location.

* Allow to specify a final speed given a braking distance.

This is to allow planning to not stop at a waypoint, but instead
to reach the waypoint while maintaining a certain velocity

* Updated src/lib/matrix

* Account for speed at target when determining constraints

* Separate constraints into x/y components

* Use setpoint position, not vehicle position

* Fix whitespace, add documentation
2019-11-04 11:57:12 +01:00
Daniel Agar 07825faeff Update submodule mavlink v2.0 to latest Mon Nov 4 00:39:49 UTC 2019 (#13340)
- mavlink v2.0 in PX4/Firmware (64daa96d11): https://github.com/mavlink/c_library_v2/commit/086f176b677b719c1f5b4267a10553ffc5c3a974
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/7c0ec61677d378320c2ee33a2e8db842d6fb4bc2
    - Changes: https://github.com/mavlink/c_library_v2/compare/086f176b677b719c1f5b4267a10553ffc5c3a974...7c0ec61677d378320c2ee33a2e8db842d6fb4bc2
2019-11-03 20:27:19 -05:00
Daniel Agar 64daa96d11 Jenkins hardware move to nested stages 2019-11-03 16:31:43 -05:00
Jacob Dahl 005f530eed Removed lidar lite reset after intialization 2019-11-03 20:07:27 +01:00
Daniel Agar 40850f58ee boards cleanup old nsh_archinitialize 2019-11-03 12:09:48 -05:00
Daniel Agar ee003370c4 UVify Core board sync with px4/fmu-v4
* A few minor changes to keep the UVify Core board in sync with fmu-v4. This will be important when transitioning to the new IMU drivers using SPI DMA (#13103).
2019-11-03 11:51:54 -05:00
Daniel Agar 69bec3ee62 defines.h delete obsolete PRIu64, PRId64, and offsetof 2019-11-03 11:50:15 -05:00
Daniel Agar 7bf9700426 NuttX: math.h drop extra math defines carried in PX4 defines.h 2019-11-03 10:30:00 -05:00
Jaeyoung-Lim 1951e416b1 Enable rover attitude setpoint 2019-11-03 09:54:22 -05:00
FlavioTonelli 7984c0c910 px4_work_queue: stack size rounded to page size on posix 2019-11-03 09:04:04 -05:00
Julian Oes a08abccdd5 mpu9250: fix mag spikes on fmu-v4pro
This should fix spikes in the mag data on MPU9250 found inside Drotek
Pixhawk 3Pro.

The problem turned out to be that we are not checking the DRDY bit
before reading the data. We presumably threw away most of the stale data
by doing a duplicate check, however, sometimes we might have run into a
race where the mag data was already being updated in the chip while
still being read.
2019-11-02 12:49:30 -04:00
Daniel Agar 3e189889ef FlightTasks: shift DEFINE_PARAMETERS to end of access modifiers
- DEFINE_PARAMETERS includes a private access modifier, so we need to
keep these at the end to prevent issues when extending a flight task
2019-11-02 12:41:45 -04:00
CAI Dongcai c804dea914 sitl script: Do NOT kill px4 if debug in IDE 2019-11-02 12:40:36 -04:00
Daniel Agar 7a82df3872 UVify Core and Draco-R updates
* Draco-R sensor orientation correction
* LL40LS sensor is not stable during I2C probing. More trials have been implemented.
* px4flow execution has been removed as rc script already running it
* GPS LED script repaired
* Off ICM20608 due to some bug?
* Removed i2c speed adjustment due to SMBUS.
* ms5611 test2 does not exist
* Baud rate has changed.
* Draco-R airframe parameters are updated.
* IFO and Draco parameters are updated
* Draco-R sensor orientation corrected
* Draco-R DSHOT supports
2019-11-02 11:39:41 -04:00
Daniel Agar a475d71ca9 astyle shift module documentation to bottom of files
- Astyle chokes on the module description strings, so for now we can keep them near the bottom of each file.
2019-11-02 10:58:47 -04:00
PX4 BuildBot f0ac270174 Update submodule ecl to latest Sat Nov 2 13:49:23 UTC 2019
- ecl in PX4/Firmware (4658aaf8a0ff90662843558dbc8ea68adcc7284d): https://github.com/PX4/ecl/commit/9b4b24ee71902c6a4289170e8fb1ca3306c1d9c4
    - ecl current upstream: https://github.com/PX4/ecl/commit/d76b7042251b6f4f230a34dd38818f7af1bb991d
    - Changes: https://github.com/PX4/ecl/compare/9b4b24ee71902c6a4289170e8fb1ca3306c1d9c4...d76b7042251b6f4f230a34dd38818f7af1bb991d

    d76b704 2019-11-01 kamilritz - Only inlcude gtest if standalone build
7c1e38d 2019-10-18 kamilritz - Make it build with Firmware
d79199c 2019-10-17 kamilritz - Remove swig and python test related things
d88e242 2019-10-17 kamilritz - pytest are replaced in gtests
71be26e 2019-10-17 kamilritz - Port RingBuffer Test to GTests
cac5f3f 2019-10-17 kamilritz - GTest and Coverage cleanup and Basic EKF GTest
fcea13e 2019-10-14 Martina Rivizzigno - add gtest, temp disable swig
2019-11-02 10:48:45 -04:00
Matthias Grob cc06009932 pre-commit: fix indentation style 2019-11-02 09:49:46 -04:00
Matthias Grob 5c0692e59e pre-commit: add error messages for style issues 2019-11-02 09:49:46 -04:00
Matthias Grob 933ff8d480 Remove duplicate EOF trailing newlines
because they can screw up git when merging branches.
2019-11-02 09:49:46 -04:00
Julian Oes 5491f9b8f9 px_uploader.py: increase estimated erase time
The 9 seconds to erase a board probably still come from the FMU-v1 and
Pixhawks with only 1 MB flash. By now, many targets have 2 MB flash and
take a bit longer to erase. Therefore, we can increase the estimated
time a bit and don't need to resort to the timeout notice.
2019-11-02 09:47:54 -04:00
Travis Bottalico d657a4ee83 modalai-fc-v1- rotate default orientation 180° yaw 2019-11-02 11:37:30 +00:00
katzfey ff9744b0d3 Fixed typo for extra_args when HEADLESS mode chosen. 2019-11-02 11:35:53 +00:00
Julian Oes 87415d36a2 commander: check center throttle for POSCTL/ALTCTL
When flying POSCTL and ALTCTL the throttle stick is usually spring
loaded and therefore centered. Therefore, it makes more sense to check
for above center instead of above low.
2019-11-01 10:36:30 +01:00
Julian Oes 283a57054a commander: add missing manual modes
We prevent arming when in a "manual" mode with throttle high. However,
POSCTL and ALTCTL were missing.
2019-11-01 10:36:30 +01:00
Julian Oes 300bc0a332 commander: fully support MAVLink force arming
When a magic number is added as param2 for the MAVLink ARM_DISARM
command not just disarming but also arming should be enforced.
2019-11-01 10:36:30 +01:00
Julian Oes 51ba80f33b commander: improve msg when trying to arm in air 2019-11-01 10:36:30 +01:00
CUAVcaijie 77a896a0dd UAVCAN: Fixed CAN battery status
* Set battery.voltage_filtered_v and battery.current_filtered_a value
* Fixed battery.remaining error when full_charge_capacity_wh is zero
2019-10-31 22:35:04 -04:00
Daniel Agar e39e73cea1 delete auav esc35-v1 board 2019-10-31 22:34:05 -04:00
Daniel Agar 129299e25d Update submodule GPSDrivers to latest Fri Nov 1 00:38:09 UTC 2019 (#13338)
- GPSDrivers in PX4/Firmware (939b83ad492abe795f5eb9f0c4e4387aaee193a5): https://github.com/PX4/GpsDrivers/commit/69e38ecc846df03f0bb71aa136bcc830dd3316a9
    - GPSDrivers current upstream: https://github.com/PX4/GpsDrivers/commit/011959b4dabc6edbc1b22f5e0fa42a62d137e993
    - Changes: https://github.com/PX4/GpsDrivers/compare/69e38ecc846df03f0bb71aa136bcc830dd3316a9...011959b4dabc6edbc1b22f5e0fa42a62d137e993

    011959b 2019-10-27 Daniel Agar - clang-tidy: fix hicpp-member-init
2019-10-31 21:29:27 -04:00
PX4 BuildBot 6647a9a762 Update submodule jMAVSim to latest Thu Oct 31 12:39:44 UTC 2019
- jMAVSim in PX4/Firmware (a6a8877463): https://github.com/PX4/jMAVSim/commit/3bd51e67e022ce59644d33ebdf6570c2ea88ddb6
    - jMAVSim current upstream: https://github.com/PX4/jMAVSim/commit/eeb23ef68e0491332d3169deaa42c4babc0395b7
    - Changes: https://github.com/PX4/jMAVSim/compare/3bd51e67e022ce59644d33ebdf6570c2ea88ddb6...eeb23ef68e0491332d3169deaa42c4babc0395b7

    eeb23ef 2019-10-30 bresch - magnetometer: update inclination/declination/local mag field strength of default starting locations. Set magnetometer scale factor to 1 (instead of 2) Set local mag field using DEFAULT_MAG_FIELD instead of an estimated one using inclination/declination and a norm of 1
2019-10-31 14:53:45 -04:00
flbernier 79a814199c Add rm3100 start for fmu-v5x 2019-10-31 12:09:44 -04:00
flbernier 568a349d60 Add rm3100 start for fmu-v5 2019-10-31 12:09:44 -04:00
flbernier 6f5f9a787e Add rm3100 start for fmu-v4 2019-10-31 12:09:44 -04:00
flbernier 7a356e1e91 Add rm3100 start for fmu-v3 2019-10-31 12:09:44 -04:00
David Sidrane a3e2777208 NuttX/nuttx with SDIO fixes (#13311)
* NuttX/nuttx with SDIO fixes
2019-10-31 16:55:16 +01:00
xdwgood 854220dccd mc_pos_control.cpp:Fix forced update parameters 2019-10-31 10:15:25 -04:00
Julian Oes a6a8877463 simulator: don't reset battery when disarmed
Before this change, the battery percentage is reset to 100% as soon as
the drone is disarmed again. In my opinion it is more realistic if the
batteries don't magically fill up again but stay low.
2019-10-30 15:45:44 -04:00
Jacob Dahl 66b3a4269b updated maintainer on 4250_teal 2019-10-30 15:31:04 +00:00
Beat Küng 1dd6b6a505 stm32f3: add libs and stubs for F3 build (thiemar_s2740vc-v1) 2019-10-30 11:48:47 +01:00
Beat Küng 3b7c1b4ff1 src/drivers/boards: move to platforms/nuttx/src/px4/common 2019-10-30 11:48:47 +01:00
Beat Küng be7ed5e388 src/drivers/boards/common/{stm32,kinetis}: move under platforms/nuttx/src/px4 2019-10-30 11:48:47 +01:00
Beat Küng 58e161347b board_mcu_version: move to platforms/nuttx/src/px4 2019-10-30 11:48:47 +01:00
Beat Küng e7519c9fa0 board_identity: move to platforms/nuttx/src
And fix a potential alignment issue in board_get_mfguid and
board_get_px4_guid.
2019-10-30 11:48:47 +01:00
Beat Küng b30171ba8d board_common.h: move under platforms/common
Also move board_determine_hw_info and board_gpio_init under platforms/nuttx
2019-10-30 11:48:47 +01:00
Beat Küng dc601f15f1 includes: remove unused global include directories 2019-10-30 11:48:47 +01:00
Beat Küng 3198610f85 src/platforms: move all headers to platforms/common/include/px4_platform_common
and remove the px4_ prefix, except for px4_config.h.

command to update includes:
for k in app.h atomic.h cli.h console_buffer.h defines.h getopt.h i2c.h init.h log.h micro_hal.h module.h module_params.h param.h param_macros.h posix.h sem.h sem.hpp shmem.h shutdown.h tasks.h time.h workqueue.h; do for i in $(grep -rl 'include <px4_'$k src platforms boards); do sed -i 's/#include <px4_'$k'/#include <px4_platform_common\/'$k/ $i; done; done
for in $(grep -rl 'include <px4_config.h' src platforms boards); do sed -i 's/#include <px4_config.h/#include <px4_platform_common\/px4_config.h'/ $i; done

Transitional headers for submodules are added (px4_{defines,log,time}.h)
2019-10-30 11:48:47 +01:00
Julian Oes fad0c31872 commander: battery failsafe action back to warning
This reverts a previous change because we're not entirely sure about all
implications on various airframes. It makes sense to change this default
after the failsafe state machines have been consolidated and the various
failsafe behaviours are more predictable for all airframes (not just
multicopter).
2019-10-29 15:42:43 +01:00
Hamish Willee 24e3dc6a76 RTL Params - relative to destination not home 2019-10-29 15:00:49 +01:00
Peter van der Perk 07eb3d301b Enabled UDP in NuttX microRTPS build
Added commandline argument to change microRTPS ip address
2019-10-29 09:08:21 +00:00
Daniel Agar 375fc4a75c uavcan module cleanup
- move most orb to uORB::Publication and uORB::Subscription
 - update legacy message handling (warn to PX4_INFO, PX4_WARN, PX4_ERR)
 - add perf counters
 - sensors/mag support newer `uavcan::equipment::ahrs::MagneticFieldStrength2` message
 - sensors/gps support `uavcan::equipment::gnss::Auxiliary` for hdop and vdop
 - sensors delete obsolete ioctl and read methods
 - use PublicationMulti for actuator_outputs and esc_reports (to coexist with other output modules)
 - add GNSS parameter metadata (parameters_injected.xml)
2019-10-28 19:57:50 -04:00
Daniel Agar 47dd312b57 fw_att_control: move to px4::params 2019-10-28 18:08:47 -04:00
JaeyoungLim 71fbe58e20 fw_pos_ctrl_l1: enable loiter type offboard position setpoint for Fixedwing vehicles
* Use NAV_LOITER_RAD when provided offboard position setpoints
2019-10-28 17:42:27 -04:00
RomanBapst 216556e7f6 commander_params: mention definition of battery states in the description
of the battery failsafe mode parameter

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-10-28 16:18:42 -04:00
Daniel Agar 94de12ef19 sensors: own BAT_V_DIV and BAT_A_PER_V params (#13299)
- this is currently necessary for the QGC power setup gui, but should be reverted in the future
 - fixes #13292
2019-10-28 16:03:05 -04:00
Julian Oes cb03612d99 mavlink: only ignore messages on UDP before init
We should still accept messages arriving over serial.
2019-10-28 11:13:16 -04:00
Julian Oes 08cce4f7f3 mavlink: accept msgs without source initialized
I don't understand why we should wait to parse incoming MAVLink traffic
just because we don't have the source address initialized. We still
check the source address before doing a sendto.

This should fix serial MAVLink communication on FMU5x where both serial
and UDP is available. There the serial connection previously did not
work because nothing was connected over UDP.
2019-10-28 11:13:16 -04:00
Daniel Agar c284198bec clang-tidy: partially fix hicpp-use-override 2019-10-28 10:50:31 -04:00
Daniel Agar bfd44afef8 clang-tidy: enable readability-braces-around-statements 2019-10-28 10:50:31 -04:00
Daniel Agar 6f1e132286 clang-tidy: enable readability-redundant-control-flow and fix 2019-10-28 10:50:31 -04:00
Daniel Agar 6f1f5e0325 clang-tidy: partially fix readability-redundant-declaration 2019-10-28 10:50:31 -04:00
Daniel Agar 68d20b56cf clang-tidy: enable readability-redundant-member-init 2019-10-28 10:50:31 -04:00
Daniel Agar 9f4258f6ff clang-tidy: partially fix hicpp-explicit-conversions 2019-10-28 10:50:31 -04:00
Daniel Agar a7f330075a clang-tidy: enable hicpp-braces-around-statements and fix 2019-10-28 10:50:31 -04:00
Daniel Agar 744f06cc8f clang-tidy: enable readability-delete-null-pointer and fix 2019-10-28 10:50:31 -04:00
Daniel Agar 4192414576 clang-tidy: partially fix cppcoreguidelines-pro-type-reinterpret-cast 2019-10-28 10:50:31 -04:00
Julian Oes f5945d1185 commander: make battery failsafes sane by default
I propose two changes to the battery failsafes:
1. Remove the return only mode because it means the drone is likely
   to crash during RTL. I think this is not expected by users chosing
   the option and therefore better not exposed as an option.
2. Make Return/Land the default battery failsafe because it is expected
   that a drone does the right thing when battery is low.

Also, this changes the description of the Return/Land behaviour to make
the drop down menu less long and awkward in QGC.
2019-10-28 05:51:12 -07:00
Beat Küng 0734fe047e fmu-v2 fixedwing: add CONSTRAINED_FLASH to the config 2019-10-28 09:54:59 +01:00
Silvan Fuhrer 0ce9329803 Safe Landing Points: Added new RTL_TYPE: closest between home, mission landing and safe points
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>

Co-authored by Martina Rivizzigno <martina@rivizzigno.it>
2019-10-28 09:54:59 +01:00
Silvan Fuhrer efafd91095 Rally Points in RTL: fly to closest Rally Point (safe point), or to home if that's closer
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-10-28 09:54:59 +01:00
Silvan Fuhrer 99dd229d71 Rally Point: fix typo of save to safe in mission_safe_point_s
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-10-28 09:54:59 +01:00
Julien Lecoeur 8f910f8435 ATTITUDE_QUATERNION: fill repr_offset_q for tailsitters (#13249)
* Conversions lib: add quaternion getter

* vehicle_status: add flag is_vtol_tailsitter

* ATTITUDE_QUATERNION: fill repr_offset_q for tailsitters
2019-10-28 09:27:53 +01:00
Daniel Agar 380cae18d1 clang-tidy: partially fix modernize-use-equals-default 2019-10-27 19:19:07 -04:00
Daniel Agar 967446af4c clang-tidy: enable readability-simplify-boolean-expr and fix 2019-10-27 19:19:07 -04:00
Daniel Agar 279df3b1b8 clang-tidy: partially fix hicpp-use-equals-delete 2019-10-27 19:19:07 -04:00
Daniel Agar d545825bf0 clang-tidy: enable performance-unnecessary-value-param and fix 2019-10-27 19:19:07 -04:00
Daniel Agar 4a7a9a1ba9 Makefile: clang-tidy use unmodified run-clang-tidy 2019-10-27 19:19:07 -04:00
Daniel Agar ae27dd60a6 Jenkins re-enable clang-tidy and update .clang-tidy
- device/Device: fix explicit constructor and uninitialized fields
 - systemcmds/motor_test: update NULL to nullptr
2019-10-27 17:19:11 -04:00
Daniel Agar 7b94c501cd Jenkins discard artifacts sooner 2019-10-27 12:52:28 -04:00
Daniel Agar e2cf501f9d boards: increase CONFIG_MAX_TASKS 32->64 on all F7s (#13285)
On more complicated setups it's still possible to exceed 32 tasks. For example fmu-v5 with mavlink on every telem (+ USB), external spi usage (pmw3901), gimbal (vmount), multiple i2c sensors, and camera feedback is 35 tasks (with top running). This is a fairly extreme case, so I'm only going to increase CONFIG_MAX_TASKS on newer F7 boards.
2019-10-27 12:37:01 -04:00
Daniel Agar 17b654f165 Update submodule ecl to latest Sun Oct 27 12:38:03 UTC 2019 (#13175)
- ecl in PX4/Firmware (dcfe226638): https://github.com/PX4/ecl/commit/f005e0ea8f33d10dd014a0700e712426540bb58a
    - ecl current upstream: https://github.com/PX4/ecl/commit/9b4b24ee71902c6a4289170e8fb1ca3306c1d9c4
    - Changes: https://github.com/PX4/ecl/compare/f005e0ea8f33d10dd014a0700e712426540bb58a...9b4b24ee71902c6a4289170e8fb1ca3306c1d9c4

9b4b24e 2019-10-17 RomanBapst - removed unused definition
0e3a0b8 2019-10-15 RomanBapst - range_finder_checks: parametrised signal quality hysteresis duration
16d1e15 2019-10-15 RomanBapst - addressed review comments
6bc6f26 2019-10-14 RomanBapst - range_finder_checks: set range height to valid if signal quality is non-zero
6299d81 2019-10-14 RomanBapst - ekf_helper: use latest validated range sample to reset height
00f49e6 2019-10-14 RomanBapst - cleanup checks of range finder data
4d37065 2019-08-22 Paul Riseborough - EKF: Make use of inverse rotation function consistent with name
36de2b3 2019-08-22 Paul Riseborough - EKF: Use matrix library for quaternion to rotation matrix conversion
1a4ab06 2019-10-22 bresch - rate controller: add override specifiers whenever needed
29f71ff 2019-10-21 bresch - ekf: Add override specifier for all functions that override virtual functions of the estimator interface class
50167bf 2019-10-16 bresch - estimator interface: add deprecated functions for backward compatibility
b38458c 2019-10-10 bresch - Terrain estimator: formatting and remove redundant comments
0aef0ed 2019-10-10 bresch - terrain_estimator: remove dead code. Since the terrain estimator is constantly reset on ground, it is not necessary anymore to fuse fake measurements on ground if the range measurements are bad.
370e04e 2019-10-03 bresch - terrain_est: Continuously reset terrain height on ground using known clearance. This is the best estimate as we should not rely on a distance sensor while on the ground. This also helps when the drone is carried over as it avoids starting with a crazy downward distance for optical flow scaling.
e09e3e1 2019-10-14 bresch - control: rename _range_aid_enabled to _is_range_aid_suitable rename rangeAidConditionsMet to checkRangeAidSuitability
fac69d0 2019-10-14 bresch - control: refactor rangeAidConditionsMet function
eae6e8f 2019-08-06 Paul Riseborough - EKF: Fix on ground yaw drift when using EKF2_MAG_TYPE = 4
4e946d5 2019-09-04 RomanBapst - implemented synthesized magnetometer Z measurement - calculate a theoretical value based on the knowledge of the direction and strength of the magnetic field vector and X/Y sensor measurements - needs knowledge about location on earth to work
2019-10-27 11:24:26 -04:00
Jaeyoung-Lim dcfe226638 Add onboard computer status rtps message 2019-10-27 11:47:10 +00:00
Jaeyoung-Lim 1b7d04d835 Add units on message comments 2019-10-27 11:47:10 +00:00
Jaeyoung-Lim 2ab692b8dc Document types 2019-10-27 11:47:10 +00:00
JaeyoungLim b7ebbabfd6 Update msg/onboard_computer_status.msg
Co-Authored-By: Beat Küng <beat-kueng@gmx.net>
2019-10-27 11:47:10 +00:00
Jaeyoung-Lim 29987a4f80 Address comments 2019-10-27 11:47:10 +00:00
Jaeyoung-Lim 3dc3679f9e Copy fields 2019-10-27 11:47:10 +00:00
Jaeyoung-Lim 58d646e33d Log CPU loads 2019-10-27 11:47:10 +00:00
Jaeyoung-Lim 677c0b4713 Add uorb topic 2019-10-27 11:47:10 +00:00
Jaeyoung-Lim a3bd9ead4c Add message handlers for onboard computer status 2019-10-27 11:47:10 +00:00
Ildar Sadykov 0326a8ec76 mavlink_receiver: Fit in 'flash' region 2019-10-26 18:29:16 +01:00
Ildar Sadykov b29a6b8761 set_attitude_target: get vehicle_status every time. 2019-10-26 18:29:16 +01:00
Ildar Sadykov fc59414a25 set_attitude_target: set rate thrust according to VTOL mode 2019-10-26 18:29:16 +01:00
Ildar Sadykov 948d24c1e3 Apply suggestions from code review
Co-Authored-By: Julien Lecoeur <jlecoeur@users.noreply.github.com>
2019-10-26 18:29:16 +01:00
Ildar Sadykov 65ed068bbd mavlink_receiver: vtol_vehicle_status changed to vehicle_status subscription 2019-10-26 18:29:16 +01:00
Ildar Sadykov d2f0100e5e Removed _is_vtol in MavlinkReceiver class 2019-10-26 18:29:16 +01:00
Ildar Sadykov c8edac0a1d VTOL state check for attitude setpoint publish 2019-10-26 18:29:16 +01:00
Ildar Sadykov 35b0778499 Check system type for SET_ATTITUDE_TARGET attitude publising
Check if system type is VTOL and publish attitude to proper uORB topic
2019-10-26 18:29:16 +01:00
Julien Lecoeur 8bf60662fa fmu-v2: set CONSTRAINED_FLASH on all targets 2019-10-26 15:19:07 +01:00
bresch bdc546b2e0 AutoLineSmoothVel: fix constrain priority for autocontinue.
The constrainAbs function was not prioritizing the minimum value
that produces the autocontinue behaviour. This caused zig-zag
paths when the waypoints were almost -but not exactly- aligned.
2019-10-26 08:34:30 +02:00
Matthias Grob be545db44f mc_pos_control: reuse timestamp to reduce hrt calls 2019-10-26 06:11:18 +02:00
Matthias Grob d0084766ff PositionControl: make getters const functions 2019-10-26 06:11:18 +02:00
Matthias Grob f70d4d21a1 PositionControl: add getter for output attitude setpoint 2019-10-26 06:11:18 +02:00
Matthias Grob 198605d258 PositionControl: add getter for output position setpoint 2019-10-26 06:11:18 +02:00
PX4 BuildBot 9e309f62a9 Update submodule sitl_gazebo to latest Fri Oct 25 12:40:00 UTC 2019
- sitl_gazebo in PX4/Firmware (ffefd458be): https://github.com/PX4/sitl_gazebo/commit/c0634b241eb730cee2ef91e5f5298427a4a328c8
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/169d48217df89922e9fae72ef34fa46ce2e209dd
    - Changes: https://github.com/PX4/sitl_gazebo/compare/c0634b241eb730cee2ef91e5f5298427a4a328c8...169d48217df89922e9fae72ef34fa46ce2e209dd

    169d482 2019-10-22 Julian Oes - travis: let's not bother about macOS Sierra
78fef51 2019-10-22 Julian Oes - travis: install gstreamer using brew
764d1b7 2019-10-21 Julian Oes - models: fix reported validation errors
053622b 2019-10-11 TSC21 - Travis CI: Cleanup scripts and add more MacOSX build pipelines
0c8214c 2019-10-21 Julian Oes - cmake: fix Qt prefix path for macOS
bb2c08c 2019-10-06 TSC21 - CMake: fix Qt5 find in MacOS
81f072b 2019-10-14 Julian Oes - travis: install GStreamer using brew
39d4399 2019-10-14 Julian Oes - cmake: link to glib-2.0 and gobject-2.0
fef3ff5 2019-10-14 Julian Oes - cmake: fix GStreamer and Qt deps for macOS
605da22 2019-10-22 Nuno Marques - Update README.md
2a8a54e 2019-10-20 Nuno Marques - README: update install instructions
2019-10-25 15:29:41 +01:00
Jacob Crabill ffefd458be UAVCAN: Optical Flow: Bug fix (missing integration_timespan field in optical_flow topic). (#13257) 2019-10-25 13:21:03 +02:00
JaeyoungLim 4c8f27cf57 Fix typhoon h480 parameter (#13263) 2019-10-25 10:46:27 +02:00
Igor Mišić f4ee9141cb DShot: updated driver to use NuttX DMA functions (#13233) 2019-10-25 09:49:03 +02:00
Dusan Zivkovic 7ebaf9a1cb mission: ensure precland::on_inactivation() is called once landed 2019-10-25 09:28:09 +02:00
Hamish Willee 6295a55a87 Mavlink Submodule update 2019-10-24 19:02:34 -07:00
Hamish Willee 564b29c0f8 Fix incorrect default for parser 2019-10-24 19:00:17 -07:00
Hamish Willee a904f78fad Parameter parser/markdown includes boolean flag 2019-10-24 19:00:17 -07:00
bresch 788b8c86a2 InnovationLpf: initialize state to zero 2019-10-24 18:33:55 +02:00
Matthias Grob 40edd33078 mc_pos_control: reduce scope of attitude setpoint
No need for a gloabl state since it gets produced freshly
by the controller and then published.
2019-10-24 14:58:57 +02:00
Matthias Grob 79334958a9 WeatherVane: only update with last row of rotation matrix 2019-10-24 14:58:57 +02:00
Matthias Grob 9c25b987bc vehicle_local_position_setpoint: make acceleration and jerk arrays 2019-10-24 14:58:57 +02:00
TSC21 0062390c46 Jenkins CI: Colcon build on ROS2 Dashing workspace 2019-10-24 11:23:24 +01:00
TSC21 45c320ba8e bump container tags to 2019-10-24 2019-10-24 11:23:24 +01:00
TSC21 5b018ebc83 Jenkins CI: Tests: bump px4-dev-ros-melodic tag to 2019-10-23 2019-10-24 11:23:24 +01:00
TSC21 6fbc8afd50 Jenkins CI: move SITL tests to Melodic container 2019-10-24 11:23:24 +01:00
bresch a7727769e9 ekf2: Fix heading not stable issue. The prblem was that a large
dt could drive the alpha filter crazy because of the small dt
approximation during the computation of the coefficient.
- Remove unused bitmask packing of the innovation checks
2019-10-24 11:27:35 +02:00
JaeyoungLim 2fc5789d68 Support offboard velocity setpoints for rover (#13225)
* Enable velocity control for rover

* Address comments

* Use pid for speed control

* Calculate steering commands correctly

* Use local velocity estimates to avoid global position dependency
2019-10-24 10:40:20 +02:00
Beat Küng b5ba1665f6 commander: add COM_MOT_TEST_EN parameter to enable/disable motor testing 2019-10-24 09:27:29 +02:00
Beat Küng 02833c6075 px4io: add support for test_motor
And fix some IO bugs:
- PX4IO_P_STATUS_FLAGS_RAW_PWM was never cleared. This meant that after a
  'pwm test' command, normal mixing was not possible anymore.
  Fixed by remembering when we are in test mode and not sending
  PX4IO_PAGE_CONTROLS during that time. PX4IO_P_STATUS_FLAGS_RAW_PWM is
  cleared when PX4IO_PAGE_CONTROLS are received.
- when entering test mode w/o specifying all channels, the other channels
  were not set at all, which means they could still be set to values from
  a previous test call.
  This is fixed by setting all channels to disarmed when entering/leaving
  test mode.
2019-10-24 09:27:29 +02:00
Beat Küng 0d91d4e702 commander: do not beep on successful commands
DO_MOTOR_TEST is sent continuously, which led to constant beeping
2019-10-24 09:27:29 +02:00
Beat Küng f7b04d5cbc commander: answer to VEHICLE_CMD_DO_ORBIT 2019-10-24 09:27:29 +02:00
Beat Küng bc09a872fa mixer_module: do not enter test mode if kill switch is engaged 2019-10-24 09:27:29 +02:00
Beat Küng 285ae608a5 commander: add support for DO_MOTOR_TEST
- add an optional timeout to test_motor
- enforce a timeout when receiving DO_MOTOR_TEST
- limitation: DO_MOTOR_TEST can only control the MAIN outputs
2019-10-24 09:27:29 +02:00
Beat Küng eb6a9bd488 px4io: add missing lock()/unlock() in ioctl 2019-10-24 09:27:29 +02:00
Matthias Grob f317d227ef arch.sh: get rid of ignition-cmake workaround
The AUR repository got fixed upstream after
I reported the issue. I tested on a fresh machine
so we can get rid of the workaround that was necessary. See
https://aur.archlinux.org/packages/ignition-cmake/#comment-712301
2019-10-24 08:50:18 +02:00
Travis Bottalico 1d44231cd4 modalai fc-v1: add dshot support 2019-10-24 02:06:28 -04:00
Travis Bottalico 367e756c81 Fix a missed refactor of board name in vscode file 2019-10-24 02:06:28 -04:00
mcsauder 7389bf1759 Add rangefinder dependency to the CM8JL65 driver CMakeList and organize #includes. 2019-10-24 01:50:49 -04:00
Jaeyoung-Lim f7871ec9de Retune h480 2019-10-23 16:55:30 +01:00
RomanBapst 06a902f598 rcS: do not wipe next flight UUID parameter when resetting parameters
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-10-23 16:54:17 +01:00
Matthias Grob 38651ceee1 mc_pos_control: address @bresch's review comments 2019-10-23 17:33:47 +02:00
Matthias Grob d60e1e2774 ControlMath: switch to gtest for unit tessting 2019-10-23 17:33:47 +02:00
Matthias Grob ad60f6d786 PositionControl: make it self contained library 2019-10-23 17:33:47 +02:00
Mathieu Bresciani 549fb0d5de ekf2_main - Add optical flow innovation pre-flight check (#13036)
* ekf2: Add FirstOrderLpf and InnovationLpf classes for innovation lowpass filtering

* ekf2: use InnovLpf filter class in preflight checks

* ekf2: move selection of yaw test limit for pre-flight check in function

* ekf2: Move pre-flight checks into separate function

* ekf2: use static constexpr insetead of inline for sq (square) function

* ekf2: Split pre-flight checks in separate functions
Also use the same check for all the innovations:
innov_lpf < test and innov < 2xtest

* ekf2: Add optical flow pre-flight check

* ekf2: Combine FirstOrderLpf and InnovationLpf in single class

* ekf2: check vel_pos_innov when ev_pos is active as well

* ekf2: transform InnovationLpf into a header only library and pass the
spike limit during the update call to avoid storing it here

* ekf2: Static and const cleanup
- set spike_lim constants as static constexpr, set innovation
- set checker helper functions as static
- rename the mix of heading and yaw as heading to avoid confusion

* ekf2: use ternary operator in selectHeadingTestLimit instead of if-else

* ekf2: store intermediate redults in const bool flags. Those will be used for logging

* ekf2: set variable const whenever possible

* ekf2: create PreFlightChecker class that handle all the innovation
pre-flight checks.
Add simple unit testing
Use bitmask instead of general flag to have more granularity

* PreFlightChecker: use setter for the innovations to check instead of sending booleans in the update function
This makes it more scalable as more checks will be added

* ekf: Use booleans instead of bitmask for ekf preflt checks
Rename "down" to "vert"
2019-10-22 16:22:42 +02:00
Daniel Agar 644c816a2a generate_listener.py don't use message length 2019-10-22 09:19:18 +02:00
Daniel Agar 35398e05ca perf counter cleanup (mostly intervals)
Some of these perf counters were useful during initial development, but realistically aren't needed anymore, some are redundant when we can now see the average interval from `work_queue status` and some of them simply aren't worth the cost at higher rates.
2019-10-21 18:54:17 -04:00
Daniel Agar f7e62349b3 px4_posix: increase posix stack overhead (mostly for ASan)
- sync address sanitizer SITL tests
2019-10-21 16:56:09 -04:00
Daniel Agar 6a0f5249f8 sensors: split out analog battery handling to new standalone battery_status module 2019-10-21 13:40:23 -04:00
Beat Küng f956bafa4e MixingOutput: remove safety button check
The assumption is that the system can only ever get into armed state if
the safety button is already off.
2019-10-21 09:42:08 +02:00
Beat Küng 529da7b33e MIXERIOCLOADBUF ioctl: remove unnecessary string length restriction
mixer.cpp ensures the string is null-terminated (buffer length is 2048).
2019-10-21 09:42:08 +02:00
Beat Küng a8f6622831 OutputModuleInterface::updateOutputs return bool to control actuator_outputs pub
Required for pwm_out_sim: only publish actuator_outputs when we get
actuator_controls. Otherwise lockstep startup does not work.
The issue was there before but hidden, due to a long poll timeout.

Works with HIL too.
2019-10-21 09:42:08 +02:00
Beat Küng 380247168d mixer_module: avoid using an enum as px4::atomic argument
Does not compile on MacOS.
2019-10-21 09:42:08 +02:00
Beat Küng 0871802568 mixer_module: add support for test_motor (motor_test CLI command) 2019-10-21 09:42:08 +02:00
Beat Küng 349469cf75 refactor pwm_out_sim: use mixer_module and run on work queue
Tested with SITL + HITL
2019-10-21 09:42:08 +02:00
Beat Küng 2837152983 refactor mixer_module: move some code in update() into separate methods 2019-10-21 09:42:08 +02:00
Beat Küng 72a8be538a mixer_module: more robust logic to set 'stop_motors' flag
Checking the first output_limited for a disarmed value is fragile.
For example a disarmed value might be within the range of min/max output
values and could then be triggered while armed.
2019-10-21 09:42:08 +02:00
Hamish Willee 177da1f923 RTL params - proposed updates 2019-10-21 09:08:27 +03:00
RomanBapst 4cc7bb7296 addressed review comments
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-10-21 09:08:27 +03:00
RomanBapst b1a9d4b4c7 updated rtl parameter descriptions.
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-10-21 09:08:27 +03:00
TSC21 2930b55732 microRTPS: templates: only decode ros2_distro when possible and nedeed 2019-10-20 16:08:32 +01:00
Daniel Agar 981f8d5d90 systemcmds/tests: IntrusiveQueue and List fix memory leaks 2019-10-20 10:46:44 -04:00
Daniel Agar 687a3a15c5 top: decrease priority below IMU sensor WQ threads
- otherwise top can potentially disrupt with sensor sampling
2019-10-19 13:44:24 -04:00
modaltb 3bbf1cc868 Add support for ModalAI FC1 2019-10-19 12:23:23 -04:00
Nick Steele 070d75496d Handle MAV_CMD_PREFLIGHT_REBOOT_SHUTDOWN 'Do nothing for autopilot' 2019-10-18 15:57:50 -04:00
Matthias Grob 08ec6a28f0 mc_att_control: remove TPA
because it's mostly unused and we have thrust curve correction
see parameter THR_MDL_FAC
2019-10-18 15:54:09 -04:00
Julian Oes f9ddbd7e2a mpu6000: remove factory test for fmu-v2 2019-10-18 15:00:41 -04:00
Matthias Grob 22c4bb498c FlightTaskDescend: set no vertical thrust when commanding velocity 2019-10-18 16:18:19 +02:00
Julian Oes de90543d6f FlightTasks: add Descend task to land without GPS
This adds a flight task to catch the case where we want to do an
emergency descent without GPS but only a baro.

Previously, this would lead to the navigator land class being called
without position estimates which then made the flight tasks fail and
react with a flight task failsafe. This however meant that landed was
never detected and a couple of confusing error messages.

This applies if NAV_RCL_ACT is set to 3 "land".
2019-10-18 16:18:19 +02:00
Matthias Grob 5f53ae1253 mc_pos_control: execute failsafe with invalid setpoints 2019-10-18 16:18:19 +02:00
Martina Rivizzigno 95dc522b99 update sitl_gazebo submodule 18/10/2019 2019-10-18 11:43:58 +01:00
Julian Oes d3da4a92e0 msg: don't implement print_message for fmu-v2
This saves about 3.4k of flash for fmu-v2.
2019-10-18 11:54:24 +02:00
Mark Sauder e9c9fb8239 fix multicopter land detector: do not update parameters every cycle (#13212)
And add updateParams() call in LandDetector::_update_params().
2019-10-18 09:25:41 +02:00
Matthias Grob cefa7ec5dc arch.sh: use nproc instead of grepping /proc/cpuinfo 2019-10-17 12:48:04 -04:00
Tanja Baumann be1f966e5f Collision prevention: Option to enable flying outside FOV and rename parameters (new CP group)
* rename parameters to allow more descriptive names under CP group
* add option to enable moving where there is no data
* add test for param CP_GO_NO_DATA

Co-Authored-By: Martina Rivizzigno <martina@rivizzigno.it>
2019-10-17 11:23:50 -04:00
Julian Oes 2fcddd9b8d mavlink: fix uninitialized mavlink warnings 2019-10-17 08:44:53 -04:00
Julian Oes ec95378821 logger: fix uninitialized coverity warnings 2019-10-17 08:44:53 -04:00
Julian Oes 8e625285fc platforms: initialize strings
This might fix a warning about argv being a TAINTED_SCALAR further down.
2019-10-17 08:44:53 -04:00
Timothy Scott cf8f03f190 Changed listener to not busy-wait (#13157)
* Changed listener to not busy-wait
2019-10-17 11:29:36 +02:00
Nicolas de Palezieux 40bb209fd2 dshot telemetry: enable telemetry publishing for setups with only one ESC 2019-10-17 11:13:38 +02:00
Daniel Agar 6ccb4af8b0 CollisionPrevention: remove unnecessary double precision floating point math 2019-10-17 08:44:33 +02:00
Daniel Agar e942d3a3b2 FlightTasks: remove unnecessary double precision floating point math 2019-10-17 08:44:33 +02:00
Beat Küng 25aded36ec WorkQueue: avoid potential semaphore counter overflow
This could happen in the following cases:
- IRQ/publisher rate is faster than the processing rate, and therefore
  WorkQueue::Add is called at a higher rate
- a long-running or stuck task that blocks the work queue a long time

Both cases are not expected to happen under 'normal' circumstances (if the
system runs as expected).
2019-10-16 18:29:26 +02:00
Beat Küng 2296c9acfa uavcan_virtual_can_driver: fix invalid use of px4_sem_getvalue
sem_getvalue returns 0 on success, -1 on error, and never a value > 0.
2019-10-16 18:29:26 +02:00
Beat Küng 884621415d dataman: fix invalid use of px4_sem_timedwait
px4_sem_timedwait expects an absolute time (from CLOCK_REALTIME), but a
relative time was provided.

This is only relevant if FLASH_BASED_DATAMAN is set (only on Intel aero).
2019-10-16 18:29:26 +02:00
Daniel Agar bde36f0f4a ROMFS: rc.vtol_defaults limit inner loop rate (#13196)
- temporary remedy for https://github.com/PX4/Firmware/issues/13149
2019-10-16 12:27:06 -04:00
ThomasRigi 17c17f26a9 VTOL GPSF: fix fixed bank loiter (#12778)
* GPS Failsafe fix for VTOL
* navigator: use new uORB API for VTOL publication
2019-10-16 17:57:44 +02:00
TSC21 412c364e90 microRTPS bridge: templates: do not change naming of topics based on the fasrtpsgen version 2019-10-16 16:16:11 +01:00
Matthias Grob a053b7f69b vtol_att_control_main: only reset thrust when disarmed
to see flaps moving according to attitude control before arming
and not have tailsitter elevons move to follow north heading.
2019-10-16 16:30:38 +02:00
Julien Lecoeur 4cc7b1319f Fix param update in mc_att_control
ModuleParams::updateParams() was never called
2019-10-16 08:17:04 -04:00
Beat Küng 17551a99f8 io_timer: fix potential invalid memory access 2019-10-16 13:13:17 +02:00
Beat Küng 617f37afbf mixer_{multicopter,helicopter}: add buffer size check
Fixes a potential buffer overflow if an MC/helicopter mixer is used that
exceeds the number of physical pins.
This is not a useful/flyable configuration, but the system still should
not crash.
2019-10-16 13:13:17 +02:00
Beat Küng 173337e49c uORBManager: print errno for advertisement failures
Helps with debugging.
2019-10-16 13:13:17 +02:00
Matthias Grob 45a53726d6 LandDetector: switch to uORB::Publication 2019-10-16 00:47:01 -04:00
Matthias Grob 679e4fedf5 LandDetector: switch land flags to properies instead of one state 2019-10-16 00:47:01 -04:00
modaltb 1e1549a169 Add support for Bosch BMP388 barometer 2019-10-15 23:33:49 -04:00
Ilya Petrov c58cfce6be do not check VP fusion during GPS startup
This is solution for https://github.com/PX4/Firmware/issues/11864
2019-10-15 17:01:20 +01:00
kamilritz a4e035d338 Add param to choose vision observation noise source 2019-10-15 16:06:37 +01:00
RomanBapst 6bfb50df8a run arm authorization as last pre-arm check, as it used to be implemented
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-10-15 15:44:24 +01:00
Matthias Grob e843090383 Replace a lot of memset with {} initializers 2019-10-15 10:01:03 -04:00
Matthias Grob b8f70e865c voted_senors_update: remove memset 0 initializations because of zero initializer in header 2019-10-15 10:01:03 -04:00
Matthias Grob 185e2811dc gyro_calibration: use constexpr instead of const 2019-10-15 10:01:03 -04:00
Matthias Grob 09faa4647b ekf2_params: correct typo 2019-10-15 10:01:03 -04:00
TSC21 bfab544a64 Jenkins CI: reactivate Catkin build stage 2019-10-15 10:42:14 +01:00
Mark Sauder 0cbb693a8d Add return INFINITY; to the LandDetector class _get_max_altitude() method declaration (#12343) 2019-10-15 08:19:53 +02:00
Matthias Grob 9f639d1f3b mc_att_control: move rate control to RateControl class
This makes the controller more modular, more readable and hence
better maintainable.
2019-10-15 07:46:47 +02:00
TSC21 97e1edc835 microRTPS: templates: fix support for ROS2 Dashing 2019-10-14 23:17:27 +01:00
TSC21 f91770f9cd generate_microRTPS_bridge: fix fastrtpsgen version check handler 2019-10-14 21:23:27 +01:00
Daniel Agar c51475640e mavlink: only send ATTITUDE/ATTITUDE_QUATERNION msgs on vehicle_attitude update
- fixes #13182
2019-10-14 15:47:22 -04:00
mcsauder fb12ddb69a Cherry pick the directory and voted_sensors_update.h from PR #9756.
Consolidate _update_params() methods for improved inheritance from the LandDetector base class.
Move common uORB::Subscriptions to the base class for inheritance.
Deprecate redundant override methods.
2019-10-14 21:25:57 +02:00
David Sidrane c44e4b9578 imu/mpu6000: support ICM20689 rev 4 ID 2019-10-14 15:17:43 -04:00
Silvan Fuhrer 51374aec7b px4_fmu-v5: add here2 mag to startup
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-10-14 15:16:33 -04:00
Nick b72d010c34 Update vehicle_local_position.ref_alt comment to reflect how ref_alt is being used in PX4 2019-10-14 12:33:25 -04:00
Matthias Grob bb91db2057 AttitudeControlTest: fix adaptAntipodal() function 2019-10-14 18:23:22 +02:00
Matthias Grob 83dfa227a7 AttitudeControlTest: include all corner case combinations
Which revealed antipodal quaternion corner cases when
the first element is zero.
2019-10-14 18:23:22 +02:00
Matthias Grob 511828bfd2 AttitudeControlTest: add first controller convergence test 2019-10-14 18:23:22 +02:00
TSC21 10e3bcd138 ulog stream msgs: rename 'sequence' fields as they are protected names in fastrtpsgen 2019-10-14 16:37:17 +01:00
TSC21 88a7e3df09 microRTPS bridge: fix templates for ROS2 usage 2019-10-14 16:37:17 +01:00
BazookaJoe1900 3007b0876c mavlink: add protection against setting wrong type of parameters 2019-10-14 11:18:08 -04:00
Travis Bottalico 5324c37d04 Add support for voxlpm (I2C power monitor) 2019-10-14 11:08:56 -04:00
Jin Chengde 13c3ae3b52 FW RWTO: add throttle_ramp_time parameter RWTO_RAMP_TIME
* add throttle_ramp_time parameter support fixed wing runway takeoff
2019-10-14 11:07:33 -04:00
Matthias Grob 7e2fb6b4da arch.sh: switch permissions of pip install (again)
after testing the right solution on a fresh installation
2019-10-14 10:54:09 -04:00
Martina Rivizzigno 123f769306 enable safe landing test 2019-10-14 10:53:13 -04:00
Martina Rivizzigno 7f4ddde378 enable avoidance test 2019-10-14 10:53:13 -04:00
Matthias Grob 001da78089 mc_pos_control: improve failsafe handling
See issue #12307

Since commander should still handle all failsafes we should only run
into this case as last resort to not crash.
If all failsafe actions are disabled but data is missing
e.g. RC loss action disabled but flying in manual and no RC
this can be tested.
2019-10-14 15:07:09 +02:00
Matthias Grob 068f56d66f FlightTasks: fix switchTask() comment typo 2019-10-14 15:07:09 +02:00
Daniel Agar 97efbde6f4 WIP: commander re-evaluate RC mode switch when local position becomes valid 2019-10-14 14:16:24 +02:00
Matthias Grob 093d3b76d9 PULL_REQUEST_TEMPLATE: change order of titles (#13174) 2019-10-14 13:11:44 +02:00
ToppingXu 35e0554ace navigator: fix save mission state. (#12468) 2019-10-14 11:58:42 +02:00
Daniel Agar 04ea84908e Update submodule mavlink v2.0 to latest Sun Oct 13 08:37:21 EDT 2019
- mavlink v2.0 in PX4/Firmware (c09ea2a9b0): https://github.com/mavlink/c_library_v2/commit/31cc5bb39e1cb69f5e608e8e2cac8a4d57332e1c
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/c549ee329842e6182bc0dd72369a83fc0deb8f6e
    - Changes: https://github.com/mavlink/c_library_v2/compare/31cc5bb39e1cb69f5e608e8e2cac8a4d57332e1c...c549ee329842e6182bc0dd72369a83fc0deb8f6e
2019-10-13 13:47:06 -05:00
Matthias Grob c09ea2a9b0 arch.sh: don't execute pip as root
otherwise packages get installed in
/root/.local/lib/python3.7/site-packages
2019-10-12 08:38:39 +02:00
Matthias Grob 50c5150471 arch.sh: work around gazebo AUR build error and correct comments 2019-10-12 08:38:39 +02:00
Matthias Grob bba464d722 arch.sh: enable multicore gazebo compilation 2019-10-12 08:38:39 +02:00
Matthias Grob 7dd1be65ca arch.sh: add gazebo installation 2019-10-12 08:38:39 +02:00
Beat Küng 803a71928f fmu-v3: enable DShot
Disables RX DMA on TEL4 and IO debug serial port
2019-10-11 08:14:17 +02:00
Beat Küng 82106105b7 parameters: defer auto-saving to after disarming for flash-based params
This is especially important for DShot, that does not update when the CPU
stalls.
2019-10-11 08:14:17 +02:00
Beat Küng 67500123e3 fmu-v5: add dshot support
But only on the first 4 FMU outputs, as the next ones conflict with px4io
serial dma (UART8_RX)

RX DMA is disabled on the GPS port as well (conflicts with TIM1).
2019-10-11 08:14:17 +02:00
Beat Küng 8a9744d05a dshot: allow boards to enable dshot only on a subset of the timers 2019-10-11 08:14:17 +02:00
Beat Küng 93a12436a3 parameters: update perf counter for flash-based param_save_default() 2019-10-11 08:14:17 +02:00
Beat Küng a545f7ee16 mixer_module: extend printf status output 2019-10-11 08:14:17 +02:00
Beat Küng b080679146 kakutef7, kopis airframe: enable dshot & telemetry 2019-10-11 08:14:17 +02:00
Beat Küng d0a7490222 dshot: update timer generation before DMA request
This reloads the timer configuration before triggering DMA. Without that,
in rare cases, there were 17 bits sent instead of 16.
The 1. bit (1. pulse) was always wrong (too much), the rest of the bits
were the correct DShot packet that was meant to be sent.
2019-10-11 08:14:17 +02:00
Beat Küng 7445c25fcc dshot: check if DMA still in progress
No other functional change, just restructuring.
2019-10-11 08:14:17 +02:00
Beat Küng 182efaa757 dshot: reduce static buffer size
And handle failures of up_dshot_init().

On Omnibus: reduces memory usage if dshot is enabled by ~1.0KB.
The buffer is roughly 1KB in size.
2019-10-11 08:14:17 +02:00
Beat Küng e78250ab8d dshot telemetry: retrieve & print ESC info with 'dshot esc_info' CLI command 2019-10-11 08:14:17 +02:00
Beat Küng 26648ad0b9 dshot: add support to send commands via CLI
This enables the possibility to permanently reverse motor directions :)
2019-10-11 08:14:17 +02:00
Beat Küng 65f3c7f93d dshot: add telemetry and publish esc_status message 2019-10-11 08:14:17 +02:00
Beat Küng d44302c03b module_schema.yaml: add 'decimal' and 'increment' for floats 2019-10-11 08:14:17 +02:00
Beat Küng 4c4ce09005 esc_status: trim the message and remove unused fields 2019-10-11 08:14:17 +02:00
Beat Küng 69c10dcaac dshot: move implementation to a separate directory & library
So that the static memory overhead is not added to targets w/o dshot
2019-10-11 08:14:17 +02:00
Beat Küng 775916ef11 kakutef7: enable dshot 2019-10-11 08:14:17 +02:00
Beat Küng 23dbd9426a dshot: handle dcache, flush cache before DMA transfer 2019-10-11 08:14:17 +02:00
Beat Küng 3234aca53b px4_micro_hal: add PX4_ARCH_DCACHE_LINESIZE definition 2019-10-11 08:14:17 +02:00
Beat Küng 132dcdaf25 beta75x airframe: enable DShot600 2019-10-11 08:14:17 +02:00
Igor Mišić 543a057f80 fmu-v4: add dshot timer config 2019-10-11 08:14:17 +02:00
Beat Küng ac82c5114b omnibusf4sd: add dshot timer config 2019-10-11 08:14:17 +02:00
Beat Küng d8ef1b59b9 ROMFS: add dshot startup support 2019-10-11 08:14:17 +02:00
Beat Küng a161be6ec8 dshot: add dshot driver
Supports all DShot modes, but no telemetry yet.
It includes the modes and capture configuration from FMU so that it serves
as drop-in replacement.
2019-10-11 08:14:17 +02:00
Beat Küng f3eea85bef MOT_ORDERING, MC_AIRMODE: move param def to mixer_module and 'Mixer Output' group 2019-10-11 08:14:17 +02:00
Beat Küng 2a492a8e47 fmu: remove unused include and variable 2019-10-11 08:14:17 +02:00
Igor Mišić 5bd9659301 stm32 timers: add dshot implementation 2019-10-11 08:14:17 +02:00
TSC21 061ee15139 update sitl_gazebo submodule (10/10/2019) 2019-10-10 15:51:09 +02:00
Dusan Zivkovic ab2e235333 Commander: bugfix: get all available messages on the subsystem_info topic 2019-10-10 13:12:31 +02:00
Dusan Zivkovic b6f21fa76e voted_sensors_update: fix style 2019-10-10 10:31:56 +02:00
Dusan Zivkovic 316a188e8e voted_sensors_update: parameter CAL_*_EN enables sensor with id CAL_*_ID 2019-10-10 10:31:56 +02:00
Dusan Zivkovic d3e79c4726 voted_sensors_update: set priority properly in case of late mag subscriptions or sensors enabled param changes 2019-10-10 10:31:56 +02:00
Matthias Grob 7f63ed8202 Arch setup script (#13111)
* ubuntu.sh: fix space and capitalization

* Add setup script for Arch Linux

* arch.sh: remove numerous confirmations, added some base packages

* setup scripts: adjust messages according to review
2019-10-10 08:59:11 +02:00
Julian Oes 307dc3e32d mavlink: fix boot complete without lockstep
Without lockstep the actual monotonic clock of the host computer is
used. Therefore, this time is likely much more than 20 seconds and the
check if the boot complete happened in time will fail immediately.

Therefore, it probably makes more sense to count the time from the first
mavlink creation.
2019-10-10 08:58:34 +02:00
Julian Oes ea35923d3a navigator: bugfix to prevent NaN setpoints
The asinf function is NaN outside of -1 to 1. Therefore, it probably
makes sense to constrain the input to prevent NaN setpoints further down
the line.
2019-10-09 08:36:34 -06:00
Matthias Grob ca711fecc7 Commander: improve message for RC override event 2019-10-09 15:34:46 +02:00
mcsauder f9a5c91f8c Deprecate vehicle_attitude_sub from MulticopterLandDetector as it is no longer utilized. 2019-10-09 09:48:17 +02:00
Lasse 5ac0a3043b Clarify Documentation of THR_MDL_FAC
The documentation of the thrust model parameter `THR_MDL_FAC` did not
mention both thrust and "PWM" being relative values. Also the use of the
term PWM could be misleading, since the model is applicable to CAN ESCs
as well.

This commit rephrases the user documentation string and a few source
code comments, but no logic changes are made.

Closes PX4/Firmware#13105
2019-10-09 08:06:51 +02:00
Matthias Grob c1faea8d32 Commander: add const qualifiers for clarity 2019-10-09 08:03:07 +02:00
Matthias Grob 63f2c009c7 PreflightCheck: refactor failureDetectorCheck return value 2019-10-09 08:03:07 +02:00
Matthias Grob 8e0ee88e0a PreflightCheck: add const qualifiers to parameters
to help readability
2019-10-09 08:03:07 +02:00
Matthias Grob c570dc9315 PreflightCheck: remove goto from imu consistency check 2019-10-09 08:03:07 +02:00
mcsauder 6066300757 Set a default signal_quality value in the MavlinkReciever::handle_message_distance_sensor() method. 2019-10-08 21:19:47 +01:00
mcsauder 5ccba5541d Added missing fields and a TODO with commented field to the MavlinkReciever::handle_message_distance_sensor(). 2019-10-08 21:19:47 +01:00
dusan19 8c4d32ff4b navigator: when setting pos_sp_triplet yaw, also set the yaw valid flag to true 2019-10-07 20:53:40 -04:00
Julian Oes 741f6787a7 mavlink: disable sending RC override
This was added to enable a Pixhawk to be used as an RC input for e.g.
SITL. As far as we're aware of that's not really used. However, sending
this can cause issues if multiple Pixhawks are in the same network.
Also, is uses up some of the MAVLink bandwidth.

Therefore, it's probably best to remove that feature for now.
2019-10-07 09:59:17 -04:00
TSC21 9a4a02a255 uorb_rtps_message_ids.yaml: fix typo 2019-10-07 12:58:15 +01:00
Julian Oes 5e663b9321 Remove eigen leftovers
It looks like we're not using Eigen for a while now.
2019-10-07 12:04:50 +02:00
BazookaJoe1900 02e861b16e enable silent compare of parameter (#12850)
Remove false errors after comparing parameters that doesn't exists.
as described in #12832
2019-10-07 09:50:11 +02:00
Matthias Grob 05446c0875 ubuntu.sh: correct output during ccache installation (#13106) 2019-10-07 09:14:00 +02:00
Daniel Agar 941a3258b6 Update submodule mavlink v2.0 to latest Sun Oct 6 12:38:38 UTC 2019 (#13100)
- mavlink v2.0 in PX4/Firmware (91badceb27): https://github.com/mavlink/c_library_v2/commit/d4a4a4314b8912015e999e17a3f66afee434a9cd
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/31cc5bb39e1cb69f5e608e8e2cac8a4d57332e1c
    - Changes: https://github.com/mavlink/c_library_v2/compare/d4a4a4314b8912015e999e17a3f66afee434a9cd...31cc5bb39e1cb69f5e608e8e2cac8a4d57332e1c
2019-10-06 10:41:21 -04:00
TSC21 91badceb27 Update submodule sitl_gazebo to latest Sun Oct 06 11:02:54 GMT 2019 2019-10-06 11:40:02 +01:00
Nuno Marques 5a8aa04970 CI: bump container tags to 2019-10-04 (#13095)
* bump container tags to 2019-10-04

* docker_run: update container name and tag

* generate_microRTPS_bridge.py: force FastRTPSGen to version 1.0 if the result of 'fastrtpsgen -version' command is not a number

* CI: temporarly disable avoidance and safe landing tests

* CI: try to revive tiltrotor test
2019-10-06 01:21:04 -04:00
Matthias Grob c8f3f07ff7 matrix: pull explicit constructors 2019-10-05 11:46:07 -04:00
TSC21 474c406147 CI: microRTPS: deploy templates to px4_ros_com 2019-10-04 16:56:03 +01:00
TSC21 e7b0384f05 fix FastRTPSGen version verification 2019-10-04 16:56:03 +01:00
TSC21 9c00f3de02 microRTPS bridge: CMake: add verbosity regarding the FastRTPSGen version 2019-10-04 16:56:03 +01:00
TSC21 5c0f01a8b8 microRTPS bridge: try/catch FastRTPSGen errors 2019-10-04 16:56:03 +01:00
TSC21 2677e12024 microRTPS bridge: templates: Publisher.cpp.em: close 'if' statement 2019-10-04 16:56:03 +01:00
TSC21 8846092c59 readd console output removal 2019-10-04 16:56:03 +01:00
TSC21 1970ef875f micrortps bridge: clean templates; add backwards compatibility; add ROS2 compatibility 2019-10-04 16:56:03 +01:00
TSC21 278d2fd21f first push on supporting ROS2 Dashing and IDL 4.2 2019-10-04 16:56:03 +01:00
Daniel Agar f885d2274a Revert "vtol_att_control: update parameter strings to class enum"
This reverts commit 5351f886ec.
2019-10-03 11:28:51 -04:00
Daniel Agar a5895e5a99 Revert "commander: update parameter strings to class enum"
This reverts commit c322f1d156.
2019-10-03 11:28:44 -04:00
PX4 Build Bot 5f040fe24c Update submodule ecl to latest Wed Oct 2 20:37:33 EDT 2019
- ecl in PX4/Firmware (4d0ac1a400cc007af392c99bbfa809d59d3e7ecd): https://github.com/PX4/ecl/commit/b78429aa60257157c53a8a43c1c29646560de124
    - ecl current upstream: https://github.com/PX4/ecl/commit/f005e0ea8f33d10dd014a0700e712426540bb58a
    - Changes: https://github.com/PX4/ecl/compare/b78429aa60257157c53a8a43c1c29646560de124...f005e0ea8f33d10dd014a0700e712426540bb58a

    f005e0e 2019-09-27 kamilritz - Remove deprecated ev_innov_gate param
2019-10-03 00:26:16 -04:00
PX4 Build Bot cee8c31649 Update submodule matrix to latest Wed Oct 2 20:37:38 EDT 2019
- matrix in PX4/Firmware (cb369cb6a75cae71035d72a3bacecce3e109f971): https://github.com/PX4/Matrix/commit/c34e8dc98fd05ea55dcd4c9fc551b11a3d23a601
    - matrix current upstream: https://github.com/PX4/Matrix/commit/973999a4d3c6d4d85bf0153230974fd9571f7846
    - Changes: https://github.com/PX4/Matrix/compare/c34e8dc98fd05ea55dcd4c9fc551b11a3d23a601...973999a4d3c6d4d85bf0153230974fd9571f7846

    973999a 2019-09-23 Matthias Grob - Fix some template type conversions and style
2019-10-03 00:25:18 -04:00
Mark Sauder 3ce58f7102 sensors: organize vars in voted_sensors_update.h 2019-10-02 19:54:38 -04:00
Daniel Agar e3bbac0447 land_detector: move to same WQ as estimator
- the primary data sources of the land detector run from the same WQ so
don't lose anything by serializing these modules
2019-10-02 19:44:46 -04:00
Daniel Agar c639444ef9 intel aerofc-v1 disable sih module to save flash 2019-10-02 19:44:46 -04:00
Daniel Agar 315141873e NuttX boards reduce CONFIG_MAX_TASKS 64 -> 32 (default) 2019-10-02 19:44:46 -04:00
Daniel Agar 7baf474940 mc_pos_control: move to WQ 2019-10-02 19:44:46 -04:00
Daniel Agar 3c623af903 ekf2: move to WQ with uORB callback scheduling 2019-10-02 19:44:46 -04:00
Daniel Agar 5351f886ec vtol_att_control: update parameter strings to class enum 2019-10-02 19:43:32 -04:00
Daniel Agar c322f1d156 commander: update parameter strings to class enum 2019-10-02 19:43:32 -04:00
Mark Sauder 508ffa1b39 land_detector: Remove recently added vehicle_attitude.timestamp check from MulticopterLandDetector::_get_maybe_landed_state(). (#13072)
PR #12681 added a check to the MulticopterLandDetector::_get_maybe_landed_state() method for a valid vehicle_attitude.timstamp value to finish work in PR #9756. It was discovered that the addition of that check leaves it possible to fly in acro mode without a valid attitude and auto-disarm can engage, allowing the multicopter to fall out of the sky.
2019-10-02 16:31:06 -04:00
Daniel Agar d537f3ec6b vscode: restore editor.smoothScrolling to default 2019-10-02 16:24:53 -04:00
mcsauder 2644742b37 Deprecate RoverLandDetector virtual methods that are redundant. 2019-10-02 16:02:30 -04:00
Jacob Dahl 5842c0c2fb UAVCAN: add battery support (uavcan::equipment::power::BatteryInfo) 2019-10-02 13:08:43 -04:00
Daniel Agar 26364d44c9 px4_work_queue: command line status output and shutdown empty queues
* adds a work_queue systemcmd that will bring a tree view of all active work queues and work items
 * WorkQueues now track attached WorkItems and will shutdown when the last WorkItem is detached
2019-10-02 12:23:17 -04:00
garfieldG cc1d86bc0b @value will be printed with Whitespace in start of line for serial_config parameters 2019-10-02 10:34:10 +02:00
Daniel Agar 0fe271b7f5 CollisionPrevention add more distance_sensor orientations 2019-10-01 21:05:37 -04:00
Daniel Agar 5126e6ea61 cmake: use gold linker if available 2019-10-01 20:44:07 -04:00
Daniel Agar 3687677095 cmake: show sitl_gazebo build output and improve rebuild 2019-10-01 14:22:30 -04:00
Daniel Agar 27f459c14e px4io: move to uORB::Publication<> 2019-10-01 12:24:27 -04:00
Julian Oes fa9ac6ecf6 github: tone stalebot down
My suggestion is to re-configure stale bot so it just adds the label
stale but does not close the issue/PR.

This enables us to look for outdated issues using the stale label and
close them.

This brings these advantages:
- No more endless re-opening of PRs and issues which is not fun (and I
  will eventually give up on).
- Less stalebot comment noise. (Because it is handy to look for all
  issues/PRs without any comments to see what is unanswered).
- I'm not listed as "participating" in all the issues/PRs just because
  I was just fighting the stalebot.
- Less notifications meaning we can see anything in the noise.
2019-10-01 10:35:28 -04:00
Daniel Agar 2989ce981c rc_input: move to uORB::PublicationMulti<> 2019-09-30 18:41:23 -04:00
Daniel Agar 6941077218 FlightTasks: orbit and obstacle test use new uORB::Publication<> 2019-09-30 18:26:01 -04:00
Daniel Agar 045f6233d4 FlightTasks: switch to uORB::Subscription
- delete SubscriptionArray
 - all FlightTasks are now responsible for updating their own subscriptions (typically in updateInitialize()).
2019-09-30 18:16:36 -04:00
dvornikov-aa ad728cc0c7 sf1xx: Fix max distance for SF/LW20/b 2019-09-30 20:10:57 +01:00
Daniel Agar a557f3ffe4 bitcraze crazyflie add dmesg and console buffer 2019-09-30 14:29:54 -04:00
Daniel Agar 62bc0ab8ad CollisionPrevention: limit collision warning to every 3 seconds and minor cleanup
- whitespace and formatting fixes
 - mark locals const for readability
2019-09-30 10:48:12 -04:00
Daniel Agar 34b03d5659 frsky_telemetry: move to uORB::Subscription 2019-09-30 10:28:03 +02:00
Daniel Agar 0af942ce12 Jenkins hardware skip sd_bench on px4_fmu-v5_stackcheck 2019-09-29 20:29:34 -04:00
Daniel Agar 030e22c724 adc test shorten 2019-09-29 20:29:34 -04:00
Daniel Agar c8e59c4e39 parameter_update use uORB::Subscription consistently 2019-09-29 10:49:03 -04:00
garfieldG bbb96cbd0c Mavlink startup script per board
-moved rc.mavlink to the boards optional rc additions (now it's called rc.board_mavlink) to handle board specific mavlink needs (mavlink over usb, ethernet, additional streams, etc.)
-mavlink module will be responsible to usb defaults, therefore less args are needed to be passed to mavlink module if one wants to use mavlink over usb.
-the way to check if connection is usb is by it's designated variable and not by config mode.
2019-09-29 10:46:08 -04:00
Daniel Agar fdefaf1ad3 lights/blinkm: move to uORB::Subscription 2019-09-28 18:34:20 -04:00
Daniel Agar ec061a7cfd telemetry/bst: move to uORB::Subscription 2019-09-28 18:19:38 -04:00
Daniel Agar 105bbef3bf commander: rc_calibration move to uORB::Subscription 2019-09-28 16:43:53 -04:00
Julian Oes ce4290c8d4 mavlink: typo fix att -> act 2019-09-28 16:40:13 -04:00
Julian Oes b0035e5704 mavlink: prevent race if shut down immediately
If we do mavlink stop-all right after mavlink start, we do a perf_free
before actually having stopped the threads accessing the perf counters.
2019-09-28 16:40:13 -04:00
Daniel Agar 0486d69240 delete obsolete segway example 2019-09-28 15:05:50 -04:00
Daniel Agar fd67bd0680 uORB: SubscriptionCallback cleanup naming 2019-09-28 13:43:56 -04:00
Kjkinney 3f9b3fb4da px4_log: publish all PX4_INFO messages as well (#12954) 2019-09-27 14:04:30 -04:00
Daniel Agar 637d52c74f frsky_telemetry: increase stack by 60 bytes 2019-09-27 11:37:29 -04:00
mcsauder 4f71c4e123 Change #defines to static constexpr types in LidateLite.h, updated the docs link in ll40ls.cpp, and shortened comments to allow uniform indentation in LidarLiteI2C.h. 2019-09-27 07:55:53 +01:00
mcsauder 9023030931 LidarLite driver minor comment updates/formatting and change instances of OK to PX4_OK. 2019-09-27 07:55:53 +01:00
mcsauder 7b16c3482d Refactor the ll40ls namespace driver methods to more closely match the cm8jl65, mappydot, leddar_one, and other distance sensor driver implementations. 2019-09-27 07:55:53 +01:00
kamilritz 8ce4a15778 Update frame in mavlink receiver odometry to newest mavlink 2019-09-26 14:48:20 -04:00
kamilritz 9c46a89f64 Update EKF_AID_MASK 2019-09-26 14:48:20 -04:00
Silvan Fuhrer bfbc9dda91 VTOL: fix front transition rate publication (enable FW attitude controller to run instantly when transition is started). For that the vehicle_status_poll is moved before vehicle_control_module_poll in FW att C
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-09-26 11:39:55 -04:00
kritz 190c817a9e ekf2: update to latest ecl version [continued] (#13023)
* ekf2: update to latest ecl version

Includes compatibility changes for renamed variables.

* ekf2: Add write of odometry velocity data

Co-Authored-By: kritz <kritz@ethz.ch>

* ekf2: Modify parameters to enable control of vision velocity fusion

* ekf2: Update to latest ecl with timestamp messages
2019-09-26 10:21:53 +02:00
Daniel Agar dedd257433 CollisionPrevention: fix integer rounding (#13028) 2019-09-26 09:45:55 +02:00
Daniel Agar 3031f94ded mavlink: optimize normal mode for typical GCS usage over serial radio 2019-09-25 14:08:04 -04:00
Daniel Agar 2366abefd8 nxp/fmuk66-v3: readd uavcan
* this was accidentally dropped earlier this year
2019-09-25 13:42:59 -04:00
Daniel Agar 88fb6f7b8e cm8jl65: move to PX4Rangefinder and cleanup
* cm8jl65 split out header and main
* cm8jl65: move to PX4Rangefinder
* PX4Rangefinder: move signal_quality handling to PX4Rangefinder
2019-09-25 12:52:45 -04:00
Daniel Agar a217e15c5f Jenkins temporarily disable Catkin build 2019-09-25 10:45:12 -04:00
Mark Sauder db8e203a7a Update the Integrator class local variable dt from double to float and utilize the hrt_abstime typedef. (#12935) 2019-09-25 14:41:54 +02:00
Julian Oes 0b368d043f mavlink: always check stream subscriptions (#13018)
This fixes the regression where we saw this in SITL:
ERROR [mavlink] system boot did not complete in 20 seconds

The reason was that the stream subscription requests were not checked
because the while loop was not running yet because mavlink was not
booted completely.
By moving the stream subscription requests into a function we can run
them even if we don't run the rest of the loop.
2019-09-25 14:37:08 +02:00
Daniel Agar b6db872303 listener fix incorrect "never published" cases (#13006)
- fixes #12955
2019-09-25 10:46:13 +02:00
Matthias Grob bc8781d130 Appveyor: update to Windows Toolchain v0.6 (#13016) 2019-09-25 10:43:04 +02:00
Mark Sauder 4a6742c3e6 Deprecate the non-functioning HC_SR04 driver. (#13021) 2019-09-25 10:34:50 +02:00
Julian Kent 07d656e971 Guidance feature for Collision Prevention (#13017)
* add guidance

* remove COL_PREV_ANG and replace with COL_PREV_CNG

* safe max ranges per bin

* increase default value for colprev delay to account for tracking delay

* update parameter description

* fix and extend testing

* add handling for overlapping sensor data

* fix decision process for overlapping sensors
2019-09-24 17:00:04 +02:00
bresch 6139812293 FailureDetector - use standard topic subscription for attitude topic and
pass vehicle_status from commander instead of subscribing to it.
2019-09-24 14:17:58 +02:00
bresch 000c1e364c FailureDetector - Ignore attitude check for MC in acro and rattude, and FW in manual, acro and rattitude modes 2019-09-24 14:17:58 +02:00
kamilritz 35c50f693f Add missing id for vehicle_visual_odometry_aligned for rtps 2019-09-24 10:49:33 +01:00
Matthias Grob 6a5ca6e336 FlightTask: use inline assignment initializer for reset_counters struct 2019-09-24 10:34:08 +02:00
bresch 679b1659eb AutoLineSmoothVel - Reorganize functions declarations to match cpp file 2019-09-24 10:34:08 +02:00
bresch c811cf4784 FlightTask - Move ekf reset counter monitoring logic in the base FlihtTask
Each child FlightTask can simply implement what it wants to do in case
of an EKF reset event by overriding one of the _ekfResetHandler functions
2019-09-24 10:34:08 +02:00
kritz 7427768e70 ECL reference frame alignment fix (#12771)
* Fix EKF frame alignemen in ECL

* Remove empty lines

* Add initalization for ev_odom

* Only use yaw covariance for angErr

* Improve frame naming in comments

* Use copyTo

* Add aligned as suffix

* Add missing vehicle_visual_odometry_aligned
2019-09-23 14:24:52 -04:00
Matthias Grob 412b44ff6e Commander: allow RC to override during RTL 2019-09-23 12:42:33 +02:00
Matthias Grob 4f44fde080 Commander: remove not disarming by RC message
Refactoring the condition to be more clear.
2019-09-23 12:42:33 +02:00
Christian Clauss 41516fbd55 Old style exceptions are Python 3 syntax errors 2019-09-22 17:47:37 -04:00
Daniel Agar bc35251799 Update submodule mavlink v2.0 to latest Sun Sep 22 08:37:26 EDT 2019
- mavlink v2.0 in PX4/Firmware (09bd7bbcab7ba508043018eefbe020ff74d79c66): https://github.com/mavlink/c_library_v2/commit/be2f1fbe0a8235ff4632e7df1d54c89a3c8615bd
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/d4a4a4314b8912015e999e17a3f66afee434a9cd
    - Changes: https://github.com/mavlink/c_library_v2/compare/be2f1fbe0a8235ff4632e7df1d54c89a3c8615bd...d4a4a4314b8912015e999e17a3f66afee434a9cd
2019-09-22 14:23:56 -04:00
bazooka joe fb3a91cc4f added circuit_breaker_enabled_by_val()
added and using circuit_breaker_enabled_by_val() where possible instead of circuit_breaker_enabled() which search for cbrk parameters by name, which is extensive process.
2019-09-22 13:55:40 -04:00
cclauss c18104d48b Use print() function in both Python 2 and Python 3
Legacy __print__ statements are syntax errors in Python 3 but __print()__ function works as expected in both Python 2 and Python 3.
2019-09-22 13:54:24 -04:00
mcsauder cdbe4a3ee8 Refactor the terraranger driver. 2019-09-22 12:23:25 -04:00
PX4 Build Bot c67a7536d4 Update submodule matrix to latest Sun Sep 22 08:37:30 EDT 2019
- matrix in PX4/Firmware (8b1f9546aabfe6ab2a0431f1d5af6dcc976d4f59): https://github.com/PX4/Matrix/commit/60c9c99dcc44ea12bed0c3f9b95d01e2aa6d7d9e
    - matrix current upstream: https://github.com/PX4/Matrix/commit/c34e8dc98fd05ea55dcd4c9fc551b11a3d23a601
    - Changes: https://github.com/PX4/Matrix/compare/60c9c99dcc44ea12bed0c3f9b95d01e2aa6d7d9e...c34e8dc98fd05ea55dcd4c9fc551b11a3d23a601

    c34e8dc 2019-09-17 Matthias Grob - helper: consider matrices with the same NANs and INFINITYs equal
bbaa938 2019-09-17 Matthias Grob - helper: consider NAN equal to NAN such that vectors can be compared exactly
33a6291 2019-09-17 Matthias Grob - Matrix: add proper print function testing
b0b7d72 2019-09-17 Matthias Grob - Multiplication test: fix division resulting in NAN
3747232 2019-09-17 Matthias Grob - LeastSquaresSolver: Fix nasty GCC compile optimization error
5844b0e 2019-09-16 Matthias Grob - Implement one float equality check and use it everywhere
1e80807 2019-09-16 Matthias Grob - test: Add uncovered equality checks with NAN and INFINITE
a374f37 2019-09-16 Matthias Grob - Include helper_functions like all other library components
2019-09-22 11:34:53 -04:00
Daniel Agar fe4f6c186e Mavlink: ifdef networking code 2019-09-21 13:46:01 -04:00
Daniel Agar 86dc4c5a00 cmake generate vscode launch.json 2019-09-21 13:06:49 -04:00
PX4 Build Bot 42ca17ce77 Update submodule v2.0 to latest Thu Sep 19 20:38:28 EDT 2019
- v2.0 in PX4/Firmware (103595e866882191593136495a52825c455d2026): https://github.com/mavlink/c_library_v2/commit/ac40c0329e88b70ae5db4c1467ed5853d305af54
    - v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/be2f1fbe0a8235ff4632e7df1d54c89a3c8615bd
    - Changes: https://github.com/mavlink/c_library_v2/compare/ac40c0329e88b70ae5db4c1467ed5853d305af54...be2f1fbe0a8235ff4632e7df1d54c89a3c8615bd

    be2f1fb 2019-09-17 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/b21a2652249a27a151b38cd3da5c4ac9d51fcb69
d465e22 2019-09-17 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/af677f748aa2c3268f71db6f3a1c867530b51894
5631a1e 2019-09-16 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/2876e4c06e707519a8770b661abaac008feef703
05a4389 2019-09-16 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/77a18b1cb7d4667b669e0429d86082ed38b79886
2019-09-20 11:41:27 +02:00
bresch 6f3868b5ba ManualVelocitySmoothing - Fix unlock initialization 2019-09-19 17:31:49 +02:00
bresch 0153e1b126 Matrix - Explicitly cast array[3] to Vector3f
Use .xy() for Vector2 -> Vector3 assignment
2019-09-19 17:31:49 +02:00
bresch f405bf506b AltitudeSmoothVel - Use ManualVelocitySmoothingZ class instead of re-implementing the logic 2019-09-19 17:31:49 +02:00
bresch ce96d98621 ManualVelocitySmoothing - Cosmetic changes (renaming, indentation,..)
Set the classes as final and set destructor to non-virtual
2019-09-19 17:31:49 +02:00
bresch 7cdb2364e9 ManualVelocitySmoothingXY - Add simple unit test 2019-09-19 17:31:49 +02:00
bresch f5d7eb4d87 Refactor FlightTaskManualPositionSmoothVel 2019-09-19 17:31:49 +02:00
bresch 080eedfd02 ManualPositionSmoothVel - Split large function into smaller ones, split XY and Z axes
Next step is to move as much as possible to a library in order to
reuse the Z axis in the Altitude FlightTask
2019-09-19 17:31:49 +02:00
Dennis Mannhart 453b6a39e4 TrajMath: move from FlightTasks/Utility into mathlib library because the function is also used by other libraries 2019-09-19 14:09:44 +02:00
Dennis Mannhart e6b7062442 TrajMath: replace type placeholder with floats 2019-09-19 14:09:44 +02:00
bresch e9ab6a75ba MC rate control - Scale the integrator with K during the integration
part to avoid having to scale its saturation separately. This is
required to avoid premature saturation of the integrator when using
the K term.
Also remove double saturation of the integrator
2019-09-19 14:05:28 +02:00
bresch 67e528ec0c Takeoff - allow publishing NAN longitude and latitude
A NAN is interpreted in the FlightTaskAuto as a non-valid global coordinate and sets a local position.
If a zero is sent instead, the global coordinate is recognized as valid and will be executed.
This is a problem when the global position is gained for the first time after takeoff and that a valid global reference did not exist before
2019-09-19 14:03:58 +02:00
Nico van Duijn 549a962553 EKF2: move handling of invalid range into ECL (#12988)
* ekf2: Move handling of invalid range finder data inside ecl library

The ecl library EKF is able to use vehicle motion and in-air status to better determine when the default on-ground range finder reading can be used.
The description for the EKF2_MIN_RNG parameter has been updated to make its use clearer.
2019-09-19 11:29:34 +02:00
Matthias Grob fa13f63db6 ekf2: temporarily hardcode new quality information to unkown
until priseborough's and nicovanduijn's pr #12950
2019-09-18 22:01:36 -04:00
Matthias Grob c8d0eba1d2 Update ecl and matrix to safe matrix access 2019-09-18 22:01:36 -04:00
Matthias Grob 1ecbf8efd2 test_matrix: remove duplicate namespace accesses 2019-09-18 22:01:36 -04:00
Julian Kent 2d4ecab3b0 Remove unsafe access to .data() and _data in Matrix 2019-09-18 22:01:36 -04:00
Daniel Agar 78bf12f0db px4_tasks: reduce POSITION_CONTROL priority
* this is to prevent the loss of any sensor data or estimator time slip in the event of a position controller or flight task overrun
2019-09-18 09:55:06 -04:00
Daniel Agar 494f35d5f4 Mavlink: wait for boot complete before sending or receiving anything 2019-09-18 09:07:55 -04:00
Daniel Agar be61d93d64 tfmini split out header and main 2019-09-17 21:50:59 -04:00
Daniel Agar 9b7ef7141f tfmini cleanup and use PX4Rangefinder 2019-09-17 21:50:59 -04:00
Nico van Duijn 18eaeb564d PMW3901 improvements (#12977)
* PMW3901: use frame count and quality metric

* PMW3901: set qual to 0 for unsuccessful SPI reads

* PMW3901: improve comment for collect_time

* PMW3901: set qual to zero for huge flow values
2019-09-17 10:54:56 -04:00
Maximilian Laiacker 72e93a9c36 fixed total flight time counting bug
After landing it can happen that a second take off is detected and then the _takeoff_time is rest, resulting in a wrong total flight time counter. With this fix the flight time is reliably counted from the first take off until the vehicle is disarmed. Normally the vehicle will not spend much time armed after landing, if it does the flight time will be off but this is the same as before this fix. This fix was tested in several flight experiments.
2019-09-17 14:52:27 +02:00
Daniel Agar c13835c0f0 replay module split replay_main.cpp into separate compilation units 2019-09-17 14:33:04 +02:00
Matthias Grob 270e12a4df VelocitySmoothing: refactor local scope t variables instead of array 2019-09-17 09:27:00 +02:00
bresch da8ac8cafb VelocitySmoothing - Clean up updateTraj function based on Matthias' comments 2019-09-17 09:27:00 +02:00
bresch b82fa68893 VelocitySmoothingTest - Fix typo and use "zero" instead of "null" 2019-09-17 09:27:00 +02:00
bresch 42cedb7fda VelocitySmoothing - Change direction of "brake" as braking means that
only the T3 part is required and that the jerk applied during T3 is the
opposite of the one defined by "_direction".
2019-09-17 09:27:00 +02:00
bresch 8490266be8 VelocitySmoothing - (Re)set _state_init every time _state is (re)set 2019-09-17 09:27:00 +02:00
bresch 654938f6a1 VelocitySmoothing - Cosmetic changes (new lines, reorganize functions),
regroup both updateTraj functions and edit some comments
2019-09-17 09:27:00 +02:00
bresch 0b765a1642 AltitudeSmoothVel - Update to use new implementation of VelocitySmoothing
Remove jerk reduction (not needed in the new implementation)
2019-09-17 09:27:00 +02:00
bresch 862454827e VelocitySmoothingTest - Test that the trajectory is always within the constraints 2019-09-17 09:27:00 +02:00
bresch 8cc2a7018e VelocitySmoothing - Re-enable time stretch, integrate dt to get local time.
Also split a few functions into smaller ones for readability, fix
formatting, use geters to get the current state of the trajectory
instead of return arguments.
2019-09-17 09:27:00 +02:00
bresch c7696488fe VelocitySmoothing - Improve computation of the direction of the trajectory by predicting the velocity at zero acceleration instead of the current velocity
This helps when the current velocity is smaller than the target but that
the acceleration is too large such that the velocity will overshoot.
Without this check, the algorithm increases the acceleration which leads
to an even larger overshoot.
2019-09-17 09:27:00 +02:00
bresch 052932fa95 VelocitySmoothingTest - Update unit test to use the same parameters ordering (time, setpoint) as the VelocitySmoothing class 2019-09-17 09:27:00 +02:00
bresch c13499e64b test_velocity_smothing - Update test script to use new polynomial evaluation algorithm 2019-09-17 09:27:00 +02:00
bresch a03cc495ce VelocitySmoothing - Refactor class to use polynomial evaluation instead of numerical integration
This solves many numerical issues when the trajectory is close to the
primary NE axes (small velocities). It is also more robust when dt is
large and has some jitter.
2019-09-17 09:27:00 +02:00
Hamish Willee 0c0b261ff2 ubuntu.sh - remove modemmanager 2019-09-17 00:38:14 -04:00
Daniel Agar 5507f14bb2 Jenkins HIL disable rgbled 2019-09-15 17:17:09 -04:00
Daniel Agar ed6c7cc806 cmake remove unused/broken _no_optimization_for_target 2019-09-15 17:16:38 -04:00
Daniel Agar 251831f7af cmake px4_add_library remove unused PX4_LIBRARIES property 2019-09-15 17:16:38 -04:00
Daniel Agar dc46b6a749 cmake px4_add_module MAIN is always present (required) 2019-09-15 17:16:38 -04:00
Daniel Agar fb7521eb5e cmake px4_base -> px4_parse_function_args 2019-09-15 14:36:38 -04:00
Daniel Agar d256fb8770 cmake px4_find_python_module move to standalone file 2019-09-15 14:36:38 -04:00
Daniel Agar d27dfcd921 NuttX CMakeLists.txt extract helpers (jlink, upload, etc) 2019-09-15 14:36:38 -04:00
Daniel Agar f2189dd045 CMakeLists.txt extract top level helpers (ccache, doxygen, metadata, etc) 2019-09-15 14:36:38 -04:00
Matthias Grob d4f984fea5 FlightTaskAutoLineSmooth: Fix comment to be style compliant 2019-09-13 18:10:05 +02:00
bresch 47401d1177 AutoLineSmoothVel - Replace min/max absolute constraints with a function named constrainAbs
This function constrain the absolute value of some value but keeps the original sign.
2019-09-13 17:46:01 +02:00
bresch 3c5b24037a AutoLineSmoothVel - Improve virtual pilot logic that provides velocity setpoints to the trajectory generator.
Constrain the generated velocities in the NE inertial frame rather than
just constraining the norm.
2019-09-13 17:46:01 +02:00
bresch 59f54a7fd8 mathlib - Add FLT_EPSILON deadzone in sign computation 2019-09-13 17:46:01 +02:00
mcsauder 410dd85289 Comment out the ll40ls (LidarLite) driver from the fmu-v2 build. 2019-09-13 11:03:13 -04:00
Nico van Duijn a26865c279 drivers: set CM8JL65 signal_quality invalid beyond bounds 2019-09-13 10:42:10 -04:00
Martina Rivizzigno 78279f6587 Unit tests for Obstacle Avoidance interface (#12816)
* FlighTask: remove legacy definition of empty_trajectory_wapoint

* add unit tests for the ObstacleAvoidance interface
2019-09-12 14:37:31 +02:00
Julian Kent 39451b811a Do syscall for time once, outside of loop 2019-09-11 12:34:59 -04:00
Julian Kent b27d6a958a Account for the time since range data arrived 2019-09-11 12:34:59 -04:00
Hamish Willee 94ef585f76 Link to missing params docs 2019-09-11 09:17:00 -04:00
Hamish Willee fd10220a34 Ubuntu.sh: check for requirements.txt 2019-09-11 09:15:44 -04:00
Daniel Agar 6277710fac Github actions simple cpp build 2019-09-10 17:07:51 -04:00
Daniel Agar df01eda550 systemcmds/tests: delete obsolete test_sensors 2019-09-10 16:37:33 -04:00
Silvan Fuhrer 702c6f6df4 FW pos C: fix altitude control for VTOL/FW by also publishing attitude sp if in altitude, not only if position or velocity controlled
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-09-10 13:20:07 -04:00
Silvan Fuhrer 92b824e218 VTOL attitude controller: run update_vtol_state only if mc or fw att sp changed, such that pusher support in hover works again
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-09-10 13:52:33 +02:00
Silvan Fuhrer 1b2403a87f VTOL land detector: trigger land detector in fixed-wing mode if disarmed.
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-09-10 13:46:43 +02:00
Julian Kent a8fbe6bba2 Remove references to pow(x,0.5), use sqrt instead (#12928)
* Remove references to pow(x,0.5), use sqrt instead

* Update matrix library
2019-09-10 13:29:39 +02:00
Patrick Servello 47e668eb86 simulator and dumpfile fix minor resource leaks
* Certain conditional branches returned before closing the file handler.
2019-09-09 13:24:07 -04:00
Daniel Agar a5e6c880fe Update submodule mavlink v2.0 to latest Mon Sep 9 12:38:36 UTC 2019
- mavlink v2.0 in PX4/Firmware (65db4b70fd76afe122c1aed404de60e978ead294): https://github.com/mavlink/c_library_v2/commit/d5d131cf710ceaa93d26884ea12de8de95804985
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/ac40c0329e88b70ae5db4c1467ed5853d305af54
    - Changes: https://github.com/mavlink/c_library_v2/compare/d5d131cf710ceaa93d26884ea12de8de95804985...ac40c0329e88b70ae5db4c1467ed5853d305af54
2019-09-09 12:29:42 -04:00
mcsauder e4509486e8 Correct a typo and create a #define for the LeddarOne FOV. 2019-09-06 11:59:29 +02:00
mcsauder aea139bc1b Correct the LeddarOne FOV and deprecate the unneeded _distance_sensor_topic after migrating to PX4RangeFinder. 2019-09-06 11:59:29 +02:00
mcsauder ddd9a97d42 Modify the LeddarOne driver class to utilize the PX4RangeFinder library. 2019-09-06 11:59:29 +02:00
mcsauder 94d39e4466 Return from LeddarOne::collect() via LeddarOne::measure() and alphabetize #includes. 2019-09-06 11:59:29 +02:00
mcsauder f31ac44289 Const correctness and fix leddar_one::test(). 2019-09-06 11:59:29 +02:00
mcsauder c0e8b37d96 Add collect() validation to the LeddarOne::init() method, format whitespace and console output.
Reduce measure/collect timing logic complexity to use ScheduleOnInterval() rather than SchuleDelayed().
2019-09-06 11:59:29 +02:00
mcsauder 04073f2c71 Deprecate the LeddarOne request() and publish() methods to match other distance sensor driver classes and fix perf counter errata. 2019-09-06 11:59:29 +02:00
Tanja Baumann f3c5ca6015 Collision Prevention: support multiple sensors and frames (#12883)
* build internal sensor map

* Extend testing coverage

* Update matrix library
2019-09-06 08:38:56 +02:00
Hamish Willee eb81f4bce2 ubuntu.sh: Add note to reboot computer 2019-09-06 08:02:02 +02:00
Hamish Willee 0b049fa4d7 Add updated ccache for Ubuntu 16.04 dev scripts 2019-09-06 08:02:02 +02:00
Julien Lecoeur 7bea81f02c Add board orientation ROLL_90_YAW_270 2019-09-05 20:41:32 -07:00
Daniel Agar c75954fef8 lib/led: temporarily ignore implicit fallthrough warning 2019-09-04 20:03:02 -07:00
Julian Oes c8d13bacf2 pwm_out_sim: don't advertise garbage 2019-09-04 09:21:54 -07:00
TSC21 f6a5c7cca9 qshell: rename qshell sequence fields so they can be parsed on fastrtpsgen 2019-09-04 17:04:28 +01:00
PX4 Build Bot 69475a172b Update submodule ecl to latest Wed Sep 4 08:37:31 EDT 2019
- ecl in PX4/Firmware (da6970329175df98ff46b2d9ddfa467ba438bb2e): https://github.com/PX4/ecl/commit/62fa464e4dd6cb5e585d23bd353aa50a469879f7
    - ecl current upstream: https://github.com/PX4/ecl/commit/3b32ee41660afd4785c374355e0fdefdae83e9b9
    - Changes: https://github.com/PX4/ecl/compare/62fa464e4dd6cb5e585d23bd353aa50a469879f7...3b32ee41660afd4785c374355e0fdefdae83e9b9

    3b32ee4 2019-09-02 bresch - Flow aiding - Reset state when flow is enabled only if it is the only position/velocity aiding sensor. Until now, it was alway resetting if the vehicle does not have gps or external vision. This caused a reset/glitch at every stop (when range data gets valid)
be368f3 2019-08-28 kamilritz - Update comment
c5abfe6 2019-08-28 kamilritz - remove canonicalize and adapt comments
67512d8 2019-08-22 kamilritz - Update matrix library for CI
a2ff415 2019-08-22 kamilritz - Fix get frame aligning quaternion function
53eac6e 2019-08-21 kamilritz - Canonicalize alignment quaternion
933c32c 2019-08-20 kamilritz - Enable local frame alignment also without using it
ea352a6 2019-08-20 kamilritz - Dont use mag suffix for magnitude
05196db 2019-08-20 kamilritz - Fix alignment of local frame
2019-09-04 08:09:36 -07:00
BazookaJoe1900 6ab5c2170e remove unused pca8574 and oreoled drivers 2019-09-04 08:05:08 -07:00
Nico van Duijn b4709d229a PMW3901: use quality metric 2019-09-04 08:03:04 -07:00
Claudio Micheli 5fd483dbf8 ll40ls: fixed typo errors.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-09-04 15:27:16 +01:00
Claudio Micheli 6a8b25a1b9 ll40ls: simplified probe logic and lowered max readable distance.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-09-04 15:27:16 +01:00
Claudio Micheli 59f61b3107 ll40ls: fix v3hp signal quality and modified probe to detect v3hp.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-09-04 15:27:16 +01:00
Claudio Micheli 327529d063 ll40ls: unify maximum operational distance to 35m
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-09-04 15:27:16 +01:00
Claudio Micheli fcdd2fabeb ll40ls: refactor driver start on i2c.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-09-04 15:27:16 +01:00
Claudio Micheli 5eefd9409b ll40ls: [Wingtra docet] fix for properly resetting v3 and v3hp modules.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-09-04 15:27:16 +01:00
Claudio Micheli 7799f4c68b ll40ls: fix for lidar lite v3hp
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-09-04 15:27:16 +01:00
Julian Oes 5e9cae11f8 controllib: fix for undefined sanitizer 2019-09-03 11:54:09 -05:00
Julian Oes 78d3986013 platforms: fix main function signature 2019-09-03 11:52:54 -05:00
Daniel Agar f1339038ca px4_fmu-v5_stackcheck disable roboclaw and pca9685 to reduce flash 2019-09-03 08:03:32 -07:00
Claudio Micheli b6bba0428a uavcan: fix limit actuator poll interval.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-09-03 09:35:01 -05:00
Silvan Fuhrer d5fdc55460 fmu-v5: add baro again in startup
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-09-03 13:48:34 +02:00
JaeyoungLim 09dab07071 Enable support for global position setpoints with SET_POSITION_TARGET_GLOBAL_INT (#12819) 2019-09-03 11:21:41 +02:00
Daniel Agar 9bc19fd732 IMU_GYRO_RATEMAX add common options 2019-09-02 23:53:26 -05:00
Daniel Agar f280977ed0 mavlink: update orb_publish to uORB::Publication<> 2019-09-02 23:51:54 -05:00
Daniel Agar 20e6adc4ca sensors: update orb_publish to uORB::Publication<> 2019-09-02 20:44:03 -04:00
Daniel Agar c8f77d438d load_mon: update orb_publish to uORB::Publication<> 2019-09-02 20:41:34 -04:00
Daniel Agar 4d9f2bf776 add IMU_GYRO_RATEMAX to optionally limit gyro control publication rate 2019-09-02 20:06:50 -04:00
bazooka joe 49c74ab021 add new parameter LIGHT_EN_BLINKM to start blinkm lights 2019-09-02 20:02:00 -04:00
Daniel Agar 7162000e80 fw_pos_control_l1: update orb_publish to uORB::Publication<> 2019-09-02 16:20:44 -04:00
Daniel Agar e83026f106 fw_att_control: update orb_publish to uORB::Publication<> 2019-09-02 16:20:44 -04:00
Daniel Agar b0f82ee8ac CollisionPrevention: update orb_publish to uORB::Publication<> 2019-09-02 15:35:34 -04:00
Daniel Agar 9f5f9c577e uavcan: limit actuator controls poll interval
* rather than only in UavcanEscController updates
2019-09-02 14:21:54 -04:00
Daniel Agar 6938955b8d vtol_att_control: limit state updates to input availability and always publish both FW/MC actuator controls 2019-09-02 14:13:33 -04:00
Daniel Agar 06cf801121 SENS_BARO_QNH set reboot_required
- fixes https://github.com/PX4/Firmware/issues/12866
2019-09-02 13:40:34 -04:00
Daniel Agar 3c8a41aff7 px4_fmu-v2 variants disable mpu9250 2019-09-02 12:42:18 -04:00
Daniel Agar 0c11ab1e5e Update submodule mavlink v2.0 to latest Mon Sep 2 12:38:04 UTC 2019 (#12868)
- mavlink v2.0 in PX4/Firmware (51a0a59d2c65869a79e85d7d43c0917db2b5ff06): https://github.com/mavlink/c_library_v2/commit/e26d03dbf858d3b04babb4fe106ecc831ac9b906
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/d5d131cf710ceaa93d26884ea12de8de95804985
    - Changes: https://github.com/mavlink/c_library_v2/compare/e26d03dbf858d3b04babb4fe106ecc831ac9b906...d5d131cf710ceaa93d26884ea12de8de95804985
2019-09-02 11:53:30 -04:00
BazookaJoe1900 8a45c6145b add new parameter SENS_EN_PMW3901 to start pmw3901 optical flow 2019-09-02 11:08:51 -04:00
Julien Lecoeur 47355333ad Clarify comment 2019-09-02 10:47:40 -04:00
Julien Lecoeur ced201bdb5 IO: respect actuator_armed.prearmed flag 2019-09-02 10:47:40 -04:00
Julien Lecoeur 9c50f5ea08 Add parameter COM_PREARM_MODE
Condition to enter the prearmed state, an intermediate state between disarmed and armed
 * in which non-throttling actuators are active.
 *
 * @value 0 Disabled
 * @value 1 Safety button
 * @value 2 Always
2019-09-02 10:47:40 -04:00
Julian Kent bc58bed960 Add test for jerk reduction 2019-09-02 14:51:18 +02:00
Julian Kent 865157228f Add collision prevention velocity limitations also based on max accel/jerk 2019-09-02 14:51:18 +02:00
Mark Sauder 60e5e0821a land_detector: Add and max_altitude and timestamp validity checks to MulticopterLandDetector class. (#12681)
* Rename local camelCase vars to snake_case and control_mode -> vehicle_control_mode to match typdef with established class convention.
2019-09-02 00:30:46 -04:00
Daniel Agar c180d63441 delete accidental systemlib/param/param_new.c 2019-09-01 20:42:41 -04:00
Hamish Willee a77fc9aca9 Add docker gazebo dependencies 2019-09-01 20:18:52 -04:00
Hamish Willee ceaf134092 Change java to openjdk like docker 2019-09-01 20:18:52 -04:00
Hamish Willee 33ae0bb705 ubuntu.py: update to dual install to Python2 2019-09-01 20:18:52 -04:00
Daniel Agar 82bcfcb710 boards/px4/fmu-v5x remove alternate configs until default is complete 2019-09-01 18:48:55 -04:00
mcsauder 0817ee40f8 Add generic vtol tailsitter airframe/mixer and incorporate modifications from PR 9849 in 4001_quad_x and 13001_caipirinha_vtol. 2019-09-01 18:35:14 -04:00
Matthias Grob 328544ae2e deltaquad: remove deprecated parameter MAN_R_MAX 2019-09-01 14:56:59 -04:00
Daniel Agar 891aae0377 commander increase cpu overload threshold
* the large 20% margin is no longer appropriate now that nearly all work in the system is
scheduled (moved out of ISRs) and represented in the load percentage
 * closes https://github.com/PX4/Firmware/issues/12753
2019-09-01 14:55:05 -04:00
Daniel Agar 9aad996b04 PMW3901 add register write delay (TIME_us_TSWW) 2019-09-01 14:19:46 -04:00
Daniel Agar ab92f3ab7d pmw3901 split out header and main 2019-09-01 14:19:46 -04:00
Daniel Agar 41e544727c pmw3901 cleanup and updates
- includes updates from PixArt
2019-09-01 14:19:46 -04:00
Silvan Fuhrer ff6577ce5f EKF and AirspeedSelector: publish multiple wind estimate topic instances and log them all
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-09-01 14:05:06 -04:00
Daniel Agar 10ed88db57 VTOL airframes update legacy VT_MOT_COUNT parameter 2019-09-01 13:09:48 -04:00
BazookaJoe1900 e3b60cd9e7 rc.sensors: moved common ms5611 start to rc.board_sensors per board 2019-09-01 12:55:50 -04:00
Daniel Agar 9c6d4e28ea fxos8701cq cleanup and move to PX4Accelerometer/PX4Magnetomer 2019-09-01 12:08:52 -04:00
Daniel Agar ee9f65b38b fxos8701cq split out header and main 2019-09-01 12:08:52 -04:00
Beat Küng f0ee0b5d49 MixingOutput: make scheduling configurable
And make sure fmu calls MixingOutput::updateSubscriptions on startup even
if no mixer is loaded, so that it gets scheduled.
2019-08-31 10:05:00 -04:00
Beat Küng a2ebbe9066 pwm_limit: rename to output_limit
As there is nothing pwm-specific about it.
2019-08-31 10:05:00 -04:00
Beat Küng 1bee984bb0 MC_AIRMODE: move parameter definition to mixer_module
Makes sure that the parameter is included for the builds that need it.
2019-08-31 10:05:00 -04:00
Beat Küng 077b229655 MixingOutput: make mixer loading thread-safe 2019-08-31 10:05:00 -04:00
Beat Küng d3fb610fde mixer_module: create MixingOutput library and use in fmu
This should be a pure refactoring, no functional change.
2019-08-31 10:05:00 -04:00
Beat Küng 0ec6e79a0a fmu: remove unused _num_failsafe_set 2019-08-31 10:05:00 -04:00
Beat Küng 1d577802cf fmu: remove unused write() interface 2019-08-31 10:05:00 -04:00
Beat Küng 5b87b81b90 fmu: fix comments & documentation 2019-08-31 10:05:00 -04:00
Matthias Grob d3c7d06288 FlightTaskOrbit: don't apply yaw feed forward in circle approach
The yaw pointing towards the center makes sense since that's the approach
direction anyways. But with the yaw feed forward results in a weird looking
bias when not orbiting yet.
2019-08-31 14:25:39 +02:00
Matthias Grob 7774b150a9 FlightTaskOrbit: only reapproach circle if center changed
The condition that the vehicle is more than 3m away from the circle line
was too sloppy. That often happens when the radius is changed by sticks.
A reapproach is only necessary when the center is moved and that's only
possible through the orbit command.
2019-08-31 14:25:39 +02:00
Matthias Grob cca7596bcd FlightTaskOrbit: use StraightLine library to approach circle
The initial approach to the circle to orbit on was very agressive since
it was just the controller trying to stay on the circle reaching the
limits. Now there's first an approach phase in which the vehicle reaches
the circle trajeectory in a smooth perpendicular line before starting the
orbit execution.
2019-08-31 14:25:39 +02:00
Matthias Grob 345ad06d7e StraightLine: rewrite old implementation
Before it was:
- not used anywhere
- copied from an old mission implementation version
- didn't plan in advance
- had a lot of broken cases
- dependent on a lot of parameters

I'm starting with a new relatively simple implementation that works as
expected for a minimum viable implementation and can be improved over time.
The first version is used to approach the circle path in Orbit mode to
verify the interface and get testing such that it gets eventually used
everywhere.
2019-08-31 14:25:39 +02:00
Daniel Agar 78ef8aab2d STACK_MAIN increase default 1024 -> 2048 2019-08-30 19:11:51 -07:00
kritz 9ed2daef48 Fixing and simplifying mavlink odometry handling (#12793)
* Fixing and simplify mavlink odometry
2019-08-30 06:33:13 -07:00
Beat Küng 43fdcd7876 px4_middleware: remove that header and move px4::init to px4_init.h
delete include:
for i in $(grep -rl 'px4_middleware.h' src platforms); do sed -i '/#include <px4_middleware.h/d' $i; done
2019-08-30 07:59:44 +02:00
Beat Küng f32abe8534 src/platforms: move remaining source files to platforms/common 2019-08-30 07:59:44 +02:00
Beat Küng f8e0441e7b src/platforms/common: move to platforms/common
Script to update include paths:
for i in $(grep -rl 'include <px4_work_queue' src platforms); do sed -i 's/#include <px4_work_queue/#include <px4_platform_common\/px4_work_queue/' $i; done
2019-08-30 07:59:44 +02:00
Beat Küng 5d0e72040c src/platforms/posix: move to platforms/posix/src/px4/common and src/drivers/driver_framework_wrapper 2019-08-30 07:59:44 +02:00
Beat Küng fa8165a1c3 platforms/posix/src: move to platforms/posix/src/px4/common 2019-08-30 07:59:44 +02:00
Beat Küng 8cbb3852ba src/platforms/qurt: move to src/drivers 2019-08-30 07:59:44 +02:00
Beat Küng 3bdfd8ce8d ToneAlarmInterface: move to drivers/drv_tone_alarm
It belongs there since it's not a library providing the implementation, but
just declaring the interface.
2019-08-30 07:59:44 +02:00
Beat Küng f3fccf53f6 src/drivers/{kinetis,stm32}: move to arch-specific directories 2019-08-30 07:59:44 +02:00
Beat Küng 3003e7d0fc drv_led_pwm: move to arch-specific directory 2019-08-30 07:59:44 +02:00
Beat Küng bd1b267baa NuttX hrt: move into arch-specific directory 2019-08-30 07:59:44 +02:00
Beat Küng 1cb6c36a00 adc: refactor into arch-specific directories 2019-08-30 07:59:44 +02:00
Beat Küng ab43a83bed platform: restructure (NuttX) architecture-specific code
updated: tone_alarm, px4io_serial, px4_micro_hal
2019-08-30 07:59:44 +02:00
Daniel Agar 2fa3ee9336 Jenkins hardware add Modal AI v5m/v5x 2019-08-30 00:40:22 -04:00
Silvan Fuhrer db4b4719c3 BabyShark VTOL: update config file
- increased transition throttle
 - enable airmode
 - increased max roll angle

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-29 09:58:20 -04:00
bresch fe73cef224 TestVelocitySmoothing - Split time synchronization and final state checks into two different test functions
Also improve the comments
2019-08-29 15:20:53 +02:00
bresch 94d15931f2 TestVelocitySmoothing - Remove useless function override, use ceil instead of ceilf and remove line duplicate 2019-08-29 15:20:53 +02:00
bresch 5b82fa3a0f TestVelocitySmoothing - add check for time synchronization and final acceleration 2019-08-29 15:20:53 +02:00
bresch f40d571858 VelocitySmoothing - add zero setpoint test 2019-08-29 15:20:53 +02:00
bresch c59bcc686c VelocitySmothing - Add gtest script 2019-08-29 15:20:53 +02:00
roangel 1e510f5a44 [FlightTasks] Added class enum for FlightTasks errors (#12822) 2019-08-29 14:48:52 +02:00
Daniel Agar 497a053bc1 fxas21002c fix perf counter typo and add interval 2019-08-29 00:37:24 -04:00
Daniel Agar e8dcd8c2fc cmake nuttx ignore linking target warning 2019-08-28 22:50:23 -04:00
Daniel Agar 2bb00e1f28 Jenkins snapdragon always pass sanity check for now 2019-08-28 21:49:40 -04:00
PX4 Build Bot 511438d6ef Update submodule matrix to latest Thu Aug 29 00:42:01 UTC 2019
- matrix in PX4/Firmware (341c0ae739753db98dcd0711e91f621c1666b16d): https://github.com/PX4/Matrix/commit/56b069956da141da244926ed7000e89b2ba6c731
    - matrix current upstream: https://github.com/PX4/Matrix/commit/cc084e0791535e8426780e6a4f05794804db1b82
    - Changes: https://github.com/PX4/Matrix/compare/56b069956da141da244926ed7000e89b2ba6c731...cc084e0791535e8426780e6a4f05794804db1b82

    cc084e0 2019-08-26 Martina Rivizzigno - matrix: add method to check all values are nan (#82)
84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
2019-08-28 21:45:09 -04:00
Daniel Agar 690aeef186 drivers/gps: increase task stack 2019-08-28 21:20:45 -04:00
Daniel Agar 3ee78cb36a safety_button set STACK_MAIN 2019-08-28 21:20:45 -04:00
Daniel Agar aebf244464 mc_pos_control: takeoff fix implicit switch fallthrough 2019-08-28 18:16:28 -04:00
Daniel Agar 5a5e15d384 Update submodule mavlink v2.0 to latest Wed Aug 28 15:06:44 UTC 2019
- mavlink v2.0 in PX4/Firmware (f0881530b255eb6f7cdbbed12d8da453e59f09dc): https://github.com/mavlink/c_library_v2/commit/dc26ccd71dcb0138b23176233eade1c04a09b462
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/e26d03dbf858d3b04babb4fe106ecc831ac9b906
    - Changes: https://github.com/mavlink/c_library_v2/compare/dc26ccd71dcb0138b23176233eade1c04a09b462...e26d03dbf858d3b04babb4fe106ecc831ac9b906
2019-08-28 13:31:39 -04:00
Daniel Agar 0c736fc98b Jenkins add bloaty SITL and disable ccache 2019-08-28 12:22:39 -04:00
Daniel Agar 7ee1043932 gitattributes *.bin, *.pdf, and *.png are binary
* fixes #12818
2019-08-28 11:01:35 -04:00
roangel e50dd7c364 replay: close replay log file after replay is finished, then exit (#11264) 2019-08-28 08:13:50 +02:00
Daniel Agar a20b508d7e gitignore remove core 2019-08-27 08:59:48 -04:00
Daniel Agar 2f10c315b5 listener print all instances by default 2019-08-26 16:07:41 +02:00
TSC21 693d89583d RTPS: add check for ID space 2019-08-25 23:04:09 +01:00
TSC21 1fa43a707f uorb_rtps_message_ids: enlarge id space for base type msgs 2019-08-25 23:04:09 +01:00
TSC21 062b693fea uorb_rtps_classifier: improve way to check base type of alias 2019-08-25 23:04:09 +01:00
TSC21 ac6ee972d3 airspeed_validated: move it out of the alias space 2019-08-25 23:04:09 +01:00
Julien Lecoeur 32fb4a9585 px4io: force io firmware build
This fixes incremental build of the px4io firmware on targets that use the px4io driver.

fixes #11042
2019-08-25 09:48:50 -04:00
Daniel Agar b1d59c8817 px4fmu split safety button into new driver 2019-08-24 17:14:17 -04:00
alessandro 2cb26dd5f5 GPS: Prevent injection from choking the driver (#12710)
Sending a continuous stream of injection messages can cause the
GPS driver to get stuck indefinitely in the handling loop.
2019-08-23 19:12:20 -04:00
Hyon Lim 0262a699c1 UVify Core board support and airframes (Draco, Draco-R, IFO) (#12337)
* also includes minor changes to make it easy to keep in sync with px4_fmu-v4
2019-08-23 17:02:25 -04:00
Claudio Micheli ec5d36d9c7 UAVCAN esc: relax threshold for detecting offline escs.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-23 11:40:53 -04:00
Claudio Micheli f3eafdc296 Fix wrong initialization of PWM_AUX_RATE.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-23 15:37:57 +02:00
Julian Oes a7c541d7e2 version: more tests to check tags with - prefix 2019-08-23 13:18:52 +02:00
Julian Oes 3fa3cbd28a version: add beta tag
This adds the "beta" tag and adds a dash before "rc" or "beta".
2019-08-23 13:18:52 +02:00
Julian Oes c3529baa5b jMAVSim: disable GUI using HEADLESS=1
@katzfey added the option to run jMAVSim without GUI. Now we just need
to read the HEADLESS env variable to use it.
2019-08-23 09:27:42 +02:00
Daniel Agar 3c0f4f9ace Jenkins hardware snapdragon build with CCACHE_BASEDIR and dump logs 2019-08-22 16:20:39 -04:00
Daniel Agar 331b533b3d Jenkins hardware linux add CCACHE_BASEDIR for rpi build 2019-08-22 15:46:39 -04:00
Daniel Agar e7e477962c snapdragon fix sanity test and add to Jenkins hardware 2019-08-22 15:11:32 -04:00
Daniel Agar b45f459ef1 Jenkins add linux (raspberry pi) build and test 2019-08-22 15:09:04 -04:00
Julian Oes 68078795c0 px_update_git_header.py: allow -beta/-rc in tag
This changes two things:
- This adds "-beta" as a valid tag suffix.
- This changes "rc" without "-" to "-rc". "rc" without is now described
  as deprecated and with "-rc" is preferred.
2019-08-22 18:45:50 +02:00
bresch f4b40865af SmoothVel - Fix altitude lock logic.
It was broken because _velocity_setpoint is used for input and output
and was assumed to be the input at a place where it was already overwitten
To clarify this, the input setpoint is renamed "target"
2019-08-22 16:43:41 +02:00
Julian Oes dd2d5c029f platforms: match usb-Hex_ProfiCNC device (#12772)
This means that we are able to detect and flash the Pixhawk Cube Black.
2019-08-22 01:32:39 -07:00
Todd Colten b55ae09f00 FW: set default RTL_TYPE = 1 for fixed wing
This change adds the line "param set RTL_TYPE 1" to the default init scripts for fixed wing.  Similar to the other PR that sets default RTL_TYPE=1 for VTOLs, RTL_TYPE=1 should be default for normal fixed wings as well.  Reference: https://github.com/PX4/Firmware/pull/12746/files
2019-08-22 08:47:50 +02:00
JaeyoungLim 950dbc1d2e Rover: Enable Offboard support for Rover position control 2019-08-21 12:04:19 -04:00
Daniel Agar ccdc2dffa9 WQ decrease att_pos_ctrl stack 2019-08-21 11:59:50 -04:00
Julien Lecoeur 7fa885c7b3 Document the behaviour of TERMINATE and LOCKDOWN in comments 2019-08-21 07:56:20 -07:00
Julien Lecoeur 85c2e7d65d Offboard failsafe actions: cleanup and move to dedicated functions 2019-08-21 07:56:20 -07:00
Julien Lecoeur 84eeacfb38 Offboard failsafe actions: add DISABLED, LOCKDOWN and TERMINATE options 2019-08-21 07:56:20 -07:00
Julien Lecoeur 4c9288d993 Commander: cleanup COM_POSCTL_NAVL parameter
- move to px4::params
- use enum
2019-08-21 07:56:20 -07:00
Julien Lecoeur 907b6ccf46 fmu: fix implicit fallthrough 2019-08-21 07:56:20 -07:00
Julien Lecoeur d41f72f092 Re-enable implicit-fallthrough warning 2019-08-21 07:56:20 -07:00
Beat Küng 7f6a9e587f logger: fix multiple format definitions for multi-instance topics
With https://github.com/PX4/Firmware/pull/12123 all multi-instance topics
lead to repeated format definitions in the ULog file.
2019-08-21 10:47:31 -04:00
Julian Kent 5c68880b56 Reset parameters in test setup, not teardown 2019-08-21 14:53:41 +02:00
Julian Kent ddd4181b39 Don't run each functional test in a different process 2019-08-21 14:53:41 +02:00
Julian Kent 63140f1d61 Do a single setup of uORB/Parameters instead of once every test 2019-08-21 14:53:41 +02:00
Jaeyoung-Lim 914417f580 Enable offboard local position setpoints for fixed wing position control 2019-08-21 12:12:29 +02:00
Silvan Fuhrer 536f073d02 VTOL: set RTL_TYPE default for VTOL to 1 (return to home via mission landing if available) 2019-08-21 10:15:06 +02:00
Silvan Fuhrer 8a8cc3b52b Navigator: VTOL: set heading of transition of a VTOL_TAKEOFF to the VTOL_TAKEOFF waypoint (and enforce heading)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-21 10:08:04 +02:00
Silvan Fuhrer b1d38ee050 Navigator: VTOL: fix mission yawing timeout (MIS_YAW_TMT)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-21 10:08:04 +02:00
Silvan Fuhrer ab28f1e4f7 Navigator: VTOL: disable weather vane during yaw aligning before front transition
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-21 10:08:04 +02:00
baumanta af0d63250c check velocity_setpoint instead of sticks in altitude mode 2019-08-21 10:02:40 +02:00
baumanta d168d5049f check vel_setpoint instead of stick input for position lock 2019-08-21 10:02:40 +02:00
Silvan Fuhrer 5a736c9af8 update babyshark VTOl config
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-21 05:23:25 +02:00
Daniel Agar 5d813224c8 PX4 SPI default to thread locking mode 2019-08-20 21:36:21 -04:00
Daniel Agar 7d248e0f45 px4fmu: move to WQ with uORB callback scheduling (#12224) 2019-08-20 20:24:12 -04:00
Daniel Agar b439e08e24 tone_alarm move to uORB::Subscription 2019-08-20 19:44:03 -04:00
Daniel Agar 5ae408382b led drivers and controller move to uORB::Subscription 2019-08-20 14:03:23 -04:00
Daniel Agar 41dee3875e VTOL: only run on actuator publications corresponding to VTOL mode 2019-08-20 13:50:34 -04:00
Tanja Baumann be233f6bc7 Collision Prevention: don't allow moving outside sensor FOV (#12741)
* don't allow moving outside FOV

* Update parameters in tests
2019-08-20 17:01:13 +02:00
Daniel Agar d38dfcfcd3 uORB::Subscription fix initialization but not yet published case
- otherwise uORB::Subscription will erroneously report published after the first successful initialization of an unpublished topic
2019-08-20 10:28:09 -04:00
Daniel Agar 6cf55ac83a av_x-v1 fix timer_config clock bit 2019-08-19 15:22:08 -04:00
Daniel Agar 737f5d4e3d px4io fix code style 2019-08-19 15:11:39 -04:00
dlwalter 310fd80405 added logic to encode NAN as INT16_MAX to transfer to IO from FMU 2019-08-19 21:08:11 +02:00
Hamish Willee c1c253d9be TRIG_PINS: clarify TRIG_PINS on FMU (#12714) 2019-08-19 14:45:59 +02:00
garfieldG 1958275495 drivers/boards/common: now checks if board has "px4-io" in its name instead of just "io" 2019-08-19 08:45:42 -04:00
Beat Küng a7eed520b4 commander: refactor module usage output 2019-08-19 10:54:56 +02:00
Beat Küng d64d3170c0 commander unit tests: enable preflight checks
- the last check expects pre_arm to run so we need to enable the
  preflight checks. This is closer to the real system.
- as a result we need to enable HIL for other tests so that the sensors
  are not checked.
2019-08-19 10:54:56 +02:00
Beat Küng 878ed8136c commander: add 'commander arm -f' command to force arming
This allows to bypass preflight and prearm checks.
During development there are regular cases where I just want to arm the
board/vehicle no matter what, and the preflight checks are guaranteed to
fail (e.g. sensors uncalibrated, inconsistent, powered via USB, etc.).
Allowing an easy and quick way to arm (assuming you know what you are
doing) helps to speed up development considerably and is less frustrating.
2019-08-19 10:54:56 +02:00
Beat Küng b8dba34fd0 commander arming_state_transition: do not call prearm_check if !fRunPreArmChecks
Reason: if you don't want preflight checks, you don't want prearm checks
either (these are the circuit breakers, like usb connected check).

The other changes are cleanup and rework of operations.

In most cases, arming_state_transition is called with fRunPreArmChecks set
to true, so no change in behavior.

The cases with fRunPreArmChecks=false are:
- unit tests
- in_arming_grace_period=true (quick arming after disarm)
- VEHICLE_CMD_PREFLIGHT_CALIBRATION (does not transition to armed)
2019-08-19 10:54:56 +02:00
Daniel Agar f9f2afd856 add .gitattributes to force all line endings to LF
- this improves the windows development experience when moving between cygwin, WSL, and native tools
 - cmd and bat files are left alone (we don't currently have any)
2019-08-18 14:13:26 -04:00
Daniel Agar 646519fa0d vscode disable selection drag and drop 2019-08-18 12:59:03 -04:00
Daniel Agar 24041370c0 vscode github pull request default merge method squash 2019-08-18 12:59:03 -04:00
Daniel Agar 3c33962e78 vscode disable telemetry and experiments 2019-08-18 12:59:03 -04:00
Daniel Agar 404984c355 vscode settings sort git ignoreLimitWarning 2019-08-18 12:59:03 -04:00
Daniel Agar 929b48099e vscode files watcher exclude build folder 2019-08-18 12:59:03 -04:00
Daniel Agar 6515c11048 vscode make astyle default formatter 2019-08-18 12:59:03 -04:00
Daniel Agar f3aba02654 vscode recommended extensions update docker and ros 2019-08-17 20:12:34 -04:00
Daniel Agar 24764c676e Jenkins hardware run logger and attempt to stop modules 2019-08-17 13:43:10 -04:00
Daniel Agar 67644e29b7 Jenkins hardware print AUX pwm info 2019-08-17 13:43:10 -04:00
Daniel Agar b9fc3ed2ab Jenkins hardware select airframe 4001 on fmu-v4 2019-08-17 13:43:10 -04:00
Daniel Agar 17c46623f9 Jenkins hardware default airframe 4001 -> 13000 (run all controllers) 2019-08-17 11:03:26 -04:00
Daniel Agar b8cdec65cc Jenkins hardware target general px4_fmu-v5 2019-08-17 11:03:26 -04:00
Daniel Agar 7adc43b795 px4_fmu-v5: add critical section monitor build (#12724) 2019-08-16 21:48:09 -04:00
Daniel Agar acc7067596 Jenkins hardware run adc test 2019-08-16 19:05:55 -04:00
Daniel Agar 76b9198522 kinetis/adc move to new WQ 2019-08-16 19:05:55 -04:00
Daniel Agar 746f13d2d4 stm32/adc move to new WQ 2019-08-16 19:05:55 -04:00
Daniel Agar 6e7e2b6e3b px4_fmu-v5: add irqmonitor build (#12723) 2019-08-16 19:01:16 -04:00
fghanei b28dda3926 rpi_rc_in: fix typo that was causing build to fail rpi 2019-08-16 15:52:49 -04:00
Daniel Agar 48f5ab2896 Update submodule mavlink v2.0 to latest Fri Aug 16 12:37:56 UTC 2019 (#12717)
- mavlink v2.0 in PX4/Firmware (be3d09c700): https://github.com/mavlink/c_library_v2/commit/0385f82286df78d51b06e5e325b13e2411ba2170
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/dc26ccd71dcb0138b23176233eade1c04a09b462
    - Changes: https://github.com/mavlink/c_library_v2/compare/0385f82286df78d51b06e5e325b13e2411ba2170...dc26ccd71dcb0138b23176233eade1c04a09b462

    dc26ccd 2019-08-15 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/e5597b68bd5a98bf689aa056c623da480e7ef17a
2019-08-16 14:20:45 -04:00
Daniel Agar dacaabe92e introduce sensor_gyro_control message for vehicle_angular_velocity (#12145) 2019-08-16 13:53:59 -04:00
Daniele Pettenuzzo be3d09c700 uavcan: add optical flow support (Here Flow)
* move uavcan dsdlc generation to module
 * 20200.Measurement.uavcan sync with upstream project (https://github.com/OpenMotorDrive/flow/blob/master/dsdl/com/hex/equipment/flow/20200.Measurement.uavcan)

Signed-off-by: DanielePettenuzzo <daniele@px4.io>
2019-08-15 12:22:29 -04:00
Mathieu Bresciani dab66e92d3 Fix typo 2019-08-15 14:31:23 +02:00
Dennis Mannhart bf25c462b2 Orbit failsafe: switch internal_state to Posctrl such that Manual-Positionctrl is activated after failsafe recovery. This is needed because Orbit can only be invoked via vehicle_command msg. 2019-08-15 14:31:23 +02:00
Daniele Pettenuzzo 82ecf4d942 motor_ramp: set fmu in test mode and cleanup (#11249)
and restore pwm min after test
2019-08-15 09:42:07 +02:00
mcsauder d4fedca1ee Rename _accel_horz_lp -> _xy_accel_filtered to standardize naming, use time literal, and delete unneeded #includes in the FixedwingLandDetector class. 2019-08-14 23:10:20 -04:00
Martina 0414d59ee9 mavlink_main: stream OBSTACLE_DISTANCE to GCS 2019-08-14 13:32:15 -04:00
Julian Oes 82bee2bf54 mavlink: match commands aimed at any sysid/compid
When we send a command to any sysid or any compid, we need to match an
ack from a specific sysid or compid. If we don't do that, we keep
sending retransmissions and eventually time out.
2019-08-14 13:29:07 -04:00
Julian Oes a4fb18a6c4 commander: fix arming auth param translation
The int32 param COM_ARM_AUTH is mapped to a packed struct. However, this
struct was not actually packed (anymore) and therefore the values were
applied incorrectly.

I fixed this by applying the packed attribute. By using a union with a
int32_t I could rid of the warning about address-of-packed-member.
2019-08-14 13:29:07 -04:00
Daniel Agar b7f0db62ba mRo Control Zero F7 initial board support 2019-08-14 13:13:27 -04:00
Beat Küng 5cadb0aab1 px_mkfw: add git commit hash to .px4 file 2019-08-14 12:37:20 -04:00
mcsauder 9e055e9b21 Implement ModuleParams inheritance in the VtolLandDetector class. Requires PR #12356. 2019-08-14 11:58:14 -04:00
Jimmy Johnson 9e3493bd6e Update commander_params.c
Addressing parameter description syntax
2019-08-14 14:17:33 +02:00
Jimmy Johnson 3ab5932adf updating pre-takeoff and landding values to defaults 2019-08-14 14:17:33 +02:00
Jimmy Johnson 963467b4df splitting preflight and land disarm times into 2 parameters 2019-08-14 14:17:33 +02:00
Mark Owen e25db01620 Mavlink: Fix forwarding of messages with target system/component id (#12559)
Mavlink does not correctly forward messages that have the target_system or target_component routing fields in the message.

Some investigation revealed that the Mavlink::forward_message function is incorrectly utilizing the mavlink_msg_entry_t.target_system_ofs and mavlink_msg_entry_t.target_component_ofs fields. These offsets are intended to be used relative to the start of the message payload. But, as implemented, these offsets are incorrectly being used relative to the start of the message. This pull-request corrects that problem.

I also correctly made use of the mavlink_msg_entry_t.flags field to determine if a message contains a target_system or target component field. The previous check incorrectly assumed that they would always be non-zero if present.

Signed-off-by: Mark Owen <maowen801@gmail.com>
2019-08-13 07:16:09 -07:00
Beat Küng 166639be3a logger: unconditionally call _writer.notify()
The file writer thread could get into a state where it blocked infinitely
on pthread_cond_wait() (or rather until the logging stops).

This is very rare and the following conditions must be met:
- the buffer is almost empty (<4KB filled), so that the writer thread does
  not write anything.
- an fsync call is scheduled (happens once every second)
- the fsync call takes a long time (several 100ms), during which time the
  complete log buffer fills up.

The main thread would then get into dropout state where it does not call
_writer.notify() anymore.

Notifying the writer thread on every loop update of the main thread fixes
that.

It does not increase resource usage.
2019-08-12 08:07:37 +02:00
Mark Sauder 6abf2203a3 sensors: uniform initialization and whitespace formatting in voted_sensors_update.h 2019-08-10 02:14:22 -04:00
Daniel Agar 6413525645 uORB::PublicationQueued don't unadvertise on destruction (#12674)
* this is a bit of a hack for vehicle_command and vehicle_command_ack usage
2019-08-09 12:45:02 -04:00
Daniel Agar b5a01532ae vtol_att_control move to WQ with uORB callback scheduling (#12229)
* add perf counters for cycle time and interval
2019-08-09 12:44:11 -04:00
jie.zhang decb9a8982 mc_pos_control_main: Fixed missing semicolon 2019-08-09 17:00:43 +02:00
Julian Kent d70b024ec7 GTest functional tests that include parameters and uORB messaging (#12521)
* Add kdevelop to gitignore

* Add test stubs

* Rename px4_add_gtest to px4_add_unit_gtest

* Add infrastructure to run functional tests

* Add example tests with parameters and uorb messages

* Fix memory issues in destructors in uORB manager and CDev

* Add a more real-world test of the collision prevention
2019-08-09 15:10:09 +02:00
bresch 4eb9c7d812 Create TrajMath library and move waypoint speed calculations in it 2019-08-09 12:04:48 +02:00
bresch b1698b78bc AutoSmoothVel - scale down acc_hor using traj_p parameter in the computation of the maximum waypoint entrance speed 2019-08-09 12:04:48 +02:00
bresch de10f1e04d MC auto - Modify yaw_sp_aligned to take mis_yaw_error tolerance.
Add check for this flag in AutoLine
2019-08-09 12:04:48 +02:00
Dennis Mannhart 9e9b2ab9e8 FlightTaskAutoLine/SmoothVel: stop at waypoint if altitude is has not been reached yet 2019-08-09 12:04:48 +02:00
bresch 255c911155 AutoSmoothVel - Compute desired speed at target based on angle between previous-current and current-next waypoints
Also remove crosstrack P controller that produces overshoots when the
acceptance radius is large (crosstrack error is suddenly large at
waypoint switch).
2019-08-09 12:04:48 +02:00
Silvan Fuhrer 07895cd3b6 Airspeed Selector: resolve conflics for wind estimate topic publishing after rebase
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-09 10:55:05 +02:00
Silvan Fuhrer d129fcccd5 Omnibus: take out local_position_estimator from build as was out of flash after ecl update for airspeed selection module
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-09 10:55:05 +02:00
Silvan Fuhrer 5bc6979796 AirspeedSelector: added RTPS ID for airspeed_validated message
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-09 10:55:05 +02:00
Silvan Fuhrer cedf14e2ba Airspeed Selector: repurpose wind estimator into an airspeed (selection, validation) module.
This new airspeed module does:
  -runns an airspeed validator for every airspeed sensor present, which checks measurement validity and estimates an airspeed scale
  -selects another airspeed sensor if for the current one a failure is detected
  -estimates airspeed with groundspeed-windspeed if no valid airspeed sensor is present
  -outputs airspeed_validated topic

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-09 10:55:05 +02:00
Silvan Fuhrer 970e362e9a Increased stack of lp work queue as with new airspeed modudle it was getting low
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-09 10:55:05 +02:00
Silvan Fuhrer 50dc8aee7a Airspeed Selector: added airspeed validator class
This validator takes measurements from a single airspeed sensor and:
    -checks validity of measurement
    -can estimate an airspeed scale factor (estimation enabled with parameter setting) to accout for errors in airspeed due due placement of sensor

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-09 10:55:05 +02:00
Silvan Fuhrer 248e1818e2 Airspeed Selector: changes in airspeed library to account for new EAS state (equivalent airspeed)
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-08-09 10:55:05 +02:00
Claudio Micheli aae16cc594 uavcan esc: use time literals for timeout checks.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-09 09:41:17 +02:00
Claudio Micheli 2eb9fb9ed6 Commander: move esc_status as local variable.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-09 09:41:17 +02:00
Claudio Micheli 5fe7992af5 mixer_group: improved get_multirotor_count () code readbility.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-09 09:41:17 +02:00
Claudio Micheli 09d79b221f Simplified esc_status healthiness logic.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-09 09:41:17 +02:00
Claudio Micheli 8a2d05be4f Improved code comment for condition_escs_error topic.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-09 09:41:17 +02:00
Claudio Micheli 75c336c00c uavcan_main: replaced printf messages with PX4_INFO
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-09 09:41:17 +02:00
Claudio Micheli 1e04d718f6 uavcan escs: Modified esc_status reporting to have _rotor_count published.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-09 09:41:17 +02:00
Claudio Micheli 187a025dfe Commander: added esc_status prearm checks
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-09 09:41:17 +02:00
Claudio Micheli d06c679252 uavcan esc: added timeout checks to escs.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-09 09:41:17 +02:00
Claudio Micheli 03637fa6f1 Added topics to esc_status and vehicle_status_flags.
Signed-off-by: Claudio Micheli <claudio@auterion.com>
2019-08-09 09:41:17 +02:00
Mark Sauder 056c8000a1 MultiCopterLandDetector: Implement ModuleParams inheritance (#12356) 2019-08-09 07:57:42 +02:00
Daniel Agar 2f222d6cbf containers/List add nullptr check 2019-08-09 07:55:13 +02:00
Daniel Agar 9481b3b232 Update submodule mavlink v2.0 to latest Fri Aug 9 02:59:05 UTC 2019 (#12669)
- mavlink v2.0 in PX4/Firmware (e8a11086eb): https://github.com/mavlink/c_library_v2/commit/72832840733f0d78cda7e2071a6bf6c7fc3f9273
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/0385f82286df78d51b06e5e325b13e2411ba2170
    - Changes: https://github.com/mavlink/c_library_v2/compare/72832840733f0d78cda7e2071a6bf6c7fc3f9273...0385f82286df78d51b06e5e325b13e2411ba2170
2019-08-09 00:15:38 -04:00
PX4 Build Bot 34ed454ea9 Update submodule ecl to latest Fri Aug 9 02:59:11 UTC 2019
- ecl in PX4/Firmware (e93e676c38bc3ce2e57c20a8dc33ffe377826903): https://github.com/PX4/ecl/commit/d38164fc8e68b740405669127138e550c3c7375c
    - ecl current upstream: https://github.com/PX4/ecl/commit/62fa464e4dd6cb5e585d23bd353aa50a469879f7
    - Changes: https://github.com/PX4/ecl/compare/d38164fc8e68b740405669127138e550c3c7375c...62fa464e4dd6cb5e585d23bd353aa50a469879f7

    62fa464 2019-07-17 RomanBapst - WindEstimator: added support for pre-set airspeed scale factor
a7d9c73 2019-07-09 Silvan Fuhrer - Wind estimator: added wind_estimator_reset state (to indicate if wind estimator was reset in last fusion-cycle)
09f29db 2019-07-02 Silvan Fuhrer - added option to fix airspeed scaling to 1
2019-08-08 23:39:43 -04:00
Daniel Agar e8a11086eb create uORB::PublicationMulti for multi publications 2019-08-08 21:01:56 -04:00
Daniel Agar 0a0c404a08 mavlink receiver move to uORB::Publication 2019-08-08 21:01:56 -04:00
David Sidrane 21782603b3 px4_fmu-v5x: add networking
* fixed dropped CONFIG_LIBC_FLOATINGPOINT=y
* fix RMII TX pinning
* update platforms/nuttx/NuttX/nuttx w/ f7 eth
2019-08-08 20:38:56 -04:00
mcsauder 887b55269a Delete whitespace to quiet githooks. 2019-08-08 18:56:26 -04:00
Daniel Agar c6aaa606da sensors angular velocity and acceleration publishers fix auto usage
- if the primary gyro or accel change this will cause the callback to be registered multiple times
2019-08-08 11:36:27 -04:00
Daniel Agar c66fc85630 fw_pos_control_l1: move to WQ with uORB callback scheduling 2019-08-07 23:13:21 -04:00
Daniel Agar cab0aee2a0 fw_att_control: move to WQ with uORB callback scheduling 2019-08-07 22:54:44 -04:00
Daniel Agar 0955fd2d58 NuttX boards reduce CONFIG_NFILE_DESCRIPTORS 54 -> 20 2019-08-07 21:23:27 -04:00
Daniel Agar e43e37cc46 fw_pos_control_l1 add new simple min groundspeed 2019-08-07 18:50:42 +02:00
Matthias Grob 161429f8c6 voted_sensors_update: refactor to camelCase function names 2019-08-07 18:44:39 +02:00
Matthias Grob 89a0a3acb6 PreflightCheck: improve output in case of mag inconsistency 2019-08-07 18:44:39 +02:00
Matthias Grob fe37ee2b7f voted_sensors_update: refactor out matrix:: because of using namespace 2019-08-07 18:44:39 +02:00
Matthias Grob 45187e1aa8 Improve magnetometer inconsistency check
To check directional difference between the magnetometer field vectors
instead of vector component difference.
2019-08-07 18:44:39 +02:00
Daniel Agar 83e532d339 logger move to uORB::SubscriptionInterval (#12123) 2019-08-07 11:02:16 -04:00
baumanta e91614c791 change angle parmeter to degrees 2019-08-07 15:29:13 +02:00
baumanta f80a539faa add unit for coll prev angle 2019-08-07 15:29:13 +02:00
baumanta 14f128b89d add parameter for detection angle 2019-08-07 15:29:13 +02:00
baumanta 150b5df7cb change size of reaction angle 2019-08-07 15:29:13 +02:00
baumanta b26d3ac9d4 no slinding in collision prevention (roll jerk fix) 2019-08-07 15:29:13 +02:00
Daniel Agar a917f22b65 sensors: create vehicle_acceleration module (#12597) 2019-08-07 05:05:48 -04:00
bresch 50fbb56737 Yaw mode 3 - Add check for minimum distance to target in MPC_YAW_MODE 3 (along trajectory) to be consistent with the other yaw modes 2019-08-07 10:30:34 +02:00
Martina 119e5e3182 Revert "CollisionPrevention only process distance_sensor updates"
This reverts commit 839787568c.
2019-08-07 04:01:50 -04:00
Daniel Agar 6e781c2289 InvenSense ICM20948 move to PX4Accelerometer, PX4Gyroscope, PX4Magnetometer helpers 2019-08-06 23:36:31 -04:00
Daniel Agar 5421ef5535 NuttX increase HPWORK and LPWORK stack by 256 bytes 2019-08-06 23:15:07 -04:00
Daniel Agar 4c329c3b4b simple circleci.com px4_fmu-v5 build & archive example 2019-08-06 19:07:21 -04:00
Daniel Agar 7b179776e2 vehicle_angular_velocity: sensor_selection callback
- needed to update the main sensor_gyro subscription if the primary
stops responding
2019-08-06 14:23:57 -04:00
Daniel Agar b945e28e08 uORB fix vehicle_angular_velocity RTPS id 2019-08-06 13:39:56 -04:00
Daniel Agar 2ad12d7977 sensors: create vehicle_angular_velocity module (#12596)
* split out filtered sensor_gyro aggregation from mc_att_control and move to wq:rate_ctrl
2019-08-06 12:55:25 -04:00
Daniel Agar bf0eaf4d54 bloaty fix master comparison
- jenkins add new sections and segments output
2019-08-06 11:57:53 -04:00
Daniel Agar 6f2d1d55f6 logger use uORB::PublicationQueued for ulog_stream
- queue depth is now set by the msg
2019-08-06 11:07:59 -04:00
Daniel Agar 5b511eaa1a logger move non-logged subscriptions to uORB::Subscription 2019-08-06 11:07:59 -04:00
Daniel Agar 9d701a077d NuttX reduce stack for interrupts, HPWORK, LPWORK 2019-08-06 11:00:55 -04:00
Daniel Agar bf474028ff px4flow add parameter to enable (SENS_EN_PX4FLOW)
- fixes https://github.com/PX4/Firmware/issues/12571
2019-08-06 10:55:35 -04:00
garfieldG d3ba9c59e0 mavlink: added check if instance mode is serial when trying to find if instance exists (#12642) 2019-08-06 10:53:07 -04:00
David Sidrane 5a1c46deeb fmuv5x:Use ADC3 for HW VER/REV detection
fmu-v5x:hrt needs to be running for ADC time out

       Fixes bug introduced in 320d2e adding platform layer.
2019-08-06 10:46:37 -04:00
David Sidrane 890f805b37 adc:Add that ability to select an ADC 2019-08-06 10:46:37 -04:00
David Sidrane 0ebb87357f fmu-v5:hrt needs to be running for ADC time out
Fixes bug introduced in 320d2e adding platform layer.
2019-08-06 10:46:37 -04:00
Daniel Agar 8f5b7de498 uORB::Subscription minor API cleanup
* the forceInit() method was combined with the existing subscribe()
 * delete unused last_update()
2019-08-06 10:28:49 -04:00
RomanBapst cfba41d2f4 posix configs: set trigger interface to mavlink as it's the only one
supported on posix

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-08-06 08:08:56 +02:00
RomanBapst cd85f584cf camera trigger: do not try to start if interface was not created
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-08-06 08:08:56 +02:00
David Sidrane f21dc82c24 Add i2cdetect to K66 2019-08-05 19:40:32 -04:00
David Sidrane e8d874cf34 i2cdetect do not exceed 100Khz 2019-08-05 19:40:32 -04:00
Daniel Agar 64f105b530 Update submodule nuttx to latest Mon Aug 5 20:30:34 UTC 2019 (#12636)
- nuttx in PX4/Firmware (be76f909beadfe80415b733c020695efb042adef): https://github.com/PX4/NuttX/commit/b4013dcd4a9ec8edf412277fa3e4dccd419089c1
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/14f4dc735a6f092b7acbf5861c0b9f1ed5e19216
    - Changes: https://github.com/PX4/NuttX/compare/b4013dcd4a9ec8edf412277fa3e4dccd419089c1...14f4dc735a6f092b7acbf5861c0b9f1ed5e19216

    14f4dc7 2019-08-05 David Sidrane - [BACKPORT] kinetis:i2c transfer ensure correct result returned
2019-08-05 13:32:46 -07:00
Daniel Agar a6777ca4f1 uORB add RTPS message id for new wheel_encoders msg 2019-08-05 12:34:48 -04:00
Martina Rivizzigno 19ad80385e ObstacleAvoidance: update empty_trajectory_waypoint 2019-08-05 16:05:40 +02:00
Martina Rivizzigno e0893c383d increase mc_pos_control stack from 1300 to 1500 2019-08-05 16:05:40 +02:00
Martina Rivizzigno d29f2ff60c ObstacleAvoidance: use hysteresis on z to check progress towards the goal 2019-08-05 16:05:40 +02:00
Martina Rivizzigno 39e59d6cc4 add point type (mavlink command associated with wp) in Obstacle Avoidance interface 2019-08-05 16:05:40 +02:00
Andrei Korigodski 4d5f922e7a commander: use shutdown_if_allowed() to check for shutdown safety
Signed-off-by: Andrei Korigodski <akorigod@gmail.com>
2019-08-05 05:55:33 -07:00
Andrei Korigodski 5133453822 vehicle_status: replace ARMING_STATE_REBOOT with ARMING_STATE_SHUTDOWN
Signed-off-by: Andrei Korigodski <akorigod@gmail.com>
2019-08-05 05:55:33 -07:00
Andrei Korigodski 4a330c6e0a commander: do not reboot on USB disconnect when armed
Signed-off-by: Andrei Korigodski <akorigod@gmail.com>
2019-08-05 05:55:33 -07:00
mcsauder 2e3926b577 Fix a corner case that prevented mavlink config streams from being indexed appropriately when USB is not connected at boot.
Break out Mavlink class constructor logic into set_instance() and set_channel() methods. and add const specifiers and default arguments to Mavlink::mavlink_open_uart().
2019-08-05 05:02:20 -07:00
Matej Frančeškin 3d993773ae Mavlink FTP: Fix for wrong component id in retry 2019-08-05 13:51:10 +02:00
RomanBapst 43d006aff2 mavlink command sender: give channels more time to request command
- if a channel receives an ack for a command, do not immediately remove the
command item from the send queue but wait until the next ack timeout occurs.
This gives other mavlink channels time to try to put identical commands into
the send queue.

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-08-05 12:07:05 +02:00
RomanBapst 71791fa8f8 mavlink_command_sender: don't try to resend command to instance which
did not request this command

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-08-05 12:07:05 +02:00
RomanBapst 807cfc8aac mavlink: fix race condition in mavlink_command_sender
- if we receive an ack for a command through a specific mavlink channel
then do not drop the corresponding command in the queue if this specific
mavlink channel did not issue the command. If we don't do this we can
end up in a situation where we associate an ack coming through a specific
mavlink channel to a command in the queue which was not requested by this mavlink channel.
Moreover, the actual command for which the ack was meant remains in the
queue and eventually triggers a timeout.

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-08-05 12:07:05 +02:00
Timothy Scott 830d576f45 Changed wheel encoder publication to multi-instance 2019-08-05 02:45:33 -07:00
Timothy Scott 3850322046 Added module.yaml and serial port configuration. 2019-08-05 02:45:33 -07:00
Timothy Scott 35dae9e285 More code cleanup 2019-08-05 02:45:33 -07:00
Timothy Scott ee5a790ecb Removed some parameters 2019-08-05 02:45:33 -07:00
Timothy Scott 834ae3128f Implemented reading speed from the Roboclaw 2019-08-05 02:45:33 -07:00
Timothy Scott 2406aa8b50 Further fixing up parameters 2019-08-05 02:45:33 -07:00
Timothy Scott 2b79684f29 Added parameters 2019-08-05 02:45:33 -07:00
Timothy Scott ffe505b76b Fixed timeout error handling 2019-08-05 02:45:33 -07:00
Timothy Scott e6dc847360 Minor cleanup 2019-08-05 02:45:33 -07:00
Timothy Scott 71067a7e2d Fixed timeout handling 2019-08-05 02:45:33 -07:00
Timothy Scott f780191c5a Fixed disarming 2019-08-05 02:45:33 -07:00
Timothy Scott b5cf8416b6 Publishing encoder message at regular intervals 2019-08-05 02:45:33 -07:00
Timothy Scott 60da26978f Ongoing encoder work 2019-08-05 02:45:33 -07:00
Timothy Scott 0b3f636603 Ongoing encoder work 2019-08-05 02:45:33 -07:00
Timothy Scott 6ea03bee58 Ongoing work to update RoboClaw driver 2019-08-05 02:45:33 -07:00
Daniel Agar cfdabb26d7 update all docker tags 2019-03-08 -> 2019-07-29 2019-08-05 00:19:18 -04:00
Daniel Agar 030508a71d cmake make bloaty available everywhere and improve output 2019-08-05 00:19:18 -04:00
Daniel Agar a2288b1e16 AV-X board_config.h fix ADIS16497 chip select 2019-08-05 00:14:03 -04:00
TSC21 618ce49479 rtps: ids: add missing aliased topics 2019-08-04 20:04:19 +01:00
TSC21 47f5b23419 rtps: generation scripts: make indexing of lists possible in both Python 2 and 3 2019-08-04 20:04:19 +01:00
Daniel Agar e69398c09f introduce uORB::PublicationQueued and transition most orb_advertise_queue usage 2019-08-04 10:08:09 -04:00
Daniel Agar 839787568c CollisionPrevention only process distance_sensor updates 2019-08-04 10:04:09 -04:00
Daniel Agar 34598fe353 mavlink uavcan parameters initialize value 2019-08-03 15:05:34 -04:00
Daniel Agar 6a6bc4be58 drivers helper classes remove empty publication (forced advertise)
- this is no longer necessary with all publications outside of ISRs
2019-08-03 14:08:45 -04:00
Daniel Agar 483280236b mavlink use all ORB battery_status instances instead of BOARD_NUMBER_BRICKS 2019-08-03 13:36:42 -04:00
Daniel Agar 991669073e Jenkins HIL run sd_bench and configure as multicopter 2019-08-03 11:22:31 -04:00
Daniel Agar dcccbbe584 Mavlink receiver ODOMETRY fix code style 2019-08-02 21:36:20 -04:00
Nick Steele b203bc15df Fix rotation of odometry velocities from body frame to local frame in the mavlink receiver odometry handler
Summary:
PX4 assumed that odometry orientation was a way to rotate data from parent frame to child frame, so to rotate child to parent, it was taking the inverse rotation of the odometry orientation,
but orientation rotates the parent frame to the child frame, whereas for data, it represents a rotation from child to parent; hence, the rotation inverse operations were removed.

Test Plan: Checked that vehicle_mocap_odometry and vehicle_local_position gave correct linear velocities. Also visualized px4 output twist in rviz.
2019-08-02 23:15:47 +01:00
Daniel Agar 77694183b2 delete position_estimator_inav 2019-08-02 17:38:28 -04:00
Karl Schwabe d301c22665 Bosch BMI088 initial driver 2019-08-02 13:38:36 -04:00
PX4 Build Bot 5f962401cb Update submodule DriverFramework to latest Fri Aug 2 08:39:05 EDT 2019
- DriverFramework in PX4/Firmware (eda49a4b63): https://github.com/PX4/DriverFramework/commit/06277ef49fb8c9fad18d56ef40e8bc9fe1655a65
    - DriverFramework current upstream: https://github.com/PX4/DriverFramework/commit/c7d2fe2d4f5954b9042af4edf7e5aeb21dbdd129
    - Changes: https://github.com/PX4/DriverFramework/compare/06277ef49fb8c9fad18d56ef40e8bc9fe1655a65...c7d2fe2d4f5954b9042af4edf7e5aeb21dbdd129

    c7d2fe2 2019-07-23 Andrii Beregovenko - Fix missing symbol from librobotcontrol
2019-08-02 10:36:38 -04:00
Timothy Scott 39a5799e65 Mavlink: fixed temperature for batteries (#12605) 2019-08-02 10:09:03 -04:00
Martina Rivizzigno 959a35b3bd add safe_landing_planner to CI 2019-08-02 09:12:02 -04:00
Martina Rivizzigno 14501dfdf2 update local_planner ci to avoidance stable release 0.3.0 2019-08-02 09:12:02 -04:00
Martina Rivizzigno c2a5fc0520 Jenkinsfile-SITL_tests: bump kinetic container to 2019-07-29 tag 2019-08-02 09:12:02 -04:00
Daniel Agar eda49a4b63 PixArt PAW3902 optical motion tracking driver (#12576) 2019-08-01 23:43:26 -04:00
Mark Sauder e0c85c8831 ll40ls: correct a write_reg issue (#12604)
* deprecate a goto statement
 * migrate to uniform initialization in LidarLite base class.
2019-08-01 23:41:05 -04:00
PX4 Build Bot 8609be28a7 Update submodule v2.0 to latest Thu Aug 1 18:09:13 EDT 2019
- v2.0 in PX4/Firmware (d0f1a551e9): https://github.com/mavlink/c_library_v2/commit/18cf6ff2fc0e51e4555b19fc31e8b06eb38bdd79
    - v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/72832840733f0d78cda7e2071a6bf6c7fc3f9273
    - Changes: https://github.com/mavlink/c_library_v2/compare/18cf6ff2fc0e51e4555b19fc31e8b06eb38bdd79...72832840733f0d78cda7e2071a6bf6c7fc3f9273

    7283284 2019-07-26 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/9c1d1feec0f2bd7ee7f408bed53f3de90a16c537
51a62d5 2019-07-23 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/06e378b91a620d20d99fe1476d57bc41e7210b18
477a5b6 2019-07-11 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/6e06b09b9ceb1d03c8f54e91494ab84901d33d9c
2a9615b 2019-07-10 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/e2c91dcc8c389a02a5e2f02b18662a951af7a33d
cd2a362 2019-07-07 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/8b75e0a5a74429c98aa0b33a8b65fe3a7384d38d
beb7890 2019-06-27 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/95031e31a5eec47dc951fc09e2939071b8cf3c2b
614164b 2019-06-27 PX4BuildBot - autogenerated headers for rev https://github.com/mavlink/mavlink/tree/595037a9fbd95ab51d84497f7d1cff3f998ba76e
2019-08-02 00:30:10 +01:00
Daniel Agar f7c9acbdab Update submodule nuttx to latest Thu Aug 1 18:09:20 EDT 2019 (#12603)
- nuttx in PX4/Firmware (210dbb5b8365eb003453695aa4711044bb6d49be): https://github.com/PX4/NuttX/commit/257e1730dca1faafdf3a694ba53da423f46d569c
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/b4013dcd4a9ec8edf412277fa3e4dccd419089c1
    - Changes: https://github.com/PX4/NuttX/compare/257e1730dca1faafdf3a694ba53da423f46d569c...b4013dcd4a9ec8edf412277fa3e4dccd419089c1

    b4013dc 2019-08-01 David Sidrane - [BACKPORT] stm32l4:serial add HW HS on UART 4 & 5
4380c12 2019-08-01 David Sidrane - [BACKPORT] stm32h7:serial add HW HS on UART 4 & 5
0ff3e6c 2019-08-01 David Sidrane - [BACKPORT] stm32:serial add HW HS on UART 4 & 5
316126f 2019-07-31 David Sidrane - [BACKPORT] stm32f7:serial add HW HS on UART 4 & 5
2019-08-01 16:14:45 -07:00
Matthias Grob d0f1a551e9 manual_contol_setpoint: fix mode slot numbering (#12578)
* This fix is necessary because usually uORB structs get initialized with
all zeros and then get filled with the fields that are actually in use.
 * The number 0 for the mode slot was already commanding to switch to the
mode in slot one even though for example the joystick input via mavlink
does not use this mechanism at all.
2019-08-01 12:27:58 -04:00
Anthony Lamping 5d986f2030 posix: add argument to change the CWD (#12482) 2019-08-01 12:25:35 -04:00
Daniel Agar 4bf9344913 camera_trigger: move to new WQ and uORB::Subscription 2019-08-01 12:24:12 -04:00
Daniel Agar bc9fb26ccd commander esc_calibration move to uORB::Subscrition 2019-07-31 20:30:05 -04:00
Burak Saruhan 7789e2de88 sensors: mag reload calibration parameters when first seen (#12586)
* fixes UAVCAN MAG calibration application after reboot
2019-07-31 15:22:59 -04:00
Daniel Agar 29c50da1f6 ll40ls: cleanup and create PX4Rangerfinder helper class (#12567) 2019-07-31 15:17:35 -04:00
dvornikov-aa e9397eeb75 ll40ls: fix LIDAR-Lite v3 initialization (#12453) 2019-07-31 13:00:30 -04:00
Matej Frančeškin 1600b0fd82 Mavlink FTP - return ENOENT when directory doesn't exist (#12589) 2019-07-31 15:22:46 +02:00
Timothy Scott eaaf66e46b INA226::init Restored return OK in trigger mode
Restore return state that was lost in e4926373e6
2019-07-31 03:20:46 -07:00
garfieldG 487addbba5 rc.autostart: add error reporting (#12527)
-Fixed bug : cd to /etc/init.d/airframes, but no cd after
-Added error report to user if value of SYS_AUTOSTART param value is incorrect
2019-07-31 07:37:40 +02:00
David Sidrane a90c87a791 px4fmu-v5x:BMI055->BMI088 (#12582) 2019-07-30 15:54:17 -07:00
David Sidrane 0300a380cf fmuv5x:Missing define PX4_SPI_BUS_SENSORS 2019-07-30 10:49:03 -04:00
David Sidrane 423dd23ff1 fmu-v5x:SPI fix Typo on SPI4 causing assertion 2019-07-30 10:49:03 -04:00
David Sidrane 25b95dcd0c px4fmu-v5x:Fix up start script
Fix commandline for bmm150
    Add 2 internal bmp388 - needs works
    Add 2 ina2662
2019-07-30 10:49:03 -04:00
David Sidrane 72c742f53d px4_fmuv5x:Update to master single wire 2019-07-30 10:49:03 -04:00
David Sidrane 7c1d616187 px4_fmuv5x:Fix GPS 2019-07-30 10:49:03 -04:00
David Sidrane 7eb7db476c px4_fmuv5x:Fixed SDMMC DMA 2019-07-30 10:49:03 -04:00
David Sidrane 13e777c2ce px4_fmuv5x:Use slot 0 with SDMMC2 2019-07-30 10:49:03 -04:00
Daniel Agar 0e949a36ee task_stack_info increase task_name length to match NuttX CONFIG_TASK_NAME_SIZE 2019-07-30 10:47:10 -04:00
Daniel Agar 0dc8119c89 listener print strings 2019-07-30 10:47:10 -04:00
PX4 Build Bot ca74b3fef1 Update submodule nuttx to latest Mon Jul 29 12:38:24 UTC 2019
- nuttx in PX4/Firmware (0654fdcf0ec7e45cc1e1ca5cc38de6c5e36417bc): https://github.com/PX4/NuttX/commit/feb5b6f1743fc3376008013f7dbd16dbc8501f10
    - nuttx current upstream: https://github.com/PX4/NuttX/commit/257e1730dca1faafdf3a694ba53da423f46d569c
    - Changes: https://github.com/PX4/NuttX/compare/feb5b6f1743fc3376008013f7dbd16dbc8501f10...257e1730dca1faafdf3a694ba53da423f46d569c

    257e173 2019-07-26 David Sidrane - [BACKPORT] stm32f7:If only one SDMMC it is slot 0
2019-07-29 10:59:28 -04:00
Daniel Agar 75531125a2 lsm303d split out header and main 2019-07-29 10:57:51 -04:00
Daniel Agar 87200d7954 lsm303d driver move to PX4Accelerometer/PX4Magnetometer and cleanup 2019-07-29 10:57:51 -04:00
Daniel Agar 203d9327ee osd/atxxxx move to new WQ and uORB::Subscription 2019-07-29 10:52:33 -04:00
RomanBapst b75d2ce982 set trajectory generating flight task as default (MPC_POS_MODE = 3)
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-29 10:37:26 -04:00
RomanBapst a8071589bc increase default fixed wing rate controller I term
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-29 10:37:26 -04:00
RomanBapst 77fd290b0c added default expo for yaw and x/y/z velocity demand in position mode
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-29 10:37:26 -04:00
RomanBapst 81ae85015f changed defaults of MPC acceleration limit parameters
- vehicle will fly less aggressive
- it does not make sense to set the lower acceleration limit to something
that exceeds gravity if most of the vehicles do not support reverse thrust

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-29 10:37:26 -04:00
RomanBapst a5d3e10c67 MPC_MAN_Y_MAX: changed default from 200 to 150 deg/s
- we have set the maximum yaw-rate MC_YAWRATE_MAX to 200 degrees and it
makes senses to leave a bit of margin between what the user can demand
and what the limits of the vehicle are

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-29 10:37:26 -04:00
RomanBapst f0cdd9be60 MPC_Z_VEL_I: changed default from 0.02 to 0.1
- generally better attitude tracking
- much better altitude control immediately after takeoff (hover throttle offset)
- faster landing detection

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-29 10:37:26 -04:00
Daniel Agar be99d2f111 sih: fix code style 2019-07-28 11:18:02 -04:00
Daniel Agar 09eaef82f6 sih: move to PX4Accelerometer/PX4Gyroscope/PX4Magnetometer/PX4Barometer helpers 2019-07-28 11:18:02 -04:00
Mark Sauder f432f74611 ulanding: refactor driver to utilize ScheduledWorkQueue class inheritance (#11894)
* Migrate variable initialization from constructor list to declaration uniform initialization, format whitespace, alphabetize/group/order variables and methods in ulanding.cpp.

* Refactor the uLanding driver to utilize the ScheduledWorkQueue.
2019-07-28 10:51:01 -04:00
Anthony Lamping ff8e70f6b3 jenkins: archive catkin test logs on failure 2019-07-28 10:25:36 -04:00
Daniel Agar 97445b60aa commander preflightcheck update orb usage to uORB::SubscriptionData 2019-07-28 10:22:47 -04:00
Daniel Agar 1d191cc141 px4flow driver move to new WQ and cleanup 2019-07-26 20:03:21 -04:00
Daniel Agar a462bfeb53 vscode add v5x variant (for cmake configure) 2019-07-26 12:59:27 -04:00
PX4 Build Bot 36534d5bab Update submodule ecl to latest Fri Jul 26 12:38:35 UTC 2019
- ecl in PX4/Firmware (83316cf7b0484e7ba7f9b61201dea7215185da49): https://github.com/PX4/ecl/commit/e1751188fd15b799cbfae86bd7373bb91206069b
    - ecl current upstream: https://github.com/PX4/ecl/commit/d38164fc8e68b740405669127138e550c3c7375c
    - Changes: https://github.com/PX4/ecl/compare/e1751188fd15b799cbfae86bd7373bb91206069b...d38164fc8e68b740405669127138e550c3c7375c

    d38164f 2019-07-21 Jaeyoung-Lim - Fix flag for initialization
2019-07-26 12:04:07 -04:00
TSC21 eb951ede6a urtps templates: minor cleanup 2019-07-26 15:05:54 +02:00
TSC21 11a28665b7 px_generate_uorb_topic_files: cleanup uneeded conditions 2019-07-26 15:05:54 +02:00
TSC21 85bcfd7d72 generate_microRTPS_bridge: remove commented code 2019-07-26 15:05:54 +02:00
TSC21 2b4c878e77 rebase: sync up submodules 2019-07-26 15:05:54 +02:00
TSC21 c15e54445e increase cutoff margin for alias matching 2019-07-26 15:05:54 +02:00
TSC21 5b2d952e4b add checker for multitopic msg naming 2019-07-26 15:05:54 +02:00
TSC21 3d9f83a4f2 microRTPS_bridge: structural change to make possible to generate pub/sub code for multi-topics/aliased msgs 2019-07-26 15:05:54 +02:00
TSC21 a747116eab microRTPS bridge: make mandatory that all the uORB messages have their RTPS id 2019-07-26 15:05:54 +02:00
Julian Oes 98dfa30838 commander: fix disarming for rovers
We have to ignore the landed flag for rovers, it doesn't really apply
for them.
2019-07-26 02:52:38 -07:00
Julian Oes 308d91e5ff commander: prevent potential disarms in-air
This fixes the terrifying case where the drone disarms in-air just
because it receives a MAVLink disarm command. We now check param2 for a
magic number which enforces arming/disarming.

This is added to the mavlink protocol in:
https://github.com/mavlink/mavlink/pull/1162
2019-07-26 02:52:38 -07:00
Daniel Agar 71613ac631 Jenkins fetch all tags 2019-07-25 11:14:16 -04:00
Timothy Scott 57352ae3bd Reinstated rover CI test 2019-07-25 10:53:39 -04:00
Timothy Scott 80f2603b17 Fixed timing of rover pos control 2019-07-25 10:53:39 -04:00
Beat Küng 4f090980ab kakutef7 board_config: remove usb valid defines
Otherwise 'system_power' gets published with voltage5v_v = 0, as there is
no 5V sensing pin, leading to Avionics Power Low preflight check failures.
2019-07-25 10:38:57 -04:00
Beat Küng 72ddf3e0aa tune_control: use orb queue advertisement consistently 2019-07-25 10:38:57 -04:00
Beat Küng c869cb0ea5 validate_yaml.py: fix for python3
RuntimeError: dictionary changed size during iteration
2019-07-25 10:38:57 -04:00
Beat Küng 8e5aaff76b airframes: add Kopis 2 2019-07-25 10:38:57 -04:00
Matthias Grob 5afa404b7f appveyor: fix PX4 version format check
by removing shallow clone such that we can infer the version from the
last tag
2019-07-25 10:36:58 -04:00
David Sidrane e296297ab7 Revert "hotfix for logger: use '%i' instead of '%zu'"
This reverts commit e6aa035209.
  Root cause was fixe in Nuttx and backported
2019-07-25 05:28:46 -07:00
David Sidrane df0599913e Firmwarte master with nuttx printf backport 2019-07-25 05:28:46 -07:00
RomanBapst c0053409a3 ak09916: fixed driver not reporting magnetometer as external
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-25 13:17:08 +02:00
Hamish Willee 2b8337e5e2 Add units for EKF2_RNG_A_HMAX and EKF2_RNG_A_VMAX (#12545) 2019-07-25 08:09:35 +02:00
Julien Lecoeur 8f47535b54 ROMFS: fix airframe incremental build 2019-07-24 05:40:53 -07:00
Julien Lecoeur 24c2846750 ROMFS: add explicit dependency to parser scripts 2019-07-24 05:40:53 -07:00
RomanBapst 2fbb70d9ca mc_att_control: output zero throttle in manual mode when landed
- MPC_MANTHR_MIN is used as minimum throttle in attitude control mode when
the vehicle is in air. This is useful to retain some control around roll and
pitch axis if airmode is not enabled and the user demands zero throttle.
However, when the vehicle is landed there is not need to keep the throttle
at a higher value than zero.

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-23 17:12:45 +02:00
Beat Küng ac5669deb4 CI: ensure 'git fetch --tags' is executed for all Firmware builds 2019-07-23 13:16:43 +02:00
Beat Küng 05ff7bb731 version: validate format of the git tag
This fails the build if a wrong version tag is used.
A wrong tag leads to wrong reporting in QGC, and incorrect error messages
about minimum required PX4 version.
It also leads to wrong statistics on Flight Review.
2019-07-23 13:16:43 +02:00
Timothy Scott 2ed8ebf889 rover_pos_control: refactor to ModuleBase and use C++ Param API 2019-07-23 11:16:52 +02:00
Julien Lecoeur e23e3d7bae Airframe parser: add docs 2019-07-22 13:02:45 +02:00
Julien Lecoeur daeba4e75f Add airframe .post scripts on NuttX targets 2019-07-22 13:02:45 +02:00
Matthias Grob e964af9262 commander_params: enable RC override by default
It doesn't affect fixed wing flying anymore. I disabled it for the
deltaquad since I presume @sanderux prefers to have the feature disabled
even when flying in multicopter mode.
2019-07-22 09:57:37 +02:00
Matthias Grob 706500f19c Commander: make RC override multicopter only
AAs discussed in the devcall this functionality is only useful for
rotary-wing (multicopter) flying since it's a big safety hazard to
accidentally bring a fixed wing out of an auto mode e.g. a mission
and fly away in a straight line or into an obstacle.
2019-07-22 09:57:37 +02:00
Matthias Grob 5c1ab06343 Commander: pure refactor of RC override conditions 2019-07-22 09:57:37 +02:00
Bob Long 84a0d16386 Clarify weird behavior of the LIS3MDL
See issue #12514
2019-07-21 12:08:26 -04:00
Beat Küng b71bae414b param: fix potential nullptr dereferencing on param import
NuttX 7.28 seemed to handle this gracefully, but officially passing NULL
results in undefined behavior, and with 7.29 leads to a hardfault.

This happens on configs with flash-based params, on the first unsuccessful
import attempt.
2019-07-19 09:55:08 +02:00
Matthias Grob aaad71faab commander_params: enable automatic disarming after land detection by default 2019-07-18 14:36:50 +02:00
Daniel Agar 9986a88697 mavlink: split BATTERY_STATUS from SYS_STATUS update and handle all bricks (#12034) 2019-07-18 13:32:41 +02:00
Timothy Scott 51d4239eee Commented out rover SITL test 2019-07-17 16:52:24 +02:00
Timothy Scott ecf396443f Minor bugfix 2019-07-17 10:47:56 +02:00
Timothy Scott b9a2c9daf8 Fixed uninitialized variable 2019-07-17 10:47:16 +02:00
Mark Sauder 4a02475dd1 rcS: reduce a few LOC in AUTOCNF logic (#12467)
* Set/unset rcS vars at beginning and end of rcS script and reduce a few LOC checking SYS_AUTOCONFIG with improved logic.

* Restore current placement of set/unset vars in rcS script to leave only the SYS_AUTOCONFIG logic modification.

* Replace set AUTOCNF no after inadvertent deletion.
2019-07-16 16:48:25 +02:00
Beat Küng e6aa035209 hotfix for logger: use '%i' instead of '%zu'
Work-around for https://github.com/PX4/Firmware/issues/12485.

This can be reverted after the root-cause is fixed.
2019-07-16 13:11:41 +02:00
bresch ea0e164145 FlightTask - Rename state_prev to last_setpoint 2019-07-16 13:09:09 +02:00
bresch 37a9b90945 FlightTask - Move checkSetpoints function in each FlightTask to be tailored to the specific needs and avoid checking all the setpoints 2019-07-16 13:09:09 +02:00
bresch 24811cf550 FlightTask smoothVel - Initialize ekf reset counters when task is activated 2019-07-16 13:09:09 +02:00
bresch 1414f50cea FlightTask - When switching task, pass the last setpoints of the previous task to the new task
This is done to allow proper initialization of the new FlightTask and
give it a chance to continue the setpoints without discontinuity. The
function checkSetpoints replaces the setpoints containing NANs with an
estimate of the state. The estimate is usually the current estimate of
the EKF or zero.
The transition FlightTask also provides an estimate of the current
acceleration to properly initialize the next FlightTask after
back-transition. This avoid having to initialize the accelerations to
zero knowing that the actual acceleration is usually far from zero.
2019-07-16 13:09:09 +02:00
bresch d24c415fd7 PID rate controller - Add controller gain to support Ideal PID form (ISA standard) 2019-07-16 10:24:19 +02:00
Timothy Scott 7c05073044 Fixed overflowing tslc. 2019-07-16 09:43:58 +02:00
Timothy Scott e25ad348e8 Added message handler for UTM_GLOBAL_POSITION 2019-07-16 09:43:58 +02:00
Anthony Lamping efad34e55e jenkins: pub_test needs to start px4 in daemon mode 2019-07-16 09:39:01 +02:00
Beat Küng f613581b70 Jenkinsfile-compile: add kakutef7 to nuttx build targets 2019-07-16 08:09:22 +02:00
Beat Küng 84bca7e4d0 shellcheck: disable SC2181
The combination of 'if mycmd' and a logical expression is not supported in
NuttX.
2019-07-16 08:09:22 +02:00
Beat Küng d95aae4619 Generic-arm-none-eabi-gcc-cortex-m7: use SP float depending on NuttX config
Not all m7 boards support double, as for example the STM32F745.
2019-07-16 08:09:22 +02:00
Beat Küng 6e833ed7a8 boards: add Holybro KakuteF7 2019-07-16 08:09:22 +02:00
Beat Küng 098afad9e0 missing SD card error tune: play only twice instead of repeating endlessly 2019-07-16 08:09:22 +02:00
Beat Küng f803e54eee ToneAlarmInterface: add support for non-pwm-based buzzers 2019-07-16 08:09:22 +02:00
Beat Küng 92c2d7ae36 CBRK_BUZZER: allow to disable startup sound
The 'if [ $LOG_FILE = /dev/null ]' block can be removed, because
STARTUP_TUNE is already set in that case.
2019-07-16 08:09:22 +02:00
Beat Küng d8da9db04c fix atxxxx osd driver: use correct device id 2019-07-16 08:09:22 +02:00
Beat Küng 5fe4c61b42 rc_input: add RC_PORT_CONFIG param to configure RC port
The parameter will only be available if the board defines an 'RC' serial
port in SERIAL_PORTS (in default.cmake).
2019-07-16 08:09:22 +02:00
Beat Küng b7a0e1ef03 boards: simplify RC port configuration by using NuttX ioctl's
A board only needs to define:
 #define RC_SERIAL_PORT                     "/dev/ttyS4"

Then it can optionally define one or more of the following:
 #define RC_SERIAL_SWAP_RXTX
 #define RC_SERIAL_SINGLEWIRE
 #define RC_INVERT_INPUT(_invert_true) px4_arch_gpiowrite(GPIO_SBUS_INV, _invert_true)
2019-07-16 08:09:22 +02:00
Beat Küng 9a1ad97c11 fix ToneAlarmInterface: correct TOME_ALARM_CLOCK for timer 13 and 14 2019-07-16 08:09:22 +02:00
Beat Küng a3c920db7d board_defaults: remove unnecessary 'set MIXER_AUX none'
On all of these boards '$USE_IO = no' will hold.
2019-07-16 08:09:22 +02:00
Beat Küng 4b0afff33a fmu-v5 init.c: remove unused include 2019-07-16 08:09:22 +02:00
Beat Küng fcb7372554 atxxxx: fix comment 2019-07-16 08:09:22 +02:00
Beat Küng 1112828dcf adc: allow board to not define BOARD_ADC_HIPOWER_5V_OC or BOARD_ADC_PERIPH_5V_OC 2019-07-16 08:09:22 +02:00
Beat Küng 5d8710d539 bmp280: fix device_id initialization 2019-07-16 08:09:22 +02:00
Martina Rivizzigno 1fb80612f3 CollisionPrevention: address https://github.com/PX4/Firmware/pull/12179
review comments
2019-07-15 10:58:00 +02:00
Martina Rivizzigno ac67d5603f CollisionPrevention: compute the attitude_sensor_frame outside for loop 2019-07-15 10:58:00 +02:00
Martina Rivizzigno 560c9f972a CollisionPrevention: use the maximum timestamp between offboard and
distance sensor such that if one of the two fails the vehicle goes into
failsafe, do not switch off CollisionPrevention if it fails
2019-07-15 10:58:00 +02:00
Martina Rivizzigno 8aad105265 mc_pos_control: increase stack size by 100 bytes 2019-07-15 10:58:00 +02:00
Martina Rivizzigno 02bdc2c46b CollisionPrevention: use FlightTasks convention for private/public methods,
add doxygen on header file
2019-07-15 10:58:00 +02:00
Martina Rivizzigno 8637a9255e CollisionPrevention: add failsafe for stale distance data 2019-07-15 10:58:00 +02:00
Martina Rivizzigno 0ee770e853 logger: log obstacle_distance_fused instead of obstacle_distance 2019-07-15 10:58:00 +02:00
Martina Rivizzigno ff6a4d9e71 stream mavlink message OBSTACLE DISTANCE 2019-07-15 10:58:00 +02:00
Martina Rivizzigno e6e4d846fb add uORB message obstacle_distance_fused with data from offboard
obstacle_distance and distance sensor
2019-07-15 10:58:00 +02:00
Martina Rivizzigno a9b1946bea CollisionPrevention: make sure that vehicle tilt compensation is
correct for all sensor orientation
2019-07-15 10:58:00 +02:00
Martina Rivizzigno 2439dc09ae CollisionPrevention: refactor code to make it more readable 2019-07-15 10:58:00 +02:00
Martina Rivizzigno b6eea508bb CollisionPrevention: make sure that the timestamp is updated for distance
sensors even if they are out of range
2019-07-15 10:58:00 +02:00
Martina Rivizzigno 09bfb00c88 Obstacle_distance: use only one increment in float directly
CollisionPrevention: rename a few variables to make the code more readable
2019-07-15 10:58:00 +02:00
Martina Rivizzigno d216b45202 cm8jl65: use paramter to set sensor orientation 2019-07-15 10:58:00 +02:00
Martina Rivizzigno 6a0ed6af93 cm8jl65: add field of view 2019-07-15 10:58:00 +02:00
Martina Rivizzigno 5b24f28ac7 CollisionPrevention: map distance_sensor data to obstacle distance 2019-07-15 10:58:00 +02:00
Martina Rivizzigno aff131774e simulator mavlink: add horizontal and vertical fov + quaterion orientation
to distance sensor
2019-07-15 10:58:00 +02:00
Martina Rivizzigno 02c3765c1b obstacle_distance: add fields from mavlink extension 2019-07-15 10:58:00 +02:00
Martina Rivizzigno d375402b5b distance_sensor: add horiontal and vertical fov, add quaternion for sensor orientation 2019-07-15 10:58:00 +02:00
Daniel Agar 53c5b6d24f px4_fmu-v2_multicopter disable batt_smbus
- saves a bit of flash
2019-07-12 15:57:35 -04:00
BazookaJoe1900 7be5d15502 px4fmu: cleanup - removed duplicate const MAX_ACTUATORS definition 2019-07-11 18:25:56 -04:00
bresch e5128ac7b9 Cosmetic - Use c++ list initialization 2019-07-11 17:46:44 +02:00
bresch 15ec73629b MPC auto - Add MPC_YAW_MODE: towards waypoint (yaw first) mode. This mode ensures that
the vehicle yaws towards the next waypoint before accelerating. This is
required for drones with front vision and aerodynamic multicopters such
as standard vtol planes or highspeed multirotors.
2019-07-11 17:46:44 +02:00
Timothy Scott 2ed00c9cb6 Rover: Rewrote gnd_pos_control and removed gnd_att_control (#12239) 2019-07-11 09:39:13 -04:00
Beat Küng 3743e6d8fb yaml: use safe_load(f) instead of load(f, Loader=yaml.FullLoader)
yaml.FullLoader is not always defined
2019-07-11 10:20:06 +02:00
Hamish Willee 27ef1899c7 Fix up MAV_X_RATE as html tag doesn't render (#12449)
* Fix up MAV_X_RATE as html tag doesn't render

* Update src/modules/mavlink/module.yaml

Co-Authored-By: Beat Küng <beat-kueng@gmx.net>
2019-07-11 08:07:20 +02:00
Mark Sauder 4e5974f1ca srf02 driver: Move member variable initialization to declarations, standardize against other drivers and format. (#11891)
* Migrate variable initialization from constructor list to declarations, standardize whitespace formatting, and alphabetize/organize order of methods and variables in srf02.cpp.

* Increase stack allocation size for the srf02 driver main.
2019-07-10 23:05:02 -04:00
Daniel Agar d4cd1d0d2e NuttX stm32f7 fully re-enable dcache with write back (#12435)
- fixes https://github.com/PX4/Firmware/issues/12216
 - includes latest PX4/NuttX and apps update 7.29+
2019-07-10 19:08:12 -04:00
Daniel Agar dc10a68539 NuttX and apps update 7.29 2019-07-10 12:58:35 -04:00
Daniel Agar fbd3386c39 Jenkins Hardware ensure buzzer is disabled on test rack 2019-07-10 09:50:29 -04:00
Alexis Paques 453ecfeb55 YAML: use Loaders and safe_load (#11910) 2019-07-10 15:15:29 +02:00
Fabian Schilling 6da8ce94f1 Fix off-by-one error in tgt_system (SDF version) 2019-07-10 14:49:18 +02:00
Fabian Schilling 5e39e14e7c Fix off-by-one error in tgt_system parameter 2019-07-10 14:49:18 +02:00
Daniel Agar 7ace66a2b9 Jenkins hardware increase timeout 10 -> 20 minutes 2019-07-09 21:08:07 -04:00
Beat Küng aa86bf5f92 landdetector flight time: fix cast to 64 bits
`_param_total_flight_time_low.get()` is an int32_t and gets sign-extended
if cast directly to uint64_t. To avoid that we first cast to uint32_t.
2019-07-09 20:26:40 -04:00
Daniel Agar 321c2c0392 boards don't use px4_add_library for drivers_board
- this prevents low level board support from using PX4 logging, uORB, etc
2019-07-09 19:09:47 -04:00
Roman Bapst b54a43fccc UAVCAN driver: support throttle linearization (THR_MLD_FAC parameter)
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-09 15:10:54 -04:00
Matej Frančeškin 2aa05e3914 Mavlink FTP - process only messages that have our component id 2019-07-09 20:21:15 +02:00
Silvan Fuhrer fdcb0f06d6 Babyshark VTOL: updated config file (new smooth flight task, detuned position control,
improved land detector, included autopilot rotation)

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-07-09 15:38:40 +02:00
bresch 6df1600357 Auto - Update velocity setpoint generator to avoid overshoot at high cruise speed.
The linear mapping from position error to cruise velocity is changed by
a combination of that linear mapping and a nonlinear function containing
the maximum acceleration and jerk to avoid overshoots at waypoints due to
overoptimistic breaking distance.
2019-07-09 09:46:45 +02:00
Jacob Dahl 59c555aec3 Multicopter Auto: Adjustable land speed via RC (#12220) 2019-07-08 23:55:21 -04:00
mcsauder c1e4970841 Delete uneccessary #includes from the lights driver directory. 2019-07-08 23:45:01 -04:00
mcsauder f3af3217c7 Delete unnecessary #includes from the irlock driver. 2019-07-08 23:45:01 -04:00
mcsauder b495ddbdd3 Delete unnecessary #includes from the imu driver directory. 2019-07-08 23:45:01 -04:00
mcsauder be414f7ab1 Alphabetize the heater driver #include list. 2019-07-08 23:45:01 -04:00
mcsauder 35e5327cc9 Delete unnecessary #includes in the gps driver directory. 2019-07-08 23:45:01 -04:00
mcsauder 2ef6e18640 Delete unnecessary #includes in the differential_pressure drivers directory. 2019-07-08 23:45:01 -04:00
mcsauder 2a3b98a463 Deprecate unneeded #includes from the camera_capture driver. 2019-07-08 23:45:01 -04:00
mcsauder b10cb2a24e Deprecate unnecessary #includes from the batt_smbus driver. 2019-07-08 23:45:01 -04:00
mcsauder d1e46737a3 Organize, alphabetize, and deprecate unneeded #includes from the barometer drivers. 2019-07-08 21:32:52 -04:00
Daniel Agar aff13f6f64 rc.fw_defaults: reduce EPH/EPV failsafe values from 5x to 3x MC 2019-07-08 17:50:54 -04:00
BazookaJoe1900 df45124d02 black sheep telemetry add new TEL_BST_EN parameter to enable 2019-07-08 16:30:22 -04:00
Daniel Agar 6ea5853161 px4_fmu-v2_multicopter sync with px4_fmu-v2_default 2019-07-08 14:49:58 -04:00
Daniel Agar 58b74e241e px4_fmu-v2 disable mpu9250 2019-07-08 14:49:58 -04:00
Daniel Agar 26f6794aa9 px4_fmu-v2 re-enable CONSTRAINED_FLASH build
- this limits console output at boot
2019-07-08 14:49:58 -04:00
Daniel Agar 15d1543f95 create systemcmds/i2cdetect tool to scan i2c bus 2019-07-06 10:28:16 -04:00
PX4 Build Bot d9c90ed31a Update submodule ecl to latest Fri Jul 5 12:38:36 UTC 2019
- ecl in PX4/Firmware (590b55cb222ec68d4bbb61208f301102607b6161): https://github.com/PX4/ecl/commit/a036cf82cc92ef6572ea7ee960cfff4d305c01fa
    - ecl current upstream: https://github.com/PX4/ecl/commit/e1751188fd15b799cbfae86bd7373bb91206069b
    - Changes: https://github.com/PX4/ecl/compare/a036cf82cc92ef6572ea7ee960cfff4d305c01fa...e1751188fd15b799cbfae86bd7373bb91206069b

    e175118 2019-06-28 bresch - EKF - Initialize _deadrekon_time_exceeded to true. If no sample have been received, deadrekoning and local position should be invalid.
2019-07-05 16:46:31 -04:00
Mathieu Bresciani e54075abe8 MC pos control - Force cruise and manual speeds below max speed. (#12404)
- Force hover thrust between min and max thrust
2019-07-05 15:40:28 -04:00
David Sidrane ea0da3a3b6 px4/fmu-v5x: GPIO ADC had bad definition 2019-07-05 12:23:06 -04:00
RomanBapst 7c8fa82e76 rtl cone angle: expose a few values to the user
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-05 18:05:09 +02:00
RomanBapst 81ee40eac8 rtl: implemented RTL based on cone shape
- user defines a cone half angle which defines the RTL altitude behavior
- if vehicle is outside the cone it will climb until it intersects the cone
and then return at this altitude.
- if vehicle is inside the cone or above the predefined return altitude (RTL_RETURN_ALT)
then it will return at the current altitude

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-07-05 18:05:09 +02:00
Timothy Scott f7a460427b Changed name of mixer to be shorter 2019-07-05 18:00:15 +02:00
CarlOlsson 12fcddd288 fmu: remove unused functions 2019-07-04 22:08:00 -04:00
Silvan Fuhrer 9b46c1d8a9 Upated Babyshark VTOL config and vtol_defaults
Updated the babyshark default  parameters for improved flight performance,
as well as two MPC parameters in vtol_defaults for smoother hovering with VTOLS"

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2019-07-04 11:26:01 -04:00
Nicolas de Palezieux 2f1cfa60f4 precland: store result of _target_pose_sub.update() for later use
- Fixes #12391
2019-07-04 11:02:14 -04:00
BazookaJoe1900 72a449490a Mavlink: Use MAV_BROADCAST only in context of ethernet 2019-07-03 14:02:37 -04:00
Fabian Schilling d139bc5a7c Use bc to support floating point PX4_SIM_SPEED_FACTOR 2019-07-03 16:54:29 +02:00
Timothy Scott dce1dda871 Fixed incorrect timestamps 2019-07-03 14:39:59 +02:00
Beat Küng a2471fb539 logger: handle 'char' type in messages
Fixes errors like:
ERROR [logger] No definition for topic char[10] key;uint8_t[2] _padding0; found
when the Debug logging profile is selected.
2019-07-03 10:43:59 +02:00
alessandro fecb32f88d Parameter for virtual battery in SITL (#12299)
* New parameter for virtual battery in SITL

* Update src/modules/simulator/simulator_mavlink.cpp

Co-Authored-By: Beat Küng <beat-kueng@gmx.net>

* Updated description for parameter SIM_BAT_MIN_PCT
2019-07-02 15:53:18 +02:00
Daniel Agar 9bfc4f2d54 Analog Device ADIS16477 move to PX4Accelerometer/PX4Gyroscope and cleanup 2019-07-01 22:53:27 -04:00
Daniel Agar 9450496eb4 Analog Devices ADIS16497 move to PX4Accelerometer/PX4Gyroscope and cleanup 2019-07-01 22:47:31 -04:00
Daniel Agar cdadb393b7 Analog Device ADIS16448 cleanup
- move to PX4Accelerometer, PX4Gyroscope, PX4Magnetometer helpers
 - add barometer support (using PX4Barometer)
2019-07-01 16:02:00 -04:00
dlwalter cbdfc0c587 px4_fmu-v5: rc.board_sensors start lis3mdl optional external magnetometer 2019-07-01 14:52:14 -04:00
Daniel Agar 6ef61e5c19 landing_target_estimator: update to uORB Subscription and Publication 2019-07-01 10:35:41 -04:00
Daniel Agar 38da0f95aa rc_input move to uORB::Subscription 2019-07-01 10:35:26 +02:00
Daniel Agar 4f445cd7f8 vscode add av_x-v1 debug target 2019-06-30 19:05:54 -04:00
Daniel Agar 7f9415ba46 systemcmds/top: increase stack 200 bytes
- this is necessary after most boards increased CONFIG_MAX_TASKS 32 -> 64
2019-06-30 18:37:41 -04:00
Daniel Agar d1298f2c37 Jenkins HITL exit upload monitor on nsh> 2019-06-29 17:18:22 -04:00
Daniel Agar c165a6f71b attitude_estimator_q: move most orb subscriptions to uORB::Subscription 2019-06-29 15:51:49 -04:00
Mark Sauder 423219c60e pga460: Change variable initialization to uniform initialization style, format whitespace, and change baud rate unsigned to speed_t type. (#11861) 2019-06-28 21:52:16 -04:00
Mark Sauder db96b6c08d cm8jl65: Refactor driver, employ uniform initialization, format, and deprecate ringbuffer and IOCTL. (#11853)
* Move cm8jl65 class member variable initialization from constructor list to declarations.  Format whitespace and move method doxy comments  to declarations.

* Refactor the cm8jl65 driver start() method, and rename info()->status().

* Continued refactoring of the cm8jl65 driver class:
 - Condense all class files into a single *.cpp file and give class scope resolution to previously unscoped methods.
 - Refactor cm8jl65 namespace level driver entry methods to reduce code and improve clarity.
 - Breakout CDev specific initialization LOC into the device_init() method.
 - Move the endian modification inside of the crc16_calc() method.

* Deprecate the hardware ringbuffer, _class_instance, and ioctl() from the cm8jl65 driver.
2019-06-28 21:46:02 -04:00
Daniel Agar 4b778fd0c2 navigator: fix vehicle_status update (#12364) 2019-06-28 21:35:29 -04:00
Mark Sauder 5857cf4799 LeddarOne: Refactor the driver to standardize against other distance sensor drivers. (#11858)
* Migrate remaining member variable intialization to declarations and employ uniform initialization style. Copy/paste help() and main() methods to the bottom of the file to match convention with other distance sensor drivers.

* Refactor the LeddarOne driver class to give scope resultion to the methods that were global and to standardize the implementation against most of the other distance sensor drivers.

* Deprecate _reports member var, use of hardware ring buffer, and LeddarOne::read() method.

* Deprecate commented (dead) code from the LeddarOne class init() method.

* Refactor the LeddarOne class cycle() and collect() methods and create measure() method to untangle the previous logic implementation.
2019-06-28 21:29:44 -04:00
PX4 Build Bot 309322ce98 Update submodule sitl_gazebo to latest Fri Jun 28 12:37:57 UTC 2019
- sitl_gazebo in PX4/Firmware (7bba5a7287): https://github.com/PX4/sitl_gazebo/commit/95adbb11f8deef06fb132bf0eb85c19e6ca00f6e
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/22df9475ca0d157e2db066a20f64c35906bf7f25
    - Changes: https://github.com/PX4/sitl_gazebo/compare/95adbb11f8deef06fb132bf0eb85c19e6ca00f6e...22df9475ca0d157e2db066a20f64c35906bf7f25

    22df947 2019-06-27 Martina Rivizzigno - Range.proto: fix indentation
8ef5625 2019-05-28 Martina Rivizzigno - update sonar message to match mavlink distance sensor definition
e04ff96 2018-12-04 Martina - get distance sensor orientation from the vehicle model instead of hard-coding it in the gazebo interface, add horizontal and vertical fov
2019-06-28 16:43:49 +01:00
Daniele Pettenuzzo 55b5e7552c mavlink: add new extvisionmin mode (#12279)
Signed-off-by: DanielePettenuzzo <daniele@px4.io>
2019-06-28 10:44:22 -04:00
Mark Sauder c22ed9397e land_detector: Implement ModuleParams inheritance in the FixedwingLandDetector class. 2019-06-28 10:26:59 -04:00
RomanBapst 0b2af5c519 FixedWingAttitudeControl: don't lock integrator during transition
- airframes that are not well trimmed rely on the integrator to learn
the offset. This change can help improve altitude hold during transitions

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-06-28 09:54:40 -04:00
RomanBapst 7bba5a7287 vtol_configs: replaced VT_MOT_COUNT with VT_MOT_ID
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-06-27 20:14:10 +02:00
RomanBapst afd95b14cf vtol_att_control: use VT_MOT_ID instead of VT_MOT_COUNT
- VT_MOT_COUNT assumed that motors were always the first outputs. This
does not have to be true always. VT_MOT_ID allows to specify precisely how
many motors we have for hovering and to which channel they are connected.

Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-06-27 20:14:10 +02:00
RomanBapst 2c74216028 ekf2: fixed calculation of static pressure error
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2019-06-27 18:11:53 +02:00
Mark Sauder 1466d11acc land_detector: cleanup actuator_armed and battery_status naming
* Rename _arming -> _actuator_armed
 * Rename _battery -> _battery_status in the MulticopterLandDetector class.
2019-06-27 12:02:14 -04:00
Mark Sauder 94c1f21473 mb12xx: Refactor driver class to allow for multiple sensors and cleanup (#11859)
* Migrate mb12xx driver class member variable initialization to declarations.
Format whitespace and alphabetize/group/order var declarations.
Refactor driver reset() and mb12xx_main() methods for readability.
Deprecate usage of IOCTL.

* Deprecate the _reports ringbuffer, _class_instance, and read() method and minor formatting in the mb12xx driver.

* Add time_literal usage and #define MB12XX_BUS_SPEED.

* Refactor the mb12xx driver to mirror the mappy_dot driver implementation and create functionality for multiple sensors.

* Add stack size for the mb12xx driver.
2019-06-27 11:59:40 -04:00
Mathieu Bresciani c5deba53a2 mc_pos_control: Explicitly convert tilt variables to radians during check and assignments 2019-06-27 11:38:21 -04:00
Lorenz Meier 748ff7f50a Update README.md
Clarify the naming of FMU versions to not confuse users once the new industrial FMUv5X standard is established.
2019-06-27 08:28:32 +02:00
Anthony Lamping 49966f4c46 launch: multiple sdf models (#12306) 2019-06-26 15:20:49 -04:00
David Sidrane 6fcc4cc6a2 WIP Digital PM Support 2019-06-26 14:34:02 -04:00
David Sidrane 1cf4a2d953 Added Suport for ICM 20602 on PX4_SPI_BUS_SENSORS1 2019-06-26 14:34:02 -04:00
David Sidrane e5b6adc7f3 fmu-v5X VER REV Combined 2019-06-26 14:34:02 -04:00
David Sidrane 31dfaee76a fmuv5x board support 2019-06-26 14:34:02 -04:00
mcsauder 6e9f706b12 Standardize remaining class member variable naming convention in the MulticopterLandDetector class. 2019-06-26 14:06:56 -04:00
mcsauder df662245a2 Standardize class member variable naming convention in the LandDetector class. 2019-06-26 14:06:56 -04:00
mcsauder 6b6d82447e Standardize class member variable naming convention in the MulticopterLandDetector class. 2019-06-26 14:06:56 -04:00
mcsauder 3f0159d784 Standardize class member variable naming convention in the VtolLandDetector class. 2019-06-26 14:06:56 -04:00
mcsauder 2b9ad179a2 Standardize class member variable naming convention in the FixedWingLandDetector class. 2019-06-26 14:06:56 -04:00
Lorenz Meier 7ba658d573 MAVLink module: Add additional IMUs as default outputs
This simplifies setup and verification of systems, as all three sensors can be looked at in a graph view.
2019-06-26 10:24:16 -04:00
mcsauder d7cfebe0a3 Add check_params(true) call to the LandDetector start() method. Break out _update_total_flight_time() method in the LandDetector class. 2019-06-26 09:23:02 +02:00
mcsauder f783982edb Revert changes to the check_params(const bool force) declaration/definition to match current PX4:master. 2019-06-26 09:23:02 +02:00
mcsauder 0ec7efcfc4 Delete _measure_interval and redundant parentheses in LandDetector.h. 2019-06-26 09:23:02 +02:00
mcsauder faa3c3dc6f Refactor the LandDetector class to
- Reduce duplicate code in LandDetector _check_params() method.
 - Standardize naming cases.
 - Implement DEFINE_PARAMETERS() macro.
2019-06-26 09:23:02 +02:00
Angel 46662072d1 Missed conversion to radians in AutoMapper and AutoMapper2 2019-06-25 14:01:35 +02:00
Daniel Agar 6d9bf18ca6 Revert "VTOL: add parameter to prevent flight if roll direction was not checked"
This reverts commit 5f06c6a1aa.
2019-06-25 09:26:20 +02:00
Matthias Grob 5002b13bda mc_att_control: Increase default rate integral gain
@bkueang and me realized that on every frame we tune the integral gain for
the roll and pitch rate controller is much too low. Usually it needs to be
increased to 0.3 or even 0.4 to have better "locked in" flight performance
and 0.2 seems like a good compromise for a safe default.
2019-06-24 18:26:27 +02:00
Matthias Grob 443381327e Airframes: rename normal S500 to generic and remove PX4 defaults 2019-06-24 18:26:27 +02:00
Matthias Grob c22825ee45 Airframes: add Holybro S500 Kit which was tested at dev summit 2019-06-24 18:26:27 +02:00
Daniel Agar d96c97ed48 Update submodule jMAVSim to latest Sat Jun 22 12:37:52 UTC 2019 (#12316)
- jMAVSim in PX4/Firmware (fb8630c267): https://github.com/PX4/jMAVSim/commit/883413f8b97cc53d48491d6ff3630d6efd2e2467
    - jMAVSim current upstream: https://github.com/PX4/jMAVSim/commit/def7501bc0536b8d1050f65d09c7dfbebcc0ce61
    - Changes: https://github.com/PX4/jMAVSim/compare/883413f8b97cc53d48491d6ff3630d6efd2e2467...def7501bc0536b8d1050f65d09c7dfbebcc0ce61

    def7501 2019-06-18 romain-chiap - SIH support: add display-only mode for simulation-in-hardware (#101)
2019-06-22 15:42:08 +02:00
Ildar Sadykov fb8630c267 Adding VTOL Octoplane airframe type (#12303)
* Srcparser updated, default script for VTOL octoplane added.
2019-06-22 14:13:29 +02:00
Beat Küng 64ac8c18d2 mc airframes: increase I gains a bit
Previous commit allows to increase them again.
Partially reverts commit 6c3e79f361.
2019-06-22 13:23:19 +02:00
Beat Küng ea31f34d09 mc rate controller: add I term reduction factor
Reduce the I gain for high rate errors to reduce bounce-back effects after
flips. Up to 200 degrees the gain is almost not reduced (<25%), so this
will only take noticeable effects for large errors (setpoint changes),
where we actually want to have an effect.

This allows to increase the MC_*RATE_I parameters w/o negative effects
when doing flips (i.e. bounce-back after flips).

The 400 degrees limit and the x^2 are empirical.

The better the rate tracking in general (high P gain), the less this is
required (because of the lower tracking error). At the same time it also
does not harm, as the i_factor will always be close to 1.
2019-06-22 13:23:19 +02:00
JaeyoungLim 4c4bcc5fdb Mavlink: Fill in thrust field correctly for offboard rates setpoints on fixed wing (#12311)
* Fill in thrust field for rates sp
2019-06-20 17:17:32 +02:00
PX4 Build Bot 4831a4b0cf Update submodule ecl to latest Tue Jun 18 20:37:33 EDT 2019
- ecl in PX4/Firmware (4673dd0a0c9b90fcab84a26e75812a5c7172d1af): https://github.com/PX4/ecl/commit/0f49eb34a08e499a26d749ed981429047f2100ff
    - ecl current upstream: https://github.com/PX4/ecl/commit/a036cf82cc92ef6572ea7ee960cfff4d305c01fa
    - Changes: https://github.com/PX4/ecl/compare/0f49eb34a08e499a26d749ed981429047f2100ff...a036cf82cc92ef6572ea7ee960cfff4d305c01fa

    a036cf8 2019-06-14 Paul Riseborough - EKF: Remove use of of quaternion self product operator and fix delta rotation sign
0e946f2 2019-06-14 Paul Riseborough - EKF: Remove use of quaternion self product operator and fix delta rotation sign error
ad7f7af 2019-05-21 CarlOlsson - ekf: correct quaternion multiplication order
d6351bd 2019-05-21 CarlOlsson - EKF: update comment
7612fa4 2019-05-30 Paul Riseborough - EKF: Don't start using GPS for height until all validity checks have passed
cef2ba5 2019-05-08 Roman - implemented Kahan summation algorithm for adding process noise to delta angle- and delta velocity bias variance
2019-06-19 11:38:49 +10:00
SalimTerryLi e0f3fc8d00 Mavlink receiver SET_ATTITUDE_TARGET fill the correct throttle field by checking its frametype in offboard mode (#12149) 2019-06-18 02:06:41 +02:00
Julian Oes 46c00ca6a4 vscode: add PX4_SIM_SPEED_FACTOR
This env variable can be changed to adapt the simulation speed.
2019-06-18 01:56:49 +02:00
Julian Oes 1cee945a22 vscode: use lockstep
This changes the VSCode debugging to use lockstep. For lockstep, the
rate needs to be 250 Hz.
2019-06-18 01:56:49 +02:00
Julian Oes e1671571c8 jMAVSim: use PX4_SIM_SPEED_FACTOR, not cli arg
In order to be consistent between Gazebo and jMAVSim we should be using
the env variable PX4_SIM_SPEED_FACTOR in the same way. This enables
vscode to set the speed using the env variable.
2019-06-18 01:56:49 +02:00
Julian Oes fea284f728 vscode: start gzclient GUI for Gazebo simulation 2019-06-18 01:55:21 +02:00
alessandro 2deab6c607 commander: refactored state-machine strings
- Follow-up changes to https://github.com/PX4/Firmware/pull/11796
2019-06-17 20:09:05 +02:00
Daniel Agar 136962d125 uORB Subscription callbacks with WorkItem scheduling on publication (#12207) 2019-06-17 16:26:06 +02:00
Beat Küng beaba44e5b mc mixer: prioritize roll/pitch over yaw for full airmode
Improves roll/pitch tracking in situations of large yaw demands.
2019-06-17 13:17:18 +02:00
mcsauder 8811c8315c Modify the update_params() comment to better reflect what is taking place in mavlink_receiver.h. 2019-06-17 09:41:30 +02:00
mcsauder 742c22d099 Rename _param_sub to _param_update_sub and initialize. Re-define and re-implement the update_params() method and only call if parameters have been updated. 2019-06-17 09:41:30 +02:00
mcsauder c92b8b03cd Move variable initialization from constructor to declarations in MavlinkReceiver class, alphabetize var lists. Added update_params() method to ensure that parameters subscribed to are updated routinely. 2019-06-17 09:41:30 +02:00
Patrick Brünn b402c9697d hardfault_log: fix NULL terminator truncation
building "make omnibus_f4sd_default" with gcc 8.2.1 failes with:
hardfault_log.c:315:7: error: 'strncat' specified bound 30 equals destination size

gcc8 introduced -Wstringop-truncation, which will warn about NULL terminator
truncation.

This patch fixes two similar issues:
- strncpy() makes no sense if we want to copy without NULL terminator
- strncat() needs space to append the NULL terminator

fixes #12283
2019-06-17 08:15:34 +02:00
Daniel Agar 7c4bf6ddae Mavlink ODOMETRY (331) support MAV_FRAME_BODY_FLU 2019-06-16 13:23:57 -04:00
Daniel Agar 09e09863b5 Update submodule mavlink v2.0 to latest Sun Jun 16 00:37:57 UTC 2019
- mavlink v2.0 in PX4/Firmware (067eb41d23252cbc5725f98e63ea56a2951da317): https://github.com/mavlink/c_library_v2/commit/70c1b4ef2db3244df23196bf2e47e369e2e8b78a
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/18cf6ff2fc0e51e4555b19fc31e8b06eb38bdd79
    - Changes: https://github.com/mavlink/c_library_v2/compare/70c1b4ef2db3244df23196bf2e47e369e2e8b78a...18cf6ff2fc0e51e4555b19fc31e8b06eb38bdd79
2019-06-15 23:22:45 -04:00
Daniel Agar 115b8f83ef Update submodule sitl_gazebo to latest Sun Jun 16 00:37:52 UTC 2019
- sitl_gazebo in PX4/Firmware (648e7de249): https://github.com/PX4/sitl_gazebo/commit/f2593dbcc2980dd15714925931fbb0e46a63a4b2
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/95adbb11f8deef06fb132bf0eb85c19e6ca00f6e
    - Changes: https://github.com/PX4/sitl_gazebo/compare/f2593dbcc2980dd15714925931fbb0e46a63a4b2...95adbb11f8deef06fb132bf0eb85c19e6ca00f6e

    95adbb1 2019-06-08 David Jablonski - fix gstreamer package finding for ubuntu
2019-06-15 23:21:12 -04:00
Mark Sauder f1c66749e3 vl53lxx: migrate variable initialization from constructor list to declaration uniform initialization (#11896)
* Format whitespace
 * Alphabetize/group/order variables and methods.
 * Deprecate IOCTL usage and simplify a few methods.
2019-06-15 23:18:46 -04:00
David Sidrane f96c47ae1b stm32f7 bootloader update support (#11394)
* micro_hal: F7 add flash
* micro_hal: F7 non up_progmem functions
* bl_update: Add F7 Support
2019-06-15 21:46:46 -04:00
JaeyoungLim d7d0bd2764 Mavlink: Enable gimbal control using SET_ACTUATOR_CONTROL_TARGET while controlling the vehicle offboard (#12146)
* Stop ignoring setpoints when actuator setpoints are for the gimbal
2019-06-15 21:35:41 -04:00
Daniel Agar 106ee280c5 land_detector initiate cycle immediately
- fixes #12190
2019-06-15 21:30:09 -04:00
Kabir Mohammed ce784d1ef0 Sensordots Mappydot+ driver (#12147)
* Add MappyDot+ driver capable of utilizing multiple sensors on a single i2c bus.
2019-06-15 21:13:51 -04:00
Mark Sauder eaa3d4a24f tfmini: migrate driver class member variable initialization to declarations (#11893)
* format whitespace
 * alphabetize/group/order var/method declarations 
 * added a default port to start the tfmini driver without requiring arguments.
2019-06-15 21:01:36 -04:00
Daniel Agar 4e360064d9 commander refactor and cleanup offboard control mode 2019-06-15 20:45:26 -04:00
Daniel Agar 648e7de249 drivers/px4io move to uORB::Subscription 2019-06-15 20:14:10 -04:00
Daniel Agar 1657b5030a wind_estimator always copy attitude and local position data 2019-06-15 19:42:48 -04:00
Daniel Agar a175c4407d Jenkins add rover SITL test 2019-06-15 17:55:44 -04:00
Daniel Agar e7add33c12 Jenkins HIL print fmu status and pwm info 2019-06-15 16:59:04 -04:00
Daniel Agar 5f20d3cf3b Jenkins HIL increase boot timeout for stackcheck build
- px4_fmu-v5_stackcheck remove extra drivers (to try and get the system
usuable)
2019-06-15 16:59:04 -04:00
Daniel Agar e6799e90ad Jenkins HIL disable buzzer and remove redundant px4_fmu-v5 test 2019-06-15 15:06:02 -04:00
Daniel Agar 81c914a092 Jenkins HIL test run various commands to inspect system 2019-06-15 14:29:00 -04:00
Daniel Agar d30e30a2a6 Jenkins HIL run more tests 2019-06-15 11:31:01 -04:00
Daniel Agar 4910bed45b mavlink send_statustext_critical() remove redundant print 2019-06-15 10:14:41 -04:00
Daniel Agar 8e0e846e6e Jenkins hardware target different V5 variants 2019-06-14 14:48:44 -04:00
David Sidrane 6eb4cf0ceb Add CUAV 5+ and Nano to fmu-v5 manifest
* rcS: Set SYS_USE_IO for Nano
2019-06-14 13:19:41 -04:00
Daniel Agar bf08b60b8f vscode launch.json add nxp_fmuk66-v3 2019-06-14 11:35:12 -04:00
Daniel Agar 5e058ae290 vscode launch.json add black magic probe debug config 2019-06-14 10:31:42 -04:00
Daniel Agar fe2dff649c vscode launch.json (debug configurations) cleanup naming and sort list 2019-06-14 10:31:42 -04:00
Matthias Grob 146a3866c0 Testing: hotfix to recover test coverage CI
CMAKE_TESTING should automatically be enabled
but I hoped to do that in the test.cmake
target specific options and not in the main
CMakeLists. I have to see if I can make that
order work. Here the hotfix to make CI work
again.
2019-06-14 06:54:10 -07:00
Daniel Agar 61512f063a vscode debug linux vs osx handle external console properly 2019-06-14 08:27:37 -04:00
Daniel Agar fd18a6c0e6 vscode improve fmu-v2/v3/v4/v4pro/v5 debug targets 2019-06-14 08:27:37 -04:00
bresch 83d90410ff Jerk-limited auto mode - use MPC_ACC_HOR instead of MPC_ACC_HOR_MAX
as written in the parameter desctiption
2019-06-14 09:56:56 +02:00
Daniel Agar a4a130fe53 tests free test containers in IntrusiveQueue and List 2019-06-13 10:47:27 -04:00
Daniel Agar aee8f13289 List fix remove() and update testing 2019-06-13 10:47:27 -04:00
Daniel Agar 1623de8bd0 IntrusiveQueue add remove method, iterators, and update test 2019-06-13 10:47:27 -04:00
Timothy Scott 327354705b Fixed filename 2019-06-13 10:04:26 +02:00
Timothy Scott c4bb6b53e8 Changed soft stop check 2019-06-13 10:04:26 +02:00
Timothy Scott 21760a5856 Changed constant name to UNMANNED_GROUND_VEHICLE 2019-06-13 10:04:26 +02:00
Timothy Scott 714c90b9db Updated code style to fix confusing if conditions 2019-06-13 10:04:26 +02:00
Timothy Scott a134da6e12 Removed is_rotor_wing, replaced with vehicle_type 2019-06-13 10:04:26 +02:00
Timothy Scott 2ca40bfc65 Changed navigator to properly separate xy and z distance to waypoint 2019-06-13 10:04:26 +02:00
Daniel Agar 6816f2a4ce commander force offboard control update when first entering mode
- fixes #12241
2019-06-12 20:25:05 -04:00
Matthias Grob 048cca7bc4 vtol_att_control: apply multicopter takeoff hotfix also for vtol (#12250)
Please see reference:
https://github.com/PX4/Firmware/issues/12171
2019-06-12 13:59:29 -04:00
Mark Sauder ae6fed4f29 Migrate remaining variable initializations from constructor list to declarations in mavlink_main.cpp/h. 2019-06-12 12:53:09 -04:00
Martina Rivizzigno 7a586d2b60 ObstacleAvoidance: hysteresis on failsafe 2019-06-12 16:42:02 +02:00
Daniel Agar 79d4c09d59 uORB::Publication simplify and cleanup
- base class is now template
 - drop linked list
 - virtualization no longer required
2019-06-12 08:48:19 -04:00
PX4 Build Bot 57fc6eb4b8 Update submodule devices to latest Tue Jun 11 20:38:48 EDT 2019
- devices in PX4/Firmware (96e8e25a85a334872f2e46786d7c2f546ed846df): https://github.com/PX4/GpsDrivers/commit/a4999f111d13bcb209754823a3c503fa659a0d15
    - devices current upstream: https://github.com/PX4/GpsDrivers/commit/69e38ecc846df03f0bb71aa136bcc830dd3316a9
    - Changes: https://github.com/PX4/GpsDrivers/compare/a4999f111d13bcb209754823a3c503fa659a0d15...69e38ecc846df03f0bb71aa136bcc830dd3316a9

    69e38ec 2019-06-06 Andreas Antener - sbf: report vertical velocity DOWN (converted from UP)
c803bad 2019-06-05 Andreas Daniel Antener - SBF Updates (#43)
2019-06-12 08:01:31 +02:00
Bharat Tak 1ebf5d04d9 logger: add Ulog sync bytes at 1Hz and tagged log message definition (#12144) 2019-06-11 11:00:54 +02:00
PX4 Build Bot 736a1c4778 Update submodule ecl to latest Mon Jun 10 12:38:13 UTC 2019
- ecl in PX4/Firmware (e80050ce8c261e9b5c1cf7e1e8c62f32db08099f): https://github.com/PX4/ecl/commit/54ac147ae8930f1c280a0bd5c25fa90eaf4c6e0d
    - ecl current upstream: https://github.com/PX4/ecl/commit/0f49eb34a08e499a26d749ed981429047f2100ff
    - Changes: https://github.com/PX4/ecl/compare/54ac147ae8930f1c280a0bd5c25fa90eaf4c6e0d...0f49eb34a08e499a26d749ed981429047f2100ff

    0f49eb3 2019-05-24 RomanBapst - fixed method which calculates validity of terrain estimate
cd34ab8 2019-05-24 Daniel Agar - mathlib delete floorf in favor of math.h
340d85a 2019-05-27 Robert de Vries - EKF: fix variable names in estimator_interface.h
90b4c7c 2019-05-24 Matthias Grob - mathlib: fix floorf indentation
710c529 2019-05-23 Sebastian Verling - fixed calculation of magentic table values by using floor instead of int casting
2019-06-10 10:42:37 -07:00
Daniel Agar 32a89a1834 rename empy templates (*.template) to proper file extension (.em) 2019-06-10 10:42:00 -07:00
Daniel Agar bef7a9ba8e NuttX boards increase task limit 32 -> 64 (#12230) 2019-06-10 09:42:36 -04:00
Daniel Agar 070df61daf Update submodule mavlink v2.0 to latest Mon Jun 10 12:37:58 UTC 2019 (#12232)
- mavlink v2.0 in PX4/Firmware (b69bf26721b61a8dd026e3c28b201a5baa72d2df): https://github.com/mavlink/c_library_v2/commit/60df2613725c21f3eedc51251285f80a22e7d07d
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/70c1b4ef2db3244df23196bf2e47e369e2e8b78a
    - Changes: https://github.com/mavlink/c_library_v2/compare/60df2613725c21f3eedc51251285f80a22e7d07d...70c1b4ef2db3244df23196bf2e47e369e2e8b78a
2019-06-10 09:10:49 -04:00
Daniel Agar 9db4d87587 Update submodule sitl_gazebo to latest Mon Jun 10 12:37:51 UTC 2019
- sitl_gazebo in PX4/Firmware (b0176dc88a): https://github.com/PX4/sitl_gazebo/commit/a0b0eb8df12b11e8f63d3cc766dee97cefa32ab7
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/af00ac4dfc5cfb25140254c5cae2a225944fc1c1
    - Changes: https://github.com/PX4/sitl_gazebo/compare/a0b0eb8df12b11e8f63d3cc766dee97cefa32ab7...af00ac4dfc5cfb25140254c5cae2a225944fc1c1

af00ac4 2019-06-07 Lukas Woodtli - Add support for unit tests on macOS
3a81838 2019-06-04 Lukas Woodtli - Add support to build and run unit tests with catkin
c59d214 2019-05-11 Lukas Woodtli - Add unit tests for gps plugin
860e1ce 2018-09-20 Lukas Woodtli - Add unit tests for gimbal controller plugin
2019-06-10 09:09:49 -04:00
BazookaJoe1900 b0176dc88a Pr cleanup board files (#12218)
Clear non exist functions definitions
Added RC Serial note before its relevant definitions
2019-06-08 15:48:53 -07:00
Daniel Agar 8a0beb83db templates/module move print_usage() to bottom of file 2019-06-08 03:23:50 -07:00
Daniel Agar 910e938943 tune_control move usage() to bottom of file 2019-06-08 03:23:50 -07:00
Daniel Agar cfa58dfc36 led_control move usage() to bottom of file 2019-06-08 03:23:50 -07:00
Daniel Agar c223de8a50 vmount move usage() to bottom of file and format 2019-06-08 03:23:50 -07:00
Daniel Agar 933dd1357e navigator move print_usage() to bottom of file 2019-06-08 03:23:50 -07:00
Daniel Agar d9c5fb0500 mc_att_control move print_usage() to bottom of file and format 2019-06-08 03:23:50 -07:00
Daniel Agar 97c2dba2fa logger move print_usage() to bottom of file and format 2019-06-08 03:23:50 -07:00
Daniel Agar e428829b84 drivers/heater move print_usage() to bottom of file and format" 2019-06-08 03:23:50 -07:00
Daniel Agar 6c495bc4a3 leddar_one move help to bottom and format 2019-06-08 03:23:50 -07:00
Daniel Agar 63d582464e mc_pos_control move print_usage() to bottom of file and format 2019-06-08 03:23:50 -07:00
Julian Oes d2c824c534 gpssim: don't advertize uninitialized data
According to valgrind uninitialized bytes were being advertized.
2019-06-07 17:10:35 -04:00
Daniel Agar 90bf26b239 CollisionPrevention move orb subscriptions to uORB::Subscription 2019-06-07 09:22:35 -04:00
Daniel Agar 5669df4ca4 mc_pos_control move orb subscriptions to new uORB::Subscription 2019-06-07 09:22:35 -04:00
Daniel Agar be02ad3514 fw_att_control move orb subscriptions to uORB::Subscription 2019-06-06 20:02:02 -04:00
Daniel Agar 4bef573497 fw_pos_control_l1 move to new uORB::Subscription 2019-06-06 20:00:02 -04:00
Daniel Agar 528d2f61a0 sensors partially move to new uORB::Subscription 2019-06-06 19:07:17 -04:00
Daniel Agar 55c9786157 PX4Magnetometer implement MAGIOCGSCALE (copy out scale)
- fixes #12193
2019-06-06 14:10:13 -04:00
Beat Küng ab0466eddf omnibus: enable dmesg buffer (3kb)
without LPE running, we have about 17.6 kb more free RAM.
2019-06-06 11:11:44 -04:00
Beat Küng 223e3c6429 aerofc rc.board_defaults: remove wrong parameter settings
This was a regression.
2019-06-06 11:11:44 -04:00
Beat Küng 73102dc3c4 SYS_MC_EST_GROUP: add q estimator only option and activate on omnibus 2019-06-06 11:11:44 -04:00
Beat Küng 1321f96b59 omnibus rc.board_defaults: remove flash-based params transition logic 2019-06-06 11:11:44 -04:00
Beat Küng 5c715978e8 param compare/greater: do not print 'parameter not found' message
Reduces clutter in the boot output (now that we have it in the log).
On omnibus for example we see:
ERROR [param] Parameter SENS_EN_BATT not found
ERROR [param] Parameter SENS_EN_LL40LS not found
ERROR [param] Parameter SENS_EN_LL40LS not found
ERROR [param] Parameter SENS_EN_MB12XX not found
ERROR [param] Parameter SENS_EN_PGA460 not found
ERROR [param] Parameter SENS_EN_SF1XX not found
ERROR [param] Parameter SENS_EN_TRANGER not found
2019-06-06 09:16:49 -04:00
Julian Kent 0553d4d01e Fix px_uploader.py to work in 16.04 with Python 2.7.
Before, the pyserial check would fail before it could check for the
VERSION that the Python 2.7 version contains. This fixes it to check
for the VERSION independently.
2019-06-06 09:13:54 -04:00
Tanja Baumann fcec3b3efc px4_fmu-v4: increase uart buffer sizes for vision algorithms (#12199) 2019-06-06 09:01:42 -04:00
Daniel Agar 3796dda209 ekf2 move most orb subscriptions to uORB::Subscription 2019-06-06 08:22:15 +02:00
Daniel Agar cecd009ddc mc_att_control: fix vehicle_rates_setpoint_poll() error due to merge timing 2019-06-05 21:18:02 -04:00
Daniel Agar ca5651bd8b heater move to new WQ and uORB::Subscription 2019-06-05 20:38:42 -04:00
Daniel Agar 4c42cac380 mc_att_control move most orb subscriptions to uORB::Subscription 2019-06-05 20:37:47 -04:00
Daniel Agar c0e735c88a vtol_att_control move to new uORB::Subscription 2019-06-05 20:33:20 -04:00
Daniel Agar 71d58c9278 wind_estimator move to new WQ (lp_default) and uORB::Subscription 2019-06-05 20:31:16 -04:00
Daniel Agar e4ad994763 navigator move to new uORB::Subscription 2019-06-05 20:28:44 -04:00
David Sidrane 79eb74be3f Fix bmp280 on FMUv4 2019-06-05 15:43:53 -04:00
Daniel Agar 9d726cb0c4 bmi160 move to PX4Accelerometer and PX4Gyroscope and cleanup (#12128) 2019-06-05 11:25:18 -07:00
bresch ac4458460d FailureDetector - update hysteresis to comply with new interface 2019-06-05 16:53:08 +02:00
bresch 57c2085ce4 IO driver - Recover flight termination state from IO after FMU reboot in air 2019-06-05 16:53:08 +02:00
bresch c75f71abc2 IO failsafe - apply failsafe values to outputs when in failsafe.
This is required because otherwise, IO would output disarmed values if
FMU goes into a disarmed state.
2019-06-05 16:53:08 +02:00
bresch 96da46d1aa Failsafe - cosmetic changes 2019-06-05 16:53:08 +02:00
bresch 776b1a28de IO mixer - cleanup FMU timeout check (comments and indentation) 2019-06-05 16:53:08 +02:00
bresch c576c57d7b protocol.h - comment style update 2019-06-05 16:53:08 +02:00
bresch 4b8febf558 Flight termination IO - reword flight termination flag description 2019-06-05 16:53:08 +02:00
bresch 158463d0a0 Flight termination - Rename "flightterm" variables and defines to "flighttermination". 2019-06-05 16:53:08 +02:00
bresch 5becc24a1f Failure detector - in failure detector preflight check, get
vehicle_status as const type. Also use FAILURE_NONE enum to check for a
failure
2019-06-05 16:53:08 +02:00
bresch 33a94c8191 Failure detector - change snake_case function names to camelCase 2019-06-05 16:53:08 +02:00
bresch ee1f8f457b px4io - rename safety_param_val to circuit_breaker_io_enabled and change its type to bool since circuit_breaker_enabled returns a boolean 2019-06-05 16:53:08 +02:00
bresch 03ad4ffd47 FailureDetector - Add is_failure() function to simplify the interface; the user does not need to check the bitmask 2019-06-05 16:53:08 +02:00
bresch d3c9436f84 flight termination - rename in_flight_termination to flight_termination_triggered 2019-06-05 16:53:08 +02:00
bresch e8705f08c4 quad_x_main - rename parachute output to failsafe output 2019-06-05 16:53:08 +02:00
bresch 4eaf6e77be Flight termination - Always send flag to IO without checking the circuit breaker. The circuit breaker is used inside IO to decide if it has to go into failsafe if FMU dies and also controls is the FailureDetector sets the force_failsafe flag. The other sources of flight termination (rc loss, geo fence, ...) are not disabled by the circuit breaker 2019-06-05 16:53:08 +02:00
bresch 59265f6663 Failure detector - Add flight termination comments, make format 2019-06-05 16:53:08 +02:00
bresch 0655f7603b FailureDetector - Increase min value of FD_FAIL_P/R to 60 degrees 2019-06-05 16:53:08 +02:00
bresch d19614a94f MC Lnd detector - Remove double include 2019-06-05 16:53:08 +02:00
bresch 38345be41a FailureDetector - Add roll and pitch failures hysteresis 2019-06-05 16:53:08 +02:00
bresch a72de95c94 Failure detector - Disable flight termination by default. Modify FD_FAIL parameters description 2019-06-05 16:53:08 +02:00
bresch 81bb7888de Failure Detector - Add Failure Detector check to preflight checks 2019-06-05 16:53:08 +02:00
bresch c73875cbf8 quad x mixer - Add null mixer for parachute triggering 2019-06-05 16:53:08 +02:00
bresch 34fca5a552 PWM - Remove unused MIXERADDSIMPLE 2019-06-05 16:53:08 +02:00
bresch 7b531bcaef Failure Detector - Play TONE_PARACHUTE_RELEASE_TUNE when force failsafe is set 2019-06-05 16:53:08 +02:00
bresch d655c33faa IO mixer - Change default mixer to DISARMED and allow to set outputs to failsafe if FMU does not respond and if flight termination circuit breaker is not set 2019-06-05 16:53:08 +02:00
bresch 6fb1b4886c IO - Send flight termination circuit breaker state to IO through PX4IO_P_SETUP_ENABLE_FLIGHTTERM 2019-06-05 16:53:08 +02:00
bresch 796631db20 PX4IO driver - use "curcuit_breaker_enabled" function instead of manually checking its value 2019-06-05 16:53:08 +02:00
bresch 19bf080313 PX4ioFirmware - Clean should_arm, should_arm_nothrottle and should_always_enable_pwm indentation for better understanding 2019-06-05 16:53:08 +02:00
bresch ba93f9b983 FailureDetector - Update failure detector logic in commander. 2019-06-05 16:53:08 +02:00
bresch 664fff4a24 Px4io Driver - Remove unimplemented prototype 2019-06-05 16:53:08 +02:00
bresch b64a2a884b Circuit Breaker - Disable flight termination circuit breaker by default (reverts ab40008) -> Allow flight termination 2019-06-05 16:53:08 +02:00
bresch 50d75dc7a6 IOFirmware - Properly clear the alarm flags 2019-06-05 16:53:08 +02:00
Thomas Gubler cf15cef066 Param "User Flight Profile" : improve documentation 2019-06-05 06:45:43 -07:00
Thomas Gubler d8a4d70fce Add Param "User Flight Profile"
This param has no effect within the Firmware.

The param can be used for example:

* in log post processing to have context about the flight
* in ground stations to adapt the UI automatically
2019-06-05 06:45:43 -07:00
Daniel Agar 1d5684823d disable -fassociative-math (within -funsafe-math-optimizations) 2019-06-05 14:54:29 +02:00
Julian Oes e7d0cabb52 logger: fix uninitialized member variable
This was reported by Coverity Scan.
2019-06-05 14:46:03 +02:00
bresch d5298fccbd PWM_REV - Clarify use case. The user shoul not be tempted to use that
parameter to reverse the direction of a rotor.
2019-06-05 09:10:06 +02:00
Daniel Agar f2b4480e6b GPS driver update to uORB::Subscription 2019-06-05 08:18:02 +02:00
Julian Oes bece63866d platforms: remove px4_backtrace 2019-06-05 08:16:19 +02:00
Julian Oes 35074aaffd posix: remove segfault handler
I could not get a core dump without removing the segfault handler, hence
this change.
2019-06-05 08:16:19 +02:00
Julian Oes f3620f7018 Remove all leftover PX4_BACKTRACE calls 2019-06-05 08:16:19 +02:00
Julian Oes 5273e2af04 Tools: remove decode_backtrace.py
This hasn't been used in a while and didn't quite work with the
backtraces produced anyway.
2019-06-05 08:16:19 +02:00
Daniel Agar a1b96ba3a5 mpu9250 delete unused perf counters 2019-06-04 20:31:47 -04:00
Daniel Agar 26e041c43c WQ increase stacks from 1200 to 1250 bytes 2019-06-04 20:24:51 -04:00
Daniel Agar 574f7e9f00 batt_smbus move to new WQ 2019-06-04 19:54:06 -04:00
Daniel Agar 3faab909d7 commander move most orb subscriptions to uORB::Subscription 2019-06-04 18:44:51 -04:00
Daniel Agar 777b615cf9 land_detector move to PX4 WQ hp_default 2019-06-04 18:10:21 -04:00
Daniel Agar 53aa4130a8 land_detector move orb subscriptions to uORB::Subscription 2019-06-04 18:10:21 -04:00
baumanta 2320088541 use position controller parameters for limitation instead of acceleration/jerk 2019-06-04 16:47:33 +02:00
baumanta c497d94616 publish a minimal message for logging/debugging 2019-06-04 16:47:33 +02:00
baumanta 09e1d4888c use velocity component in bin direction instead of norm 2019-06-04 16:47:33 +02:00
baumanta 33cd032c35 camelcase function name, initialize c++11 style 2019-06-04 16:47:33 +02:00
baumanta e7d17cc265 consider acceleration ramp-up time 2019-06-04 16:47:33 +02:00
baumanta ab792093e1 fix wrong if clause 2019-06-04 16:47:33 +02:00
baumanta 23c23e3aa5 clean up 2019-06-04 16:47:33 +02:00
baumanta f50a1d58b0 bugfixes and cleanup 2019-06-04 16:47:33 +02:00
baumanta 4212ae8b87 sign bug fix and clean up 2019-06-04 16:47:33 +02:00
baumanta 60befdce5b change collision prevention algorithm 2019-06-04 16:47:33 +02:00
baumanta 8427cd3051 constant acceleration breaking for collision prevention 2019-06-04 16:47:33 +02:00
Julian Oes 6f9598c76a topic_listener: document how to exit
This was left out when the feature was added.
2019-06-04 09:24:00 -04:00
Daniel Agar ceac68e69d uORB remove unused SubscriptionInterval and SubscriptionIntervalData 2019-06-04 09:17:34 -04:00
Beat Küng d68dcb9cf7 log_writer_file: increase stack size by 20 bytes
Seems to be due to the console buffer.
2019-06-04 11:57:54 +02:00
Beat Küng 0d71eeccbf console buffer: write to log as 'boot_console_output' message 2019-06-04 11:57:54 +02:00
Beat Küng 08b8ee4831 replace fprintf(stderr with PX4_{INFO/WARN} 2019-06-04 11:57:54 +02:00
Beat Küng d947818654 console: add simple dmesg functionality (enable only on v5) 2019-06-04 11:57:54 +02:00
bresch 2307c7c390 Geofence - Rename _warning_action_on to _geofence_warning_action_on
since it is only set by the geofence logic. Simplify conditions in IF
statements.
2019-06-04 08:35:56 +02:00
bresch f8f967f073 Geofence - Change from "re-engage geofence failsafe every 10s when
outside the fence" to "engage geofence failsafe on transition". This
way, the pilot is not stucked in the non flight zone and can switch to
a manual mode and fly back or trigger RTL.
2019-06-04 08:35:56 +02:00
bresch 427b2e6636 Geofence - Do not trigger geofence failsafe while in low battery
failsafe action.
Also move geofence flags from static variables declared into the if
statement to private members of the class.
2019-06-04 08:35:56 +02:00
pedro-roque a707403eaf mc_att_ctrl: added yawrate control from offboard.
This commit adds Roll Pitch Yawrate Thrust (RPYrT) setpoint control to the
PX4 stack, enabling the UAV to follow specific yawrates sent from
offboard. It also introduces individual body_rate flags, along the
lines of mavros.

Tested on a MoCap enabled flight arena in KTH Royal Institute of
Technology, Stockholm. The MAV receives RPYrT setpoints from an
external PID controller to stabilize around position setpoints.
The UAV is also externally disturbed to assess the stability to
external unmodeled events.

Fixed Kabir comments.

Removed deprecated ignore_bodyrate.

Fixed integration test.
2019-06-04 08:26:09 +02:00
Matthias Grob ac002db25c MAVLink/Commander: @Pedro-Roque's offboard yawrate handling 2019-06-04 08:26:09 +02:00
Daniel Agar 579cbbb42c mavlink move to new lightweight uORB::Subscription 2019-06-03 17:06:21 -04:00
Daniel Agar 2c63e335e9 uORB::Subscription subscribe directly to uORB device node object 2019-06-03 17:06:21 -04:00
Daniel Agar 2d1c60bc85 SITL offboard ATT test reduce Z boundary requirement
- fixes #12155
2019-06-03 12:31:12 -04:00
rfauvet 755eccbe60 simulator: fixing missing declaration
The "len" variable was not defined and gave me an error, declaring it as "int" fixed it
2019-06-03 10:02:36 -04:00
mcsauder 8966ad59c7 Add distance sensor id to the the MavlinkStreamDistanceSensor class and format whitespace in mavlink_messages.cpp. 2019-06-01 14:23:49 -04:00
Daniel Agar 32fb2bae8c InvenSense MPU9250 move to PX4Accelerometer and PX4Gyroscope helpers 2019-05-31 21:43:30 -04:00
Daniel Agar cd45d8fc68 fxas21002c split out main and header 2019-05-31 18:20:32 -04:00
Daniel Agar b57dff8594 fxas21002c move to PX4Gyroscope and cleanup 2019-05-31 18:20:32 -04:00
Daniel Agar c8ea198a78 uavcan cmake FATAL_ERROR if platform isn't set
- this indicates a build system error
2019-05-31 12:20:50 -04:00
Daniel Agar 43e3fc707d simulator move to PX4Accelerometer, PX4Gyroscope, PX4Magnetometer, PX4Barometer helpers (#12081) 2019-05-30 21:07:26 -04:00
Daniel Agar 4a4d323a97 Update submodule mavlink v2.0 to latest Thu May 30 13:05:26 UTC 2019 (#12127)
- mavlink v2.0 in PX4/Firmware (a10b1afb54): https://github.com/mavlink/c_library_v2/commit/4b80386684d6823d43a87c53b28dc62570bfd42b
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/60df2613725c21f3eedc51251285f80a22e7d07d
    - Changes: https://github.com/mavlink/c_library_v2/compare/4b80386684d6823d43a87c53b28dc62570bfd42b...60df2613725c21f3eedc51251285f80a22e7d07d
2019-05-30 21:01:47 -04:00
Daniel Agar f85c15e247 board common create generic dma allocator (from fat_dma_alloc) 2019-05-30 19:31:40 -04:00
Daniel Agar bf12583d80 fw_pos_control_l1 replace FW_LND_THRTC_SC param description < character
- fixes #12124
2019-05-30 18:03:03 -04:00
Daniel Agar e4926373e6 INA226 move to new WQ and cleanup 2019-05-30 10:22:15 -07:00
Daniel Agar a10b1afb54 vtol_att_control vtol_type enum -> enum class 2019-05-30 09:04:08 -04:00
bresch d13dfdcd24 AutoLineSmoothVel - Remove duplicate of _yaw_sp_prev update. This is done in the Auto FlightTask, _limit_yaw_rate 2019-05-30 11:14:44 +02:00
bresch a7cf981c8c AutoLineSmoothVel - Reduce jerk if acceleration, velocity and desired velocity are small to help the optimizer to converge towards zero 2019-05-30 11:14:44 +02:00
bresch 3499b6ff89 AutoLineSmoothVel - Do not generate heading from trajectory if the velocity vector is smaller than 10cm/s
This is done to avoid generating large yaw changes when the velocity
vector is small; for example when switching into loiter or reaching the
last waypoint.
2019-05-30 11:14:44 +02:00
Daniel Agar 21c791e959 listener exit with ctrl-c, escape, or q 2019-05-30 10:53:06 +02:00
Julian Oes 2ac8841f35 vtol/fw/mc: fix VTOL enum shadowing
This changes the enums used for various VTOL states to enum classes
which makes them type-safe and should avoid shadowing.

This change was motivated by a Clang warning about shadowing of the
enum const TRANSITION_TO_FW which was declared twice, once in
vtol_type.h and once in standard.h.

This change only removes the shadowing but presumably these enums could
be cleaned up and consolidated further.
2019-05-29 23:51:10 -04:00
Daniel Agar 4b3f68f90c cmake and Tools/setup.sh default to python3 2019-05-29 20:48:22 -04:00
Daniel Agar f593e3de9c AK09916 move to new WQ, PX4Magnetometer, and cleanup 2019-05-29 13:59:08 -04:00
Daniel Agar a523e18c13 ST L3GD20 move to PX4Gyroscope helper 2019-05-29 13:56:18 -04:00
Martina Rivizzigno 119ccc4256 ObstacleAvoidance: fix comment 2019-05-29 15:16:33 +02:00
Martina Rivizzigno 61f69ed139 ObstacleAvoidance: use convention for paramter name 2019-05-29 15:16:33 +02:00
Martina Rivizzigno 1e8582974c do not update desired setpoints and waypoints if the oa is disabled 2019-05-29 15:16:33 +02:00
Martina Rivizzigno 0963dc9af1 ObstacleAvoidance: fix bug in requesting update of the mission item.
During takeoff you're always in the condition within xy acceptance radius
and more than altitude radius away from the takeoff waypoint
2019-05-29 15:16:33 +02:00
Martina Rivizzigno 9e8575b71b do not overwrite with obstacle avoidance yaw setpoints if external yaw
handling is enabled
2019-05-29 15:16:33 +02:00
Martina Rivizzigno 44b8b4f79f send velocity setpoint to enable proper takeoff/land 2019-05-29 15:16:33 +02:00
Julian Oes b135503447 wqueue: check before dereferencing
This was found by coverity.
2019-05-29 08:57:46 -04:00
Julian Oes 29915cbc6d BlockingQueue: default initialize _data
This was reported by coverity.
2019-05-29 08:57:46 -04:00
Julian Oes 4d7a1afd92 Revert "Revert "simulator: remove hack for diff_pressure noise""
This reverts commit 2142459027.
2019-05-29 08:56:33 -04:00
Beat Küng ed9d25a75a logger: add arming/disarming via AUX1 RC channel logging mode 2019-05-29 11:41:22 +02:00
Beat Küng 721f9f901f log_writer_file: fix race condition for fast consecutive stop & start calls 2019-05-29 11:41:22 +02:00
Beat Küng 03332aaa20 PX4Accelerometer,PX4Gyroscope: set_sample_rate requires a filter update 2019-05-29 09:15:52 +02:00
Beat Küng 6da78c956e SYS_COMPANION: remove this parameter
It was already deprecated.
2019-05-29 09:15:52 +02:00
Beat Küng 6e2b70cbcd posix: restore original SEGV signal handler upon first entry of our handler
The current SEGV handling on posix is not useful: as soon as our handler
is left, it's triggered again, infinitely.
This patch changes to restore the original handler, so the OS can create
a core dump, etc.
2019-05-29 08:30:52 +02:00
Mohammed Kabir b334b75886 Move optical flow drivers to own subdirectory 2019-05-28 23:23:38 -04:00
Daniel Agar 6627c60e5b load_mon move from NuttX LPWORK to PX4 work queue lp_default 2019-05-28 09:40:36 -04:00
Beat Küng 5d6cc7d033 ekf2: reduce GPS initialization time for SITL from 10s to 0.5s
Speeds up SITL startup.
2019-05-28 10:45:38 +02:00
Daniel Agar f7ff82c754 Bosch BMI055 IMU cleanup
- move to PX4Accelerometer and PX4Gyroscope helpers
2019-05-27 18:03:32 -04:00
Daniel Agar 03924704d5 Jenkins SITL tests temporarily disable tiltrotor 2019-05-27 15:23:08 +02:00
TSC21 bd87bee632 px4_posix.h: add px4_exit() 2019-05-27 15:22:37 +02:00
Matthias Grob 8a84472795 Hysteresis: switch unit test file name to convention 2019-05-27 09:57:50 +02:00
Julian Oes b29e5e3adb hysteresis: remove dependency/side effect on time 2019-05-27 09:57:50 +02:00
Julian Oes 7b9562e3b1 hysteresis: move out of systemlib, move to gtest
This moves the hysteresis test out of the systemlib and makes it its own
small library. Since it still depends on hrt_absolute_time this does not
link yet. My attempt to get all link dependencies together failed.
2019-05-27 09:57:50 +02:00
Daniel Agar b849991494 Update submodule mavlink v2.0 to latest Mon May 27 00:38:40 UTC 2019
- mavlink v2.0 in PX4/Firmware (61367199aca6aa135462db93c8c8063946876ad4): https://github.com/mavlink/c_library_v2/commit/57000134021fb8d5c2c6281e3783ce29bb35bc17
    - mavlink v2.0 current upstream: https://github.com/mavlink/c_library_v2/commit/4b80386684d6823d43a87c53b28dc62570bfd42b
    - Changes: https://github.com/mavlink/c_library_v2/compare/57000134021fb8d5c2c6281e3783ce29bb35bc17...4b80386684d6823d43a87c53b28dc62570bfd42b
2019-05-27 00:13:12 -04:00
Daniel Agar b3505bfbf4 Update submodule sitl_gazebo to latest Mon May 27 00:38:33 UTC 2019
- sitl_gazebo in PX4/Firmware (88127380e7): https://github.com/PX4/sitl_gazebo/commit/3062d287c322fabf1b41b8e33518eb449d4ac6ed
    - sitl_gazebo current upstream: https://github.com/PX4/sitl_gazebo/commit/a0b0eb8df12b11e8f63d3cc766dee97cefa32ab7
    - Changes: https://github.com/PX4/sitl_gazebo/compare/3062d287c322fabf1b41b8e33518eb449d4ac6ed...a0b0eb8df12b11e8f63d3cc766dee97cefa32ab7

 - a0b0eb8 2019-05-10 bazooka joe - Calculate iris inertia from the body colision parameters assuming that the body is homogenic cube. that fixes impossible inertia matrix
 - 113605b 2019-03-27 Elia Tarasov - fix gimbal_controller timestep sign
2019-05-26 23:57:26 -04:00
Daniel Agar 88127380e7 vscode add linker script extension to recommended 2019-05-25 14:21:45 -04:00
Daniel Agar d83a35a503 Update README.md
Co-Authored-By: LorenzMeier <lorenz@px4.io>
2019-05-25 20:08:36 +02:00
Daniel Agar 782d2033c0 Update README.md
Fix link for Roman

Co-Authored-By: LorenzMeier <lorenz@px4.io>
2019-05-25 20:08:36 +02:00
Lorenz Meier c3a58c31d3 Update the README to clarify component ownership
This represents more closely the actual maintenance model.
2019-05-25 20:08:36 +02:00
Beat Küng 800266741b Merge pull request #12063 from PX4/fix_custom_tune
fix tunes: make sure a custom tune gets played
2019-05-25 17:58:44 +02:00
Daniel Agar 9ab9a29a01 astyle don't enforce style in build output 2019-05-25 17:58:19 +02:00
Martina Rivizzigno a18f3e5d45 reset the position lock only if current triplet latitude and longitude
are valid
2019-05-24 21:40:42 +02:00
Daniel Agar c4c3bbbfb0 uORB simplify handling of subscriptions with configured intervals 2019-05-24 14:57:46 -04:00
Daniel Agar 8e6708bdcb qmc5883 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 5e427b4e46 adis16497 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 5ebb0d5d96 rpi_rc_in move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar da6210151c tone_alarm move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 8c3821c806 bst move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 525fdc87c7 pmw3901 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 104b1010bf pca9685 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 8f1b4f693b rm3100 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 8176fe1b6e lsm303agr move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar dffaf544ab lis3mdl move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 537c139134 bmm150 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 78d35f2677 linux_sbus move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 4dd017cd59 rgbled_pwm move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 23f7a662c6 rgbled_ncp5623c move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 6ec7730bf1 rgbled move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 4ac48f154d pca8574 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar e7f539f29a oreoled move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar d8dd592d20 blinkm move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar cdb207804d irlock move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 835a38f6dc vl53lxx move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 593aaa48ca tfmini move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar eb8fbaf93d teraranger move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar a1f3f2112b srf02 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 592037851a sf1xx move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar a6bbf0b945 sf0x move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar ce3b5103fc mb12xx move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 22b89034d9 ll40ls move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 4d41dcaee2 leddar_one move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 9a0f145fc0 hc_sr04 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 6ef42e2c52 cm8jl65 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar e73dd73ea7 mpl3115a2 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar b8befe36b9 lps25h move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 9003aeb216 lps22hb move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 1e7c6be839 bmp280 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar e1bc975065 drivers/differential_pressure move all to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 83d3ead821 ist8310 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar ec0d1d6f62 lsm303d move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 8b4ecc6947 icm20948 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar fc7f1ca598 fxos8701cq move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar d4ece2c7bb fxas21002c move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 9fa865d490 bmi160 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 370f0f73ce bma180 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar e27a8e1010 bmi055 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar be3653f761 l3gd20 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 427c49ac43 adis16477 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 6113caaa33 adis16448 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 16b26c1927 mpu6000 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 70947920b8 hmc5883 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar 56024cda79 ms5611 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar ea734f634d mpu9250 move to px4 work queue 2019-05-24 12:58:55 -04:00
Daniel Agar e9ca5d5aba PX4 general work queue 2019-05-24 12:58:55 -04:00
Beat Küng f58079bc5d pxh.cpp: fix invalid reference if words is empty
This can happen for example if 'line' is a space.
2019-05-24 11:06:41 -04:00
Matthias Grob 6eb29fca9d vscode: remove matter of taste tabs customization 2019-05-24 10:06:06 -04:00
3999 changed files with 331144 additions and 206184 deletions
-160
View File
@@ -1,160 +0,0 @@
#!/usr/bin/env groovy
pipeline {
agent none
stages {
stage('Build') {
agent {
docker {
image 'px4io/px4-dev-ros-kinetic:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'git fetch --tags'
sh 'make px4_sitl_default'
sh 'make px4_sitl_default sitl_gazebo'
sh 'make px4_sitl_default package'
sh 'ccache -s'
stash(name: "px4_sitl_package", includes: "build/px4_sitl_default/*.bz2")
archiveArtifacts(artifacts: "build/px4_sitl_default/*.bz2", fingerprint: true, onlyIfSuccessful: true)
}
post {
always {
sh 'make distclean'
}
}
} // stage Build
stage('ROS Tests') {
steps {
script {
def missions = [
[
name: "FW",
test: "mavros_posix_test_mission.test",
mission: "FW_mission_1",
vehicle: "plane"
],
[
name: "MC_box",
test: "mavros_posix_test_mission.test",
mission: "MC_mission_box",
vehicle: "iris"
],
[
name: "MC_offboard_att",
test: "mavros_posix_tests_offboard_attctl.test",
mission: "",
vehicle: "iris"
],
[
name: "MC_offboard_pos",
test: "mavros_posix_tests_offboard_posctl.test",
mission: "",
vehicle: "iris"
],
[
name: "VTOL_standard",
test: "mavros_posix_test_mission.test",
mission: "VTOL_mission_1",
vehicle: "standard_vtol"
],
[
name: "VTOL_tailsitter",
test: "mavros_posix_test_mission.test",
mission: "VTOL_mission_1",
vehicle: "tailsitter"
],
[
name: "VTOL_tiltrotor",
test: "mavros_posix_test_mission.test",
mission: "VTOL_mission_1",
vehicle: "tiltrotor"
],
[
name: "MC_avoidance",
test: "mavros_posix_test_avoidance.test",
mission: "avoidance",
vehicle: "iris_obs_avoid",
run_script: "rostest_avoidance_run.sh"
],
]
def test_nodes = [:]
for (def i = 0; i < missions.size(); i++) {
test_nodes.put(missions[i].name, createTestNode(missions[i]))
}
parallel test_nodes
} // script
} // steps
} // stage ROS Tests
} //stages
environment {
CCACHE_DIR = '/tmp/ccache'
CI = true
}
options {
buildDiscarder(logRotator(numToKeepStr: '10', artifactDaysToKeepStr: '30'))
timeout(time: 60, unit: 'MINUTES')
}
} // pipeline
def createTestNode(Map test_def) {
return {
node {
cleanWs()
docker.image("px4io/px4-dev-ros-kinetic:2019-03-08").inside('-e HOME=${WORKSPACE}') {
stage(test_def.name) {
def run_script = test_def.get('run_script', 'rostest_px4_run.sh')
def test_ok = true
sh('export')
unstash('px4_sitl_package')
sh('tar -xjpvf build/px4_sitl_default/px4-px4_sitl_default*.bz2')
// run test
try {
sh('px4-px4_sitl_default*/px4/test/' + run_script + ' ' + test_def.test + ' mission:=' + test_def.mission + ' vehicle:=' + test_def.vehicle)
} catch (exc) {
// save all test artifacts for debugging
archiveArtifacts(allowEmptyArchive: false, artifacts: '.ros/**/*.ulg, .ros/**/rosunit-*.xml, .ros/**/rostest-*.log')
test_ok = false
}
// log analysis
// process ekf log data
try {
sh('px4-px4_sitl_default*/px4/Tools/ecl_ekf/process_logdata_ekf.py .ros/log/*/*.ulg')
} catch (exc) {
// save log analysis artifacts for debugging
archiveArtifacts(allowEmptyArchive: false, artifacts: '.ros/**/*.pdf, .ros/**/*.csv')
// FIXME: don't let the script to fail the build
// test_ok = false
}
// upload log to flight review (https://logs.px4.io/)
sh('px4-px4_sitl_default*/px4/Tools/upload_log.py -q --description "${JOB_NAME}: ${STAGE_NAME}" --feedback "${JOB_NAME} ${CHANGE_TITLE} ${CHANGE_URL}" --source CI .ros/log/*/*.ulg')
if (!test_ok) {
error('ROS Test failed')
}
} // stage
cleanWs()
} // docker.image
} // node
} // return
} // createTestNode
-153
View File
@@ -1,153 +0,0 @@
#!/usr/bin/env groovy
pipeline {
agent none
stages {
stage('Build') {
agent {
docker {
image 'px4io/px4-dev-ros-kinetic:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw -e HOME=$WORKSPACE'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'git fetch --tags'
sh 'make px4_sitl_default'
sh 'make px4_sitl_default sitl_gazebo'
sh 'make px4_sitl_default package'
sh 'ccache -s'
stash(name: "px4_sitl_package", includes: "build/px4_sitl_default/*.bz2")
//archiveArtifacts(artifacts: "build/px4_sitl_default/*.bz2", fingerprint: true, onlyIfSuccessful: true)
}
post {
always {
sh 'make distclean'
}
}
} // stage Build
stage('ROS Tests') {
steps {
script {
def missions = [
[
name: "FW",
test: "mavros_posix_test_mission.test",
mission: "FW_mission_1",
vehicle: "plane"
],
[
name: "MC_box",
test: "mavros_posix_test_mission.test",
mission: "MC_mission_box",
vehicle: "iris"
],
[
name: "MC_offboard_att",
test: "mavros_posix_tests_offboard_attctl.test",
mission: "",
vehicle: "iris"
],
[
name: "MC_offboard_pos",
test: "mavros_posix_tests_offboard_posctl.test",
mission: "",
vehicle: "iris"
],
[
name: "VTOL_standard",
test: "mavros_posix_test_mission.test",
mission: "VTOL_mission_1",
vehicle: "standard_vtol"
],
[
name: "VTOL_tailsitter",
test: "mavros_posix_test_mission.test",
mission: "VTOL_mission_1",
vehicle: "tailsitter"
],
[
name: "VTOL_tiltrotor",
test: "mavros_posix_test_mission.test",
mission: "VTOL_mission_1",
vehicle: "tiltrotor"
],
]
def test_nodes = [:]
for (def i = 0; i < missions.size(); i++) {
test_nodes.put(missions[i].name, createTestNode(missions[i]))
}
parallel test_nodes
} // script
} // steps
} // stage ROS Tests
} //stages
environment {
CCACHE_DIR = '/tmp/ccache'
CI = true
PX4_CMAKE_BUILD_TYPE = 'AddressSanitizer'
}
options {
buildDiscarder(logRotator(numToKeepStr: '10', artifactDaysToKeepStr: '30'))
timeout(time: 60, unit: 'MINUTES')
}
} // pipeline
def createTestNode(Map test_def) {
return {
node {
cleanWs()
docker.image("px4io/px4-dev-ros-kinetic:2019-03-08").inside('-e HOME=${WORKSPACE}') {
stage(test_def.name) {
def test_ok = true
sh('export')
unstash('px4_sitl_package')
sh('tar -xjpvf build/px4_sitl_default/px4-px4_sitl_default*.bz2')
// run test
try {
sh('px4-px4_sitl_default*/px4/test/rostest_px4_run.sh ' + test_def.test + ' mission:=' + test_def.mission + ' vehicle:=' + test_def.vehicle)
} catch (exc) {
// save all test artifacts for debugging
archiveArtifacts(allowEmptyArchive: false, artifacts: '.ros/**/*.ulg, .ros/**/rosunit-*.xml, .ros/**/rostest-*.log')
test_ok = false
}
// log analysis
// process ekf log data
try {
sh('px4-px4_sitl_default*/px4/Tools/ecl_ekf/process_logdata_ekf.py .ros/log/*/*.ulg')
} catch (exc) {
// save log analysis artifacts for debugging
archiveArtifacts(allowEmptyArchive: false, artifacts: '.ros/**/*.pdf, .ros/**/*.csv')
// FIXME: don't let the script to fail the build
// test_ok = false
}
// upload log to flight review (https://logs.px4.io/)
sh('px4-px4_sitl_default*/px4/Tools/upload_log.py -q --description "${JOB_NAME}: ${STAGE_NAME}" --feedback "${JOB_NAME} ${CHANGE_TITLE} ${CHANGE_URL}" --source CI .ros/log/*/*.ulg')
if (!test_ok) {
error('ROS Test failed')
}
} // stage
cleanWs()
} // docker.image
} // node
} // return
} // createTestNode
-182
View File
@@ -1,182 +0,0 @@
#!/usr/bin/env groovy
pipeline {
agent none
stages {
stage('ROS Tests') {
steps {
script {
def missions = [
[
name: "FW",
test: "mavros_posix_test_mission.test",
mission: "FW_mission_1",
vehicle: "plane"
],
[
name: "MC_box",
test: "mavros_posix_test_mission.test",
mission: "MC_mission_box",
vehicle: "iris"
],
[
name: "MC_offboard_att",
test: "mavros_posix_tests_offboard_attctl.test",
mission: "",
vehicle: "iris"
],
[
name: "MC_offboard_pos",
test: "mavros_posix_tests_offboard_posctl.test",
mission: "",
vehicle: "iris"
],
[
name: "VTOL_standard",
test: "mavros_posix_test_mission.test",
mission: "VTOL_mission_1",
vehicle: "standard_vtol"
],
[
name: "VTOL_tailsitter",
test: "mavros_posix_test_mission.test",
mission: "VTOL_mission_1",
vehicle: "tailsitter"
],
[
name: "VTOL_tiltrotor",
test: "mavros_posix_test_mission.test",
mission: "VTOL_mission_1",
vehicle: "tiltrotor"
],
]
def test_nodes = [:]
for (def i = 0; i < missions.size(); i++) {
test_nodes.put(missions[i].name, createTestNode(missions[i]))
}
parallel test_nodes
} // script
} // steps
} // stage ROS Tests
stage('Coverage') {
parallel {
stage('code coverage (python)') {
agent {
docker {
image 'px4io/px4-dev-base-bionic:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'make python_coverage'
withCredentials([string(credentialsId: 'FIRMWARE_CODECOV_TOKEN', variable: 'CODECOV_TOKEN')]) {
sh 'curl -s https://codecov.io/bash | bash -s - -F python'
}
sh 'make distclean'
}
}
stage('unit tests') {
agent {
docker {
image 'px4io/px4-dev-base-bionic:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'make px4_sitl_test test_results_junit'
withCredentials([string(credentialsId: 'FIRMWARE_CODECOV_TOKEN', variable: 'CODECOV_TOKEN')]) {
sh 'curl -s https://codecov.io/bash | bash -s - -F unittest'
}
sh 'make distclean'
}
}
} // parallel
} // stage Coverage
} //stages
environment {
CCACHE_DIR = '/tmp/ccache'
CI = true
CTEST_OUTPUT_ON_FAILURE = 1
PX4_CMAKE_BUILD_TYPE = 'Coverage'
}
options {
buildDiscarder(logRotator(numToKeepStr: '10', artifactDaysToKeepStr: '30'))
timeout(time: 60, unit: 'MINUTES')
}
} // pipeline
def createTestNode(Map test_def) {
return {
node {
cleanWs()
docker.image("px4io/px4-dev-ros-kinetic:2019-03-08").inside('-e HOME=${WORKSPACE}') {
stage(test_def.name) {
def test_ok = true
sh('export')
checkout(scm)
// run test
try {
sh('make distclean')
sh('ccache -z')
sh('make px4_sitl_default')
sh('make px4_sitl_default sitl_gazebo')
sh('ccache -s')
sh('make rostest_run TEST_FILE=' + test_def.test + ' TEST_MISSION=' + test_def.mission + ' TEST_VEHICLE=' + test_def.vehicle)
} catch (exc) {
// save all test artifacts for debugging
archiveArtifacts(allowEmptyArchive: false, artifacts: '.ros/**/*.ulg, .ros/**/rosunit-*.xml, .ros/**/rostest-*.log')
test_ok = false
}
// log analysis
withCredentials([string(credentialsId: 'FIRMWARE_CODECOV_TOKEN', variable: 'CODECOV_TOKEN')]) {
sh 'curl -s https://codecov.io/bash | bash -s - -F sitl_mission_${STAGE_NAME}'
// process log data (with python code coverage)
try {
//sh('coverage run -p Tools/ecl_ekf/process_logdata_ekf.py .ros/log/*/*.ulg')
sh('Tools/ecl_ekf/process_logdata_ekf.py .ros/log/*/*.ulg')
} catch (exc) {
// save log analysis artifacts for debugging
archiveArtifacts(allowEmptyArchive: false, artifacts: '.ros/**/*.pdf, .ros/**/*.csv')
// FIXME: don't let the script to fail the build
// test_ok = false
}
// upload log to flight review (https://logs.px4.io/) with python code coverage
sh('coverage run -p Tools/upload_log.py -q --description "${JOB_NAME}: ${STAGE_NAME}" --feedback "${JOB_NAME} ${CHANGE_TITLE} ${CHANGE_URL}" --source CI .ros/log/*/*.ulg')
// upload python code coverage to codecov.io
sh 'curl -s https://codecov.io/bash | bash -s - -X gcov -F sitl_python_${STAGE_NAME}'
}
if (!test_ok) {
error('ROS Test failed')
}
} // stage
cleanWs()
} // docker.image
} // node
} // return
} // createTestNode
+66 -29
View File
@@ -9,20 +9,25 @@ pipeline {
script {
def build_nodes = [:]
def docker_images = [
armhf: "px4io/px4-dev-armhf:2019-03-08",
base: "px4io/px4-dev-base-bionic:2019-03-08",
nuttx: "px4io/px4-dev-nuttx:2019-03-08",
ros: "px4io/px4-dev-ros-kinetic:2019-03-08",
rpi: "px4io/px4-dev-raspi:2019-03-08",
snapdragon: "lorenzmeier/px4-dev-snapdragon:2018-09-12"
armhf: "px4io/px4-dev-armhf:2020-04-01",
arm64: "px4io/px4-dev-aarch64:latest",
base: "px4io/px4-dev-base-bionic:2020-04-01",
nuttx: "px4io/px4-dev-nuttx-focal:2020-09-14",
snapdragon: "lorenzmeier/px4-dev-snapdragon:2020-04-01"
]
def armhf_builds = [
target: ["aerotenna_ocpoc_ubuntu"],
target: ["aerotenna_ocpoc_default", "beaglebone_blue_default", "emlid_navio2_default", "px4_raspberrypi_default", "scumaker_pilotpi_default"],
image: docker_images.armhf,
archive: false
]
def arm64_builds = [
target: ["scumaker_pilotpi_arm64"],
image: docker_images.arm64,
archive: false
]
def base_builds = [
target: ["px4_sitl_rtps"],
image: docker_images.base,
@@ -31,37 +36,69 @@ pipeline {
def nuttx_builds_archive = [
target: [
"px4_fmu-v2_default", "px4_fmu-v2_fixedwing", "px4_fmu-v2_lpe", "px4_fmu-v2_multicopter", "px4_fmu-v2_rover", "px4_fmu-v2_test",
"airmind_mindpx-v2_default",
"av_x-v1_default",
"bitcraze_crazyflie_default",
"cuav_can-gps-v1_canbootloader",
"cuav_can-gps-v1_default",
"cuav_nora_default",
"cuav_x7pro_default",
"cubepilot_cubeorange_console",
"cubepilot_cubeorange_default",
"cubepilot_cubeyellow_console",
"cubepilot_cubeyellow_default",
"holybro_durandal-v1_default",
"holybro_kakutef7_default",
"holybro_pix32v5_default",
"intel_aerofc-v1_default",
"modalai_fc-v1_default",
"mro_ctrl-zero-f7_default",
"mro_x21-777_default",
"mro_x21_default",
"nxp_fmuk66-v3_default",
"nxp_fmuk66-v3_socketcan",
"nxp_fmuk66-v3_rtps",
"nxp_fmurt1062-v1_default",
"nxp_ucans32k146_default",
"omnibus_f4sd_default",
"px4_fmu-v2_default",
"px4_fmu-v2_fixedwing",
"px4_fmu-v2_lpe",
"px4_fmu-v2_multicopter",
"px4_fmu-v2_rover",
"px4_fmu-v2_test",
"px4_fmu-v3_default",
"px4_fmu-v4_cannode",
"px4_fmu-v4_default",
"px4_fmu-v4_optimized",
"px4_fmu-v4pro_default",
"px4_fmu-v5_default", "px4_fmu-v5_fixedwing", "px4_fmu-v5_multicopter", "px4_fmu-v5_rover", "px4_fmu-v5_rtps", "px4_fmu-v5_stackcheck",
"intel_aerofc-v1_default", "auav_x21_default", "av_x-v1_default", "bitcraze_crazyflie_default", "airmind_mindpx-v2_default",
"nxp_fmuk66-v3_default", "omnibus_f4sd_default"],
"px4_fmu-v5_default",
"px4_fmu-v5_debug",
"px4_fmu-v5_fixedwing",
"px4_fmu-v5_multicopter",
"px4_fmu-v5_optimized",
"px4_fmu-v5_rover",
"px4_fmu-v5_rtps",
"px4_fmu-v5_stackcheck",
"px4_fmu-v5x_base_phy_DP83848C",
"px4_fmu-v5x_default",
"px4_fmu-v6x_default",
"px4_io-v2_default",
"spracing_h7extreme_default",
"uvify_core_default"
],
image: docker_images.nuttx,
archive: true
]
def nuttx_builds_other = [
target: ["px4_cannode-v1_default", "px4_esc-v1_default", "thiemar_s2740vc-v1_default"],
image: docker_images.nuttx,
archive: false
]
def rpi_builds = [
target: ["emlid_navio2_cross", "parrot_bebop_default"],
image: docker_images.rpi,
archive: false
]
def snapdragon_builds = [
target: ["atlflight_eagle_qurt-default", "atlflight_eagle_default"],
target: ["atlflight_eagle_qurt", "atlflight_eagle_default"],
image: docker_images.snapdragon,
archive: false
]
def docker_builds = [
armhf_builds, base_builds, nuttx_builds_archive, nuttx_builds_other, rpi_builds, snapdragon_builds
armhf_builds, base_builds, nuttx_builds_archive//, snapdragon_builds
]
for (def build_type = 0; build_type < docker_builds.size(); build_type++) {
@@ -81,7 +118,7 @@ pipeline {
// TODO: actually upload artifacts to S3
// stage('S3 Upload') {
// agent {
// docker { image 'px4io/px4-dev-base-bionic:2019-03-08' }
// docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
// }
// options {
// skipDefaultCheckout()
@@ -105,7 +142,7 @@ pipeline {
CI = true
}
options {
buildDiscarder(logRotator(numToKeepStr: '2', artifactDaysToKeepStr: '14'))
buildDiscarder(logRotator(numToKeepStr: '5', artifactDaysToKeepStr: '14'))
timeout(time: 60, unit: 'MINUTES')
}
}
@@ -115,7 +152,7 @@ def createBuildNode(Boolean archive, String docker_image, String target) {
// TODO: fix the snapdragon image
bypass_entrypoint = ''
if (docker_image == 'lorenzmeier/px4-dev-snapdragon:2018-09-12') {
if (docker_image == 'lorenzmeier/px4-dev-snapdragon:2020-04-01') {
bypass_entrypoint = ' --entrypoint=""'
}
@@ -128,7 +165,7 @@ def createBuildNode(Boolean archive, String docker_image, String target) {
checkout(scm)
sh('make distclean')
sh('git fetch --tags')
sh('ccache -z')
sh('ccache -s')
sh('make ' + target)
sh('ccache -s')
sh('make sizes')
-87
View File
@@ -1,87 +0,0 @@
#!/usr/bin/env groovy
pipeline {
agent none
stages {
stage('Build') {
parallel {
stage('px4_sitl_default (OSX)') {
agent {
label 'mac'
}
environment {
CCACHE_BASEDIR = "${env.WORKSPACE}"
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'make px4_sitl_default'
sh 'ccache -s'
}
post {
always {
sh 'make distclean'
}
}
} // stage px4_sitl_default
stage('px4_fmu-v5_default (OSX)') {
agent {
label 'mac'
}
environment {
CCACHE_BASEDIR = "${env.WORKSPACE}"
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'make px4_fmu-v5_default'
sh 'ccache -s'
}
post {
always {
sh 'make distclean'
}
}
} // stage px4_fmu-v5_default
stage('sitl tests (OSX)') {
agent {
label 'mac'
}
environment {
CCACHE_BASEDIR = "${env.WORKSPACE}"
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'make tests'
sh 'ccache -s'
}
post {
always {
sh 'make distclean'
}
}
} // stage sitl tests
} // parallel
} // stage Build
} // stages
environment {
CCACHE_CPP2 = '1'
CCACHE_DIR = '/tmp/ccache'
CI = true
}
options {
buildDiscarder(logRotator(numToKeepStr: '10', artifactDaysToKeepStr: '30'))
timeout(time: 120, unit: 'MINUTES')
}
}
+1005 -320
View File
File diff suppressed because it is too large Load Diff
+100 -82
View File
@@ -1,89 +1,107 @@
Checks: '*
,-cert-dcl50-cpp
,-cert-env33-c
,-cert-err34-c
,-cert-err58-cpp
,-cert-msc30-c
,-cert-msc50-cpp
,-clang-analyzer-core.CallAndMessage
,-clang-analyzer-core.NullDereference
,-clang-analyzer-core.UndefinedBinaryOperatorResult
,-clang-analyzer-core.uninitialized.Assign
,-clang-analyzer-core.VLASize
,-clang-analyzer-cplusplus.NewDelete
,-clang-analyzer-cplusplus.NewDeleteLeaks
,-clang-analyzer-deadcode.DeadStores
,-clang-analyzer-optin.cplusplus.VirtualCall
,-clang-analyzer-optin.performance.Padding
,-clang-analyzer-security.insecureAPI.strcpy
,-clang-analyzer-unix.API
,-clang-analyzer-unix.cstring.BadSizeArg
,-clang-analyzer-unix.Malloc
,-clang-analyzer-unix.MallocSizeof
,-cppcoreguidelines-c-copy-assignment-signature
,-cppcoreguidelines-interfaces-global-init
,-cppcoreguidelines-no-malloc
,-cppcoreguidelines-pro-bounds-array-to-pointer-decay
,-cppcoreguidelines-pro-bounds-constant-array-index
,-cppcoreguidelines-pro-bounds-pointer-arithmetic
,-cppcoreguidelines-pro-type-const-cast
,-cppcoreguidelines-pro-type-cstyle-cast
,-cppcoreguidelines-pro-type-member-init
,-cppcoreguidelines-pro-type-reinterpret-cast
,-cppcoreguidelines-pro-type-union-access
,-cppcoreguidelines-pro-type-vararg
,-cppcoreguidelines-special-member-functions
,-google-build-using-namespace
,-google-explicit-constructor
,-google-global-names-in-headers
,-google-readability-casting
,-google-readability-namespace-comments
,-google-readability-todo
,-google-runtime-int
,-google-runtime-references
,-llvm-header-guard
,-llvm-include-order
,-llvm-namespace-comment
,-misc-incorrect-roundings
,-misc-macro-parentheses
,-misc-misplaced-widening-cast
,-misc-redundant-expression
,-misc-unconventional-assign-operator
,-misc-unused-parameters
,-modernize-deprecated-headers
,-modernize-loop-convert
,-modernize-use-auto
,-modernize-use-bool-literals
,-modernize-use-default-member-init
,-modernize-use-emplace
,-modernize-use-equals-default
,-modernize-use-equals-delete
,-modernize-use-override
,-modernize-use-using
,-modernize-pass-by-value
,-performance-inefficient-string-concatenation
,-readability-avoid-const-params-in-decls
,-readability-else-after-return
,-readability-implicit-bool-cast
,-readability-inconsistent-declaration-parameter-name
,-readability-non-const-parameter
,-readability-redundant-declaration
,-readability-redundant-member-init
,-readability-simplify-boolean-expr
'
---
Checks: '*,
-android*,
-bugprone-integer-division,
-cert-dcl50-cpp,
-cert-env33-c,
-cert-err34-c,
-cert-err58-cpp,
-cert-msc30-c,
-cert-msc50-cpp,
-clang-analyzer-core.CallAndMessage,
-clang-analyzer-core.NullDereference,
-clang-analyzer-core.UndefinedBinaryOperatorResult,
-clang-analyzer-core.uninitialized.Assign,
-clang-analyzer-core.VLASize,
-clang-analyzer-cplusplus.NewDelete,
-clang-analyzer-cplusplus.NewDeleteLeaks,
-clang-analyzer-deadcode.DeadStores,
-clang-analyzer-optin.cplusplus.VirtualCall,
-clang-analyzer-optin.performance.Padding,
-clang-analyzer-security.insecureAPI.strcpy,
-clang-analyzer-unix.API,
-clang-analyzer-unix.cstring.BadSizeArg,
-clang-analyzer-unix.Malloc,
-clang-analyzer-unix.MallocSizeof,
-cppcoreguidelines-c-copy-assignment-signature,
-cppcoreguidelines-interfaces-global-init,
-cppcoreguidelines-no-malloc,
-cppcoreguidelines-owning-memory,
-cppcoreguidelines-pro-bounds-array-to-pointer-decay,
-cppcoreguidelines-pro-bounds-constant-array-index,
-cppcoreguidelines-pro-bounds-pointer-arithmetic,
-cppcoreguidelines-pro-type-const-cast,
-cppcoreguidelines-pro-type-cstyle-cast,
-cppcoreguidelines-pro-type-member-init,
-cppcoreguidelines-pro-type-reinterpret-cast,
-cppcoreguidelines-pro-type-union-access,
-cppcoreguidelines-pro-type-vararg,
-cppcoreguidelines-special-member-functions,
-fuchsia-default-arguments,
-fuchsia-overloaded-operator,
-google-build-using-namespace,
-google-explicit-constructor,
-google-global-names-in-headers,
-google-readability-casting,
-google-readability-function-size,
-google-readability-namespace-comments,
-google-readability-todo,
-google-runtime-int,
-google-runtime-references,
-hicpp-deprecated-headers,
-hicpp-explicit-conversions,
-hicpp-function-size,
-hicpp-member-init,
-hicpp-no-array-decay,
-hicpp-no-assembler,
-hicpp-no-malloc,
-hicpp-signed-bitwise,
-hicpp-special-member-functions,
-hicpp-use-auto,
-hicpp-use-equals-default,
-hicpp-use-equals-delete,
-hicpp-use-override,
-hicpp-vararg,
-llvm-header-guard,
-llvm-include-order,
-llvm-namespace-comment,
-misc-incorrect-roundings,
-misc-macro-parentheses,
-misc-misplaced-widening-cast,
-misc-redundant-expression,
-misc-unconventional-assign-operator,
-misc-unused-parameters,
-modernize-deprecated-headers,
-modernize-loop-convert,
-modernize-pass-by-value,
-modernize-return-braced-init-list,
-modernize-use-auto,
-modernize-use-bool-literals,
-modernize-use-default-member-init,
-modernize-use-equals-default,
-modernize-use-equals-delete,
-modernize-use-override,
-modernize-use-using,
-performance-inefficient-string-concatenation,
-readability-avoid-const-params-in-decls,
-readability-container-size-empty,
-readability-else-after-return,
-readability-function-size,
-readability-implicit-bool-cast,
-readability-implicit-bool-conversion,
-readability-inconsistent-declaration-parameter-name,
-readability-named-parameter,
-readability-non-const-parameter,
-readability-redundant-declaration,
-readability-static-accessed-through-instance,
-readability-static-definition-in-anonymous-namespace,
'
WarningsAsErrors: '*'
CheckOptions:
- key: google-readability-braces-around-statements.ShortStatementLines
value: '1'
CheckOptions:
- key: google-readability-function-size.BranchThreshold
value: '600'
- key: google-readability-function-size.LineThreshold
value: '4000'
- key: google-readability-function-size.StatementThreshold
value: '4000'
- key: readability-braces-around-statements.ShortStatementLines
value: '1'
- key: readability-function-size.LineThreshold
value: '4000'
- key: readability-function-size.StatementThreshold
value: '4000'
...
+42
View File
@@ -0,0 +1,42 @@
// For format details, see https://aka.ms/vscode-remote/devcontainer.json or this file's README at:
// https://github.com/microsoft/vscode-dev-containers/tree/v0.134.0/containers/cpp
{
"name": "px4-dev-nuttx",
"image": "px4io/px4-dev-nuttx-focal:2020-09-14",
"runArgs": [ "--cap-add=SYS_PTRACE", "--security-opt", "seccomp=unconfined" ],
// Set *default* container specific settings.json values on container create.
"settings": {
"terminal.integrated.shell.linux": "/bin/bash"
},
// Add the IDs of extensions you want installed when the container is created.
"extensions": [
"chiehyu.vscode-astyle",
"dan-c-underwood.arm",
"fredericbonnet.cmake-test-adapter",
"github.vscode-pull-request-github",
"marus25.cortex-debug",
"ms-azuretools.vscode-docker",
"ms-iot.vscode-ros",
"ms-python.python",
"ms-vscode.cmake-tools",
"ms-vscode.cpptools",
"ms-vscode.cpptools-extension-pack",
"redhat.vscode-yaml",
"streetsidesoftware.code-spell-checker",
"twxs.cmake",
"uavcan.dsdl",
"wholroyd.jinja",
"zixuanwang.linkerscript"
],
"containerUser": "user",
"containerEnv": {
"LOCAL_USER_ID": "${localEnv:UID}"
},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
"forwardPorts": [14556],
}
+80
View File
@@ -0,0 +1,80 @@
* text=auto eol=lf
*.cmake text eol=lf
*.c text eol=lf
*.cc text eol=lf
*.cpp text eol=lf
*.h text eol=lf
*.hh text eol=lf
*.hpp text eol=lf
*.hxx text eol=lf
*.S text eol=lf
*.ipynb text eol=lf
*.m text eol=lf
*.mat binary
*.py text eol=lf
*.java text eol=lf
*.jar binary
*.xml text eol=lf
# PX4 mixers, msgs, etc
*.bin binary
*.mix text eol=lf
*.msg text eol=lf
*.config text eol=lf
*.sdf text eol=lf
*.uavcan text eol=lf
# NuttX
Makefile.* text eol=lf
*.defs text eol=lf
*.ld text eol=lf
*.csv text eol=lf
*.md text eol=lf
*.txt text eol=lf
# Scripts
*.bash text eol=lf
*.sh text eol=lf
*.zsh text eol=lf
# These are explicitly windows files and should use crlf
*.ps1 text eol=crlf
*.{cmd,[cC][mM][dD]} text eol=crlf
*.{bat,[bB][aA][tT]} text eol=crlf
# Serialisation
*.json text eol=lf
*.toml text eol=lf
*.xml text eol=lf
*.yaml text eol=lf
*.yml text eol=lf
# Graphics
*.png binary
*.jpg binary
*.jpeg binary
*.gif binary
*.tif binary
*.tiff binary
*.ico binary
*.pdf binary
# SVG treated as an asset (binary) by default.
*.svg text eol=lf
# Text files where line endings should be preserved
*.patch -text
# Archives
*.7z binary
*.gz binary
*.tar binary
*.tgz binary
*.zip binary
# everything else
.gitattributes text eol=lf
.gitignore text eol=lf
Makefile text eol=lf
+1 -1
View File
@@ -19,7 +19,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/en/getting_started/flight_reporting.html)).
- Download the flight log file from the vehicle ([tutorial](https://docs.px4.io/master/en/getting_started/flight_reporting.html)).
- Share the link to a log showing the problem on [PX4 Flight Review](http://logs.px4.io/).
Add screenshots to help explain your problem.
+5 -8
View File
@@ -1,18 +1,15 @@
# Number of days of inactivity before an issue becomes stale
daysUntilStale: 90
# Number of days of inactivity before a stale issue is closed
daysUntilClose: 14
# Number of days of inactivity before a stale issue is closed, or `false` to disable
daysUntilClose: false
# Issues with these labels will never be considered stale
exemptLabels:
- pinned
- security
# Label to use when marking an issue as stale
staleLabel: wontfix
staleLabel: stale
# Comment to post when marking an issue as stale. Set to `false` to disable
markComment: >
This issue has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs. Thank you
for your contributions.
recent activity. Thank you for your contributions.
# Comment to post when closing a stale issue. Set to `false` to disable
closeComment: >
Closing as stale.
closeComment: false
+58
View File
@@ -0,0 +1,58 @@
name: Checks
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
check: [
"check_format",
"tests",
"px4_fmu-v2_default stack_check",
"validate_module_configs",
"shellcheck_all",
"NO_NINJA_BUILD=1 px4_fmu-v5_default",
"NO_NINJA_BUILD=1 px4_sitl_default",
"airframe_metadata",
"module_documentation",
"parameters_metadata",
]
container: px4io/px4-dev-nuttx-focal:2020-09-14
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: tests_${{matrix.ubuntu_release}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: tests_${{matrix.ubuntu_release}}-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 400M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: ${{matrix.check}}
run: make ${{matrix.check}}
+46
View File
@@ -0,0 +1,46 @@
name: Clang Tidy
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
container: px4io/px4-dev-clang:2020-08-14
steps:
- uses: actions/checkout@v1
with:
token: ${{secrets.ACCESS_TOKEN}}
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: clang-tidy-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: clang-tidy-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 400M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: make clang-tidy-quiet
run: |
ccache -z
make clang-tidy-quiet
ccache -s
+54
View File
@@ -0,0 +1,54 @@
name: Linux Targets
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
container: px4io/px4-dev-armhf:2020-08-14
strategy:
matrix:
config: [
aerotenna_ocpoc_default,
beaglebone_blue_default,
emlid_navio2_default,
px4_raspberrypi_default,
scumaker_pilotpi_default,
]
steps:
- uses: actions/checkout@v1
with:
token: ${{secrets.ACCESS_TOKEN}}
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: ${{matrix.config}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: ${{matrix.config}}-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 400M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: make ${{matrix.config}}
run: make ${{matrix.config}}
- name: ccache post-run
run: ccache -s
+50
View File
@@ -0,0 +1,50 @@
name: Linux ARM64 Targets
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
container: px4io/px4-dev-aarch64:latest
strategy:
matrix:
config: [
scumaker_pilotpi_arm64,
]
steps:
- uses: actions/checkout@v1
with:
token: ${{secrets.ACCESS_TOKEN}}
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: ${{matrix.config}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: ${{matrix.config}}-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 400M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: make ${{matrix.config}}
run: make ${{matrix.config}}
- name: ccache post-run
run: ccache -s
+55
View File
@@ -0,0 +1,55 @@
name: MacOS build
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: macos-10.15
strategy:
matrix:
config: [
px4_fmu-v5_default,
px4_sitl_default,
#tests, # includes px4_sitl
]
steps:
- uses: actions/checkout@v1
with:
token: ${{secrets.ACCESS_TOKEN}}
- name: setup
run: ./Tools/setup/macos.sh
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: macos_${{matrix.config}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: macos_${{matrix.config}}-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 400M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: make ${{matrix.config}}
run: |
ccache -z
make ${{matrix.config}}
ccache -s
+117
View File
@@ -0,0 +1,117 @@
name: Nuttx Targets
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
container: px4io/px4-dev-nuttx-focal:2020-09-14
strategy:
matrix:
config: [
airmind_mindpx-v2_default,
av_x-v1_default,
bitcraze_crazyflie_default,
cuav_can-gps-v1_canbootloader,
cuav_can-gps-v1_default,
cuav_nora_default,
cuav_x7pro_default,
cubepilot_cubeorange_console,
cubepilot_cubeorange_default,
cubepilot_cubeyellow_console,
cubepilot_cubeyellow_default,
holybro_durandal-v1_default,
holybro_kakutef7_default,
holybro_pix32v5_default,
intel_aerofc-v1_default,
modalai_fc-v1_default,
mro_ctrl-zero-f7_default,
mro_x21-777_default,
mro_x21_default,
nxp_fmuk66-v3_default,
nxp_fmuk66-e_default,
nxp_fmuk66-v3_socketcan,
nxp_fmuk66-v3_rtps,
nxp_fmurt1062-v1_default,
nxp_ucans32k146_default,
omnibus_f4sd_default,
px4_fmu-v2_default,
px4_fmu-v2_fixedwing,
px4_fmu-v2_lpe,
px4_fmu-v2_multicopter,
px4_fmu-v2_rover,
px4_fmu-v2_test,
px4_fmu-v3_default,
px4_fmu-v4_cannode,
px4_fmu-v4_default,
px4_fmu-v4_optimized,
px4_fmu-v4pro_default,
px4_fmu-v5_default,
px4_fmu-v5_fixedwing,
px4_fmu-v5_multicopter,
px4_fmu-v5_optimized,
px4_fmu-v5_rover,
px4_fmu-v5_rtps,
px4_fmu-v5_stackcheck,
px4_fmu-v5x_base_phy_DP83848C,
px4_fmu-v5x_default,
px4_fmu-v6x_default,
px4_io-v2_default,
spracing_h7extreme_default,
uvify_core_default
]
steps:
- uses: actions/checkout@v1
with:
token: ${{secrets.ACCESS_TOKEN}}
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: ${{matrix.config}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: ${{matrix.config}}-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 400M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: make ${{matrix.config}}
run: make ${{matrix.config}}
- name: make ${{matrix.config}} bloaty_compileunits
run: make ${{matrix.config}} bloaty_compileunits || true
- name: make ${{matrix.config}} bloaty_inlines
run: make ${{matrix.config}} bloaty_inlines || true
- name: make ${{matrix.config}} bloaty_segments
run: make ${{matrix.config}} bloaty_segments || true
- name: make ${{matrix.config}} bloaty_symbols
run: make ${{matrix.config}} bloaty_symbols || true
- name: make ${{matrix.config}} bloaty_templates
run: make ${{matrix.config}} bloaty_templates || true
- name: make ${{matrix.config}} bloaty_compare_master
run: make ${{matrix.config}} bloaty_compare_master || true
- name: ccache post-run
run: ccache -s
- name: Upload px4 package
uses: actions/upload-artifact@v1
with:
name: px4_package_${{matrix.config}}
path: build/${{matrix.config}}/${{matrix.config}}.px4
+67
View File
@@ -0,0 +1,67 @@
name: Coverage
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
container: px4io/px4-dev-base-focal:2020-09-14
strategy:
matrix:
config: [
tests,
#python_coverage,
]
steps:
- uses: actions/checkout@v1
with:
token: ${{secrets.ACCESS_TOKEN}}
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: coverage_${{matrix.config}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: coverage_${{matrix.config}}-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 100M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: make ${{matrix.config}}
env:
PX4_CMAKE_BUILD_TYPE: "Coverage"
run: make ${{matrix.config}}
# Report test coverage
- name: Upload coverage
run: |
git config --global credential.helper "" # disable the keychain credential helper
git config --global --add credential.helper store # enable the local store credential helper
echo "https://x-access-token:${{ secrets.ACCESS_TOKEN }}@github.com" >> ~/.git-credentials # add credential
git config --global url."https://github.com/".insteadof git@github.com: # credentials add credential
mkdir -p coverage
lcov --directory build/px4_sitl_test --base-directory build/px4_sitl_test --gcov-tool gcov --capture -o coverage/lcov.info
- name: Upload coverage information to Codecov
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
flags: ${{matrix.config}}
file: coverage/lcov.info
@@ -0,0 +1,129 @@
name: MAVROS Avoidance Tests
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
config:
- {test_file: "mavros_posix_test_avoidance.test", vehicle: "iris_obs_avoid", mission: "avoidance", build_type: "RelWithDebInfo"}
- {test_file: "mavros_posix_test_safe_landing.test", vehicle: "iris_obs_avoid", mission: "MC_safe_landing", build_type: "RelWithDebInfo"}
container:
image: px4io/px4-dev-ros-melodic:2020-08-14
options: --privileged --ulimit core=-1 --security-opt seccomp=unconfined
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: sitl_tests-${{matrix.config.build_type}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: sitl_tests-${{matrix.config.build_type}}-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 400M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: check environment
run: export
- name: Build PX4 and sitl_gazebo
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: |
ccache -z
make px4_sitl_default
make px4_sitl_default sitl_gazebo
ccache -s
- name: Core dump settings
run: |
ulimit -c unlimited
echo "`pwd`/%e.core" > /proc/sys/kernel/core_pattern
- name: Run SITL tests
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: |
export
./test/rostest_avoidance_run.sh ${{matrix.config.test_file}} mission:=${{matrix.config.mission}} vehicle:=${{matrix.config.vehicle}} || true
- name: Look at core files
if: failure()
run: gdb build/px4_sitl_default/bin/px4 px4.core -ex "thread apply all bt" -ex "quit"
- name: Upload px4 coredump
if: failure()
uses: actions/upload-artifact@v2-preview
with:
name: coredump
path: px4.core
# - name: ecl EKF analysis
# if: always()
# run: ./Tools/ecl_ekf/process_logdata_ekf.py ~/.ros/log/*/*.ulg
- name: Upload logs to flight review
if: always()
run: ./Tools/upload_log.py -q --description "${GITHUB_WORKFLOW} ${GITHUB_RUN_ID}" --feedback "${GITHUB_WORKFLOW} ${GITHUB_RUN_ID} ${GITHUB_REPOSITORY} ${GITHUB_REF}" --source CI ~/.ros/log/*/*.ulg
- name: Upload px4 binary
if: failure()
uses: actions/upload-artifact@v2
with:
name: binary
path: build/px4_sitl_default/bin/px4
- name: Store PX4 log
if: failure()
uses: actions/upload-artifact@v2
with:
name: px4_log
path: ~/.ros/log/*/*.ulg
- name: Store ROS log
if: failure()
uses: actions/upload-artifact@v2
with:
name: ros_log
path: ~/.ros/**/rostest-*.log
# Report test coverage
- name: Upload coverage
if: contains(matrix.config.build_type, 'Coverage')
run: |
git config --global credential.helper "" # disable the keychain credential helper
git config --global --add credential.helper store # enable the local store credential helper
echo "https://x-access-token:${{ secrets.ACCESS_TOKEN }}@github.com" >> ~/.git-credentials # add credential
git config --global url."https://github.com/".insteadof git@github.com: # credentials add credential
mkdir -p coverage
lcov --directory build/px4_sitl_default --base-directory build/px4_sitl_default --gcov-tool gcov --capture -o coverage/lcov.info
- name: Upload coverage information to Codecov
if: contains(matrix.config.build_type, 'Coverage')
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
flags: mavros_avoidance
file: coverage/lcov.info
+135
View File
@@ -0,0 +1,135 @@
name: MAVROS Mission Tests
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
config:
- {vehicle: "iris", mission: "MC_mission_box", build_type: "RelWithDebInfo"}
- {vehicle: "rover", mission: "rover_mission_1", build_type: "RelWithDebInfo"}
- {vehicle: "plane", mission: "FW_mission_1", build_type: "RelWithDebInfo"}
- {vehicle: "plane_catapult",mission: "FW_mission_1", build_type: "RelWithDebInfo"}
- {vehicle: "standard_vtol", mission: "VTOL_mission_1", build_type: "Coverage"}
- {vehicle: "standard_vtol", mission: "VTOL_mission_1", build_type: "AddressSanitizer"}
#- {vehicle: "tailsitter", mission: "VTOL_mission_1", build_type: "RelWithDebInfo"}
- {vehicle: "tiltrotor", mission: "VTOL_mission_1", build_type: "RelWithDebInfo"}
container:
image: px4io/px4-dev-ros-melodic:2020-08-14
options: --privileged --ulimit core=-1 --security-opt seccomp=unconfined
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: sitl_tests-${{matrix.config.build_type}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: sitl_tests-${{matrix.config.build_type}}-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 400M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: check environment
run: export
- name: Build PX4 and sitl_gazebo
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: |
ccache -z
make px4_sitl_default
make px4_sitl_default sitl_gazebo
ccache -s
- name: Core dump settings
run: |
ulimit -c unlimited
echo "`pwd`/%e.core" > /proc/sys/kernel/core_pattern
- name: Run SITL tests
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: |
export
./test/rostest_px4_run.sh mavros_posix_test_mission.test mission:=${{matrix.config.mission}} vehicle:=${{matrix.config.vehicle}}
- name: Look at core files
if: failure()
run: gdb build/px4_sitl_default/bin/px4 px4.core -ex "thread apply all bt" -ex "quit"
- name: Upload px4 coredump
if: failure()
uses: actions/upload-artifact@v2-preview
with:
name: coredump
path: px4.core
- name: ecl EKF analysis
if: always()
run: ./Tools/ecl_ekf/process_logdata_ekf.py ~/.ros/log/*/*.ulg || true
- name: Upload logs to flight review
if: always()
run: ./Tools/upload_log.py -q --description "${GITHUB_WORKFLOW} ${GITHUB_RUN_ID}" --feedback "${GITHUB_WORKFLOW} ${GITHUB_RUN_ID} ${GITHUB_REPOSITORY} ${GITHUB_REF}" --source CI ~/.ros/log/*/*.ulg
- name: Upload px4 binary
if: failure()
uses: actions/upload-artifact@v2
with:
name: binary
path: build/px4_sitl_default/bin/px4
- name: Store PX4 log
if: failure()
uses: actions/upload-artifact@v2
with:
name: px4_log
path: ~/.ros/log/*/*.ulg
- name: Store ROS log
if: failure()
uses: actions/upload-artifact@v2
with:
name: ros_log
path: ~/.ros/**/rostest-*.log
# Report test coverage
- name: Upload coverage
if: contains(matrix.config.build_type, 'Coverage')
run: |
git config --global credential.helper "" # disable the keychain credential helper
git config --global --add credential.helper store # enable the local store credential helper
echo "https://x-access-token:${{ secrets.ACCESS_TOKEN }}@github.com" >> ~/.git-credentials # add credential
git config --global url."https://github.com/".insteadof git@github.com: # credentials add credential
mkdir -p coverage
lcov --directory build/px4_sitl_default --base-directory build/px4_sitl_default --gcov-tool gcov --capture -o coverage/lcov.info
- name: Upload coverage information to Codecov
if: contains(matrix.config.build_type, 'Coverage')
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
flags: mavros_mission
file: coverage/lcov.info
+130
View File
@@ -0,0 +1,130 @@
name: MAVROS Offboard Tests
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
config:
- {test_file: "mavros_posix_tests_offboard_posctl.test", vehicle: "iris", build_type: "RelWithDebInfo"}
#- {test_file: "mavros_posix_tests_offboard_attctl.test", vehicle: "iris", build_type: "RelWithDebInfo"}
#- {test_file: "mavros_posix_tests_offboard_rpyrt_ctl.test", vehicle: "iris", build_type: "RelWithDebInfo"}
container:
image: px4io/px4-dev-ros-melodic:2020-08-14
options: --privileged --ulimit core=-1 --security-opt seccomp=unconfined
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: sitl_tests-${{matrix.config.build_type}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: sitl_tests-${{matrix.config.build_type}}-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 400M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: check environment
run: export
- name: Build PX4 and sitl_gazebo
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: |
ccache -z
make px4_sitl_default
make px4_sitl_default sitl_gazebo
ccache -s
- name: Core dump settings
run: |
ulimit -c unlimited
echo "`pwd`/%e.core" > /proc/sys/kernel/core_pattern
- name: Run SITL tests
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: |
export
./test/rostest_px4_run.sh ${{matrix.config.test_file}} vehicle:=${{matrix.config.vehicle}}
- name: Look at core files
if: failure()
run: gdb build/px4_sitl_default/bin/px4 px4.core -ex "thread apply all bt" -ex "quit"
- name: Upload px4 coredump
if: failure()
uses: actions/upload-artifact@v2-preview
with:
name: coredump
path: px4.core
- name: ecl EKF analysis
if: always()
run: ./Tools/ecl_ekf/process_logdata_ekf.py ~/.ros/log/*/*.ulg || true
- name: Upload logs to flight review
if: always()
run: ./Tools/upload_log.py -q --description "${GITHUB_WORKFLOW} ${GITHUB_RUN_ID}" --feedback "${GITHUB_WORKFLOW} ${GITHUB_RUN_ID} ${GITHUB_REPOSITORY} ${GITHUB_REF}" --source CI ~/.ros/log/*/*.ulg
- name: Upload px4 binary
if: failure()
uses: actions/upload-artifact@v2
with:
name: binary
path: build/px4_sitl_default/bin/px4
- name: Store PX4 log
if: failure()
uses: actions/upload-artifact@v2
with:
name: px4_log
path: ~/.ros/log/*/*.ulg
- name: Store ROS log
if: failure()
uses: actions/upload-artifact@v2
with:
name: ros_log
path: ~/.ros/**/rostest-*.log
# Report test coverage
- name: Upload coverage
if: contains(matrix.config.build_type, 'Coverage')
run: |
git config --global credential.helper "" # disable the keychain credential helper
git config --global --add credential.helper store # enable the local store credential helper
echo "https://x-access-token:${{ secrets.ACCESS_TOKEN }}@github.com" >> ~/.git-credentials # add credential
git config --global url."https://github.com/".insteadof git@github.com: # credentials add credential
mkdir -p coverage
lcov --directory build/px4_sitl_default --base-directory build/px4_sitl_default --gcov-tool gcov --capture -o coverage/lcov.info
- name: Upload coverage information to Codecov
if: contains(matrix.config.build_type, 'Coverage')
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
flags: mavros_offboard
file: coverage/lcov.info
+111
View File
@@ -0,0 +1,111 @@
name: Metadata
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
airframe:
runs-on: ubuntu-latest
container: px4io/px4-dev-base-focal:2020-09-14
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: airframe metadata
run: |
make airframe_metadata
cd build/px4_sitl_default/docs
ls -ls *
# TODO: deploy to devguide gitbook and s3
module:
runs-on: ubuntu-latest
container: px4io/px4-dev-base-focal:2020-09-14
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: module documentation
run: |
make module_documentation
cd build/px4_sitl_default/docs
ls -ls *
# TODO: deploy to devguide gitbook and s3
parameter:
runs-on: ubuntu-latest
container: px4io/px4-dev-base-focal:2020-09-14
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: parameter metadata
run: |
make parameters_metadata
cd build/px4_sitl_default/docs
ls -ls *
# TODO: deploy 'parameters.md, parameters.xml to S3 px4-travis:Firmware/master/
uorb_graph:
runs-on: ubuntu-latest
container: px4io/px4-dev-nuttx-focal:2020-09-14
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: uORB graph
run: |
make uorb_graphs
cd Tools/uorb_graph
ls -ls *
# TODO: deploy graph_px4_sitl.json to S3 px4-travis:Firmware/master/
micrortps_agent:
runs-on: ubuntu-latest
container: px4io/px4-dev-base-focal:2020-09-14
steps:
- uses: actions/checkout@v1
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:2020-09-14
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: PX4 ROS 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:2020-09-14
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_rtps_ids.py -i msg/tools/uorb_rtps_message_ids.yaml -o px4_ros_com/templates/uorb_rtps_message_ids.yaml
+25
View File
@@ -0,0 +1,25 @@
name: Python CI Checks
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: Install Python3
run: sudo apt-get install python3 python3-setuptools python3-pip -y
- name: Install tools
run: pip3 install --user mypy flake8
- name: Check MAVSDK test scripts with mypy
run: $HOME/.local/bin/mypy --strict test/mavsdk_tests/*.py
- name: Check MAVSDK test scripts with flake8
run: $HOME/.local/bin/flake8 test/mavsdk_tests/*.py
+134
View File
@@ -0,0 +1,134 @@
name: SITL Tests
on:
push:
branches:
- 'master'
pull_request:
branches:
- '*'
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
config:
- {latitude: "59.617693", longitude: "-151.145316", altitude: "48", build_type: "RelWithDebInfo", model: "iris" } # Alaska
- {latitude: "-38.071235", longitude: "145.281220", altitude: "31", build_type: "RelWithDebInfo", model: "standard_vtol" } # Australia
- {latitude: "29.660316", longitude: "-82.316658", altitude: "30", build_type: "RelWithDebInfo", model: "tailsitter" } # Florida
- {latitude: "47.397742", longitude: "8.545594", altitude: "488", build_type: "Coverage", model: "standard_vtol" } # Zurich
container:
image: px4io/px4-dev-simulation-focal:2020-08-14
options: --privileged --ulimit core=-1 --security-opt seccomp=unconfined
steps:
- uses: actions/checkout@v1
with:
token: ${{ secrets.ACCESS_TOKEN }}
- name: Download MAVSDK
run: wget https://github.com/mavlink/MAVSDK/releases/download/v0.33.1/mavsdk_0.33.1_ubuntu20.04_amd64.deb
- name: Install MAVSDK
run: dpkg -i mavsdk_0.33.1_ubuntu20.04_amd64.deb
- name: Prepare ccache timestamp
id: ccache_cache_timestamp
shell: cmake -P {0}
run: |
string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
message("::set-output name=timestamp::${current_date}")
- name: ccache cache files
uses: actions/cache@v2
with:
path: ~/.ccache
key: sitl_tests-${{matrix.config.build_type}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
restore-keys: sitl_tests-${{matrix.config.build_type}}-ccache-
- name: setup ccache
run: |
mkdir -p ~/.ccache
echo "base_dir = ${GITHUB_WORKSPACE}" > ~/.ccache/ccache.conf
echo "compression = true" >> ~/.ccache/ccache.conf
echo "compression_level = 6" >> ~/.ccache/ccache.conf
echo "max_size = 400M" >> ~/.ccache/ccache.conf
ccache -s
ccache -z
- name: check environment
env:
PX4_HOME_LAT: ${{matrix.config.latitude}}
PX4_HOME_LON: ${{matrix.config.longitude}}
PX4_HOME_ALT: ${{matrix.config.altitude}}
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: export
- name: Build PX4
env:
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: make px4_sitl_default
- name: ccache post-run px4/firmware
run: ccache -s
- 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: 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
- name: ccache post-run mavsdk_tests
run: ccache -s
- name: Core dump settings
run: |
ulimit -c unlimited
echo "`pwd`/%e.core" > /proc/sys/kernel/core_pattern
- name: Run SITL tests
env:
PX4_HOME_LAT: ${{matrix.config.latitude}}
PX4_HOME_LON: ${{matrix.config.longitude}}
PX4_HOME_ALT: ${{matrix.config.altitude}}
PX4_CMAKE_BUILD_TYPE: ${{matrix.config.build_type}}
run: test/mavsdk_tests/mavsdk_test_runner.py --speed-factor 20 --abort-early --model ${{matrix.config.model}} test/mavsdk_tests/configs/sitl.json
- name: Look at core files
if: failure()
run: gdb build/px4_sitl_default/bin/px4 px4.core -ex "thread apply all bt" -ex "quit"
- name: Upload px4 coredump
if: failure()
uses: actions/upload-artifact@v2-preview
with:
name: coredump
path: px4.core
- name: Upload logs to flight review
if: failure()
run: ./Tools/upload_log.py -q --description "${GITHUB_WORKFLOW} ${GITHUB_RUN_ID}" --feedback "${GITHUB_WORKFLOW} ${GITHUB_RUN_ID} ${GITHUB_REPOSITORY} ${GITHUB_REF}" --source CI ${GITHUB_WORKSPACE}/build/px4_sitl_default/tmp_mavsdk_tests/rootfs/log/*/*.ulg
- name: Upload px4 binary
if: failure()
uses: actions/upload-artifact@v2-preview
with:
name: binary
path: build/px4_sitl_default/bin/px4
# Report test coverage
- name: Upload coverage
if: contains(matrix.config.build_type, 'Coverage')
run: |
git config --global credential.helper "" # disable the keychain credential helper
git config --global --add credential.helper store # enable the local store credential helper
echo "https://x-access-token:${{ secrets.ACCESS_TOKEN }}@github.com" >> ~/.git-credentials # add credential
git config --global url."https://github.com/".insteadof git@github.com: # credentials add credential
mkdir -p coverage
lcov --directory build/px4_sitl_default --base-directory build/px4_sitl_default --gcov-tool gcov --capture -o coverage/lcov.info
- name: Upload coverage information to Codecov
if: contains(matrix.config.build_type, 'Coverage')
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }}
flags: mavsdk
file: coverage/lcov.info
+50 -1
View File
@@ -17,7 +17,6 @@ Testing/
Packages/*
build/*
build_*/
core
cscope.out
cscope.in.out
cscope.po.out
@@ -64,3 +63,53 @@ posix-configs/SITL/init/test/*_generated
*.gcov
.coverage
.coverage.*
# KDevelop ignores
.kdev4/*
*.kdev4
# cmake in tree (ninja)
.ninja_deps
.ninja_log
bin/
build.ninja
cmake_install.cmake
CMakeCache.txt
CMakeFiles
compile_commands.json
CPackConfig.cmake
CPackSourceConfig.cmake
CTestTestfile.cmake
external/
rules.ninja
# in tree build
**/*.a
**/*.px4mod
**/*.stamp
/coverage*
/functional-*
/generated_params/
/googletest-*/
/logs
/mavsdk_tests
/test_mixer_multirotor
/unit-*
/uORB/
DartConfiguration.tcl
msg/tmp/
msg/topics_sources/
platforms/posix/apps.cpp
platforms/posix/apps.h
src/lib/flight_tasks/FlightTasks_generated.cpp
src/lib/flight_tasks/FlightTasks_generated.hpp
src/lib/parameters/px4_parameters.c
src/lib/parameters/px4_parameters.h
src/lib/parameters/px4_parameters_public.h
src/lib/version/build_git_version.h
src/modules/simulator/simulator_config.h
src/systemcmds/topic_listener/listener_generated.cpp
# SITL
dataman
eeprom/
+18 -22
View File
@@ -6,33 +6,21 @@
path = src/drivers/uavcan/libuavcan
url = https://github.com/PX4/uavcan.git
branch = px4
[submodule "msg/tools/genmsg"]
path = msg/tools/genmsg
url = https://github.com/PX4/genmsg.git
branch = px4
[submodule "msg/tools/gencpp"]
path = msg/tools/gencpp
url = https://github.com/PX4/gencpp.git
branch = px4
[submodule "Tools/jMAVSim"]
path = Tools/jMAVSim
url = https://github.com/PX4/jMAVSim.git
branch = master
[submodule "Tools/sitl_gazebo"]
path = Tools/sitl_gazebo
url = https://github.com/PX4/sitl_gazebo.git
url = https://github.com/PX4/PX4-SITL_gazebo.git
branch = master
[submodule "src/lib/matrix"]
path = src/lib/matrix
url = https://github.com/PX4/Matrix.git
branch = master
[submodule "src/lib/DriverFramework"]
path = src/lib/DriverFramework
url = https://github.com/PX4/DriverFramework.git
url = https://github.com/PX4/PX4-Matrix
branch = master
[submodule "src/lib/ecl"]
path = src/lib/ecl
url = https://github.com/PX4/ecl.git
url = https://github.com/PX4/PX4-ECL
branch = master
[submodule "boards/atlflight/cmake_hexagon"]
path = boards/atlflight/cmake_hexagon
@@ -40,7 +28,7 @@
branch = px4
[submodule "src/drivers/gps/devices"]
path = src/drivers/gps/devices
url = https://github.com/PX4/GpsDrivers.git
url = https://github.com/PX4/PX4-GPSDrivers
branch = master
[submodule "src/modules/micrortps_bridge/micro-CDR"]
path = src/modules/micrortps_bridge/micro-CDR
@@ -49,12 +37,20 @@
[submodule "platforms/nuttx/NuttX/nuttx"]
path = platforms/nuttx/NuttX/nuttx
url = https://github.com/PX4/NuttX.git
branch = px4_firmware_nuttx-7.28+
branch = px4_firmware_nuttx-10.0.0+
[submodule "platforms/nuttx/NuttX/apps"]
path = platforms/nuttx/NuttX/apps
url = https://github.com/PX4/NuttX-apps.git
branch = px4_firmware_nuttx-7.28+
[submodule "cmake/configs/uavcan_board_ident"]
path = cmake/configs/uavcan_board_ident
url = https://github.com/PX4/uavcan_board_ident.git
branch = master
branch = px4_firmware_nuttx-10.0.0+
[submodule "platforms/qurt/dspal"]
path = platforms/qurt/dspal
url = https://github.com/ATLFlight/dspal.git
[submodule "Tools/flightgear_bridge"]
path = Tools/flightgear_bridge
url = https://github.com/PX4/PX4-FlightGear-Bridge.git
[submodule "Tools/jsbsim_bridge"]
path = Tools/jsbsim_bridge
url = https://github.com/PX4/px4-jsbsim-bridge.git
[submodule "src/examples/gyro_fft/CMSIS_5"]
path = src/examples/gyro_fft/CMSIS_5
url = https://github.com/ARM-software/CMSIS_5.git
+3 -1
View File
@@ -9,7 +9,9 @@ matrix:
include:
- os: linux
dist: xenial
if: branch = coverity_scan
# 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
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-
+5
View File
@@ -2,5 +2,10 @@
.cortex-debug.registers.state.json
compile_commands.json
# generated by cmake
launch.json
# C/C++ extension does some local caching in this folder
ipch/
browse.vc.db*
+5 -15
View File
@@ -1,25 +1,15 @@
{
"configurations": [
{
"name": "Linux",
"intelliSenseMode": "gcc-x64",
"name": "PX4",
"includePath": [
"${workspaceFolder}/**"
],
"defines": [],
"browse": {
"path": [
"${workspaceFolder}/src/",
"${workspaceFolder}/src/lib/",
"${workspaceFolder}/src/lib/matrix",
"${workspaceFolder}/src/platforms",
"${workspaceFolder}/platforms/",
"."
],
"limitSymbolsToIncludedHeaders": true
},
"compileCommands": "${workspaceFolder}/.vscode/compile_commands.json",
"configurationProvider": "vector-of-bool.cmake-tools"
"macFrameworkPath": [],
"configurationProvider": "ms-vscode.cmake-tools",
"cppStandard": "c++14",
"cStandard": "c11"
}
],
"version": 4
+69 -9
View File
@@ -6,16 +6,21 @@ CONFIG:
buildType: RelWithDebInfo
settings:
CONFIG: px4_sitl_default
px4_sitl_default_Debug:
short: px4_sitl (Debug)
buildType: Debug
px4_sitl_replay:
short: px4_sitl_replay
buildType: RelWithDebInfo
settings:
CONFIG: px4_sitl_default
px4_sitl_default_ASan:
short: px4_sitl (Address Sanitizer)
buildType: AddressSanitizer
CONFIG: px4_sitl_replay
px4_sitl_test:
short: px4_sitl_test
buildType: RelWithDebInfo
settings:
CONFIG: px4_sitl_default
CONFIG: px4_sitl_test
px4_io-v2_default:
short: px4_io-v2
buildType: MinSizeRel
settings:
CONFIG: px4_io-v2_default
px4_fmu-v2_default:
short: px4_fmu-v2
buildType: MinSizeRel
@@ -41,21 +46,76 @@ CONFIG:
buildType: MinSizeRel
settings:
CONFIG: px4_fmu-v5_default
px4_fmu-v5x_default:
short: px4_fmu-v5x
buildType: MinSizeRel
settings:
CONFIG: px4_fmu-v5x_default
airmind_mindpx-v2_default:
short: airmind_mindpx-v2
buildType: MinSizeRel
settings:
CONFIG: airmind_mindpx-v2_default
av_x-v1_default:
short: av-x
short: av_x-v1
buildType: MinSizeRel
settings:
CONFIG: av_x-v1_default
cuav_can-gps-v1_default:
short: cuav_can-gps-v1_default
buildType: MinSizeRel
settings:
CONFIG: cuav_can-gps-v1_default
cuav_nora_default:
short: cuav_nora
buildType: MinSizeRel
settings:
CONFIG: cuav_nora_default
cuav_x7pro_default:
short: cuav_x7pro
buildType: MinSizeRel
settings:
CONFIG: cuav_x7pro_default
cubepilot_cubeorange_default:
short: cubepilot_cubeorange
buildType: MinSizeRel
settings:
CONFIG: cubepilot_orange_default
cubepilot_cubeyellow_default:
short: cubepilot_cubeyellow
buildType: MinSizeRel
settings:
CONFIG: cubepilot_cubeyellow_default
emlid_navio2_default:
short: emlid_navio2
buildType: MinSizeRel
settings:
CONFIG: emlid_navio2_default
holybro_durandal-v1_default:
short: holybro_durandal-v1
buildType: MinSizeRel
settings:
CONFIG: holybro_durandal-v1_default
intel_aerofc-v1_default:
short: intel_aerofc-v1
buildType: MinSizeRel
settings:
CONFIG: intel_aerofc-v1_default
modalai_fc-v1_default:
short: modalai_fc-v1
buildType: MinSizeRel
settings:
CONFIG: modalai_fc-v1_default
mro_ctrl-zero-f7_default:
short: mro_ctrl-zero-f7
buildType: MinSizeRel
settings:
CONFIG: mro_ctrl-zero-f7_default
mro_x21-777_default:
short: mro_x2.1-777
buildType: MinSizeRel
settings:
CONFIG: mro_x21-777_default
nxp_fmuk66-v3_default:
short: nxp_fmuk66-v3
buildType: MinSizeRel
+9 -4
View File
@@ -2,17 +2,22 @@
// See http://go.microsoft.com/fwlink/?LinkId=827846
// for the documentation about the extensions.json format
"recommendations": [
"ajshort.ros",
"chiehyu.vscode-astyle",
"dan-c-underwood.arm",
"fredericbonnet.cmake-test-adapter",
"github.vscode-pull-request-github",
"marus25.cortex-debug",
"ms-azuretools.vscode-docker",
"ms-iot.vscode-ros",
"ms-python.python",
"ms-vscode.cmake-tools",
"ms-vscode.cpptools",
"peterjausovec.vscode-docker",
"ms-vscode.cpptools-extension-pack",
"redhat.vscode-yaml",
"streetsidesoftware.code-spell-checker",
"twxs.cmake",
"uavcan.dsdl",
"vector-of-bool.cmake-tools",
"wholroyd.jinja"
"wholroyd.jinja",
"zixuanwang.linkerscript"
]
}
-194
View File
@@ -1,194 +0,0 @@
{
"version": "0.2.0",
"configurations": [
{
"name": "SITL shell",
"type": "cppdbg",
"request": "launch",
"program": "${command:cmake.launchTargetPath}",
"args": [
"${workspaceFolder}/ROMFS/px4fmu_common",
"-s",
"etc/init.d-posix/rcS",
"-t",
"${workspaceFolder}/test_data"
],
"stopAtEntry": false,
"cwd": "${workspaceFolder}/build/px4_sitl_default/tmp",
"environment": [
{
"name": "PX4_SIM_MODEL",
"value": "shell"
}
],
"externalConsole": false,
"linux": {
"MIMode": "gdb",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
},
{
"description": "PX4 ignore wq signals",
"text": "handle SIGCONT nostop noprint nopass",
"ignoreFailures": true
}
]
},
"osx": {
"MIMode": "lldb",
"setupCommands": [
{
"text": "pro hand -p true -s false -n false SIGCONT",
}
]
}
},
{
"name": "SITL jmavsim iris",
"type": "cppdbg",
"request": "launch",
"program": "${command:cmake.launchTargetPath}",
"args": [
"${workspaceFolder}/ROMFS/px4fmu_common",
"-s",
"etc/init.d-posix/rcS",
"-t",
"${workspaceFolder}/test_data"
],
"stopAtEntry": false,
"cwd": "${workspaceFolder}/build/px4_sitl_default/tmp",
"environment": [
{
"name": "PX4_SIM_MODEL",
"value": "iris"
}
],
"externalConsole": false,
"preLaunchTask": "jmavsim",
"postDebugTask": "jmavsim kill",
"linux": {
"MIMode": "gdb",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
},
{
"description": "PX4 ignore wq signals",
"text": "handle SIGCONT nostop noprint nopass",
"ignoreFailures": true
}
]
},
"osx": {
"MIMode": "lldb",
"setupCommands": [
{
"text": "pro hand -p true -s false -n false SIGCONT",
}
]
}
},
{
"name": "SITL gazebo iris",
"type": "cppdbg",
"request": "launch",
"program": "${command:cmake.launchTargetPath}",
"args": [
"${workspaceFolder}/ROMFS/px4fmu_common",
"-s",
"etc/init.d-posix/rcS",
"-t",
"${workspaceFolder}/test_data"
],
"stopAtEntry": false,
"cwd": "${workspaceFolder}/build/px4_sitl_default/tmp",
"environment": [
{
"name": "PX4_SIM_MODEL",
"value": "iris"
}
],
"externalConsole": false,
"preLaunchTask": "gazebo iris",
"postDebugTask": "gazebo kill",
"linux": {
"MIMode": "gdb",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
},
{
"description": "PX4 ignore wq signals",
"text": "handle SIGCONT nostop noprint nopass",
"ignoreFailures": true
}
]
},
"osx": {
"MIMode": "lldb",
"setupCommands": [
{
"text": "pro hand -p true -s false -n false SIGCONT",
}
]
}
},
{
"name": "px4_fmu-v2 (jlink) ",
"executable": "${command:cmake.launchTargetPath}",
"request": "launch",
"type": "cortex-debug",
"servertype": "jlink",
"device": "STM32F427VI",
"svdFile": "${workspaceRoot}/../cmsis-svd/data/STMicro/STM32F427.svd",
"interface": "swd"
},
{
"name": "px4_fmu-v3 (jlink)",
"executable": "${command:cmake.launchTargetPath}",
"request": "launch",
"type": "cortex-debug",
"servertype": "jlink",
"device": "STM32F427VI",
"svdFile": "${workspaceRoot}/../cmsis-svd/data/STMicro/STM32F427.svd",
"interface": "swd"
},
{
"name": "px4_fmu-v4 (jlink)",
"executable": "${command:cmake.launchTargetPath}",
"request": "launch",
"type": "cortex-debug",
"servertype": "jlink",
"device": "STM32F427VI",
"svdFile": "${workspaceRoot}/../cmsis-svd/data/STMicro/STM32F427.svd",
"interface": "swd"
},
{
"name": "px4_fmu-v4pro (jlink)",
"executable": "${command:cmake.launchTargetPath}",
"request": "launch",
"type": "cortex-debug",
"servertype": "jlink",
"device": "STM32F469VI",
"svdFile": "${workspaceRoot}/../cmsis-svd/data/STMicro/STM32F469.svd",
"interface": "swd"
},
{
"name": "px4_fmu-v5 (jlink)",
"executable": "${command:cmake.launchTargetPath}",
"request": "launch",
"type": "cortex-debug",
"servertype": "jlink",
"device": "STM32F765VI",
"svdFile": "${workspaceRoot}/../cmsis-svd/data/STMicro/STM32F7x5.svd",
"interface": "swd"
},
]
}
+114 -62
View File
@@ -3,89 +3,141 @@
"astyle.c.enable": true,
"astyle.cpp.enable": true,
"breadcrumbs.enabled": true,
"cmake.autoRestartBuild": true,
"cmake.buildDirectory": "${workspaceFolder}/build/${variant:CONFIG}",
"cmake.buildBeforeRun": true,
"cmake.configureOnOpen": true,
"cmake.copyCompileCommands": "${workspaceFolder}/.vscode/compile_commands.json",
"cmake.debugConfig": {
"name": "SITL shell (gdb)",
"type": "cppdbg",
"request": "launch",
"program": "${command:cmake.launchTargetPath}",
"args": [
"${workspaceFolder}/ROMFS/px4fmu_common",
"-s",
"etc/init.d-posix/rcS",
"-t",
"${workspaceFolder}/test_data"
],
"stopAtEntry": false,
"cwd": "${workspaceFolder}/build/px4_sitl_default/tmp",
"environment": [
{
"name": "PX4_SIM_MODEL",
"value": "shell"
}
],
"externalConsole": false,
"linux": {
"MIMode": "gdb",
"setupCommands": [
{
"description": "Enable pretty-printing for gdb",
"text": "-enable-pretty-printing",
"ignoreFailures": true
},
{
"description": "PX4 ignore wq signals",
"text": "handle SIGCONT nostop noprint nopass",
"ignoreFailures": true
}
]
},
"osx": {
"MIMode": "lldb",
"setupCommands": [
{
"text": "pro hand -p true -s false -n false SIGCONT",
}
]
}
},
"C_Cpp.autoAddFileAssociations": false,
"C_Cpp.clang_format_fallbackStyle": "none",
"C_Cpp.configurationWarnings": "Disabled",
"C_Cpp.default.cppStandard": "c++11",
"C_Cpp.default.cStandard": "c99",
"C_Cpp.default.intelliSenseMode": "gcc-x64",
"C_Cpp.errorSquiggles": "Disabled",
"C_Cpp.default.browse.limitSymbolsToIncludedHeaders": true,
"C_Cpp.default.cppStandard": "c++14",
"C_Cpp.default.cStandard": "c11",
"C_Cpp.formatting": "Disabled",
"C_Cpp.intelliSenseEngine": "Default",
"C_Cpp.intelliSenseEngineFallback": "Disabled",
"C_Cpp.vcpkg.enabled": false,
"C_Cpp.workspaceParsingPriority": "low",
"cmake.buildBeforeRun": true,
"cmake.buildDirectory": "${workspaceFolder}/build/${variant:CONFIG}",
"cmake.buildTask": true,
"cmake.configureOnOpen": true,
"cmake.ctest.parallelJobs": 1,
"cmake.skipConfigureIfCachePresent": true,
"cmakeExplorer.buildDir": "${workspaceFolder}/build/px4_sitl_test",
"cmakeExplorer.parallelJobs": 1,
"cmakeExplorer.suiteDelimiter": "-",
"cortex-debug.enableTelemetry": false,
"cSpell.allowCompoundWords": true,
"cSpell.diagnosticLevel": "Hint",
"cSpell.showStatus": false,
"cSpell.words": [
"acro",
"rattitude",
"nuttx",
"esc"
],
"debug.toolBarLocation": "docked",
"editor.acceptSuggestionOnEnter": "off",
"editor.defaultFormatter": "chiehyu.vscode-astyle",
"editor.dragAndDrop": false,
"editor.insertSpaces": false,
"editor.minimap.maxColumn": 120,
"editor.minimap.renderCharacters": false,
"editor.minimap.showSlider": "always",
"editor.smoothScrolling": true,
"editor.suggest.localityBonus": true,
"editor.tabSize": 8,
"editor.wordWrapColumn": 120,
"explorer.openEditors.visible": 0,
"files.insertFinalNewline": true,
"files.trimTrailingWhitespace": true,
"files.watcherExclude": {
"**/build/**": true
},
"git.detectSubmodulesLimit": 20,
"git.ignoreLimitWarning": true,
"githubPullRequests.defaultMergeMethod": "squash",
"githubPullRequests.telemetry.enabled": false,
"files.associations": {
"*.jinja": "jinja"
"*.jinja": "jinja",
"algorithm": "cpp",
"array": "cpp",
"atomic": "cpp",
"bitset": "cpp",
"cctype": "cpp",
"cfenv": "cpp",
"chrono": "cpp",
"cinttypes": "cpp",
"clocale": "cpp",
"cmath": "cpp",
"codecvt": "cpp",
"complex": "cpp",
"condition_variable": "cpp",
"csignal": "cpp",
"cstdarg": "cpp",
"cstddef": "cpp",
"cstdint": "cpp",
"cstdio": "cpp",
"cstdlib": "cpp",
"cstring": "cpp",
"ctime": "cpp",
"cwchar": "cpp",
"cwctype": "cpp",
"deque": "cpp",
"exception": "cpp",
"forward_list": "cpp",
"fstream": "cpp",
"functional": "cpp",
"future": "cpp",
"hash_map": "cpp",
"hash_set": "cpp",
"initializer_list": "cpp",
"iomanip": "cpp",
"iosfwd": "cpp",
"iostream": "cpp",
"istream": "cpp",
"iterator": "cpp",
"limits": "cpp",
"list": "cpp",
"map": "cpp",
"memory": "cpp",
"memory_resource": "cpp",
"mutex": "cpp",
"new": "cpp",
"numeric": "cpp",
"optional": "cpp",
"ostream": "cpp",
"random": "cpp",
"ratio": "cpp",
"regex": "cpp",
"set": "cpp",
"sstream": "cpp",
"stdexcept": "cpp",
"streambuf": "cpp",
"string": "cpp",
"string_view": "cpp",
"strstream": "cpp",
"system_error": "cpp",
"thread": "cpp",
"tuple": "cpp",
"type_traits": "cpp",
"typeindex": "cpp",
"typeinfo": "cpp",
"unordered_map": "cpp",
"unordered_set": "cpp",
"utility": "cpp",
"valarray": "cpp",
"variant": "cpp",
"vector": "cpp"
},
"search.exclude": {
"build/**": true
"${workspaceFolder}/build": true
},
"search.showLineNumbers": true,
"search.smartCase": true,
"telemetry.enableTelemetry": false,
"terminal.integrated.copyOnSelection": true,
"terminal.integrated.rightClickBehavior": "paste",
"terminal.integrated.scrollback": 5000,
"window.title": "${dirty} ${activeEditorMedium}${separator}${rootName}",
"workbench.editor.enablePreview": false,
"workbench.editor.enablePreviewFromQuickOpen": false,
"workbench.editor.highlightModifiedTabs": true,
"workbench.enableExperiments": false,
"workbench.settings.enableNaturalLanguageSearch": false,
"workbench.statusBar.feedback.visible": false
"yaml.schemas": {
"${workspaceFolder}/validation/module_schema.yaml": "${workspaceFolder}/src/modules/*/module.yaml"
}
}
+294 -18
View File
@@ -4,20 +4,87 @@
"version": "2.0.0",
"tasks": [
{
"label": "jmavsim",
"label": "build",
"type": "shell",
"command": "Tools/jmavsim_run.sh",
"isBackground": true,
"command": "/bin/bash",
"args": [
"-r",
"500"
"-c",
"${command:cmake.tasksBuildCommand}"
],
"options": {
"cwd": "${workspaceRoot}"
"cwd": "${command:cmake.buildDirectory}"
},
"group": {
"kind": "build",
"isDefault": true,
},
"problemMatcher": {
"base": "$gcc",
"fileLocation": ["relative", "${command:cmake.buildDirectory}"]
},
"presentation":{
"echo": false,
"showReuseMessage": false,
"clear": true,
"panel": "shared",
"group": "build"
}
},
{
"label": "test",
"type": "shell",
"command": "make tests",
"options": {
"cwd": "${workspaceFolder}"
},
"group": {
"kind": "test",
"isDefault": true,
},
"presentation":{
"echo": true,
"showReuseMessage": false,
"clear": false,
"panel": "shared",
"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": {
"reveal": "always",
"panel": "dedicated"
"echo": true,
"reveal": "never",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": [
{
@@ -41,6 +108,14 @@
"label": "jmavsim kill",
"type": "shell",
"command": "kill $(ps aux | grep jmavsim | grep -v 'grep' | awk '{print $2}')",
"presentation": {
"echo": false,
"reveal": "never",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": []
},
{
@@ -48,26 +123,119 @@
"type": "shell",
"command": "make px4_sitl_default sitl_gazebo",
"options": {
"cwd": "${workspaceRoot}"
"cwd": "${workspaceFolder}"
},
"problemMatcher": []
"problemMatcher": [],
"presentation":{
"echo": true,
"reveal": "always",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false,
}
},
{
"label": "gazebo iris",
"label": "gazebo start",
"type": "shell",
"dependsOn": "gazebo build",
"options": {
"cwd": "${workspaceRoot}",
"cwd": "${workspaceFolder}",
"env": {
"GAZEBO_PLUGIN_PATH": "${workspaceRoot}/build/px4_sitl_default/build_gazebo",
"GAZEBO_MODEL_PATH": "${workspaceRoot}/Tools/sitl_gazebo/models"
"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 ${workspaceRoot}/Tools/sitl_gazebo/worlds/iris.world",
"command": "gzserver --verbose ${workspaceFolder}/Tools/sitl_gazebo/worlds/${input:gazeboWorld}.world",
"isBackground": true,
"presentation": {
"reveal": "always",
"panel": "dedicated"
"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": [
{
@@ -91,7 +259,115 @@
"label": "gazebo kill",
"type": "shell",
"command": "killall gzserver",
"presentation": {
"echo": true,
"reveal": "silent",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": [],
"dependsOn":["px4_sitl_cleanup"]
},
{
"label": "px4_sitl_cleanup",
"type": "shell",
"command": "rm -rfv /tmp/px4*",
"presentation": {
"echo": true,
"reveal": "silent",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": [],
"dependsOn":["px4_kill"]
},
{
"label": "px4_kill",
"type": "shell",
"command": "killall px4 || true",
"presentation": {
"echo": true,
"reveal": "silent",
"focus": false,
"panel": "shared",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": []
},
{
"label": "mavlink shell",
"type": "shell",
"command": "./Tools/mavlink_shell.py",
"options": {
"cwd": "${workspaceFolder}"
},
"presentation": {
"echo": true,
"reveal": "always",
"focus": true,
"panel": "new",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": []
},
{
"label": "miniterm.py",
"type": "shell",
"command": "miniterm.py --raw - 57600",
"options": {
"cwd": "${workspaceFolder}"
},
"presentation": {
"echo": true,
"reveal": "always",
"focus": true,
"panel": "new",
"showReuseMessage": false,
"clear": false
},
"problemMatcher": []
}
],
"inputs": [
{
"type": "pickString",
"id": "vehicleModel",
"description": "gazebo model",
"options": [
"iris",
"typhoon_h480",
"plane",
"plane_catapult",
"plane_lidar",
"standard_vtol",
"tailsitter",
"tiltrotor",
"r1_rover",
"boat"
],
"default": "iris"
},
{
"type": "pickString",
"id": "gazeboWorld",
"description": "gazebo world",
"options": [
"baylands",
"empty",
"ksql_airport",
"mcmillan_airfield",
"sonoma_raceway",
"warehouse",
"windy",
"yosemite"
],
"default": "empty"
}
]
}
}
+2 -2
View File
@@ -51,8 +51,8 @@ flags = [
# headers will be compiled as C headers. You don't want that so ALWAYS specify
# a "-std=<something>".
# For a C project, you would set this to something like 'c99' instead of
# 'c++11'.
'-std=c++11',
# 'c++14'.
'-std=c++14',
# ...and the same thing goes for the magic -x option which specifies the
# language that the files to be compiled are written in. This is mostly
# relevant for c++ headers.
+114 -254
View File
@@ -105,6 +105,7 @@ set(PX4_SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}")
set(PX4_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}")
list(APPEND CMAKE_MODULE_PATH ${PX4_SOURCE_DIR}/cmake)
include(px4_parse_function_args)
#=============================================================================
# git
@@ -117,6 +118,7 @@ execute_process(
OUTPUT_STRIP_TRAILING_WHITESPACE
WORKING_DIRECTORY ${PX4_SOURCE_DIR}
)
message(STATUS "PX4 version: ${PX4_GIT_TAG}")
define_property(GLOBAL PROPERTY PX4_MODULE_LIBRARIES
BRIEF_DOCS "PX4 module libs"
@@ -136,97 +138,26 @@ set(CONFIG "px4_sitl_default" CACHE STRING "desired configuration")
include(px4_add_module)
set(config_module_list)
set(config_df_driver_list)
# find PX4 config
# look for in tree board config that matches CONFIG input
if(NOT PX4_CONFIG_FILE)
file(GLOB_RECURSE board_configs
RELATIVE "${PX4_SOURCE_DIR}/boards"
"boards/*.cmake"
)
set(PX4_CONFIGS ${board_configs} CACHE STRING "PX4 board configs" FORCE)
foreach(filename ${board_configs})
# parse input CONFIG into components to match with existing in tree configs
# the platform prefix (eg nuttx_) is historical, and removed if present
string(REPLACE ".cmake" "" filename_stripped ${filename})
string(REPLACE "/" ";" config ${filename_stripped})
list(LENGTH config config_len)
if(${config_len} EQUAL 3)
list(GET config 0 vendor)
list(GET config 1 model)
list(GET config 2 label)
set(board "${vendor}${model}")
# <VENDOR>_<MODEL>_<LABEL> (eg px4_fmu-v2_default)
# <VENDOR>_<MODEL>_default (eg px4_fmu-v2) # allow skipping label if "default"
if ((${CONFIG} MATCHES "${vendor}_${model}_${label}") OR # match full vendor, model, label
((${label} STREQUAL "default") AND (${CONFIG} STREQUAL "${vendor}_${model}")) # default label can be omitted
)
set(PX4_CONFIG_FILE "${PX4_SOURCE_DIR}/boards/${filename}" CACHE FILEPATH "path to PX4 CONFIG file" FORCE)
break()
endif()
# <BOARD>_<LABEL> (eg px4_fmu-v2_default)
# <BOARD>_default (eg px4_fmu-v2) # allow skipping label if "default"
if ((${CONFIG} MATCHES "${board}_${label}") OR # match full board, label
((${label} STREQUAL "default") AND (${CONFIG} STREQUAL "${board}")) # default label can be omitted
)
set(PX4_CONFIG_FILE "${PX4_SOURCE_DIR}/boards/${filename}" CACHE FILEPATH "path to PX4 CONFIG file" FORCE)
break()
endif()
# LEGACY form
# <OS>_<BOARD>_<LABEL> (eg nuttx_px4_fmu-v2_default)
string(REGEX REPLACE "^nuttx_|^posix_|^qurt_" "" config_no_os ${CONFIG}) # ignore OS prefix
if ((${config_no_os} MATCHES "${board}_${label}"))
set(PX4_CONFIG_FILE "${PX4_SOURCE_DIR}/boards/${filename}" CACHE FILEPATH "path to PX4 CONFIG file" FORCE)
break()
endif()
# LEGACY form special case to ease board layout transition (2018-11-18)
# match board with model and label only: eg sitl_default -> px4_sitl_default
if ((${config_no_os} MATCHES "${model}_${label}"))
set(PX4_CONFIG_FILE "${PX4_SOURCE_DIR}/boards/${filename}" CACHE FILEPATH "path to PX4 CONFIG file" FORCE)
break()
endif()
endif()
endforeach()
endif()
if(NOT PX4_CONFIG_FILE)
message(FATAL_ERROR "PX4 config file not set, try one of ${PX4_CONFIGS}")
endif()
message(STATUS "PX4 config file: ${PX4_CONFIG_FILE}")
include(px4_config)
include(px4_add_board)
include(${PX4_CONFIG_FILE})
message(STATUS "PX4 config: ${PX4_CONFIG}")
message(STATUS "PX4 platform: ${PX4_PLATFORM}")
if (ENABLE_LOCKSTEP_SCHEDULER)
add_definitions(-DENABLE_LOCKSTEP_SCHEDULER)
message(STATUS "PX4 lockstep: enabled")
else()
message(STATUS "PX4 lockstep: disabled")
if(${PX4_PLATFORM} STREQUAL "posix")
if(ENABLE_LOCKSTEP_SCHEDULER)
add_definitions(-DENABLE_LOCKSTEP_SCHEDULER)
message(STATUS "PX4 lockstep: enabled")
else()
message(STATUS "PX4 lockstep: disabled")
endif()
endif()
# external modules
set(EXTERNAL_MODULES_LOCATION "" CACHE STRING "External modules source location")
if (NOT EXTERNAL_MODULES_LOCATION STREQUAL "")
if(NOT EXTERNAL_MODULES_LOCATION STREQUAL "")
get_filename_component(EXTERNAL_MODULES_LOCATION "${EXTERNAL_MODULES_LOCATION}" ABSOLUTE)
endif()
@@ -240,8 +171,8 @@ if(EXISTS "${PX4_SOURCE_DIR}/platforms/${PX4_PLATFORM}/cmake/init.cmake")
endif()
# CMake build type (Debug Release RelWithDebInfo MinSizeRel Coverage)
if (NOT CMAKE_BUILD_TYPE)
if (${PX4_PLATFORM} STREQUAL "nuttx")
if(NOT CMAKE_BUILD_TYPE)
if(${PX4_PLATFORM} STREQUAL "nuttx")
set(PX4_BUILD_TYPE "MinSizeRel")
else()
set(PX4_BUILD_TYPE "RelWithDebInfo")
@@ -250,11 +181,19 @@ if (NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE ${PX4_BUILD_TYPE} CACHE STRING "Build type" FORCE)
endif()
if((CMAKE_BUILD_TYPE STREQUAL "Debug") OR (CMAKE_BUILD_TYPE STREQUAL "Coverage"))
set(MAX_CUSTOM_OPT_LEVEL -O0)
elseif(CMAKE_BUILD_TYPE MATCHES "Sanitizer")
set(MAX_CUSTOM_OPT_LEVEL -O1)
else()
if(px4_constrained_flash_build)
set(MAX_CUSTOM_OPT_LEVEL -Os)
else()
set(MAX_CUSTOM_OPT_LEVEL -O2)
endif()
endif()
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug;Release;RelWithDebInfo;MinSizeRel;Coverage;AddressSanitizer;UndefinedBehaviorSanitizer")
#=============================================================================
message(STATUS "PX4 version: ${PX4_GIT_TAG}")
message(STATUS "cmake build type: ${CMAKE_BUILD_TYPE}")
#=============================================================================
@@ -264,9 +203,9 @@ project(px4 CXX C ASM)
set(package-contact "px4users@googlegroups.com")
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_STANDARD 11)
set(CMAKE_C_STANDARD_REQUIRED ON)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
@@ -282,9 +221,29 @@ endif()
#=============================================================================
# Setup install paths
if (${PX4_PLATFORM} STREQUAL "posix")
# gold linker - use if available (posix only for now)
if(${PX4_PLATFORM} STREQUAL "posix")
include(CMakeDependentOption)
CMAKE_DEPENDENT_OPTION(USE_LD_GOLD
"Use GNU gold linker" ON
"NOT WIN32;NOT APPLE" OFF
)
if(USE_LD_GOLD)
execute_process(COMMAND ${CMAKE_C_COMPILER} -fuse-ld=gold -Wl,--version ERROR_QUIET OUTPUT_VARIABLE LD_VERSION)
if("${LD_VERSION}" MATCHES "GNU gold")
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fuse-ld=gold")
set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fuse-ld=gold")
else()
set(USE_LD_GOLD OFF)
endif()
endif()
endif()
#=============================================================================
# Setup install paths
if(${PX4_PLATFORM} STREQUAL "posix")
# This makes it possible to dynamically load code which depends on symbols
# inside the px4 executable.
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
@@ -301,25 +260,7 @@ if (${PX4_PLATFORM} STREQUAL "posix")
endif()
endif()
#=============================================================================
# ccache
#
option(CCACHE "Use ccache if available" ON)
find_program(CCACHE_PROGRAM ccache)
if (CCACHE AND CCACHE_PROGRAM AND NOT DEFINED ENV{CCACHE_DISABLE})
get_filename_component(ccache_real_path ${CCACHE_PROGRAM} REALPATH)
get_filename_component(cxx_real_path ${CMAKE_CXX_COMPILER} REALPATH)
get_filename_component(cxx_abs_path ${CMAKE_CXX_COMPILER} ABSOLUTE)
if ("${ccache_real_path}" STREQUAL "${cxx_real_path}")
message(STATUS "ccache enabled via symlink (${cxx_abs_path} -> ${cxx_real_path})")
else()
message(STATUS "ccache enabled (export CCACHE_DISABLE=1 to disable)")
set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE "${CCACHE_PROGRAM}")
endif()
endif()
include(ccache)
#=============================================================================
# find programs and packages
@@ -336,15 +277,36 @@ if (CATKIN_DEVEL_PREFIX)
endif()
endif()
find_package(PythonInterp REQUIRED)
# 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)
endif()
option(PYTHON_COVERAGE "Python code coverage" OFF)
if(PYTHON_COVERAGE)
message(STATUS "python coverage enabled")
set(PYTHON_EXECUTABLE coverage run -p)
else()
# run normally (broken under coveragepy)
px4_find_python_module(jinja2 REQUIRED)
endif()
#=============================================================================
# get chip and chip manufacturer
#
px4_os_determine_build_chip()
if(NOT PX4_CHIP_MANUFACTURER)
message(FATAL_ERROR "px4_os_determine_build_chip() needs to set PX4_CHIP_MANUFACTURER")
endif()
if(NOT PX4_CHIP)
message(FATAL_ERROR "px4_os_determine_build_chip() needs to set PX4_CHIP")
endif()
#=============================================================================
@@ -354,6 +316,13 @@ include(px4_add_common_flags)
px4_add_common_flags()
px4_os_add_flags()
#=============================================================================
# board cmake init (optional)
#
if(EXISTS ${PX4_BOARD_DIR}/cmake/init.cmake)
include(${PX4_BOARD_DIR}/cmake/init.cmake)
endif()
#=============================================================================
# message, and airframe generation
#
@@ -363,25 +332,6 @@ add_subdirectory(msg EXCLUDE_FROM_ALL)
px4_generate_airframes_xml(BOARD ${PX4_BOARD})
#=============================================================================
# DriverFramework
#
px4_add_git_submodule(TARGET git_driverframework PATH "src/lib/DriverFramework")
set(OS ${PX4_PLATFORM})
add_subdirectory(src/lib/DriverFramework/framework)
# List the DriverFramework drivers
if (DEFINED config_df_driver_list)
message("DF Drivers: ${config_df_driver_list}")
endif()
set(df_driver_libs)
foreach(driver ${config_df_driver_list})
add_subdirectory(src/lib/DriverFramework/drivers/${driver})
list(APPEND df_driver_libs df_${driver})
message("Adding DF driver: ${driver}")
endforeach()
#=============================================================================
# external projects
#
@@ -389,11 +339,13 @@ set(ep_base ${PX4_BINARY_DIR}/external)
set_property(DIRECTORY PROPERTY EP_BASE ${ep_base})
# add external project install folders to build
link_directories(${ep_base}/Install/lib)
include_directories(${ep_base}/Install/include)
# add the directories so cmake won't warn
execute_process(COMMAND cmake -E make_directory ${ep_base}/Install/lib)
execute_process(COMMAND cmake -E make_directory ${ep_base}/Install/include)
execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory ${ep_base})
execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory ${ep_base}/Install)
execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory ${ep_base}/Install/lib)
link_directories(${ep_base}/Install/lib)
execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory ${ep_base}/Install/include)
include_directories(${ep_base}/Install/include)
#=============================================================================
# external modules
@@ -415,6 +367,9 @@ endif()
# optionally enable cmake testing (supported only on posix)
option(CMAKE_TESTING "Configure test targets" OFF)
if(${PX4_CONFIG} STREQUAL "px4_sitl_test")
set(CMAKE_TESTING ON)
endif()
if(CMAKE_TESTING)
include(CTest) # sets BUILD_TESTING variable
endif()
@@ -427,18 +382,19 @@ list(APPEND CMAKE_MODULE_PATH ${PX4_SOURCE_DIR}/cmake/gtest/)
include(px4_add_gtest)
if(BUILD_TESTING)
include(gtest)
add_custom_target(test_results
COMMAND GTEST_COLOR=1 ${CMAKE_CTEST_COMMAND} --output-on-failure -T Test -R ${TESTFILTER} USES_TERMINAL
DEPENDS
px4
examples__dyn_hello
test_mixer_multirotor
USES_TERMINAL
COMMENT "Running tests"
WORKING_DIRECTORY ${PX4_BINARY_DIR})
set_target_properties(test_results PROPERTIES EXCLUDE_FROM_ALL TRUE)
endif()
add_custom_target(test_results
COMMAND GTEST_COLOR=1 ${CMAKE_CTEST_COMMAND} --output-on-failure -T Test -R ${TESTFILTER} USES_TERMINAL
DEPENDS
px4
examples__dyn_hello
test_mixer_multirotor
USES_TERMINAL
COMMENT "Running tests"
WORKING_DIRECTORY ${PX4_BINARY_DIR})
set_target_properties(test_results PROPERTIES EXCLUDE_FROM_ALL TRUE)
#=============================================================================
# subdirectories
@@ -448,9 +404,9 @@ add_library(parameters_interface INTERFACE)
include(px4_add_library)
add_subdirectory(src/lib EXCLUDE_FROM_ALL)
add_subdirectory(src/platforms EXCLUDE_FROM_ALL)
add_subdirectory(platforms/${PX4_PLATFORM}/src/px4)
add_subdirectory(platforms EXCLUDE_FROM_ALL)
add_subdirectory(src/modules/uORB EXCLUDE_FROM_ALL) # TODO: platform layer
add_subdirectory(src/drivers/boards EXCLUDE_FROM_ALL)
if(EXISTS "${PX4_BOARD_DIR}/CMakeLists.txt")
add_subdirectory(${PX4_BOARD_DIR})
@@ -479,7 +435,7 @@ endforeach()
add_custom_command(OUTPUT ${uorb_graph_config}
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/uorb_graph/create.py
${module_list}
${graph_module_list}
--exclude-path src/examples
--file ${PX4_SOURCE_DIR}/Tools/uorb_graph/graph_${uorb_graph_config}
WORKING_DIRECTORY ${PX4_SOURCE_DIR}
@@ -487,111 +443,15 @@ add_custom_command(OUTPUT ${uorb_graph_config}
)
add_custom_target(uorb_graph DEPENDS ${uorb_graph_config})
#=============================================================================
# Doxygen
#
option(BUILD_DOXYGEN "Build doxygen documentation" OFF)
if (BUILD_DOXYGEN)
find_package(Doxygen)
if (DOXYGEN_FOUND)
# set input and output files
set(DOXYGEN_IN ${CMAKE_SOURCE_DIR}/Documentation/Doxyfile.in)
set(DOXYGEN_OUT ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile)
include(doxygen)
include(metadata)
include(package)
# request to configure the file
configure_file(${DOXYGEN_IN} ${DOXYGEN_OUT} @ONLY)
# note the option ALL which allows to build the docs together with the application
add_custom_target(doxygen ALL
COMMAND ${DOXYGEN_EXECUTABLE} ${DOXYGEN_OUT}
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
COMMENT "Generating documentation with Doxygen"
DEPENDS uorb_msgs parameters
VERBATIM
USES_TERMINAL
)
else()
message("Doxygen needs to be installed to generate documentation")
endif()
endif()
#=============================================================================
# Metadata - helpers for generating documentation
#
add_custom_target(metadata_airframes
COMMAND ${CMAKE_COMMAND} -E make_directory ${PX4_BINARY_DIR}/docs
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/px_process_airframes.py
-v -a ${PX4_SOURCE_DIR}/ROMFS/px4fmu_common/init.d
--markdown ${PX4_BINARY_DIR}/docs/airframes.md
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/px_process_airframes.py
-v -a ${PX4_SOURCE_DIR}/ROMFS/px4fmu_common/init.d
--xml ${PX4_BINARY_DIR}/docs/airframes.xml
COMMENT "Generating full airframe metadata (markdown and xml)"
# print size
add_custom_target(size
COMMAND size $<TARGET_FILE:px4>
DEPENDS px4
WORKING_DIRECTORY ${PX4_BINARY_DIR}
USES_TERMINAL
)
file(GLOB_RECURSE yaml_config_files ${PX4_SOURCE_DIR}/src/modules/*.yaml
${PX4_SOURCE_DIR}/src/drivers/*.yaml ${PX4_SOURCE_DIR}/src/lib/*.yaml)
add_custom_target(metadata_parameters
COMMAND ${CMAKE_COMMAND} -E make_directory ${PX4_BINARY_DIR}/docs
COMMAND ${PYTHON_EXECUTABLE}
${PX4_SOURCE_DIR}/Tools/serial/generate_config.py --all-ports --params-file ${PX4_SOURCE_DIR}/src/generated_serial_params.c --config-files ${yaml_config_files}
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/src/lib/parameters/px_process_params.py
--src-path `find ${PX4_SOURCE_DIR}/src -maxdepth 4 -type d`
--inject-xml ${PX4_SOURCE_DIR}/src/lib/parameters/parameters_injected.xml
--markdown ${PX4_BINARY_DIR}/docs/parameters.md
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/src/lib/parameters/px_process_params.py
--src-path `find ${PX4_SOURCE_DIR}/src -maxdepth 4 -type d`
--inject-xml ${PX4_SOURCE_DIR}/src/lib/parameters/parameters_injected.xml
--xml ${PX4_BINARY_DIR}/docs/parameters.xml
COMMENT "Generating full parameter metadata (markdown and xml)"
USES_TERMINAL
)
add_custom_target(metadata_module_documentation
COMMAND ${CMAKE_COMMAND} -E make_directory ${PX4_BINARY_DIR}/docs
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/px_process_module_doc.py -v --src-path ${PX4_SOURCE_DIR}/src
--markdown ${PX4_BINARY_DIR}/docs/modules
COMMENT "Generating module documentation"
USES_TERMINAL
)
add_custom_target(all_metadata
DEPENDS
metadata_airframes
metadata_parameters
metadata_module_documentation
)
#=============================================================================
# packaging
#
# Important to having packaging at end of cmake file.
#
set(CPACK_PACKAGE_NAME ${PROJECT_NAME}-${PX4_CONFIG})
set(CPACK_PACKAGE_VERSION ${PX4_GIT_TAG})
set(CPACK_PACKAGE_CONTACT ${package-contact})
set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS OFF) # TODO: review packaging for linux boards
set(CPACK_DEBIAN_PACKAGE_SECTION "devel")
set(CPACK_DEBIAN_PACKAGE_PRIORITY "optional")
set(CPACK_DEBIAN_PACKAGE_DESCRIPTION "The PX4 Pro autopilot.")
set(CPACK_PACKAGE_FILE_NAME "${PROJECT_NAME}-${PX4_CONFIG}-${PX4_GIT_TAG}")
set(CPACK_SOURCE_PACKAGE_FILE_NAME "${PROJECT_NAME}-${PX4_GIT_TAG}")
set(CPACK_SOURCE_GENERATOR "ZIP;TBZ2")
set(CPACK_PACKAGING_INSTALL_PREFIX "")
set(CPACK_SET_DESTDIR "OFF")
if ("${CMAKE_SYSTEM}" MATCHES "Linux")
set(CPACK_GENERATOR "TBZ2")
find_program(DPKG_PROGRAM dpkg)
if (EXISTS ${DPKG_PROGRAM})
list (APPEND CPACK_GENERATOR "DEB")
endif()
else()
set(CPACK_GENERATOR "ZIP")
endif()
include(CPack)
)
+1 -1
View File
@@ -41,4 +41,4 @@ Since we care about safety, we will regularly ask you for test results. Best is
Push changes to your repo and send a [pull request](https://github.com/PX4/Firmware/compare/).
MuncherMake sure to provide some testing feedback and if possible the link to a flight log file. Upload flight log files to [Flight Review](http://logs.px4.io) and link the resulting report.
Make sure to provide some testing feedback and if possible the link to a flight log file. Upload flight log files to [Flight Review](http://logs.px4.io) and link the resulting report.
+1 -2
View File
@@ -828,8 +828,7 @@ RECURSIVE = YES
# Note that relative paths are relative to the directory from which doxygen is
# run.
EXCLUDE = @CMAKE_SOURCE_DIR@/src/lib/DriverFramework \
@CMAKE_SOURCE_DIR@/src/modules/uavcan/libuavcan \
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
+106 -369
View File
@@ -5,49 +5,58 @@ pipeline {
stages {
stage('Analysis') {
parallel {
stage('Catkin build on ROS workspace') {
agent {
docker {
image 'px4io/px4-dev-ros-melodic:2019-03-08'
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;
source /opt/ros/melodic/setup.bash;
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'
}
}
options {
checkoutToSubdirectory('catkin_ws/src/Firmware')
}
when {
anyOf {
branch 'master'
branch 'pr-jenkins' // for testing
}
}
parallel {
// stage('Catkin build on ROS workspace') {
// agent {
// docker {
// image 'px4io/px4-dev-ros-melodic:2020-08-20'
// 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-bouncy:2019-03-08'
image 'px4io/px4-dev-ros2-foxy:2020-08-20'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw -e HOME=$WORKSPACE'
}
}
@@ -60,6 +69,7 @@ pipeline {
cd colcon_ws;
git -C ${WORKSPACE}/colcon_ws/src/Firmware submodule update --init --recursive --force Tools/sitl_gazebo
git clone --recursive ${WORKSPACE}/colcon_ws/src/Firmware/Tools/sitl_gazebo src/mavlink_sitl_gazebo;
git -C ${WORKSPACE}/colcon_ws/src/Firmware fetch --tags;
source /opt/ros/bouncy/setup.sh;
source /opt/ros/melodic/setup.sh;
colcon build --event-handlers console_direct+ --symlink-install;
@@ -75,326 +85,9 @@ pipeline {
}
}
stage('Style check') {
agent {
docker { image 'px4io/px4-dev-base-bionic:2019-03-08' }
}
steps {
sh 'make check_format'
}
post {
always {
sh 'rm -rf catkin_ws'
}
}
}
stage('Bloaty px4_fmu-v2') {
agent {
docker {
image 'px4io/px4-dev-nuttx:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'git fetch --tags'
sh 'make px4_fmu-v2_default'
sh 'make px4_fmu-v2_default bloaty_symbols'
sh 'make px4_fmu-v2_default bloaty_compileunits'
sh 'make px4_fmu-v2_default bloaty_inlines'
sh 'make px4_fmu-v2_default bloaty_templates'
sh 'make px4_fmu-v2_default bloaty_compare_master'
sh 'make sizes'
sh 'ccache -s'
}
post {
always {
sh 'make distclean'
}
}
}
stage('Bloaty px4_fmu-v5') {
agent {
docker {
image 'px4io/px4-dev-nuttx:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'git fetch --tags'
sh 'make px4_fmu-v5_default'
sh 'make px4_fmu-v5_default bloaty_symbols'
sh 'make px4_fmu-v5_default bloaty_compileunits'
sh 'make px4_fmu-v5_default bloaty_inlines'
sh 'make px4_fmu-v5_default bloaty_templates'
sh 'make px4_fmu-v5_default bloaty_compare_master'
sh 'make sizes'
sh 'ccache -s'
}
post {
always {
sh 'make distclean'
}
}
}
stage('No-ninja px4_fmu-v2') {
agent {
docker {
image 'px4io/px4-dev-nuttx:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'git fetch --tags'
sh 'NO_NINJA_BUILD=1 make px4_fmu-v2_default'
sh 'ccache -s'
}
post {
always {
sh 'make distclean'
}
}
}
stage('No-ninja px4_fmu-v5') {
agent {
docker {
image 'px4io/px4-dev-nuttx:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'git fetch --tags'
sh 'NO_NINJA_BUILD=1 make px4_fmu-v5_default'
sh 'ccache -s'
}
post {
always {
sh 'make distclean'
}
}
}
stage('No-ninja SITL build') {
agent {
docker {
image 'px4io/px4-dev-base-bionic:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'git fetch --tags'
sh 'NO_NINJA_BUILD=1 make px4_sitl_default'
sh 'ccache -s'
}
post {
always {
sh 'make distclean'
}
}
}
stage('SITL unit tests') {
agent {
docker {
image 'px4io/px4-dev-base-bionic:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'ccache -z'
sh 'git fetch --tags'
sh 'make tests'
sh 'ccache -s'
}
post {
always {
sh 'make distclean'
}
}
}
stage('Clang analyzer') {
agent {
docker {
image 'px4io/px4-dev-clang:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'make scan-build'
// publish html
publishHTML target: [
reportTitles: 'clang static analyzer',
allowMissing: false,
alwaysLinkToLastBuild: true,
keepAll: true,
reportDir: 'build/scan-build/report_latest',
reportFiles: '*',
reportName: 'Clang Static Analyzer'
]
}
post {
always {
sh 'make distclean'
}
}
when {
anyOf {
branch 'master'
branch 'beta'
branch 'stable'
branch 'pr-jenkins' // for testing
}
}
}
// stage('Clang tidy') {
// agent {
// docker {
// image 'px4io/px4-dev-clang:2019-03-08'
// args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
// }
// }
// steps {
// sh 'export'
// retry (3) {
// sh 'make distclean'
// sh 'make clang-tidy-quiet'
// }
// }
// post {
// always {
// sh 'make distclean'
// }
// }
// }
stage('Cppcheck') {
agent {
docker {
image 'px4io/px4-dev-base-bionic:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'make cppcheck'
// publish html
publishHTML target: [
reportTitles: 'Cppcheck',
allowMissing: false,
alwaysLinkToLastBuild: true,
keepAll: true,
reportDir: 'build/cppcheck/',
reportFiles: '*',
reportName: 'Cppcheck'
]
}
post {
always {
sh 'make distclean'
}
}
when {
anyOf {
branch 'master'
branch 'beta'
branch 'stable'
branch 'pr-jenkins' // for testing
}
}
}
stage('Check stack') {
agent {
docker {
image 'px4io/px4-dev-nuttx:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'make px4_fmu-v2_default stack_check'
}
post {
always {
sh 'make distclean'
}
}
}
stage('ShellCheck') {
agent {
docker {
image 'px4io/px4-dev-nuttx:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'make shellcheck_all'
}
post {
always {
sh 'make distclean'
}
}
}
stage('Module config validation') {
agent {
docker {
image 'px4io/px4-dev-base-bionic:2019-03-08'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
steps {
sh 'export'
sh 'make distclean'
sh 'make validate_module_configs'
}
post {
always {
sh 'make distclean'
}
}
}
} // parallel
} // stage Analysis
stage('Generate Metadata') {
parallel {
stage('Airframe') {
agent {
docker { image 'px4io/px4-dev-base-bionic:2019-03-08' }
docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
}
steps {
sh 'make distclean'
@@ -413,7 +106,7 @@ pipeline {
stage('Parameter') {
agent {
docker { image 'px4io/px4-dev-base-bionic:2019-03-08' }
docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
}
steps {
sh 'make distclean'
@@ -432,7 +125,7 @@ pipeline {
stage('Module') {
agent {
docker { image 'px4io/px4-dev-base-bionic:2019-03-08' }
docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
}
steps {
sh 'make distclean'
@@ -452,7 +145,7 @@ pipeline {
stage('uORB graphs') {
agent {
docker {
image 'px4io/px4-dev-nuttx:2019-03-08'
image 'px4io/px4-dev-nuttx-focal:2020-09-14'
args '-e CCACHE_BASEDIR=$WORKSPACE -v ${CCACHE_DIR}:${CCACHE_DIR}:rw'
}
}
@@ -481,7 +174,7 @@ pipeline {
stage('Devguide') {
agent {
docker { image 'px4io/px4-dev-base-bionic:2019-03-08' }
docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
}
steps {
sh('export')
@@ -511,16 +204,18 @@ pipeline {
stage('Userguide') {
agent {
docker { image 'px4io/px4-dev-base-bionic:2019-03-08' }
docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
}
steps {
sh('export')
unstash 'metadata_airframes'
unstash 'metadata_parameters'
unstash 'metadata_module_documentation'
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('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')
@@ -539,7 +234,7 @@ pipeline {
stage('QGroundControl') {
agent {
docker { image 'px4io/px4-dev-base-bionic:2019-03-08' }
docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
}
steps {
sh('export')
@@ -565,9 +260,39 @@ pipeline {
}
}
stage('microRTPS agent') {
agent {
docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
}
steps {
sh('export')
sh('git fetch --all --tags')
sh('make distclean')
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-bionic:2019-03-08' }
docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
}
steps {
sh('export')
@@ -575,12 +300,12 @@ pipeline {
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('python msg/tools/uorb_to_ros_msgs.py msg/ px4_msgs/msg/')
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 master || true')
// 'ros1' branch
sh('cd px4_msgs; git checkout ros1')
sh('python msg/tools/uorb_to_ros_msgs.py msg/ px4_msgs/msg/')
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('rm -rf px4_msgs')
@@ -596,7 +321,7 @@ pipeline {
stage('PX4 ROS2 bridge') {
agent {
docker { image 'px4io/px4-dev-base-bionic:2019-03-08' }
docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
}
steps {
sh('export')
@@ -604,7 +329,7 @@ pipeline {
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('python msg/tools/uorb_to_ros_rtps_ids.py -i msg/tools/uorb_rtps_message_ids.yaml -o px4_ros_com/templates/uorb_rtps_message_ids.yaml')
sh('./msg/tools/uorb_to_ros_rtps_ids.py -i msg/tools/uorb_rtps_message_ids.yaml -o px4_ros_com/templates/uorb_rtps_message_ids.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
@@ -612,6 +337,18 @@ pipeline {
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')
@@ -627,7 +364,7 @@ pipeline {
stage('S3') {
agent {
docker { image 'px4io/px4-dev-base-bionic:2019-03-08' }
docker { image 'px4io/px4-dev-base-focal:2020-09-14' }
}
steps {
sh('export')
@@ -664,7 +401,7 @@ pipeline {
GIT_COMMITTER_NAME = "PX4BuildBot"
}
options {
buildDiscarder(logRotator(numToKeepStr: '20', artifactDaysToKeepStr: '30'))
buildDiscarder(logRotator(numToKeepStr: '10', artifactDaysToKeepStr: '20'))
timeout(time: 60, unit: 'MINUTES')
}
}
+1 -1
View File
@@ -1,6 +1,6 @@
BSD 3-Clause License
Copyright (c) 2012 - 2019, PX4 Development Team
Copyright (c) 2012 - 2020, PX4 Development Team
All rights reserved.
Redistribution and use in source and binary forms, with or without
+71 -36
View File
@@ -1,6 +1,6 @@
############################################################################
#
# Copyright (c) 2015 - 2019 PX4 Development Team. All rights reserved.
# Copyright (c) 2015 - 2020 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
@@ -62,6 +62,10 @@ all: px4_sitl_default
# define a space character to be able to explicitly find it in strings
space := $(subst ,, )
define make_list
$(shell cat .github/workflows/compile_${1}.yml | sed -E 's|[[:space:]]+(.*),|check_\1|g' | grep check_${2})
endef
# Parsing
# --------------------------------------------------------------------
# assume 1st argument passed is the main target, the
@@ -69,7 +73,14 @@ space := $(subst ,, )
# by cmake in the subdirectory
FIRST_ARG := $(firstword $(MAKECMDGOALS))
ARGS := $(wordlist 2,$(words $(MAKECMDGOALS)),$(MAKECMDGOALS))
j ?= 4
# Get -j or --jobs argument as suggested in:
# https://stackoverflow.com/a/33616144/8548472
MAKE_PID := $(shell echo $$PPID)
j := $(shell ps T | sed -n 's|.*$(MAKE_PID).*$(MAKE).* \(-j\|--jobs\) *\([0-9][0-9]*\).*|\2|p')
# Default j for clang-tidy
j_clang_tidy := $(or $(j),4)
NINJA_BIN := ninja
ifndef NO_NINJA_BUILD
@@ -90,6 +101,11 @@ ifdef NINJA_BUILD
else
PX4_MAKE_ARGS :=
endif
# Only override ninja default if -j is set.
ifneq ($(j),)
PX4_MAKE_ARGS := $(PX4_MAKE_ARGS) -j$(j)
endif
else
ifdef SYSTEMROOT
# Windows
@@ -97,6 +113,9 @@ else
else
PX4_CMAKE_GENERATOR := "Unix\ Makefiles"
endif
# For non-ninja builds we default to -j4
j := $(or $(j),4)
PX4_MAKE = $(MAKE)
PX4_MAKE_ARGS = -j$(j) --no-print-directory
endif
@@ -141,6 +160,11 @@ else
endif
# Pick up specific Python path if set
ifdef PYTHON_EXECUTABLE
CMAKE_ARGS += -DPYTHON_EXECUTABLE=${PYTHON_EXECUTABLE}
endif
# Functions
# --------------------------------------------------------------------
# describe how to build a cmake config
@@ -165,9 +189,9 @@ endef
define cmake-cache-check
@# change to build folder which fails if it doesn't exist and CACHED_CMAKE_OPTIONS stays empty
@# fetch all previously configured and cached options from the build folder and transform them into the OPTION=VALUE format without type (e.g. :BOOL)
@$(eval CACHED_CMAKE_OPTIONS = $(shell cd $(BUILD_DIR) 2>/dev/null && cmake -L 2>/dev/null | sed -n 's/\([^[:blank:]]*\):[^[:blank:]]*\(=[^[:blank:]]*\)/\1\2/gp' ))
@$(eval CACHED_CMAKE_OPTIONS = $(shell cd $(BUILD_DIR) 2>/dev/null && cmake -L 2>/dev/null | sed -n 's|\([^[:blank:]]*\):[^[:blank:]]*\(=[^[:blank:]]*\)|\1\2|gp' ))
@# transform the options in CMAKE_ARGS into the OPTION=VALUE format without -D
@$(eval DESIRED_CMAKE_OPTIONS = $(shell echo $(CMAKE_ARGS) | sed -n 's/-D\([^[:blank:]]*=[^[:blank:]]*\)/\1/gp' ))
@$(eval DESIRED_CMAKE_OPTIONS = $(shell echo $(CMAKE_ARGS) | sed -n 's|-D\([^[:blank:]]*=[^[:blank:]]*\)|\1|gp' ))
@# find each currently desired option in the already cached ones making sure the complete configured string value is the same
@$(eval VERIFIED_CMAKE_OPTIONS = $(foreach option,$(DESIRED_CMAKE_OPTIONS),$(strip $(findstring $(option)$(space),$(CACHED_CMAKE_OPTIONS)))))
@# if the complete list of desired options is found in the list of verified options we don't need to reconfigure and CMAKE_CACHE_CHECK stays empty
@@ -182,7 +206,7 @@ define colorecho
endef
# Get a list of all config targets boards/*/*.cmake
ALL_CONFIG_TARGETS := $(shell find boards -maxdepth 3 -mindepth 3 ! -name '*common*' ! -name '*sdflight*' -name '*.cmake' -print | sed -e 's/boards\///' | sed -e 's/\.cmake//' | sed -e 's/\//_/g' | sort)
ALL_CONFIG_TARGETS := $(shell find boards -maxdepth 3 -mindepth 3 ! -name '*common*' ! -name '*sdflight*' -name '*.cmake' -print | sed -e 's|boards\/||' | sed -e 's|\.cmake||' | sed -e 's|\/|_|g' | sort)
# ADD CONFIGS HERE
# --------------------------------------------------------------------
@@ -204,29 +228,19 @@ $(CONFIG_TARGETS_DEFAULT):
all_config_targets: $(ALL_CONFIG_TARGETS)
all_default_targets: $(CONFIG_TARGETS_DEFAULT)
posix: px4_sitl_default
# board reorganization deprecation warnings (2018-11-22)
define deprecation_warning
$(warning $(1) has been deprecated and will be removed, please use $(2)!)
endef
px4fmu-%_default:
$(call deprecation_warning, ${@},$(subst px4fmu,px4_fmu,$@))
$(MAKE) $(subst px4fmu,px4_fmu, $@)
posix_sitl_default:
$(call deprecation_warning, ${@},px4_sitl_default)
$(MAKE) px4_sitl_default
# All targets with just dependencies but no recipe must either be marked as phony (or have the special @: as recipe).
.PHONY: all posix px4_sitl_default all_config_targets all_default_targets
.PHONY: all px4_sitl_default all_config_targets all_default_targets
# Multi- config targets.
eagle_default: atlflight_eagle_default atlflight_eagle_qurt-default
eagle_default: atlflight_eagle_default atlflight_eagle_qurt
eagle_rtps: atlflight_eagle_rtps atlflight_eagle_qurt-rtps
excelsior_default: atlflight_excelsior_default atlflight_excelsior_qurt-default
excelsior_default: atlflight_excelsior_default atlflight_excelsior_qurt
excelsior_rtps: atlflight_excelsior_rtps atlflight_excelsior_qurt-rtps
.PHONY: eagle_default eagle_rtps
@@ -235,7 +249,7 @@ excelsior_rtps: atlflight_excelsior_rtps atlflight_excelsior_qurt-rtps
# Other targets
# --------------------------------------------------------------------
.PHONY: qgc_firmware px4fmu_firmware misc_qgc_extra_firmware alt_firmware check_rtps
.PHONY: qgc_firmware px4fmu_firmware misc_qgc_extra_firmware check_rtps
# QGroundControl flashable NuttX firmware
qgc_firmware: px4fmu_firmware misc_qgc_extra_firmware
@@ -248,25 +262,19 @@ px4fmu_firmware: \
check_px4_fmu-v4_default \
check_px4_fmu-v4pro_default \
check_px4_fmu-v5_default \
check_px4_fmu-v5x_default \
sizes
misc_qgc_extra_firmware: \
check_nxp_fmuk66-v3_default \
check_nxp_fmurt1062-v1_default \
check_intel_aerofc-v1_default \
check_auav_x21_default \
check_mro_x21_default \
check_bitcraze_crazyflie_default \
check_airmind_mindpx-v2_default \
check_px4_fmu-v2_lpe \
sizes
# Other NuttX firmware
alt_firmware: \
check_px4_cannode-v1_default \
check_px4_esc-v1_default \
check_auav_esc35-v1_default \
check_thiemar_s2740vc-v1_default \
sizes
# builds with RTPS
check_rtps: \
check_px4_fmu-v3_rtps \
@@ -281,9 +289,9 @@ sizes:
@-find build -name *.elf -type f | xargs size 2> /dev/null || :
# All default targets that don't require a special build environment
check: check_px4_sitl_default px4fmu_firmware misc_qgc_extra_firmware alt_firmware tests check_format
check: check_px4_sitl_default px4fmu_firmware misc_qgc_extra_firmware tests check_format
# quick_check builds a single nuttx and posix target, runs testing, and checks the style
# quick_check builds a single nuttx and SITL target, runs testing, and checks the style
quick_check: check_px4_sitl_test check_px4_fmu-v5_default tests check_format
check_%:
@@ -344,7 +352,6 @@ format:
.PHONY: rostest python_coverage
tests:
$(eval CMAKE_ARGS += -DCMAKE_TESTING=ON)
$(eval CMAKE_ARGS += -DCONFIG=px4_sitl_test)
$(eval CMAKE_ARGS += -DTESTFILTER=$(TESTFILTER))
$(eval ARGS += test_results)
@@ -360,6 +367,20 @@ tests_coverage:
rostest: px4_sitl_default
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo
tests_integration: px4_sitl_default
@$(MAKE) --no-print-directory px4_sitl_default sitl_gazebo
@$(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 mavsdk_tests
@"$(SRC_DIR)"/test/mavsdk_tests/mavsdk_test_runner.py --speed-factor 20 test/mavsdk_tests/configs/sitl.json
@mkdir -p coverage
@lcov --directory build/px4_sitl_default --base-directory build/px4_sitl_default --gcov-tool gcov --capture -o coverage/lcov.info
tests_mission: rostest
@"$(SRC_DIR)"/test/rostest_px4_run.sh mavros_posix_tests_missions.test
@@ -377,9 +398,11 @@ tests_mission_coverage:
tests_offboard: rostest
@"$(SRC_DIR)"/test/rostest_px4_run.sh mavros_posix_tests_offboard_attctl.test
@"$(SRC_DIR)"/test/rostest_px4_run.sh mavros_posix_tests_offboard_posctl.test
@"$(SRC_DIR)"/test/rostest_px4_run.sh mavros_posix_tests_offboard_rpyrt_ctl.test
tests_avoidance: rostest
@"$(SRC_DIR)"/test/rostest_avoidance_run.sh mavros_posix_test_avoidance.test
@"$(SRC_DIR)"/test/rostest_avoidance_run.sh mavros_posix_test_safe_landing.test
python_coverage:
@mkdir -p "$(SRC_DIR)"/build/python_coverage
@@ -413,21 +436,21 @@ px4_sitl_default-clang:
@$(PX4_MAKE) -C "$(SRC_DIR)"/build/px4_sitl_default-clang
clang-tidy: px4_sitl_default-clang
@cd "$(SRC_DIR)"/build/px4_sitl_default-clang && "$(SRC_DIR)"/Tools/run-clang-tidy.py -header-filter=".*\.hpp" -j$(j) -p .
@cd "$(SRC_DIR)"/build/px4_sitl_default-clang && "$(SRC_DIR)"/Tools/run-clang-tidy.py -header-filter=".*\.hpp" -j$(j_clang_tidy) -p .
# to automatically fix a single check at a time, eg modernize-redundant-void-arg
# % run-clang-tidy-4.0.py -fix -j4 -checks=-\*,modernize-redundant-void-arg -p .
clang-tidy-fix: px4_sitl_default-clang
@cd "$(SRC_DIR)"/build/px4_sitl_default-clang && "$(SRC_DIR)"/Tools/run-clang-tidy.py -header-filter=".*\.hpp" -j$(j) -fix -p .
@cd "$(SRC_DIR)"/build/px4_sitl_default-clang && "$(SRC_DIR)"/Tools/run-clang-tidy.py -header-filter=".*\.hpp" -j$(j_clang_tidy) -fix -p .
# modified version of run-clang-tidy.py to return error codes and only output relevant results
clang-tidy-quiet: px4_sitl_default-clang
@cd "$(SRC_DIR)"/build/px4_sitl_default-clang && "$(SRC_DIR)"/Tools/run-clang-tidy.py -header-filter=".*\.hpp" -j$(j) -p .
@cd "$(SRC_DIR)"/build/px4_sitl_default-clang && "$(SRC_DIR)"/Tools/run-clang-tidy.py -header-filter=".*\.hpp" -j$(j_clang_tidy) -p .
# TODO: Fix cppcheck errors then try --enable=warning,performance,portability,style,unusedFunction or --enable=all
cppcheck: px4_sitl_default
@mkdir -p "$(SRC_DIR)"/build/cppcheck
@cppcheck -i"$(SRC_DIR)"/src/examples --enable=performance --std=c++11 --std=c99 --std=posix --project="$(SRC_DIR)"/build/px4_sitl_default/compile_commands.json --xml-version=2 2> "$(SRC_DIR)"/build/cppcheck/cppcheck-result.xml > /dev/null
@cppcheck -i"$(SRC_DIR)"/src/examples --enable=performance --std=c++14 --std=c99 --std=posix --project="$(SRC_DIR)"/build/px4_sitl_default/compile_commands.json --xml-version=2 2> "$(SRC_DIR)"/build/cppcheck/cppcheck-result.xml > /dev/null
@cppcheck-htmlreport --source-encoding=ascii --file="$(SRC_DIR)"/build/cppcheck/cppcheck-result.xml --report-dir="$(SRC_DIR)"/build/cppcheck --source-dir="$(SRC_DIR)"/src/
shellcheck_all:
@@ -468,7 +491,7 @@ distclean: gazeboclean
# All other targets are handled by PX4_MAKE. Add a rule here to avoid printing an error.
%:
$(if $(filter $(FIRST_ARG),$@), \
$(error "$@ cannot be the first argument. Use '$(MAKE) help|list_config_targets' to get a list of all possible [configuration] targets."),@#)
$(error "Make target $@ not found. It either does not exist or $@ cannot be the first argument. Use '$(MAKE) help|list_config_targets' to get a list of all possible [configuration] targets."),@#)
# Print a list of non-config targets (based on http://stackoverflow.com/a/26339924/1487069)
help:
@@ -484,3 +507,15 @@ help:
# Print a list of all config targets.
list_config_targets:
@for targ in $(patsubst %_default,%[_default],$(ALL_CONFIG_TARGETS)); do echo $$targ; done
check_nuttx : $(call make_list,nuttx) \
sizes
check_linux : $(call make_list,linux) \
sizes
check_px4: $(call make_list,nuttx,"px4") \
sizes
check_nxp: $(call make_list,nuttx,"nxp") \
sizes
+7 -6
View File
@@ -1,16 +1,17 @@
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 the proposed pull request**
A clear and concise description of the problem this proposed change will solve. E.g. For this use case I ran into...
**Describe problem solved by this pull request**
A clear and concise description of the problem this proposed change will solve.
E.g. For this use case I ran into...
**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.
**Describe your preferred solution**
**Describe your solution**
A clear and concise description of what you have implemented.
**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.
**Additional context**
Add any other related context or media.
+57 -54
View File
@@ -2,106 +2,109 @@
[![Releases](https://img.shields.io/github/release/PX4/Firmware.svg)](https://github.com/PX4/Firmware/releases) [![DOI](https://zenodo.org/badge/22634/PX4/Firmware.svg)](https://zenodo.org/badge/latestdoi/22634/PX4/Firmware)
[![Build Status](http://ci.px4.io:8080/buildStatus/icon?job=PX4/Firmware/master)](http://ci.px4.io:8080/blue/organizations/jenkins/PX4%2FFirmware/activity)
[![Nuttx Targets](https://github.com/PX4/Firmware/workflows/Nuttx%20Targets/badge.svg)](https://github.com/PX4/Firmware/actions?query=workflow%3A%22Nuttx+Targets%22?branch=master) [![SITL Tests](https://github.com/PX4/Firmware/workflows/SITL%20Tests/badge.svg?branch=master)](https://github.com/PX4/Firmware/actions?query=workflow%3A%22SITL+Tests%22)
[![Slack](https://px4-slack.herokuapp.com/badge.svg)](http://slack.px4.io)
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/Firmware/tree/master/src/modules) directory. It also contains the PX4 Drone Middleware Platform, which provides drivers and middleware to run drones.
* Official Website: http://px4.io (License: BSD 3-clause, [LICENSE](https://github.com/PX4/Firmware/blob/master/LICENSE))
* [Supported airframes](https://docs.px4.io/en/airframes/airframe_reference.html) ([portfolio](http://px4.io/#airframes)):
* [Multicopters](https://docs.px4.io/en/airframes/airframe_reference.html#copter)
* [Fixed wing](https://docs.px4.io/en/airframes/airframe_reference.html#plane)
* [VTOL](https://docs.px4.io/en/airframes/airframe_reference.html#vtol)
* many more experimental types (Rovers, Blimps, Boats, Submarines, etc)
* [Supported airframes](https://docs.px4.io/master/en/airframes/airframe_reference.html) ([portfolio](http://px4.io/#airframes)):
* [Multicopters](https://docs.px4.io/master/en/airframes/airframe_reference.html#copter)
* [Fixed wing](https://docs.px4.io/master/en/airframes/airframe_reference.html#plane)
* [VTOL](https://docs.px4.io/master/en/airframes/airframe_reference.html#vtol)
* many more experimental types (Rovers, Blimps, Boats, Submarines, Autogyros, etc)
* Releases: [Downloads](https://github.com/PX4/Firmware/releases)
## PX4 Users
The [PX4 User Guide](https://docs.px4.io/en/) explains how to assemble [supported vehicles](https://docs.px4.io/en/airframes/airframe_reference.html) and fly drones with PX4.
See the [forum and chat](https://docs.px4.io/en/#support) if you need help!
The [PX4 User Guide](https://docs.px4.io/master/en/) explains how to assemble [supported vehicles](https://docs.px4.io/master/en/airframes/airframe_reference.html) and fly drones with PX4.
See the [forum and chat](https://docs.px4.io/master/en/#support) if you need help!
## PX4 Developers
This [Developer Guide](https://dev.px4.io/) is for software developers who want to modify the flight stack and middleware (e.g. to add new flight modes), hardware integrators who want to support new flight controller boards and peripherals, and anyone who wants to get PX4 working on a new (unsupported) airframe/vehicle.
Developers should read the [Guide for Contributions](https://dev.px4.io/en/contribute/).
See the [forum and chat](https://dev.px4.io/en/#support) if you need help!
Developers should read the [Guide for Contributions](https://dev.px4.io/master/en/contribute/).
See the [forum and chat](https://dev.px4.io/master/en/#support) if you need help!
### Weekly Dev Call
The PX4 Dev Team syncs up on a [weekly dev call](https://dev.px4.io/en/contribute/#dev_call).
The PX4 Dev Team syncs up on a [weekly dev call](https://dev.px4.io/master/en/contribute/#dev_call).
> **Note** The dev call is open to all interested developers (not just the core dev team). This is a great opportunity to meet the team and contribute to the ongoing development of the platform. It includes a QA session for newcomers. All regular calls are listed in the [Dronecode calendar](https://www.dronecode.org/calendar/).
## Maintenance Team
* Project: Founder - [Lorenz Meier](https://github.com/LorenzMeier), Architecture: [Daniel Agar](https://github.com/dagar)
* [Dev Call](https://github.com/PX4/Firmware/labels/devcall) - [Ramon Roche](https://github.com/mrpollo)
* Project: Founder
* [Lorenz Meier](https://github.com/LorenzMeier)
* Architecture
* [Daniel Agar](https://github.com/dagar)
* [Dev Call](https://github.com/PX4/Firmware/labels/devcall)
* [Ramon Roche](https://github.com/mrpollo)
* Communication Architecture
* [Beat Kueng](https://github.com/bkueng)
* [Julian Oes](https://github.com/JulianOes)
* UI / UX
* [Donald Gagne](https://github.com/DonLakeFlyer)
* UI in QGroundControl
* [Gus Grubba](https://github.com/dogmaphobic)
* [Multicopter Flight Control](https://github.com/PX4/Firmware/labels/multicopter)
* [Dennis Mannhart](https://github.com/Stifael)
* [Mathieu Bresciani](https://github.com/bresch)
* [Multicopter Software Architecture](https://github.com/PX4/Firmware/labels/multicopter)
* [Matthias Grob](https://github.com/MaEtUgR)
* [VTOL Flight Control](https://github.com/PX4/Firmware/labels/vtol)
* [Daniel Agar](https://github.com/dagar)
* [Mathieu Bresciani](https://github.com/bresch)
* [Sander Smeets](https://github.com/sanderux)
* [Roman Bapst](https://github.com/tumbili)
* [Andreas Antener](https://github.com/AndreasAntener)
* [Roman Bapst](https://github.com/RomanBapst)
* [Fixed Wing Flight Control](https://github.com/PX4/Firmware/labels/fixedwing)
* [Roman Bapst](https://github.com/RomanBapst)
* OS / NuttX
* [David Sidrane](https://github.com/davids5)
* Driver Architecture
* [Daniel Agar](https://github.com/dagar)
* Commander Architecture
* [Julian Oes](https://github.com/julianoes)
* [UAVCAN](https://github.com/PX4/Firmware/labels/uavcan)
* [Daniel Agar](https://github.com/dagar)
* [State Estimation](https://github.com/PX4/Firmware/issues?q=is%3Aopen+is%3Aissue+label%3A%22state+estimation%22)
* [Paul Riseborough](https://github.com/priseborough)
* Racers - [Matthias Grob](https://github.com/MaEtUgR)
* OS / drivers - [David Sidrane](https://github.com/davids5)
* [UAVCAN](https://github.com/PX4/Firmware/labels/uavcan) / Industrial - [Pavel Kirienko](https://github.com/pavel-kirienko)
* [State Estimation](https://github.com/PX4/Firmware/issues?q=is%3Aopen+is%3Aissue+label%3A%22state+estimation%22) - [James Goppert](https://github.com/jgoppert), [Paul Riseborough](https://github.com/priseborough)
* Vision based navigation
* [Christoph Tobler](https://github.com/ChristophTobler)
* [Mohammed Kabir](https://github.com/mhkabir)
* Obstacle Avoidance - [Martina Rivizzigno](https://github.com/mrivi)
* [Snapdragon](https://github.com/PX4/Firmware/labels/snapdragon)
* [Christoph Tobler](https://github.com/ChristophTobler)
* [Intel Aero](https://github.com/PX4/Firmware/labels/intel%20aero)
* [Sugnan Prabhu](https://github.com/sugnanprabhu)
* [José Roberto de Souza](https://github.com/zehortigoza)
* [Raspberry Pi / Navio](https://github.com/PX4/Firmware/labels/raspberry_pi) - [Beat Kueng](https://github.com/bkueng)
* [Airmind MindPX / MindRacer](https://github.com/PX4/Firmware/labels/mindpx) - [Henry Zhang](https://github.com/iZhangHui)
* RTPS/ROS2 Interface - [Nuno Marques](https://github.com/TSC21)
* [Julian Kent](https://github.com/jkflying)
* Obstacle Avoidance
* [Martina Rivizzigno](https://github.com/mrivi)
* RTPS/ROS2 Interface
* [Nuno Marques](https://github.com/TSC21)
See also [About Us](http://px4.io/about-us/#development_team) (px4.io) and the [contributors list](https://github.com/PX4/Firmware/graphs/contributors) (Github).
See also [maintainers list](https://px4.io/community/maintainers/) (px4.io) and the [contributors list](https://github.com/PX4/Firmware/graphs/contributors) (Github).
## Supported Hardware
This repository contains code supporting these boards:
* [Snapdragon Flight](https://docs.px4.io/en/flight_controller/snapdragon_flight.html)
* [Intel Aero](https://docs.px4.io/en/flight_controller/intel_aero.html)
* [Raspberry PI with Navio 2](https://docs.px4.io/en/flight_controller/raspberry_pi_navio2.html)
* [Parrot Bebop 2](https://dev.px4.io/en/advanced/parrot_bebop.html)
* FMUv2.x
* [Pixhawk](https://docs.px4.io/en/flight_controller/pixhawk.html)
* [Pixhawk Mini](https://docs.px4.io/en/flight_controller/pixhawk_mini.html)
* [Pixfalcon](https://docs.px4.io/en/flight_controller/pixfalcon.html)
* FMUv3.x [Pixhawk 2](https://docs.px4.io/en/flight_controller/pixhawk-2.html)
* FMUv4.x
* [Pixracer](https://docs.px4.io/en/flight_controller/pixracer.html)
* [Pixhawk 3 Pro](https://docs.px4.io/en/flight_controller/pixhawk3_pro.html)
* FMUv5.x (ARM Cortex M7)
* [Pixhawk 4](https://docs.px4.io/en/flight_controller/pixhawk4.html)
* [Pixhawk 4 mini](https://docs.px4.io/en/flight_controller/pixhawk4_mini.html)
* FMUv2
* [Pixhawk](https://docs.px4.io/master/en/flight_controller/pixhawk.html)
* [Pixfalcon](https://docs.px4.io/master/en/flight_controller/pixfalcon.html)
* FMUv3
* [Pixhawk 2](https://docs.px4.io/master/en/flight_controller/pixhawk-2.html)
* [Pixhawk Mini](https://docs.px4.io/master/en/flight_controller/pixhawk_mini.html)
* [CUAV Pixhack v3](https://docs.px4.io/master/en/flight_controller/pixhack_v3.html)
* FMUv4
* [Pixracer](https://docs.px4.io/master/en/flight_controller/pixracer.html)
* [Pixhawk 3 Pro](https://docs.px4.io/master/en/flight_controller/pixhawk3_pro.html)
* FMUv5 (ARM Cortex M7)
* [Pixhawk 4](https://docs.px4.io/master/en/flight_controller/pixhawk4.html)
* [Pixhawk 4 mini](https://docs.px4.io/master/en/flight_controller/pixhawk4_mini.html)
* [CUAV V5+](https://docs.px4.io/master/en/flight_controller/cuav_v5_plus.html)
* [CUAV V5 nano](https://docs.px4.io/master/en/flight_controller/cuav_v5_nano.html)
* [Airmind MindPX V2.8](http://www.mindpx.net/assets/accessories/UserGuide_MindPX.pdf)
* [Airmind MindRacer V1.2](http://mindpx.net/assets/accessories/mindracer_user_guide_v1.2.pdf)
* [Bitcraze Crazyflie 2.0](https://docs.px4.io/en/flight_controller/crazyflie2.html)
* [Bitcraze Crazyflie 2.0](https://docs.px4.io/master/en/flight_controller/crazyflie2.html)
* [Omnibus F4 SD](https://docs.px4.io/master/en/flight_controller/omnibus_f4_sd.html)
* [Holybro Durandal](https://docs.px4.io/master/en/flight_controller/durandal.html)
* [Holybro Kakute F7](https://docs.px4.io/master/en/flight_controller/kakutef7.html)
* [Raspberry PI with Navio 2](https://docs.px4.io/master/en/flight_controller/raspberry_pi_navio2.html)
Additional information about supported hardware can be found in [PX4 user Guide > Autopilot Hardware](https://docs.px4.io/en/flight_controller/).
Additional information about supported hardware can be found in [PX4 user Guide > Autopilot Hardware](https://docs.px4.io/master/en/flight_controller/).
## Project Roadmap
+82 -31
View File
@@ -34,7 +34,7 @@
message(STATUS "ROMFS: ${config_romfs_root}")
set(romfs_src_dir ${PX4_SOURCE_DIR}/ROMFS/${config_romfs_root})
set(romfs_gen_root_dir ${PX4_BINARY_DIR}/genromfs)
set(romfs_gen_root_dir ${PX4_BINARY_DIR}/etc)
set_property(GLOBAL PROPERTY PX4_ROMFS_FILES)
set_property(GLOBAL PROPERTY PX4_ROMFS_CMAKE_FILES)
@@ -62,6 +62,9 @@ function(px4_add_romfs_files)
set_property(GLOBAL APPEND PROPERTY PX4_ROMFS_CMAKE_FILES ${CMAKE_CURRENT_LIST_FILE})
foreach(arg IN LISTS ARGN)
if(NOT EXISTS ${CMAKE_CURRENT_LIST_DIR}/${arg})
message(FATAL_ERROR "${CMAKE_CURRENT_LIST_DIR}/${arg} doesn't exist")
endif()
set_property(GLOBAL APPEND PROPERTY PX4_ROMFS_FILES ${CMAKE_CURRENT_LIST_DIR}/${arg})
endforeach()
endfunction()
@@ -78,20 +81,48 @@ file(GLOB jinja_templates ${PX4_SOURCE_DIR}/Tools/serial/*.jinja)
if (px4_constrained_flash_build)
set(added_arguments --constrained-flash)
endif()
# create list of relative romfs file names
set(romfs_copy_files_relative)
foreach(romfs_file IN LISTS romfs_copy_files)
string(REPLACE "${romfs_src_dir}/" "" romfs_file_rel ${romfs_file})
list(APPEND romfs_copy_files_relative ${romfs_file_rel})
endforeach()
# copy the ROMFS files by creating a tar and extracting it to the build
# directory (which preserves the directory structure)
file(MAKE_DIRECTORY ${romfs_gen_root_dir})
set(romfs_tar_file ${PX4_BINARY_DIR}/romfs_files.tar)
add_custom_command(
OUTPUT ${romfs_tar_file}
COMMAND ${CMAKE_COMMAND} -E tar cf ${romfs_tar_file} ${romfs_copy_files_relative}
WORKING_DIRECTORY ${romfs_src_dir}
DEPENDS
${romfs_copy_files}
${jinja_templates}
${module_config_files}
${romfs_cmake_files}
${PX4_SOURCE_DIR}/Tools/px_process_airframes.py
${PX4_SOURCE_DIR}/Tools/px4airframes/markdownout.py
${PX4_SOURCE_DIR}/Tools/px4airframes/rcout.py
${PX4_SOURCE_DIR}/Tools/px4airframes/srcparser.py
${PX4_SOURCE_DIR}/Tools/px4airframes/srcscanner.py
${PX4_SOURCE_DIR}/Tools/px4airframes/xmlout.py
${PX4_SOURCE_DIR}/Tools/serial/generate_config.py
)
set(romfs_extract_stamp ${CMAKE_CURRENT_BINARY_DIR}/romfs_extract.stamp)
add_custom_command(
OUTPUT ${romfs_extract_stamp}
COMMAND ${CMAKE_COMMAND} -E tar xf ${romfs_tar_file}
COMMAND ${CMAKE_COMMAND} -E touch ${romfs_extract_stamp}
WORKING_DIRECTORY ${romfs_gen_root_dir}
DEPENDS ${romfs_tar_file}
)
add_custom_command(
OUTPUT
${romfs_gen_root_dir}/init.d/rcS
${romfs_gen_root_dir}/init.d/rc.serial
${romfs_gen_root_dir}/init.d/rc.autostart
${romfs_gen_root_dir}/init.d/rc.autostart.post
romfs_copy.stamp
COMMAND ${CMAKE_COMMAND} -E remove_directory ${romfs_gen_root_dir}
# TODO: we should only copy the files in ${romfs_copy_files}
COMMAND ${CMAKE_COMMAND} -E copy_directory ${romfs_src_dir} ${romfs_gen_root_dir}
COMMAND ${CMAKE_COMMAND} -E remove_directory ${romfs_gen_root_dir}/init.d-posix
COMMAND ${CMAKE_COMMAND} -E remove_directory ${romfs_gen_root_dir}/mixers-sitl
COMMAND ${CMAKE_COMMAND} -E remove ${romfs_gen_root_dir}/mixers/CMakeLists.txt
COMMAND ${CMAKE_COMMAND} -E remove ${romfs_gen_root_dir}/init.d/CMakeLists.txt
COMMAND ${CMAKE_COMMAND} -E remove ${romfs_gen_root_dir}/init.d/airframes/CMakeLists.txt
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/px_process_airframes.py
--airframes-path ${romfs_gen_root_dir}/init.d
--start-script ${romfs_gen_root_dir}/init.d/rc.autostart
@@ -102,12 +133,7 @@ add_custom_command(
--config-files ${module_config_files} #--verbose
COMMAND ${CMAKE_COMMAND} -E touch romfs_copy.stamp
DEPENDS
${jinja_templates}
${module_config_files}
${romfs_cmake_files}
${romfs_copy_files}
${PX4_SOURCE_DIR}/Tools/px_process_airframes.py
${PX4_SOURCE_DIR}/Tools/serial/generate_config.py
${romfs_extract_stamp}
COMMENT "ROMFS: copying, generating airframes"
)
@@ -119,17 +145,14 @@ if(config_io_board)
list(APPEND extras_dependencies
copy_px4io_bin
${fw_io_bin}
)
)
endif()
if(config_bl_file)
file(MAKE_DIRECTORY ${PX4_BINARY_DIR}/romfs_extras)
configure_file(${config_bl_file} ${PX4_BINARY_DIR}/romfs_extras COPYONLY)
if(config_build_bootloader)
list(APPEND extras_dependencies
${config_bl_file}
)
copy_bootloader_bin
${bootloader_bin}
)
endif()
set(OPTIONAL_BOARD_RC)
@@ -137,6 +160,7 @@ list(APPEND OPTIONAL_BOARD_RC
rc.board_defaults
rc.board_sensors
rc.board_extras
rc.board_mavlink
)
foreach(board_rc_file ${OPTIONAL_BOARD_RC})
@@ -148,7 +172,7 @@ foreach(board_rc_file ${OPTIONAL_BOARD_RC})
OUTPUT
${romfs_gen_root_dir}/init.d/${board_rc_file}
${board_rc_file}.stamp
COMMAND ${CMAKE_COMMAND} -E copy ${PX4_BOARD_DIR}/init/${board_rc_file} ${romfs_gen_root_dir}/init.d/${board_rc_file}
COMMAND ${CMAKE_COMMAND} -E copy_if_different ${PX4_BOARD_DIR}/init/${board_rc_file} ${romfs_gen_root_dir}/init.d/${board_rc_file}
COMMAND ${CMAKE_COMMAND} -E touch ${board_rc_file}.stamp
DEPENDS
${PX4_BOARD_DIR}/init/${board_rc_file}
@@ -163,17 +187,35 @@ foreach(board_rc_file ${OPTIONAL_BOARD_RC})
endforeach()
list(APPEND extras_dependencies
${config_romfs_extra_dependencies}
)
if (config_romfs_extra_files)
set(extras_copy_cmd COMMAND ${CMAKE_COMMAND} -E copy_if_different ${config_romfs_extra_files} ${romfs_gen_root_dir}/extras/)
else()
set(extras_copy_cmd "")
endif()
add_custom_command(OUTPUT romfs_extras.stamp
COMMAND ${CMAKE_COMMAND} -E make_directory ${romfs_gen_root_dir}/extras/
COMMAND ${CMAKE_COMMAND} -E make_directory ${PX4_BINARY_DIR}/romfs_extras/
COMMAND ${CMAKE_COMMAND} -E copy_directory ${PX4_BINARY_DIR}/romfs_extras/ ${romfs_gen_root_dir}/extras/
${extras_copy_cmd}
COMMAND ${CMAKE_COMMAND} -E touch romfs_extras.stamp
DEPENDS
romfs_copy.stamp
${config_romfs_extra_files}
${extras_dependencies}
COMMENT "ROMFS: copying extras"
)
add_custom_target(romfs_gen_files_target
DEPENDS
${romfs_extract_stamp}
${romfs_gen_root_dir}/init.d/rc.serial
romfs_extras.stamp
)
add_custom_command(
OUTPUT romfs_pruned.stamp
COMMAND ${PYTHON_EXECUTABLE} ${PX4_SOURCE_DIR}/Tools/px_romfs_pruner.py --folder ${romfs_gen_root_dir} --board ${PX4_BOARD}
@@ -189,7 +231,7 @@ if("${CONFIG_FS_CROMFS}" STREQUAL "y")
add_custom_command(
OUTPUT ${CMAKE_BINARY_DIR}/gencromfs
COMMAND make --no-print-directory --silent -f Makefile.host gencromfs
COMMAND ${CMAKE_COMMAND} -E copy gencromfs ${CMAKE_BINARY_DIR}/gencromfs
COMMAND ${CMAKE_COMMAND} -E copy_if_different gencromfs ${CMAKE_BINARY_DIR}/gencromfs
DEPENDS ${PX4_SOURCE_DIR}/platforms/nuttx/NuttX/nuttx/tools/gencromfs.c
WORKING_DIRECTORY ${NUTTX_DIR}/tools
)
@@ -204,7 +246,11 @@ if("${CONFIG_FS_CROMFS}" STREQUAL "y")
COMMENT "ROMFS: generating image"
)
else()
add_library(romfs STATIC nsh_romfsimg.c)
add_dependencies(romfs prebuild_targets)
set_target_properties(romfs PROPERTIES LINKER_LANGUAGE C)
elseif("${CONFIG_FS_ROMFS}" STREQUAL "y")
# create romfs.img
find_program(GENROMFS genromfs)
if(NOT GENROMFS)
@@ -239,13 +285,13 @@ else()
COMMAND ${SED} 's/unsigned/const unsigned/g' nsh_romfsimg.c > nsh_romfsimg.c.tmp && ${CMAKE_COMMAND} -E rename nsh_romfsimg.c.tmp nsh_romfsimg.c
DEPENDS romfs.img
)
add_library(romfs STATIC nsh_romfsimg.c)
add_dependencies(romfs prebuild_targets)
set_target_properties(romfs PROPERTIES LINKER_LANGUAGE C)
endif()
add_library(romfs STATIC nsh_romfsimg.c)
add_dependencies(romfs prebuild_targets)
set_target_properties(romfs PROPERTIES LINKER_LANGUAGE C)
# shellcheck
find_program(SHELLCHECK_PATH shellcheck)
@@ -255,11 +301,16 @@ if(SHELLCHECK_PATH)
# TODO: fix SC2086, SC2166
add_custom_target(shellcheck
COMMAND ${SHELLCHECK_PATH} --shell=sh
--exclude=SC1090 # SC1090: use of source (.) - Can't follow non-constant source. Use a directive to specify location.
--exclude=SC1091 # SC1091: use of source (.) - Not following: xxxx openBinaryFile: does not exist (No such file or directory)
--exclude=SC2121 # SC2121: To assign a variable, use just 'var=value'
--exclude=SC2086 # SC2086: Double quote to prevent globbing and word splitting.
--exclude=SC2166 # SC2166: Prefer [ p ] || [ q ] as [ p -o q ] is not well defined.
--exclude=SC2154 # SC2154: <var> is referenced but not assigned (NuttX uses different asssignment)
--exclude=SC2164 # SC2164: Use 'cd ... || exit' or 'cd ... || return' in case cd fails.
--exclude=SC2169 # SC2169: In dash, 'source' in place of '.' is not supported. (we alias it)
--exclude=SC2039 # SC2039: In POSIX sh, 'source' in place of '.' is undefined. (we alias it)
--exclude=SC2181 # SC2181: Check exit code directly with e.g. 'if mycmd;', not indirectly with $?.
`find ${romfs_gen_root_dir}/init.d -type f`
DEPENDS ${romfs_gen_root_dir}/init.d/rc.autostart
WORKING_DIRECTORY ${romfs_gen_root_dir}
+34
View File
@@ -0,0 +1,34 @@
############################################################################
#
# Copyright (c) 2020 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
# are met:
#
# 1. Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in
# the documentation and/or other materials provided with the
# distribution.
# 3. Neither the name PX4 nor the names of its contributors may be
# used to endorse or promote products derived from this software
# without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
#
############################################################################
add_subdirectory(init.d)
+36
View File
@@ -0,0 +1,36 @@
############################################################################
#
# Copyright (c) 2020 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
# are met:
#
# 1. Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in
# the documentation and/or other materials provided with the
# distribution.
# 3. Neither the name PX4 nor the names of its contributors may be
# used to endorse or promote products derived from this software
# without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
#
############################################################################
px4_add_romfs_files(
rcS
)
+107
View File
@@ -0,0 +1,107 @@
#!/bin/sh
# Un comment and use set +e to ignore and set -e to enable 'exit on error control'
set +e
# Un comment the line below to help debug scripts by printing a trace of the script commands
#set -x
# PX4FMU startup script.
#
# NOTE: environment variable references:
# If the dollar sign ('$') is followed by a left bracket ('{') then the
# variable name is terminated with the right bracket character ('}').
# Otherwise, the variable name goes to the end of the argument.
#
#
# NOTE: COMMENT LINES ARE REMOVED BEFORE STORED IN ROMFS.
#
#------------------------------------------------------------------------------
set R /
#
# Mount the procfs.
#
mount -t procfs /proc
#
# Start CDC/ACM serial driver.
#
sercon
#
# Print full system version.
#
ver all
#
# Start the ORB (first app to start)
# tone_alarm and tune_control
# is dependent.
#
uorb start
#
# Set the parameter file if mtd starts successfully.
#
if mtd start
then
set PARAM_FILE /fs/mtd_params
fi
#
# Load parameters.
#
param select $PARAM_FILE
if ! param load
then
param reset_all
fi
#
# Optional board defaults: rc.board_defaults
#
set BOARD_RC_DEFAULTS ${R}etc/init.d/rc.board_defaults
if [ -f $BOARD_RC_DEFAULTS ]
then
echo "Board defaults: ${BOARD_RC_DEFAULTS}"
. $BOARD_RC_DEFAULTS
fi
unset BOARD_RC_DEFAULTS
#
# Start system state indicator.
#
rgbled start -X -q
rgbled_ncp5623c start -X -q
rgbled_pwm start
if param greater LIGHT_EN_BLINKM 0
then
if blinkm start -X
then
blinkm systemstate
fi
fi
#
# board sensors: rc.sensors
#
set BOARD_RC_SENSORS ${R}etc/init.d/rc.board_sensors
if [ -f $BOARD_RC_SENSORS ]
then
echo "Board sensors: ${BOARD_RC_SENSORS}"
. $BOARD_RC_SENSORS
fi
unset BOARD_RC_SENSORS
#
# Start UART/Serial device drivers.
# Note: rc.serial is auto-generated from Tools/serial/generate_config.py
#
. ${R}etc/init.d/rc.serial
# Check for flow sensor
if param compare SENS_EN_PX4FLOW 1
then
px4flow start -X
fi
uavcannode start
unset R
+5
View File
@@ -33,3 +33,8 @@
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()
@@ -1,12 +0,0 @@
#!/bin/sh
#
# @name IF750A SITL
# InspiredFlight 750 Auterion edition. Gazebo Only.
#
# @type Quadrotor
#
sh /etc/init.d/rc.mc_defaults
set MIXER quad_x
@@ -1,29 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Optical Flow)
#
# @type Quadrotor Wide
#
sh /etc/init.d-posix/10016_iris
if [ $AUTOCNF = yes ]
then
# EKF2
param set EKF2_AID_MASK 2
param set EKF2_EVP_NOISE 0.05
param set EKF2_EVA_NOISE 0.05
# INAV
param set INAV_LIDAR_EST 1
param set INAV_W_XY_FLOW 1
param set INAV_W_XY_GPS_P 0
param set INAV_W_XY_GPS_V 0
param set INAV_W_Z_GPS_P 0
# LPE: Flow-only mode
param set LPE_FUSION 242
param set LPE_FAKE_ORIGIN 1
param set MPC_ALT_MODE 2
fi
@@ -1,28 +0,0 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Vision)
#
# @type Quadrotor Wide
#
sh /etc/init.d-posix/10016_iris
if [ $AUTOCNF = yes ]
then
# EKF2: Vision position and heading
param set EKF2_AID_MASK 24
param set EKF2_EV_DELAY 5
# INAV: trust more on the vision input
param set INAV_W_XY_VIS_P 9
param set INAV_W_Z_VIS_P 7
param set INAV_W_XY_GPS_P 0
param set INAV_W_XY_GPS_V 0
param set INAV_W_Z_GPS_P 0
# LPE: Vision + baro
param set LPE_FUSION 132
# AEQ: External heading set to use vision input
param set ATT_EXT_HDG_M 1
fi
@@ -1,16 +0,0 @@
#!/bin/sh
#
# @name Solo
#
# @type Quadrotor
#
sh /etc/init.d/rc.mc_defaults
if [ $AUTOCNF = yes ]
then
param set MC_PITCHRATE_P 0.15
param set MC_ROLLRATE_P 0.15
fi
set MIXER quad_x
@@ -1,8 +0,0 @@
#!/bin/sh
#
# @name Hippocampus UUV
#
sh /etc/init.d/rc.mc_defaults
set MIXER uuv_quad_x
@@ -1,6 +0,0 @@
#!/bin/sh
#
# @name Plane SITL with camera
#
sh /etc/init.d-posix/1030_plane
@@ -1,50 +0,0 @@
#!/bin/sh
#
# @name Standard VTOL
#
# @type Standard VTOL
#
sh /etc/init.d/rc.vtol_defaults
if [ $AUTOCNF = yes ]
then
param set FW_AIRSPD_MAX 25
param set FW_AIRSPD_MIN 14
param set FW_AIRSPD_TRIM 16
param set MC_ROLLRATE_P 0.3
param set MIS_LTRMIN_ALT 10
param set MIS_TAKEOFF_ALT 10
param set MIS_YAW_TMT 10
param set MPC_ACC_HOR_MAX 2
param set MPC_ACC_HOR_MAX 2
param set MPC_THR_MIN 0.1
param set MPC_TKO_SPEED 1
param set MPC_XY_P 0.8
param set MPC_XY_VEL_D 0.005
param set MPC_XY_VEL_I 0.2
param set MPC_XY_VEL_P 0.15
param set MPC_Z_VEL_MAX_DN 1.5
param set NAV_ACC_RAD 5
param set NAV_LOITER_RAD 80
param set VT_F_TRANS_DUR 5
param set VT_F_TRANS_THR 0.75
param set VT_ARSP_TRANS 16
param set VT_MOT_COUNT 4
param set VT_TYPE 2
param set WEST_EN 1
# Indicate that FW roll direction was fixed in mixer, to be removed in v1.10
param set V19_VT_ROLLDIR 0
fi
set MAV_TYPE 22
set MIXER_FILE etc/mixers-sitl/standard_vtol_sitl.main.mix
set MIXER custom
@@ -1,50 +0,0 @@
#!/bin/sh
#
# @name Quadrotor + Tailsitter
#
# @type VTOL Quad Tailsitter
#
sh /etc/init.d/rc.vtol_defaults
if [ $AUTOCNF = yes ]
then
param set FW_AIRSPD_MAX 25
param set FW_AIRSPD_MIN 14
param set FW_AIRSPD_TRIM 16
param set MC_ROLLRATE_P 0.3
param set MIS_LTRMIN_ALT 10
param set MIS_TAKEOFF_ALT 10
param set MIS_YAW_TMT 10
param set MPC_ACC_HOR_MAX 2
param set MPC_ACC_HOR_MAX 2
param set MPC_THR_MIN 0.1
param set MPC_TKO_SPEED 1
param set MPC_XY_P 0.15
param set MPC_XY_VEL_D 0.005
param set MPC_XY_VEL_I 0.2
param set MPC_XY_VEL_P 0.05
param set MPC_Z_VEL_MAX_DN 1.5
param set MPC_Z_VEL_P 0.8
param set NAV_ACC_RAD 5
param set NAV_LOITER_RAD 80
param set VT_F_TRANS_DUR 1.5
param set VT_F_TRANS_THR 0.7
param set VT_MOT_COUNT 0
param set VT_TYPE 0
param set WEST_EN 1
# Indicate that FW roll direction was fixed in mixer, to be removed in v1.10
param set V19_VT_ROLLDIR 0
fi
set MAV_TYPE 20
set MIXER_FILE etc/mixers-sitl/quad_x_vtol.main.mix
set MIXER custom
@@ -1,53 +0,0 @@
#!/bin/sh
#
# @name VTOL Tiltrotor
#
# @type VTOL Tiltrotor
#
sh /etc/init.d/rc.vtol_defaults
if [ $AUTOCNF = yes ]
then
param set FW_AIRSPD_MAX 25
param set FW_AIRSPD_MIN 14
param set FW_AIRSPD_TRIM 16
param set MC_ROLLRATE_P 0.3
param set MIS_LTRMIN_ALT 10
param set MIS_TAKEOFF_ALT 10
param set MIS_YAW_TMT 10
param set MPC_ACC_HOR_MAX 2
param set MPC_ACC_HOR_MAX 2
param set MPC_THR_MIN 0.1
param set MPC_TKO_SPEED 1
param set MPC_XY_P 0.15
param set MPC_XY_VEL_D 0.005
param set MPC_XY_VEL_I 0.2
param set MPC_XY_VEL_P 0.05
param set MPC_Z_VEL_MAX_DN 1.5
param set MPC_Z_VEL_P 0.8
param set NAV_ACC_RAD 5
param set NAV_LOITER_RAD 80
param set VT_F_TRANS_DUR 1.5
param set VT_F_TRANS_THR 0.75
param set VT_MOT_COUNT 4
param set VT_TILT_FW 3.1415
param set VT_TILT_TRANS 1.2
param set VT_ELEV_MC_LOCK 0
param set VT_TYPE 1
param set WEST_EN 1
# Indicate that FW roll direction was fixed in mixer, to be removed in v1.10
param set V19_VT_ROLLDIR 0
fi
set MAV_TYPE 21
set MIXER_FILE etc/mixers-sitl/tiltrotor_sitl.main.mix
set MIXER custom
@@ -1,37 +0,0 @@
#!/bin/sh
#
# @name Rover
#
sh /etc/init.d/rc.ugv_defaults
if [ $AUTOCNF = yes ]
then
param set GND_L1_DIST 5
param set GND_SP_CTRL_MODE 1
param set GND_SPEED_D 3
param set GND_SPEED_I 0.001
param set GND_SPEED_IMAX 0.125
param set GND_SPEED_P 0.25
param set GND_SPEED_THR_SC 1
param set GND_SPEED_TRIM 4
param set GND_THR_CRUISE 0.3
param set GND_THR_IDLE 0
param set GND_THR_MAX 0.5
param set GND_THR_MIN 0
param set GND_WR_D 1.2
param set GND_WR_I 0.9674
param set GND_WR_IMAX 0.1
param set GND_WR_P 2
param set MIS_LTRMIN_ALT 0.01
param set MIS_TAKEOFF_ALT 0.01
param set NAV_ACC_RAD 0.5
param set NAV_LOITER_RAD 2
param set CBRK_AIRSPD_CHK 162128
fi
set MAV_TYPE 10
set MIXER_FILE etc/mixers-sitl/rover_sitl.main.mix
@@ -1,28 +0,0 @@
#!/bin/sh
#
# @name Typhoon H480 SITL
#
# @type Hexarotor x
#
sh /etc/init.d/rc.mc_defaults
if [ $AUTOCNF = yes ]
then
param set MC_PITCHRATE_P 0.1
param set MC_ROLLRATE_P 0.05
param set MPC_XY_VEL_I 0.2
param set MPC_XY_VEL_P 0.15
param set RTL_DESCEND_ALT 10
param set RTL_LAND_DELAY 0
param set TRIG_INTERFACE 3
param set TRIG_MODE 4
param set MNT_MODE_IN 0
param set MAV_PROTO_VER 2
fi
set MAV_TYPE 13
set MIXER hexa_x
@@ -0,0 +1,39 @@
############################################################################
#
# Copyright (c) 2020 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
# are met:
#
# 1. Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright
# notice, this list of conditions and the following disclaimer in
# the documentation and/or other materials provided with the
# distribution.
# 3. Neither the name PX4 nor the names of its contributors may be
# used to endorse or promote products derived from this software
# without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
#
############################################################################
add_subdirectory(airframes)
px4_add_romfs_files(
rc.replay
rcS
)
@@ -7,7 +7,6 @@
# @maintainer Julian Oes <julian@oes.ch>
#
sh /etc/init.d/rc.mc_defaults
. ${R}etc/init.d/rc.mc_defaults
set MIXER quad_w
@@ -0,0 +1,17 @@
#!/bin/sh
#
# @name IF750A SITL
# InspiredFlight 750 Auterion edition. Gazebo Only.
#
# @type Quadrotor
#
. ${R}etc/init.d/rc.mc_defaults
if [ $AUTOCNF = yes ]
then
# EKF2: Multi GPS blending (as the model has 2 GPS's)
param set EKF2_GPS_MASK 7 # Uses speed, hpos and vpos accuracy
fi
set MIXER quad_x
@@ -0,0 +1,11 @@
#!/bin/sh
#
# @name PX4Vision SITL
# Holybro px4vision. Gazebo Only.
#
# @type Quadrotor
#
. ${R}etc/init.d/airframes/4016_holybro_px4vision
set MIXER quad_x
@@ -0,0 +1,22 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Optical Flow)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
if [ $AUTOCNF = yes ]
then
# EKF2
param set EKF2_AID_MASK 2
param set EKF2_EVP_NOISE 0.05
param set EKF2_EVA_NOISE 0.05
# LPE: Flow-only mode
param set LPE_FUSION 242
param set LPE_FAKE_ORIGIN 1
param set MPC_ALT_MODE 2
fi
@@ -5,7 +5,7 @@
# @type Quadrotor Wide
#
sh /etc/init.d-posix/10016_iris
. ${R}etc/init.d-posix/airframes/10016_iris
if [ $AUTOCNF = yes ]
then
@@ -5,7 +5,7 @@
# @type Quadrotor Wide
#
sh /etc/init.d-posix/10016_iris
. ${R}etc/init.d-posix/airframes/10016_iris
if [ $AUTOCNF = yes ]
then
@@ -0,0 +1,21 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Vision)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
if [ $AUTOCNF = yes ]
then
# EKF2: Vision position and heading
param set EKF2_AID_MASK 24
param set EKF2_EV_DELAY 5
# LPE: Vision + baro
param set LPE_FUSION 132
# AEQ: External heading set to use vision input
param set ATT_EXT_HDG_M 1
fi
@@ -0,0 +1,16 @@
#!/bin/sh
#
# @name Solo
#
# @type Quadrotor
#
. ${R}etc/init.d/rc.mc_defaults
if [ $AUTOCNF = yes ]
then
param set MC_PITCHRATE_P 0.1
param set MC_ROLLRATE_P 0.1
fi
set MIXER quad_x
@@ -5,7 +5,7 @@
# @type Quadrotor Wide
#
sh /etc/init.d-posix/10016_iris
. ${R}etc/init.d-posix/airframes/10016_iris
if [ $AUTOCNF = yes ]
then
@@ -0,0 +1,8 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (RTPS)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
@@ -0,0 +1,4 @@
#!/bin/sh
# shellcheck disable=SC2154
micrortps_client start -t UDP -r $((2019+2*px4_instance)) -s $((2020+2*px4_instance))
@@ -0,0 +1,21 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Optical Flow)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
if [ $AUTOCNF = yes ]
then
# EKF2
param set EKF2_AID_MASK 2
param set SENS_FLOW_ROT 0
# LPE: Flow-only mode
param set LPE_FUSION 242
param set LPE_FAKE_ORIGIN 1
param set MPC_ALT_MODE 2
fi
@@ -0,0 +1,15 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Vision Velocity)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
if [ $AUTOCNF = yes ]
then
# EKF2: Vision velocity and heading
param set EKF2_AID_MASK 272
param set EKF2_EV_DELAY 5
fi
@@ -0,0 +1,14 @@
#!/bin/sh
#
# @name 3DR Iris Quadrotor SITL (Dual GPS)
#
# @type Quadrotor Wide
#
. ${R}etc/init.d-posix/airframes/10016_iris
if [ $AUTOCNF = yes ]
then
# EKF2: Multi GPS blending
param set EKF2_GPS_MASK 7 # Uses speed, hpos and vpos accuracy
fi
@@ -0,0 +1,23 @@
#!/bin/sh
#
# @name UUV
#
. ${R}etc/init.d/rc.uuv_defaults
if [ $AUTOCNF = yes ]
then
#Set data link loss failsafe mode (0: disabled)
param set NAV_DLL_ACT 0
# disable circuit breaker for airspeed sensor
param set CBRK_AIRSPD_CHK 162128
#param set CBRK_GPSFAIL 240024
fi
set MAV_TYPE 12
param set MAV_TYPE ${MAV_TYPE}
set MIXER_FILE etc/mixers-sitl/uuv_x_sitl.main.mix
set MIXER custom
@@ -0,0 +1,23 @@
#!/bin/sh
#
# @name Hippocampus UUV
#
. ${R}etc/init.d/rc.uuv_defaults
if [ $AUTOCNF = yes ]
then
#Set data link loss failsafe mode (0: disabled)
param set NAV_DLL_ACT 0
# disable circuit breaker for airspeed sensor
param set CBRK_AIRSPD_CHK 162128
#param set CBRK_GPSFAIL 240024
fi
set MAV_TYPE 12
param set MAV_TYPE ${MAV_TYPE}
set MIXER_FILE etc/mixers-sitl/uuv_x_sitl.main.mix
set MIXER custom
@@ -0,0 +1,20 @@
#!/bin/sh
#
# @name BlueROV2 Heavy Configuration
#
. ${R}etc/init.d/rc.uuv_defaults
if [ $AUTOCNF = yes ]
then
#Set data link loss failsafe mode (0: disabled)
param set NAV_DLL_ACT 0
# disable circuit breaker for airspeed sensor
param set CBRK_AIRSPD_CHK 162128
fi
set PWM_OUT 12345678
set MIXER_FILE etc/mixers-sitl/vectored6dof_sitl.main.mix
set MIXER custom
@@ -3,7 +3,7 @@
# @name Plane SITL
#
sh /etc/init.d/rc.fw_defaults
. ${R}etc/init.d/rc.fw_defaults
if [ $AUTOCNF = yes ]
then
@@ -16,6 +16,8 @@ then
param set FW_LND_ANG 8
param set FW_THR_LND_MAX 0
param set FW_L1_PERIOD 15
param set FW_P_TC 0.5
param set FW_PR_FF 0.40
param set FW_PR_I 0.05
@@ -26,6 +28,8 @@ then
param set FW_RR_I 0.02
param set FW_RR_P 0.22
param set FW_L1_PERIOD 12
param set FW_W_EN 1
param set MIS_LTRMIN_ALT 30
@@ -37,7 +41,6 @@ then
param set RWTO_TKOFF 1
param set WEST_EN 1
fi
set MIXER_FILE etc/mixers-sitl/plane_sitl.main.mix
@@ -0,0 +1,14 @@
#!/bin/sh
#
# @name Plane SITL with camera
#
. ${R}etc/init.d-posix/airframes/1030_plane
if [ $AUTOCNF = yes ]
then
# Camera trigger interface is MAVLink
param set TRIG_INTERFACE 3
# Distance trigger mode enabled
param set TRIG_MODE 4
fi
@@ -0,0 +1,12 @@
#!/bin/sh
#
# @name Plane SITL with catapult
#
. ${R}etc/init.d-posix/airframes/1030_plane
if [ $AUTOCNF = yes ]
then
param set RWTO_TKOFF 0
fi
@@ -0,0 +1,12 @@
#!/bin/sh
#
# @name Plane SITL with downward facing LIDAR.
#
. ${R}etc/init.d-posix/airframes/1030_plane
if [ $AUTOCNF = yes ]
then
param set FW_LND_USETER 1
fi
@@ -0,0 +1,58 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
if [ $AUTOCNF = yes ]
then
param set EKF2_ARSP_THR 8
param set EKF2_FUSE_BETA 1
#param set EKF2_MAG_ACCLIM 0
#param set EKF2_MAG_YAWLIM 0
param set FW_LND_AIRSPD_SC 1.1
param set FW_LND_ANG 5
param set FW_THR_LND_MAX 0
param set FW_LND_HHDIST 30
param set FW_LND_FL_PMIN 9.5
param set FW_LND_FL_PMAX 20
param set FW_LND_FLALT 5
param set FW_LND_TLALT 15
param set FW_L1_PERIOD 25
param set FW_P_TC 0.4
param set FW_PR_FF 0.40
param set FW_PR_I 0.05
param set FW_PR_P 0.05
param set FW_R_TC 0.45
param set FW_RR_FF 0.40
param set FW_RR_I 0.132
param set FW_RR_P 0.085
param set FW_W_EN 1
param set MIS_LTRMIN_ALT 30
param set MIS_TAKEOFF_ALT 20
param set MIS_DIST_1WP 2500
param set MIS_DIST_WPS 10000
param set NAV_ACC_RAD 15
param set NAV_DLL_ACT 2
param set NAV_LOITER_RAD 50
param set RWTO_TKOFF 1
#param set FW_THR_SLEW_MAX 0.3 # fix takeoff failure for JSBsim in autonomous mission mode.
param set RWTO_MAX_PITCH 20
param set RWTO_MAX_ROLL 10
#param set RWTO_MAX_THR 0.6 # fix takeoff failure for JSBsim in autonomous mission mode.
param set RWTO_PSP 8
param set RWTO_AIRSPD_SCL 1.8
fi
set MIXER_FILE etc/mixers-sitl/plane_sitl.main.mix
set MIXER custom
@@ -0,0 +1,58 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
if [ $AUTOCNF = yes ]
then
param set EKF2_ARSP_THR 8
param set EKF2_FUSE_BETA 1
#param set EKF2_MAG_ACCLIM 0
#param set EKF2_MAG_YAWLIM 0
param set FW_LND_AIRSPD_SC 1.1
param set FW_LND_ANG 5
param set FW_THR_LND_MAX 0
param set FW_LND_HHDIST 30
param set FW_LND_FL_PMIN 9.5
param set FW_LND_FL_PMAX 20
param set FW_LND_FLALT 5
param set FW_LND_TLALT 15
param set FW_L1_PERIOD 25
param set FW_P_TC 0.4
param set FW_PR_FF 0.40
param set FW_PR_I 0.05
param set FW_PR_P 0.05
param set FW_R_TC 0.45
param set FW_RR_FF 0.40
param set FW_RR_I 0.132
param set FW_RR_P 0.085
param set FW_W_EN 1
param set MIS_LTRMIN_ALT 30
param set MIS_TAKEOFF_ALT 20
param set MIS_DIST_1WP 2500
param set MIS_DIST_WPS 10000
param set NAV_ACC_RAD 15
param set NAV_DLL_ACT 2
param set NAV_LOITER_RAD 50
param set RWTO_TKOFF 1
#param set FW_THR_SLEW_MAX 0.3 # fix takeoff failure for JSBsim in autonomous mission mode.
param set RWTO_MAX_PITCH 20
param set RWTO_MAX_ROLL 10
#param set RWTO_MAX_THR 0.6 # fix takeoff failure for JSBsim in autonomous mission mode.
param set RWTO_PSP 8
param set RWTO_AIRSPD_SCL 1.8
fi
set MIXER_FILE etc/mixers-sitl/plane_sitl.main.mix
set MIXER custom
@@ -0,0 +1,47 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
if [ $AUTOCNF = yes ]
then
param set EKF2_ARSP_THR 8
param set EKF2_FUSE_BETA 1
param set EKF2_MAG_ACCLIM 0
param set EKF2_MAG_YAWLIM 0
param set FW_LND_AIRSPD_SC 1
param set FW_LND_ANG 8
param set FW_THR_LND_MAX 0
param set FW_L1_PERIOD 15
param set FW_P_TC 0.5
param set FW_PR_FF 0.40
param set FW_PR_I 0.05
param set FW_PR_P 0.05
param set FW_R_TC 0.7
param set FW_RR_FF 0.20
param set FW_RR_I 0.02
param set FW_RR_P 0.22
param set FW_L1_PERIOD 12
param set FW_W_EN 1
param set MIS_LTRMIN_ALT 30
param set MIS_TAKEOFF_ALT 30
param set NAV_ACC_RAD 15
param set NAV_DLL_ACT 2
param set NAV_LOITER_RAD 50
param set RWTO_TKOFF 1
fi
set MIXER_FILE etc/mixers-sitl/plane_sitl.main.mix
set MIXER custom
@@ -0,0 +1,56 @@
#!/bin/sh
#
# @name Plane SITL
#
. ${R}etc/init.d/rc.fw_defaults
if [ $AUTOCNF = yes ]
then
param set EKF2_ARSP_THR 8
param set EKF2_FUSE_BETA 1
#param set EKF2_MAG_ACCLIM 0
#param set EKF2_MAG_YAWLIM 0
param set FW_LND_AIRSPD_SC 1.1
param set FW_LND_ANG 5
param set FW_THR_LND_MAX 0
param set FW_LND_HHDIST 30
param set FW_LND_FL_PMIN 9.5
param set FW_LND_FL_PMAX 20
param set FW_LND_FLALT 5
param set FW_LND_TLALT 15
param set FW_L1_PERIOD 25
param set FW_P_TC 0.4
param set FW_PR_FF 0.40
param set FW_PR_I 0.05
param set FW_PR_P 0.05
param set FW_R_TC 0.45
param set FW_RR_FF 0.40
param set FW_RR_I 0.132
param set FW_RR_P 0.085
param set FW_W_EN 1
param set MIS_LTRMIN_ALT 30
param set MIS_TAKEOFF_ALT 20
param set MIS_DIST_1WP 2500
param set MIS_DIST_WPS 10000
param set NAV_ACC_RAD 15
param set NAV_DLL_ACT 2
param set NAV_LOITER_RAD 50
param set RWTO_TKOFF 1
param set RWTO_MAX_PITCH 20
param set RWTO_MAX_ROLL 10
param set RWTO_PSP 8
param set RWTO_AIRSPD_SCL 1.8
fi
set MIXER_FILE etc/mixers-sitl/plane_sitl.main.mix
set MIXER custom
@@ -0,0 +1,52 @@
#!/bin/sh
#
# @name Standard VTOL
#
# @type Standard VTOL
#
. ${R}etc/init.d/rc.vtol_defaults
if [ $AUTOCNF = yes ]
then
param set FW_AIRSPD_MAX 25
param set FW_AIRSPD_MIN 14
param set FW_AIRSPD_TRIM 16
param set FW_L1_PERIOD 12
param set FW_RR_FF 0.1
param set FW_RR_P 0.01
param set MC_ROLLRATE_P 0.3
param set MIS_LTRMIN_ALT 10
param set MIS_TAKEOFF_ALT 10
param set MIS_YAW_TMT 10
param set MPC_ACC_HOR_MAX 2
param set MPC_ACC_HOR_MAX 2
param set MPC_THR_HOVER 0.58
param set MPC_TKO_SPEED 1
param set MPC_XY_P 0.8
param set MPC_XY_VEL_P_ACC 3
param set MPC_XY_VEL_I_ACC 4
param set MPC_XY_VEL_D_ACC 0.1
param set MPC_Z_VEL_MAX_DN 1.5
param set NAV_ACC_RAD 5
param set NAV_LOITER_RAD 80
param set VT_F_TRANS_DUR 5
param set VT_F_TRANS_THR 0.75
param set VT_ARSP_TRANS 16
param set VT_MOT_ID 1234
param set VT_FW_MOT_OFFID 1234
param set VT_TYPE 2
param set VT_B_TRANS_DUR 8
fi
set MAV_TYPE 22
set MIXER_FILE etc/mixers-sitl/standard_vtol_sitl.main.mix
set MIXER custom
@@ -0,0 +1,44 @@
#!/bin/sh
#
# @name Quadrotor + Tailsitter
#
# @type VTOL Quad Tailsitter
#
. ${R}etc/init.d/rc.vtol_defaults
if [ $AUTOCNF = yes ]
then
param set FW_AIRSPD_MAX 25
param set FW_AIRSPD_MIN 14
param set FW_AIRSPD_TRIM 16
param set FW_L1_PERIOD 12
param set MC_ROLLRATE_P 0.3
param set MIS_YAW_TMT 10
param set MPC_ACC_HOR_MAX 2
param set MPC_ACC_HOR_MAX 2
param set MPC_THR_MIN 0.3
param set MPC_XY_P 0.15
param set MPC_XY_VEL_D_ACC 0.1
param set MPC_XY_VEL_P_ACC 1
param set MPC_Z_VEL_MAX_DN 1.5
param set MPC_Z_VEL_P_ACC 16
param set NAV_ACC_RAD 5
param set NAV_LOITER_RAD 80
param set VT_F_TRANS_DUR 1.5
param set VT_F_TRANS_THR 0.7
param set VT_TYPE 0
param set WV_EN 0
fi
set MAV_TYPE 20
set MIXER_FILE etc/mixers-sitl/quad_x_vtol.main.mix
set MIXER custom
@@ -0,0 +1,52 @@
#!/bin/sh
#
# @name VTOL Tiltrotor
#
# @type VTOL Tiltrotor
#
. ${R}etc/init.d/rc.vtol_defaults
if [ $AUTOCNF = yes ]
then
param set FW_ARSP_MODE 1
param set FW_AIRSPD_MAX 25
param set FW_AIRSPD_MIN 14
param set FW_AIRSPD_TRIM 16
param set FW_L1_PERIOD 12
param set MC_ROLLRATE_P 0.3
param set MIS_LTRMIN_ALT 10
param set MIS_TAKEOFF_ALT 10
param set MIS_YAW_TMT 10
param set MPC_ACC_HOR_MAX 2
param set MPC_ACC_HOR_MAX 2
param set MPC_THR_MIN 0.1
param set MPC_TKO_SPEED 1
param set MPC_XY_P 0.15
param set MPC_XY_VEL_D_ACC 0.1
param set MPC_XY_VEL_I_ACC 4
param set MPC_XY_VEL_P_ACC 1
param set MPC_Z_VEL_MAX_DN 1.5
param set MPC_Z_VEL_P_ACC 16
param set NAV_ACC_RAD 5
param set NAV_LOITER_RAD 80
param set VT_F_TRANS_DUR 5.0
param set VT_F_TRANS_THR 0.75
param set VT_FWD_THRUST_SC 1.1
param set VT_TILT_FW 1
param set VT_TILT_TRANS 0.6
param set VT_ELEV_MC_LOCK 0
param set VT_TYPE 1
param set VT_B_TRANS_DUR 8
fi
set MAV_TYPE 21
set MIXER_FILE etc/mixers-sitl/tiltrotor_sitl.main.mix
set MIXER custom
@@ -0,0 +1,37 @@
#!/bin/sh
#
# @name Rover
#
. ${R}etc/init.d/rc.rover_defaults
if [ $AUTOCNF = yes ]
then
param set GND_L1_DIST 5
param set GND_SP_CTRL_MODE 1
param set GND_SPEED_D 0.001
param set GND_SPEED_I 3
param set GND_SPEED_IMAX 0.125
param set GND_SPEED_P 0.25
param set GND_SPEED_THR_SC 1
param set GND_SPEED_TRIM 4
param set GND_THR_CRUISE 0.3
param set GND_THR_IDLE 0
param set GND_THR_MAX 0.5
param set GND_THR_MIN 0
param set MIS_LTRMIN_ALT 0.01
param set MIS_TAKEOFF_ALT 0.01
param set NAV_ACC_RAD 0.5
param set NAV_LOITER_RAD 2
param set CBRK_AIRSPD_CHK 162128
param set GND_MAX_ANG 0.6
param set GND_WHEEL_BASE 2.0
fi
set MAV_TYPE 10
set MIXER_FILE etc/mixers-sitl/rover_ackermann_sitl.main.mix
@@ -0,0 +1,38 @@
#!/bin/sh
#
# @name Aion Robotics R1 Rover
# @type Rover
# @class Rover
. ${R}etc/init.d/rc.rover_defaults
if [ $AUTOCNF = yes ]
then
param set GND_L1_DIST 5
param set GND_SP_CTRL_MODE 1
param set GND_SPEED_D 3
param set GND_SPEED_I 0.001
param set GND_SPEED_IMAX 0.125
param set GND_SPEED_P 0.25
param set GND_SPEED_THR_SC 1
param set GND_SPEED_TRIM 4
param set GND_THR_CRUISE 0.3
param set GND_THR_IDLE 0
param set GND_THR_MAX 0.5
param set GND_THR_MIN 0
param set MIS_LTRMIN_ALT 0.01
param set MIS_TAKEOFF_ALT 0.01
param set NAV_ACC_RAD 0.5
param set NAV_LOITER_RAD 2
param set CBRK_AIRSPD_CHK 162128
param set GND_MAX_ANG 0.6
param set GND_WHEEL_BASE 2.0
fi
set MAV_TYPE 10
set MIXER_FILE etc/mixers-sitl/rover_diff_sitl.main.mix
@@ -0,0 +1,43 @@
#!/bin/sh
#
# @name ThunderFly TF-R1 UAV Rover
# @type Rover
# @class Rover
#
# @url https://github.com/ThunderFly-aerospace/TF-R1/
# @maintainer ThunderFly s.r.o.
#
. ${R}etc/init.d/rc.rover_defaults
if [ $AUTOCNF = yes ]
then
param set GND_L1_DIST 5
param set GND_SP_CTRL_MODE 1
param set GND_SPEED_D 3
param set GND_SPEED_I 0.001
param set GND_SPEED_IMAX 0.125
param set GND_SPEED_P 0.25
param set GND_SPEED_THR_SC 1
param set GND_SPEED_TRIM 15
param set GND_SPEED_MAX 25
param set GND_THR_CRUISE 0.3
param set GND_THR_IDLE 0
param set GND_THR_MAX 0.5
param set GND_THR_MIN 0
param set MIS_LTRMIN_ALT 0.01
param set MIS_TAKEOFF_ALT 0.01
param set NAV_ACC_RAD 0.5
param set NAV_LOITER_RAD 2
param set CBRK_AIRSPD_CHK 162128
param set GND_MAX_ANG 0.6
param set GND_WHEEL_BASE 3.0
fi
set MAV_TYPE 10
set MIXER_FILE etc/mixers-sitl/rover_ackermann_sitl.main.mix
@@ -0,0 +1,37 @@
#!/bin/sh
#
# @name Boat
#
. ${R}etc/init.d/rc.boat_defaults
if [ $AUTOCNF = yes ]
then
param set GND_L1_DIST 5
param set GND_SP_CTRL_MODE 1
param set GND_SPEED_D 0.001
param set GND_SPEED_I 3
param set GND_SPEED_IMAX 0.125
param set GND_SPEED_P 0.25
param set GND_SPEED_THR_SC 1
param set GND_SPEED_TRIM 4
param set GND_THR_CRUISE 0.3
param set GND_THR_IDLE 0
param set GND_THR_MAX 0.5
param set GND_THR_MIN 0
param set MIS_LTRMIN_ALT 0.01
param set MIS_TAKEOFF_ALT 0.01
param set NAV_ACC_RAD 0.5
param set NAV_LOITER_RAD 2
param set CBRK_AIRSPD_CHK 162128
param set GND_MAX_ANG 0.6
param set GND_WHEEL_BASE 2.0
fi
set MAV_TYPE 11
set MIXER_FILE etc/mixers-sitl/boat_sitl.main.mix
@@ -0,0 +1,64 @@
#!/bin/sh
#
# @name ThunderFly TF-G1
# ThunderFly TF-G1 autogyro airframe. Only for FlightGear simulator
#
# @type Autogyro
# @class Autogyro
#
# @url https://github.com/ThunderFly-aerospace/TF-G1/
#
#
. ${R}etc/init.d/rc.fw_defaults
if [ $AUTOCNF = yes ]
then
param set EKF2_ARSP_THR 8
param set EKF2_FUSE_BETA 1
param set ASPD_STALL 10.0
param set FW_P_RMAX_NEG 20.0
param set FW_P_RMAX_POS 60.0
param set FW_W_RMAX 10
param set FW_W_EN 1
param set FW_PR_IMAX 0.4
param set FW_R_TC 0.4
param set FW_RR_FF 0.5
param set FW_RR_I 0.1
param set FW_RR_IMAX 0.2
param set FW_RR_P 0.08
param set MIS_LTRMIN_ALT 50
param set MIS_TAKEOFF_ALT 3
param set NAV_ACC_RAD 20
param set NAV_DLL_ACT 2
param set NAV_LOITER_RAD 100
param set RWTO_TKOFF 1
param set MAV_BROADCAST 1
param set FW_ARSP_SCALE_EN 0
param set FW_AIRSPD_MAX 35
param set FW_AIRSPD_MIN 7
param set FW_AIRSPD_TRIM 15
param set FW_P_LIM_MAX 25
param set FW_P_LIM_MIN -5
param set FW_R_LIM 30
param set FW_MAN_P_MAX 30.0
param set FW_MAN_R_MAX 30.0
param set FW_THR_CRUISE 0.8
param set FW_THR_IDLE 0
param set COM_DISARM_PRFLT 0
fi
set MIXER_FILE etc/mixers-sitl/autogyro_sitl.main.mix
set MIXER custom
@@ -0,0 +1,15 @@
#!/bin/sh
#
# @name Cloudship
# @type Airship
# @class Airship
#
# @output MAIN1 thrust tilt
# @output MAIN2 starboard thruster
# @output MAIN3 port thruster
# @output MAIN4 tail thruster
. ${R}etc/init.d/rc.airship_defaults
set MIXER cloudship
set PWM_OUT 1234
@@ -0,0 +1,12 @@
#!/bin/sh
#
# @name Quadrotor SITL model for JSBSim
#
# @type Quadrotor Wide
#
# @maintainer Jaeyoung Lim <jaeyoung@auterion.com>
#
. ${R}etc/init.d/rc.mc_defaults
set MIXER quad_w
@@ -0,0 +1,35 @@
#!/bin/sh
#
# @name Hexacopter SITL model for JSBSim
#
# @type Hexarotor x
#
# @maintainer Jaeyoung Lim <jaeyoung@auterion.com>
#
. ${R}etc/init.d/rc.mc_defaults
if [ $AUTOCNF = yes ]
then
param set MC_PITCHRATE_P 0.1
param set MC_PITCHRATE_I 0.05
param set MC_PITCH_P 6.0
param set MC_ROLLRATE_P 0.15
param set MC_ROLLRATE_I 0.1
param set MC_ROLL_P 6.0
param set MPC_XY_VEL_I_ACC 4
param set MPC_XY_VEL_P_ACC 3
param set RTL_DESCEND_ALT 10
param set RTL_LAND_DELAY 0
param set TRIG_INTERFACE 3
param set TRIG_MODE 4
param set MNT_MODE_IN 4
param set MNT_DO_STAB 2
param set MAV_PROTO_VER 2
fi
set MAV_TYPE 13
set MIXER hexa_x
@@ -0,0 +1,32 @@
#!/bin/sh
#
# @name Typhoon H480 SITL
#
# @type Hexarotor x
#
. ${R}etc/init.d/rc.mc_defaults
if [ $AUTOCNF = yes ]
then
param set MC_PITCHRATE_P 0.1
param set MC_PITCHRATE_I 0.05
param set MC_PITCH_P 6.0
param set MC_ROLLRATE_P 0.15
param set MC_ROLLRATE_I 0.1
param set MC_ROLL_P 6.0
param set MPC_XY_VEL_I_ACC 4
param set MPC_XY_VEL_P_ACC 3
param set RTL_DESCEND_ALT 10
param set RTL_LAND_DELAY 0
param set TRIG_INTERFACE 3
param set TRIG_MODE 4
param set MNT_MODE_IN 0
param set MAV_PROTO_VER 2
fi
set MAV_TYPE 13
set MIXER hexa_x

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