Close

Wireless solar-powered liquid level sensor - ESP8266-based

A project log for Retro-futuristic automobile control panel

Conversion of dashboard from an old, Communist clone of the French Renault 12 (Dacia 1310)

skaarj[skaarj] 05/29/2016 at 21:290 Comments

If I see any wires today, I will go insane for good. No more wires for this update log. Today - wireless approach.

They say the French started to dig some archaeologic hole and they found wires after 6 feet (2 meters) depth. They concluded they had communication network since 1700s. The British went mad after this discovery and they dug around 9 feet (3.5m) until they also found wires. In conclusion, the Brits were ahead of the French with another 100 years. The Romanians dug some 100 feet (50 meters) pit and found nothing. In conclusion - 2000 years ago we already had wireless telecommunication networks.

Good. I want to see how much gasoline I have in my tank. And if anyone asks me to remove the dash console one more time to find the gasoline level wire, then someone should call the emergency number and ask for neuropsychiatry hospital.

Because everyone on Hackaday is talking about the ESP8266 and its amazing properties, let's get one and torture it.

Also we need an ultrasonic fluid level sensor, just like this one - JSN-SR04T (google).

Also my old love - Arduino Due, a solar panel shield, some lithium accumulators and a custom-made shield for Wifi and level sensor.

The master side will be the RasPI powered by FreeBSD Unix 11.0-CURRENT.

First, the schematic - drawn by hand as usual:

"Nivel" means "level".

There's also a jumper called "ID". So If I need more sensors, they must identify themselves so the server knows which one is transmiting. Maxmum 4 sensors for now: both pins unselected, both pins selected and only one pin selected. Pins D5 and D6.

The pinouts for ESP and level sensors are as following:

The client and server side software are placed in the Files section.

These are my two sensors. Again, trouble with camera focus.

Right side - solar panel shield. The other shield has the schematic listed in the first picture.


Yes, my hand is burned due to high voltage. Details in the Audio Sound System (II) log.

On the back side I placed some magnets in a silicone layer...

so the sensor can be placed on any vertical metallic surface close to the monitored tank.

Software:

Sensor side:

Arduino Due. No offense. It has huge processing power and it can do everything that the older arduinos do. And faster.

Server side: Gnu C, FreeBSD Unix. Needs an open access point to work. Mobile phone in AP mode or whatever router. Just don't enable any encryption if you have any older ESPs, the firmware has some undocumented bugs - or I am too lazy to search on the internet.

How it works:

The sensor searches for the server IP and connects. It sends the measured level in centimeters.

The server listens for connections. If any connection fails, the server can fork() another instance of itself when the sensor reconnects, and the OS handles the killing of the inactive instances left. The number is dumped in /usr/local/www/data/index.html which has some 1 second autorefresh() when accessed from a browser.

Work in progress: integrate this with the CANBUS/WITS system, so it can receive the data as a WITS-style string.

Software is uploaded in the Files section.

______________________________________

kernel panic: improbability coefficient below zero

Discussions