410 likes | 584 Views
ECE 445 – Spring 2014 Bluetooth Trashcan. Group 57 Albert Kim Caroline Cho Hyunjun Hong TA: Mustafa Mukadam. Bluetooth Trashcan Introduction & Outline. Mobilized Trashcan with using Bluetooth connectivity and Android app Motivation Objectives Review
E N D
ECE 445 – Spring 2014Bluetooth Trashcan Group 57 AlbertKim Caroline Cho Hyunjun Hong TA: Mustafa Mukadam
Bluetooth Trashcan Introduction & Outline • Mobilized Trashcan with using Bluetooth connectivity and Android app • Motivation • Objectives • Review • Hardware Side - Requirements & Verifications, Build & Functional Tests • Software Side - Requirements & Verifications, Build & Functional Tests • Further Improvements • What We Have Learned
Bluetooth Trashcan Motivation • When you feel lazy or Can’t move freely • But you want it keep it clean!
Bluetooth Trashcan Motivation/Inspiration
Bluetooth Trashcan Objectives • Purpose - Make it Easy for the people to throw trash away - Utilize Microcontroller - Create Android App - Bluetooth Connectivity • Benefits - Mobility - Easy to Use - You don’t have to move!
Bluetooth Trashcan Review : Block Diagram
Bluetooth TrashcanHardware Overview • Microcontroller • Transportation Unit - Car Chassis • Motor and Motor Driver • Power Supply • Takes 9Vdc from battery and converts to stable 5Vdc • Bluetooth Transceiver • Detection Unit - Ultrasonic sensor
Hardware Side Microcontroller • Built our own Arduino using Atmega328 • Communication with - Bluetooth transceiver - Motor driver - Ultrasonic sensor • Operating voltage: 5V
Hardware Side Transportation Unit • Built own H-bridge Motor driver • Communicating with - Microcontroller • Car chassis • Motor - Gear ratio 1:120 - 200 RPM - 1.92Kgcm - 59.2mA (5V)
Hardware Side Requirement & Verifications: Transportation Unit
Hardware Side Bluetooth Transceiver • HC-06 • Serial communication • Operating voltage: 3.6~6V • Baud rate: 1200 ~ 1382400 bps • 10 meters of transmission distance
Hardware Side Requirements & Verifications: Bluetooth Transceiver
Hardware SideFailures • Malfunctioning of Microcontroller - Tested with FTDI - Receives the data - Can’t send out the data • TXD on Microcontroller malfunction • TXD & RXD on Bluetooth operated - Tested with Arduino Mega - Receives the data (RXD - O) - Sends out the data (TXD - O)
Hardware Side Detection Unit • SMAKN HC-SR04 • Operating Voltage : 5V • Operating Current : 15mA • Operating Frequency : 40Hz • Max Range Detection : 50cm • Min Range Detection : 0~1cm
Hardware Side Power Supply • Battery provides 9V • Using a voltage regulator (LM7805), Supply 5V to all components
Hardware Side Functional Tests: Microcontroller • LED blinking test for Microcontroller
Hardware Side Functional Tests: Transportation Unit • Measuring the voltage between motor
Hardware Side Functional Tests: Bluetooth Transceiver • Receiving inputs in serial monitor by sending out test inputs from the Android app, “Blueterm”
Hardware Side Functional Tests: Power Supply • Voltage regulator should always provide 5 ±0.1V
Software Side Development Tools • Android Application - Eclipse Standard 4.3.2 (Kepler) - Java Platform (JDK) 7u51 • Device - ASUS Nexus 7 Tablet - Android Version 4.3 (Jelly Bean)
Software Side Development Tools • Arduino - Arduino IDE 1.0.5
Software Side Requirements & Verifications • Goal: 1. To create an android application that can: • Select a trashcan • Specify the location of the user and the trashcan • Calculate the path to be taken by the trashcan • Send Bluetooth signal to the microcontroller • Receive Bluetooth signal from the microcontroller
Software Side Requirements & Verifications • Goal: 2. To program microcontroller that can: • Receive Bluetooth signal from the tablet • Send Bluetooth signal to the tablet • Give “on” signal to the motor drivers for length of time that is received • Receive signal from the ultrasound sensor and process this signal
Software Side Requirements & Verifications • Interfaces are complete and the buttons connect to correct pages • Touchscreen is enabled to receive the user input for the trashcan/user location specification • Upon receiving the trashcan location and the user location, a perpendicular path is calculated. This path should be up to scale.
Software Side Requirements & Verifications • Tablet–microcontroller Bluetooth connection is successful • Send a Bluetooth signal: Tablet => Microcontroller • Check serial monitor to see if this signal is received by printing out the value. • Send a Bluetooth signal: Microcontroller => Tablet • Change the color of a button on the main page upon receiving this signal.
Software Side Functional Tests • Complete interfaces and functional buttons
Software Side Functional Tests • Touchscreen worked perfectly and the consequent path calculation was successful.
Software Side Functional Tests • Successful Bluetooth connection set-up • Bluetooth communication Test (Tablet => microcontroller)
Software Side Functional Tests • Bluetooth communication Test (microcontroller => Tablet) Diameter of Trashcan = 16 cm
Software SideFunctional Tests - Combined • Get the scheduled movements by specifying the trashcan/user locations • Send this data to microcontroller via Bluetooth • Microcontroller sends “ON” signal to the motor drivers according to the data received
Software Side Functional Tests - Combined • Success! • Scheduled movement: • Forward 106 cm • Right turn • Forward 337 cm • Estimated speed 10cm/s • Both wheels turned for ~10s • Left wheels turned for ~3s • Both wheels turned for ~34s
Software Side Failures • Integration of ultrasonic sensors with the rest of the system • Sensor output correctly printed out
Software Side Failures • Error: sending Bluetooth signal when distance is less than 16 cm • When distance is set manually (ex. distance = 13cm), Bluetooth signal is correctly received on the tablet • When the sensor output is used to set distance, Bluetooth signal was not received on the tablet • Possible reason: read() and write() methods in the serial channel are using the wrong addresses
Bluetooth TrashcanFurther Improvements • Our robot is currently “blind” - Send data to the robot once and expect it to arrive where it is supposed to go • We need a feedback system to make sure that the trashcan goes to where it is supposed to go • Solution: Feedback system using magnetic rotary position sensors (AS5145A by AMS)
Bluetooth Trashcan Further Improvements • Use a rotary sensor to count the number of revolutions each motor makes • Using this information we can determine the distance the trashcan travels • Compare the actual movement against the scheduled movement and re-calculate the required path • Move the trashcan again accordingly and repeat this procedure until the difference is within the acceptable range
Bluetooth Trashcan What We Have Learned • How to be a real Engineer! • Process, design, testing, etc… • Creating Android Application • Building our own Microcontroller • Usage of Bluetooth – interacting with Microcontroller and Android Application • Generating PCB board and schematics