Assignment -1 IIOT
Assignment -1 IIOT
(22CIC07)
ASSIGNMENT – 1
1|Page
INTRODUCTION
Objectives
● To develop a reliable soil moisture detection system using
sensors that can accurately measure soil moisture levels in real-
time.
● To create a system that can alert users when the soil moisture
levels fall below or exceed the optimal range.
● To integrate the system with a user-friendly interface that can
display data and provide actionable insights for effective water
management.
● To evaluate the effectiveness of the system in different soil types
and environmental conditions.
Problem Statement
Water is essential for agriculture, and using it wisely is key to
sustainable farming. However, traditional irrigation techniques often
lead to either overwatering or underwatering, both of which can harm
crops and waste valuable water resources. To tackle this issue, there
is a pressing need for a system that can continuously monitor soil
moisture levels and deliver real-time data to inform better irrigation
practices. The proposed soil moisture detection system aims to solve
this problem by ensuring precise water management, which not only
boosts crop health but also helps conserve water.
2|Page
EXISTING SYSYEM
3|Page
PROPOSED PROTOTYPE
4|Page
SENSORS AND COMPONENTS USED
5|Page
Arduino Uno R3
Purpose: The Arduino Uno R3 is a microcontroller board designed to control
various sensors, actuators, and components in a circuit, acting as the central
processing unit for the project.
Function: It reads inputs from sensors (like soil moisture sensors), processes
the data based on programmed instructions, and outputs signals to components
like buzzers or LEDs. It facilitates communication between hardware and
software.
Applications: Widely used in DIY electronics, robotics, IoT devices, and
educational projects for prototyping and automation.
6|Page
Buzzer (1):
Purpose: Provides audible alerts.
Function: Emits sound signals to alert the user when soil moisture levels fall
below or rise above a certain threshold. This helps in making timely irrigation
decisions
Applications: Used in various alert systems, such as alarms, timers, and
notifications.
9V Battery (1):
Purpose: Powers the electronic components.
Function: Supplies the necessary voltage to the microcontroller, sensors, and
other parts of the system. The 9V battery is used for portable or remote setups.
Applications: Commonly used in low-power electronics, remote controls, and
DIY projects.
7|Page
Jumper Wires (4, generic):
Purpose: Connects components on the breadboard or between the breadboard
and microcontroller.
Function: Facilitates the easy connection of components in the circuit. These
wires are used to establish connections for power, ground, and signal lines.
Applications: Widely used in breadboarding, prototyping, and connecting
different parts of a circuit.
8|Page
Applications: Used in a wide range of electronic circuits to control current flow
and protect sensitive components.
9|Page
Function: Used to cover and insulate wires or connections to prevent short
circuits and provide mechanical support. It shrinks when heated, forming a
tight fit around the wires.
Applications: Commonly used in electrical insulation, wire bundling, and
protecting connections from moisture and wear.
10 | P a g e
Specifications and Data Sheets
SparkFun Soil Moisture Sensor (with Screw Terminals):
Operating Voltage: 3.3V - 5V
Output Signal: Analog voltage (0-3.3V or 0-5V)
Measurement Range: Typically from 0% (dry) to 100% (saturated)
Connector Type: Screw terminals for secure connections
Data Sheet: SparkFun Soil Moisture Sensor (Check SparkFun’s
product page for detailed specifications)
Arduino Uno R3:
Microcontroller: ATmega328P
Operating Voltage: 5V
Input Voltage (recommended): 7-12V
Digital I/O Pins: 14 (6 PWM output)
Analog Input Pins: 6
Clock Speed: 16 MHz
Flash Memory: 32 KB (0.5 KB used by bootloader)
SRAM: 2 KB
EEPROM: 1 KB
Male/Female Jumper Wires (6):
Wire Type: Flexible, insulated
Length: Typically 20-30 cm
Connector Type: Male-to-female
Data Sheet: Generic jumper wires generally do not have detailed
data sheets. Specifications can be found on the product
packaging or retailer's page.
Buzzer (1):
Operating Voltage: Typically 5V
Current Consumption: Varies (usually around 20-30 mA)
Sound Output: Audible (varies depending on design)
Data Sheet: Check specific buzzer product details on electronics
retailers' sites or datasheets provided by manufacturers.
9V Battery (1):
Voltage: 9V
Capacity: Varies by brand (typically around 500-600 mAh)
Chemistry: Alkaline or rechargeable (NiMH)
11 | P a g e
Data Sheet: Refer to the battery manufacturer's website or
product packaging for detailed specifications.
Jumper Wires (4, generic):
Wire Type: Flexible, insulated
Length: Typically 20-30 cm
Connector Type: Male-to-male
Data Sheet: Similar to other jumper wires, detailed data sheets
are often not provided. Specifications can be found on product
packaging or retailer's page.
Resistors (3, 220 ohm):
Resistance: 220 ohms
Power Rating: Typically 1/4 watt
Tolerance: ±5% (standard), ±1% (precision)
Data Sheet: General resistor specifications can be found in
component datasheets, which are available from suppliers or
manufacturers. For example, 220 Ohm Resistor Datasheet.
Mini Breadboard (1):
Size: Small (typically 170 tie points)
Dimensions: Varies by model (usually around 8.5 cm x 5.5 cm)
Construction: Plastic with metal contacts for connecting
components
Data Sheet: Detailed specifications are usually found on the
retailer's product page or manufacturer's datasheet.
10 mm Heat Shrink (1):
Diameter: 10 mm (before shrinking)
Shrink Ratio: Typically 2:1 (shrinks to 50% of its original
diameter)
Operating Temperature: Shrinks at around 70°C (160°F)
Data Sheet: Specifications can be found on the product
packaging or from suppliers like TE Connectivity.
9V Battery Clip (1):
Connector Type: Snap-on clips for 9V battery terminals
Wire Type: Typically 22 AWG insulated wire
Data Sheet: Information is usually available from the retailer's
product page or the manufacturer’s datasheet.
12 | P a g e
CIRCUIT DIAGRAM:
13 | P a g e
System Design and Implementation
Hardware Implementation
Power Supply:
The system is powered by a 9V battery, connected to the
microcontroller via a 9V battery clip. The battery provides the
necessary voltage to the microcontroller and all connected
components.
Sensor Integration:
The SparkFun Soil Moisture Sensor is connected to one of the analog
input pins on the microcontroller. The sensor’s screw terminals allow
for a secure connection, and jumper wires are used to connect the
sensor to the breadboard and microcontroller.
Buzzer for Alerts:
14 | P a g e
The buzzer is connected to one of the digital output pins of the
microcontroller. A 220-ohm resistor is placed in series with the buzzer
to limit the current and protect it from damage. The buzzer is
programmed to emit a sound when the soil moisture level is below the
set threshold.
Display Module:
An optional LCD display can be connected to the microcontroller to
display real-time soil moisture readings. The display is connected
using jumper wires, with the necessary pins (e.g., data, power,
ground) linked to the corresponding pins on the microcontroller.
Breadboard Assembly:
A mini breadboard is used to assemble the circuit without soldering,
allowing for easy modifications and troubleshooting. The breadboard
holds the connections for the sensor, buzzer, resistors, and other
components.
Heat Shrink for Insulation:
Heat shrink tubing is used to insulate exposed wires and connections,
preventing short circuits and ensuring the durability of the
connections. The heat shrink is applied to critical areas where wires
are joined.
Software Implementation
Sensor Data Acquisition:
The microcontroller’s software is programmed to continuously read the
analog signal from the soil moisture sensor. The signal is converted
into a digital value representing the soil moisture percentage.
Threshold Monitoring:
The software includes a threshold value for soil moisture. When the
moisture level drops below this threshold, the microcontroller triggers
the buzzer to alert the user.
Data Display:
If an LCD display is used, the software updates the display with real-
time soil moisture readings. The data is refreshed regularly to provide
an accurate view of the soil’s condition.
15 | P a g e
Communication (Optional):
If a communication module (e.g., Wi-Fi or Bluetooth) is integrated, the
software handles the transmission of soil moisture data to a remote
device, such as a smartphone or computer. This allows users to
monitor soil conditions remotely and receive alerts.
Power Management:
The software includes power-saving features to extend the battery life.
For instance, the microcontroller can be programmed to enter a low-
power mode when the soil moisture is within acceptable levels and
wake up periodically to check the sensor.
16 | P a g e
Results and Analysis
Performance of Prototype
The prototype soil moisture sensor performed admirably and showed
some promise on a few key metrics. It showed high accuracy with an
error margin of ±3% range and very good precision, having a standard
deviation value of 0.5%, three repetitions in each case done
independently on two different systems. With fast sensor response
time (settle in 15 s and change quickly respond To moisture changes
within ~10s) the device is suitable for process control applications
where real-time data can be utilized.
In summary, the prototype is highly effective for its intended purpose,
with room for improvement in soil-specific calibration and further
optimization for diverse environmental conditions. Future development
could focus on enhancing versatility and extending battery life to
further increase its practical value in agricultural and environmental
applications.
17 | P a g e
Challenges and Solutions
18 | P a g e
Future Work and Improvements
Suggested Enhancements
Integrating a feature that automatically identifies the soil type
and applies the correct calibration curve, reducing the need for
manual selection.
Connect with Wi-Fi, Bluetooth for real-time alerting and data
logging allowing this solution to be used in other smart
agriculture scenarios.
Use energy harvesting technologies such as solar panels to
increase battery life and better deploy the sensor in ecological
field sites over long deployment cycles.
Creating a cost-reduced variant with essential features for
budget-conscious users, without compromising basic accuracy
and reliability.
Develop the capability to integrate multiple sensors (e.g.,
temperature, humidity, pH) into a single unit for comprehensive
soil health monitoring.
Potential Upgrades
Temperature, humidity, and light sensors can also be integrated
for a more detailed environmental profile along with incoming
soil moisture data.
Add mass memory to store data on board, allowing the sensor to
continue operating while offline and sync once back online.
Leverage machine learning calibration that could learn and
adjust to changing soil conditions throughout a season, reducing
the need for manual recalibration.
Integrate with LoRa or NB-IoT modules to support long-distance,
high-range communication; best suited for vast landscape
agricultural cases.
Develop a mesh network capability that allows multiple sensors
to communicate and relay data, improving coverage across large
fields.
19 | P a g e
Conclusion
Summary of Findings
20 | P a g e
References
21 | P a g e
Appendices
Additional information
Raw data:
Circuit Setup:
22 | P a g e
FLOWCHART OF HOW IT WORKS:
23 | P a g e
Code Listings:
24 | P a g e