Nixie Spedometer and Mechanical Iris Without GPS

Introduction: Nixie Spedometer and Mechanical Iris Without GPS

About: Engineer by day. By night... I sleep, mostly. Unless it's a night shift.

So, this is the car. I've been building this for about seven years now. This Instructable focuses on one part of it, the speedometer.

A brief background - the car is something I have had in my head for many years now, since I was a kid really. I'm an impulsive guy, and one hazy afternoon sat in a field in Chimay (Belgium) at a show called "European Bug In", after a hearty brunch of off-steak, undercooked eggs and several cans of fermented wheat juice, I said to my close friend in a slightly slurred voice:

"Y'know what, amma gonna build a thing. Wossit. Volksrod. Wivva keg forra fuel tank, and a turbo, and lots o craziness..."

My friend didn't really believe me. He nodded along passively, said something like:

"Yeah, sure, uh-huh..." in a disinterested sort of way.

"Really, though, you won't. You never get around to your projects..." he said.

Au contraire Monsieur!

Fast forward a few years, and I had started to make good on my inebriated pipe dream. The rules for the project:

  1. No technology that was not readily available when the car was manufactured, with the exceptions of safety grounds, or where cost is prohibitive to be done with 60's technology today, but it MUST be possible and I MUST prove so.
  2. No part of the car can be untouched. If a faithful restoration is "As it left the factory" then it must follow that this car has to be the inverse of that. "Nothing is left as it left the factory"
  3. This project is for me - it is to be the embodiment of the car that I have had in my imagination since I was a child, faithfully reproduced with as much flare as I can physically shoehorn into it.

The car has had a crazy amount of work done so far. A 9" roof chop, a 12" chassis extension and suicide front end, a turbocharged engine, a leather bench seat, the list goes on and on from the major "WOW" factors to the tiny subtle trick bits.

This Instructable focuses on one small, but key, part of the vehicle. The speedometer! Arguably the centrepiece for the driver. With that in mind, it just had to be special... Really, really special...

Supplies

Stuff. Lots of stuff...

An Arduino of your choice (I developed this with my Arduino Mega, but have two Arduino Beetles to actually run this when I install it)

A hall effect sensor of your choice, there are lots available with nice boards that are plug & play for Arduino

An original VW Beetle speedometer to donate parts (you need the housing with the little spinning magnet, and the speedo cable)

A 3D printer

Some 0.2mm copper or brass sheet

Some brass round bar (I think I used 2.5mm, but the diameter just needs to match the holes and slots in the iris)

Two IN-12 Nixie Tubes

Two NixieTester driver boards

A suitable Nixie tube power supply (Old proverb say: "Buy cheap, buy twice!" - so buy the best you can afford!)

Solder and flux

A gas soldering iron or tiny blowtorch

Coffee. LOTS of coffee.

Step 1: Nixie Is the Way!

After thinking about unusual ways of displaying speed, I actually opted for something simple. A decimal display. For me, there really was only one contender for this - the nixie tube. Looking around, there are a few Nixie speedometers out there already, but every single one I found ran with a GPS. However, rule #1 means that I can't use a GPS. Besides, for me, that's a copout. Why not use the equipment that was already in the car? A Beetle (because that what the car was, once...) has a little magnet in the speedo that spins with the speedo cable driven by the front wheel. This in turns creates an eddy current, which would pull on the needle in the speedo and give a readout of speed. It wasn't especially accurate (that's why I was going a little fast, Officer!), but it worked well enough.

The beauty of this is that the little magnet, as it spins, makes it's magnetic field spin with it. If you mount something, say a hall sensor, next to the magnet, it will pick up the field as it spins. The hall sensor will see the polarity of this field change and so will output a pulse with it.

I must confess the hall sensor I used was just a random one I had kicking around, but it was on a board a little like this one:

https://www.ebay.co.uk/p/14018166934?iid=372284183...

Nice and easy, hook it up to an arduino - I'm using an Arduino Mega because that is what I had laid around the place. Yes, yes, this contravenes Rule #1. However, while I could use BCD decoders, a counter chip and various bits n pieces, this would not be cost effective. I designed an Arduino-free version using traditional components in some clever simulator software and it worked well enough, which proved that it could be done. Besides, it's my party and if I want to bend the rules a bit, then I will! Anyway...

The "DO" pin needs to go to whichever interrupt pint you assigning in your code (in my example for Arduino Mega it is interrupt pin 0).

VIn needs to go to the 5V output from your arduino.

You can probably guess that GND needs to go to GND on the Arduino.

Write yourself a little code to count the pulses... Or, if you're lazy, you can steal mine... I say "mine", but this was actually someone else's that I shamelessly pilfered from the internet and altered...

So, running this bit of attached code, opening the serial monitor, and spinning the magnet gives us a nice readout of pulses, and the time between rising edges of your pulses in microseconds. A little maths, convert the duration to seconds and divide 1 by that number and you have yourself frequency! Try running the code I posted here, open the serial monitor and see if it works. If it does, see if you can figure out how to convert revDuration to RPM. Or, you can cheat and look at my code later on ;-)

Step 2: It Has to Look Beautiful!

So. Before we delve deeper into the code and hardware, and because I have the attention span of a small child in a toy shop, lets think about making this thing look special. Properly, awesomely special.

A Nixie speedometer is just not enough, boys and girls. Oh, no no no. It needs to have some style, a bit of panache, a little something about it.

I've always been fascinated by mechanical irises. So. why not use one?

I broke out the Sketchup, fired up my 3D printer, and I checked out this guys Instructable:

https://www.instructables.com/id/How-to-make-a-12-...

This is what I came up with. I won't repeat the steps "kommodore" already put in his Instructable, the credit for this part is almost entirely his.

After some careful measurements and a little tinkering, I was ready to print it out...

I would upload my sketchup files, but where would the fun in that be? Besides, my dimensions are very specific to my car, and hinge on the space available in the dashboard etc etc. You're better off drawing up your own!

Oh, OK then, since you asked so nicely you can have my SketchUp file too...

Step 3: A Mechanical Iris

So, this is how it looks after some careful assembly, sanding and minor tweaks.

The leaves are 0.2mm brass, rather than copper. The pegs are just brass pins cut down and soldered to the leaves.

I don't have a photograph, but I hand made a stainless steel former, cut the brass sheet int strips, clamped the former onto it, and used a flapwheel in an angle grinder to make my leaves.

I drilled holes in the former and through the leaves to locate the pins and soldered them into place with a small gas soldering iron, flux and regular electrical solder.

I wish I had more photographs of this stage, but really it's not an exact science. There's plenty of ways to catch a monkey, you will find yours if you attempt this. Scissors would work well enough if you take the burs off it leaves behind.

The plan is to attach the mechanism to an actuator or something so that when you turn the car on, the iris opens to reveal the nixie tubes. Pretty neat, huh?

Step 4: More Electronics. and Coding.

So back to the coding and electronics.

I really hit several walls at this stage. I'm a coding novice, and for me getting from measuring RPM to outputting speed to nixie tubes was a leap.

Nixie tubes with the numbers 0-9 have eleven pins, one for the high voltage supply input, and then when one of the other ten pins are grounded, it lights up a number corresponding to that pin.

There are chips out there for driving nixie tubes using Binary Coded Decimal (BCD). To give an example of what BCD is, the number "12" in decimal is, well, 12. In binary, it is "1100" - both of these are easy to output from an Arduino. But, 12 in BCD is "0001 0010". This is slightly more complicated to output. It would also mean a frightening number of connections to the Arduino!

There would then have to be some transistors to drive the Nixie tubes, and lots of other pokery jiggery that I could really have done without having to design. Outputting the data to a shift register would have made less connections to the arduino, but would have made for a no-less complicated circuit. I'm all for simplification where possible.

The answer I found quite by accident. This beautiful product:

https://nixietester.com/project/nixie-tube-driver/

I was searching for something quite unrelated, but when I stumbled on these, along with the library for using them with Arduino, I immediately bought several. I won't go into depth about the wiring right here, but it is extremely simple and explained in full on the website. You can daisy chain these together with just three connections to the Arduino (clock, EN and Data In). for all the boards you use, the clock and EN pins are common, and data out from the first board goes to data in of the second, and so on. Add the VIn (5v) and ground, and the HV from a suitable nixie supply like this one:

https://www.tindie.com/products/tonyp7/170v-high-v...

As if by magic, it all fell into place here. Almost... A few false starts, and I had code that sort of worked, but it was buggy as hell, kept freezing, and did not behave quite as I wanted.

However, I'll spare you the pain, and we can just skip straight to the good bit in the next step! But for those interested, the issues I had were ironed out in this forum discussion:

https://forum.arduino.cc/index.php?topic=672499.0

Step 5: The "finished" Product

This is the finished speedo, attached to a drill, and doing what it should do.

It pains me to release something to the public at large that I worked so hard on and spent hours trying to get right, but it is only right I give back to a community that has helped me so much!

The wiring will depend entirely on which pins you assign in the code, and which Arduino you choose to use.

So, here is my code. Actually my code this time. Not pilfered and stolen. What you need to really note is firstly the pin definitions, they will change depending on what Arduino you have. Secondly, the calculation for MPH, that is based on my wheel circumference. My wheel is, give or take, 22" or so in diameter. So the line in the code that reads:
"SpeedMPH = 500000 * 4 / revDuration;" will need to change depending on your wheel size, and the method by which you are measuring pulses. yes, I could have simplified it further, but to be honest I was so happy I got hte code working properly, I didn't want to poke the bear any more.

The way I calculated my speed:

Frequency = 1/revDuration

However, there are two edges per magnet rotation, so:

Frequency actually = 0.5/revDuration

Wheel circumference = 0.001112257 miles (this was calculated from the diameter of the wheel in mm multiplied by Pi, divided by the number of mm in a mile which is 1609344mm)

SpeedMPH = MagnetPulseFrequency * 60 * 60 (to give pulses per hour) * Wheel circumference

So MPH = 4 * Frequency

Happily, this makes a very convenient bit of maths to play with.

I hope the code makes sense, I haven't annotated it as much as I maybe should have...

Step 6: Sadly, Not "totally" Finished... But a Glimpse of What Is to Come!

Because of the craziness of Covid-19, I am unable to get to my workshop where my foundry and casting equipment is.

The next step is to cast the front face in aluminium or brass, and mount it in the car. Unfortunately I can do neither :-(

What's more, I got sent away short notice with work, and I am typing this from my hotel room. So I can't even assemble the actuator. However, left to do:

I'm going to use an Arduino Beetle in the finished product.

The dashboard will also feature a Nixie rev counter, and IN-9 indicators for oil temp, boost pressure etc.

As I said, I will cast the front face in a nice metal to really finish it off.

I've popped some pictures up of the dashboard, it's a solid mahogany board cut to shape and fixed in place with turned brass fixings. The plan is to bore a hole to fit the speedometer once I have cast the front in a nice metal. I've also included a picture of the layout for where the IN-9 tubes will go in the 3D printed housings I made. These will read out:
Fuel level

Fuel pressure

Boost pressure

Lambda

Oil temperature

Oil pressure

Cylinder head temperatures

Battery level

I've also given a little sneak peek of the nixieclock that will also be fitted in the dash.

I am developing a nixie rev counter too to really finish it off. The whole dash will have laser cut brass cover plates with etched annotations for everything.

I hope you have enjoyed my almost-finished Instructable, and will forgive me for not having a totally finished polished product to show you.

3D Printed Contest

Participated in the
3D Printed Contest

Be the First to Share

    Recommendations

    • First Time Author Contest

      First Time Author Contest
    • Fruit and Veggies Speed Challenge

      Fruit and Veggies Speed Challenge
    • Make it Fly Challenge

      Make it Fly Challenge

    11 Comments

    0
    GFunkBus76
    GFunkBus76

    11 months ago

    Super cool! Been trying to make a digital speedometer for my 1976 VW Bus... Going to be using some of your hard work here on my project!

    I'm not using nixie tubes myself... but thought about it at one stage! Super cool. Saw some guy on youtube / arduino forums with one years ago and no updates... super excited to find this indestructible out now!

    Will let you know how my project goes... You got me to register here just comment! Thanks!!

    0
    GFunkBus76
    GFunkBus76

    Reply 11 months ago

    Sorry Dave, tried piecing together the math you used - but couldn't quite get there. What is this 500000 number exactly?

    My wheel circumference is slightly larger than yours, 24" or 0.001189996843 miles - so I used that information....
    0.001189996843 * 60(seconds) * 60(minutes) = 4.2839886348

    So would my SpeedMPH look like: SpeedMPH = 500000 * 4.284 / revDuration;

    Or do I need to figure out a different 500000 number?

    Thanks so much! (cross posted on the arduino forum also ;))

    0
    Fall-Apart-Dave
    Fall-Apart-Dave

    Reply 11 months ago

    Hello.

    I would have to check through my notes, but I believe the 500000 is to convert the two pulses per revolution of the magnet to frequency in seconds. But I'd have to check! I remember it was a fixed variable.
    You can assign a potentiometer to an analogue input, and used the voltage to give your 4.284 number an adjustment. That's what I've done to mine in the end so I can tweak Vs a satnav.

    0
    GFunkBus76
    GFunkBus76

    Reply 11 months ago

    Thanks very much! I am using the same speedo (altered a vw bug speedo).... So its got the 2 pulses per rotation etc. So I suppose it will be alright! Looks about accurate to my minor testing lol. Vehicle is not on the road currently, so I'll have to wait it out for serious testing :)

    Thanks again for sharing! I think we both originally found that one guy on the arduino forums/youtube who went AWOL lol... Appreciate you flushing out the project more!

    0
    Fall-Apart-Dave
    Fall-Apart-Dave

    Reply 11 months ago

    You're most welcome dude. Stay in touch!!! What are your plans if not nixie tubes? Where are you in the world?

    0
    GFunkBus76
    GFunkBus76

    Reply 11 months ago

    Working on a digital dash setup for my Bus... So definitely not the 'era-appropriate' mod you have done lol... My bus is quite custom - so this is just another rabbit hole I've fallen into. 12.3" lcd for dash, 7" touchscreen run off a raspberry pi... Arduino in the front and rear (maybe more ... lol). Its definitely snow-balled. Will keep in touch! ... I'm from the Vancouver area in Canada :)

    0
    Fall-Apart-Dave
    Fall-Apart-Dave

    Reply 11 months ago

    Cool! Well drop me a personal message if you ever need help or advice. My hotrod is somewhat custom too!

    0
    Makerneer
    Makerneer

    1 year ago

    Wow. Very cool!

    0
    HappyLes
    HappyLes

    1 year ago

    The intricate and ridiculous product of a genius mind... Nice work!

    0
    jessyratfink
    jessyratfink

    1 year ago

    What an interesting speedometer :)

    0
    Fall-Apart-Dave
    Fall-Apart-Dave

    Reply 1 year ago

    Thanks! I know Nixies are getting a little "old hat" these days, but I wanted to make something that really fitted with the feel of the rest of the project.
    I'm also developing a rev counter and some other nice little bits to go with it. In time I'll upload instructables for the whole project.