Giter VIP home page Giter VIP logo

arduino-ntpd's Introduction

Arduino NTP server

This is a work-in-progress that will eventually allow the Arduino to act as an NTP time server using time data from GPS satellites.

Prerequisites

  • [Arduino Mega2560 or equivalent] 1
  • [GPS shield] 2 with appropriate [GPS module] 3 that outputs NMEA data. Tested with EM-406.
  • Ethernet shield.

Setup Guide

  • (optional) Solder wire from INT jumper on bottom of Ethernet shield to pin 48. Comment out ETH_RX_PIN in config.h if not done.
  • Solder 1PPS output from GPS to pin 49. GPS Shield currently comes with this unattached on the PCB.
  • Solder GPS RX/TX pins to the appropriate Serial1-3 pins. By default, GPS RX/TX is on pins 18 and 19, respectively, but this can be changed in config.h.
  • Assemble board and shields. GPS should be on top, Ethernet in the middle and the Mega2560 on the bottom.
  • Open sketch in the Arduino IDE.
  • Verify that everything in ArduinoNTPd/config.cpp and config.h look okay.
  • Upload sketch to board (right arrow button at the upper-left).

Licensing

New BSD license.

Unit testing code on PC

$ cd test; sh runTestApps.sh
Current time (seconds since 1900): 3579060209

arduino-ntpd's People

Contributors

lanurmi avatar micooke avatar tmiw avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

arduino-ntpd's Issues

Time is ~3 seconds off from https://time.is/ on first fix

To reproduce:

  1. Plug in Arduno and allow it to connect to the network.
  2. Update IP address of NTP server in Windows Control Panel and push Update Now until Windows accepts the time from it (approximately 2-3 times).
  3. Go to https://time.is/ in a browser.

It kinda sounds like a leap second issue but the code for that is disabled (not to mention that only 2 leap seconds were added since 2013). More investigation is required to know for sure.

Some modern C++ compliance issues

I'd like to fix - however I don't have permission to create a branch
Mainly the use of const strings where char arrays were expected (eg "/time" being passed where a char* or char[] was reqiured - C++ no longer permits this).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.