real-time clock

Hi,

I have strange behaviours with my real-time clock (RTC) on my embedded
system.
I spare you the boring details, my only interesting questions are :

(1)
when I type :

rtc hw

I sometimes got the following return message :
RTC: Clock not running, Must be set first 0x60
what does it means ?
What the “0x60” for (sometimes it is 0x40 instead) ?

(2)
Does NTO 6.x change the value of the real time clock state register A (a.k.a
“control 1”) ?
If yes, why ?

Best Regards,
Cyril.

What the “0x60” for (sometimes it is 0x40 instead) ?

  1. These two cases correspond to RTC being held in reset, with the
    oscillator enabled and RTC being held in reset with the oscillator being
    disabled. In either case, the clock will not run until you write a pattern
    of 010 to Register A.

Does NTO 6.x change the value of the real time clock state register A
(a.k.a “control 1”) ?

  1. Yes, the value of Register A is modified when you run rtc -s hw. This
    will set the internal oscillator running by writing a value of 010 to the
    register, and is the only instance where register A is set.

Cheers,
-Brian


+================================================+
Brian K. Hlady bhlady@qnx.com
Technical Account Manager (613) 591 0836
QNX Software Systems, Ltd. extension 9268
+================================================+

“Cyril OTHENIN-GIRARD” <cothenin@bcisa.com> wrote in message
news:arluub$pge$1@inn.qnx.com

Hi,

I have strange behaviours with my real-time clock (RTC) on my embedded
system.
I spare you the boring details, my only interesting questions are :

(1)
when I type :

rtc hw

I sometimes got the following return message :
RTC: Clock not running, Must be set first 0x60
what does it means ?
What the “0x60” for (sometimes it is 0x40 instead) ?

(2)
Does NTO 6.x change the value of the real time clock state register A
(a.k.a
“control 1”) ?
If yes, why ?

Best Regards,
Cyril.