Integrating Bar30 Depth Sensor with Pixhawk 2.4.8

Hi everyone,

I’m trying to integrate the Bar30 depth sensor with a Pixhawk 2.4.8 flight controller running ArduSub v4.5.3. The sensor is connected to the I²C port on the Pixhawk, and I’m using Mission Planner for monitoring.

However, I’m not seeing any values for SCALED_PRESSURE2 or related depth data in the MAVLink Inspector .

Could anyone confirm if it’s possible to get the Bar30 working with the Pixhawk 2.4.8 on ArduSub v4.5.3? If so, what are the steps to correctly configure it? Do I need to enable any specific parameters or settings in Mission Planner to make it work?

Thanks in advance for any guidance!

Hi @Harshada -
Have you checked the Vehicle Setup page in BlueOS to view the status of connected sensors?
Using the Bar30 with the Pixhawk and the latest ArduSub is definitely supported - it should work by default! Have you modified the Bar30 in any way, like extending the wires?

Hi,

Yes, I’ve checked the Vehicle Setup page in BlueOS. We’re using the Bar30 with the Pixhawk running the latest ArduSub, and it was working initially—Pixhawk was detecting the sensor and giving air pressure readings in the range of 996–1000 mbar. However, the readings were intermittently jumping to around 2000 mbar before it eventually stopped detecting the Bar30 altogether.

I should mention that we did extend the depth sensor cables. Could this have introduced signal integrity issues or voltage drops affecting I²C communication? Let me know if there are any suggestions for troubleshooting or verifying the sensor connection.

Thanks!

Hi @Harshada -
Extending the cables is definitely responsible for your issues - but not due to voltage drop. I2C is a protocl that was never intended to run for long ditances, so any extension beyond the default cable length is liable to run into trouble, especially in a noisy electrical environment like an ROV.

This guide has some tips for extreme lengths, but generally the best course of action is to examine your clock and data lines with an oscilloscope, and add a Resistor/Capacitor filter to help make sure you have nice square transitions on your signals. Lowering the frequency of the I2C bus can also help, and won’t affect much given the low data rates involved.