Crazy Alarm Clock - the GMU ECE Department

Crazy Alarm Clock - the GMU ECE Department
Crazy Alarm Clock
Description
The goal of the project is to build an alarm clock with creative snooze options to help people get out of
bed in the morning without hitting snooze excessively. The alarm clock will accomplish this by escalating
its snooze tactics from the standard beeping, to cognitive puzzles, all the way to the clock physically
running away.
Features
The alarm clock will have 3 stages as well as some standard features. Additional stages can be added if
time permits. Because of the nature of the stages and features, the project can be built modularly and
combined into the final product. Components or stages that prove too complicated or too simple can be
easily modified and still fit into the final product, allowing us flexibility over the course of the semester.
Stages
1. Play a repeating tone
2. Require a simple version of the simon game to be won
3. Run away
Features
●
●
●
●
●
●
Military clock
Set alarm time
Set minutes between snoozes
Choose tone
Turn alarm on/off
Snooze
Hardware Components
LCD Display
Rocker/toggle switches
Buttons
Adafruit Trellis
Piezo buzzer
DC gearmotors
H-bridge
Enclosure and Wheels
Software Implementation
We will use Timer A for the piezo buzzer as well as button debouncing, Timer B for the PWM signal to
drive the h-bridge, and the Real Time Clock for the military clock, alarm time, and snooze time. Buttons
and switches can be debounced using interrupts, whereas the Trellis will use an I2C connection. The DC
motors will be controlled through the h-bridge, utilizing PWM and enable signals to allow it to change
speed and change direction.
Program Flow
The military clock will always display, and the device will be in sleep mode until awoken by an interrupt.
Interrupts will occur either to set a feature, or it will be triggered by the alarm. When the user presses
the set button, the device will go into set mode, through which the user can set the time, alarm time,
snooze duration, and alarm tone. Alternately, when the alarm goes off for the first time, the device will
play the specified tone until the snooze button is pressed. The second time the alarm goes off, the
device will go into game mode which will repeat until the user wins the game. In the second stage,
winning the game is the only way to snooze the alarm. The third time the alarm goes off, the device will
play the specified tone and run away until the alarm is turned off. The third alarm does not have a snooze
feature, as the user is already out of bed. At any point, the user can toggle an alarm on/off switch to turn
the alarm on or off. During all stages, if the switch is turned off then the stage will end immediately.
Project Division
Main programmer – William Diehl
●
●
●
Building a state machine for the stages and features of the program
Setting up the real time clock and alarm/snooze set features
Combining all parts of the project into one program
Secondary Programmer – Cong Chen
●
●
●
Programming interrupts
Debouncing buttons and switches
Interfacing with the piezo and programming the tone set feature
Robotics Lead – Lakshmi Meyyappan (Project Lead)
●
●
●
●
Driving motors with H-bridge
Connecting power
Building enclosure and attaching wheels
Vector boarding and assembling final circuits
User Interface Lead – Alex Kaye
●
●
●
Interfacing with the keypad/Trellis
Interfacing with the LCD display and creating views for each stage
Building the stage two simon game
Was this manual useful for you? yes no
Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Download PDF

advertisement