Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of RTC8563 by
Revision 1:385198587f4b, committed 2015-04-22
- Comitter:
- Cartillius
- Date:
- Wed Apr 22 19:42:05 2015 +0000
- Parent:
- 0:e7072e1b5fa5
- Commit message:
- Imported library
Changed in this revision
RTC8563.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r e7072e1b5fa5 -r 385198587f4b RTC8563.cpp --- a/RTC8563.cpp Thu Apr 16 10:34:46 2015 +0000 +++ b/RTC8563.cpp Wed Apr 22 19:42:05 2015 +0000 @@ -56,6 +56,18 @@ void RTC8563::rtc_init() { + rtc_write(CONTROL1, 0x20); //stop + rtc_write(CONTROL2, 0x00); + rtc_write(YEARS, 0x15); + rtc_write(MONTHS, 0x04); + rtc_write(DAYS, 0x22); + rtc_write(HOURS, 0x21); + rtc_write(MINUTES, 0x34); + rtc_write(SECONDS, 0x00); + rtc_write(WEEKDAYS, 0x02); + rtc_write(CLOCKOUT_FREQ, 0x00); // 0x83 = TE on & 1Hz + rtc_write(TIMER_CINTROL, 0x00); + rtc_write(CONTROL1, 0x00); //start } void RTC8563::rtc_alarm()