Sorry, you need to enable JavaScript to visit this website.

You are here

Azure IoT garden project with Arduino

BY keith coutlemanis 10 November 2020

In this blog, I'll showcase some of the interesting things you can do with the Internet of Things (IoT) and Azure services at home, that could potentially be commercialised in an industrialised environment.

This blog was originally posted here by Keith Coutlemanis, Infrastructure Consultant at Telstra Purple on 02 Jun 2020 as part of a series. See also Part 2 and Part 3.  

An IoT garden project

In my latest project, I used Microsoft IoT in my garden, not only to provide basic monitoring but with scope to take it to the next level. I utilised Azure Machine Learning and Azure Services to create a complex reactive ecosystem controlled through cloud services and voice commands.

The mini-farm environment for this project includes two plots of garden beds: a worm farm and a chicken house. The main goal is for the IoT solution to monitor the environment and control the water and feeding systems for the plants and animals.

IOT Garden Concept

The chicken coup

The small chicken coup for two to four chickens will require automatic watering and feeding systems. The watering system is connected to the mains supply and will refresh the watering outlet of the coup daily.

The feeding system is a 10-litre container with food pellets. The dispensing system is an Auger connected to a servo motor to feed pellets into the feeding tray daily. The level of chicken food in the 10-litre container is monitored through an ultrasonic system measuring the height of the food in the main chamber. The IoT system will monitor for enough food in the main reservoir and alert when it needs attention.

The worm farm

Worms are susceptible to heat and so when it gets too hot in the worm farm, it may impact upon their health. The project calls for monitoring the temperature of the worm farm and to send and record telemetric data to Azure cloud for storage and alerts. If excessive temperatures are measured, then Azure event systems will send instructions to the IoT device to turn on a watering system to cool down and moisten the worm farm to keep the environment cooler.

The garden plot

Typical watering systems on the market today will measure moisture levels and turn on the sprinkler systems without any measurement or logical analysis behind the process.

I wanted to do something upscale, so I created an IoT solution that will send telemetric data to Azure for recording long term statistics for moisture levels at the surface and underground at 10 cm. In addition, it can be used to determine evaporation rates, water usage, fertiliser usage, etc.

Power BI

The IoT device will monitor the environment and send telemetric data to Azure storage. Environmental measurements of temperature, humidity, light levels, soil moisture levels, water flow in LPM are sent every few minutes to Azure IoT HUB for processing.

The statistics are measured for real-time alerts and stored for long-term trend analysis. The evaporation rates and temperature trends are of importance because they reveal soil moisture health and water-retaining ability, which in turn impact plant growth and water usage.

Power BI is used to provide a historical graphical representation of soil moisture and evaporation rates.

Sample Moisture report

Azure machine learning

The IoT device sends a small telemetric message to Azure blob storage every minute. That equates to over 500,000 status updates a year. From all this data, the goal is to determine evaporation deltas and use predictive algorithms to determine the minimum water requirements required in the current environment. The water requirements will change during the hot seasons, milder seasons and plant maturity.

I will use Azure machine learning to model an algorithm to determine evaporation rates and use reinforcement learning to determine the most efficient watering times and watering duration.

The Azure Machine learning service will then send web service commands to the IoT device to control the watering system.

Google IFTT

Just to show off, I have enabled Google Home assistant to turn on and off the watering system via voice commands. "Hey Google, water the garden." The sprinklers will turn on for 10 minutes.

The Office
Figure 1: The farm workspace with IoT solution
 

Above is an image of the solution on the workbench. You can see the water flow meter and water on/off solenoids, batteries and the Arduino MBK NB 1500 IoT device. In Part two, I'll show you how it was put together.

What's next? 

For further reading on this project, and to try it yourself, check out part two – where we'll introduce the hardware used for this project – and part three in this blog series, as well as others on Telstra Purple.

Related Blogs

anonymous's picture

By Daniel Simpson

17/12/21

  • azure
  • microsoft

A code-first approach to digital twins

Find out how to use code-first digital twins with the Telstra Digital Twins library.   ...
anonymous's picture

By Michelle Howie

25/10/21

  • iot
  • arduino

AgTech and sustainable agribusiness

Our GovHack 2021 challege explored how AgTech can improve sustainable agribusiness.  ...
anonymous's picture

By Quinn Tran

25/9/21

  • iot
  • microsoft

Creative projects with Microsoft Azure

Get your creative juices flowing with the latest in computer vision innovation.   ...
anonymous's picture

By Michelle Howie

15/7/21

  • arduino
  • iot

Trigger an SMS alert when a device is dropped

Learn how Arduino can be used to trigger an SMS alert when a device has been dropped.  Autom...
anonymous's picture

By Michelle Howie

15/7/21

  • arduino
  • iot

Get environmental sensor data via SMS

Learn how to set up on-demand SMS updates for your IoT devices.  Potential use cases If y...
anonymous's picture

By Michelle Howie

15/7/21

  • arduino
  • iot

Use SMS to control your IoT device

In this blog, we look at how to use SMS commands from the Telstra Messaging API to control your IoT...
anonymous's picture

By Michelle Howie

2/7/21

  • iot
  • arduino

Changes to our IoT Developer Kit offer

The IoT Marketplace and Developer Kit trial were retired in July 2021.    Where we...
anonymous's picture

By Tim McMahon

2/6/21

  • Telstra Messaging API
  • bushfire

Air quality SMS alerts during bushfire season

I woke up one morning in January 2020 to discover that the air quality in Melbourne had dropped...
anonymous's picture

By Alan Quayle

18/5/21

  • iot
  • REST API

Unlocking the IoT: Telstra Track and Monitor API

As Australia’s longest serving telco, Telstra is expanding their developer program to provide...
anonymous's picture

By Sri Amirthalingam

31/3/21

  • iot
  • regional

Your regional mobile coverage questions answered

When developing an IoT solution for your business, coverage and access to a reliable network is crit...
anonymous's picture

By Michelle Howie

23/12/20

  • TDev
  • documentation

TelstraDev End of Year Wrap: 2020

We made it! Welcome to the end of 2020, may it soon be just a distant memory. Though it wasn’t...
anonymous's picture

By Trent Steenholdt

10/11/20

  • iot
  • azure

A home IoT project using Azure

In this blog series, I'll explan how I used the Internet of Things (IoT) to enable my gate, gara...