CNC Lessons Learned
Building my own CNC machine has been quite an educational experience. I've got a better idea of what I'm up against now, and have plans for moving forward.
Lessons Learned so Far
First. Hardware is hard. Much harder than software. I expected programming or wiring the electronics to be the difficult part, but thanks to good docs and helpful Arduino libraries I was able to get basic movement going pretty quick. The biggest challenge has been the mechanical construction of machine. I've gone through several iterations of the pen mount, sliders, and lead screw attachments but there is still much more to do. Software is so much easier to modify and test out new ideas. Creating a new slider took several hours to design, build, and test.
I have also learned how much of hardware success is based on component sourcing. Throughout this project I have added to a growing list of good online shops to getting interesting pieces; and how to repurpose unexpected materials like plumbers tape. I also learned that Amazon Prime is your friend. I honestly don't know how Fedex can make any money off of them.
So far I'm happy with the progress I've made on my CNC machine. I can now make a pen move in the X and Y directions with a fair amount of repeatability. The machine is a good test of ideas but not reliable enough to actually use yet. The biggest issue is tightness. Everything in the CNC machine has some slack in it. Each component of slack multiplies to make the pen slide all over the place; and a sliding pen means bad drawings. So that will be the main driver of the next version: making it super tight.
The other night I designed a new slider. It still uses roller skate bearings but applies them to the support beam from three sides instead of two. It also uses more rollers spaced further apart. The new sliders greatly improve stiffness without adding too much friction.
To remove the stickiness of then pen I realized I need a way to press the pen into the paper but still have some slack. This calls for a spring. After reading work that others have done I devised a new holder using two ballpoint pens. They are, interestingly enough, identical pens but with different brands on the side. Most likely from the same swag manufacturer. If you attend conferences you likely have tons of these guys lying around.
By combining two pen barrels and putting a spring at the top I can get the pen to sort of float in the middle but pressed against the bottom end. The spring pushes it against the paper but lets it slide up when needed. It acts sort of like a tiny shock absorber. Good enough for this version.
On the electronics side I finally mounted the various boards on a sheet of plastic. Using my Dremel drill press I set them up on inexpensive spacers from the Robot Shop. I also gave the steppers proper four pin connectors from Adafruit since I'm always plugging and unplugging them. The drivers still have some breadboarding to get rid of, but things are improving. I also added a real power switch for the motor current instead of having to constantly unplug the wall wart.
On the software side I wrote some new Arduino sketches using the excellent open source library AccelStepper. It handles acceleration and multiple steppers with ease. Now the motors sound like engines powering up.
Oh yeah; my teaser from before. The NES Controller.
I found two original NES controllers at our local electronics recycling shop for five bucks each. I love these things. These two are probably over 20 years old and they still work perfectly. Nintendo designed them to be bullet proof. (Sadly their design of the cartridge connector was not so well thought out).
The controllers use a simple serial protocol over their five pins. You can hook them up directly to an Arduino using jumper wires but I found an NES breakout board (Robot Shop) to give it that nice finished look. The software side is easy using the NESpad library. Note that this code is a few years old and won't compile out of the box. I suggest using my fork of the lib which is patched to compile with Arduino 1.0 and higher.
Every good project needs a name. I'm tired of saying "my CNC drawing machine thingy" over and over. Thus I dub thee "Clyde" after the orange ghost of Pacman fame. Apparently his other names are (translated from Japanese) are "stupid", "slow guy", and "pokey". Fortunately Clyde is easier to pronounce than Guzuta and Otoboke. He may be slow but he tries really hard and gets the job done.
I'm going to take a week off from Clyde during my parents' visit. Instead we will play with Jesse and finish up some house projects. When I return I will build a new machine over twice the size of the current one: 40cm x 60cm x 10cm. This is big enough to do some real work while still able to fit on my desktop. My latest extrusion order from OpenBeam is enough to build the new machine with plenty left over for reinforcement and experimentation. Have a good weekend!