I decided to make a 3D printer. 3D printing seems to be the wave of the future for producing many parts. There are a few different types of 3D printers, one of which, the extrusion type, seems to be the most popular on the market. This kind of 3D printer takes in filament, which is essentially plastic wire, and extrudes it into a small bead of plastic. The printer moves the extrusion nozzle on a table to draw a part. This printer is basically a fancy hot-glue gun that makes 3D shapes.
The consumer grade 3D printers on the market are pretty slow and they don't produce the best quality parts. In addition, most of them don't use support material. Support material is a second material used by the 3D printer with the standard plastic. The support material can be dissolved so you can make parts with overhangs or other features that require additional support.
The concept for this 3D printer is to use high power hobby brushless motors, similar in size and power to those used in the heavy weight combat robot I built last semester. These motors aren't meant to be used as servos, so the printer needs custom motor controllers as well as additional hardware to properly drive the motors.
The brushless motors have 3 wires: phases A, B, and C. Brushless motors have magnetic coils in multiples of 3, one set for each of the 3 phases. These coils are connected together in a few different configurations, such as wye or delta, which provide different characteristics to the motor. Driving the motor is the same regardless of the coil configuration. Phases A, B, and C must be pulled to supply voltage, ground, or floated to make the motor rotate. A nice resource for this would be AN857 from Microchip. Microchip makes microprocessors, transistors, and other components used in motor controllers. AN857 is one of their application notes on brushless motor control.
Most hobby brushless motors are sensorless, so there is nothing added to the motor to help a controller determine when to switch which phases are being powered. Since a servo needs an encoder, I decided to use this to perform the commutation, or timing for when the motor controller switches which coils are powered.
Here's a picture of the custom motor controller. This board uses power MOSFETs. MOSFETs are a type of transistor that is great for high frequency switching applications. There are 3 pairs of power MOSFETs; each pair corresponds to one of the motor's phases. One MOSFET in each pair is connected to the power line, and the other in each pair is connected to the ground line. If a high-side MOSFET is on, that phase will be connected to the power line. If a low-side MOSFET is on, that phase will be connected to ground. If neither is on, the phase will be disconnected from power and ground. If bot MOSFETs are on, power fill flow from the power line to ground. In this case the MOSFETs will form a short circuit. With a large power source, batteries or computer power supply, the MOSFETs will fry from too much current.
Portions of this project became a group effort for final projects in two of my electronics classes. The motor controller and its design are part of an advanced electronics course. The logic portion of the control, which is built on an FPGA and microprocessor board is part of a digital electronics and embedded systems course.
The logic portion of the motor controller is implemented on an FPGA. This includes PID control, which is being temporarily used until the mechanical portion is built; motor commutation; and coordinate input. An FPGA is a chip that has programmable logic gates. An FPGA allows the user to implement hardware design on the chip. Certain features like encoder counting, and motor commutation are very convenient to implement on an FPGA. Since these features are in hardware, certain situations can be made impossible. One example of this would be short circuiting two of the MOSFETs together.
Here is a quick video of the motor. The motor controller is connected to a variable voltage supply. The motor controller is just switching which phases are powered depending on where the motor is positioned. The voltage determines the peak speed of the motor. I can't remember if this test went up to 12,000 rpm, but the motor and encoder functioned up to this rpm.
This shows the output of the encoder at 12,000 RPM. The signal is very clean. There are two square waves because this encoder is a quadrature encoder. There are two sensors, 90 degrees out of phase from each other, which read lines on the encoder. This lets the controller decode a resolution four times higher than the line count on the encoder. This encoder can be read at up to 8192 counts per rotation.
The mechanics for this project are meant to be relatively cheap to make. Linear slides in the gantry are built using hardened round rails and ball bearing bushings. These components are commonly used in other 3D printers and can be found very cheaply on sites like Ebay. The design for the printer isn't completely finished. There table motion system and mount, material mount, extruder, and heater block have yet to be designed. Thankfully the project proposed for class only required the motor controller, not the full 3D printer. I will likely finish these parts over the winter break when I have more free time.
Here's a screen shot of the CAD in the 3D printer's current state. The gantry design is done and looks pretty sweet. The table still needs some work, and the extruder doesn't exist.
These are the bearing blocks used in the gantry. Each one holds a round rod ball bearing bushing. The bushings are tight slip fits, so you can put them in by hand, but it does require some force to push though. Each of the bushings are held in with snap rings. Most of the dimensions on this printer are a mix of english and metric units. Linear slides are all metric, but screws and part dimensions are english. I wanted to use existing stock and screws for most of this project to keep my costs lower, otherwise I would have made every dimension metric.
Here are most of the components in the gantry. Locating dowel pins are not pressed into the bearing blocks or the blocks that hold the X axis rails.
The frame is made from MDF. MDF was chosen because it is pretty cheap, it cuts nicely on a CNC router, it is relatively dense, and it doesn't produce splinters like other woods. If I get around to paining the frame it will look even cleaner than it does now.
Eventually I will glue the frame together, but for now it's going to be held together with clamps. There are still a few features that need to be cut into the frame, so I want to be able to replace or modify the 6 panels.
Here is the servo mount. The motor is a 350KV outrunner motor that should be able to output 1200 watts. This is total overkill for the printer. This size motor is used because of the low KV which makes it easier to control at a particular voltage. It also eliminates the need for a gear box, which can introduce backlash to a system. The encoder is mounted on top. The gantry uses an H-Bot design. This design uses one loop of belt within the gantry. The servos can be stationary and mounted to the frame with this design. This makes the gantry much lighter than a traditional gantry design where each motor separately controls each axis. In the H-Bot design the position of the gantry is a linear combination of the two motor positions. The gantry moves in the X axis when both motors spin the same direction. The gantry moves in the Y axis when both motors spin in opposite directions. If only one motor is spun, the gantry moves equally in both the X and Y directions.
Here is the FPGA board and motor control board wired up to the system for testing. The final system will be wired in a much cleaner way...
I'll try to keep up to date on the progress over break. I have this and a number of other projects to start and complete, so I should post more often than during this semester.