Microsoft Farmbeats University community project Imperial College London
We are currently 3rd Year Electrical and Electronic Engineering students at Imperial College London. We worked on this project in collaboration with the Microsoft FarmBeats Engineering Team. You can learn more about each of us through the below Linkedin Profiles. Feel free to message us regarding any questions about the project through Linkedin messaging!
FarmBeats is a venture of Microsoft Research that was launched in 2015 as a prototype for an Internet of Things (IoT) platform for agriculture. Stemming from the concept of Digital Agriculture, it uses technologies such as low-cost sensors, drones, vision, white space, cloud computing and Machine Learning algorithms to combat very little or no-power in farms. Consequently, the FarmBeats platform has not only allowed for real-time seamless data collection from sensors, cameras and drones but also for storage and complex processing within Microsoft’s cloud computing platform, known as Microsoft Azure.
This concept of data-drive farming enables farmers to make effective data-driven decisions about their farms which help improve overall agricultural yield, lower costs, and reduce the impact the environment impact of agricultural production. The International Food Policy Research Institute claims that these data-driven techniques provide for robust data-analytics within the agricultural industry which can boost the farm productivity by as much as 67% while reducing consumption
It is estimated that the global population will rise by 2.2 billion by 2050, thus requiring a 70% increase in the current yield of agriculture. This growing population combined with environmental challenges has exacerbated the current food shortage challenge which makes this an issue of contemporary global significance. Dr. Ranveer Chandra, the Principal Research Scientist of the FarmBeats venture, says that, "Large amounts of data can be captured from the farms and Machine Learning can be used to translate that data into insight for the growers" Finally, key statistic by the Food Security Research Program in the UK is that more than 2 billion people lack vital micronutrients which affects their health and life expectancy. Dr. Chandra says that the FarmBeats product is capable of giving insights to also achieve the growth of highly nutritious food with minimal environmental impact.
The Microsoft FarmBeats student kit is a tool to help enable data-driven farming. Microsoft truly believes that reliable and properly contextualized data coupled with farmer's knowledge and intuition about their farm, can help increase farm productivity and reduce costs. Moreover, the FarmBeats student kit was developed to promote the concept of FarmBeats among students at universities. These kits are easy-to-use solutions that help students learn about precision agriculture and Internet of Things (IoT) technologies. This IoT kit consists of a Raspberry Pi, running Windows 10 IoT Core, with preconfigured Microsoft Azure cloud services with the following sensors:
Grove BME280 Temperature, Humidity and Pressure Sensor
Grove Capacitive Soil Moisture Sensor
Grove Light Sensor v1.2
This kit gives students an opportunity to not only utilize Python programming for IoT devices but also understand Microsoft Azure cloud services. The data from the sensors is brought to life in an online dashboard using Microsoft Azure IoT central which will give students an insight to understand how to improve their productivity, increase yield and save resources.
The FarmBeats University Pilot Community was established as a way for educational institutions and university teams to collaborate on FarmBeats projects for both education and research. This GitHub repository is a one-stop-shop resource to learn about state-of-the-art digital agriculture and precision farming techniques. No prior experience is required.
This project welcomes contributions and suggestions. This project has adopted the Microsoft Open Source Code of Conduct.
So, to give an overview of our project, our aim is to teach undergraduate students, just as ourselves, about IOT and digital agriculture. For this, we’ve created a set of learning resources using the FarmBeats Kit and the Azure cloud computing services.
We’ve designed these resources following certain specifications:
We’ve designed these learning modules in such a way that they start out simple and get more sophisticated along the way, so that the students can build up on the things they learn as they progress through the labs.
In each of the labs, students experiment on familiar agriculture scenarios and utilize several Azure cloud computing services.
We also provide extension project suggestions, so that the students can apply the things they learn in the labs themselves, and hopefully, build even more sophisticated projects.
We are delivering a set of learning resources which comprises of a GitHub repository containing user guides and step-by-step tutorials for the following modules:
Monitor your plant: Here students will learn how to set-up their Raspberry Pi with their sensors and learn how to obtain and view real-time data from the sensors using IoT Hub or a mobile application developed in PowerApps
Water your plant: A more advanced lab where the students will learn how to start processing data and learn how to build products such as automatic irrigation system.
Predict the Weather: In this lab, students will learn how to use Azure Machine Learning. This will help them build a model that will help them predict the probability of rain.
LED Light Grow System: Finally, in this scenario, the light sensor to create an LED grow light system that optimizes the plant growth.
We have chosen the above modules for the following reasons:
In this scenario, students will learn how to create their own application in two different platforms which are: Azure IoT Central Application and PowerApps. These applications will allow the student to visualise the sensor data collected from the sensors configured with their Raspberry Pi. The process of creating application is considerably different according to the platform chosen. It is highly recommended for students to create an application using both Azure IoT central and PowerApps to gain a deeper understanding of Azure services.
Azure IoT Central is an IoT application platform that allows the user to easily interact with the Azure Cloud services. IoT Central has a friendly user interface to monitor plant conditions, create rules, and easily manage several devices. The student will learn how to use a Raspberry Pi, IoT Central, Azure Event Hubs, Azure Stream Analytics and Azure Blob Storage account.
The first step is to create an interface in Azure IoT Central. In this tutorial, students learn how to use this service, from creating a custom application to creating a device template and device in IoT Central. A device is defined using capability models, which define the capabilities of all devices that will use this template. Capability models are consist of three parts:
The environment sensor requires a capability model to be created, with an interface defined for the telemetry values being sent and a view to display these values. After creating the template, a device needs to be created to be able to connect the Raspberry Pi and send data.
The data received by the Azure Iot Central application is then exported to Azure Event Hubs. Azure Event Hubs is a real-time data ingestion service that allows the user to take capture incoming data. This data can be streamed from Azure Event Hubs to a storage account, referred to as Azure Blob Storage. This is done using Azure Stream Analytics.
As mentioned, the Azure Storage Account is used to store all incoming data, ordered by date and time. This allows the student to revisit this data, at any point in time. There are a wide variety of Azure storage services which include file, table and blob. In this case, the students will use blob storage. Azure Blob Storage allows a user to store blobs of unstructured data that can be easily accessed from other Azure services, such as Azure Machine Learning Studio (Scenario 3).
The data from the sensors ingested into Azure Event Hubs has to be streamed into the Azure Blob Storage account using Azure Stream Analytics. This service provides real-time analytics on streams of data, allowing the student to stream data from one service to another. It is easily implemented in Structured Query Language (SQL) and it does not require the student to learn new processing frameworks.
Although, PowerApps is a more complex platform compared to Azure IoT Central, it still allows a user to build an application without having a significant programming experience. PowerApps has a user-friendly interface and allows the student to connect to a wide variety of data sources ranging from Microsoft Excel tables to Microsoft Outlook and Azure Services. Furthermore, the interface created with PowerApps is more customizable and highly compatible with mobile applications.
In this case, the Raspberry Pi sends the data from the sensors to the IoT Hub instead of the Azure IoT Central. The IoT Hub is a platform that enables easy communication between IoT devices. Moreover, it allows the user to have a bidirectional communication with enhanced security. Alternatively, Azure Event Hubs can be used instead of IoT Hub. But the main difference between the two services lies in the fact that Azure Event Hubs can only receive messages, whereas, the IoT Hub can not only receive but also send messages.
In terms of the Azure Storage account, students get an opportunity to explore tables within the service. Tables can store upto petabytes of structured data which can be accessed using a key-value approach where the key should be unique for each element. In this part of the experiment, ‘partitionkey' was set to be the device name and the ‘rowkey' was set as the timestamp. This allows the student to easily filter through the entire table by using either of the keys.
Azure Functions is an event driven server-less compute platform which essentially allows for small blocks of code to be defined. These blocks of code can be triggered by events such as a web request, data changes in storage or events being put into an Azure Event Hub. In this experiment, it is mainly used to get the information from the table. This is done by ‘binding’ the function to the table in the storage account. This function does not require any advanced code and the function will directly obtain the data from the table named ‘data’. his data can be retrieved by the variable ‘messageJSON’ when writing the code inside the function. The ‘connection’ field accesses the ‘AzureWebJobsStorage’ which contains the storage account string.
PowerApps has a great variety of ‘connectors' to import data from sources such as: Microsoft Sharepoint, Microsoft Outlook, Google Mail, Azure Event Hubs, and so on. However, in this tutorial, the student will create their own custom connector to establish communication with the Application Programming Interface (API) in the Azure Functions. This will allow for requests to be customized and the required data to be extracted. Moreover, Microsoft Excel is also used as a connector to import static data regarding information from the sensors about the model or the sensor name.
PowerApps offers a whole range of components, from ‘icons’ to ‘galleries’ and ‘text input’. All this is very widely used in current applications in the market. These tools can be inserted by just dragging them from the insert tab.
The figure above display an example of the interface that students will learn to create. The interface uses icons to navigate between screens. On the other hand, line graphs are used to display the data while the text input is used to insert a search bar. Moreover, galleries are present to choose which sensor data to display and text labels are added to show more detailed information about the measurements. Finally, a timer to refresh the data. Moreover, the student will also gain knowledge about working with collections which is used to store data in PowerApps.
We would like to thank Dr. Christos Bouganis, Reader in Intelligent Systems in the Department of Electrical and Electronic Engineering at Imperial College London, for his invaluable support and continued engagement during the project. We would also like to thank our Industrial Supervisors from Microsoft, Mr. Lee Stott, Mr. Jim Bennett and Ms. Stacey Wood, for their valuable insights and suggestions for our project along with regular meetings. We would also like to express our sincere gratitude towards them for giving us a great opportunity to present our work on the the FarmBeats learning resource to the Microsoft FarmBeats Engineering Team based in Redmond, Washington, U.S.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.