-
Notifications
You must be signed in to change notification settings - Fork 709
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DS3231: Add support for the Aging Offset Register #300
base: master
Are you sure you want to change the base?
Conversation
Could this somehow be connected to the 'issue' I've just raised Cannot update to latest version 2.1.4? |
@terrypin999: I don't know. Maybe the library manager sees you have a manually-installed version of RTClib, and this prevents the upgrade? |
Appreciate the fast reply. That sounds right because meanwhile I then tried IDE 2.3.2 which told me: and listing several, all beginning with 'RTClib'. I have always assumed that the |
Does 2.1.4 includes your work on the Aging Offset Register? If so, and I succeed in updating to it, then it will obviously 'break' my existing sketch, as I edited RTClib.h and replaced that file in my RTClib library. (So I'll then need to explore how to use the new method.) However I don't understand why, still using 2.1.3 (a library that apparently no longer exists in Manage Libraries!) my sketch no longer compiles. It gives the error |
@terrypin999: This pull request is still open, which means it has not been merged into the official repository. As for the compile error, I would guess the library manager re-installed the official 2.1.3 version. |
Thanks, understood. But still don’t follow why unable to update to 2.1.4. Or why 2.1.3 not in the list (or 2.1.2). |
Also see #270 |
The DS3231 has an “aging offset” register that can be used to finely trim the frequency of the oscillator, and hence compensate for any frequency inaccuracy that may come as the resonator ages. Advanced users can measure the drift rate of their RTC by comparing with a reliable reference, then use this register to calibrate-out that drift.
This pull request adds support for using the Aging Offset register. It adds the following methods to the class
RTC_DS3231
:as well as Doxygen comments explaining what this register is about.
These methods were tested by @terrypin999 (see #299) using the sketch below (
#ifdef
ed-out code removed):Source code (click to expand/collapse)
Fixes #299.