Author Topic: System Time/date Problems  (Read 2206 times)

waalkman

  • Full Member
  • ***
  • Posts: 176
    • View Profile
System Time/date Problems
« on: December 12, 2004, 03:17:43 am »
Guys, I keep getting a "The system date doesn't seem to be valid" when I reboot (which is happening fairly often because of package manager lockups).

Usually the time isn't anywhere near accurate so I don't bother with it. But the system date messages are getting annoying

Currently I'm using OZ 3.5.2 on a C860, but I have had timekeeping problems with every ROM that I've tried. Not to mention my 5500.

Is there something wrong with how the Z keeps time?


Thanks.
C860, SMC Model SMC2642W, various sized memory cards

Bundabrg

  • Full Member
  • ***
  • Posts: 183
    • View Profile
System Time/date Problems
« Reply #1 on: December 13, 2004, 01:36:59 am »
Yes and no.

The C Series do not have a hardware clock. So each time you reset it will reset it to the beginning of the epoch.

However, there is a 'kinda' fix. Install the 'slutils' package. This creates a file 'sltime' in /usr/bin

Now each time you run 'sltime -set', it will take the current time and store it on the Z.
Each time you run 'sltime' (without any parameters) it will restore the saved time.

So it may be useful to have it 'set' the time when the unit is shut down, or each time it suspends, or even via cron every 30 minutes, and have it 'restore' the time on a reboot.

I'll probably create an ipk with this all auto one day soon.

 - Bundabrg
[img]http://www.worldguard.com.au/brendan-ambi.png\" border=\"0\" class=\"linked-sig-image\" /]

Bundabrg

  • Full Member
  • ***
  • Posts: 183
    • View Profile
System Time/date Problems
« Reply #2 on: December 13, 2004, 01:39:10 am »
Actually you shouldn't have time problems with pdaXrom. It already uses sltime by default. My only change with it was to add a cronjob that runs sltime -set every hour. When I work out how to do it on 'suspend'/'resume' then that would be a useful place.

 - Bundabrg
[img]http://www.worldguard.com.au/brendan-ambi.png\" border=\"0\" class=\"linked-sig-image\" /]

lpotter

  • Sr. Member
  • ****
  • Posts: 450
    • View Profile
    • http://qtopia.net
System Time/date Problems
« Reply #3 on: December 13, 2004, 04:10:26 pm »
Here's a bad hack of a init script that saves time on shutdown and restores it on bootup.
Software Engineer, Systems Group, MES, Trolltech
irc.freenode.net #qtopia
http://qtopia.net

waalkman

  • Full Member
  • ***
  • Posts: 176
    • View Profile
System Time/date Problems
« Reply #4 on: January 12, 2005, 01:46:34 am »
Thanks guys!

Sorry it took so long for me to get back to you, I was on vacation (sabbatical more like it).

Thanks for the package, I've already snagged it.

Surprisingly enough, cacko 1.22 does a good job of keeping time so I don't need it at the moment. I'm sure it will come in handy the next time I switch ROMs

Thanks again


John
C860, SMC Model SMC2642W, various sized memory cards

nianderson

  • Jr. Member
  • **
  • Posts: 75
    • View Profile
System Time/date Problems
« Reply #5 on: January 19, 2005, 06:58:35 pm »
Can we get that dateinit reattached after the forum move? or is it working for everyone but me?

thanks