- 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
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.
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.
* 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
* 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>
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.
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.
* 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
- 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)
- refactor Run() into simple state machine
- perform reset and configuration in sensor bus thread
- when using data ready interrupt skip checking FIFO count
- 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)
- 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
- 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.
- 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
* 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
- 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)
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)
- instrumenting PX4 Matrix and Param methods is too burdensome
- partially restore px4_fmu-v5_stackcheck and holybro_durandal-v1_stackcheck to match default configs
- 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
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.
* 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
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
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
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)
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.
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).
* 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
-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.
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>
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)