Plant Pal, Your New Discrete Clock
by minimatter3d in Circuits > Arduino
312 Views, 6 Favorites, 0 Comments
Plant Pal, Your New Discrete Clock
Meet Plant Pal!
A simple and cute smart planter that not only monitors your plant’s health but also acts as a modern timekeeping device on your desk!
Traditional pot plants are large, unsightly and quite rudimentary. I wanted to change this by creating a new, modern version that’s functional and also practical. Something that doesn’t just hold a plant but also holds useful information! Designed with personality and functionality in mind, Plant Pal uses a NodeMCU and an OLED Display to not only display the current time, but also express your plant’s current feelings! It has an integrated temperature and soil-humidity sensor to monitor your plant's health, and a modular 3D-printed body to ensure maximum functionality!
The result is a friendly plant companion that shows the time and even displays statistics about the plant's health.
It's both a planter and a clock, and an adorable one at that!
Supplies
Plant Pal is pretty simple and doesn't require that many components.
What you'll need in total is:
Electronics
- NodeMCU (ESP8266)
- 0.96" or 1.3" I2C OLED Display
- Capacitive Touch Sensor Module
- Soil Moisture Sensor Module
- Temperature sensor (DS18B20)
- Jumper Wires
Tools
- 3D printer
- PLA or PETG filament
- Hot Glue Gun
- Glue Sticks
Mounting
- M4*8mm x 4
- 8mm Magnets
Software
- Arduino IDE or VS Code + Platform IO
- Optionally, Fusion 360, if you’re designing your own planter
- Libraries: Adafruit SSD1306, Adafruit GFX, One Wire
Creating the Planter
I modelled the entire planter in Fusion 360, making sure it was aesthetic and modern.
The key design features were the modular setup with the detachable sensor body and the drip tray at the bottom. I also had drainage holes in the main planter to ensure that there wouldn’t be overwatering.
You can try to model your own Plant Pal or just download my files from the step below!
If you decide to design it yourself, export the STL files once done in Fusion360 and then slice the files for printing!
I printed my parts with no supports except for the electronic casing.
The quality and infill for the parts were standard at 0.2mm and 20% respectively. I increased the wall width for the main pot to around 3 in order to ensure it was completely waterproof and sealed.
Assembly of Electronics
To begin assembly of your Plant Pal, you’ll need to start with its brains or electronics!
First, make sure the 3D printed casing is clean and free from any print defects.
Then, mount the OLED Display, Touch Sensor and Temperature sensor inside the casing using some hot glue.
Make sure to secure the components in place using plentiful amounts of glue. You may also choose to add extra glue over the exposed PCB in order to ensure there are no shorts (like how I did later on), but this step is optional.
Once this is done, we can begin with the wiring!
Note: Make sure to keep the wires short and tidy since they’ll need to fit inside the planter’s front shell.
First, connect the OLED display to the NodeMCU with:
- VCC > 3.3v on MCU
- GND > GND on MCU
- SDA > D2 on MCU
- SCL > D1 on MCU
Once that’s done, wire up the soil moisture sensor and the temperature sensor to power via:
- VCC > 3.3v on MCU
- GND > GND on MCU
Then connect the soil moisture sensor’s analog output to A0 on the NodeMCU.
Once that’s done, connect the temperature sensor to D4 on the MCU board before finally connecting the touch sensor button to D5 on the MCU board!
Then, connect a USB-C cable to the NodeMCU before packing it away inside the casing and sealing it up using four M4 *5mm screws. This will keep the assembly together neatly and protect it from any external elements!
Assembly of Pot
Before we can continue, though, we need to do one last step, which is preparing the Pot body itself.
All it requires is inserting (or gluing) a small magnet into the cutout made for the enclosure.
These magnets will help keep the whole Plant Pal together and make it appear sleeker.
Uploading the Code
Now it’s time to breathe life into your Plant Pal!
- First, connect your NodeMCU to your computer using a USB-C cable
- Open Arduino IDE.
- Download and place all 3 files in this step into one folder.
- Then open the main.ino file within Arduino IDE
- Make sure you have installed the following libraries (via Sketch > Include Library > Manage Libraries):
- Adafruit GFX
- Adafruit SSD1306
- OneWire
- DallasTemperature
- Then, select the correct board and port via:
- Tools > Board
- Tools > Port > COMxx
- Finally, hit upload, and you’ll be done!
Here's a quick overview of the code and what it makes the MCU do.
First, the NodeMCU reads the temperature from the DS18B20 before measuring the humidity from the analog pin.
Then, it calculates the plant’s “health” through some simple addition/subtraction, which dictates the overall mood of Plant Pal’s face!
Afterwards, it displays the current screen, only updating when required and changing when the touch button is pressed.
The code itself is quite simple yet effective!
Assembly
Now we're basically done!
Simply insert the electronics module into the side of the pot, making sure the humidity sensor's prongs enter through their allocated hole.
Then, route the wire from underneath the pot and out the back end, ensuring the final clean look.
Done!
And that's it!
That's all it takes to make a Plant Pal.
To set the current time, simply send your time through serial to the NodeMCU in the format: "xx:xx" (e.g., "12:30" and it will continue to track it!
Pet Pal is more than just a normal planter, though; it's a character that has actual use on tabletops and other setups. It not only tracks time, but it also displays other vital info, making it the perfect next weekend project!
Happy building, and may your plants (and clocks) always stay happy!