ECE 445 Senior Design Laboratory. Fall Individual Progress Report. Automatic Pill Dispenser

Similar documents
ENGI1020. Lab 0 Introduction to Arduino IDE and Hardware Lori Hogan, Lab Instructor - Winter 2019

CURIE Academy, Summer 2014 Lab 2: Computer Engineering Software Perspective Sign-Off Sheet

PSoC and Arduino Calculator

Laboratory Seven Stepper Motor and Feedback Control

Total Hours Registration through Website or for further details please visit (Refer Upcoming Events Section)

Arduino STEAM Academy Arduino STEM Academy Art without Engineering is dreaming. Engineering without Art is calculating. - Steven K.

FABO ACADEMY X ELECTRONIC DESIGN

EE 308 Lab Spring 2009

A servo is an electric motor that takes in a pulse width modulated signal that controls direction and speed. A servo has three leads:

Experiment 9 : Pulse Width Modulation

Exercise 5: PWM and Control Theory

EE-110 Introduction to Engineering & Laboratory Experience Saeid Rahimi, Ph.D. Labs Introduction to Arduino

EE 314 Spring 2003 Microprocessor Systems

Programming a Servo. Servo. Red Wire. Black Wire. White Wire

Electronics Design Laboratory Lecture #9. ECEN 2270 Electronics Design Laboratory

Arbeitskreis Hardware. Prof. Dr. Michael Rohs, Dipl.-Inform. Sven Kratz MHCI Lab, LMU München

Lesson 3: Arduino. Goals

Welcome to Arduino Day 2016

ZX Distance and Gesture Sensor Hookup Guide

UNIVERSITY OF CALIFORNIA, DAVIS Department of Electrical and Computer Engineering. EEC 180A DIGITAL SYSTEMS I Winter 2015

Lab 2: Blinkie Lab. Objectives. Materials. Theory

EE 308 Spring S12 SUBSYSTEMS: PULSE WIDTH MODULATION, A/D CONVERTER, AND SYNCHRONOUS SERIAN INTERFACE

Module: Arduino as Signal Generator

Introduction to Pspice

Rodni What will yours be?

Training Schedule. Robotic System Design using Arduino Platform

ME 461 Laboratory #5 Characterization and Control of PMDC Motors

Pulse Sensor Individual Progress Report

MAE106 Laboratory Exercises Lab # 1 - Laboratory tools

Lab 8. Stepper Motor Controller

GE423 Laboratory Assignment 6 Robot Sensors and Wall-Following

Lock Cracker S. Lust, E. Skjel, R. LeBlanc, C. Kim

Intro To Engineering II for ECE: Lab 7 The Op Amp Erin Webster and Dr. Jay Weitzen, c 2014 All rights reserved.

Lab 3: Embedded Systems

Sensors and Motor Control Lab Individual lab report #1 October 16, 2015

ILR #1: Sensors and Motor Control Lab. Zihao (Theo) Zhang- Team A October 14, 2016 Teammates: Amit Agarwal, Harry Golash, Yihao Qian, Menghan Zhang

Mechatronics Engineering and Automation Faculty of Engineering, Ain Shams University MCT-151, Spring 2015 Lab-4: Electric Actuators

THE GUESS OF DEATH. PSEUDOCODE: The logic for my code will be. Dawson Dill 152BC. A less convinient form of analog hangman

3.5 hour Drawing Machines Workshop

ELECTRICAL ENGINEERING TECHNOLOGY PROGRAM EET 433 CONTROL SYSTEMS ANALYSIS AND DESIGN LABORATORY EXPERIENCES

Design. BE 1200 Winter 2012 Quiz 6/7 Line Following Program Garan Marlatt

Project Proposal. Underwater Fish 02/16/2007 Nathan Smith,

MAE106 Laboratory Exercises Lab # 3 Open-loop control of a DC motor

o What happens if S1 and S2 or S3 and S4 are closed simultaneously? o Perform Motor Control, H-Bridges LAB 2 H-Bridges with SPST Switches

Section 2 Lab Experiments

The Candle Extinguisher ECE 445 Spring 2017 Group #46 TA: Dan Frei

Internet of Things Student STEM Project Jackson High School. Lesson 3: Arduino Solar Tracker

AC : THE UBIQUITOUS MICROCONTROLLER IN MECHANICAL ENGINEERING: MEASUREMENT SYSTEMS

ARDUINO / GENUINO. start as professional

Saturday Academy Program

Arduino Workshop 01. AD32600 Physical Computing Prof. Fabian Winkler Fall 2014

AUTOMATIC CLOTH FOLDING MACHINE

DC Motor and Servo motor Control with ARM and Arduino. Created by:

Setup Download the Arduino library (link) for Processing and the Lab 12 sketches (link).

Objectives: Learn what an Arduino is and what it can do Learn what an LED is and how to use it Be able to wire and program an LED to blink

Electronic Components

EE 110 Introduction to Engineering & Laboratory Experience Saeid Rahimi, Ph.D. Lab 0: Course Introduction

An External Command Reading White line Follower Robot

Industrial Automation Training Academy. Arduino, LabVIEW & PLC Training Programs Duration: 6 Months (180 ~ 240 Hours)

Computational Crafting with Arduino. Christopher Michaud Marist School ECEP Programs, Georgia Tech

Sirindhorn International Institute of Technology Thammasat University at Rangsit

Prelab: Introduction and Greenhouse Construction

Lab 5: Arduino Uno Microcontroller Innovation Fellows Program Bootcamp Prof. Steven S. Saliterman

Community College of Allegheny County Unit 4 Page #1. Timers and PWM Motor Control

Lab book. Exploring Robotics (CORC3303)

MOBILE ROBOT LOCALIZATION with POSITION CONTROL

Students will design, program, and build a robot vehicle to traverse a maze in 30 seconds without touching any sidewalls or going out of bounds.

Copyright 2015 by Stephen A. Zajac & Gregory M. Wierzba. All rights reserved..spring 2015.

CprE 288 Introduction to Embedded Systems (Output Compare and PWM) Instructors: Dr. Phillip Jones

Digital-to-Analog Converter. Lab 3 Final Report

Experiment 4.B. Position Control. ECEN 2270 Electronics Design Laboratory 1

Sensor and. Motor Control Lab. Abhishek Bhatia. Individual Lab Report #1

Rockets, Robots, Hovercraft, and Quadracopters, all for the STEM of IT! John J. Helferty Temple University

Understanding the Arduino to LabVIEW Interface

APDS-9960 RGB and Gesture Sensor Hookup Guide

Two Hour Robot. Lets build a Robot.

Coding with Arduino to operate the prosthetic arm

Exercise 2-2. Antenna Driving System EXERCISE OBJECTIVE DISCUSSION OUTLINE DISCUSSION

UC Berkeley, EECS Department EECS 40/42/100 Lab LAB3: Operational Amplifier UID:

1 Day Robot Building (MC40A + Aluminum Base) for Edubot 2.0

University of Portland EE 271 Electrical Circuits Laboratory. Experiment: Kirchhoff's Laws and Voltage and Current Division

Lab 5: Inverted Pendulum PID Control

For this exercise, you will need a partner, an Arduino kit (in the plastic tub), and a laptop with the Arduino programming environment.

Lab 3 DC CIRCUITS AND OHM'S LAW

E85: Digital Design and Computer Architecture

Morse Code Autonomous Challenge. Overview. Challenge. Activity. Difficulty. Materials Needed. Class Time. Grade Level. Learning Focus.

Unit level 5 Credit value 15. Introduction. Learning Outcomes

Monitoring Temperature using LM35 and Arduino UNO

Solar Mobius Final Report. Team 1821 Members: Advisor. Sponsor

CSE 3215 Embedded Systems Laboratory Lab 5 Digital Control System

Ultimate Actuator Drivebox 30A Quick start guide

DC CIRCUITS AND OHM'S LAW

EGG 101L INTRODUCTION TO ENGINEERING EXPERIENCE

TWEAK THE ARDUINO LOGO

GetTutorialized Workshops Brochure-2017

GE 320: Introduction to Control Systems

Multipurpose Iron Man Glove & Moveable Platform

The Motor sketch. One Direction ON-OFF DC Motor

Technology and the Stage:

INA169 Breakout Board Hookup Guide

Transcription:

ECE 445 Senior Design Laboratory Fall 2017 Individual Progress Report Automatic Pill Dispenser Iskandar Aripov (aripov2) Team Members: Iskandar Aripov Mattew Colletti Instructor: Prof. Arne Fliflet TA: Rebecca Chen

1. Introduction 1.1 Team Project Overview Our project s goal is to build a configurable pill dispenser unit that interactively collects the input from the user such as specific time and days of the week and dispense selected pill at these specified times. Our pill dispenser can dispense one or two different pills. 1.2 Individual responsibilities and role in the greater project My role in the project is to write and test all the software for the whole system. It includes interaction between peripherals such as LCD, time unit, buttons, sensors, motors, LED with the microcontroller. Each of the mentioned peripheral needs its individual module to effectively talk to microcontroller and other peripherals such as LCD with buttons and time unit, motors with sensors, etc. I am responsible for any programmable components specific hardware additions such as resistors and potentiometers. I am also responsible for hardware pin configuration for testing and actual design and also for communicating any software specific details that may affect hardware design. 2. Individual design work 2.1 Design Considerations There are no major design changes since the design review. We decided to use two buttons for navigation process and not to use speaker. For testing we use standard arduino uno board, but for actual design we plan to burn the bootloader onto the actual microcontroller. 2.2 Diagrams Figure 1: Button Arduino interaction [1]

Figure 2: Button architecture [2] Figure 3: Possible LCD pin configuration. [3] For LCD we needed to add potentiometer and connect it to pin V0 (3 rd pin from left) for characters to background contrast control. We also needed to connect the last two pins (most right ones) to Vcc and GND for brightness.

Raw code for Motor Sensor Interaction Steps = Number of steps in One Revolution * Gear ratio. Steps = (360 /5.625 )*64 "Gear ratio" = 64 * 64 = 4096. This value will substitute it on the arduino sketch. Since we want motor to rotate clockwise and counterclockwise we are using range of Steps/2 to Steps/2. So to invert a motor by 180 degrees we need 180/360 * Steps/2 = Steps/4.

Now the most challenging part of the design is to implement steps described in design document in microcontroller FSM and pseudocode regarding buttons to arduino to LCD interaction and to fetch and store the time and days of the week. Some obstacles and their solutions include: Since buttons can be pressed at any time single digitalread statement can t capture it without a while loop. After the button is pressed at each step we need some sort of tracking system for our cursor and what user tries to do. This is particularly challenging for data collection states such as days of the week and time. For every state we implement a control statements and recursion to original function. LCD is slow and microcontroller is very fast relative to the lcd so we need to add appropriate delays in code to allow LCD to process instructions. We need to distinguish between the pills as per original pseudocode. This can be accomplished by creating separate global variables for each pill. We need to assign the times to the time unit. We are still working on this. Raw code for step1, which is Select Pill stage on the pseudocode.

Raw code for step2, which is Select Days of the week stage on the pseudocode.

(Note: other states raw code won t be posted because enter time step is much larger in size and verify entry and another pill? are similar to step 1.) 2.3 Testing/Verification 2.3.1 Test plans and procedures with specific timelines November 7 2017 November 7-November13 2017 November 13-November 20 2017 Test states communication and information fetching of LCD, microcontroller, buttons by giving input with buttons and checking result of microcontroller operation on lcd. Test time unit integration to the whole system by making sure that time unit accurately counts time,and notify microcontroller when it is equal to setup time, add LED to the system and check whether it is on during appropriate time. Debug and software-hardware communication problems Bootload code into microcontroller, Test the whole system on microcontroller 2.3.2 Modular testing or System testing Each of the steps on the pseudocode from design document is separately tested to make sure it outputs a correct result. For example for step 1, which is Select Pill state, the right button press needs to switch the cursor to the right and record its new pill number by adjusting the position. For step 2, which is Select Days of the week when we press enter it shows that that day was selected and if we press enter again it gets deselected. If we press right button it navigates to the next day until we navigate after Sunday entry and press enter. We test each code unit by giving our custom input and comparing the output of the system with what we expect. Each of the steps gets individually tested and after all modules behave as expected we integrate all the modules. We applied the same procedure for the motor sensor interaction. When sensor gets obstructed, the motor is tested to rotate amount we set in code in particular direction. When we test the time unit individually for functionality and make sure it operates correctly we would be ready to integrate all our code parts into one code. After our code is working under arduino, we will combine all parts with other hardware and our actual microcontroller. Such modular testing can simplify our design debugging.

2.3.3 Results As of November 6, 2017 all steps perform as expected and output correct results to LCD. The only issue is when user selects another pill option and then selects the same pill as before. When we tried it created overlap between previous timing parameters. The motor is also configured correctly and interacts with sensors in the right way. 2.3.4 Contingency plans for failed tests To fix aforementioned error we need to clear the data if user selects the same pill after another pill state but not alter it if user selects another pill. We would have to come up with the appropriate control mechanism to erase data depending on current and next state pill selection and use recursion after another pill state. 3. Conclusion 3.1 Self-assesment 3.1.1 Individual workload vs total workload for the project I am responsible for the great deal of the project. The software part is rigorous, consists of many modules and is appropriate in difficulty for the rigor of Senior Design. My lab partner is responsible of the hardware part, of which design details I am not fully sure. Since I am Computer Engineering major and he is Electrical Power Engineering, the responsibilities reflect individual major. 3.1.2 Ahead or behind of schedule We forgot to add time unit to the schedule on design document. Since it had to be replaced and arrived late we would have to deal with it this week. Otherwise, we are on schedule. 3.2 Plans for remaining work Timeline is similar to design document except adding of time unit to the design of our system. Our ambitious goal is to have a working version by Thanksgiving break. Realistically, we may need to use Thanksgiving break for further any debugging and suggested modifications.

4. Citations [1] Button. Arduino Tutorials - Button, Arduino, 28 July 2015, www.arduino.cc/en/tutorial/button. [2] Omron, Tactile Switch, B3F datasheet, July 2010. http://omronfs.omron.com/en_us/ecb/products/pdf/en-b3f.pdf [3] van den Berg, Wimpie. Displaying Sensor Values on LCD. Arduino Project Hub, Arduino, 14 Nov. 2016. http://create.arduino.cc/projecthub/guitarman1/displaying-sensor-values-on-lcdc0c44f