I have connected the bar 30 pressure sensor to my arduino Due (VCC 5V, GND, SDA 3.3V, SCL 3.3V) I’m receiving data properly but without touching or moving the sensor the value changes from 854mbar to 841mbar in 3 minutes approximately; then the pressure starts to increase up to 850 again in the same lapse of time. When I connect another sensor the reading is 815 mbar and this value stays without change. I’m 1800 meters over the sea level.
According to the datasheet for the pressure sensor used in the Bar30 (MS5837-30BA), the absolute accuracy in this pressure range is +/- 50 mbar, so these measurements are well within the published accuracy. I’m not sure what is causing the one sensor to move around a bit.
Please note that this change in pressure only causes about 10cm of depth change.
The sensor has a resolution of 2mm, so it can detect very small changes in depth, but the absolute accuracy is not quite that good.
Thank you Rusty; testing with a new sensor I realized that the pressure increases with time, I have 10 cm more every 10 minutes!!! Why does it happens?
Where can I find some information about the arduino library? probably modifying it I can solve the problem.
Can you please confirm for me that with the Arduino example code you are seeing the pressure reading go up by 10 mbar every ten minutes, continuously? Is this correct? Does the incease level off after any time?
I am testing a couple of Bar30s over here, and although their absolute values may disagree by up to 50 mbar (50cm of freshwater), they are quite precise and I have not seen their values change by more than 10 mbar in air in any amount of time.
The Bar30 is designed for underwater use, and we haven’t tested its performance in air too much. Could you please try leaving the sensor submerged in a cup of water, and seeing if the continuous incease in pressure still occurs?
Of course I’ll try it underwater, here is the code that I’m using. Yes; the pressure increases every 10 minutes approximately 10 mbar. I don’t know if after more than 3 hours this changes. I’ll try downloading again the library.
I’m using Arduino DUE (3.3 V logic level) and feeding the sensor with a 3.3 voltage regulator. (all the grounds are interconnected)
Yes, I am powering the sensor with 5v from an Arduino Uno. Can you also try powering it with 5v if possible? The logic should stay at 3.3v.
10 mbar increase every 10 minutes for at least 3 hours- does this mean you are seeing the reading change by as much as 180 mbar, or 1.8 meters?
I tried another sensor in air, and this one did see a drop similar to what you were describing- after an hour and a half, the sensor altitude changed by 28 cm (28 mbar) but did not decrease any further. This is still within the 50 mbar accuracy of the sensor.
Can you also try using the sensor with the example code?
Ok I’ll try it with the example code and feeding the sensor with 5V, by the way I wanna find the solution of that drop of the value. (It’s the same behavior that I have in my sensor).
It seems that the change of the pressure stops until 2 hours after.
I’ve been trying to solve the problem feeding the sensor with 5v and test it underwater (always at the same depth in controlled conditions) and I’ve found that as I request data faster the pressure changes faster too and farther of the real reading. For example: the first reading of the sensor is 846mbar, if I poll data with 1000 ms of delay the pressure only goes around 4 cm, If I poll data every 5 ms the value goes upt to 15 cm more sometimes not always.
I’ll add a picture of how I douing my experiment and the code that I’m using, basically is the example program.
Thanks for the code and a picture of your setup, it looks like you are doing everthing right. I continued my testing with a couple of Bar30s, and although their values do fluctuate by up to 30-40 mbar over time, this is still within the specification of the MS5837-30BA sensor. Previously, Ruty mistakenly told you the value may fluctuate by up to 10cm over time, but it is actually up to 50cm (+/-50mbar). Unless you are seeing the sensor value change by over 50 mbar at a constant pressure, it it still operating within normal parameters. Rusty took a look through the code and our MS5837 Arduino library, and he doesn’t see anything that may cause an issue like this or the reading to fluctuate more rapidly with a higher polling rate. You are welcome to double check our work and see if you can find an issue, but I do believe your Bar30 is operating within the sensor manufacturers specifications.
Ok thank you; the problem for me is not the accuracy, is the repeatibility of the values everytime I read the pressure, let me tell you that before I used to connect the Sparkfun Breakout MS5803-14BA with any issue, it has a pressure sensor of the same company that the Bar 30 has. The difference is that it is not waterproof.
I’ll continue checking a possible solution to the problem and if I find something I’ll tell you.
Probably I can help you to design a breakout with the mentioned sensor that could fit in a penetrator like the MS5837-30BA and make it waterproof.