DCF77 radio clock receiver for Ice Tube and Monochron

For RTC breakouts, etc., use the Other Products from Adafruit forum

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
bastard
 
Posts: 54
Joined: Tue Aug 25, 2009 7:10 am

DCF77 radio clock receiver for Ice Tube and Monochron

Post by bastard »

Hi all,

I would like to discuss the following idea with you:

I would like to connect a DCF77 radio clock signal receiver to my Ice Tube / Monochron Clocks (I own two of both and two Bulbdial Clocks too). Unfortunately there are not much free pins left to connect a DCF77 receiver.

For Ice Tube Clock the pins PD0, PD1, PB4, PC1 and PC2 are free to use.
For Monochron the pins PD0, PD1, BP4 and PB5 are free to use.

Usually a DCF77 receiver delivers a signal which is 0.1s long for a binary 0 or 0.2s long for a binary 1. More details are all over the Internet if you wish to learn more. Now to my questions:

Which of the above pins are able to read such signals for storing the binary into values? I think none, right?

If I'm right, there comes another idea. I could connect the receiver to another microcontroller - maybe an ATTiny would be fine - and do all the reading, converting and storing there. The connection to the clocks could use the RXD/TXD (PD0/PD1) and the communication could be in a unix-timestamp-format or similar.

Which ATTiny would be o.k. for that task?

Any further thoughts?

Bye

Stefan

PurpleTentacle
 
Posts: 2
Joined: Tue Oct 05, 2010 3:46 pm

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by PurpleTentacle »

Hi Stefan,

I am also working on connecting a DCF77 receiver to my monochron. I would prefer not to add an extra microcontroller (ATTiny-idea) to the clock.

The pins PB4 and PB5 are not free. They are connected to the display. The RXD (PD0) and TXD (PD1) pins can be very useful for sending/receiving debug messages to/from a PC. I would not use them for anything else, if possible. The Pin PC1 is free and can be used to connect the receiver. It is not an interrupt-pin so you have to poll.

Have you thougt of which timer you want to use? As all three timers are in use, i think i will do the polling in the interrupt function of timer 0, which is called once every millisecond.

If you still plan to use a second microcontroller, you should pick one with SPI. This makes serial communication to the main microcontroller a lot easier. In my opinion, ISP is also a must-have. Maybe you can use something like an ATTiny48. If you are searching for examples how to evaluate the serial data
on the main microcontroller, you can take a look at the code of the GPS-mod.

Fabian

User avatar
dataman
 
Posts: 98
Joined: Wed May 20, 2009 7:03 pm

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by dataman »

Latest version of MultiChron has GPS baked in.
I know, I wrote it!

Pretty much just hook up rx.
You should be able to modify that pretty easily.

And small correction, Yes Rx and TX are wired,
But only TX is really needed to output messages.
When debugging is disabled, there's no output on TX.
You could repurpose both.

If you still need a coprocessor...
Have you seen the Teensy?
It's an incredible little devide, and cheap.

bastard
 
Posts: 54
Joined: Tue Aug 25, 2009 7:10 am

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by bastard »

Hi Fabian,
PurpleTentacle wrote:I am also working on connecting a DCF77 receiver to my monochron. I would prefer not to add an extra microcontroller (ATTiny-idea) to the clock.
nice to hear, I'm not alone! Thanks for your thoughts. Here are mine:
PurpleTentacle wrote:The pins PB4 and PB5 are not free. They are connected to the display.
I do not agree. Take a look at the schematics. Pin PB4 is MISO, PB5 is SCK. They are only used during reprogramming the chip.
PurpleTentacle wrote:The RXD (PD0) and TXD (PD1) pins can be very useful for sending/receiving debug messages to/from a PC. I would not use them for anything else, if possible.
O.k.
PurpleTentacle wrote:The Pin PC1 is free and can be used to connect the receiver. It is not an interrupt-pin so you have to poll.
That's a problem - hopefully only in my mind. I have by now no idea how to poll that pin often enough to distinguish a binary 0 to a binary 1. Do you have an idea?
PurpleTentacle wrote:Have you thougt of which timer you want to use? As all three timers are in use, i think i will do the polling in the interrupt function of timer 0, which is called once every millisecond.
No, I havn't, because I never thought about polling that pin. But maybe there is a possibility to do it, I'll be fine with that.
PurpleTentacle wrote:If you still plan to use a second microcontroller, you should pick one with SPI. This makes serial communication to the main microcontroller a lot easier. In my opinion, ISP is also a must-have. Maybe you can use something like an ATTiny48. If you are searching for examples how to evaluate the serial data
on the main microcontroller, you can take a look at the code of the GPS-mod.
My plans so far are to use this receiver module - I have one already with this clock and it works fine. There is enough room inside the case to have a controller inside.

Stefan

PurpleTentacle
 
Posts: 2
Joined: Tue Oct 05, 2010 3:46 pm

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by PurpleTentacle »

Hi all,

I've now connected a DCF77 receiver to pin PC1 of my monochron and it works fine! I made a fork of the MultiChron project on github to add the DCF support to the firmware. The sources can be found under:

http://github.com/PurpleTentacle/monochron

The hardware modifications are described in a howto document:

http://github.com/PurpleTentacle/monoch ... oDCF77.pdf

@Stefan: It may be possible to connect your external DCF receiver to the clock in the same way, but you will probably have to modify the case to get it wired.

Fabian

bastard
 
Posts: 54
Joined: Tue Aug 25, 2009 7:10 am

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by bastard »

Hi Fabian,
PurpleTentacle wrote:I've now connected a DCF77 receiver to pin PC1 of my monochron and it works fine!
Great news! I can't wait until weekend to hack my monochron too. I'll post pics when done. If we ever meet in Germany, I'll spend you a beer!
PurpleTentacle wrote:@Stefan: It may be possible to connect your external DCF receiver to the clock in the same way, but you will probably have to modify the case to get it wired.
Yes, but putting it inside the case is more beautiful.

Thanks again!

Stefan

bastard
 
Posts: 54
Joined: Tue Aug 25, 2009 7:10 am

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by bastard »

Hi all,

finished.
monochron dcf77 028 (Large).jpg
monochron dcf77 028 (Large).jpg (126.66 KiB) Viewed 6701 times
More pictures and the hole story (no radio signal while antenna inside the case ...) goes here. Enjoy!

Stefan

User avatar
rickrump
 
Posts: 77
Joined: Sat Jan 16, 2010 1:54 pm

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by rickrump »

Using Adafruit's "Basic GPS Module" PMB-648 with Monochron. Have attached +5, gnd to 7805 pads, Tx (yellow wire) to Pin 2 of uP, tied Rx to +5V. Getting NOLOCK and data stream "BANNED>BANNED" (see photo). Have GPS located in same location (in basement south window) where my iPhone and my AT&T MicroCell both can "see" GPS satelittes and get a fix. Red LED on GPS module is solid.

So what am I doing wrong?

Thanks for any ideas.

Rick
GPS Setup Screen.JPG
GPS Setup Screen.JPG (117.12 KiB) Viewed 6330 times

User avatar
rickrump
 
Posts: 77
Joined: Sat Jan 16, 2010 1:54 pm

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by rickrump »

Just curious how we know what the data rate coming out of the GPS module is? Does the GPS data standard set that? Only mention that because the data stream looks like it might be a data rate mismatch in the UART.

Rick

adafruit
 
Posts: 12151
Joined: Thu Apr 06, 2006 4:21 pm

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by adafruit »

all GPS units use 4800 baud, but there are a few different wires, make sure you have the TTL 4800 baud TX wire

User avatar
rickrump
 
Posts: 77
Joined: Sat Jan 16, 2010 1:54 pm

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by rickrump »

Using Pin 1 (yellow) from GPS marked TxD. The RS232 TX is just marked Tx.

I attached the Bus Pirate to that wire and saw the expected NMEA sentence streams from it (at 4800 baud.) It's almost like the TX port on the 328 isn't getting set to the right data rate, but I looked at the code and see that it is set to 4800 bps.

The Monochron clock works in all other ways. I will try reloading the firmware, but according to the "About" screen, I have the latest loaded from GitHub. (1.1b)

Any other suggestions?

Rick

adafruit
 
Posts: 12151
Joined: Thu Apr 06, 2006 4:21 pm

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by adafruit »

you want to connect to the microcontroller RX

User avatar
rickrump
 
Posts: 77
Joined: Sat Jan 16, 2010 1:54 pm

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by rickrump »

Yup, got that. Pin 2 on the 328. When it is NOT attached, I see NO data on the GPS setup screen. When it IS connected, I see the garbled data in my picture.

Rick

adafruit
 
Posts: 12151
Joined: Thu Apr 06, 2006 4:21 pm

Re: DCF77 radio clock receiver for Ice Tube and Monochron

Post by adafruit »

sorry, we didnt write the GPS mod but you're also posting in a completely different thread.

Locked
Please be positive and constructive with your questions and comments.

Return to “Clock Kits (discontinued)”