Getting Started with Grow

Automatic, systematic and hydromatic, Grow is a smart modular monitoring system designed to help you take the best possible care of your plants. It will tell you how well they're hydrated, attract your attention when they need water and, if you want to go a step further, even give them water!

Grow HAT Minis attached to a Pi Zero and a Pi 4, and three Grow moisture sensors

Seeds, soil and software!

In this tutorial, we’ll show you how everything fits together and how get started monitoring your plants using our monitor application, as well as explaining a little bit about how Grow works. We’ll be starting from the absolute basics, so if you’re already familiar with how to setup a Raspberry Pi and install software for HATs you might want to skip the first few sections.

What you’ll need

One of our Grow kits! The base kit of mini HAT and moisture sensors will do if you’d like to monitor your existing plants, or you could pick up one of our chilli or herb starter kits if you’d like to grow your own from scratch.

A Raspberry Pi! We’ll be using a Pi Zero WH in this tutorial as we’ve designed the Grow HAT Mini to fit nicely on top of the Zero footprint, and it has a pre-soldered header so you won’t need to do any soldering yourself. Grow HAT Mini will also work with other Raspberry Pis as long as they have a 40 pin GPIO header (it’s only the very early ones that don’t).

Power supply for Pi. You’ll need a way of powering your Pi - for a Zero we’d recommend this USB micro-B power supply.

MicroSD card, 8GB or greater. We sell ones pre-installed with Raspberry Pi OS here, which will save you a step later on.

Standoffs (Optional) To be extra sure that your Grow Mini HAT stays firmly attached to your Pi Zero, you could use a couple of 10mm M2.5 standoffs to secure the board to your Pi.

Keyboard, mouse, display cables. We’ll be assuming that you’ll be plugging your Pi into a HDMI monitor and keyboard as that’s the easiest way to set everything up (though it’s also possible to set it up ‘headlessly’ from another computer - we’ve got a tutorial for how to do that here). The Pi Zero WH has a mini HDMI display port, so you'll need either a mini HDMI cable or a standard HDMI cable and a mini HDMI adaptor (like the one in our Zero adaptor kit). To plug in a USB keyboard, you'll likely need a micro USB adaptor - there's one of those in our Zero adaptor kit too!

Seeds and soil

If you’re using our Chillies or Herbs kits you’ll need to rehydrate the Cocopress ‘soil’ - it’s worth doing this as your first order of business so that the moisture levels have time to settle down a bit. Stick the three tablets in a watertight container with 100ml of warm water, and leave them there until they’ve sucked it all up. Don’t be tempted to rehydrate the tablets in the plant pots, all the water will escape out of the hole in the bottom (ask us how we know). We had good results leaving our soil overnight before we planted our seeds, as it was a bit on the soggy side when freshly generated. Adding 100ml of water to Cocopress tablets

Adding rehydrated soil to plant pots

When you’re ready to plant the seeds, divide most of the soil between the three pots, sprinkle the seeds on the surface and cover them with a bit more soil. Adding seeds to plant pots

It’s best to put the seeds somewhere warm and light for best results, and once the seedlings are big enough you’ll want to transfer them to some bigger pots - you can carry on monitoring your favourites with Grow though! There’s a space on the back of the Grow moisture sensors for keeping track of what you’ve planted in which pot, we’ve found whiteboard markers work nicely for labelling and are easy to erase.A plant with a handwritten moisture sensor label

How to attach Grow to your Pi

To attach Grow HAT Mini to your Pi, push the female header on Grow down onto the male header on the Raspberry Pi as far as it will go, making sure that you've lined all of the pins up correctly and that it’s the right way round. Powering it up when plugged in to the wrong pins could damage the Pi or the Grow HAT Mini.A Raspberry Pi Zero with a Grow HAT Mini attached

You can unpeel the protective plastic film from the screen using the green tab, or you can leave it on to protect it from errant bits of soil if you prefer.

Connecting the moisture sensors

The moisture sensors come in sets of three, still attached to their sprues. Side cutters are the best way to separate them if you have them, but snapping them by hand along the perforation line will work too. You can tidy up the rough edge with sandpaper or an emery board if you want.Removing the moisture sensors from their sprues

The moisture sensor cables have three wires and connect to the three pin ports S1, S2 and S3 on top of the Grow HAT Mini - the connectors will only go in one way round, so if you’re having trouble plugging them in try rotating the connector and trying it the other way round rather than forcing them. If you ever need to unplug these little JST connectors, we’d recommend holding onto the moulded plastic connector and gently wiggling - don’t pull them out by the wires, as they can sometimes be a bit delicate. Plugging the moisture sensor cables into the upper set of connectors The connectors on the bottom of the HAT (P1, P2 and P3) are squarer and only have two pins. They’re for plugging in 5v devices like pumps - we’ll take a look at those in later tutorials!

For the capacitive moisture sensors to work best as much of them will need to be surrounded by soil as possible, so it’s best to position the sensors a little way in from the edge of the pot and push them in as far as they can go. The Under/Ground line should be at or above the level of the soil, to avoid the components at the top of the sensors coming into contact with water.

Installing the software

For this part of the tutorial, you'll need a micro-SD card that's been set up with the Raspberry Pi OS operating system, and to be connected to Wi-Fi. If you’re flashing the SD card yourself, we’d recommend using the Raspberry Pi Imager tool, which is available for Windows, Mac and Linux - you can download it here and there are detailed instructions here if you need them.

Screenshot of Raspberry Pi imager program

If you're a beginner, it's best to use the full 32-bit desktop version of Raspberry Pi OS as it's a little easier to set up and use and includes all the software dependencies that you'll need.

Once Raspberry Pi OS is booted, you can configure wifi through the menu that appears on first boot or by typing sudo raspi-config in the terminal - the wifi settings are under Network Options>Wireless LAN and you can navigate with the arrow keys and enter. We'd recommend starting with a fresh install of Raspberry Pi OS if you can, but if you you’re using an older image we’d recommend that you run sudo apt update and sudo apt upgrade in the terminal to get everything up to date.

To download and install the Grow software open a terminal (press control-alt-t or find it in the Raspberry Pi menu) and then type the following and press enter.

curl -sSL https://get.pimoroni.com/grow | bash

The installer will download the other software dependencies it needs to work, make some changes to your config.txt file that let your Pi interface with Grow’s hardware and then ask whether you’d like to install the examples - say yes! It will also ask you if you’d like to install the plant monitor as a service - if you answer yes to this it will make the monitor start automatically when the Pi is turned on, which means you don't need to permanently have your display and keyboard plugged in!

Once everything’s installed, type Y to reboot (or sudo reboot ) to reboot your Pi and apply the config changes.

If you're having trouble finding the | (pipe) symbol in the middle of the install command, we made a video on where it might be hiding! If you've found it on your keyboard, but it's coming out as a different symbol you might need to change your keyboard layout to US (sudo raspi-config then Localisation Options > Change Keyboard Layout )

Using the monitor

Once you've rebooted, if everything's gone well you should have a screen that looks something like this (though your lines and bars are likely to be in different places!)

Main screen of Grow HAT Mini UI

You’ll see three bars that correspond to your three moisture sensor channels, the colour and height will show you how hydrated each of your pots is, and the black line will show you at what level the alarm will sound. The button next to the little bell will mute the alarm if it’s going off, the alarm will also auto-mute if the light sensor detects it’s dark (so it shouldn’t chirp away at night!) The > (A button) at the top left will cycle through the channels and show you more information about each one, as well as a little graph showing the moisture levels over time.

Channel view of Grow HAT Mini UI

The % is the current moisture level of your pot, or saturation. The settings button (X button) within the channel menu will take you to a screen where you can alter the moisture level at which the alarm is triggered, or disable the channel altogether. You can also alter the wet and dry points using this screen - more on how those work in the calibration section below!

Channel settings of Grow HAT Mini UI

From the main screen with the three bars, pressing the settings button (X button) will take you to a screen that will let you change global settings, like disabling the alarm and changing up the beep sound.

Global settings of Grow HAT Mini UI

Any of the settings that you change in using the menus in the monitor will be saved in a file on your Pi, which will look something like this:

Screenshot of settings file in Nano text editor

Starting and stopping the service

If you ever need to stop the monitor from running in the background, you can do that with:

sudo systemctl stop grow-monitor.service

If you want to permanently disable it, you can type in the terminal:

sudo systemctl stop grow-monitor.service

sudo systemctl disable grow-monitor.service

Or to re-enable it:

sudo systemctl enable grow-monitor.service

sudo systemctl start grow-monitor.service

If you’re running the monitor as a service and want to edit your settings file directly you can do that with:

cd /etc/default

sudo nano grow

(and ctrl-X to exit Nano when you're done editing). It's a good idea to stop the service before you start editing the settings file, and start it again afterwards.

How the moisture sensors work

Grow's capacitive moisture sensors work using Pulse-Frequency Modulation - they report the moisture level by sending out a regular pattern of on-off electrical pulses, with varying frequency. If you looked at the pattern of pulses with an oscilloscope, you would see a square wave like this:

Diagram showing a high and low frequency square wave

The Pi (via Grow HAT Mini) interprets the frequency of the pulses as a Hz value between about 0 and 30. A smaller number is wetter, and a larger number is drier.

Calibration (important!)

The Hz values that Grow’s sensors report are relative rather than absolute moisture readings, and are likely to vary depending on soil type, pot size, sensor position and ambient conditions. We’ve included some default values for ‘wet points’ and ‘dry points’ - but you’ll likely get better results if you calibrate the sensors by taking your own base readings. Setting your own wet points and dry points will also mean you can tailor your conditions to different types of plants - a cactus will likely have different opinions about what it considers to be ideal soil conditions to a basil seed!

We’d recommend letting your soil dry out to the point where you think it really needs watering, and then setting the ‘dry point’ reading in the channel settings to match. You can then water it to the desired level, and then set the ‘wet point’ reading. You’ve now got an upper and lower limit of what Grow considers to be acceptable soil conditions! How to set Wet Point on Grow Hat Mini In the channel settings you can also change the % at which the alarm tells you it’s time for watering to happen - if you want to wait until everything’s at the minimum acceptable moisture level set your alarm level to 0%, or set it at 20% or 40% if you want a bit of a heads up before everything dries up.

Next steps

We hope that gets you started monitoring your plants with Grow - tweet us @pimoroni and let us know what you’ve been planting! We’ve got another tutorial planned to show you how to take your Grow setup to the next level by incorporating pumps and auto-watering, so keep an eye out for that.

Shopping basket

Need something for this project? You can use the links below to add products to your Pimoroni Shop basket for easy checkout.

Grow Kit
£22.50
Grow Kit + Herb Pack
£30.00
Grow Kit + Chilli Pack
£30.00
Want to checkout or change something? Click here to view your cart.

Tutorial
Beginner
Raspberry Pi, Pi Zero

Hel Gibbons

hel@pimoroni.com
@jankmammal
http://shop.pimoroni.com
Working her way through every job at Pimoroni, currently looking after content and curation. Likes rescuing stuff from skips, and starting revolutions. Pronouns: she/they