Water pressure sensor for an rc submarine

Hey guys!
Im new here so dont be too mean to me haha.
I just build an rc submarine, and now I want to add some automatic functions to it, one that I thought of is to build an depth keeping sistem with a water pressure sensor, that if I press a button it takes a screenshot of the current water pressure and with the pitch and the ballast tank try to keep the depth. My problem is that I can’t find a proper pressure sensor.Almost every presure sensor I have found are barometric pressure sensor and I dont know if I can be adapted to be used under water. In aliexpress I only found this
https://a.aliexpress.com/_B1OFuE. But the pressure range is 0 to 40kpa, which I think is not enough (the sub will get max 2 meters under water) and I can't find any information or code about this sensor. Do you think this sensor will do the job? If so is there any tutorial or source code about it? If it dosen't can you recomend me a cheap sensor for the job and a tutorial for it?
Thanks for the help :)))

If you are smart enough to build an RC submarine, you can certainly build a pressure sensor for your sub.

Use a piece of rubber, inner tube material, etc or a piece of wet suit rubber and make a diaphragm to fit a port on the bottom of your sub.

In the middle of the diaphragm, make a hole for a bolt to connect to rod to the diaphragm. Water pressure will press against the air inside the sub and move the rod.

Pick a 10k pot and attach a lever arm to the control shaft. Attach the diaphragm rod to the end of the lever arm. Now, the movement of the diaphragm will turn the potentiometer.

Use the pot as a voltage divider and connect the pot pin that is connected to the slider to your Arduino AD pin and measure the changing value. Calibrate for depth.

See how easy that is?

Paul

Figure it this way. At sea level on a nice day atmospheric pressure is about 14.6 PSI or 100.6635 Kiloppascal. For every 33 feet (10.06 meters) you go down, the pressure increases by one atmosphere. So if we start with zero and eliminate atmospheric pressure on the surface every 10.06 meters the pressure will increase by 100.6635 Kilopascal. You are only looking at a depth of 2 meters or about 1/5 atmosphere or roughly 20 Kilopascal.

A 0 to 40 kpa pressure transducer should work fine. Just remember you need to measure pressure outside your submarine. So your sensor needs ported to outside the submarine. The sensor you linked to should work. I suggest you read this:

Making sure you understand everything before starting on this project.

That or as suggested roll your own sensor.

Ron

Thank you so much for your answer! It has helped me a lot. Maybe my reply is a bit silly, but at those 100k kPa for every 10 meters, is not 1 atm added? I mean, the air column above it plus the water column, that's why I doubted if the module would work.

Air inside a sub always remains around 1 atm. Even at 1, 000 feet below the surface. If not the crew would turn into pancake.

see https://www.reddit.com/r/explainlikeimfive/comments/u6l4l/eli5_why_do_submarines_need_to_be_pressurized/

Without overly going into detail we have pressure absolute and pressure gauge. An absolute pressure gauge will not read 0 at sea level, it will read about 100.6635 kpa give or take depending on the barometric pressure that day. Then as we descend into the water (submarine) the pressure acting on the hull will increase about 1.0 atmosphere for every 10 meters of depth. A pressure gauge designed for gauge and not absolute will start at 0 kpa at sea level (not absolute) and increase about 100 kpa for every 10 meters.

Inside the submarine sea level pressure is maintained, the sub is pressurized. This is why I mentioned your pressure sensor needs to be vented to outside the sub.

Ron

tycobrae has a point. The pressure inside the RC submarine could vary between the atmopheric pressure and the water pressure, depending on how it is build. There might be flexible parts or it might leak. To measure the only water pressure relative to the inside pressure might not be the most accurate.

When the absolute water pressure is measured outside the RC submarine and also the absolute baromic pressure of the air at the surface, that would be the most accurate.

The normal absolute (baromic) pressure sensors are made to go up (mountain climbing, airplane), but not to go down. For example the BMP280 can measure 300...1100 hPa.

The bare pressure sensors are for air. When it is for water, then it is in a housing with protection against the water.

What about a absolute (baromic) pressure sensor inside the RC submarine, to be able to tell if there is a leak, and a differential (relative/gauge) pressure sensor to measure the water pressure ?
The BMP380 can measure up to 1250 hPa.
To measure the water pressure a waterproof or submersible pressure sensor can be bought or made.