Академический Документы
Профессиональный Документы
Культура Документы
By
Ganapathy Nallasivan
Rustem Burkhanov
Saken Istamkulov
6 May 2015
Project No. 51
Abstract
This paper explains the premise and results of our Senior Design project - Plant
Watering System. The plant watering system is an autonomous water administration
system designed for small scale gardens and indoor potted plants. It contains 2 sensor
modules that collect real-time environmental data crucial for plant care and sends it to a
central processing hub that decides and administers the water to the plant system. Our
project was successfully completed during the given time and its usability proven on
potted plants. Here we found the system very efficient for usage for plant growing
beginners. Our results on how reliable the system is on actual plants and possible
improvements we discovered is detailed in this paper.
ii
Contents
1. Introduction .............................................................................................................................................. 1
1.1 Statement of Purpose ......................................................................................................................... 1
1.2 Design Changes ................................................................................................................................... 1
1.3 Block diagram...................................................................................................................................... 2
2 Design......................................................................................................................................................... 3
2.1 Soil Moisture Sensor Unit ................................................................................................................... 3
2.1.1 Soil Moisture Sensor .................................................................................................................... 4
2.1.2 XBee transmitter .......................................................................................................................... 4
2.1.3 Power Supply ............................................................................................................................... 5
2.2 Data Collection and Processing Unit ................................................................................................... 5
2.2.1 Humidity/Temperature Sensor .................................................................................................... 6
2.2.2 Light Intensity Sensor ................................................................................................................... 7
2.2.3 Rain Presence Sensor ................................................................................................................... 7
2.2.4 Receiving XBee ............................................................................................................................. 7
2.2.5 Microcontroller ............................................................................................................................ 7
2.2.6 Bluetooth ..................................................................................................................................... 8
2.2.7 Power Supply ............................................................................................................................... 8
2.3 Phone application ............................................................................................................................... 9
2.3.1 Android Application ..................................................................................................................... 9
3. Design Verification .................................................................................................................................. 11
3.1 Sensor verification ............................................................................................................................ 11
3.1.1 Light Sensor ................................................................................................................................ 11
3.1.2 Rain Sensor................................................................................................................................. 11
3.1.3 Soil Moisture Sensor .................................................................................................................. 12
3.2 Android App , Central Processing Hub Verification .......................................................................... 12
4. Costs ........................................................................................................................................................ 13
4.1 Parts .................................................................................................................................................. 13
4.2 Labor ................................................................................................................................................. 14
4.3 Total Cost .......................................................................................................................................... 14
iii
5. Conclusion ............................................................................................................................................... 14
5.1 Accomplishments .............................................................................................................................. 14
5.2 Uncertainties ..................................................................................................................................... 14
5.3 Ethical considerations ....................................................................................................................... 14
5.4 Future work ....................................................................................................................................... 15
References .................................................................................................................................................. 16
Appendix A Requirement and Verification Table ................................................................................... 17
iv
1. Introduction
1.1 Statement of Purpose
Home gardens or indoor plants are significant part of any urban dweller’s life in almost
any country. Individuals who try to grow their own small scale gardens or potted plants
often find it cumbersome to consistently and correctly water the plants for optimal
growth. Hence we set out to create the easiest and smartest autonomous gardening
solution. Our purpose was to create a system that can autonomously administer the
right volume of water to up to 2 plant systems simultaneously with preset time intervals.
The system checks environmental conditions using various sensors to obtain real-time
data and as well as weather forecast from the internet if available, to calculate and
release the needed water from the pump at regular time intervals set by the user.
Flexibility of our system provides for a hassle free experience for most new users.
1
1.3 Block diagram
The final design consists of 2 separate soil moisture sensor modules that send wireless
signal to the execution module that contains of microcontroller, Bluetooth and remaining
sensors as shown in Figure 1.
2
2 Design
3
Figure 3. Soil Moisture Sensor Unit 2 schematic
4
Table 1. XCTU configuration of the transmitting XBee
Parameter Value
DL 0x13
MY 0x27
ID 0xBADD
D0 2
IR 0x14
IT 5
Parameter Value
DL 13
MY 0x26
ID 0xBADD
D1 2
IR 0x14
IT 5
6
2.2.2 Light Intensity Sensor
This sensor provides real time sunlight presence and intensity information directly to the
microcontroller as an analog signal. The sensor is placed strategically on different
points to ensure sunlight level is at optimum levels throughout the day. Sunlight level
readings from throughout the day is another component that is used by the
microcontroller to calculate the volume of water to be pumped into the plant system.
Parameter Value
MY 0x13
DL 0x00
ID 0xBADD
P0 2
P1 2
IU 1
IA 0xFFFF
2.2.5 Microcontroller
We decided to use ATmega168P as our microcontroller. It supports both analog and
digital I/O, as well as serial data transfer. Microcontroller takes is directly connected
to Humidity/Temperature, Light and Rain sensors. It is also connected to the Soil
Moisture Sensor Modules via XBEE transceiver, and to the Android application via the
Bluetooth module. At any given time, the microcontroller records sensor readings,
checks if there are any requests from the phone application, processes them if there are
any, and then decides if plants need to be watered.
Communication with the app is done through a request protocol. Whenever a user
needs to send or receive information about the system, the application sends
corresponding request via Bluetooth. Request is a string with a special character at the
beginning defining the type of request. “!” stands for “Create New Profile”, “?” means
7
“Get Sensor Data”, and “*” means “Check for Warnings”. After receiving a request,
microcontroller processes it according to the request type and responds to the app if
needed. “!” request sets the microcontroller parameters, such as Maximum
Temperature, Maximum Soil Moisture, Minimum Relative Humidity, Water Volume and
Watering Time Interval. Only three of the above mentioned parameters, Maximum Soil
Moisture, Water Volume and Watering Time Interval, are used for watering purposes;
other two, Maximum Temperature and Minimum Relative Humidity are used to warn the
user about critical conditions. Upon receiving the “?” request, microcontroller sends all
sensor data to the application as a single string with a “,” character as a delimiter. And
finally, after receiving the “*” request, microcontroller responds information regarding if
there were any warnings during the execution time. That is, if temperature on site
exceeded the user-set Maximum Temperature at some point of time, microcontroller
would respond with the exact time of this occurrence. The same method applies for air
humidity, except that air humidity would need to become lower than Minimum Relative
Humidity for microcontroller to record this warning.
2.2.6 Bluetooth
This unit allows for the Central Processing Hub to connect over the Bluetooth protocol
to the smartphone and the Android application. The module allows for upto 40 m range
between the smartphone and Central Processing Hub.
8
2.3 Phone application
2.3.1 Android Application
The smartphone application is written for Android-based phones. Communication with
the rest of the plant watering system is done through a request protocol. Whenever a
user needs to send or receive information about the system, the application sends
corresponding request via Bluetooth. Request is a string with a special character at the
beginning defining the type of request. “!” stands for “Create New Profile”, “?” means
“Get Sensor Data”, and “*” means “Check for Warnings”.
Android application will be used by the user to create “profiles” for different plants up to
8 different profiles. The profiles are stored permanently on the phone using a module
called Tiny Database. The application can also be used to view the data collected by
the microcontroller in real time. Also whenever the user sends a request for warnings to
the microcontroller in the central processing hub it receives back the accumulated
warnings that were stored in the microcontroller. The user can enter the needed settings
for each profile which will be used by the microcontroller as reference to process the
sensor data. All the settings data is sent as one concatenated string for better
assurance of data being transferred successfully. The application also has internet
capabilities. If an internet connection is available then it can successfully pull weather
data based on the location it has detected. The application also has preset settings for
some commonly grown plants such as Viola,Rose and a few more. Since the
application works with the Central Processing Hub as a pair the works of this part of the
system could be better understand from a visual flowchart. Figure 5 shows this.
9
Figure 5. Android Application and Remaining system Flow Chart
10
3. Design Verification
11
3.1.3 Soil Moisture Sensor
Soil moisture Sensor has Vcc, GND, Vdo and Vao pins. Different levels of moisture
were applied on the sensor starting from completely dry to completely wet (all in water)
conditions. The testing results are shown in Table 6.
From Table 6 we can observe that output varies from 5.14V to 2.6V, which satisfies our
requirements, because this output range can be used to adjust the watering equation in
the microcontroller code.
12
Table 8. Watering results when light presence and rain presence varied
4. Costs
4.1 Parts
13
4.2 Labor
Table 10. Labor Cost
Name Hourly Rate ($) Total hours invested Total = Rate x Hours x
2.5 ($)
Saken 30 200 15000
Ganapathy 30 200 15000
Rustem 30 200 15000
Total 45000
5. Conclusion
5.1 Accomplishments
We were able to successfully complete every aspect of our project we had initially set
out to do. Our results backed our statement of purpose and we were able to
successfully utilize the system on 2 Viola potted plants for autonomous watering. Most
importantly the Android Application turned out to be very user - friendly and when we
tested on new users they were intuitively use it without any explicit instructions. As our
end user doesn’t necessarily have to have many technically skills this was an important
accomplishment.
5.2 Uncertainties
Due to time constraints we were unable to test the longevity of our system. We tested
for a duration of a week so we are uncertain for how long the sensor modules and
Central Processing Hub would weather outdoor conditions before requiring any form of
human intervention. Even though in theory our components are sealed and prevent any
outdoor elements from damaging the electronics inside this hasn’t been tested for long
periods such as 6 months. Another uncertainty is again the improved plant growth that
this system would provide over normal human watering when tested over durations of
longer than 6 months.
14
5.4 Future work
We believe our system can be successfully implemented in small scale gardens and
urban indoor plants in the future. Inexperienced but enthusiastic plant growers could
use our system as a great introduction into plant growing for a hassle free start.
We could also look into scaling this system to include more sensors modules and
increased range. The bottleneck in our current project was processing power. The
Atmel 328 microprocessor currently used has nearly maxed its capacity so we would
have to look at alternative ways of distributing the processing load.
We could also introduce an artificial lighting source that would help provide the plant
with consistent light intensity levels even when natural lighting sources are not up to
what the user prefers. This would be including some sort of UV light source that could
be complemented with our existing light sensors.
15
References
[1] D-ROBOTICS. DHT11 Humidity & Temperature Sensor. [Online]. Available:
http://www.micropik.com/PDF/dht11.pdf
[6] Institute of Electrical and Electronics Engineers, Inc. (2006). IEEE Code of Ethics.
[online]. Available:
http://www.ieee.org/about/corporate/governance/p7-8.html
16
Appendix A Requirement and Verification Table
Requirements Verification
Checking procedure:
Need: connect oscilloscope probe to
humidity accuracy +/-2%RH (Relative output signal of the sensor
Humidity) check the signal pattern - digital
temperature accuracy +/-0.2% C characteristic signal should be
power supply in the range of 3.3-6V displayed on the screen
The Complete range detection 0 - 100 % alternatively, connect sensor output
of Relative Humidity to Arduino digital inout and write
code to display signal data on the
computer
check outside temperature and
humidity with the thermometer and
check if error is within required
margins
17
2) Soil Moisture Sensor [2] Ensure the following criteria:
This sensor needs to output an analog power indicator LED is on (red)
signal to output real-time soil moisture output is low when humidity
(unit:Water Content) data to exceeds set threshold value
microcontroller.
Checking procedure:
connect oscilloscope probe to
output signal of the sensor
Need: check the signal pattern - analog
Error +/-2.5% wfv (water fraction by characteristic signal should be
volume) displayed on screen
Power supply is set in the range of 3.3- alternatively, connect voltmeter at
5V the output, check how voltage
changes with sensor under
different moisture conditions
measure soil moisture with the
digital detector, check if error is
within required range
18
Rain presence accuracy 90% check the signal pattern - analog
Power supply is in the range 3.3-5V characteristic signal should be
Analog output provides intensity of the displayed on the screen for probe
rain alternatively, connect voltmeter at
the output, check how voltage
changes with sensor under
different moisture conditions
check presence of the rain by
observation, then check if the
sensor detects it in 9 cases out of
10.
7) Microcontroller [4]
Needs: Checking procedure:
Temperature Range(C): - 40 to 125 connect oscilloscope probe to
flexible for outdoor conditions analog output signal of the sensor
19
Operating Voltage Range(V): 2 to 5.5 same analog pattern as in signal
input of the transmitter should be
Program Memory Type: Flash displayed on screen
Timers 2 x 8-bit, 1 x 16-bit is able to connect with Android
phone using Bluetooth
Comparators: 2
20