SMART AGRI

Published May 02, 2024
 60 hours to build
 Intermediate

Smart-Agri is an integrated smart farming solution combining hardware and software, optimizing greenhouse conditions for increased productivity and farmer profits amidst climate change. It utilizes sensors and appliances to manage water, nutrients, and temperature, while prioritizing renewable resources like rainwater and solar power.

display image

Components Used

MQ2 Gas Sensor
MQ2 is a gas sensor used for gas leakage detection.
1
ALS PT19 Ambient Light sensor
ALS PT19 is a low cost ambient light sensor that is available in a miniature SMD package.
1
INA169 DC Current Sensor
INA169 DC Current Sensor
1
Turbidity Sensor
Turbidity Sensor
1
DS18B20 Temperature Sensors
DS18B20 Temperature Sensors
1
Limit Switches
Limit Switches Short Hinge 10A Roller
1
Water Pump 12V
Adafruit Accessories Peristaltic Liquid Pump w/tubing
1
Cooling Fan
DC Fans Spot Cool with 120x120x32mm Fan, Terminal for 120VAC, 1 Guard, Adapter 6' Cord
1
DHT11
DHT11 is a single wire digital humidity and temperature sensor, which gives relative humidity in percentage and temperature in degree Celsius.
1
LM2596 STEP DOWN Voltage rgulator
LM2596 STEP-DOWN Voltage regulator
1
Raspberry Pi 3 - Model B
Single Board Computers The factory is currently not accepting orders for this product.
1
LED 5mm
LED 5mm
5
ZMPT101B voltage sensor module
Measuring voltage across load
1
Moisture Sensor
1
Ph-Sensor
1
Rain Sensor
1
Ultrasonic sensor
The ultrasonic sensor measures distance by emitting ultrasonic waves and detecting their reflection, providing accurate proximity data. It's commonly used in obstacle detection and avoidance applications for robots and automation systems.
1
Night Vision camera module
1
8-channel relay module
1
Peltier plate with heat sink
1
LED Lights
Simple colorful LED lights are selected due to their brightness, compactness and cost.
1
Servo
1
Description

With the exponential growth of world population, according to the UN Food and Agriculture Organization, the world will need to produce 70% more food in 2050, shrinking agricultural lands, and depletion of finite natural resources, the need to enhance farm yield has become critical. Limited availability of natural resources such as fresh water and arable land along with slowing yield trends in several staple crops, have further aggravated the problem. Another impeding concern over the farming industry is the shifting structure of agricultural workforce. Moreover, agricultural labour in most of the countries has declined . Still many of the local or rural farmers who are completely depending upon farming as their only income, due to their lack of knowledge and unpredictive climate change, low availability of labour worker pushing them to face huge loss and huge production losses.

 

About SMART-AGRI, Why is it different from others?

 

SMART-AGRI  is a proposal of bringing technology in the field, amid climate change, dwindling resources and increasing population, the global farming industry has come under significant pressure. As the unpredictability intensifies, it’s no surprise that growers are turning to advanced technologies to boost production efficiency and crop resilience. In agriculture, the Internet of Things (IoT) is more present than ever before, and SMART-AGRI(a prototype greenhouse farming) is a stellar example.

SMART-AGRI provides a controlled environment customized to the vegetation needs cultivated inside. Traditionally, micro-climate and agronomic parameters have been recorded in a rather manual and inconsistent manner. There’s a limit to what can be measured, and farming practices are executed on a pre-defined, speculation-based schedule. On the other hand, weather changes throughout the day and “invisible” conditions like open doors or early-stage infection constantly influence the greenhouse environment and threaten to damage crops. 

 

Equipped with modern sensor and communications technologies and appliances, SMART-AGRI automatically capture and deliver the farm information to the farmer 24/7 on the surroundings and crop along with the local outside weather parameters. Collected data is fed into IBM Cloud where analytical algorithms turn it into actionable intelligence to uncover bottlenecks and abnormalities also to detect and predict some informative value depending upon past 10+ years analytics which includes, Crop-Yield, Best crop under that particular condition, Disease checking and pesticides recommendation, Rain prediction, best fertilizer and each of the appliances and conditions can be controlled anytime from anywhere just with the use of our APP, which is further equipped with notification facility to choose among the 7+ parameter which is to be informed and with 2 alarm timing to be set by the farmer, to let the system know when to be informed through SMS notifications.

SMART-AGRI is also equipped with a special water tank to load the ground water when ever needed to save more energy, water. Water nutrients and optimum water temperature is very necessary for the best production of the crops. So we had an automated water heater and cooler with nutrients detection of the water to take care of every little things. Also the farmer can access the past sensors values loaded in the IBM cloud for any reference or knowledge of the farmer. Our system is built with 20+ sensors, 5+ appliances and in Raspberry Pi using Python3 as the coding language and Node-Red services for giving the user with best possible interface with the system further implemented to MIT-APP-INVENTOR.

 

By unlocking massive crop insights, the SMART-AGRI allows growers to minimize labour work, improve efficiency in resource and chemical use while optimizing yield rates.
Main Unique points of SMART-AGRI, it is environmental friendly, low energy consumption using maximum energy from solar power(Natural resources) and rain water, reliable, cost effective and with extra safety and security, running night vision camera 24/7 for surveillance of the greenhouse system directly storing any suspicious moves in the IBM Object Storage for any future use. Most importantly it supports 7+ Local Indian language(more can be implemented) along with English to make it easy for anyone to understand and operate the system.

What's the problem?

Agriculture is one of the professions that is been practiced for decades, but by years passing, the people are losing faith from this because of the lack of productivity and lack of farming knowledge and due to this unpredictable weather because of this rapid climate change. As a result farmer's condition from different parts of the world are getting worse day by day making them to face huge losses due to which they are choosing suicide as their only option. Maximum family farming lacks the knowledge to deal with this climate change and to overcome the issues caused in the plants from different insects and due to lack of nutrients which finally results in their production. Though some of the products which are available focus on huge area basis and also with some limited features, with manuals and operating procedures only found in ENGLISH as the only language, making it very hard for most of the farmers in the world to understand easily.

Proposed Solution

Making a Smart Greenhouse prototype with the latest technology and IBM cloud integration to make the farming condition favourable for healthy production through out the year. It can intelligently monitor and can take actions, eliminating the manual interaction. Many sensors are deployed to measure the environmental parameters and to take action accordingly.

SMART-AGRI contains the following features:-

  • Real-time weather monitoring with WEATHER API.
  • Date when the crop was planted with CLOUDANT DB.
  • Best fertilizer to be used for better and healthy growth with IBM AUTO AI associated with ML model.
  • Crop selection based on the Soil, and current environmental conditions with IBM AUTO AI associated with ML model.
  • Rain fall prediction with IBM AUTO AI associated with ML model.
  • Crop Yield prediction of the particular crop in a particular region with the help of 10 years dataset and IBM AUTO AI associated with ML model.
  • Plant disease Prediction, either the farming plant or other plant selected through the app by the farmer and the way to cure them using IBM VISUAL RECOGNITION.
  • Farmer can choose the information he wants get notified in two desired times among the given 7 parameters using TWILLO.
  • Getting the Sensors value from the greenhouse and to control the appliances such as the Cooler, Heater, LEDs, Roof, Water Pump etc through IBM IOT.
  • Historical data access on desired sensor value using CLOUDANT DB.
  • Storing the Greenhouse plants image taken by the Greenhouse Camera in the OBJECT STORAGE to access for future use and to analyse it.
  • With more than 7+ Indian local languages(more can be implemented) along with English is deployed with IBM WATSON LANGUAGE TRANSLATION API to make it easy for the farmers to understand their farming conditions.
  • Making a user friendly and easy to access UI with the help of NODE RED SERVICES on IBM further implementing it to the MIT-APP-Inventor to make an APP out of it.
  • Live feed coming directly from the Greenhouse to the farmer for extra security and safety.

About the hardware setup

Node Red SetUp:-

Software/Access Requirements

 

Connections:- 

(PART-1)--RaspberryPi(FROM)(PART-1)--MCP3008(TO)(PART-2)--Sensors(FROM)(PART-2)--MCP3008(TO)(PART-3)--RELAY(FROM)(PART-3)--Raspberry Pi(TO)
Pin 1 (3.3V)Pin 16 (VDD)RAIN SENSORPIN 1RELAY-8Pin 38
Pin 1 (3.3V)Pin 15 (VREF)GAS SENSORPin 2RELAY-7Pin 36
Pin 6 (GND)Pin 14 (AGND)MOISTURE SENSORPin 3RELAY-6Pin 37
Pin 23 (SCLK)Pin 13 (CLK)PH SENSORPin 4RELAY-5Pin 35
Pin 21 (MISO)Pin 12 (DOUT)TURBIDITY SENSORPin 5RELAY-4Pin 33
Pin 19 (MOSI)Pin 11 (DIN)VOLTAGE SENSORPin 6RELAY-3Pin 32
Pin 24 (CE0)Pin 10 (CS/SHDN)CURRENT SENSORPin 7RELAY-2Pin 15
Pin 6 (GND)Pin 9 (DGNDLIGHT SENSORPin 0RELAY-1NONE

Development/Code-Setup

Upload the python files to raspberry pi

After uploading change the credentials.py file with your own credential of IBM IoT and Object Storage.

Chnage the Twillo credentials with your own credentials at notification.py

Change the IP in the APP for the live feed with your own Raspberry pi's IP.

Enable the Interface of Raspberry pi for interfacing DS18B20 and Camera

Raspberry Pi Configuration tool >  found in the Preferences menu > Click on the Interfaces tab > click on Enable for the 1-Wire interfac and Camera

 

  • Install the following libraries
sudo pip3 install w1thermsensor


wget https://github.com/doceme/py-spidev/archive/master.zip 
unzip master.zip
cd py-spidev-master
sudo python setup.py install


git clone https://github.com/adafruit/Adafruit_Python_DHT.git
cd Adafruit_Python_DHT
sudo python3 setup.py install

 

  • Now run all the python files

Import the Node-red flow

  • Import the SmartAgri.flow in node-red
  • Change the APIs with yours and you will be ready to use SMART-AGRI.
     

DEMONSTRATION VIDEO:- 
 

Codes

Downloads

project architecture Download
Hardwarehematic Download
Smart Agri Download
Comments
Ad