2635 Commits

Author SHA1 Message Date
Daniel Agar
e57aaaaa5e
rotate accel/gyro FIFO before publish and fix angular velocity filter resets
- rotates accel & gyro FIFO data before publication both to simplify downstream usage (including log review) and fix other issues
     - to best handle int16_t data rotations are now either performed with swaps if possible, otherwise promoted to float, rotated using the full rotation matrix, then rounded back to int16_t
 - fix sensors/vehicle_angular_velocity filter reset both with proper rotation and new calibration uncorrect helper
      - in FIFO case filtering is done before calibration is applied, but we need to handle a possible reset from a completely different sensor (vehicle body angular velocity -> sensor frame uncorrected data)
2021-03-22 12:01:12 -04:00
PX4 BuildBot
e79b3930f3 Update submodule ecl to latest Sun Mar 21 12:39:12 UTC 2021
- ecl in PX4/Firmware (81e811997b8e611aff08fa25c81322e4b956425f): 4df0054873
    - ecl current upstream: bb950a1550
    - Changes: 4df0054873...bb950a1550

    bb950a1 2021-03-10 Morten Fyhn Amundsen - Expose terrain vpos reset counter
ab69681 2021-03-10 Morten Fyhn Amundsen - Add parameter for terrain timeout
2021-03-21 10:42:43 -04:00
Dima Ponomarev
e660b50021
uavcan: add IMU sensor support 2021-03-17 18:04:12 -04:00
Daniel Agar
e7722b11eb pwm_out multi-instance support
PX4 uses banks of 8 outputs as a logical structure. Boards that have
more outputs than 8 get multiple instances. This is an arbitrary choice
that helps with overall structure and enables the mixing of different
device classes (like FMU, IO or UAVCAN).
2021-03-17 22:03:18 +01:00
Daniel Agar
0eac534b80
geo: purge globallocal_converter 2021-03-15 16:16:19 -04:00
Sander Smeets
517a1d0116
battery_status: factor in total current consumption in battery remaining estimation 2021-03-15 12:32:45 -04:00
RomanBapst
82a2126f97 TECS: add feedforward gain for total energy balance rate
Signed-off-by: RomanBapst <bapstroman@gmail.com>
2021-03-15 11:47:07 -04:00
Daniel Agar
2257c3767e simple gyro auto calibration module 2021-03-15 09:46:47 +01:00
jciberlin
01c9a4f24d ghst: fix warning generated on PR (Clang Tidy)
Fix warning generated on PR (Clang Tidy).
2021-03-15 09:42:53 +01:00
jciberlin
6f5efbeab5 ghst_telemetry: send battery status
Send battery status (ghst_telemetry). Apply factors to show correct values of volts, amps and mAh. Change ghost protocol code to follow more MISRA C++ guidelines.
2021-03-15 09:42:53 +01:00
Beat Küng
b512a3d8f7 param: add param_get_system_default_value 2021-03-12 13:44:10 +01:00
Daniel Agar
7d78cf8505 parameters: param_value_is_default() add note about params_changed bitset usage 2021-03-11 11:30:43 -05:00
Daniel Agar
a991e78e18 parameters: fix runtime default edge case 2021-03-11 11:30:43 -05:00
PX4 BuildBot
d2b63f137e Update submodule ecl to latest Wed Mar 10 00:59:16 UTC 2021
- ecl in PX4/Firmware (557d8f65d89cd3da4a0e88af2a7bb1a16ebf3ff9): 4bad2a272c
    - ecl current upstream: b3c1bd6d40
    - Changes: 4bad2a272c...b3c1bd6d40

    b3c1bd6 2021-03-09 Paul Riseborough - EKF: Remove un-used code
2021-03-09 23:19:22 -05:00
Daniel Agar
684424bf73 parameters: delete unused BSON_BINDATA handling 2021-03-09 19:29:42 -05:00
Daniel Agar
bd1c575ce8
lib/sensor_calibration: add simple offset and scale sanity checks 2021-03-09 09:27:21 -05:00
Paul Riseborough
4465c4fbf6
ekf2: Publish and log EKF warning and information events (NEW msg estimator_event_flags)
* msg: Add estinator information and warning events message (estimator_event_flags)
 * ekf2: publish information and warning events
 * logger: log estimator_event_flags
 * update ecl submodule to latest

Co-authored-by: Daniel Agar <daniel@agar.ca>
2021-03-07 16:16:48 -05:00
CarlOlsson
b4b424bf7d tecs: also fix the bug in update_vehicle_state_estimates() 2021-03-05 19:44:20 +01:00
CarlOlsson
0f461f7f60 TECS: Fix internal state init if dt is large 2021-03-05 19:44:20 +01:00
Alex Mikhalev
d01806a0c6 lib/battery: Fix cell voltages with >10S
Signed-off-by: Alex Mikhalev <alex@corvus-robotics.com>
2021-02-28 22:10:23 -05:00
bresch
be9b3404a2 lpf test: test several sampling frequencies 2021-02-26 14:06:45 -05:00
bresch
3277648959 lpf test: move to common function 2021-02-26 14:06:45 -05:00
bresch
844602c961 Add unit tests for Butterworth 2nd order low-pass filter 2021-02-26 14:06:45 -05:00
garfieldG
3cd9b3c2cf Added support in Mavlink Ethernet channel parameters
Mavlink Ethernet channel settings such as udp port, remote port and broadcast mode now can be changed dynamically via parameters.
2021-02-25 08:52:38 -08:00
Daniel Agar
b66a9629e0 ekf2: update to latest ecl with new global origin helpers 2021-02-25 10:43:07 -05:00
Daniel Agar
6482120d9a
sensors/vehicle_angular_velocity: use full raw FIFO data (sensor_gyro_fifo) if available 2021-02-25 10:06:17 -05:00
Matthias Grob
a637f282ce FunctionsTest: cover lerp 2021-02-24 17:27:31 +01:00
Beat Küng
14bf9cf753 mc: add SYS_VEHICLE_RESP param to configure vehicle responsiveness 2021-02-24 17:27:31 +01:00
Daniel Agar
5f3e883f2c
sensors/vehicle_imu: vehicle_imu_status include accel/gyro full raw FIFO sample rate 2021-02-24 08:13:53 -05:00
Daniel Agar
e38560b928
sensor_calibration: increase threshold for updating calibration offsets or scale
- this is to minimize needlessly writing negligible parameter changes and triggering unnecessary estimator bias resets
2021-02-23 13:32:00 -05:00
Daniel Agar
69bd3ecf95 sensor_calibration: respect board rotation even if uncalibrated
- fixes https://github.com/PX4/PX4-Autopilot/issues/16873
2021-02-23 15:24:14 +01:00
Silvan Fuhrer
0ea8104344
select single system-wide wind estimate message (current best)
- publish wind estimate only from EKF, and wind speeds from airspeed selector to new separate topic (airspeed_wind)
 - rename message wind_estimate to wind
 - publish wind from currently used ekf instance (ekf2selector)

Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
2021-02-20 13:15:01 -05:00
jciberlin
9d65e9a980 ghst: keep the previous values for channels that are not updated
Keep the previous values for channels that are not updated (ghost protocol). Add new test data for ghost protocol.
2021-02-20 11:29:57 +01:00
jciberlin
96c72a5657 RCTest: add tests for ghost protocol
Add tests for ghost protocol
2021-02-20 11:29:57 +01:00
Juraj Ciberlin
c0f7429f8c ghst: use memcpy instead of for loop
PR review, ghost protocol, use memcpy instead of for loop

Co-authored-by: Beat Küng <beat-kueng@gmx.net>
2021-02-20 11:29:57 +01:00
jciberlin
64342f568d Ghost protocol
ghst: add ghost protocol
2021-02-20 11:29:57 +01:00
Daniel Agar
711a69854b uthash: move remaining utarray usage to parameters and delete unused
- this is to discourage further use until utarray can be dropped entirely
2021-02-20 11:28:22 +01:00
PX4 BuildBot
c863d6a346 Update submodule ecl to latest Fri Feb 19 12:39:03 UTC 2021
- ecl in PX4/Firmware (5be2f2c8f835fde0ce648561636cf565d95f5741): 310f415175
    - ecl current upstream: 81937370ac
    - Changes: 310f415175...81937370ac

    8193737 2021-02-18 bresch - [AUTO COMMIT] update change indication
04844a0 2021-02-16 bresch - ekf control: move time_last_in_air/on_ground out of GPS control logic
b00d4a9 2021-02-16 bresch - mag fusion: improve on ground forced mag fusion logic
2021-02-19 08:34:17 -05:00
Alex Mikhalev
6bd4dff51f drivers/smbus: Increase max block size to 34
batt_smbus for BQ40Z80 transfers up to 34 bytes (32 byte block + 2 byte
address), but this was overflowing and failing the PEC check.
So increase the buffer size

Signed-off-by: Alex Mikhalev <alex@corvus-robotics.com>
2021-02-18 07:52:26 -05:00
David Sidrane
760e47bbf9 uavcan bootloader use new AppDes 2021-02-17 22:47:35 -05:00
Daniel Agar
ab0d0fd0be
uORB move to PX4 platform layer 2021-02-17 11:25:56 -05:00
PX4 BuildBot
0edee1e2e9 Update submodule ecl to latest Wed Feb 17 00:39:16 UTC 2021
- ecl in PX4/Firmware (a5a1d4caa0d04cb79ba29e98ba0af04e20c53de9): d4258cc66d
    - ecl current upstream: 310f415175
    - Changes: d4258cc66d...310f415175

    310f415 2021-02-16 Daniel Agar - EKF add const state reset status access
0c5291d 2021-02-16 isidroas - Heading reset to magnetometer from GPS or EV (#969)
2021-02-16 22:00:12 -05:00
PX4 BuildBot
cf2ffb1086 Update submodule ecl to latest Tue Feb 16 12:39:08 UTC 2021
- ecl in PX4/Firmware (4de4b8012999a53b3401701fe63fafb4056fa58f): ffab483504
    - ecl current upstream: d4258cc66d
    - Changes: ffab483504...d4258cc66d

    d4258cc 2021-02-15 Mathieu Bresciani - yaw emergency: check angle between vel observation and estimate (#975)
2021-02-16 08:34:02 -05:00
Lorenz Meier
0d3676e5b0 Safety switch: Default to safety off
90% of all real-world vehicle configs default to this and it is something that users stumble over if they configure a new system. There are valid cases where this would not be desired - for these it can be still switched off.
2021-02-14 11:17:28 +01:00
Daniel Agar
1981519aad L1 position controller: use double precision floating point for all lat/lon 2021-02-12 21:59:56 +01:00
Daniel Agar
ce64951578 parameter_update.msg: add basic status info 2021-02-12 08:27:47 -05:00
Daniel Agar
b8b13bb882 parameters runtime defaults 2021-02-12 08:27:47 -05:00
Daniel Agar
da1a38b44e parameters: merge generated files ito single static constexpr header
- store parameter type and if volatile separately (saves kilobytes of flash)
 - use Bitset for tracking active and changed parameters
 - use atomic for autosave_enabled flag
 - compile at ${MAX_CUSTOM_OPT_LEVEL} (-O2 on non flash constrained boards)
2021-02-12 08:27:47 -05:00
PX4 BuildBot
71c7c69c9d Update submodule ecl to latest Fri Feb 12 12:42:24 UTC 2021
- ecl in PX4/Firmware (2292cf3ed4f8c4391131870936881331bc870260): 602e65146c
    - ecl current upstream: ffab483504
    - Changes: 602e65146c...ffab483504

    ffab483 2021-02-11 Loic Dubois - Waiting for the filter to be initialized to set global origin
2021-02-12 08:26:10 -05:00
Daniel Agar
cb7aabf932 fw_pos_control_l1: cleanup body velocity and acceleration usage
- minimize storing unnecessary state (msg copies)
2021-02-12 00:41:39 +01:00