| ~ OUTPUT|
This week I made two output devices: a spindle controller and a stepper driver.
Since my goal is to make a handheld-CNC for my final project, I thought I'd use this week to make one of the most critical components for the final system: the spindle.
Since the spindle only needs to spin in one direction I used a simple MOSFET based circuit to control the motor. The motor I'm using can draw quite a bit of current though (8A stall) so I needed to use the high-current (16A) MOSFET from the fab inventory.
My board is based on David Carr's speed-controlled spindle controller. I added a flyback diode to prevent the motor from sending voltage spikes back into the microcontroller. I spec'd the diode to be able to handle peak voltages and currents equivalent to those that I'm sending to the motor (24V 8A peak).
I used the hardware PWM to modulate the voltage going to the motor. I orginally used the fast-pwm mode (that David Carr uses) but found that it produced a loud PWM-whine and was far less torquey in the low-pwm range. I eventually settled on using a phase-correct with a clk/8 prescaler.
Once, the motor was working I made the spindle. I used Ilan Moyer's spindle design because it seemed like a robust, tried-and-true design. I machined a quick housing for it out of half-inch HDPE on the shopbot and used cable-ties to tension all of the elements in place.
I tested the spindle as a hand-held device on a block of wax. It performed pretty well but definitely made me aware of some difficulties I'll have to tackle in the process of making a nice, high-precision hand-held cnc-milling tool. For one, the endmill can have a tendency to "bite" and suddenly grip the material, causing it to vibrate and make a rough edge. I found both increasing and decreasing the voltage (and speed) of the motor helped in this regard; it made the tool more controllable. With this in mind, making a speed-controllable spindle a natural next-step (this was actually my original intention but ran out of time to develop and test the speed-sensing circuitry).
I also made a stepper driver this week. For my precision machine design class I'm making a fluid flow test setup to evaluate an intra-aortic balloon pump and I need to drive a pretty beefy stepper motor. So I built Ilan's high-current stepper driver.
I wrote an insanely simple test code in Arduino to verify that it works. And it does!