Hi guys, > Yeah, I'm adding a redundancy check to all of the "get" functions. Verification (double read) of a single register does not help and probably makes things worse. I had a glance at the datasheet but did not see anything on atomic read. I can image reads are atomic when you read all registers at once. At least, since this is faster, the risk of a wrap-around is smaller. Anyone has experience with this on any RTC? What you could do is read the least significant byte first, then all other byte and last, re-read the least significant byte and check it has not changed. If it has, repeat the sequence.
> Maybe set the osc stop bit before writing the time and then clearing > it when finished would suffice? If that means timekeeping is stopped for a brief interval, you'll get significant deviation of time.... > I'm > also going to add a procedure to set the hr, min, and secs with one > procedure call as well as a function to retrieve the time in the same > manner. This is a good idea. This provides a efficient way to get a consistent set of time. The current functions allow you to uses time easy (transparent like time is kept on your pic) in apps. Joep -- You received this message because you are subscribed to the Google Groups "jallib" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/jallib?hl=en.
