Home CNC machine tools

I had a machine shop at home since 1982 or so, and had always wanted to move to CNC, but knew that writing my own CNC program would be WAY too hard. Through the net, I got in touch with a guy in California who had an Allen-Bradley 7320 CNC control but didn't know what to do with it. So, I bought it, he broke it down into 3 huge boxes and sent it to me. I finally managed to get it running. It was basically a 16-bit minicomputer with integrated CRT output and industrial interface racks. It had a bad power supply, but the guy sent me a spare. It had a bunch of bad Tantalum capacitors on the memory boards, but I got those fixed. Mostly, just run a lot of current through them and see which ones got hot. The guy assured me it had the servo amps in it and the CNC executive. Well, I had diagnostic tapes, but no executive, and some digital I/O boards but no servo amps. So, I found a guy on the net who serviced this model, and he punched executive tapes on a couple of the machines at his customer's site for me! I was able to load these tapes and make the control run. I attached encoders to it, and got the on-screen position display to update. Then, I had to come up with servo amps. First, I jury-rigged an old stereo I had built 20 years ago and took out the DC isolation, and that worked surprisingly well! Well, I had an ancient (1938) Bridgeport milling machine, totally manual of course. I had bought the axis hardware from an Excellon circuit board drill some years ago, and set out to adapt these parts to the Bridgeport. There was a lot of mechanical work to adapt that to the Bridgeport, mostly making two brackets to mount the motor and end bearing part of the drive to the where the original handles went, and replacing the yoke in the middle of the table with a bracket that holds the ballnuts. The original GE CNC control on the PC board drill used resolvers, I replaced these with small encoders I got surplus. This actually worked with the AB 7320 control, but position accuracy was real sloppy. A guy I met on the net suggested I needed real velocity servo amps, and sent me some docs of a representative older model from Servo Dynamics. I set about to build my own velocity servo amps. I had to add DC tachometers to the old GE axis drive units with miniature toothed belts. I started with the Harris HIP4080 chip that was originally designed for PWM audio amplifiers, these were advertised good to 80 Volts, but it turns out they were actually only good to about 60 V. I actually had the applications engineer say "Oh, you're really doing great at 69 V DC, none of our other customers ever got above 59 V!" Well, I eventually updated my amps to the IR 2113 FET driver, and had to invent the entire PWM modulator that was built into the HIP4080 myself with additional parts. But, it has worked reliably now for over 15 years! Then, I had to make some adaptations to the A-B 7320 executive. The main problem was my encoders were half the resolution of the original ones the executive was set up for. I set up a "BTR" (behind the reader) device so I could emulate the paper tapes with a laptop. Then, whenever the executive needed to be loaded, or a CNC program was to be run, it could be sent in from the laptop. So, I could read in the executive tape to the laptop and pick it apart. I wrote a disassembler in Pascal, and deciphered a few critical areas of the program such as where it read in the encoders. I hacked a couple locations there to double the encoder movement so the coordinates read from the encoder were correct. Then, I used this 2-axis CNC system to cut parts for the 3rd axis mod to drive the Bridgeport quill. Since I now had 2-axis CNC, I was able to put curves and angles into these parts. It was TOTALLY cool! I also used cutter offset compensation for roughing. First, I put a spring-loaded ballpoint pen in the spindle and ran a program to make sure the profile was correct. It drew the outline of the part on a piece of paper. Then I mounted the stock and set up a cutter radius in the tool table that was larger than the actual cutter. This would make a roughing pass around the rough-cut blank. I could then reduce the tool radius and it would make another cut a little closer. Finally, I'd put the actual tool radius in the tool table and it would cut the part to the final dimension. I ran this system for about 9 months, but was getting frustrated by the unreliability. I had 3 major breakdowns of the CNC control in that time, and it usually took me a day or so to debug it each time. Then, the guy who helped me with the servo amps told me he was using a program developed internally at NIST (National Institure of Standards and Technology) and it was available to the public. That was EMC, and it had recently been ported from Sun workstations to Linux. (They tried Windows with a real time extension, but the RT performance was no good.) The program had a number of rough edges, but showed a LOT of potential, so I tried to get on board.

By this time, I was moving away from the VAX (mostly, just too slow) in the late 1990's, but was no fan of Microsoft. Still, I was scared of learning a new OS, but the draw of a decent and fully understandable and configurable CNC control was powerful. I tried to build an RT kernel on an old PC from work, but ran into trouble, it turned out I had been using it for years with bad cache memory (under Windows). Another identical machine worked, but I then found out that this RT system would not run on a 486, due to the different page size. So, I had to gulp hard and buy a brand-new Pentium classic 100 MHz system. Then, the install disk from NIST booted up right away, and I was able to try out EMC. It looked good, and I quickly learned the most basic commands and functions, and got it on the home network. Then, NIST loaned me a Servo to Go card with the encoder and analog output interface, and I made up connectors so I could swap between the A-B 7320 and the PC as my CNC control. I reported a few things to NIST about problems I ran into while using it, and they fixed them and sent me an update. There was one remaining bug, the RT system didn't save the floating point state, but used the FP system in the motion modules, and this occasionally crashed Linux, but the CNC program would finish correctly, then you had to reboot. They fixed this in early 1999. I bought my own Servo to Go card and returned the loaner to NIST. I happily ran this system from 1999 until at least 2005, before the advances in EMC, and then EMC2 became so great that I had to update.

Well, after discovering Linux, and learning my way around there, I moved my desktop to Linux as well. I had several Windows-only programs that I used a lot (mostly CAD applications) and so I got VMware so I could have both Windows and Linux available at the same time on the same system. Xilinx is now well-supported on Linux, but I still use Protel99 for electronic CAD, and occasionally use Bobcad/CAM for mechanical. I have a laser photoplotter I built that generates PCB artwork at 1000 x 1000 DPI, and that software was written in Turbo Pascal and will be a bit difficult to move to Linux. Those are about the only apps that I need Windows for.

With the foray into CNC, I found there was a niche for lower-cost interfacing for CNC controls using EMC. I first made an industrial-level interface for analog velocity servo amps, with boards that plug into a motherboard, so you can add individual functions as needed. There was an encoder counter, Digital to Analog converter and digital I/O board. This all interfaced to the PC via a parallel port, which was used (by EPP mode) as a byte-wide communications channel, with a bank of registers accessible on each board. I called this the PPMC (Parallel Port Motion Control).

I then made an external step generator that was fairly similar in concept, but all on one board. Then, I made a version that outputs PWM instead of varying pulse frequency. I hacked up one of my servo amps to be driven directly by PWM instead of needing analog input, and it worked quite well. I was still using the Servo to Go board, and eventually decided I had to move to my own hardware, so I could say "I use the PPMC on my own milling machine."