Friday, March 25, 2016

DIY CNC MIlling Machine (on a budget under $100) PT 1


For years as a hobbyist that buys all kinds of add-ons and accessories for "mu millions of Hobbies" according to my wife.  I have thought how amazing it would be to have my own CNC mill and lathe equipment to make a lot of these items myself. It would also be really nice to have the ability to personalize them with my own logo and name or whatever catches my fancy. So I went out and started pricing small milling machines and compact metal lathes, and even combo mills with a built in lathe. It was then that I realized if I dropped the kind of dough needed to purchase this equipment, that I wouldn't be able to afford my hobbies anymore. So I set out on a quest to build my own CNC mill.

Do you just jump into milling?
Now I have some experience in milling and machining. I worked in a factory in the maintenance department and we were able to use a lot of their tool makers shop to do repairs on machinery and create and repair tooling. So I got a really good taste of hand milling and turning everything from a 10" dodge bearing from scratch to trueing dinged ball screws, to facing 2 ton shaper heads.. All this on old manual knee mills and old Colchester lathes. At the same time I was on a team that converted old relay logic machinery to PLC controlled and CNC operated machinery. This really gets you involved in how the machines operate as well as how to visualize the build process.

Why Now?
Well, there are a couple of reasons. The first is the Chinese market influx of affordable CNC controllers and stepper motor drivers. There is also a larger availability of scroungable steppers motors and accessories from old copiers, printers and plotters that can be used to build your mill affordably. I guess it is also something you need to take your time on and all we seem to have as we get older is time right? Just Kidding.

Getting started.

The first thing to get me interested in this project was putting a motor drive board on top of an Arduino Uno. I was able to get servo motors, dc motors and eventually stepper motors working with simple little codes. It was fun to learn and a pretty cheap way to run a cheap CNC mill. It was then that I realized that I could use these in the same way I had numerous times on old machinery in the factory.

I soon found out that a couple of motors that I thought I could use to build my mill, were both too small and to weak to do the job.  So in my visits with a guy I know in the service industry, that was parting out and old Ricoh copier, he acquired me four NEMA 17 1.8deg 1.2A 6 wire stepper motors. To run these from the Arduino as I had hoped would require at least 2 motor shields, and even then they were not rated for continuous duty nor the current like I would need. They also run upwards of $30 each. So I started the process of looking for a cheaper and or better alternative. More on the controller I decided on later.

First step.
Old Gantry design
The first thing you need is a sturdy base that you can level and that is solid enough to do the work you need done. I happened to have a good supply of a used HDP (High Density Polyethylene) Sheets laying around that used to be in service as pallet separators. They were various sizes and laying in a pile collecting dust. I had used this stuff on various other projects and found it to be very drillable and millable.

So I set out to make a base from the HDP and some extruded scrap aluminum I had laying around. I don't have a lot of photos of this process, but will post what I have. I basically just wrapped the edged of the base sheet with the extruded aluminum on the long edges and then used two pieces of 3/4" angle Iron mounted across the end. I later  applied a 1/2" strip of the HDP across both ends and extended them out long enough to mount the gantry rails on. I should let you know that with the HDP, most of the assembly is done with sheet metal screws. I predrill all holes, otherwise the material distorts or cracks.

First design of gantry rollers
I had planned to used 4 ball bearings per side for the gantry, but found very quickly that the extrusions I had were not strong enough and introduced a lot of play before even building the gantry. So I scrapped this idea and started over. I had an old Calcomp plotter laying around that wasn't working any more, so I disassembled it and started working out a new gantry plan of action.

One thing you learn very fast, is even though you do your research
Adding Rails
not everything works for every thing you build. My table sat for 3-4 months while I figured out how to reconfigure it. Sometimes you have to walk away to make it the way you need it. In the mean time I had an operation, built a robot using an Arduino controller, and then started to fly RC airplanes and helicopters. When I came back, I hit it pretty hard and started to make it look more like a CNC mill table.

New rail design.
I first thought the HDP would make great bearing slide material like Teflon. This did not turn out to be the case. The HDP grabs pretty hard when sized right, and by the time you open it up enough to where it will slide freely you have a ton of play in the gantry.  I really wanted to use linear bearings here, but my budget just wouldn't allow for it. So I had to salvage some more parts from the plotter, namely the bushings that were on the slides I used. The problem was I had to gratly modify them for my use, ad they were part of a large carriage. Nothing a band saw couldn't take care of though. You will see photos of the bushings I installed in later sections, on a more finish gantry.

X-Axis lead screw.
Ball Lead screws

Most CNC mills have high precision ball screws that move the axis' back and forth. They have built in back lash nuts that reduce play to almost nothing. The problem with these are they are extremely expensive, and for my purposes not needed.... yet. With a little work you can get a home made lead screw to hold pretty tight tolerances. I created my own lead screws from 3/8 Ready Rod and 1/4" ready rod. Though I am planning on making them all 3/8 before I am done, as the 1/4" screw seems to work the motors harder. It is also much easier to synchronize screws that are all the same size. I have also heard that some software that will not do certain operations correctly if the X an Y axis do not have the same pitch. Mach3 has no trouble with this at all though.

Bearing supports
I made some homemade dodge bearings for each end of the screws by grinding down the
DIY Dodge Bearing
edges of 3/4" spade bit to the same size as the bearings I had. and recessing a pocket into one side of the brackets I had cut out. Then the bearings just snap into the pocket. I bolted these brackets to a piece of flat aluminum I had spanned across the bottom of the base on both ends. I cut the rod long enough to
Finished X Axis Screw
place double locking nuts on the outside of each bearing to  help eliminate backlash as much as possible. And left enough on the motor end to couple with the Motor Coupler I made. You don not necessarily have to use bearings, you could use a bushing. But bearings are relatively cheap and will decrease wear and resistance on the tremendously. So I opted to use the bearings.

Nut for screw drive
Axis Drive Nut
I made the nut to drive the axis out of a small piece of the HDP, by drilling and threading a hole for the threaded rod to screw through. One tip for this is that no matter what material you use for the screw nut, take a drill and clamp the end of your screw in the chuck and then power the screw back and forth in the nut a couple dozen times at high speed, over the entire length of the screw, to seat in both the nut and the screw to each other. This makes for much smoother operation and less drag against the motor right out of the box. When completed the X axis with the 3/8" ready rod had only .003" of backlash, that I easily took out in Mach3's backlash compensation. I will be building an anti-backlash compensator nut at some point, but I am pretty happy with what I achieved with this homemade screw.

DIY Coupler
Mounting the motors.
Normally you would use a dampening motor coupler in this situation, but finances dictated that I make something instead. I needed a way to get the motors connected up to the screw. Since I was going the direct drive route instead of belt or gear this is pretty straight forward. So I took a piece of scrap aluminum stock that I had cut off the end of the rails that had been installed, and drilled holes in the ends to match the 5mm motor shaft. I then ground the threads off the end of the screw and drilled the correct size hole to fit it in the coupler. I also drilled and tapped a 3/16" hole for a set screw in each end to lock the shafts into the coupler. I will be changing this later to a flexible couple, mainly to save on bearing wear and tear for the motor. It should also help on harmonics noise to some extent.

Motor Mount
X Axis Motor Mounted
Next I needed a bracket for the X axis motor. I found an old rack mount ear for a piece of music gear I had laying on the shelf. I drilled an Inch and an eight hole in the middle and 4 holes for the motor screws to mount through. I then lined it up under the base and through bolted it to the end of the table. This works out pretty good and the bracket is flexible enough to absorb some alignment issues until I install a real flexible coupler for it.

Gantry Assy.
Once I finished mounting the motors I started on the build of the gantry. I knew I wanted at least 3-4 inches of travel in my Z axis. I would like more but did not feel I would be able to control tolerances with a much taller gantry. I used a 3" strip of HDP up the sides and quickly realized that this stuff flexes a LOT in longer lengths. So I had to reinforce all of it by screwing aluminum flat plate to the edges. This helped to support it from side to side deflection that might occur. The horizontal piece wasn't as big of a concern, as it was going to get more support later.

What's Next?
So there you have the first part of my DIY CNC build. In part 2 I will go into the building of the Y and Z axis Carriages and the building of a controller that will work well and be expandable too. Here is a little sample of what's to come.
CNC Control
Z Axis Carriage

No comments: