I started this project because I was missing some features on the popular Xiaomi Mi Flora. Those devices, despite being very useful, lack a key point: readability. Every time I wanted to check my plant's health I had to go to their app... With time I learned how to implement them into Home Assistant, receiving the data via Bluetooth on my RPi 4 and plotting the graphs I needed on my custom dashboards...
However, I wanted something more... so I made it...
I started by making a breadboard behaving as a "shield" for the LILYGO TTGO T5 V2.3.1_2.13 Inch E-Paper where I could plug a capacitive soil moisture sensor and two I2C modules for ambient light (MAX44009) and temperature & humidity (BMP280) measurement.
|Smart Plant V0R1 assembled||Smart Plant V0R1 front||Smart Plant V0R1 back|
The breadboard worked so I moved to a customized PCB, this time embedding a 555-based circuit for the capacitive soil moisture sensor and the ambient sensors (light and temperature). On this prototype, I also added a circuit to allow the selective powering of the sensors, with the aim of bringing down the total power consumption after entering the microcontroller into a deep-sleep mode.
|Smart Plant V0R2 assembled||Smart Plant V0R2 front||Smart Plant V0R2 back|
I also added a circuit for directly reading the soil conductivity through two electrodes (similar to what the Mi Flora does), but after testing it I ended up discarding it, for not finding a good solution to the electrolysis on the terminals that happened after some months of usage. I even added stainless steel rivets to cover the exposure of areas that could get affected, but with enough time it also got affected.
Since it wasn't a measurement parameter that I would miss that much, I moved with the rest of the board functionalities working (or rewiring and fixing the errors in order to get them working).
This trial and error path, brought me to the current design the Smart Plant (V1R1).
|Smart Plant V1R1 assembled||Smart Plant V1R1 front||Smart Plant V1R1 back|
On this board, I integrated an ESP32-S module and I upscaled the e-paper from the 2.13" on the TTGO to a more easy-to-read 2.9" display, together with all the sensors integrated and a LiPo charging circuit. But let's analyze each system individually:
This is the brain behind, the microcontroller powering the board. Its IoT capabilities (Bluetooth and WiFi), together with the support for a good suite of GPIO, digital busses like the I2C, and the deep-sleep mode feature makes it the ideal candidate for a solution like this. In addition, the community support with firmware like ESPHome or platforms like Arduino set the decision and since I didn't want to get things more complicated than what I already had, I decided to use directly an ESP32 module.
I chose ESPHome as the main firmware for the Smart Plant, not only because of the direct support for the e-paper panel and the rest of the sensors on board but because the integration into Home Assistant is (almost) immediate.
One of the critical tests asked for this new design was the low power consumption: for this test I configured the board to be awake 10s and into a deep-sleep mode for 1h. The results were pretty good, achieving an average of 450-500μA in deep-sleep mode and a combined consumption of 1mA per hour. This translates into approximately 5-6 weeks of usage for a 1000mAh battery updating the display (and the Home Assistant) each hour.
With the aim of reducing costs and due to the limited space on the board, I decide not to implement a USB-to-UART IC, such as the CP210x or the CH340G, instead, I use an external USB-to-UART device and the rest of firmware updates I do them OTA (Over The Air) with Home Assistant.
The battery management system consists of the LiPo charging circuit and the voltage regulation to provide...Read more »