Another Clock

  
WWVB Atomic Clock Controller Signalex Digital Clock

I built a new clock. Out of the dozens of clocks I built or modified, I made my first digital clock. Measuring 25¼ by 9½ inches, it is the biggest clock thus far.

   
Signalex Digits with Original Custom Made Controller PCB

It all began while at a Hamvention sometime during the mid-2000s, which at the time was still at Hara Arena in Dayton, Ohio. This fellow had four of these really large 6-inch numeric flip digits with each set of two of them connected to some kind of custom PCB. These industrial grade numeric displays were originally designed to be used in scoreboards and such.

These 4 digits sat around in the box I got them in until this year when I happened upon them. I then got an idea for another Arduino project.


Arduino Nano ATmega328P

In looking up the specs for various Arduinos such as the Nano, I realized I would either have to build a real time clock or find one. Well, the former Maoist Chinese will provide.


Real Time Clock DS3231 and AT24C32 I2C memory module

The Maxim DS3231 chip is said to be a really accurate I2C module RTC with an integrated temperature-compensated crystal oscillator (TCXO). The chip specs say the onboard TCXO is incorporated into the DS3231 chip.

The AT24C32 chip provides 32,768 bits of serial electrically erasable and programmable read only memory. This is where the date and time are stored.

Next…

I then asked myself, how would I set the time on this clock? Answer: why not let the government do that for me? I have this functionality built into all my other clock builds. That’s where the following off the shelf component comes in.


Universal Solder CANADUINO AM Atomic Clock Receiver module.

They designed this component around a receiver chip from Micro Analog Systems in Finland. This module was designed for use with micro controllers such as the Arduino with logic levels 3.3 and 5V.

Features:

  • Ultra-quiet LDO voltage regulator which handles up to 15V.
  • 4 LEDs to show the status of power, AGC, power down mode, and output.
  • Signal output, and an inverted signal output, capable of driving up to 15 mA.
  • AGC control on/off pin.
  • Power down control pin.
  • Fine-tuned 60 kHz ferrite rod antenna design with a short 60 mm antenna ferrite rod.
  • High sensitivity of 0.4µV (RMS).

Can be used to receive:

  • WWVB (US/Canada) 60kHz
  • JJY60 (Japan) 40kHz
  • MSF (England) 60kHz

This module has to be ordered with the correct crystal and antenna for the desired frequency.

  

The Digits


Staver Signalex 602L 7 Segment Numeric Display Flip Digit

ScoreTronics, Inc. Components Division manufactures and sells two sizes of the Staver "flip digits" (electromagnetic digits.) These were originated and supplied for many years by the Staver Company (Signalex) in Bay Shore, New York. This includes the 402L (4" - 100mm), and the 602L (6" - 150mm).

OK, now I have the Arduino, the RTC and the radio. So how do I get the Arduino to flip the digits? Turns out if the segment is to be showing or not, each of the 7 segments is flipped either by a positive or negative 12 volt pulse. I did find where several builders used MIC5601BN driver chips and initiated the pulse using the Arduino. Ah but what-the-heck. We are two decades past Y2K. So, why can’t I use another off-the-shelf component?


Sig7Seg-i2c Controller for Signalex 7 Segment display
Designed by May Fourth, Lancaster, PA

Well, what-d-ya-know. Someone does make a driver board – and they aren’t that expensive. They’ve got everything built onto them including mux and I2C bus connections. They are daisy-chained together allowing up to 8 of them to be connected via I2C bus. The I2C address for each controller is determined by 3 jumpers (A0, A1, A2) on each driver board. The boards are powered by 12v DC.

Along with the boards, they’ve published the necessary downloadable C++ Arduino driver library routines.

Address

SIG

J10 J9 J8

A0 A1 A2

31 (0x1F)

00

000

33 (0x21)

01

100

35 (0x23)

02

010

37 (0x25)

03

110

39 (0x27)

04

001

41 (0x29)

05

101

43 (0x2B)

06

011

45 (0x2D)

07

111

Pins are up – 0, down - 1

Note. There may be conflicts with certain LCD I2C address such as 39 (0x27). I only used the first four of the above SIG settings.

Sample Code:

#include <sig7seg-i2c.h>

Sig7segi2c sig0;
Sig7segi2c sig1;
Sig7segi2c sig2;
Sig7segi2c sig3;

void setup(void)

{
    delay(2000); // Wait for 12v to be fully power up and stabilized
    sig0.begin(0x00);
    sig0.clear();
    delay(20);
    sig1.begin(0x01);
    sig1.clear();
    delay(20);
    sig2.begin(0x02);
    sig2.clear();
    delay(20);
    sig3.begin(0x03);
    sig3.clear();
    delay(20);
}

void SetSig(byte digit0, byte digit1, byte digit2, byte digit3)
{
    sig0.write(digit0);
    delay(20);
    sig1.write(digit1);
    delay(20);
    sig2.write(digit2);
    delay(20);
    sig3.write(digit3);
}

The routines do all of the necessary conversions.

OK, before I wire up everything, I need to ask myself, “What’s this WWVB signal look like?” Well, it’s not bits on and off like one might expect. This is 1960s US cold war technology. There’s no forward error correction and no parity. Also, the data does not fit any common baud rate.

When I finally got the tiny radio PCB mounted on a proto board and a scope hooked up to it, I was confused. The signal kept switching on and then off again. I thought the board was defective. I then slowed the wave length of the scope down to 1 second per division. That’s when I noticed a pattern emerging. The data is transmitted via 1 second pulses with the width of each pulse indicating a different value.


WWVB Signal

The WWVB 60 kHz carrier, which has a normal effective radiated power (ERP) of 70 kW, is reduced in power at the start of each second by 17 dB (to 1.4 kW ERP). It is restored to full power some time during the second. The duration of the reduced power encodes one of three symbols:

  • If power is reduced for one-fifth of a second (0.2 s), this is a data bit with value zero.
  • If power is reduced for one-half of a second (0.5 s), this is a data bit with value one.
  • If power is reduced for four-fifths of a second (0.8 s), this is a special non-data "marker," used for framing.

Each minute, seven markers are transmitted in a regular pattern which allows the receiver to identify the beginning of the minute and thus the correct framing of the data bits. The other 53 seconds provide data bits which encode the current time, date, and related information. The beginning of a minute time data block can be identified by to two markers in succession. These are the end of one data block (59) and the beginning of the next (00).


By Denelson83. - Own work, CC BY-SA 3.0, commons.wikimedia.org/w/index.php?curid=3667565

The Atomic Clock Receiver module takes the incoming signal and shapes or creates square wave pulses. The receiver has available output data pins for either a positive pulse or an inverted negative pulse.

Note. The month and day needs to be converted from day of year to mm and dd. Date and time are UTC. The current time for the particular time zone must be calculated. The parameters for the calculations include time zone, DST, leap year, etc.

I downloaded the github.com/phanrahan/Arduino/blob/master/wwvb/wwvb.ino code to derive what I developed. There’s still a bug in that once in a great while, the Arduino code will display an erroneous time. This is likely due to RF noise and misinterpreting the data. It takes about two minutes to correct itself.

It’s on with the build

The clock case and frame are of a fairly simple construction. The digits are held onto a frame made of 1½ inch aluminum angle stock brazed at the mitered corners. I constructed the center (:) colon by gluing two small pieces of white painted aluminum to a black metal box-like bracket, which is the same height as the digits. The outer cabinet is 4 pieces of birch plywood mitered at the corners held together with biscuits. The front class frame which holds the glass is held on with decorative screws and is removable.

The metal clock frame is floating and is held in the cabinet by 8 screws through rubber grommets, hopefully quieting the noise made by the flipping segments.

I cut a decorative window mat out of some picture framing matting material to cover the edges between the 4 numeric segments and the colon. The little thing in the center in between the colon dots is an indicator LED that shows the radio is receiving a WWBV signal. This will blink on and off every second indicating each bit of data.

The controller:

From top to bottom:

  • WWVB Receiver with antenna connector
  • 2 sets of dip switches
    A 1 – Radio Test LEDs
        2 – Radio Power
    B 1 –  UTC on, STD off
        2 3 – EST off off
                 CST off on
                 MST on off
                 PST on on
  • 3 pin connector for 2 menu set-buttons
  • RTC
  • Arduino Nano
  • 2 I2C connectors 1 for LCD and 1 for the Sig7Seg-i2c controller
  • 12v to 5v converter with a LM7812 12v regulator benith
  • The rest is the 13v AC to DC regulator

   


Installed Sig7Seg-i2c Controller

   


The back of the clock with power, antenna and LCD control box connectors

   

 

Controller Box


Top Button Menu Select - Bottom Button Item Select

 Code Binary Description Type
0 00 Standard Time S
1 01 DST Ends Tonight E
2 10 DST Begins Tonight B
3 11 DST in Effect D

   The control box is also used to access the configuration menus.  These include:

  • Clock Type
    • 12
    • 24
  • Time Zone
    • E - Eastern
    • C - Central
    • M - Mountain
    • P - Pacific
    • U - UTC Time
  • Daylight Savings Time
    • Off
    • On
  • Manual Set
    • hrs: 00
  • Manual Set
    • min: 00
  • Display WWVB
    • Off
    • On
    • debug
  • Radio
    • Off
    • On
  • AGC
    • Off
    • On
  • Backlight
    • Level: 00
  • Contrast
    • Level: 00
  • Set Defaults
    • Exit
    • Reset

  

S January 15th 2020 - my 70th Birthday