Skip to content

shaddow501/Sodaq_DS3231

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sodaq_DS3231

This is an Arduino library for the DS3231 RTC (Real Time Clock).

Table of Contents

Changelog

Version 1.2.1

  • Change library to use with ESP8266
  • Add now example fpr ESP8266

License

Released under MIT License http://opensource.org/licenses/mit-license.php

Authors

Since Version 1.2.1

Till Verison 1.2.0

For more information see old readme

Information

Usage

Transmit update as ASCII String with CR and LF and the end over the serial to update the DS3231.

Connection

DS3231 Schield ESP8266
Vcc Vcc
GND GND
SDA D4
SCL D5

ESP8266 GPIO
Please use a DS3231 shield. If you are using the DS3231 without any shield you have to add pull up resistors to SDA and SCL.

NTP Specification

NTPv4 Basic Header

Bytes Description
0 LI (Bit 6-7), VersionNumber (3-5). Mode(0-2)
1 Stratum
2 Poll
3 Precision
4 - 7 Root Deleay
8 - 11 Root Dispersion
12 - 15 Reference ID
16 - 23 Reference Timestamp
24 - 31 Origin Timestamp
32 - 39 Receive Timestamp
40 - 47 Transmit Timestamp

Transmit Timestamp

Time at the server when the response left for the client, in NTP timestamp format.

NTP Timestamp format

Bytes Description
0 - 3 Seconds scince 1900
4 - 7 Fraction of Second

About

Arduino library for DS3231

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C++ 95.2%
  • Shell 4.8%