Need advice on Water tank level monitoring

thanks ill try that.

Do I connect level sensor to the ANALOG port of the Uni?

Data for my sensor

What does yours output? 0-5v?

Here are the specs for mine.
Model Number : QDY30A
Origin : Mainland China
Model Number : QDY30A
Range : 0-500m
output : 4-20mA, ,0-10V
Power supply : DC24V,12-36VDC
Working temperature : -20-55
Accuracy : 0.2%FS ,0.5%FS
Cable lenth : 1m/2m/3m/5m/10m/15m/20m/30m
Material : 304/316 Stainless Steel
Protection : IP68
Response Time : 1ms (up to 90%FS)

I think you will find it will do one or the other.

output : 4-20mA, ,0-10V

My shelly is set for adc range 12v

Damn ok that’s high. I’m sure mine will be find I guess the shelly just works it out.

Yep I originally had it set for 24v and the values didn’t really change when back to 12v. As much as i read the shelly website as soon as they dived into techy talk they lost me

Maybe if yours is a 5v range you may need resistor to bring it up? I guess you can bench test to see if the shelly reads it ok first

Yea, it says it has a large range supported for the ADC.

1 Like

I used the following in a template helper for my %.

{% set voltage = states(‘sensor.water_tank_sensor_adc’) | float %} {{ float ((voltage / 7.64) | float * 100 ) | round(0) }}

The 7.64 is the voltage when the tank is 100% full.

I’m not sure what’s going on, but this is all the entities I see, of which none are providing me with the data I need.

I’ve also enabled all disabled entities in HA.

Can you show your connection layout?

Is your level sensor two or three wire?

Its a 3wire sensor.

Connected like this.

The interesting thing is that there is an option in Shell Web UI to add a peripheral,

One of the options is a Voltage Meter?

I notice no-one is including compensation for changing air presure.

A quick calculation suggests a potential variation due to changing air pressure of up to 50cm. (pressure at 1m depth = 100 hPa. Air pressure could vary between (say) 980 & 1030 (ie a range of 50 hPa)). 50hPa = 50cm.

So changing air pressure is significant. If you have an air pressure sensor (eg BMP280, ESP), compensation is just adding Pa - Pc to the calculated depth (in cm).

Note Pa actual air pressure
Pc air pressure at time of calibration
Compensation value is in cm - adjust to same units as your depth.

There are two wires that should connect to ground. On mine it is the green wire.

I am using the “Voltage Output” version here.

If I measure the voltage between the data (yellow) and ground, I get 1.3v (tank is quite empty).

How ever, I cannot get the Shelly to read the voltage at all.

I have tried with my Yellow Data wire to the Blue (data) and the Grey (analog IN) cable on Shelly Uni

Now, since updating to the latest version (v1.4.4) the device will not connect to my IoT WiFi, had no issues whatsoever on the previous firmware.

These Shelly devices are absolute crap.