Plant1337: "Water 4 plants"
Posted on October 5, 2024 • 7 min read • 1,279 wordsAn update on the Plant133 plant watering device.
Almost a year ago, I published a blog post about the plant watering device I have been working on since the pandemic. I developed this system as I taught myself about electronics and home automation. This post is about the current state of this project, which has reached a point where I consider the device hardware basically finished. The software is functional, but there are many ways it can still be improved.
Plant133 is a device for watering houseplants. It monitors the moisture level of soil using a simple capacitive sensor, and it uses an aquarium pump to maintain the moisture level within a target zone. In 2023, the device watered a single plant and was just becoming reliable enough to work in someone else’s house besides mine.
In 2024 I made a number of improvements:
The new, 4-plant version of Plant133 is Plant1337. It is pronounced “plant-leet.”
Early versions of Plant133 were based on the ESP82661 microprocessor. The ESP8266 has a single analog input, so it could naively support only a single soil moisture sensor. Along with all my other projects, I upgraded the device to the more modern ESP322 microprocessor. These are more powerful computationally, I’ve found them to have more reliable WiFi, and older versions can be found nearly as inexpensively as the ESP8266. The ESP32 supports a greater number of analog inputs and more digital I/O pins. I used these additional inputs with a slightly larger board to provide connectors for 4 moisture sensors and 4 pumps. The upgraded device can thus monitor and water up to four plants.
In addition to the hardware upgrades, I needed to update the software. I scaled the watering logic to support multiple plants. The web interface also needed improvements for configuring the watering of multiple plants.
Finally, I made sure the interface to the MQTT3 server and Home Assistant4 discovery supported all the plants. With these improvements the device has become much more useful.
Since a single device could now water up to 4 different plants, it made sense to increase the size of the reservoir so that more plants could be watered without constant refills. Because of the way early prototypes detected when the reservoir needed to be refilled, the reservoir was a custom 3D-printed deisgn. Low-water was detected when a “flag” floating on top of the water in the reservoir sank below a given height. The flag was attached to a float, and it’s “pole” ran through the lid of the reservoir. When it fell too low, the flag was no longer detected by an infrared transmit/receive module5 mounted above the EBox on the device lid. In the picture below, this module is in the black box at the top with a black and a clear LED bulb.
The current version of Plant133 uses a simple pre-made float sensor6.
This, along with an aquarium pump per plant, can be attached to a simple 3D-printed structure which can be placed in almost any water container. An example of such a reservoir insert configured for 2 pumps and a float is shown below.
The OpenSCAD model of the insert can be configured for 1-4 pumps.
With this insert, instead of 3D-printing a custom reservoir and lid, I was able to look for larger, inexpensive, nicer looking containers that can simply be bought.
My wife identified the Royal Imports Flower Vase7 from Amazon as a possible candidate. It has a flat base that works for the pump/float insert, it looks reasonably nice, and it has a decent size at 4x4x12 inches or 10x10x30.5 cm.
At around $16 this reservoir is nearly as expensive as all the rest of the parts. But it still isn’t too bad, so it is my current choice. If you have a suggestion for something that might work better, please let me know in the comments below!
In the past year, I’ve made a number of minor adjustments to the PCB design in addition to support for multiple plants. Many of these are me still learning circuit design and layout basics. I’m a bit lucky that earlier versions worked so well.
With these changes and general practice at things like cable assembly, my devices now tend to work reliably after their initial assembly.
I worked to make everything necessary for this project available to other people on GitHub, under the very permissive MIT license. The main repository is https://github.com/chl33/Plant133. This contains:
I welcome suggestions and improvements.
Here is a very approximate estimate for the cost of materials.
Item | Source | Approximate cost |
---|---|---|
Reservoir | Amazon | $16 |
Aquarium pump | AliExpress | $1 (x4) |
Float sensor | Amazon | $2.50 |
Moisture sensor | AliExpress | $0.50 (x4) |
PCB | JLCPBC/PCBWay | $3 |
Components, connectors, and wires | (various) | $10 |
Total | $35-$40 |
I was once worried about having kids since I couldn’t manage to keep my houseplants alive. Fortunately, children are pretty loud so don’t get forgotten as easily. Mine survived their childhood.
With Plant133, I’ve also managed to keep a number of plants surprisingly happy. I have Home Assistant notify my phone when the reservoir needs a refill. This happens about once a week. If we fill the reservoirs before we leave the house, we can leave for a couple weeks and not worry about the plants. I can also remotely monitor that the watering system is working properly if I want to.
As a side effect, I’ve learned a lot and had an excuse for buying a lot of tools.
ESP8266: a low-cost WiFi microchip, with built-in TCP/IP networking software, and microcontroller capability, produced by Espressif Systems. ↩︎
ESP32: a family of microcontrollers made by Espressif Systems. A successor to the ESP8266 microcontroller. ↩︎
The MQTT protocol ( Wikipedia) is useful for IOT (Internet of Things) applications. ↩︎
Home Assistant is a popular Open Source home automation platform. It is the hub for my own smart home, and it is a blast to work with. ↩︎
IR tramsmit/receive module. A simple module often used for line-following and similar in toy robot tasks ( Amazon). ↩︎
Royal Imports Flower Vase ( Amazon). This is what I currently use for a water reservoir for Plant133 plant watering devices. ↩︎
PlatformIO is an open source framework for compiling/uploading embedded software, and managing libraries used by this software. ↩︎
og3
is my C++ utility library for ESP microprocessors, published on
GitHub. ↩︎
OpenSCAD is an open source program which implements a programming language for building 3D models. It is a way to build models using solid modeling primitives. ↩︎