[time-nuts] IRIG-B audio decoder circuits and ICs sought

Esa Heikkinen tn1ajb at nic.fi
Tue May 19 16:59:13 EDT 2015


Joseph Gwinn kirjoitti:

> I'm studying up on how IRIG-B decoder circuits work.  What are the good 
> approaches, the bad approaches, especially in the presence of noise?  
> (I asked on the NTP group, with little result beyond the C/C++ decoder 
> software written for the audio channel of a 1990s Sun workstation, 
> which it ate alive: 50% cpu load.)

I was also searching chips for IRIG-B decoding lately, but didn't find 
any. Then I decided to create my own, mostly just for fun but there's 
also some uses for it. So I ended up to use 8-bit PIC16F873 and do 
IRIG-B DCLS decoding with it. DCLS means logic level IRIG-B signal from 
Symmetricom TS2100. So it's not 1 kHz modulated.

At a start it was only a time code decoder... Then, maybe because very 
rainy weather in the Finland, new features was added daily. For now, it 
calculates local time (calendar date and weekday) for IRIG-B day number 
and year and supports european daylight saving time. Leap second is also 
supported, if it's encoded in the IEEE1344 control bits (Tymserve TS2100 
encodes this, leap seconds are flagged one minute before the actual leap 
second). IRIG-B timecode is also verified by checking it's continuity. 
If there's momentary errors or total loss of timecode, timing continues 
in freerun mode. PPS is also generated from IRIG-B with about +-100 ns. 
maximum jitter (it's one instruction cycle of 'F873, so it cannot be 
done better with this MCU). If the whole system is rebooted due to long 
blackout with UPS batteries runout, TS2100 will jump back to January 
first of current year. And because TS2100 GPS functionality is now dead, 
it means that it will also continue with wrong time until it's manually 
set. Because of that, support for TS2100 resets was also added. Now it 
keeps record of passed dates on the EEPROM... :)

Now I have also DCF77 version of this, where PPS signal is replaced with 
unmodulated DCF77 timecode with same accuracy than PPS has. I'm planning 
to use this at least to build some kind of IRIG-B wallclock and possibly 
to syncronize radio controlled clocks locally with close field magnetic 
coupling, because actual DCF77 does not work here. However, when testing 
this I was little bit disappointed when noticed that radio controlled 
clocks doesn't seem to support leap secods at all. Also their time 
setting accuracy is not millisecond grade, so the +-100 ns. accurate 
DCF77 output is little bit overkill when the final setting error can 
easily seen by eyes...

Code is 100% assembler and full version with DCF77 encoder included (and 
of course with debug LCD drivers) takes only about 1,5 kilowords and 
needs only 66 bytes of RAM when running.

And it's still raining in Finland.. Have to see, what features will be 
added next.. :)

-- 
73s!
Esa
OH4KJU


More information about the time-nuts mailing list