Close
0%
0%

"Connect" to an atomic clock in space! GPS, DCF77

This project is a clock with radio receivers which can receive the exact time from the GPS satellites or from the DCF77 transmitter.

Similar projects worth following
This project is a clock with radio receivers which can receive the exact date and time from the DCF77 time signal transmitter or the UTC from the GPS satellites and display it on a 128x64 pixel graphic display. DCF77 transmitter and GPS is synchronized to an atomic clock. So basically this project can "connect to" an atomic clock.

This project is an open design: open hardware and open source software.

Objectives:

  • receiving date and time from the DCF77 transmitter, decoding it, displaying it on a 128x64 pixel dotmatrix display
  • receiving UTC from GPS satellites with a GPS module, displaying it on a 128x64 pixel dotmatrix display
  • stand-alone date and time clock based on a real time clock (if radio signal reception is not possible)
  • measuring and displaying temperature
  • measuring and displaying battery voltage
  • displaying SW version information
  • simple menu system for configuration
  • alarm function
  • beep sound on button press

HW block diagram

On the picture below You can see the HW block diagram.

I built the project around a PIC microcontroller. The goal was during the micro selection is to have a low power consumption but yet powerful enough controller to decode the DCF77 and GPS signals and to drive the display. I also choose a type which I familiar with.

The display is a chip-on-glass type which can be powered from 3.3V. It can be controlled via a simple SPI protocol. Another advantage is that no mounting required, it can be simply soldered on the PCB, but i will use a header adapter so the display can be changed easily.

The LED backlight is powered with an NCP5005 boost driver. The clock will be running from 3 AA batteries. To decrease the power consumption the SW has to have some intelligence: dimming, or even switch off the backlight at certain time of the day.

I used a small 32768 kHz real time clock crystal, so the clock can remain relatively punctual even when no DCF77 or GPS reception is possible.

For temperature measurement an analog LM20 sensor is used.

In order to measure the output of the temperature sensor and the battery voltage accurately an LM4041 voltage reference is used.

Programming and debugging is performed with a PICkit3 programmer, so a header adapter is connected to the ICSP of the micro as programmer connector.

For powering the whole circuit 3 AA battery is used and a very low drop 3.3V voltage regulator.

For easier debugging and for measurement purpose during the development a red LED is directly connected to a micro output with a series resistor.

To be able to operate the menu and set the date and time 3 taktile type push buttons is connected to 3 microcontroller inputs with pull-up resistors.

A TDK PS1720P02 piezo buzzer is used for generating a sound signal when a button is pressed and for the alarm clock functionality.

For UTC reception from a GPS satellite a PmodGPS module is used from Digilent.

For exact time and date reception a DCF 77 receiver module with digital output is used from Conrad electronics.


Schematic

On the picture below You can see the schematic of my project.

I tried to isolate the main blocks therefore I added a grey dashed line frame around them to easily identify which block is doing what.

I used Eagle 6.6.0 PCB editor for creating the schematic.


System design: GPS signal processing

What is the interface protocol of the PmodGPS module?
According to the data sheet "The PmodGPS uses sentences based on National Marine Electronics Association (NMEA) protocols for data output. Each NMEA message begins with a '$' dollar sign. The next five characters are the talker ID and the arrival alarm.
The PmodGPS talker ID is 'GP' and the arrival alarm is the specific sentence output descriptor. Individual comma separated data fields follow these five characters. After the data fields there is an asterisk followed by a checksum. Each sentence should end with <CR><LF>. <CR> is the carriage return its ASCII value is 13, <LF> is the line feed character its ASCII value is 10.

You can see an example GPS sentence on the picture below:

Some other examples:
$GPGGA,064951.000,2307.1256,N,12016.4438, E,1,8,0.95,39.9,M,17.8,M,,*65<CR><LF>
$GPRMC,064951.000,A,2307.1256,N,12016.4438,E,0.03,165.48,260406,3.05,W,A*55<CR><LF>

How we receive these GPS sentences?
Each character in the GPS sentence corresponds to one UART (Universal Asynchronous Receiver Transmitter) byte. The data value of this byte is equals to the corresponding...

Read more »

View all 10 components

View all 17 project logs

  • 1
    Step 1

    Prepare DCF77 receiver module

    1a. Drill 6mm hole in Deltron 479-0140 enclosure

    1b. Solder DCF77 receiver to a 3.5mm jack, epoxy glue components to enclosure.

    1c. Screw back the top cover: DCF77 receiver box is ready

  • 2
    Step 2

     Prepare clock

    2a. Drill 6mm hole in Deltron 479-0160 enclosure

    2b. Super glue 3xAA battery golder into the enclosure

    2c. solder 3.5mm jack to wires and connector, heatsrink it

    2d. prepare PCB

    2e. populate PCB

    2f. Super glue PmodGPS module into the enclosure

    (note: as turned out super glue is not the best idea, since when the glue hardens it emits some kind of fume which precipitate on the inner side of the enclosure leaving a white layer so it not so nice)

    2g. connect wires

    2h. Screw PCB into final position. Clock is ready!

  • 3
    Step 3

    3a. Connect antenna and clock with a 1.5m 3.5mm jack cable! Enjoy the exact time! 

View all 3 instructions

Enjoy this project?

Share

Discussions

DL101 wrote 06/08/2014 at 14:09 point
Hi.

I've tried poking with that DCF77 reciever, and it is very unstable, I had to go on my balcony to get any reception at all, indoors there is too much interference from the computer and other electronics. What is your plan to obtain a stable connection??

  Are you sure? yes | no

hkdcsf wrote 06/08/2014 at 15:30 point
Hi,

Thank you for the very good question.

My current plan to increase reception robustness is the following:

- first I try to improve the robustness from SW side as much as possible. E.g. you can help a bit on interference with the decoding algorithm, for example my current algorithm applies a windowing method, this means that after I received the “minute mark”, my algorithm accepts an edge transition only in the near vicinity of the possible edge transition times, so unwanted edge transition caused by the interference can be filtered
- than I may poke with the HW sensitivity too
- i find that the ferrite antenna is quite sensitive to nearby (~cm) metallic objects (PCB, battery) so I try to design an enclosure where the ferrite antenna is relatively far from these objects
- i may implement some FET preamplifier like solution, but now the SW solutions are in focus

I plan to implement some convenient feature:
- when i have a frame correctly received I will picture an antenna symbol on the display, so the user is aware that in the last few minutes the clock is synchronized

Currently I concentrating on the back-end, but when I switch to front-end again I will share my experience and solution.

  Are you sure? yes | no

DL101 wrote 06/08/2014 at 16:07 point
I do hope it will work. I see you are from Hungary, and I am currently in Zagreb (Croatia), so the signal levels that you will be receiving will be similar to what I have here, and the situation here is kinda bad. My plan was to build a small device that would have the DCF77 receiver, a solar cell and a 433MHz transmitter in it, and that would be places somewhere outside, receiving the DCF77 signals, and re transmitting them on 433MHz, which could be easily received by the clock that is indoors.
Another idea that i had is to put a bnc connector, and connect the antenna which is located elsewhere via a coaxial cable.

  Are you sure? yes | no

Uhrheber wrote 07/18/2014 at 11:51 point
dajgoro.labinac, take a look at http://www.ethersex.de/index.php/Clock_%28Deutsch%29
Unfortunately in german, but google should help.
Ethersex can (amongst many other things) receive DCF77, run it's own ntp server, connect to other nodes or to the LAN via RFM12 rf modules (433 or 868MHz), USB, Ethernet.
All on a single AVR micro.

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates