I used JSN-SR04T waterproof ultrasonic sensor to calculate the water level in a water tank.
The idea is to calculate the distance to the water level and use that number to calculate the volume of water inside the tank.
The sensor is connected to an ESP8266, which uses MQTT to relay the information to a Mosquitto Broker using a Raspberry Pi and Node-Red.
Code for the ESP8266 can be found here (github):
To keep the electronics waterproof, I used an outdoor electronics box and electric PVC tubes. The 3d printed adapter fixes the sensor to the tank cover and allows it to stay attached to the PVC tube.
The piece needs to be printed in two parts. You can glue them together afterwards, or keep them separate, as you prefer. For me it worked better in two separate pieces.
I also tried painting the 3d print, but in the end found it was unnecessary.
The author hasn't provided the model origin yet.