Final_Presentationx

Download Report

Transcript Final_Presentationx

Moisture Controlled
Irrigation System
Team Members:
ECE - Aaron Beekman, Adrian Fletcher, and Derek Thomas
CECS – Jacob Schreiver
Background Info
• Swan Florist and Gift Shop is a family run business located in
Erlanger, Ky.
•
•
•
•
Operate multiple greenhouses
Several greenhouses are located at a remote location
Maintained by employees 2-3 times per week
Uses a timer system to water plants once a day
Greenhouse Layout
Existing Irrigation System
Project Requirements
•
•
•
•
Irrigate plants based on soil moisture content
Use existing sprinkler valves
Require minimal operator intervention
Perform data logging of moisture content, greenhouse
temperature, when and how long plants were watered
• Provide a Graphical User Interface that will allow the
user to change moisture thresholds to maintain proper
watering for plants
• At least 10 different threshold levels
• Restart after a power outage without reprogramming
System Diagram
Moisture Sensor Requirements
• Designed for potted plants
• Need at least 8
• Input voltage of 5 VDC
• Cost Effective
Temperature Sensors
• 2 required
• Either commercial-off-shelf or self-designed
• Cost effective choice
• Located in two neutral locations chosen by
sponsor.
• Input voltage of 5 volts
• Linear return within expected greenhouse
temperatures.
• About 40 – 110 degrees Fahrenheit
Sprinkler Valves
• Need to interface with 8
sprinkler valves
• Input Voltage 26.8 VAC
• 8 Watts per valve
• No more than 2 valves
on at one time.
Power Converter
• Use existing 26.8 VAC Transformer
•
•
•
•
Converts 120VAC to 26.8VAC
33 Watts @ 26.8 VAC
Powers Sprinkler Valve Solenoids
Provides power to AC/DC Rectifier
• Custom AC/DC Rectifier to power control
board
Control Board Hardware Requirements
• Programmable microcontroller
• Minimum of 10 analog input channels
• To interface with all sensors
• Minimum of 10 digital I/O
• 8 relays control
• 2 communication
• 8 relays either on-board or daughter card
• Provides 26.8VAC to the sprinkler valves
• Integrated RS232 interface
• Capable of powering sensors
Control Board Software Requirements
• Send/Receive Serial data
• Execute commands received from Display/Data
Management System
• Close and Open relays
• Acquire and transmit A/D values from each
sensor input
Display/Data Management System
• Serial Communication with control board
• Watering Scheduler
• Waters plants at schedule time
• Water plants according to moisture content
• Data Logging
• Log sensor and watering information
• Graphical User Interface
•
•
•
•
•
Allows user to see visual representations of sensor readouts
Control schedule times for watering
Control threshold levels
View graphical representation of data
Export data log via a comma separated values (.csv) file
Detailed Design
Moisture Sensors
Moisture Sensors
• Vegetronix VH400
•
•
•
•
•
Designed for potted plants
Independent of volume
Input voltage of 5 VDC at .7mA
Output impedance: 100kΩ
Returns 0-3 VDC
Volumetric Water Content
Temperature Sensors
Temperature Sensor
• Thermistor Design
• 5 VDC input to
temperature sensor
• 0-5 VDC output
Approximately Linear
Voltage return of 1.5-3.5
VDC in typical greenhouse
ranges
Voltage Buffer Daughter Card
•3 Quad Op-Amps configured a voltage buffers
•2 10-pin IDC connectors
•2 10-pin IDC headers
Power Converter
Rectifier Circuit
• Uses 26.8 VAC from existing transformer
• Converts 26.8 VAC to 20 VDC for control board
• Control Board requires 16 to 28 VDC
• Optional 5 VDC output
Connections and Wire Management
Connections and Wire Management
Control Board
MikroElectronika PICPLC8A
Control Board
• Utilizes a PIC18F4520
microprocessor
• Provides up to 13 A/D
conversion input channels
• Meets requirement of 10
• Provides up to 32 digital I/O pins
• Meets requirement of 10
• 8 on-board relays
• Meets requirement of 8
• On-board RS-232 interface
• Meets communication
requirement
Control Board Software Diagram
Control Board Software
• Read and transmit A/D values from sensors
• Receive and execute relay control commands
Increment Channel Number
Initialization
Read Next A/D Channel
Transmit Sensor Data
Interrupt Received
Read Serial Data
Execute Relay Control Commands
Display/Data Management System (DDMS)
Display/Data Management Software
• Java Program will control irrigation
• Provide Graphical User Interface for system control
• Set Moisture Thresholds
• Set Watering Times
• View Sensor Output
• Provide Data Logging Utility
• Log sensor values every four hours
• Log when plants were watered and for how long
• Provide a Scheduler for watering plants
• Communicate via RS-232 with Control Board
• Uses java RXTX package
DDMS Software Block Diagram
Graphical User Interface
Graphical User Interface
Data Visualization
Testing Overview
• Code Testing
• Hardware Simulation
• Communications Testing
• Analog to Digital Conversion Testing
• Moisture Sensor Testing
• Temperature Sensor Testing
Code Testing
• JUnit
• Java Unit testing package
• Runs in Netbeans
• Provides Code Coverage results as well as test result validation
• Tests for both Java Application and Control Board
Hardware Simulator
Communications Testing
• Use JUnit and Netbeans
• Send valid data to Control Board
• Verify good data acknowledgement packet
• Send invalid data to Control Board
• Verify bad data acknowledgement packet
• Send packet requesting multiple relays on
Analog-to-Digital Converter Testing
A/D Readout
1200
1000
800
600
A/D Readout
400
200
0
0
0.25 0.5 0.75
1
1.25 1.5 1.75
2
2.25 2.5 2.75
3
3.25 3.5 3.75
4
4.25 4.5 4.75
5
A/D Testing
• From the graph on the previous slide, we found out that we
needed to power the sensors from the control board.
• This is due to the control board having an on-board bridge
rectifier for power input that creates a ground difference.
• Powering the sensors from the board corrects the A/D results
shown in the previous slide
Corrected A/D Testing
A/D Readout
1200
1000
800
600
A/D Readout
400
200
0
0
0.25 0.5 0.75
1
1.25 1.5 1.75
2
2.25 2.5 2.75
3
3.25 3.5 3.75
4
4.25 4.5 4.75
5
Moisture Sensor Testing
Moisture Sensor Testing
• Moisture Sensor voltage readings were correct when measured using a
digital multi-meter
• Moisture Sensors did not output correctly when connected to the A/D
converter on the control board
• Caused by impedance mismatch
• 100KΩ moisture sensor
• 2.5KΩ max A/D
• Solution
• Add voltage buffer for each sensor input prior to the control board to
reduce output impedance
• A developed daughter card with each voltage buffer circuit will added to
the control board
Temperature Sensor Testing
• Confirmed temperature sensor
circuit varied voltage output with
varying temperature
• Plan to use an infrared heat gun to
calibrate the sensor
• Sensor Calibration Dialog will be
used to adjust calibration
coefficients so the measured
temperature values correlate to the
heat gun read out
Recommendations
• Internet connectivity
•
•
•
•
Email alerts/text alerts
Remote access
Software Updates/Patches
Automated Error Reporting
• UPS battery backup
• Allow for safe shutdown of system
• Incorporate more sensors per bench
• Expansion daughter card to allow for multiplexing analog inputs
• Completely moisture controlled watering option
Questions?
Moisture Controlled Irrigation System
Moisture Sensor Testing
Software Development
Environment
• Netbeans IDE
• Java Development for
the frontend
Application
• GUI and Form Builder
• Code Completion
• Software Debugger
• Unit Testing
• Support for Multiple
Programming
Languages
Temperature Calibration