You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I saw, that getA1Time and getA2Time do not clear parameter AlarmBits before setting certain bits there.
Probably they were written this way to facilitate combining the AlarmBits of these two functions when called in sequence.
Please add a note in DS3231.h, that variable AlarmBits needs to be cleared before calling getA1/2Time to avoid 'random' output.
Also clear that variable in DS3231_test.pde.
This may be a reason for issue #7 (Alarm 2 gives wrong Alarm bits back).
If combining the AlarmBits of A1 and A2 is not so important for you, you may want to change the first assignment of AlarmBits in getA1Time/getA2Time from AlarmBits = AlarmBits | (temp_buffer & ...
to AlarmBits = (temp_buffer & ...
The text was updated successfully, but these errors were encountered:
I saw, that getA1Time and getA2Time do not clear parameter AlarmBits before setting certain bits there.
Probably they were written this way to facilitate combining the AlarmBits of these two functions when called in sequence.
Please add a note in DS3231.h, that variable AlarmBits needs to be cleared before calling getA1/2Time to avoid 'random' output.
Also clear that variable in DS3231_test.pde.
This may be a reason for issue #7 (Alarm 2 gives wrong Alarm bits back).
If combining the AlarmBits of A1 and A2 is not so important for you, you may want to change the first assignment of AlarmBits in getA1Time/getA2Time from
AlarmBits = AlarmBits | (temp_buffer & ...
to
AlarmBits = (temp_buffer & ...
The text was updated successfully, but these errors were encountered: