Data Driven Business Solutions

We specialise in Data Science and AI solutions for complex engineering and business problems.

Search
  • Phil de Silva

Using IoT to Keep Pot Plants Alive

Updated: May 14, 2020

Introduction


The words human population is currently at 7.8 billion growing annually at a rate of 1.1%.with the current average population increase estimated at 81 million people per year. This and other socio-economic factors are resulting in an increased demand for food and water. It is estimated the demand for food would grow by 59%-98% between 2005 and 2050, and our demands for fresh water to increase by 55% between 2000 and 2050. The world is thirsty for water and every drop wasted counts.


Compounding the issue, the effects of both drought- and flood-stress on plants are well documented. Climate change forecasts around the world predict increasing aridity, more unpredictable and extreme weather and increased stress on carefully engineered food crops. With these changes, ensuring the timely supply of an appropriate quantity of water is a growing challenge.


This blog post describes a small-scale solution to this challenge. It describes the use of soil humidity, atmospheric humidity, and ambient temperature sensors to assist in the care of a pot plant. Whilst the application described here is small, the theory is scalable to nurseries, orchards and farms.


These sensors are used to:


  1. Visualise trajectories of temperature and humidity in the immediate surroundings of the plant.

  2. Trigger alerts when soil humidity drops below a threshold, indicating the need for watering.

  3. Detect when plants have been watered by detecting an increase in soil humidity.

  4. Use machine learning to predict when the plant would be due for its next watering based on given inputs.


This blog post contains high-level details on how items 1-3 are accomplished. Item 4 will be discussed in a follow on blog post.


Solution Summary





Figure-1


  • An Azure IoT MXChip combined with a analogue soil humidity sensor is used to collect and transmit soil humidity, atmospheric humidity and atmospheric temperature.


  • A collection of Azure services are used to read the incoming data, process, store and trigger alerts.


  • PowerBI is used to display the collected data


  • The collected data and events are processed using AI/ML tools to predict when the plant is due to be watered next (future scope).



Build Details


Azure IoT MX Chip

A breakout board is used to connect the soil humidity sensor to the Azure IoT MX chip as per the image below. The sample MX chip code was updated to handle the new sensor and relay other sensor data. The updated code for the IoT chip can be found in my GitHub repository.

Figure-2



Azure Data Pipeline

The Demo pipeline documented in our previous posts (here and here) is used as a starting point to ingest store and process the sensor data. The only change made is to remove any configuration for relaying streaming data into PowerBI.


Figure-3


Alerts

Azure functions were used to send out email alerts when soil humidity was low. Details configuring this function can be found here. An example email alert is shown below.




Figure-4


Data Visualisation Via PowerBI

There is no need for real-time visualisations; PowerBI is used to visualise historical data.

Figure-5



Lessons Learnt


  • The MX chip appears intermittently to lose connection to Azure requiring a restart.

  • Using Stream Analytics to trigger alerts and publish data costs approximately $3 per day. We would like to investigate the option to trigger alerts directly from the MX chip and use stream analytics on a schedule.

83 views0 comments

Recent Posts

See All