Git Product home page Git Product logo

raspberry-wwvb's Introduction

raspberry-wwvb

WWVB clock signal transmitter on Raspberry Pi

Introduction

WWVB is a US station that transmits radio signals that can be received by radio-controlled clocks to adjust their time: https://en.wikipedia.org/wiki/WWVB. This project uses Raspberry Pi to mimic the WWVB signal: it could be useful in cases when real WWVB signal is too weak or cannot be received. For instance, I use Raspberry Pi to set correct time of my Casio WaveCeptor watch desined for US market (that can only receive WWVB signals) outside of US.

Prerequisites

The code uses WiringPi library to control hardware PWM of Raspberry Pi. WiringPi should be installed prior to compiling the code. Installation instructions are here: http://wiringpi.com/download-and-install/

Hardware setup

Plug a wire to the Raspberry Pi GPIO pin 18 (PWM0), it will serve as an antenna. See here to locate the pin: https://pinout.xyz/pinout/pin12_gpio18. Since the transmitted signal is very weak, you need to place your clock/watch maximum a few centimeters away from the antenna wire.

Software setup

Run ./build.sh script to compile the WWVB program. Once the program is built, you will need to run it as root:

sudo /home/pi/wwvb

In its current configuration, the program will transmit the signal for 10 minutes, after which it will exit. Normally 10 minutes is sufficient to adjust the clock.

It is convenient to run the program around the time when the signal is expected to be received by the clock. My Casio WaveSeptor watch try to receive the signal for a few minutes at the start of every hour during the night (12am, 1am, ... 5am), so I set up cron to run the transmitter around these times. Here's the extract of my crontab:

# m h  dom mon dow   command

59 23 * * * sudo /home/pi/wwvb
59 00 * * * sudo /home/pi/wwvb
59 01 * * * sudo /home/pi/wwvb
59 02 * * * sudo /home/pi/wwvb
59 03 * * * sudo /home/pi/wwvb
59 04 * * * sudo /home/pi/wwvb

raspberry-wwvb's People

Contributors

apoluekt avatar rezin8 avatar

Watchers

James Cloos avatar

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.