CMOS Nixie Tube Clock Project: Part 1
One of the Nixie tubes from my old frequency counter
Nixie N00b
I'm starting this post after having done quite a bit of design work on this particular project, already. I acquired several Nixie tubes last year around this time in the form of a display from a broken Hewlett Packard frequency counter that I bought at an estate sale. Most of the parts in the frequency counter were pretty trashed from being in a barn for goodness knows how long, but the tubes were still in decent condition, and I'd always wanted to make a Nixie tube clock.
Before I go on, for those of you wondering what this "Nixie tube" thing is, wonder no more. They are a type of digital display popular in the 60s and 70s. Though it looks like a vacuum tube, it is actually filled with low-pressure neon. Inside each tube are multiple negative electrodes (cathodes) in the shape of numerals or characters. When one of the cathodes is energized, that cathode glows orange from the electrical discharge in the neon gas, displaying the desired character or numeral as a glowing orange outline.
The frequency counter sat in my apartment for about a month before I got around to taking it apart, and then I had eight Nixie tubes and no idea how to actually use them. Fortunately for me, Nixie tube clocks are quite the popular hobbyist project. I learned several important things: the specific tubes I have are of type IN-12, you need a high voltage DC supply (~180 V) to drive them, and almost nobody makes binary to digital converter chips that can handle those voltages anymore. But we'll come back to that later.
Breadboard version of Threeneuron's Nixie power supply
Before I started designing a clock, I needed to figure out whether the tubes actually worked or not. The piece of equipment that they came from was in no shape to even turn on enough to give me the 180 V I needed to test the tubes, and I am not a well-enough established electronics hobbyist to have a high voltage DC bench supply lying around. I would need a DC boost converter built into my clock circuit, anyway, so I looked around for good designs.
The first one I came across was the one on Threeneuron's Pile O'Poo. I bought the components and put together a breadboard version. This worked well enough to test the Nixies, but it had stability issues that I wasn't able to determine the cause of where it would randomly drop in output voltage. I assume it was something wrong with my implementation because several projects I've come across have used this design successfully. However, I also lack the equipment to do signal analysis of a cyclic circuit like a boost converter, so I just scrapped it and tried another design.
The design I tried next was from this Instructables article. It uses elements from several different designs (including Threeneuron's), which also meant I could reuse several of the components I had bought for the first power supply iteration. And when I bought the components and put the circuit together, its output voltage was rock solid.
Power supply from Instructables article. One thing to note, even though the rotary switch I'm using to switch the inputs on the tube is on the ground side of the Nixie tube, only one of the pins (the one connected to the illuminated digit) is actually grounded; the ungrounded pins are still floating at 60 to 100 V. Fortunately, I didn't die, but in retrospect, I should have mounted the switch such that I didn't have to risk touching the solder lugs in order to actuate it.
Design Goals
With the tubes and power supply tested, I needed a clock design. One popular design, the Arduinix, is an Arduino shield that multiplexes the output pins of an Arduino to drive enough Nixie tubes to make a clock display. I already have the Arduino, and just writing a clock program and multiplexing the output to a Nixie display would be a nice way to get a functional Nixie tube clock. But I like to torture myself, so I decided to try to make a clock using just a bunch of binary counters and some logic gates. Hell, if Dave Jones could do it back in the 80's, I can, too.
So what does a clock need to do? Well, obviously it needs to tell time. Beyond that, there were several extra features that I wanted my clock to have:
- Switchable between 12-hour and 24-hour format
- Independent hour/minute set buttons (the kind of time set buttons that just run the clock forward faster annoy me)
- A "blank display" switch to turn off the Nixie display if I don't want it to be running for whatever reason
- A battery backup mode that would run just the logic, but not the display
- A display shutoff override so you can still read the time, on demand, when the clock is in battery backup mode.
And I needed to figure out how to do all of those things with switches and logic chips. Some of them are easy. The "blank display" switch can just be a switch that disconnects the boost converter circuit, so there is no high-voltage to run the tubes. The battery backup mode can be achieved with some well-placed diodes, and the battery backup display shutoff override can just be a switch that shorts out the diode isolating the high voltage supply from the battery backup. But I also didn't know the first thing about choosing the types of logic chips I needed, or even what types are available.
The one criterion I knew I needed to fulfill was the chips had to be compatible with a 9V supply voltage, because that is the voltage needed to drive the boost converter to run the Nixies, and I didn't want to have more than two voltage levels in my circuit. A quick search on Mouser showed two things: one, I had no idea there were that many different types of AND gates, and two, that the vast majority of logic ICs that meet my voltage criterion are from some chip family whose part numbers are all CD4xxx. A little internet research led me to a page explaining how logic ICs work, and I learned that these chips are CMOS (Complementary Metal Oxide Silicon) chips rather than traditional TTL (Transitor-Transistor Logic) chips, meaning they use a different type of transistor (MOSFET rather than bipolar junction). Aside from being compatible with the supply voltage I wanted to use, CMOS chips are also much lower power consumption, which is nice for the battery backup. So CMOS chips it is!
Lastly, my clock needed a time base, some source of regular pulses that my logic circuit could count in order to keep time. There are many options for a source of pulses, some are good for keeping time for only short periods before they drift, and some can keep time for days, weeks, years, or even millennia. Cesium fountain clocks may be fantastically accurate, but I honestly don't have that kind of cash. Fortunately, there's something that's only one ten billionth as good for less than one ten billionth the price: quartz crystal oscillators.
Quartz crystal is piezoelectric, which means it changes shape when a voltage is applied across it, and applies a voltage when its shape is changed. What this means in practice is you can tune a quartz crystal (by changing its size) to vibrate at a very specific frequency, and the natural frequency of mechanical vibration of the crystal will force the electrical circuit it's placed in to oscillate at that frequency, assuming your circuit is tuned to oscillate at a frequency in the ballpark of the crystal's natural frequency. Generally, quartz crystals can be as accurate as 1 part per million, meaning a clock running on said crystal might gain or lose a second over the course of 11 days, which is definitely good enough for some random guy's hobbyist project.
With a power supply, a bunch of Nixie tubes, a logic chip family, and a (reasonably) accurate time base, it's time to build a clock! Tune in to Part 2 of this project, where we design a logic circuit to turn the oscillations of our quartz crystal into a nice, readable 12/24 hr time format.