25
Introducing the Digiplant

Digiplant colloquim

Embed Size (px)

Citation preview

Page 1: Digiplant colloquim

Introducing the Digiplant

Page 2: Digiplant colloquim

For those with

GREEN THUMBS• Farmers•Agriculturists

BLACK THUMBS

•Domestic and amateur gardeners

Medicine FoodAir

Page 3: Digiplant colloquim
Page 4: Digiplant colloquim

Sense Surroundings

Display emoticonbased on conditions

Take picture of plant

StorageTransfer to phone

Via Bluetooth

Store picturesand sensor data

The Final Product Functionality Layout

Page 5: Digiplant colloquim

Separation of Duties

Tyler Belle• Microcontroller

Programming• Printed Circuit

Board(PCB) interfacing of components

Connor Murray• Design and creation of

Bluetooth compatible mobile application

• Interfacing mobile application to PCB

Page 6: Digiplant colloquim

Technical Contribution(Tyler)

• Creation and fabrication of PCB• Soldering Components• Programming mbed microcontroller board to

interface with components

Page 7: Digiplant colloquim

Components

Chosen based on:Cost

Ability to be interfaced with microcontrollerDegree of accuracy

Page 8: Digiplant colloquim

Microcontroller Choice

•Online community with ready made programming libraries•Port type variance•Allows simple implementation of timed interrupts(*More on this later)

•Not as many pins as compared to mbed•Less number of ports of required communication type

Page 9: Digiplant colloquim

Software Implementation approach

Code Snippet : Attaching of timed interrupts to their respective functions

Code Snippet: Example of function attached to an interrupt

Page 10: Digiplant colloquim

Thresholding and ScoringStart

Sensor value between the range set for

good conditions?

Increment happiness()

variable

Sensor value

between the range

set for bad conditions?

IncrementSadness ()

variable

Increment average()

variableStop

True

True

True

False

False

Page 11: Digiplant colloquim

Main CodeStart

Has a flag been set

for a component

?

Carry out function(Take picture, read sensors

etc)

Set Flag to false

True

False

Page 12: Digiplant colloquim

SD Storage Output

Page 13: Digiplant colloquim

Extra Features

• Indication LEDs (red, blue and green)• Ability to safely remove SD card via a switch• OLED error display• Extra light sensor and use of averaging for

accuracy• Text file containing sensor info will be created

upon first execution and appended once program continuously runs

• Weather-proof container

Page 14: Digiplant colloquim

Technical Contribution (Conor)

• Testing Bluetooth module with Mbed microcontroller

• Creating the mobile application to connect with the Bluetooth module to send and receive data

• Testing the application with the device

Page 15: Digiplant colloquim

Android Why?

The app was designed for an android platform• Open Source• Easy access to tools

needed • Apple products doesn’t

support SSP(Serial Port Profile)

Page 16: Digiplant colloquim

My First App: Design

• First time creating an app

• Started by creating simple apps

• Original design was to have a update button

Page 17: Digiplant colloquim

Bluetooth module JY-MCY HC-06

• 4 Pins to transmit data(VCC, GND, TXD, RXD)

• Only in slave mode• Runs SPP protocol• Operates at a maximum

distance of 10 metres.• Tested hardware

Page 18: Digiplant colloquim

My First App: Creation

For Creating the App the program Eclipse IDE was used.

For the Bluetooth to connect, a UUID (universally unique identifier) and mac address is needed to be known.

This method is called to check the state of the Bluetooth on the phone. Checks that the BluetoothAdapter is not null

Page 19: Digiplant colloquim

My First App: Creation

Method runs so that is constantly listening to the input stream until an exception.

This is the data stream. It creates an input stream for data that is sent to the app and an output stream which sends out data.

Assigning the button on the app to write to output stream when the button is clicked

This method writes message to the output stream. converts the message to bytes and sends it out the output stream.

Page 20: Digiplant colloquim

My First App: Creation

ChangesThe current device repeatedly sends out the information to be displayed on screen rather than updating it through a button press

if(blue.readable()) //If the phone requests it, start transmitting data to the phone { bluetoothLED = 1; //Information has begun transmitting char c = blue.getc(); if(c==0x31) { blue.printf("Light : %f Temperature : %f Soil Humidity: %f Humidity : %f", lightValue, temp, soil, humid); } bluetoothLED = 0; //Information transmission ended }A method that handles an incoming message. So

that when a message is received it creates a string from a bytes array. The string is appended and the end of the line is determined which should be when \r\n is found.

Mbed code that shows that when the app sends out information, code is performed. The app sends out a one so this code checks to see if the received data is a one(0x31 in UTF-8 format).

Page 21: Digiplant colloquim

My First App: Implementation

Changes from what the original idea:Originally going to have two screen Display image of the plant

b) screen shot of the finished appa) From the original idea

Page 22: Digiplant colloquim

Progress

• All specifications implemented with the exception of:

• Cloud computing• Microphone• Image sending over Bluetooth• Portability of Device

Page 23: Digiplant colloquim

Conclusion : What next?

• Added Mechanics• More sensors• Development of Application complexity and

sophistication• Automated Gardening

Page 24: Digiplant colloquim

Conclusion: Summary

• Successful project• Profitable• Scalable• Room to grow and develop

Page 25: Digiplant colloquim

Thank you !!

[email protected] – Tyler [email protected] – Conor Murray

Feel Free to contact Group 15 for further information at anytime.

Questions?