I build clocks as a hobby. I'd like to use an Arduino UNO in my next clock, but I am completely new to both C++ and Arduino itself.
Things I'd like to have the Arduino perform (in order):
keep track of time
detect alarm time
create noise via loudspeaker
read input from keyboard
display inputs on 16x2 LCD screen
if inputs from keyboard match a specified string of numbers (4, 8, 15, 16, 23, 42), stop noise and clear screen.
loop the entire process, so that it occurs at a set time every 24 hours.
I've read and watched a few tutorials, and i've managed to come up with some pseudo-code, but I am still confused as to how to implement it, or what hardware I would need.
if (current time == alarm time)
{
set alarm ON;
}
...
if (alarm is ON)
{
read keyboard characters into buffer;
if (the buffer contains expected string)
{
set alarm OFF;
empty the buffer;
}
}
I know that I'm missing about 80% of what I need to make this work, but I'm willing to learn, if I can be set in the right direction.
(but, if you just wanted to write out a full sketch for the project, that would be cool too)
I like clocks as well (and also Lost). I'd suggest not trying to eat the whole elephant in one bite. Using a real-time clock (RTC) is a good suggestion. Get one, learn to set it, read it, etc. ... that's one bite. Making noise, reading a keyboard, driving an LCD are others. Approach them as individual mini-projects, conquer each device then they can be combined. Definitely read up on C/C++ if that's new to you. Google around, there are plenty of tutorials online. Just diddle around with some simple Arduino projects (just one example) to get a feel for what the thing can do. This will also be programming practice. There's a learning curve, take it one small step at a time and it should be a lot of fun.
Ask questions, pick the right board to post on, give enough background, code, wiring diagrams (schematics), etc. so folks can understand what you're trying to do, what you've tried, how it didn't work, etc.