Top level menus: Home Page | Weather | Downloads | Links | Future


The spindle speed on my Sieg X2 mill is controlled by an uncalibrated rotary "volume control". This revCounter uses a PIC to detect pulses from an optical sensor and calculate the spindle speed.

The original idea was from the Revmaster design in Model Engineers Workshop magazine. I have rewritten the firmware to include extra features.

Tachometer for an Engineering Mill

October, 2008 | By: John

This design originally appeared in issues 115 and 116 of Model Engineers Workshop. Full text of article by Tony Jeffree is here

The first modification was the replacement of the aged 16F84 PIC with a more modern 16F628, cheaper and greater functionality. This reduces the component count, because it dispenses with the need for a timing crystal or resonator. I considered that the accuracy of the device was sufficient for the purpose, see the note on read averaging below. Below is a summary of the changes that I made. to the code and some notes:

The code was written using the free Boost C compiler for PICs and debugged using the SourceBoost IDE Plugins. These latter items are very useful and dramatically cut the development time. A license is required, but the cost is well worth the time saved. I have included quite a lot of notes within the code. I found a USB powered programmer on eBay, from somewhere in China that works very well. I had in the past built my own, but they were powered from the serial port, which are fast disappearing, especially on laptops.

Bolt on or re-engineer

Not content with adding a tachometer display to the existing mill, I decided, for neatness, to replace the control box on the side of the mill head with something that housed both the display and the rest of the wiring.

I have put the code in the downloads page, see top level menu at top of the page.