BAR30 on Flight Core
Does the Flight Core firmware support the BAR30 pressure sensor? I plugged one into J13 after changing out the connector, but the sensor didn't register in QGroundControl. Then it donned on me that ArduSub supports the BAR30, but not the others. I'm using the Flight Core on a submersible and I will be using the BAR30 for depth.
If this isn't already supported then I will need to manually pull it in from ArduSub I suppose. I can write my own app to access the I2C bus and publish the information as a node.
We've not tried using this sensor, but getting I2C drivers up and going is pretty easy normally. I found this in the Nuttx code base that might help:
You'd need to enable the driver to build in here:
And to run on startup here:
It looks like ArduSub modified the ms5611 driver to accommodate the ms5837 and calls the driver AP_Baro_MS5611. The init() has a switch case on _ms56xx_type and includes a "BARO_MS5837" case.
It also includes a function for calculating the temperature and compensated pressure for the 5837.
The Flight Core firmware incudes a different version of the MS5611 driver that doesn't support the ms5837. This would be a good update to pull in.
If it's a good addition, and you're up for it, I'd suggest going for it and adding the driver to the 'standard' PX4 code base! If it's in the master branch we could pull it in pretty easily.
I know this is kinda an old post but I have created a driver for px4 that can use both flavors of the MS5837 the bar2 and bar30. I will create a pull request with px4 so it will be available.