Professional Documents
Culture Documents
TRAINING
FPT UNIVERSITY
Capstone Project 2016: Design and Implement The Model of Smart Garden
Acknowledgment
We would like to give a special shout-out to our beloved teacher
and our mentor, Mr Nguyen Duc Loi, for his professional guidance,
his conscientious teachings and his contributive advices during entire
time of this capstone project.
SUMMER 2016
PAGE 1 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table of Contents
Acknowledgment ............................................................................................... 1
Table of Contents ............................................................................................... 2
List of Tables ...................................................................................................... 6
List of Figures ..................................................................................................... 9
A. Report No. 1 Introduction........................................................................ 14
1. Project Information ................................................................................. 14
2. Introduction ............................................................................................. 14
3. Current Situation ..................................................................................... 14
4. Problem Definition .................................................................................. 16
5. Proposed Solution ................................................................................... 17
5.1. Feature functions .............................................................................. 18
5.2. Advantage and Disadvantage ........................................................... 18
6. Functional Requirements ........................................................................ 19
7. Role and Responsibility .......................................................................... 19
B. Report No. 2 Software Project Management Plant ............................... 20
1. Problem Definition .................................................................................. 20
1.1. Name of this Capstone Project ......................................................... 20
1.2. Problem Abstract.............................................................................. 20
1.3. Project Overview.............................................................................. 20
2. Project organization ................................................................................ 29
2.1. Software Process Model................................................................... 29
2.2. Roles and responsibilities................................................................. 30
2.3. Tools and Techniques ...................................................................... 31
3. Project Management Plan ....................................................................... 32
3.1. Software development life cycle ...................................................... 32
3.2. Increment Detail ............................................................................... 34
3.3. Task sheet ......................................................................................... 38
3.4. All Meeting Minutes ........................................................................ 38
4. Coding Convention ................................................................................. 38
C. Report No. 3 Software Requirement Specification................................ 39
SUMMER 2016
PAGE 2 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
1. User Requirement Specification ............................................................. 39
1.1. Model requirements ......................................................................... 39
1.2. Monitoring the status of garden ....................................................... 39
1.3. Response with expected problems ................................................... 39
1.4. Manage the model ............................................................................ 39
1.5. Schedule ........................................................................................... 39
1.6. Consumption and durability ............................................................. 39
1.7. Security ............................................................................................ 39
1.8. Interoperability ................................................................................. 39
2. System Requirement Specification ......................................................... 40
2.1. External Interface Requirement ....................................................... 40
2.2. System Overview Use Case ............................................................. 51
2.3. List of Use Case ............................................................................... 52
3. Software System Attribute ...................................................................... 88
3.1. Usability ........................................................................................... 88
3.2. Reliability ......................................................................................... 88
3.3. Availability....................................................................................... 88
3.4. Security ............................................................................................ 88
3.5. Maintainability ................................................................................. 88
3.6. Portability ......................................................................................... 88
3.7. Performance ..................................................................................... 88
4. Conceptual Diagram ............................................................................... 89
D. Report No. 4 Software Design Description ............................................ 90
1. Design Overview..................................................................................... 90
2. System Architecture Design.................................................................... 91
2.1. Software Architecture Description .................................................. 92
2.2. Hardware Architecture Description ................................................. 93
2.3. Software Hardware Connection Architecture Description ......... 111
3. Component Diagram ............................................................................. 112
3.1. Physical Component Diagram ....................................................... 112
3.2. Logical Component Diagram ......................................................... 113
4. Detailed Description ............................................................................. 114
SUMMER 2016
PAGE 3 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.1. Class Diagram ................................................................................ 114
4.2. Class Diagram Explanation............................................................ 114
4.3. Interaction Diagram ....................................................................... 117
5. Interface................................................................................................. 129
5.1. Component Interface ...................................................................... 129
5.2. User Interface Design..................................................................... 130
6. Database Design .................................................................................... 141
6.1. Entity Relationship Diagram (ERD) .............................................. 141
6.2. Data Dictionary .............................................................................. 142
7. Flowchart............................................................................................... 145
7.1. Add index of sensors to database ................................................... 145
7.2. Control Water Pump through Algorithm ....................................... 146
7.3. Control Light through Algorithm................................................... 147
E. Report No. 5 System Implementation & Test ...................................... 148
1. Introduction ........................................................................................... 148
1.1. Overview ........................................................................................ 148
1.2. Test Approach ................................................................................ 148
2. Database Relationship Diagram ............................................................ 148
2.1. Physiscal Diagram.......................................................................... 148
2.2. Data Dictionary .............................................................................. 149
3. Performance Measures .......................................................................... 152
4. Test plan ................................................................................................ 152
4.1. Features to be tested ....................................................................... 152
4.2. Features not to be tested:................................................................ 154
4.3. Test environment............................................................................ 154
5. System Testing Test Case ..................................................................... 155
5.1. Component Testing ........................................................................ 155
5.2. Integration Test .............................................................................. 172
F. Report No. 6 Software Users Manual .................................................. 177
1. Installation Guide .................................................................................. 177
1.1. Setting up environment .................................................................. 177
1.2. Setting up the environment at server side ...................................... 177
SUMMER 2016
PAGE 4 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
1.3. Setting up the environment at client side ....................................... 183
2. Users Guide.......................................................................................... 186
2.1. Login .............................................................................................. 186
2.2. Show zone ...................................................................................... 187
2.3. Add zone ........................................................................................ 188
2.4. Library info .................................................................................... 189
2.5. Add new plant ................................................................................ 190
2.6. Show plant info .............................................................................. 191
2.7. Update Zone ................................................................................... 192
2.8. Show sensor info ............................................................................ 193
2.9. History sensor ................................................................................ 194
2.10. Show actuator .............................................................................. 195
SUMMER 2016
PAGE 5 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
List of Tables
Table A-1: Role and Responsibility ................................................................ 19
Table B-1: Hardware Requirements - Sub Controller .................................... 26
Table B-2: Hardware Requirement - Main Controller .................................... 26
Table B-3: Hardware Requirements - Mobile Device .................................... 26
Table B-4: Hardware Requirement - Webserver ............................................ 27
Table B-5: Software Requirements of Project Management .......................... 27
Table B-6: Software Requirements of Embedded Development.................... 27
Table B-7: Software Requirement of Software Development ........................ 28
Table B-8: Roles and Responsibilities ............................................................ 30
Table B-9: Tools and Techniques ................................................................... 31
Table B-10: Software development life cycle ................................................ 32
Table B-11: Increment 0: Analysis and Research........................................... 34
Table B-12: Increment 1: Research - Planning - Design ................................ 35
Table B-13: Increment 2: Implementation ...................................................... 36
Table B-14: Increment 3: Merge Implementation - Testing ........................... 36
Table B-15: Increment 4: Deployment ........................................................... 37
Table C-1: Raspberry Pi 3 Hardware Specification ........................................ 41
Table C-2: Comparison of Standard Wireless Network Protocol................... 43
Table C-3: CC1310 Launchpad Specification ................................................ 45
Table C-4: Description of Light Sensor .......................................................... 46
Table C-5: Description of Temperature & Humidity Sensor ......................... 47
Table C-6: Description of Soil Moisture Sensor............................................. 48
Table C-7: Description of Analog pH Meter Module Kit............................... 49
Table C-8: <Guest>Login use case ................................................................. 52
Table C-9: <User> View Zone Use Case ....................................................... 54
Table C-10: <User> Add Zone Use Case ....................................................... 55
Table C-11: <User> Update Zone Use Case................................................... 57
Table C-12: <User> Delete Zone Use Case .................................................... 58
Table C-13: <User> View Library Use Case .................................................. 60
Table C-14: <User> Add Library Use Case ................................................... 61
Table C-15: <User> View Temperature Specification ................................... 63
Table C-16: <User> Get Humidity Specification ........................................... 64
Table C-17: <User> Get Light Index Specification........................................ 65
Table C-18: <User> Get pH Degree Specification ......................................... 66
Table C-19: <User> Get Soil Moisture Specification .................................... 67
Table C-20: <User> Switch On/Off Light Specification ................................ 68
Table C-21: <User> Change Control Mode Specification ............................. 70
Table C-22: <User> Switch On/Off Roof in Automatic Specification .......... 72
Table C-23: <User> Switch On/Off Water in Automatic Specification......... 73
Table C-24: <User> Switch On/Off Misting in Manual Use Case ................. 74
Table C-25: <User> Switch On/Off Roof in Manual Specification ............... 75
SUMMER 2016
PAGE 6 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table C-26: <User> Switch On/Off Water in Manual Specification ............. 76
Table C-27: <User> Switch On/Off Misting in Manual Specification........... 77
Table C-28: <Main Controller> Switch On/Off Light Specification ............. 79
Table C-29: <Main Controller> Switch On/Off Water Specification ............ 80
Table C-30: <Main Controller> Switch On/Off Misting Specification.......... 81
Table C-31: <Main Controller> Switch On/Off Roof Specification .............. 82
Table C-32: <Main Controller> Tracking Ambient Light Specification........ 83
Table C-33: <Main Controller> Tracking Temperature Specification ........... 84
Table C-34: <Main Controller> Tracking Humidity Specification ................ 85
Table C-35: <Main Controller> Tracking pH Degree Specification .............. 86
Table C-36: <Main Controller> Tracking Soil Moisture Specification ......... 87
Table D-1: Detail Description of Raspberry Pi 3............................................ 94
Table D-2: Detail Description of CC1310 LaunchPad in Main Controller .... 96
Table D-3: BH1750 Ouput Pins ...................................................................... 99
Table D-4: HDC1008 Output Pins ................................................................ 101
Table D-5: Soil Moisture Sensor Output Pins .............................................. 103
Table D-6: Module pH Meter Kit Output Pins ............................................. 104
Table D-7: LM2576-ADJ Description .......................................................... 104
Table D-8: Switch Description...................................................................... 106
Table D-9: Tantalum Capacitors Description ............................................... 106
Table D-10: CAP 10F 50V CERM CHIP 0805 SMD Description ............ 107
Table D-11: CAP 100nF 50V CERM CHIP 0805 SMD Description .......... 107
Table D-12: CAP 100nF 50V CERM CHIP 0805 SMD Description .......... 108
Table D-13: USB Female Description .......................................................... 108
Table D-14: RH127 100uH 3A ..................................................................... 109
Table D-15: PC817X2NIP0F ........................................................................ 109
Table D-16: ULN2003A Description ........................................................... 110
Table D-17: SMD 0805 5% Resistor ........................................................... 110
Table D-18: Relay YL303H-S-5VDC Description....................................... 111
Table D-19: Component Dictionary ............................................................. 113
Table D-20: Library Info Explanation .......................................................... 114
Table D-21: Account Explanation ................................................................ 115
Table D-22: User Library Explanation ......................................................... 115
Table D-23: Zone Explanation ...................................................................... 115
Table D-24: Sensor Info Explanation ........................................................... 116
Table D-25: End Devices Explanation.......................................................... 116
Table D-26: Component Interface ................................................................ 129
Table E-1: Hardware Test Plan ..................................................................... 152
Table E-2: Software Test Plan ...................................................................... 154
Table E-3: Test case of ambient light ........................................................... 155
Table E-4: Test case of Temperature and Humidity ..................................... 156
Table E-5: Test case of Soil Moisture Sensor ............................................... 157
Table E-6: Test Case of pH Meter Kit .......................................................... 158
SUMMER 2016
PAGE 7 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table E-7: Test Case of DIO Control End Devices ...................................... 158
Table E-8: Test Case of CC1310 LaunchPad ............................................... 159
Table E-9: Test Case of Raspberry Pi 3 ........................................................ 163
Table E-10: Test Case of Mobile App .......................................................... 164
Table E-11: Test Case of Webserver ............................................................ 166
Table E-12: Test Case Integration Test......................................................... 172
SUMMER 2016
PAGE 8 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
List of Figures
Figure A-1: Overview of Edyn System........................................................... 15
Figure A-2: Overview of Parrot device........................................................... 15
Figure A-3: Wireless Sensor Network in Agriculture .................................... 16
Figure A-4: System Introduction Overview.................................................... 17
Figure B-1: Network Topology Overview ...................................................... 21
Figure B-2: Proposed Solution System Overview .......................................... 22
Figure B-3: Peripheral Block in System ......................................................... 23
Figure B-4: Main Controller in System .......................................................... 23
Figure B-5: Webserver in System ................................................................... 24
Figure B-6: Mobile User in System ................................................................ 24
Figure B-7: 6LoWPAN Mesh Network .......................................................... 25
Figure B-8: Scrum Model ............................................................................... 29
Figure C-1: Raspberry Pi 3 Overview............................................................. 40
Figure C-2: CC1310 LaunchPad Description ................................................. 42
Figure C-3: Ambient Light Sensor.................................................................. 46
Figure C-4: Temperature and Humidity Sensor.............................................. 47
Figure C-5: Soil Moisture Sensor ................................................................... 48
Figure C-6: Platforms of mobile devices ........................................................ 50
Figure C-7: System Overview Use Case......................................................... 51
Figure C-8: <Guest> Login use case............................................................... 52
Figure C-9: <User> Manage Zone Overview Use Case ................................. 53
Figure C-10: <User> View Zone Use Case .................................................... 54
Figure C-11: <User> Add Zone Use Case ...................................................... 55
Figure C-12: <User> Update Zone Use Case ................................................. 57
Figure C-13: <User> Delete Zone Use Case .................................................. 58
Figure C-14: <User> Manage Library Overview Use Case ........................... 59
Figure C-15: <User> View Library Use Case ................................................ 59
Figure C-16: <User> Add Library Use Case .................................................. 61
Figure C-17: <User> View Sensor Status Use Case....................................... 63
Figure C-18: <User> Get Light Use Case....................................................... 63
Figure C-19: <User> Get Humidity Use Case ................................................ 64
Figure C-20: <User> Get Light Index Use Case ............................................ 65
Figure C-21: <User> Get pH Degree Use Case .............................................. 66
Figure C-22: <User> Get Soil Moisture Use Case ......................................... 67
Figure C-23: <User> Control End Devices Overview Use Case ................... 68
Figure C-24: <User> Switch On/Off Light ..................................................... 68
Figure C-25: Change Control Mode Use Case ............................................... 69
Figure C-26: Control Manual Use Case .......................................................... 70
Figure C-27: <User> Change Control Mode Use Case .................................. 70
Figure C-28: <User> Switch On/Off Devices in Automatic Overview Use
Case ................................................................................................................. 71
SUMMER 2016
PAGE 9 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Figure C-29: <User> Switch On/Off Roof in Automatic Use Case ............... 72
Figure C-30: <User> Switch On/Off Water in Automatic Use Case ............. 73
Figure C-31: <User> Switch On/Off Misting in Automatic Use Case ........... 74
Figure C-32: <User> Switch On/Off Devices in Manual Overview Use Case
......................................................................................................................... 75
Figure C-33: <User> Switch On/Off Roof in Manual Use Case .................... 75
Figure C-34: <User> Switch On/Off Water in Manual Use Case .................. 76
Figure C-35: <User> Switch On/Off Misting in Manual Use Case ............... 77
Figure C-36: <Main Controller> Switch On/Off Devices Overview Use Case
......................................................................................................................... 78
Figure C-37: <Main Controller> Switch On/Off Light .................................. 79
Figure C-38: <Main Controller> Switch On/Off Water ................................. 80
Figure C-39: <Main Controller> Switch On/Off Misting .............................. 81
Figure C-40: <Main Controller> Switch On/Off Roof ................................... 82
Figure C-41: <Main Controller> Tracking Sensors Overview Use Case ....... 83
Figure C-42: <Main Controller> Tracking Ambient Light ............................ 83
Figure C-43: <Main Controller> Tracking Temperature ................................ 84
Figure C-44: <Main Controller> Tracking Humidity Use Case ..................... 85
Figure C-45: <Main Controller> Tracking pH Degree Use Case................... 86
Figure C-46: <Main Controller> Tracking Soil Moisture Use Case .............. 87
Figure C-47: Conceptual Diagram .................................................................. 89
Figure D-1: System Architecture Design ........................................................ 91
Figure D-2: Software Architecture Description .............................................. 92
Figure D-3: Hardware Architecture Description ............................................ 93
Figure D-4: Main Controller Detail Design Description ................................ 93
Figure D-5: Raspberry Pi 3 Overview ............................................................ 94
Figure D-6: CC1310 LaunchPad Overview .................................................... 95
Figure D-7: Module BH1750-FVI .................................................................. 99
Figure D-8: BH1750-FVI Block Diagram ...................................................... 99
Figure D-9: BH1750 Flow Chart .................................................................. 100
Figure D-10: Module HDC1008 ................................................................... 100
Figure D-11: HDC1008 Block Diagram ....................................................... 101
Figure D-12: Module Soil Moisture Sensor using LM393 ........................... 102
Figure D-13: Module Soil Moisture Sensor Schematic ................................ 102
Figure D-14: Module DFRobot pH Meter .................................................... 103
Figure D-15: LM2576-ADJ chip .................................................................. 104
Figure D-16: LM2576-ADJ pinout ............................................................... 104
Figure D-17: Diodes Schottky SS34 ............................................................. 105
Figure D-18: Jack DC 002 ............................................................................ 105
Figure D-19: Switch on Shield ...................................................................... 106
Figure D-20: Tantalum Capacitors ............................................................... 106
Figure D-21: CAP 10F 50V CERM CHIP 0805 SMD............................... 107
Figure D-22: CAP 100nF 50V CERM CHIP 0805 SMD ............................. 107
SUMMER 2016
PAGE 10 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Figure D-23: Red Side LED 0805................................................................. 108
Figure D-24: AF180 Female USB-A connector ........................................... 108
Figure D-25: RH127 100uH 3A.................................................................... 109
Figure D-26: PC817X2NIP0F ...................................................................... 109
Figure D-27: ULN2003A .............................................................................. 109
Figure D-28: 220 Ohm 0805 5%................................................................... 110
Figure D-29: 1K Ohm 0805 5% .................................................................... 110
Figure D-30: 3-Pin 128V-5.0 Terminal ........................................................ 110
Figure D-31: 3-Pin 128V-5.0 Terminal ........................................................ 111
Figure D-32: Relay YL303H-S-5VDC ......................................................... 111
Figure D-33: Hardware - Software Connection Architecture Description ... 111
Figure D-34: Physical Component Diagram ................................................. 112
Figure D-35: Logical Component Diagram .................................................. 113
Figure D-36: Class Diagram ......................................................................... 114
Figure D-37: Login Sequence Diagram ........................................................ 117
Figure D-38: Show Zone Sequence Diagram ............................................... 118
Figure D-39: Update Zone Sequence Diagram ............................................. 119
Figure D-40: Add Zone Sequence Diagram ................................................. 120
Figure D-41: Delete Zone Sequence Diagram .............................................. 121
Figure D-42: Show Sensor Sequence Diagram ............................................ 122
Figure D-43: Show History Sensors Sequence Diagram .............................. 123
Figure D-44: Insert Sensor to Database Sequence Diagram......................... 124
Figure D-45: Add New Plant Sequence Diagram ......................................... 125
Figure D-46: Control End Devices Automatic Sequence Diagram .............. 126
Figure D-47: Control End Device Sequence Diagram ................................. 127
Figure D-48: Show End Device Sequence Diagram..................................... 128
Figure D-49: Login Screen Interface ............................................................ 130
Figure D-50: Zone Management Screen ....................................................... 131
Figure D-51: Add Zone Screen ..................................................................... 132
Figure D-52: Choose plant from library Screen ........................................... 133
Figure D-53: Add new plant Screen ............................................................. 134
Figure D-54: Show plant info Screen ........................................................... 135
Figure D-55: Update zone Screen ................................................................. 136
Figure D-56: Show sensor info Screen ......................................................... 138
Figure D-57: History Sensor ......................................................................... 139
Figure D-58: Show Actuator Screen ............................................................. 140
Figure D-59: Entity Relationship Diagram (ERD) ....................................... 141
Figure D-60: Add index of sensors to database Flow Chart ......................... 145
Figure D-61: Control Water Pump through Algorithm Flow Chart ............ 146
Figure D-62: Control Light through Algorithm Flow Chart......................... 147
Figure E-1: Physical Diagram ....................................................................... 148
Figure F-1: Create Environment on Server ................................................... 177
Figure F-2: New Folder in Windows ............................................................ 177
SUMMER 2016
PAGE 11 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Figure F-3: Using TortoiseGit to clone data from Server ............................. 178
Figure F-4: Copy SSH on Web openshift ..................................................... 178
Figure F-5: Paste URL to Clone ................................................................... 179
Figure F-6: Prepare file ".war" ...................................................................... 179
Figure F-7: Copy to folder webapp ............................................................... 179
Figure F-8: Git Commit --> "master" ........................................................... 180
Figure F-9: Fill all information and push Commit ........................................ 181
Figure F-10: Push on Server openshift ......................................................... 181
Figure F-11: Choose branches for master ..................................................... 182
SUMMER 2016
PAGE 12 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Definition
Search Engine Platform for Traveling Information based on
Apache Lucene
Data source Websites contains traveling information used to parse data
Data item General name for end device/ sensor parsed from data source
Keyword
Search keyword of users
Actuators Represent for machines such as pump, pressure, motor
6LoWPAN IPv6 over Low power Wireless Personal Area Networks
Zone
An area where user want to put their garden in.
OS
Operator system
IoT
Internet of Things
CTR
Click-through rate
Users
The un-authenticated users
APP
Application
MCU
Microcontroller
ADC
Analog-to-Digital Conversion
2
IC
Inter-Integrated Circuit Interface
SPI
Serial Peripheral Interface
UART
Universal Asynchronous Receiver/Transmitter
DIO
Direct Input/output
RF
Radio frequency
GPRS
General Packet Radio Service
HTTP
Hypertext Transfer Protocol
RES
Resistor
CAP
Capacitor
DC
Direct current
ADDR
Address
VCC
Positive power supply
GND
Negative power supply
SCL
Serial clock line
SDA
Serial data line
TX
Transmit
RX
Receive
Wi-Fi
Wireless Fidelity
IR
Infrared
IEEE
Institute of Electrical and Electronics Engineers
Ref
Reference
SUMMER 2016
PAGE 13 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2. Introduction
Nowadays, in this country, agricultural land is shrinking by rapid growth of
industry, which accompanies harmful effects for environment and air quality.
Green patches are being replaced by skyscrapers in the city. People are putting
in boxes and far away from nature. Day by day, people who work in office does
not have enough time and space to relax. A small garden around house or
balcony of apartment which not only decorate your house but that also keep
your healthy with fresh air around your place. That is good place to reduce
stress and lighten your mind which cannot be done being inside four walls.
Besides that, there are many reports about the unhealthy side effects found
in foods we eat everyday. Furthermore, large food that is introduced by
chemical to grow faster and use pesticides to prevent loss from being destroyed
by worms. Daily, it is easier and cheaper for a normal Vietnamese family to
find and buy unhealthy foods than try to find organically grown fruits and
vegetables. Therefore, a small garden around your place is a solution, which
not only makes your houses closer to nature, greener, but also can provide a
part of fresh and safe food for your family.
However, a small garden is also need enough land area, time, and effort to
take care. Moreover, not all people have ability to take good care of plants
without experience and knowledge.
We came up with an idea of building a system, which help anybody who
wants to set up a small garden around their house to spend less time and effort
on caring daily. This system can even build in a small area for people live in
small place in city.
3. Current Situation
There are many kinds and styles of garden, which have many differences
kinds systems to take care. According searching on the internet, in Vietnam and
on the world, we found some similar current systems that apply to build a smart
garden. Those systems can help people save time and effort in caring garden.
Here are overview and benefits of its.
SUMMER 2016
PAGE 14 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Similar trade products on the world:
+ Edyn Smart Garden System: This system includes two parts: Edyn
Garden Sensor and Edyn Water Valve. Edyn Garden Sensor will tracks light,
humidity, temperature, soil nutrition and moisture and cross-references
collected data with plant, soil science, and weather databases to recommend
which plants will thrive; monitors continuously and alerts users to changes that
require immediate action. Edyn Water Valve automatically controls existing
water system based on data collected by the Garden Sensor and adapts to
changes in the weather forecast. Edyn app provides information on what plants
that will grow best, the optimal time for planting, and even plant groupings with
the same conditional needs. It can also be used to control the Edyn Water Valve
manually. Advantage: Solar Powered, in addition to rechargeable lithium iron
phosphate battery when not in full sun; Measures ambient temperature,
humidity, light intensity and soil electrical conductivity. Many sensors is just
in one device; Water and fertilizer resistant; Connects to the cloud.
+ Parrot Flower Power: This system also receive indexes from sensors like
light, temperature, analysis fertilizer, and soil moisture. All sensors is
integrated in one device which collects a variety of plant-relevant data
accurately and uses it in conjunction with its excellent database to make plantspecific recommendations. Advantage: Has a huge database about plant (7000
plants).
SUMMER 2016
PAGE 15 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Similar systems in Vietnam:
+ There are similar projects about smart garden in other university. Wireless
sensor networks in agriculture from University of Economic and Industries
in Long An (2013). They build a Wi-Fi station for monitoring and controlling
environmental parameters, such as the environmental parameters (air
temperature, air humidity, light, insects, weeds, etc.) and other parameters
related to soil conditions (soil moisture, pH, etc.). The data are collected, stored,
and transmitted wirelessly to the farmers to handle in server, through which
they can control and take appropriate actions for their farm to increase
production and quality.
4. Problem Definition
According searching and reading documents of current situations, we give
some disadvantage of those above systems if applied.
+ With Edyn Garden System, they connect to Wi-Fi network to send
valuable insights through the corresponding Edyn app. That is a big problem if
the garden has a large area (outside Wi-Fi distance). Price of Edyn is about
100$ without tax which is high with Vietnamese average income for a small
SUMMER 2016
PAGE 16 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
garden. There has not a support and warranty system, so Vietnamese gardener
has not high reliability with this system.
+ With Parrot Flower Power, the device can only transmit data to a
Bluetooth device, meaning have to be close to the device to get any data,
limiting ability to monitor your plant or get alerts on the go.
+ With the current system in the market, we must have paid so much for
using the smart garden and it is not suitable for Viet Nam environment. In
addition, some kind of control application is hard for Vietnamese people.
+ With similar projects, such as Wireless sensor networks in agriculture,
they have a huge device, which is not comfortable with a small garden.
+ With traditional ways of gardener in Vietnam: Measuring equipment,
for temperature, humidity, light and PH degree in the market, have many
different types and individual. Gardener will spend lots of time to get indexes
from these devices manually. It is also difficult to combine these indexes
together to find a solution for taking care of plants. Besides that, plants are
usually influenced by extreme weather events and by gradual climate changes.
With this routine in Vietnameses gardening, people have many things to do if
it is rain too much or dry in a long time.
5. Proposed Solution
The proposed solution is Design and implement the model of smart garden
to combine advantages and solve disadvantages of current systems.
Reference Edyn and Parrot systems, we will combine all sensors in a device
at named nodes, the system will be automatic controlled when indexes change
compare with users indexes defined. Besides that, there is manual mode for
users who want to control the system by themselves.
Webserver
INTERNET
System at home
Modem
Actuator
Devices
Sensors
Agriculture
Gateway/Router
Users Mobile
PAGE 17 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
This system will resolve problems such as limit transmit and control
distance, size of systems or applicable with any area The system will need
more reactive based on indexes and weather condition than just control volume
of water valve. This system can not only using measuring devices automatically
but also combines their indexes to make a better response for controlling water,
fertilize, reminding improving soil, tracking life cycle of plants. This system
has some backup solution when the weather changes. The gardener have less
thing to do, they can manage garden from anywhere outside the home.
DIMOSG system includes a mobile application, a web server, background
process, and hardware device.
5.1. Feature functions
Hardware devices:
+ Users can control and track multiple plants in only one application,
which show plants indexes and environment. Nearly indexes of plants will be
monitoring and updating 24/7. Users can switch control (manual or automatic)
as they want. The part help users can manage the system from anywhere have
Internet.
5.2. Advantage and Disadvantage
Advantages:
PAGE 18 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
6. Functional Requirements
Hardware component:
Full Name
Role
Position
Contact
1 Nguyn c Li
Developer
Leader
sangptse61252@fpt.edu.vn
3 L Vn Php
Developer
Member
phaplvse60608@fpt.edu.vn
Developer
Member
chinhph60147@fpt.edu.vn
5 Hunh Hu Ngh
Developer
Member
nghihhse61055@fpt.edu.vn
SUMMER 2016
PAGE 19 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Gardening is a job, which asks people to spend time and effort for caring.
The gardeners need to track indexes of plants and combine its together to
monitor and give a best way for taking care the garden if they want their
garden grow up better, higher productivity This is not easy even with a
small garden when the gardener have to measure indexes usually; after that
they have to calculate a better plan manually which is fit with measured
indexes. However, as we mentioned above, people who want plant a small
garden around the house, face too much pressure and difference things of
works in a day and that make them have less time to take care a garden day
by day.
As we mentioned above, when people have a small garden around the
house, they need to spend more time and effort to take care it. If they want
a good green garden, and keep the plants healthy, they have many things to
do such as tracking and combine together indexes of plant, calculate a better
plan manually which is fit with measured indexes, estimate when fertilize
and how much weigh is enough, and remind to spray by themselves day by
day. Additionally, changes in the weather are also a difficult problem for
people who do not stay at home all day to handle it.
Our suggestion here is an embedded system, which help the user saving
time and effort in caring garden. It can replace people to do their jobs, for
example:
+ Tracking indexes period time daily.
+ Auto control devices like water pump, misting based on users set up
conditions to save resources of water.
+ Auto response with changes of weather to protect plants in some cases
+ User just needs one device to monitor and control the system from
anywhere in anytime.
Besides, our system must be easy to use and set up when the user want
to extent their garden. The system have to help user manage each zones
kind of plants, it need to store all measured indexes for creating resource
for some research center about agriculture.
1.3. Project Overview
1.3.1. Current Situation
PAGE 20 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
+ Knowledge of garden: lack of information about trees and their indexes.
One tree has many variety indexes in different unit such as light is lux, soil
moisture is present or temperature is degree. It is complex to combine those
indexes together to compute range standard suitable values for each area or
each tree.
+ Endurance in severe weather: the system uses much kind of sensors,
which are communicate with environment (such as water, humidity, or
chemical fertilizers) directly. With our budget as a student, we just do this
project with some cheaper sensors so maybe it will not have a long durable
time.
+ The variety of model: gardener can plant kind of tree in an area or split
them in each potted plant. There are two device relate with soil is pH
sensors and soil moisture. We need a solution to get indexes from two
device in a same soil. If there are many potted plant and much kind of trees,
the system must equipped sensors for each kind. That make cost rise.
1.3.2. The Proposed System
PAGE 21 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
has a RF core or integrated with a RF module, which help communicate
with other module via RF connection. An edge router can be chosen to
connect with MCU to communicate with Webserver via Wi-Fi.
+ We will try to implement a system, which is star network, or mesh
network.
+ We also chosen some cheaper sensors, which just get approximate
values for sending to webserver. The important thing is we can processing
all indexes and combine them together to have a better plan or response
automatically.
+ There are many kinds of sensors in agriculture such as wind, rain, pH
v.v... According researching about other system, the team chose to track
four basic sensors: ambient light, temperature, humidity, pH degree, and
soil moisture.
SUMMER 2016
PAGE 22 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- There are four parts in this model:
1.3.2.1. Peripheral block
SUMMER 2016
PAGE 23 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
1.3.2.3. Webserver
SUMMER 2016
PAGE 24 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
1.3.3. Boundaries of the system
A user who wants to use this system, have to equip enough device
includes:
+ A mobile device run with application installed and internet connected.
+ A model for planting at home with hardware devices (sensors, MCU,
router/gateway, actuator devices).
The complete product includes:
A mobile application for user who can:
+ Monitor system that work automatic or Control system in manual
+ Monitor garden status anytime anywhere have internet connected.
+ Display and update personal plant library with criteria conditions
by themselves.
+ Manage zones of plant based on hardware devices.
A webserver provide data and services for mobile application and
hardware devices. It process and store all users data.
A model of hardware devices includes:
+ Plantation model that made from reused items around the house.
+ Embedded system with packets of sensors and end devices attach
to MCUs, wireless connection between MCUs, and one main
hardware process center (Main Controller) to connect with
Webserver via Internet.
1.3.4. Future plans
PAGE 25 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
1.3.5. Development Environment
1.3.5.1. Hardware requirements
SUMMER 2016
PAGE 26 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- For Webserver
Table B-4: Hardware Requirement - Webserver
Devices
Minimum Requirements Recommended
Tomcat 7 (JBoss EWS
Server
2.0) or higher
MySQL 5.5 or higher
phpMyAdmin 4.0 or
higher
DBMS
- Project management:
Table B-5: Software Requirements of Project Management
Software
Name / Version
Description
Slack Cautionary Tale
Slack brings all
Real-time
2.0.6
communication together in
messaging
Group in Facebook
one place
Microsoft Excel
It's tempting to start a project
plan in Excel because it helps
you quickly list all your
projects, arrange them how
you want them, and even
create something that
Task Plan
resembles a Gantt Chart view
Trello.com
Trellos boards, lists, and
cards enable you to organize
and prioritize your projects in
a fun, flexible and rewarding
way.
A free Git & Mercurial client
Source Control
Source Tree 1.8.3.0
for Windows or Mac
- Embedded Development
Table B-6: Software Requirements of Embedded Development
Software
Name / Version
Description
Windows 7 or above
OS
Linux - Contiki OS 3.0
IAR Workbench
IAR Embedded Workbench
provides a complete C/C++
compiler and debugger tool
IDE
chain that supports over
10,000 MCU devices
Code Composer Studio
SUMMER 2016
PAGE 27 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Schematic
Product design
Corel
- Software Development
Table B-7: Software Requirement of Software Development
Software
Name / Version
Description
Android Studio
The official Android IDE
from Google, your best way
to build Android apps.
Spring Tool Suite
Visual Studio Professional
2012 is a professional-quality
IDE
integrated development
environment that simplifies
the tasks of creating,
debugging, and deploying
software for Windows,
Microsoft Office and the web
SQL Server 2012
Relational database
management system
developed by Microsoft
DBMS
MySQL
MySQL is an open source
relational database
management system.
Star UML
StarUML is one of the most
Modeling tool
popular UML tools in the
world
SUMMER 2016
PAGE 28 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Document tool
OS
Edraw Max
Microsoft Visio 2013
Adobe Photoshop
Microsoft Word
Microsoft Excel
Microsoft Power Point
Window 7 or above
2. Project organization
2.1. Software Process Model
2.1.1. Overall Description
PAGE 29 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.1.2. Reasons for choosing
Full name
Nguyn c Li
SUMMER 2016
Role in Group
Supervisor
Project manager
Responsibilities
Defining business
Supporting in technique issues
Controlling the development process
PAGE 30 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Team leader
BA
Developer
Tester
BA
Phm Hong Chinh Developer
Tester
L Vn Php
BA
Developer
Tester
Hunh Hu Ngh
BA
Developer
Tester
Managing process
Clarifying requirements
Preparing documents and reports
Creating task plan
Reviewing documents and reports
Committing all individual works.
Design and implement hardware.
Researching components, document
Design and implement mobile
application.
Supporting each other.
Test hardware system.
Implement document and reports
Review documents and reports
Committing all individual works
Researching components, document
Implement chart.
Test hardware component.
Implement document and reports
Review documents and reports
Design and implement web server.
Design and implement database.
Modeling system.
Test software system.
Implement document and reports
Review documents and reports.
Test software system.
Design and implement mobile app.
2
3
4
5
SUMMER 2016
Name/Version
IAR Workbench 7.4
Code Composer Studio 6.1.3
SmartRF Studio 7
Flash Programmer 2
OrCAD PCB Editor16.6
Spring Tool Suite
Android Studio 2.1
MySQL Workbench 6.2
Microsoft Office 2013
Microsoft Visio 2013
StarUML 2.7.0
Software Idea Modeler
PAGE 31 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Increment 1:
Research
Planning
Design
SUMMER 2016
Description
- Collect requirement
- Research the same system
- Research tools and
technique
- Research hardware
(sensor, MCU)
- Identify and clarify
requirement
- Define test phase
- Create introduction report
- Create Software project
management plan report
- Create Software
Requirement Specification
report
- Define requirement
- Define performance
measures
- Research giant.
- Research hardware,
sensor
- Connect sensor with
MCU.
Deliverables
Resource
needed
- Introduction report
- Research report
- 7 man-days
- Software project
management plan
- Software
Requirement
Specification
- Connect and transfer
data with hardware.
- Connect and transfer
data with internet
- Connect and transfer
data with mobile
application
- Test report
- 14 mandays
PAGE 32 OF 197
Dependencies
and
Risk
Constrains
- N/A
- Missing requirement
- Unclear scope of
project
- Lack of member
share of understand
- Depend on
introduction
report,
research
reports,
hardware
device
- Lack of Experience.
- Late for shipping
hardware
- Measure is not
exactly
- Test case cannot
cover all cases
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- Research RF connection.
- Research connect MCU
to Internet
- Research Web server
Research
mobile
application
- Design database
- Design test case
Increment 2
- Create Software Design
Implementation Description report
- Implement transfer data
from sensor to MCU and
MCU to server
- Implement control with
algorism in web server and
sent to mobile application
- Implement Web
SERVICES and hardware
get API, controlling water
supplying system.
- Testing hardware transfer
- Design user interface
- Design model of demo
Increment 3
- Create System
Implementation Implementation & Test
(communication report
in system)
- Implement schematic of
Testing
board
- Implement hardware
connects together
SUMMER 2016
- Performance
measures report
- Software Design
Description report
- Mobile application
- Web server and Web
API
- Test report
- Performance
measures report
- 21 mansday
- Depend on
introduction
report,
research
reports,
hardware
- Lack of Experience.
- Measure is not
exactly
- Hardware work not
good
- Test case cannot
cover all cases
- Create System
- 21 mansImplementation & Test day
report
- Board for hardware
- Web server for
control and transfer and
save data
- Depend on
introduction
report,
research
reports,
hardware
- Lack of Experience.
- Measure is not
exactly
- Hardware is not
exactly
- Test case cannot
cover all cases
PAGE 33 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- Implement transfer data
- Mobile Application
with wireless
for control and show
communication
information
- Implement transfer data
- Test report
from mobile application to - Performance
server
measures report
- Implement control water
supplying
- Implement model for
demo
- Test transfer data
- Test control signal from
server to MCU
Increment 4
- Create installation guide
- Installation guide
Deployment
- Create User guide
- User guide
- Integration test
- Integration test report
- Implement modeling
- Modeling garden
garden.
3.2. Increment Detail
3.2.1. Increment 0: Analysis and Research
- 7 mans-day
Description
Meeting with supervisor and get all information about requirement of
systems
Find some current systems all over the world and popular ways in
local
Find out strength and weakness for each current system.
Predict tools and technique for the system based on requirement and
current system.
PAGE 34 OF 197
Author
Sangpt, Chinhph, Phaplv
Chinhph, Phaplv
Sangpt
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- Clarify requirement
- Research hardware
SUMMER 2016
Description
Author
Sangpt
Sangpt
PAGE 35 OF 197
Phaplv, Chinhph
Sangpt, Chinhph
Sangpt, Phaplv
Phaplv
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- Design database
- Design test case
3.2.3. Increment 2: Implementation
Phaplv, Nghihh
Chinhph, Nghihh
Description
Author
Sangpt, Chinhph, Phaplv, Nghihh
Sangpt, Chinhph
Phaplv, Nghihh
Sangpt, Phaplv
Nghihh, Chinhph
Phaplv, Chinhph
Chinhph, Nghihh
SUMMER 2016
Description
Rechecking requirement based on results of
Increment 2. Find out risks and problem of
system.
Fix requirements with supervisor agreement.
PAGE 36 OF 197
Author
Sangpt, Phaplv, Nghihh, Chinhph
Chinhph, Nghihh
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- Redefine performance measures
Sangpt, Phaplv
Chinhph, Nghihh
Sangpt, Chinhph
Description
Create guide of installation.
Create guide for user how to control the
system
Retest all test case in combined system.
Fix bugs.
Deploy system to demo garden model
PAGE 37 OF 197
Author
Chinhph, Nghihh
Chinhph, Nghihh
Chinhph, Nghihh
Sangpt, Phaplv
Sangpt, Phaplv, Chinhph, Nghihh
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
3.3. Task sheet
4. Coding Convention
- C/C++ and Python: Using to develop program on hardware.
- Java: Using to develop Webserver.
- Android: Using to develop mobile application. The coding convention is
base on Java.
Summary:
Naming Conventions:
- Variable name should short yet meaningful. If the name is more than
one word, it must be in mixed case, starting word with a lowercase.
- Constants name should be uppercase with all words separated by
underscores.
- Methods name should be verbs, in mixed case with the first word
lowercase, the first letter of each internal word capitalized.
- Class name should be nouns, in mixed case with the first letter of each
internal word capitalized.
Package and import statements:
- Package statements are the first non-comment line.
- Import statement is after package statement.
Constants
- Numerical constants should not be coded directly.
Variable Assignments:
- Avoid assigning several variable to the same value in a single
statement.
Comments:
- Using /* */ and """ """ for block comments.
- Using // and # for line comments.
Return statements:
- A return statement with a value should not use parentheses.
Using C/C++ coding convention from
https://google.github.io/styleguide/cppguide.html
Using Python coding convention from
https://google.github.io/styleguide/pyguide.html
Using Java coding convention from
http://www.oracle.com/technetwork/java/codeconvtoc-136057.html
Using Android coding convention form
http://source.andoird.com/source/code-style.html
References: Code Conventions for the Java TM Programming Language
SUMMER 2016
PAGE 38 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
All sensors that used in the system have to a long life low power.
All sensors have a great durability when usually contact with water day
by day.
1.7. Security
New end devices can be added to the system and interact with other ones
regardless of manufacturing origin such as sensors, pumps, solenoid valve.
SUMMER 2016
PAGE 39 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
PAGE 40 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table C-1: Raspberry Pi 3 Hardware Specification
Specifications
System on Chip Broadcom BCM2837
1.2GHz Quad-Core ARM Cortex-A53
(SoC)
4x ARM Cortex-A53, 1.2GHz
CPU
Dual Core Video-Core IV Multimedia Co-Processor.
GPU
Provides Open GL ES 2.0, hardware-accelerated
OpenVG, and 1080p30 H.264 high-profile decode.
Capable of 1Gpixel/s, 1.5Gtexel/s or 24GFLOPs
With texture filtering and DMA infrastructure.
1GB LPDDR2 (900 MHz)
RAM
10/100 Ethernet
Networking
Broadcom BCM 43438 chip provide 2.4 GHz
802.11b/g/n wireless LAN
Bluetooth 4.1 Classic, Bluetooth Low Energy
Bluetooth
micro SD
Storage
40 pin header, populated
GPIO
HDMI, 3.5mm analogue audio-video jack
Ports
4 x USB 2.0, Ethernet, Camera
Serial Interface (CSI), Display Serial Interface (DSI)
800mA (4.0W)
Power ratings
5V, 2.5A via Micro USB or GPIO header
Power source
85.60 * 56.5 mm (3.370 x 2.224 in) not including
Size
protruding connectors
45g
Weight
Connectors
Video Output
Audio Output
SUMMER 2016
PAGE 41 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.1.2.2. CC1310 Launchpad
SUMMER 2016
PAGE 42 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table C-2: Comparison of Standard Wireless Network Protocol
Data Rate
RF
802.11
(Wi-Fi)
Bluetooth
11 & 54 Mbits/sec
1 Mbits/s
50-100 meter
10 meters
Ad-hoc, very small
networks
10-100 meters
Ad-hoc, peer to peer,
star, or mesh
868 MHz
Operating
900-928 MHz
Frequency
1 and 2.4 GHz
Low
Complexity
Very low
Power Consumption
(low power is a
(Battery option
design goal)
and life)
128 AES plus
apptication layer
Security
security
Range
Networking
Topology
SUMMER 2016
Point to hub
IR
Wireless
20-40 Kbits/s
115 Kblits/s
4 & 16 Mbitts/s
<10 meters
Point to point
2.4 GHz
800-900 nm
High
High
Low
High
Medium
Low
PAGE 43 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Based on the table, RF is the most suitable choice for this project.
Because the model requires a high-speed data transmission and long
distance, transmission is matched with houses, which have many hidden
corners, or the garden is placed outside far from house. RF help the
model can easy to work in two control modes: Automatic and Manual.
There are many kinds of module RF in Vietnam market, but they are
separate modules. After discussion in team, we decide to order CC1310
Launchpad to implement this project. It is a great starting point for your
Sub-1 GHz wireless Internet of Things (IoT) applications. Powerful
functionality out-of-the box, all I/Os exposed and easy-to-get-started
examples. Because CC1310 device is the first part in a Sub-1-GHz
family of cost-effective, ultralow power wireless MCUs. The CC1310
device combines a flexible, very low power RF transceiver with a
powerful 48-MHz Cortex-M3 microcontroller in a platform supporting
multiple physical layers and RF standards. A dedicated Radio Controller
(Cortex-M0) handles low-level RF protocol commands that are stored in
ROM or RAM, thus ensuring ultralow power and flexibility. The lowpower consumption of the CC1310 device does not come at the expense
of RF performance; the CC1310 device has excellent sensitivity and
robustness (selectivity and blocking) performance. The CC1310 device
is a highly integrated, true single-chip solution incorporating a complete
RF system and an on-chip DC-DC converter. Besides, CC1310
Launchpad also have 12-Bit ADC, 200 k samples/s, 8-Channel Analog
MUX and many interfaces which connect with environment sensors such
as I2C, UART, SPI, I2S. The model can integrated many different
devices and sensors.
SUMMER 2016
PAGE 44 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table C-3: CC1310 Launchpad Specification
Specification
Microcontroller
Powerful ARM Cortex-M3
All Digital Peripheral Pins Can Be Routed to Any
Peripherals
GPIO
12-Bit ADC, 200 k samples/s, 8-Channel Analog
MUX
Interfaces: I2C, UART, SPI, SSI, I2S
Excellent Receiver Sensitivity -124dBm Using
RF section
Long-Range Mode, -110dBm at 50kbps
Excellent Selectivity: 52dB
Excellent Blocking Performance: 90dB
Programmable Output Power up to +14dBm
Single-Ended or Differential RF Interface
Suitable for Systems Targeting Compliance With
Worldwide Radio Frequency Regulations
+ ETSI EN 300 220, EN 303 131, EN 303 204
(Europe)
+ FCC CFR47 Part 15 (US)
+ ARIB STD-T108 (Japan)
Wireless M-Bus and IEEE 802.15.4g PHY
Full-Feature and Low-Cost Development Kits
Tools and
Multiple Reference Designs for Different RF
Development
Configurations
Environment
Packet Sniffer PC Software
Sensor Controller Studio
SmartRF Studio
SmartRF Flash Programmer 2
IAR Embedded Workbench for ARM
Code Composer Studio
315, 433, 470, 500, 779, 868, 915, and 920MHz ISM
Applications
and SRD Systems
Low-Power Wireless Systems With 50kHz to 5MHz Channel Spacing
Wireless Alarm and Security Systems
Industrial Monitoring and Control
Wireless Healthcare Applications
Wireless Sensor Networks
Active RFID
IEEE 802.15.4g, IP-Enabled Smart Objects
(6LoWPAN), Wireless M-Bus, KNX Systems, WiSUN, ZigBee and Proprietary Systems
SUMMER 2016
PAGE 45 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.1.2.3. Sensors
Duty
Specification
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table C-5: Description of Temperature & Humidity Sensor
Temperature & Humidity Sensor
Adafruit HDC1008
Duty
Specification
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table C-6: Description of Soil Moisture Sensor
Soil Moisture Sensor Using LM393 Module
Duty
Specification
SUMMER 2016
PAGE 48 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table C-7: Description of Analog pH Meter Module Kit
Position
Description
Analog pH Meter
Temperature affects the productivity and growth of a plant.
One common effect of the application of water with a high pH,
or of a high soil pH, is chlorosis. The tiny bacteria and other
organisms that inhabit the soil, huge numbers of them in a
teaspoon of soil, are most active at a pH of 6.3 to 6.8, and so the
processes that break down plant waste, such as leaves, are most
active at that level. Peat bogs, for example, have a very acid
environment; act as preservatives for organic matter.
Duty
Specification
PAGE 49 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
control water pump, light, misting machine and fertilizer pump automatic
and user can control that devices and a traction motor in manual mode.
User can plant in different zones, that will be waste if the model setup
a packet of end devices (include two pump, one misting machine and one
light) for each node. Solution is used to control two pumps at main
controller and use two solenoid valves to active at each zone.
2.1.2.5. User Interface Device
The system will applied to variety kinds of garden, small or large garden;
it must satisfied distance communication in a garden. Users need a simple
system which not affect too much garden space so electric wired between
devices, so a wireless system is recommend with Wi-Fi and RF waves.
The device MCU in system has many kinds of protocol such as I2C, SPI,
and UART to communicate with sensors. We recommend use I2C protocol
to control easily and add more sensors to the systems.
SUMMER 2016
PAGE 50 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2. System Overview Use Case
PAGE 51 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3. List of Use Case
2.3.1. <Guest> Login
SUMMER 2016
PAGE 52 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Alternative Scenario:
Step
Actor Action
1
Guest input invalid username
or password
Exceptions:
No
Actor Action
1
Access mobile application
2
Not fill enough fields or
wrong format of textbox
No
Actor Action
1
Access mobile application
2
Fill invalid provided account
information
3
Press Login button
System Response
System show error message.
System Response
Display Login Screen
Display "Username or password
is wrong" message.
System Response
Display Login Screen
Check validation of username
and password
Display "Invalid username or
password" message.
Relationships: - NA
Business Rules:
- After login to system, guest will be redirected to main screen of system.
2.3.2. <User> Manage Zone Overview Use Case
SUMMER 2016
PAGE 53 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.2.1. <User> View Zone Use Case
SUMMER 2016
PAGE 54 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Alternative Scenario 1:
Step
Actor Action
System Response
1
User choose Add button
Navigate to Add Zone
Alternative Scenario 2:
Step
Actor Action
System Response
1
User send command to
Back to Main Screen
backward for choosing
another zone
Exceptions: - N/A
Relationships: - NA
Business Rules:
- User can add new zone while view all zone.
- After view a zone, user can change and update indexes of zone by choose
each index.
2.3.2.2. <User> Add Zone Use Case
PAGE 55 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Main Success Scenario:
Step Actor Action
1
User goes to Add button
2
3
[Alternative 1]
[Alternative 2]
[Alternative 3]
User send command to add a
new zone
Alternative Scenario 1:
Step Actor Action
1
User choose a library
suggestion
Alternative Scenario 2:
Step Actor Action
1
User input a new plant which
has not in library
System Response
Display Add Zone Screen
System request information for new
zone
Zone information:
- Zone Name
- Device Code ( to distinguish
between zones)
Plant information:
- Plant Name
- Plants defined indexes of sensors
- Fertilizer date
Add new zone with input information
of user
System show successful message.
[Exception 1]
[Exception 2]
System Response
Display Library Suggestion
System Response
Add new plant to library with new
information.
Add new zone with new plant
Alternative Scenario 3:
Step Actor Action
System Response
1
User send command to
Clear input information.
backward for choosing another Back to Last Screen
zone
Exceptions:
No Actor Action
System Response
1
User input already exist Device System show warning message to
Coe
check Device Code again.
No Actor Action
System Response
2
User input exist plant name in
System show warning message Plant
library
name already exist.
Relationships: - NA
Business Rules:
- After added zone, information of zone will be stored in database.
- Mobile Application can show all zones, which include new zone.
- Mobile Application wills navigate to new zones screen with input information.
- Hardware will work with scenario that created for new zone.
SUMMER 2016
PAGE 56 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.2.3. <User> Update Zone Use Case
PAGE 57 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Alternative Scenario 1:
Step
Actor Action
System Response
1
User send command to
Clear input information.
backward for choosing
Back to Last Screen
another zone
Exceptions: - N/A
Relationships: - NA
Business Rules:
- After update zone, information of zone will be stored in database.
- Mobile Application can show zone with updated indexes.
- Mobile Application wills navigate to View zones screen with input
information.
- Hardware will work with updated information in scenario.
2.3.2.4. <User> Delete Zone Use Case
PAGE 58 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Main Success Scenario:
Step
Actor Action
1
User goes to Main Screen
2
System Response
Mobile application displays all
zones in system.
Delete zone and information in
database.
System show successful
message.
SUMMER 2016
PAGE 59 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table C-13: <User> View Library Use Case
USE CASE UC06
Use Case No.
UC06
Use Case Version 2.0
Use Case Name View Library
ChinhPH60147
Author
08/06/2016
Normal
Date
Priority
Actor:
- User
Summary:
- User need to understand standard information of plants to manage system
based on indexes of sensors. Library give user recommends information of
tree.
Goal:
- User can understand easily about information of plants, which they do not
need to find in other places outside system.
Triggers:
- NA
Preconditions:
- System must provide information on core database, which join with a
personal database for each user.
Post Conditions:
- Success: User can view list of plants, which is on core database and
personal database.
- Fail: Display a popup message for errors. Log errors to system in case
conflict between personal database and core database.
Main Success Scenario:
Step
Actor Action
System Response
1
Access Library Screen
Get Joined database between
[Alternative 1]
core database and personal
database.
Show list of plants
2
User choose one plant which Navigate to Information of
they want
Plants
[Alternative 1]
Show standard information of
plants
Alternative Scenario 1:
Step
Actor Action
System Response
1
Access Library screen
Get Joined database between
core database and personal
database.
Show list of plants
2
User touch Add button
Navigate to Add new page
SUMMER 2016
PAGE 60 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Exceptions:
No
Actor Action
1
Access Library screen
System Response
Errors from join database or
system
Display errors message
Relationships: - N/A
Business Rules: - Through View Library, User can choose a suggestion
plant for adding to zone.
2.3.3.2. <User> Add Library Use Case
PAGE 61 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- Fail: Display a popup message for errors. Log errors to system in case
conflict between personal database and core database.
Main Success Scenario:
Step
Actor Action
System Response
1
Access Library Screen
Get Joined database between
core database and personal
database.
Show list of plants
2
Touch Add button
Navigate to Add new screen
with fields which ask to input
full data on
3
User fill all fields in screen
4
[Alternative 1]
Insert new data to database.
User touch Add button
Display message Add
successful
Alternative Scenario 1:
Step
Actor Action
System Response
1
User send command to
Clear input information.
backward for choosing
Back to Last Screen
another zone
Exceptions:
No
Actor Action
System Response
1
User inputs exist plant name Display warning message
duplicate plant name.
Relationships: - N/A
Business Rules:
- After add library, user can choose that plant to add a new zone.
- Added information creates a scenario for system work to responseexcepted problems.
SUMMER 2016
PAGE 62 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.4. <User> View Sensor Status Use Case
PAGE 63 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Triggers:
- User chooses a zone to view index.
Preconditions:
- User must logged into the system.
- Temperature sensor must be connected to the system.
Post Conditions:
- Success: User can view index of temperature in a zone.
- Fail: Display a message error
Main Success Scenario:
Step
Actor Action
System Response
1
User choose a zone
Navigate to View Zone Screen
2
User access to temperature
Display index of temperature
sensors tab
index
Alternative Scenario: - N/A
Exceptions: - N/A
Relationships: - N/A
Business Rules: - N/A
2.3.4.2. <User> View Humidity Use Case
PAGE 64 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Preconditions:
- User must logged into the system.
- Humidity sensor must be connected to the system.
Post Conditions:
- Success: User can view index of humidity in a zone.
- Fail: Display a message error
Main Success Scenario:
Step
Actor Action
System Response
1
User choose a zone
Navigate to View Zone Screen
2
User access to humidity
Display index of humidity
sensors tab
index
Alternative Scenario: - N/A
Exceptions: - N/A
Relationships: - N/A
Business Rules: - N/A
2.3.4.3. <User> Get Light Index Use Case
PAGE 65 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- Ambient light sensor must be connected to the system.
Post Conditions:
- Success: User can view index of ambient light in a zone.
- Fail: Display a message error
Main Success Scenario:
Step
Actor Action
System Response
1
User choose a zone
Navigate to View Zone Screen
2
User access to light sensors Display index of ambient light
tab
index
Alternative Scenario: - N/A
Exceptions: - N/A
Relationships: - N/A
Business Rules: - N/A
2.3.4.4. <User> Get pH Degree Use Case
PAGE 66 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- Fail: Display a message error
Main Success Scenario:
Step
Actor Action
1
User choose a zone
2
User access to pH Degree
sensors tab
Alternative Scenario: - N/A
Exceptions: - N/A
Relationships: - N/A
Business Rules: - N/A
System Response
Navigate to View Zone Screen
Display index of pH Degree
index
PAGE 67 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2
SUMMER 2016
PAGE 68 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Actor: - User
Summary:
- This use case allow user to turn on/off light in manual.
Goal:
- Turn on/off light based on command which received on mobile application
Triggers:
- Light is connected to the system.
Preconditions: - N/A
Post Conditions:
- Success: Light is turned on/off.
- Fail: Display a message error.
Main Success Scenario:
Step
Actor Action
System Response
1
User access to a zone
Display indexes of zone
2
User access to Control
Display status of devices in
Device tab
zone
3
Turn on/off light
Light is turned on/off
Alternative Scenario: - N/A
Exceptions: - N/A
Relationships: - N/A
Business Rules: - N/A
2.3.5.2. <User> Change Control Mode Use Case
SUMMER 2016
PAGE 69 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
PAGE 70 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
[Alternative 2]
User send command to
change mode of control in a
node
Alternative Scenario 1:
Step
Actor Action
1
User choose Automatic
mode
Alternative Scenario 2:
Step
Actor Action
1
User choose Manual mode
Exceptions:
Step
Actor Action
System Response
1
User change control mode
Reload status of mode control
unsuccessful
to the last state on database.
Relationships: N/A
Business Rules:
- After change to Automatic, the system will work based on indexes of
sensors through algorithm.
- After change to Manual, the system still receive index from sensors but
does not use algorithm to control end devices.
2.3.5.3. <User> Switch On/Off Devices Automatic Overview Use Case
PAGE 71 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
<User> Switch On/Off Roof in Automatic Use Case
PAGE 72 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
<User> Switch On/Off Water in Automatic Use Case
PAGE 73 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
<User> Switch On/Off Water in Automatic Use Case
PAGE 74 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.5.4. <User> Switch On/Off Devices Manual Overview Use Case
Figure C-32: <User> Switch On/Off Devices in Manual Overview Use Case
<User> Switch On/Off Roof in Manual Use Case
PAGE 75 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Goal: - User control roof device directly.
Triggers: - Manual mode is enabled.
Preconditions: - Algorithm is disabled.
Post Conditions:
- Success: Switch on/off roof device successful.
- Fail: Display an error message.
Main Success Scenario:
Step
Actor Action
System Response
1
User sends command to
Change status of roof device.
control roof device.
Update status to database.
Alternative Scenario: - N/A
Exceptions: - N/A
Relationships: - N/A
Business Rules: - N/A
<User> Switch On/Off Roof in Manual Use Case
PAGE 76 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Triggers:
- Manual mode is enabled.
Preconditions:
- Algorithm is disabled.
Post Conditions:
- Success: Switch on/off water device successful.
- Fail: Display an error message.
Main Success Scenario:
Step
Actor Action
System Response
1
User sends command to
Change status of roof device.
control roof device.
Update status to database.
Alternative Scenario: - N/A
Exceptions: - N/A
Relationships: - N/A
Business Rules: - N/A
<User> Switch On/Off Misting in Manual Use Case
PAGE 77 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Triggers:
- Manual mode is enabled.
Preconditions:
- Algorithm is disabled.
Post Conditions:
- Success: Switch on/off misting device successful.
- Fail: Display an error message.
Main Success Scenario:
Step
Actor Action
System Response
1
User sends command to
Change status of misting
control misting device.
device.
Update status to database.
Alternative Scenario: - N/A
Exceptions: - N/A
Relationships: - N/A
Business Rules: - N/A
2.3.6. <Main Controller > Switch On/Off Devices Overview Use Case
Figure C-36: <Main Controller> Switch On/Off Devices Overview Use Case
SUMMER 2016
PAGE 78 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.6.1. <Main Controller> Switch On/Off Light Use Case
PAGE 79 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.6.2. <Main Controller> Switch On/Off Water Use Case
PAGE 80 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.6.3. <Main Controller> Switch On/Off Misting Use Case
SUMMER 2016
PAGE 81 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.6.4. <Main Controller> Switch On/Off Roof Use Case
PAGE 82 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.7. <Main Controller > Tracking Sensors Overview Use Case
PAGE 83 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- Success: Tracking ambient light successful.
- Fail: Try to get light again.
Main Success Scenario:
Step
Actor Action
System Response
1
Send ambient light to
Receive index of light.
system
Insert to database.
Put index into algorithm to
control roof
Alternative Scenario: - N/A
Exceptions: - N/A
Relationships: - N/A
Business Rules: - N/A
2.3.7.2. <Main Controller> Tracking Temperature Use Case
PAGE 84 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.7.3. <Main Controller> Tracking Humidity Use Case
System Response
Receive index of humidity.
Insert to database.
Put index into algorithm to
control misting.
SUMMER 2016
PAGE 85 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.7.4. <Main Controller> Tracking pH Degree Use Case
SUMMER 2016
PAGE 86 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3.7.5. <Main Controller> Tracking Soil Moisture Use Case
SUMMER 2016
PAGE 87 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
The system is expected to apply for garden of users who has a garden in
home but they do not have enough time to take care or tracking usually.
There are many plant indexes which gardener are tracking to get higher
productivity in agriculture but the system has some basic sensors which can
help users keep plants live and limit harmful weather with their garden.
System provides friendly GUI for users on their mobile, which is closely
with people in nowadays.
3.2. Reliability
The server shall be working 24/7. When the system goes in undermaintenance, the page or application will display message "System is
maintaining at the moment. Please check again later". Current system will
work directly with index from sensors.
3.4. Security
All code shall be fully documented. All program files shall include
comments concerning authorship and date of last change.
The code shall be modular to permit future modifications.
3.6. Portability
SUMMER 2016
PAGE 88 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4. Conceptual Diagram
SUMMER 2016
PAGE 89 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
PAGE 90 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
PAGE 91 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.1. Software Architecture Description
SUMMER 2016
PAGE 92 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2. Hardware Architecture Description
SUMMER 2016
PAGE 93 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2.1.1. Raspberry Pi 3
Power ratings
800mA (4.0W)
Power source
Size
Weight
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2.1.2. CC1310 Launchpad
SUMMER 2016
PAGE 95 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Detail Specifications: Here are functions that used in Main Controller.
Table D-2: Detail Description of CC1310 LaunchPad in Main Controller
Specifications
Microcontroller ARM Cortex M3 48 MHz
128 KB Flash + 128 KB ROM
Memory
20 + 2 + 8 KB SRAM
IEEE 802.15.4g/e proprietary Sub-1 GHz radio
Wireless
Protocol
Broadcom BCM 43438 chip to provide 2.4 GHz
Networking
802.11b/g/n wireless LAN
Wide Supply Voltage Range: 1.8 to 3.8 V
Low Power
Active-Mode RX: 5.5 mA
Active-Mode TX at +10 dBm: 12.9 mA
Active-Mode MCU 48 MHz Running Coremark:
2.5 mA (51 A/MHz)
Active-Mode MCU: 48.5 CoreMark/mA
Active-Mode Sensor Controller at 24 MHz:
0.4 mA + 8.2 A/MHz
Sensor Controller, One Wake Up Every Second
Performing One 12-Bit ADC Sampling: 0.85 A
Standby: 0.6 A (RTC Running and RAM and
CPU Retention)
Shutdown: 185 nA (Wakeup on External Events)
Excellent Receiver Sensitivity 124 dBm Using
RF Section
Long-Range Mode, 110 dBm at 50 kbps
Excellent Selectivity: 52 dB
Excellent Blocking Performance: 90 dB
Programmable Output Power up to +14 dBm
Single-Ended or Differential RF Interface
Suitable for Systems Targeting Compliance With
Worldwide Radio Frequency Regulations
ETSI EN 300 220, EN 303 131,
EN 303 204 (Europe)
FCC CFR47 Part 15 (US)
ARIB STD-T108 (Japan)
Wireless M-Bus and IEEE 802.15.4g PHY
Power source 5V, 0.5A - 3A via Micro USB or DIO pin
SUMMER 2016
PAGE 96 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2.2. Sub Controller Detail Design Description
PAGE 97 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Low Power
RF Section
Power source
SUMMER 2016
Any GPIO
Four General-Purpose Timer Modules
(Eight 16-Bit or Four 32-Bit Timers, PWM Each)
12-Bit ADC, 200 k samples/s, 8-Channel Analog
MUX
Continuous Time Comparator
Ultralow Power Clocked Comparator
Programmable Current Source
UART - 2 SSI (SPI, MICROWIRE, TI)
I2C - I2S
Real-Time Clock (RTC)
AES-128 Security Module
True Random Number Generator (TRNG)
Support for Eight Capacitive Sensing Buttons
Integrated Temperature Sensor
Wide Supply Voltage Range: 1.8 to 3.8 V
Active-Mode RX: 5.5 mA
Active-Mode TX at +10 dBm: 12.9 mA
Active-Mode MCU 48 MHz Running Coremark:
2.5 mA (51 A/MHz)
Active-Mode MCU: 48.5 CoreMark/mA
Active-Mode Sensor Controller at 24 MHz:
0.4 mA + 8.2 A/MHz
Sensor Controller, One Wake Up Every Second
Performing One 12-Bit ADC Sampling: 0.85 A
Standby: 0.6 A (RTC Running and RAM and
CPU Retention)
Shutdown: 185 nA (Wakeup on External Events)
Excellent Receiver Sensitivity 124 dBm Using
Long-Range Mode, 110 dBm at 50 kbps
Excellent Selectivity: 52 dB
Excellent Blocking Performance: 90 dB
Programmable Output Power up to +14 dBm
Single-Ended or Differential RF Interface
Suitable for Systems Targeting Compliance With
Worldwide Radio Frequency Regulations
ETSI EN 300 220, EN 303 131,
EN 303 204 (Europe)
FCC CFR47 Part 15 (US)
ARIB STD-T108 (Japan)
Wireless M-Bus and IEEE 802.15.4g PHY
5V, 0.5A - 3A via Micro USB or DIO pin
PAGE 98 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2.2.2. Ambient Light Sensor
PAGE 99 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Specification:
+ Block diagram
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2.2.4. Soil Moisture Sensor using LM393
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
No.
1
2
3
4
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Specification:
- Module Power: 5.00V
- Module Size: 43mmx32mm
- Measuring Range: 0-14PH
- Measuring Temperature: 0-60
- Accuracy: 0.1pH (25 )
- Response Time: 1min
- PH Sensor with BNC Connector
- PH2.0 Interface (3-foot patch)
- Gain Adjustment Potentiometer
- Power Indicator LED
Table D-6: Module pH Meter Kit Output Pins
No.
Name
I/O
Description
1 VCC
5V
2 GND
Ground
4 AO
O Analog value output connector
2.2.3. Shield Power Supplier and Controller
2.2.3.1. DC Switching Regulators
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
40V
3A
500mV @ 3A
Fast Recovery =< 500ns, > 200mA
(Io)
500A @ 40V
Speed
Current - Reverse
2.2.3.3. JACK DC 002
Description
Socket
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2.3.4. SWITCH MSS-22D18
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2.3.6. Ceramic Capacitor 0805
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2.3.7. Red Side LED 0805
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2.3.9. Power inductors
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Table D-16: ULN2003A Description
Description
ULN2003A
Current (Single Output) 500-mA-Rated Collector
High-Voltage Outputs
50 V
Inputs
Compatible With Various Types of Logic
supply voltages
6 V to 15 V.
Applications
Relay-Driver Applications
2.2.3.12. SMD 0805 5% Resistor
Description
Number of pin
voltage
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
current
Contact resistance
Pin diameter
Pitch
10 A
20 milliohm
1.1 mm
5 mm
Figure D-31: 3-Pin 128V-5.0 Terminal
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
3. Component Diagram
3.1. Physical Component Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
3.2. Logical Component Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4. Detailed Description
4.1. Class Diagram
Type
Int
String
String
Float
Float
Float
Float
Float
Float
Float
Float
Float
Visibility
Private
Private
Private
Private
Private
Private
Private
Private
Private
Private
Private
Private
Description
Unique identifier of a plant in library
Plant of name
Type of plant
High threshold of pH degree
Low threshold of pH degree
High threshold of light intensity
Low threshold of light intensity
High threshold of humidity
Low threshold of humidity
High threshold of temperature
Low threshold of temperature
High threshold of soil moisture
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Float
libLowSoilMoisture
Private
4.2.2. Account
Type
String
String
String
String
String
Integer
Type
boolean
void
Visibility
Private
Private
Private
Private
Private
Private
Visibility
Private
Private
Description
Unique username for each user
Password of User
Full Name of User
Role of User
Email of User
Phone of User
Description
Check username and password
Get username of user
Type
Int
Visibility
Private
username
userPlantName
userTypePlan
userHighPH
userLowPH
userHighLight
userLowLight
userHighHumidity
userLowHumidity
userHighTemperature
userLowTemperature
userHighSoilMoisture
userLowSoilMoisture
userFertilizeDate
String
String
String
Float
Float
Float
Float
Float
Float
Float
Float
Float
Float
Datetime
Private
Private
Private
Private
Private
Private
Private
Private
Private
Private
Private
Private
Private
Private
userLifeCycleOfPlant
Method
insertUserLibrary
updateUserLibrary
deleteUserLibrary
getUserLibrary
getListUserLibrary
Int
Type
void
void
void
Library
List
Private
Visibility
Private
Private
Private
Private
Private
Description
Unique identifier of a plant which user
define in user library
User who define a plant
Name of plant which user define
Type of plant which user define
High threshold of pH degree
Low threshold of pH degree
High threshold of light intensity
Low threshold of light intensity
High threshold of humidity
Low threshold of humidity
High threshold of temperature
Low threshold of temperature
High threshold of soil moisture
Low threshold of soil moisture
Date of Fertilize Date which user
define
Life Cycle of a plant
Description
Insert new plant to Library Info
Update a plant in Library Info
Delete a plant in Library Info
Get ID of a plant in Library Info
Get List of plant from Library Info
4.2.4. Zone
Type
Int
String
Visibility
Private
Private
Description
Unique ID for each zone
Zone Name
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
userLibraryID
deviceCode
Int
String
Private
Private
location
createDate
Method
checkExistDevice
getZone
updateZone
deleteZone
addZone
String
Datetime
Type
boolean
List<zone>
void
Boolean
Void
Private
Private
Visibility
Private
Private
Private
Private
Private
ID of plant in a zone
Device code to identify devices in
zone
Location of zone
Date create zone
Description
Check end devices exist in system
Get ZONE
Update information of plant in zone
Delete zone
Add zone
Type
Int
Int
Float
Float
Visibility
Private
Private
Private
Private
humidity
temperature
Float
Float
Private
Private
soilMoisture
syncTime
Float
Datetime
Private
Private
Method
insertSensor
getSensorInfo
Type
Visibility
boolean
Private
List<zone> Private
getSensorInfobyZoneID Int
Private
Description
Unique ID for set of sensors
Zone ID include sensors
pH degree (reach realtime)
light intensity (reach
realtime)
Humidity (reach realtime)
Temperature degree (reach
realtime)
Soil Moisture (reach realtime)
Synchonization Date when
get indexes from sensors
Description
Insert new sensor
Get indexes of sensors from
Sub C
Get indexes of sensor from
zoneID
SUMMER 2016
Type
Int
Int
Bit
Bit
Bit
Bit
Bit
Bit
Type
boolean
Int
Visibility
Private
Private
Private
Private
Private
Private
Private
Private
Visibility
Private
Private
Description
ID of set enddevices in one node
Zone ID include end devices
Startus of pump
Status of covered
Status of misting
Status of machine fertilize
Status of lamp
Waning high or low index PH
Description
Update status enddevice
Return result is enddevice.
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3. Interaction Diagram
4.3.1. Login Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.2. Show Zone Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.3. Update Zone Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.4. Add Zone Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.5. Delete Zone Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.6. Show Sensor Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.7. Show History Sensors Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.8. Insert Sensor to Database Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.9. Add New Plant Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.10. Control End Devices Automatic
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.11. Control End Device Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.3.12. Show End Device Sequence Diagram
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5. Interface
5.1. Component Interface
Description
Input
Request(userna
me, password)
Show list zone of
Request
user
(userLibID)
Add new one zone
Request
in system
(zone)
Show list userlib of Request
user
(user)
Add new one plant
Request
in library
(userlibrary)
Show information of Request
plant in zone
(userLibID)
Update information Request(userlib
of zone and plant
raryDTO)
Show sensorinfo of Request
zone
(zoneID)
Show list sensor
Request
have insert in sever (zoneID)
Update actuator in
Request
zone
(enddevice)
Output
Json
Boolean
Object
Json
Message
List
object
Object
Json
Object
Json
Object
Json
Object
Json
Output
Format
Exception
Boolean
Rollback
Object
Rollback
Show
object
List
object
Rollback
Rollback
Object
Rollback
Object
Rollback
Object
Rollback
Object
Rollback
List json
List
object
Rollback
Object
Json
Object
Rollback
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.2. User Interface Design
5.2.1. Login
Field
Description
Name
Username Fill user
name
Password Fill password
Buttons/Hyperlinks
No
Function
3
NG
NHP
SUMMER 2016
Read
Control Data Leng
Mandatory
only
Type Type
th
No
Yes
Textbox String N/A
No
Yes
Description
Login into
the system
Outcome
Transfer to
show zone
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.2.2. Zone Management
Field
Name
Danh
sch
khu
Khu
A
Description
All zone of
user
Zone name
Read
Control Data
Mandatory
Length
only
Type
Type
No
Yes
Label
String N/A
No
Yes
Buttons/Hyperlinks
No Function Description
3
+
Add new zone the system
SUMMER 2016
Label
Validation
N/A
String N/A
Outcome
Transfer to
show add zone
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.2.3. Add zone
Yes
Area name
of user
Device
code
No
Yes
drop
String N/A
down
list
Textbox String N/A
No
Yes
Location of
plant
No
Yes
Buttons/Hyperlinks
No Function Description
4
+
Add new zone the system
SUMMER 2016
Validation
N/A
Outcome
Transfer to
show zone
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.2.4. Choose plant from library
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.2.5. Add new plant
PH
4
nh
Sng
m
t
SUMMER 2016
Description Read
only
Enter plant No
name
Enter type
No
plant
Enter
No
boundary
high, low ph
Enter
No
boundary
high, low
light
Enter
No
boundary
high, low
Humidity
Enter
No
boundary
high, low
Soil
moisture
Textbox
String N/A
Yes
Textbox
String N/A
Yes
Textbox
String N/A
Yes
Textbox
String N/A
Yes
Textbox
String N/A
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Nhit
Ngy
Bn
Phn
S
Enter
Lng Weight of
Phn Fertilizer
Bn
Enter
No
boundary
high, low
Temperature
Enter date
No
fertilizer
Yes
Textbox
Yes
Datetime Date
No
Yes
Textbox
Buttons/Hyperlinks
No Function
Description
1
Hy
Add new zone the
system
2
Thm Vo
Add new plant the
Th Vin
system
Validation
N/A
N/A
String N/A
N/A
String N/A
Outcome
Transfer to
show zone
Transfer to
add new plant
Description
Plant name
Data Length
Type
String N/A
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2
3
4
5
6
7
8
9
Khu
A
PH
nh
Sng
m
t
Nhit
Ngy
Bn
Phn
S
Lng
Phn
Bn
Zone name
No
Yes
Label
String N/A
High, ow ph No
Yes
Textbox
String N/A
High, low
light
High, low
Humidity
High, low
Soil
moisture
High, low
Temperature
Date
fertilizer
No
Yes
Textbox
String N/A
No
Yes
Textbox
String N/A
No
Yes
Textbox
String N/A
No
Yes
Textbox
String N/A
No
Yes
Datetime Date
Weight of
Fertilizer
No
Yes
Textbox
N/A
String N/A
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Fields
No Field
Name
1
Cay
cai
2
Khu
A
3
PH
4
nh
Sng
5
m
6
7
8
9
m
t
Nhit
No
Yes
Label
Enter high,
low ph
Enter high,
low light
Enter high,
low
humidity
Enter high,
low soil
moisture
Enter high,
low
temperature
Choose date
fertilizer
No
Yes
No
Yes
No
Yes
No
Yes
No
Yes
No
Yes
Date
time
No
Yes
Ngy
Bn
Phn
S
Enter
Lng weight of
Phn fertilizer
Bn
Buttons/Hyperlinks
No Function
Description
1
CP NHT Update info plan and
zone
SUMMER 2016
Validation
N/A
String N/A
Date
N/A
Outcome
Transfer to
information
plant in zone
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.2.8. Show sensor info
PH
3
nh
Sng
4
m
t
Nhit
SUMMER 2016
Description Read
only
Sensor in
No
zone
Index
No
sensor PH
Index
No
sensor nh
Sng
Index
No
sensor
humidity
Index
No
sensor soil
moisture
Index
No
sensor
temperature
Label
String N/A
Yes
Label
String N/A
Yes
Label
String N/A
Yes
Label
String N/A
Yes
Label
String N/A
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Buttons/Hyperlinks
No Function
1
Cp nht ln cui
Description Validation
The latest
N/A
time tracking
Outcome
Choose history
sensor
SUMMER 2016
Description
Time insert sensor
Validation
N/A
Outcome
Show index
sensor
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.2.10. Show actuator
Description
Status of pump
Validation
N/A
Mi Che
Status of covered
N/A
My Phun Sng
Status of Misting
N/A
Status of lamp
N/A
Bn phn vo lc
Show date
Fertilize
N/A
SUMMER 2016
Outcome
Update status
actuator
Update status
covered
Update status
misting
Update status
lamp
Show date
fertilize
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
6. Database Design
6.1. Entity Relationship Diagram (ERD)
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
6.2. Data Dictionary
Table name
account
userlibrary
SUMMER 2016
Attributes
Description
Null
username{PK}
No
password
Unique identifier
No
fullname
No
role
No
No
phone
No
userlibID
No
username
No
userPlantName
No
userTypePlan
No
userHighPH
No
userLowPH
No
userHighLight
No
userLowLight
No
userHighHumidity
No
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
zone
enddevice
SUMMER 2016
userLowHumidity
No
userHighTemperature
No
userLowTemperature
No
userHighSoilMoisture
No
userLowSoiMoisture
No
userFretilizeDate
No
userWeightFertilize
No
zoneID
No
zonename
No
userlibID
No
deviceCode
No
location
No
dateOfGrow
Unique identifier
No
enddeviceID
No
statuspump
No
statuscovered
No
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
sensorinfo
SUMMER 2016
statusmissting
No
zoneID
No
automatically
No
statuslamp
No
statusFertilize
No
sensorID
No
ph
No
light
No
humidity
No
temperature
No
soilMoisture
No
synctime
No
zoneID
No
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
7. Flowchart
7.1. Add index of sensors to database
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
7.2. Control Water Pump through Algorithm
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
7.3. Control Light through Algorithm
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
In this section, contains information about the test plan, test approach,
test process, test environment, test pass/fail criteria, checklist to check test
this system.
1.2. Test Approach
White box testing: Developers self-test code that they wrote and fix
themselves
Black box testing: Test on each function of each module in system to
ensure each module execute the right function. Then integration testing to
test the function in system when integrate. Finally, system test to test the
whole system.
Goal: Discover bug in system fix bug regression test completed
system.
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2. Data Dictionary
Table name
account
userlibrary
SUMMER 2016
Attributes
Description
Domain
Null
username{PK}
VARCHAR(255) no
password
Unique identifier
VARCHAR(255) no
fullname
VARCHAR(255) no
role
VARCHAR(255) no
VARCHAR(255) no
userlibID
INT
no
username
VARCHAR
no
userPlantName
VARCHAR
no
userTypePlan
VARCHAR
no
userHighPH
FLOAT
no
userLowPH
FLOAT
no
userHighLight
FLOAT
no
userLowLight
FLOAT
no
userHighHumidity
FLOAT
no
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
zone
enddevice
SUMMER 2016
userLowHumidity
FLOAT
no
userHighTemperature
FLOAT
no
userLowTemperature
FLOAT
no
userHighSoilMoisture
FLOAT
no
userLowSoiMoisture
FLOAT
no
userFretilizeDate
DATETIME
no
userWeightFertilize
FLOAT
no
userlifeCyleOfPlant
INT
no
zoneID
INT
no
zonename
VARCHAR
no
userlibID
VARCHAR
no
deviceCode
VARCHAR
no
location
VARCHAR
no
dateOfGrow
Unique identifier
DATETIME
no
enddeviceID
INT
no
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
sensorinfo
SUMMER 2016
statuspump
BIT
no
statuscovered
BIT
no
statusmissting
BIT
no
zoneID
INT
no
automatically
BIT
no
statuslamp
BIT
no
statusFertilize
BIT
no
sensorID
INT
no
ph
FLOAT
no
light
FLOAT
no
humidity
FLOAT
no
temperature
FLOAT
no
soilMoisture
FLOAT
no
synctime
DATETIME
no
zoneID
INT
no
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
3. Performance Measures
4. Test plan
The purpose of the test is to verify the functionality of the system.
Functions need to be tested. Functions to ensure technical requirements and
system requirements of the user. Error (error) will not happen after the trial.
The next content will describe which function will be tested and which
will not and plan for them
4.1. Features to be tested
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Soil
Moisture
Sensor
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
4.1.2. Software
The features of user and web services will be focused and list below:
Table E-2: Software Test Plan
Functions
Description
Web Services Automatic Services
+ Update status of end devices to database after system do
algorithms.
+ Counting how much time algorithm work and update to
database.
Services are provided for Raspberry Pi 3.
+ Insert sensor indexes from hardware to database.
+ Stress test with request and response services continuously
in a long time.
Android
Application
- N/A.
4.3. Test environment
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
ID
Test Case
Description
SUMMER 2016
Result
Test
Date
Pass
Week 2
25-50 lux
Pass
Week 2
25-50 lux
Pass
Week 2
Pass
Week 2
Pass
Week 2
From 10000
To 65535
lux
From 10000
To 30000
lux
0 lux
Note
N/A
N/A
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.1.2. Temperature an Humidity Sensor
ID
Test Case
Description
SUMMER 2016
Converted
value is the
same with
weather
forecast
Test
Date
Week 4
Week 5
Week 5
Pass
Week 8
Pass
Week 8
Note
Maybe that is
not
compatible
with MCU
Get around
environment
temperature
Can not get
right value
from sensor,
make noise
other modules
Temperature:
30. Humidity:
50-80%
The module
have to put in
reset standard
environment
to get right
value
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.1.3. Soil Moisture Sensor using LM393
ID
Test Case
Description
SUMMER 2016
Value output
is analog 16
bit: 0 4096.
Convert to
percent value
Result
Test
Date
Pass
Week 3
Pass
Week 3
Note
Dry sand: 020%
Wet sand: 7099%
Dry silt: 0%
Wet silt: 5099%
Dry sand: 020%
Wet sand: 7099%
Pass
Week 3
Pass
Week 8
Dry: 0-20%
Wet: 70-99%
Pass
Week 8
Dry: 0-20%
Wet: 70-99%
N/A
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.1.4. PH Meter DFRobot Kit
Test Case
Description
ID
Result
Test
Date
Note
Pass
Week 4
pH degree: 7
Pass
Week 5
pH degree < 7
Pass
Week 5
pH degree > 7
Pass
Week 5
pH degree
around 7
ID
Test Case
Description
SUMMER 2016
Test
Date
Note
Week 3
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.1.6. CC1310 LaunchPad
ID
Test Case
Description
SUMMER 2016
Result
Test
Date
Pass
Week 9
Pass
Week 9
Pass
Week 10
Note
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
without
obstructions
Packet is
N/A
received
when there
are less four
wall than
between two
CC1310s.
Packet is
received
when put two
CC1310 in
different
room in
different floor
Pass
Week 10
Packet is
received.
Pass
Week 9
N/A
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
TC025 Transceiver RF
between two CC1310
TC026 Transceiver RF
between more than
two CC1310
SUMMER 2016
Pack A is
received in
CC1310 B
and packet B
is received in
CC1310 A
Pass
Week 11
Master
DIO Control Pass
received two End Devices
named packet
and resend
status to
named slave,
turn on/off
Led on slaves
Week 11
UART
received
packet
N/A
N/A
Pass
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
Raspberry
received
packet
Raspberry
received
packet
N/A
Pass
Week 10 Compatible
baud rate is
9600
N/A
Pass
Week 10
N/A
Pass
Week 10
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.1.7. Raspberry Pi 3
ID
Test Case
Description
SUMMER 2016
Test
Date
Note
Week 6
Week 6
Week 6
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.1.8. Mobile
ID
Test Case
Description
SUMMER 2016
Test
Date
Note
From
(over 40
20/06/16 times)
To
13/07/16
From
(over 40
20/06/16 times)
To
13/07/16
From
20/06/16
To
13/07/16
(over 40
times)
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
Temperature,
Low
Temperature, choose
Date
Fertilize,
Weight of Fertilize .
Click DONE button
User click Update
button on screen
Indexes. User fix:
plant, High PH,
Low PH, High
Light, Low Light,
High Humidity, Low
Humidity, High soil
moisture, Low soil
moisture, High
Temperature, Low
Temperature, choose
Date Fertilize,
Weight of Fertilize ,
Device code ,
location.
Click DONE button
User click sensor tab
User click list day of
sensor
User choose one day
Mobile
application
show
notification
Update
success
Pass
From
20/06/16
To
13/07/16
(over 40
times)
Mobile
application
shows sensor
information
of day.
Pass
From
20/06/16
To
13/07/16
(over 40
times)
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Mobile
application
On/off the
device of user
Pass
From
20/06/16
To
13/07/16
(over 40
times)
5.1.9. Webserver
ID
Test Case
Description
SUMMER 2016
Test
Date
Note
From
(over 40
25/02/1 times)
6 To
13/04/1
6
(over 40
times)
From
(over 40
25/02/16 times)
To
13/04/16
(over 40
times)
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
Web browser
show
information
zone
Pass
From
25/02/16
To
13/04/16
(over 40
times)
Web browser
show
information
follow
username
Pass
From
25/02/16
To
13/04/16
(over 40
times)
Web browser
show library
information
Pass
From
25/02/16
To
13/04/16
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
(over 40
times)
Web browser
show
information
follow zone
Pass
From
25/02/16
To
13/04/16
(over 40
times)
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Web browser
show
information
plant follow
zone
Pass
From
25/02/16
To
13/04/16
(over 40
times)
Web browser
show
Pass
From
25/02/16
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
TC50
SUMMER 2016
http://smartgardenthanhsang.rhcloud.com/
SmartGarden/rest/senso
rinfo/2/sensorinfolistjso
n Check information
show on bowser with
index of database
URL of input page:
http://smartgardenthanhsang.rhcloud.com/
SmartGarden/rest/senso
rinfo/1/listsensor
Check information
show on bowser with
index of database
URL of input page:
http://smartgardenthanhsang.rhcloud.com/
SmartGarden/rest/endde
vice/1/enddevicelistjson
Check information
show on browser with
index of database
URL of input page:
http://smartgardenthanhsang.rhcloud.com/
SmartGarden/rest/endde
vice/postupdateenddevi
information
of sensor
follow zone
To
13/04/16
(over 40
times)
Web browser
show history
information
of sensor
follow zone
Pass
From
25/02/16
To
13/04/16
(over 40
times)
Web browser
show status
Pass
From
25/02/16
To
13/04/16
(over 40
times)
Web browser
show status
have update
Pass
From
25/02/16
To
13/04/16
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
(over 40
times)
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
5.2. Integration Test
Test Case
Description
Test Case
Procedure
SUMMER 2016
Inter-test
Case
Dependence
+ Change
status on
mobile
+ Update data
The light
on Webserver
or covered
+ HTTP
will turn
request on
on/off
Raspberry
after user
+Transmit
change
UART, Pi 3
status of
and CC1310
them on
+ Transmit
mobile
and receive
app.
data via RF
Average
time
process: 3
+ DIO Control
second
End devices
Expected
Output
Result
Test
Date
Pass
Week 13
GROUP 1
Note
Capstone Project 2016: Design and Implement The Model of Smart Garden
Control Water
Pump/Misting
TC052
Machine
Manual
SUMMER 2016
The water
pump or
misting
machine
will turn
on/off
after user
change
status of
them on
mobile
app.
Average
time
process: 3
second
+ Change
status on
mobile
+ Update data
on Webserver
+ HTTP
request on
Raspberry
+Transmit
UART, Pi 3
and CC1310
+ Transmit
and receive
data via RF.
+DIO Control
End Devices
Pass
Week 13
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
Get index of
ambient light
Transceiver
RF between
Main and Sub.
The
Transceiver
covered
UART
will turn
between Main
on/off
and Raspberry
after
Insert sensor to
index of
database
sensors
Update end
put in an
devices status
algorithm.
DIO control
Average
end devices
time: 3
second.
Pass
Week 13
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Control Water
Pump/Misting
TC054
Machine
Automatic
SUMMER 2016
Get index of
soil moisture,
temperature,
humidity.
The water Transceiver
pump or
RF between
misting
Main and Sub.
machine
Transceiver
will turn
UART
on/off
between Main
after
and Raspberry
index of
Insert sensor to
sensors
database
put in an
Update end
algorithm. devices status
Average
DIO control
time: 3
end devices
second.
Pass
Week 13
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
+ Get all
indexes of
sensors
+ Transceiver
RF between
Main and Sub.
+ Transceiver
UART
between Main
and Raspberry
Insert sensor to
database
Pass
Week 13
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
- Raspberry pi 3
- Circuit board, which includes cc1310, sensors and actuator designed
by our team.
- Model of Hydroponic Garden
- Android phone
- Ensure stable power system 220v ~ 50 Hz.
- Wi-Fi coverage.
1.1.2. Software requirement
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Paste to URL
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
1.3. Setting up the environment at client side
1.3.1. Setting up for mobile application
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2. Users Guide
2.1. Login
No.
Item
1 Username
2 Password
Description
Fill out username which is registered
Fill out password
You must enter a valid name and password provided by the publisher.
After the test, correctly you click "login". For security reasons, if you
forget your password, please contact the publisher to retrieve the
username and password
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.2. Show zone
No.
1
2
3
Item
+
Zone
DELETE
Description
You can add a new zone.
Contains information on the zone
You can delete the zone.
Display the user's zone, with a new user will not have any zone
displayed. When user click on "+" to add a new zone. You need only
enter the number required by the system.
When user click on "DELETE". They must be sure you want to delete
the zone. They will choose the zone you want to delete. The display
will appear the message "Are you sure you want to delete" user click
"Ok" to clear the zone.
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.3. Add zone
No
1
2
3
4
5
Item
Back
Choose from library
Device code
Location
Create date
Description
Back screen shows zone
The user will select plants at the library
Enter the correct product code
Users enter the area you want to name
The system will automatically retrieve the date
and time
Users who want to add a zone. They must make sure that there is a real
part here we called "node". On the node will have the code, this is the
device that the user must enter the code in the "Device code".
"Choose from the library": users will choose plants that they want to
grow in the zone. If the plant does not exist, a user can add new ones.
Location: users can enter the location you want.
Create date: users do not need this option. Auto save system date and
time to add new users. Users can view the creation date, when
necessary.
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.4. Library info
No
Item
Description
Back screen shows zone
1 Back
Plant where the user can choose
2 Plant name
3 ADD NEW LIBRARY Finish choose plant
The user chooses to plant they want on zone.
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.5. Add new plant
No.
1
2
3
4
Description
Back
Back screen add zone
Plant
Enter plant name
PH
PH input indicators include 2 upper and lower
Light
Light input indicators include 2 upper and
lower
Humidity input indicators include 2 upper and
5 Humidity
lower
Soil moisture input indicators include 2 upper
6 Soil moisture
and lower
Temperature input indicators include 2 upper
7 Temperature
and lower
Select dates for fertilizing plants
8 Date Fertilizer
9 Weight of Fertilizer Fertilizer for plants
Finish add new plan.
10 DONE
Add a new user to the library tree. They must be fully and accurately
enter the parameters of the tree. They can consult online or based on
actual experience itself.
Date Fertilizer: The next day fertilizing (Unfinished function).
Weight of Fertilizer: Unfinished function.
SUMMER 2016
Item
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.6. Show plant info
No.
1
2
3
4
Item
<=
Khu O
bng lng
PH
Light
Humidity
Soil moisture
Temperature
9
10
Date Fertilizer
Weight of
Fertilizer
Device code
Location
Create day
11
12
13
SUMMER 2016
Description
Back screen choose zone
Show zone name
Plant were planted in the zone name
PH input indicators include 2 upper and
lower
Light input indicators include 2 upper and
lower
Humidity input indicators include 2 upper
and lower
Soil moisture input indicators include 2
upper and lower
Temperature input indicators include 2
upper and lower
Select dates for fertilizing plants
Fertilizer for plants
Manufacturer's code
Location name
The system will automatically retrieve the
date and time
PAGE 191 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
Update
14
No.
1
2
Item
3
4
<=
Khu O
Bng Lng
PH
Light
Humidity
Soil moisture
Temperature
8
9
10
11
Date Fertilizer
Weight of Fertilizer
Device code
Location
SUMMER 2016
Description
Back screen choose zone
Show zone name
Plant were planted in the zone name
PH input indicators include 2 upper and lower
Light input indicators include 2 upper and
lower
Humidity input indicators include 2 upper and
lower
Soil moisture input indicators include 2 upper
and lower
Temperature input indicators include 2 upper
and lower
Select dates for fertilizing plants
Fertilizer for plants
Manufacturer's code
Location name
PAGE 192 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
12
Create day
13
Update
When user want to change index of plant in zone. They will change
index by click line on screen.
Must ensure that the parameters are correct. Click the button update
to finish.
2.8. Show sensor info
No.
1
2
3
4
5
6
7
8
9
SUMMER 2016
Item
<=
Khu O
Bng lng
PH
Light
Humidity
Soil moisture
Temperature
Last check
Description
Back screen choose zone
Show zone name
Plant were planted in the zone name
PH sensor that measured
Light sensor that measured
Humidity sensor that measured
Soil moisture sensor that measured
Temperature sensor that measured
The latest update now
PAGE 193 OF 197
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
10
Weight of Fertilizer
SUMMER 2016
GROUP 1
Capstone Project 2016: Design and Implement The Model of Smart Garden
2.10. Show actuator
No.
1
2
3
4
5
6
7
Item
Back
Khu O
Bng lng
Status Pump
Status Covered
Status Misting
Automatically
Description
Back screen choose zone
Show zone name
Plant were planted in the zone name
Show the status of pump
Show the status of covered
Show the status of Misting
On/off control
SUMMER 2016
GROUP 1