For a university project I have to build a vehicle that travels down a 30cm wide channel underwater without touching the sides. My vehicle is going to be approximately 18 cm wide so I need to be able to measure distances of around 6cm. We also have a somewhat small budget and cant afford the £30/£40 it would cost to buy two waterproof ultrasonic sensors. How else could I measure the distance and avoid the sides? Are there cheaper ultrasonic sensors I haven't found?
Help me understand what you wrote.
IS the channel the only part under water? Is it completely under water? Can sensors on your vehicle be out of the water? Is it ok if the vehicle sensor touches the under water channel?
You state you need to measure distance around 6cm. But if the vehicle is closer than 6cm, don't you also need to know that? So the measurement necessary seems to be 0 to 6+cm.
Describe the "water"? fresh or salt? Clarity of the water?
A little thought and you will discover you ONLY need to measure ONE distance to a single side and program your vehicle to maintain that distance.
have a look at Pololu Proximity Sensors and Range Finder and TOF sensors - never attempted to use them under water though
if you have access to a 3D printer you could make a waterproof enclosure
you could ask Pololu for advice
the channel is open at the top but the whole vehicle must be underwater including the sensors. Yes the range would be 0-6cm but if one distance is too large then the other side would have to be close to the wall. The water is clear and fresh. Thats a good point but I'd prefer to measure both if possible.
And what would you gain by doing that except to complicate tremendously the logic of keeping the vehicle within a range of distances from one wall? When you drive a car, do you constantly measure both sides of a lane?
The only sensors that will work for you are light or IR sensors. Is the channel made from reflective material? If not, what material?
Looks like IR is out for underwater sensing, But look into this link.
Those don't work underwater. For underwater sonar, you need transducers designed to work in water.
Due to the very high speed of sound in water, it is not practical to use sonar to measure distances less than about 0.5 meter.
Optical sensors or "whisker" feelers are viable options.
For a university project, you seem to have missed the class relating to waves. Sound waves produced by and detected by a sensor are COMPRESSION waves. Water is NOT compressible, so a transducer made for air cannot physically move the volume of water to produce a sound wave. That takes a lot of power to physically move a volume of water and force that moving power some distance. That is also why the receiving sensor needs to detect actual water movement.
Thats not true though? water is very slightly compressible, thats why sound travels through it. if it was completely incompressible sound would pass through it instantly and sonar wouldn't be possible. Do you think that sonar systems that measure distances of miles physically shift such a large quantity of water?
these work quite nice:
When you put them directly behind glass they work under water, too, but reported distances are different than in air.
I probably should have mentioned that the channel is made out of something clear. I'm not sure if it's glass or plastic but it if the sensors work through glass then they can't detect it i guess.
Does this vehicle need to be totally autonomous or can it use signals from outside.
Hard to say. Reflection occurs from any boundary where the index of refraction changes. The larger the change in index, the more intense the reflection.
Try it and see.
it can use signals from the outside so we are considering remote control but I'm looking into autonomous methods at the moment.
so if the difference in refractive index between the water and the channel wall material is large enough i might get a small reflection even if most of the light passes through the wall?
There is always a reflection from a boundary where the index of refraction (impedance) changes.
If the boundary is rough, the reflection will be diffuse and may not be detected by the sensor, but then the transmitted beam will be diffuse as well.
How far do you have to travel?
It's the opposite: the larger the difference in refractive index (which is related to the speed of the wave in the mediums), the more of a reflection you will get. That is at all interfaces: air/glass, glass/water, water/air, etc. Light moves faster in air than in glass, which is how lenses work. Different kinds of glass again have different light speeds, so you can make layered lenses.
Fun example: the refractive index of clear acrylic (PMMA, perspex) for visible light is about equal to that of water, which is why you can not see an acrylic sheet when it's held under water, the light passes straight through, no reflections or distortions. This makes it a popular solution for walking on water illusions.
Probably true, but you can use amplitude rather than time of flight for a rough measure at closer distances, just as with light. Still requires transducers.
With large flat areas the separation would modulate the acoustic spectrum from ambient noise due to standing waves. In theory that just needs a hydrophone, amplifier, ADC and FFT, but I'm sure there are many complications.
You could use standing waves and "levitate" yourself inside