rtc_ds3231 v0.1.0 RtcDs3231
Use a DS3231 real time clock with a nerves system
I have only tested this with a raspberry pi and the sunfounder ds3231 board
References
Summary
Functions
Read the real time clock and return the time as a NaiveDateTime
Set the real time clock from a NaiveDateTime, discarding the century
Functions
Specs
rtc_datetime(Byte, Integer) :: {:ok, NaiveDateTime}
Read the real time clock and return the time as a NaiveDateTime
Example:
RtcDs3231.rtc_datetime(<<0x68>>)
The chip apperas to store a 2 digit year and flip the century bit when it overflows, hence the need to pass in the century.