mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-09-25 23:55:28 +08:00
feat(boards/px4_fmu-v6xrt): add BMP581 fallback support
Probe the existing barometers first and start BMP581 at address 0x46 only when they are not detected,
preserving compatibility with existing hardware. Similar as done on V6X.
(cherry picked from commit 9ba27f8f4b)
This commit is contained in:
@@ -9,9 +9,7 @@ CONFIG_BOARD_SERIAL_TEL3="/dev/ttyS6"
|
||||
CONFIG_BOARD_SERIAL_RC="/dev/ttyS4"
|
||||
CONFIG_DRIVERS_ADC_ADS1115=y
|
||||
CONFIG_DRIVERS_ADC_BOARD_ADC=y
|
||||
CONFIG_DRIVERS_BAROMETER_BMP388=y
|
||||
CONFIG_DRIVERS_BAROMETER_INVENSENSE_ICP201XX=y
|
||||
CONFIG_DRIVERS_BAROMETER_MS5611=y
|
||||
CONFIG_COMMON_BAROMETERS=y
|
||||
CONFIG_DRIVERS_CAMERA_CAPTURE=y
|
||||
CONFIG_DRIVERS_CAMERA_TRIGGER=y
|
||||
CONFIG_DRIVERS_CDCACM_AUTOSTART=y
|
||||
|
||||
@@ -120,11 +120,20 @@ fi
|
||||
# External compass on GPS1/I2C1 (the 3rd external bus): standard Holybro Pixhawk 4 or CUAV V5 GPS/compass puck (with lights, safety button, and buzzer)
|
||||
ist8310 -X -b 1 -R 10 start
|
||||
|
||||
# Internal baro
|
||||
bmp388 -I -b 3 -a 0x77 start
|
||||
if ver hwtypecmp V6XRT000 V6XRT001 V6XRT002
|
||||
then
|
||||
# Internal baro
|
||||
if ! bmp388 -I -b 3 -a 0x77 start
|
||||
then
|
||||
bmp581 -I -b 3 -a 0x46 start
|
||||
fi
|
||||
|
||||
# Internal baro, on a bus shared with the PM2 connector
|
||||
bmp388 -I -b 2 start
|
||||
# Internal baro, on a bus shared with the PM2 connector
|
||||
if ! bmp388 -I -b 2 start
|
||||
then
|
||||
bmp581 -I -b 2 -a 0x46 start
|
||||
fi
|
||||
fi
|
||||
|
||||
unset INA_CONFIGURED
|
||||
unset HAVE_PM2
|
||||
|
||||
Reference in New Issue
Block a user