Rockbox.org home
release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide



Rockbox mail archive

Subject: RTC alarm works - any software design ideas? (was: need RTC help!)

RTC alarm works - any software design ideas? (was: need RTC help!)

From: Uwe Freese <mail_at_uwe-freese.de>
Date: Wed, 8 Jan 2003 16:31:36 +0100

Hello Zagor & all others,

Now it works: My AJB was successfully switched on from the RTC alarm
function after switching if off!

The problem was the Trec bit. It is set to 1 when Vcc is turned on. If I
set Trec to 0, it means that the RTC is write-protected for 200 ms after
Vcc goes down (switching off the AJB). And so the alarm works.

I will now add a firmware/rtc_alarm.[c|h] (locally at my computer, not
in CVS of course) with a function that sets the alarm and can read a
.rockbox/default.alm after startup.

So the user (at the moment: me ;) ) can set an alarm time in the format
"08:30" in this file to wake up with music..

This will be enough for now. In the future, one could add:

- format of default.alm so that the user can write "timers". That means
  the device switches on at the given time and plays a playlist/dir or
  records something.
  I think of a format like this:

MTWTF-- 08.30 /music/test dir/
MTWTF-- 09.00 shutdown
08-12 10.30 record /recorded/radioshow.mp3
08-12 11.00 shutdown

- with an option, one could tell rockbox if the alarm mod is done at the
  AJB. If not, all the timer functions can work the same way - only the
  AJB stays on the whole time.

What ideas do you have for this? Comments?
Zagor: Did you plan a general timer function like this in more detail?
It would be nice if I know what you planned. I'd like to implement this,
but don't want to add features that nobody wants/needs.

For the electronics part: Expect a detailed description and photos of
this mod in a few days if all works fine.

Bye, Uwe.
Received on 2003-01-08

Page template was last modified "Tue Sep 7 00:00:02 2021" The Rockbox Crew -- Privacy Policy