Upload
abeni
View
64
Download
2
Embed Size (px)
DESCRIPTION
Get Up Stand Up GuSu. Group 5 Summer 09. Andrew Leger Joshua Rust Matthew O’Morrow Philip Bell. Problem. Can’t always wake up on time Most alarms are more “annoying” than waking Almost all alarms allow the user to go back to bed. Solution. Wake the user on time Wake the user “gently” - PowerPoint PPT Presentation
Citation preview
Get Up Stand UpGuSu
Andrew LegerJoshua Rust
Matthew O’MorrowPhilip Bell
Group 5Summer 09
Problem
•Can’t always wake up on time•Most alarms are more “annoying” than waking
•Almost all alarms allow the user to go back to bed
Solution•Wake the user on time•Wake the user “gently”
•Flexible and robust alarm clock allowing many options in both timing and method of waking the user
•Make sure the user is awake•Detect user’s presence in bed and do not allow snooze or off option during their waking time
Objectives• Timing
• Internal clock• Flexibility
• Full user control over “what” and “when”• Seven day alarm time programmability
• Options• FM tuner integration• MP3 audio integration via SD card slot• Tone buzzers
• User detection• Sensing system for detecting when user is in bed
Objectives• For thirty minutes after alarm time, if a user is
detected by the sensor system, the alarm will perform user chosen actions and silence itself anytime no user is detected
• The coffee maker will have local on/off control and will be remotely controllable by the alarm clock
• The alarm clock shall have a battery backup to prevent both clock time loss due to power outage and snoozing by unplugging
• Power usage will be designed around efficiency
Specifications
• System will not exceed 12”L x 9”W x 5”H
• It will display time and date in U.S. standard format (HH:MM) using LCD screen
• Battery backup will last through 8 hours or at least 4 hours (average power outage duration)
• PIR sensors will have 15 feet of wire for flexible placement
• Wireless integration will have a minimum range of 100 feet
System OverviewPhilip Matt -
Philip Josh
Andrew- Matt
Josh
Josh
Andrew
External Enclosure
Case DesignChosen material: WoodTop: PushbuttonsFront: LCD and SpeakerBack: Power cable,FM tuning knob, and SD Card slotSide: FM tuning knob
5”
12”
9”
Microcontroller
Microcontroller Requirements
• Handles all communication and control between external devices
• Must support USART, SPI, and I2C, ADC
• Five push buttons, XBee, MP3 decoder, FM Tuner, SD card
• Enough memory for system logic, device interfacing and capable of implementing a FAT16 file system (~14 KB)
ATmega644P SpecificationsThe ATmega644P is a 40 pin Advanced RISC Architecture microprocessor:• 64 KB Flash memory• 20 MIPS at 20 MHz• 8 bit ADC• Two UART ports• SPI ports• I2C port• Adequate amount of digital I/O pins for possible expansion of functionality
Alarm Implementation
Block Diagram
Microcontroller
Audio Amplifier
Buzzer
Speaker
MP3 Decoder
FM Tuner
Multiplexer
SD Card Reader
•A multiplexer (HI3-0509-5) will be controlled via the microcontroller to determine which audio device will be powered and passed to the speaker
•A common LM1458 Op-Amp will be used to amplify the audio, controlled with a digital potentiometer using I2C (AD5171)
Buzzers•Two buzzers will be used, the CPE-503 and the WST- 1205S
•The CPE-503 will be controlled with ramping voltage to slowly grow louder up to a maximum output of about 70 dB
•The WST-1205S will be turned on using 5V and has a set output of about 85dB, which is just under damaging sound levels from prolonged exposure
FM Tuner•TDA7000 chip chosen for implementation on a PCB without special processing hardware
•Tuning controlled via variable inductor and potentiometer, which will be part of the housing and connect to the PCB with leads for user tuning
SD Card Reader•SD Card will be used for playing MP3 files using the FAT16 file system
•Socket will be externally accessible
•Interface to the microcontroller will be SPI with only the option to read data
MP3 Decoder•STA013 chip used to decode data from SD Card through microcontroller SPI interface to speaker output
•When ready to receive data the STA013 sends a high signal to the microcontroller, simplifying implementation
•I2C data interface used for control
•It can determine sampling frequency up to 48 KHz and MP3 input rate of 320Kbit/sec, again simplifying implementation work required
User Interface
Physical user interface• Five pushbuttons
• Up, Down, Left, Right, Center
• Used to navigate menus during setting
• Used for audio controls while running and not within alarm time span
Liquid Crystal Display
•uOLED-160-G1 (Organic Light Emitting Diode)•Resolution: 160x128 pixels with 256/65K true color. Width: 1.81 in, Height: 1.26 in
•Chosen for 5 pin UART interface and full graphical display ability
Graphical user interface
• Current time• Day of the week• Next alarm time• Selected action and their order
Running Display Setting Display• What options can be changed
under current menu• Current setting• Highlight current selected
setting for changing
Sensor system
Sensor systemHypothetical Implementation
Sensor system• Wall/Ceiling mounted PIR sensor
• Aimed at bed• Wired directly for analog reading by GuSu system
• Wooden housing protects sensor and wires
• Allows for painting to match surroundings or “decorative” style
• Helps narrow sensing range to prevent detection of warm bodies outside of bedding area
Wireless Integration
Wireless IntegrationCoffee MachineThe coffee machine will be an off the shelf coffee machine which can be controlled locally or remotely by the alarm clock. The user can choose to enable the coffee machine start time with alarm time.
Xbee Series 1 Module • Complete System on Chip module
•Provides wireless serial interface
•Zigbee Compliant
• AES 128 Bit encryption
•Out of the box solution for enabling wireless communication between devices
Clock
Real Time Clock- DS-1307• Using an external clock will prevent timing issues in program execution.• Communicates with microcontroller over I2C interface• Stores HH:MM:SS and DD/MM/YYYY• Microcontroller pushes the next alarm time to the clock which in turn sends an interrupt back at alarm time
Power Supply
Power Supply
•A 5V and 3.3V DC power supply is required. Also, +12V and -12V is required to bias the Op-Amp•A Power LED and battery replacement LED indicate status
12V Wall Wart
3.3V Step-Down5V Voltage Regulator
Op-Amp
-12V Battery
AC Wall Outlet
Mp3 Decoder ZigbeeMicrocontrolle
r
FM Tuner
LCD Screen Clock/Timer
PIR Sensor
Buzzer
SD Card Reader
Battery Back-up
Device RequirementsDevice Voltage Req.
(DC)Current Req. (Active)
Microcontroller 2V – 5V <10 mAFM Tuner 4.5V – 5V 8mALCD Screen 4V – 6V 10-115 mA (typ. 40)PIR Sensor 3V – 5V <100uABuzzers 4V - 6V 30 mAMp3 Decoder 2.4V – 3.6V <30 mASD Card Reader 3V 20 mAClock/Timer 2V - 5.5V 2 mAZIGBEE 2.1V – 3.6V 40 mAOp-Amp +12V and -12V 5 mAMultiplexer +12V and -12V 3 mATotals 2.4-3.6, 4-5, -12,
12250 mA max
Main power supply is a wall wart that provides 12V DC, and allows for 1A of
current
Backup Battery•8 AA batteries in series will serve as the backup battery
•These provide the most cost-efficient implementation, and are easily replaceable for the user
•AA batteries store roughly 2800 mA*h of charge, so this would provide roughly 12 hours of supply to the clock, assuming every device was active
Schematics1. A common 12V wall wart will be
used to provide the power2. The backup battery (12V) will only
activate when there are power outages, and the LED will only turn on if the battery is failing
3. LM7805 voltage regulator used as step-down, with an LED for visible confirmation of “power on”
4. DE-SWADJ is a variable voltage regulator with built-in capacitances. It will be used to step-down to 3.3V
5. The Op-Amp will be biased with the +12V source and a 12V battery
Software
Software• Creation• Software Engineers
• Josh Rust• Philip Bell
• Programming Languages• Arduino/C++
• Development Environment• Arduino 0015
Design
• Control all devices and hardware connected to microcontroller
• Be complex enough to simplify user controls and implement the planned graphical user interface
• Total code size must not exceed 64KB
Software• Implementation
•Global variables for all user settings
•Two “Main” functions RunMode and SetMode invoke all other functions and decide behavior based on user interaction
Current State
Printed Circuit Board
•Current Finalized Design
•Filled Ground plane
•Created with ExpressPCB in conjunction with ExpressSCH
Current challenges• Another microcontroller may be necessary to control
MP3 decoder
• Final software design for tree menu navigation implementation
• Completion of base requirements in time to make productive attempts at “extra” features
• Complete unit testing of software will be complex
Project BudgetComponents Total Cost
uOLED-160-G1 LCD Display
$79.99 (1)
Amtel ATmega644-20PU
$7.87 (1)
Sanguino Dev Kit $25.00 (1)
Xbee Modules $46.00 (2)
Coffee Machine $20.00 (1)
Housing/Case Supplies
$25.00 (1)
SD Card/SD Card Socket
$8.45 (1)
DS1305 Clock Timer $5.06 (1)
TDA7000 FM Tuner $7.00 (1)
Passive Infrared Sensor
$3.80 (2)
Directional Infrared Sensor
$3.80 (2)
Fresnel Lens $1.75 (5)
PIR Sensor Module $7.40 (1)
Components Total CostInfrared Induction Control
$2.70 (3)
LP8072 PIR Sensor $1.80 (3)
M7612 PIR Controller $2.70 (3)
STA013 MP3 Decoder $13.80 (2)
28 Pin SOIC Adapater
$1.60 (2)
LM7805 5V Regulator
$0.51 (1)
DE-SWADJ 3.3V Regulator
$15.00 (1)
WST-1205S Buzzer $1.81 (1)
LM1458 Op-Amp $0.50 (1)
EAS-4P15SA Speaker $4.32 (1)
TS5A23159DGSR MUX
$0.81 (1)
Printed Circuit Board $80.00 (1)
Miscellaneous $25.00 (1)
Total: $391.67
Project milestones
Project Progress
Work DistributionAndrew• Power Supply• Battery Backup• FM implementation• PCB Design• Audio Output
Josh• Wireless Xbee Implementation• Software Libraries• External Enclosure Design• Clock Implementation
Philip• Physical User Interface• Graphical User Interface• Behavior/Control Software• Sensor System
Matt• LCD Implementation• MP3 Implementation• Project Website
Special ThanksMichael Angell ~ UCF B.S.M.E.• External enclosure schematics for Solid Works• Construction of external enclosure
Questions?