I have 2 related issues:
- BAR02 SUPPORT in ARDUSUB
I am getting strange values using the Bar02 connected to a PixHawk running ArduSub. For the record I am running ArduSub 3.5.3.
In air at around 40m above sea level, our Bar02 is reading ~20500 mbar via QGC. We have a spare Bar02 that we have connected to the raspberry pi and are reading values via the Blue Robotics python library. This also gave us values of approximately ~20340. Then we changed the Barometer initialisation in the first few lines of example.py from
sensor = ms5837.MS5837_30BA()
sensor = ms5837.MS5837_02BA()
This meant that we now received values of approx 1017 mbar, which is still not accurate for our altitude in air but nevertheless a lot closer to what we expect.
Is there an equivalent change we can make in ArduSub so that it calculates correctly for the Bar02? Can we change a parameter in QGC that specifies which barometer we are using? Or perhaps Ardusub does not yet have support for the Bar02?
- DEPTH HOLD ISSUE
Underwater, depth hold does not function (tested in a pool ~2m deep), with the Robot desperately trying to surface regardless of its starting position or any force holding it down. Looking at the raw pressure values in QGC, we see press_abs values in the order of > 20000 mbar which equates to ~200m depth. However we do not have any fence parameters available and so the robot should still hold its depth.