91 Commits

Author SHA1 Message Date
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
Beat Küng
795b9e938e drivers: add ST LPS33HW baro driver
Note: only tested on I2C
2020-07-06 10:13:11 -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
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
Beat Küng
43279f18ba bmp388: fix variable shadowing warning 2020-05-29 09:54:18 -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
rfu
90c3819df5 fxos8701cq + fxas21002c: add support for I2C 2020-05-04 09:49:23 +02:00
Daniel Agar
f51715c7ab lps22hb: move to PX4Barometer and cleanup 2020-04-15 23:33:41 -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
02f4ad61ec
I2C/SPI require device type in constructor 2020-04-01 12:24:22 -04: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
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
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
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
Daniel Agar
1da7209fe1 lps25h: move to PX4Barometer and cleanup 2020-01-05 10:35:13 -05:00
Daniel Agar
dcbb03b785
bmp280: fix device id (device type not set) 2020-01-04 13:16:08 -05:00
Daniel Agar
16bd1088fa mpl3115a2: move to PX4Barometer and cleanup 2020-01-03 16:53:09 -05: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
cc7a0cd69d beaglebone blue: build librobotcontrol with cmake 2019-12-29 17:32:06 -05:00
modaltb
9b707eebc7 bmp388: use default stack size of 2048, fixes stack check failure 2019-12-28 19:21:05 -05: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
92559f7a85
Bosch bmp280 barometer cleanup 2019-11-23 15:31:22 -05: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
99a7491cde
bmp280: build on linux and qurt 2019-11-13 15:16:24 -05:00
Daniel Agar
bcfa2eecd8
ms5611: build on linux (navio2) 2019-11-13 13:01:00 -05: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
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
modaltb
1e1549a169 Add support for Bosch BMP388 barometer 2019-10-15 23:33:49 -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
Daniel Agar
78ef8aab2d STACK_MAIN increase default 1024 -> 2048 2019-08-30 19:11:51 -07: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
Daniel Agar
5d813224c8 PX4 SPI default to thread locking mode 2019-08-20 21:36:21 -04:00
Beat Küng
5d8710d539 bmp280: fix device_id initialization 2019-07-16 08:09:22 +02:00
mcsauder
d1e46737a3 Organize, alphabetize, and deprecate unneeded #includes from the barometer drivers. 2019-07-08 21:32:52 -04:00
David Sidrane
79eb74be3f Fix bmp280 on FMUv4 2019-06-05 15:43:53 -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
56024cda79 ms5611 move to px4 work queue 2019-05-24 12:58:55 -04:00
misswhile
37fe090225 fix bmp280 driver init faild. 2019-04-25 10:19:12 +02:00