My first post here and I thought I would share with everyone a project I have been working on for our pool. I now several others are doing the same thing, but I approached it a little differently.
It is built using the following Hardware and Software:
Raspberry Pi3 LowPowerLabs MightyHat (Pi UPS/Power Control, LCD, RFM69HW 433Mhz Radio, Power Booster, Arduino Clone) 4400mAh LiPo Battery for the MightyHat LowPowerLabs MoteinoUSB-R5 (Arduino Clone with RFM69HW 433Mhz Encrypted Radio) LowPowerLabs Moteino-R4 (Arduino Clone with RFM69HW 433Mhz Encrypted Radio) eTape resistive liquid level sensor from milonetech.com OpenEnergyMonitor (OEM) EmonCMS OEM EmonPi (Raspberry Pi w/radio for collecting sensor information via 433Mhz)
Basically I have designed an automatic pool fill system that monitors the level of our pool and then fills it automatically when needed, but based on some very specific criteria.
I know what you are thinking...why not just by a little float thing and have it fill that way...well we had one of those and it broke in such a way that we would have to tear up the existing system where it was mounted (in cement) in order to replace the part that had broke. Since we have a bunch of monitoring and automation within our home already, I decided to automate this process as well.
First some background:
Utilizing various software and hardware platforms we currently monitor every electric circuit in our main power panel, all of our solar production, all of our weather information (Davis Vantage Pro 2 weatherstation) and temperatures throughout our house, air conditioning and cooling ducts, attic and our pool water. For tracking all of this we utilize EmonCMS (from Openenergymonitor.org) and store all of the information and readings in a MySQL database. All of the weather data is stored in a MySQL database and converted with a php script to run our family weather website (http://zeus.rstechnical.com). The weather stuff is cool, but not really part of this current project.
The sensors we are using are from both Openenergymonitor as well as LowPowerLabs. We use the emonTH from OEM and the Moteinos (and associated hardware) from LowPowerLabs. We use the Raspberry Pi as our management and data collection nodes.
My current Pool level monitoring and filling project is broken into two parts: monitoring the level, and filling the pool.
The pool level monitoring part was pretty easy. We have a small cement basin with a 1" pipe connecting to our pool. This basin is about 1' deep and connects directly to the pool and the level of the water in this basin is representative of the level of the pool water. Since it only has a small 1" pipe connecting it to the pool, it is almost impervious to the kids splashing and creating havoc in the pool. This became the perfect place to install the eTape water level sensor.
The pool level monitor uses a product called eTape from milonetech.com. It is a resistive based liquid level sensor. (google milone etape and click on images). It basically looks like a ruler with three wires coming out of the top. You only need to use two of them to get a resistive reading. This eTape connects to a little Moteino (lowpowerlab.com) microcontroller (~$20) and two AA batteries. The Moteino is an Arduino clone. The Moteino sketch that I wrote gets the level of the pool and transmits it via 433Mhz to my EmonPi Raspberry Pi which in turn sends it to emoncms and stores the data in a mySql database once per minute. This Moteino is battery operated and at a once per minute transmission, the batteries should last about two or so years.
I chose the eTape solution instead of simple float or even the SST liquid sensor from sparkfun (as others have done) because I want to be able to see the level of my pool, not just get a notification if it is low. Plus from a programming standpoint, I can (and do) use low and high thresholds. With the eTape, I get a resistance measurement across the entire level of the water in my measurement area. When I see that I am low, I can fill until the resistance changes to the value that I want. This allows me to let the pool level go down several inches and then fill back to my full level as opposed to starting the fill process the instant the sensor comes out of the water. I can also track the level of the pool over time since the eTage provides resistive values based on the water level.
The second part utilizes another Raspberry Pi3 ($35), a microUPS/battery backup/power control unit called MightyHat (~$40) (lowpowerlab.com) which provides the Pi with another arduino microcontroller, a 4400mAh battery for power backup (about ~3 hours) and another 433Mhz radio for transmitting sensor data. In addition it includes an Nokia LCD screen that I can send information and status updates. I have three weatherproof buttons on the Pi, one (momentary) to boot/reboot and powerup the Pi, one (momentary) to handle manual filling of the pool if needed and a third (latching) to physically interrupt power to the valve that I use to control the filling process.
Please see part 2