Submission Format for IMS2004 (Title in 18-point Times font)



Pegasus Producer 3D- Affordable 3D printer for UCF students

Hector Arenas, Roberto Tang, and Giovanny Vazquez

University of Central Florida School of Electrical Engineering and Computer Science, Orlando, FL 32816-2450

Abstract — Engineers strive to create tools and solutions that innovate, aid and better the world. In the past 5 years 3D printing has exploded due to its unique ability to create a three dimensional idea into a physical manifestation. Currently 3D printers are being used to print houses, limbs, organs, food, rocket parts, and basic household items. The material used in 3D printing can be molded to create just about anything. The Pegasus Producer will aim to take part in this revolutionary technology.

Index — Engineers

I. Introduction

The idea to build a 3D printer as a senior design project was commissioned to expand on the ever-growing technology and demonstrate the potential for creation and problem solving that a low cost 3D Printer can have. These machines have many exciting applications, it is currently used in industry for product development, data visualization, and rapid prototyping. Most of the potential behind 3D printing lies behind the expansion of its technology utilizing more versatile extruders which is the mechanical part that extrudes the material. The 3D printing movement hopes to bring down the cost of metal printing, continue research on organic and food printing, and is even in the process of testing out 3D printed circuits. Big players such as NASA have recognized the versatility for creation that 3D printing brings and has invested millions of dollars to send a 3D printer capable of working in space to the International Space Station. Although the Pegasus Producer 3D will only print in plastic, it is a matter of introducing the idea of a home built 3D printer capable of creation and innovation. This gives regular individuals the possibility to imagine different inventions and providing them the opportunity to prototype them and see them come to life.

The main goal is to deliver a fully functional printer that a UCF student would be able to build using the different resources available at the school for a cost close to $250.

II. Specifications

To be able to measure up to the various 3D printers within the market we had to match or exceed some of the specifications that more expensive 3D printers currently have. We wanted to create a desktop sized 3D printer, something an individual would want to keep in an office or work space, and it also has to be able to print standard ABS or PLA plastic, the standard for plastic 3D printing. On the hardware side we had to make sure that we can process G-code as fast as the competition while utilizing a cost effective microcontroller and control board. The power supply will use your standard U.S wall outlet and provide clean power to the motors, heating elements, and microprocessor. Lastly, the software will be built for speed and efficiency while remaining small enough to not require extensive use of flash memory.

The specifications for the Pegasus Produces 3D are listed in Table 1.

|Area |Value |

|Printing area |215x215 (mm) |

|Weight |20 (lbs) |

|Overall size |600x560x410 (mm) |

|Printing materials |ABS, PLA |

|Build surface |PCB-heated bed |

|Computer interface |USB and SPI |

|Nozzle size |0.4 (mm) |

|Accuracy |0.1 (mm) |

|Resolution |0.02 (mm) |

|Motors |NEMA 17 Stepper Motors |

|Microcontroller |ATmega 644p |

|Power Supply |275 W |

Table 1: Specifications for Pegasus Producer

III. Microcontroller

The choice of microcontroller has been the ATmega644p for its price, speed, digital and analog output, and documentation available. The ATmega644p features an advanced 8-bit RISC architecture, 8 KB of FLASH memory, standard debug protocols such as I2C, 86 programmable I/O lines, and low power consumption. Achieving a throughput of 1MIPS per MHz it is very easy to optimize power consumption versus processing speed. 256K bytes of In-System programmable flash with read write capabilities can accommodate all the hardware needed to process g-code. For the Pegasus Producer 3D, a single ATmega644p is used which will control the motors and process all the g code data. The ATmega644p will not be producing any of the PWM signals for the micro-stepping, it will simply send the digital signals to the control boards which will allocate movement accordingly. A custom PCB has been designed to host the ATmega644p chip, it features a removable dip package that allows for replacement of the chip. The custom microcontroller has to have the ability to be preprogrammed with firmware utilizing any standard IDE package although a bootloader had to be burned within the chip to allow this. A major advantage in utilizing at Atmega644p is that it and can be tested with existing firmware that is currently in use with other 3D printers, allowing for us to meet our specifications by comparing our software to existing software during testing. The custom PCB has been designed using eagle and manufactured by a third party, soldering of components has be done by the group. Programming for the ATmega644p is done through its in-system programmable flash using one of the available debug protocols and the a standard USB interface. The in system programmer uses serial peripheral interface (SPI) to upload code onto the microcontroller. Most of the communication from the microcontroller to the motor control board happens through SPI, on the PCB all the outputs have to be traced and placed appropriately for the motor control shield to work appropriately. The custom PCB has pin outs for all the inputs detailed on figure 1, as one can see almost of the ATmega644p outputs will be used for the purpose of 3D printing.

[pic]

Figure 1: Atmega2560 Pin Layout

IV. Control Board

It is well known that an integrated circuit such as at ATmega644p cannot run motors by itself, it simply cannot provide enough power and it will need extra hardware components to be able to properly control the movement of a motor. The control board is what links the power provided from the power supply and the software within the microcontroller to produce a print. Basic functions of our control board include power regulation from incoming power which is split between 12V and 5 V, analog temperature sensors, mechanical end stops, wiring and insulation for heating elements, USB and SPI interface, and expandable pins for needed peripheral hardware such as cooling fans. The entire control board’s PCB has been manufactured by OSH Park, a third party PCB maker. All electronics have been hand soldered. As mentioned in the introduction, one of the goals for the Pegasus Producer is to create a low cost 3D printer. This has been effectively done by making sure all the electronics and microprocessor are easily attainable at a low cost and utilizing thru-hole components for easy construction of the control board. Eighty percent of the Pegasus Producer 3D control board can be constructed using the free electronic components provided by UCF.

A. Motor Drivers

Moving on, a major hurdle for constructing a 3D printer is overcoming the precision required to attain an accurate print. This is achieved by the use of motor drivers which will be mounted on directly on the control board itself using female headers. The idea is for the control board to be the interface between the microcontroller and the stepper motors, the control board is supposed to translate the signals from the microcontroller and convert them into direction, speed, and distance that a motor driver can translate into movement of the actual stepper motor. The Pegasus Producer will be able to support five stepper motors, one motor for the X and Y axis, two motors for the Z axis and single motor for the extruder. The two Z axis extruders move in conjunction so only a single output is required. The motor driver schematic is depicted in figure 2.

[pic]

Figure 2: Z axis motor driver circuit

The A4988 driver is the actual stepper driver which is not soldered onto the control board. The idea is for the stepper motor drivers to be connected to the control board via a series of driver sockets which will be input pins above all the components so that the small A4988 boards can hover over the control board allowing for easy wiring to the stepper motors and provide adequate passive cooling to the stepper drivers which are prone to overheating. The schematic is not very complicated to understand, power is delivered from the power section of the control board onto the stepper motor drivers. Each stepper motor driver received three commands from the microcontroller, for example for the X axis, the X-EN pin enables the motor, the Z-Step pin manages the amount of step the motor should do, and the X-DIR pin simply states the direction of the motor. Only two pull down resistor are required per stepper motor driver. One of the major advantages of using an A4988 stepper motor driver has the ability to adjust the step resolution of each motor. For precision, a 3D printer requires 3200 steps per revolution but the steps can be brought down to 200 steps per revolution for more robust prints, this can be configured through jumpers that have been included on the control board.

Figure 3 shows the pin out of the A4989 that will be placed on a pre-bought PCB, the PCB includes the necessary inputs and outputs to interface the control board with the stepper motor. Not using this chip would require extensive design to create a micro-stepping translator which would be out of the scope of the Pegasus Producer 3D in terms of engineering and cost.

B. Power Input

Power for the control board will be supplied from an internal power supply delivering 12 volts and 17 amps to run the motors, heat bed and other heated components. The ATmega644p is unable to power the control board or vice versa, both boards will use different power rails regardless of whether they are on the same board or not.

A green power terminal is soldered onto the PCB and power from the power supply will be distributed to the other components, specifically into the motor drivers. Power for the control board has been designed for the use of an ATX power supply for prototyping. The PS-ON pin is there to short the required wires to turn the power supply on similar to a computer, the microcontroller manages this via the D12 pin.

[pic]

Figure 3: Allegro A4989

C. Data Feedback

The more analog portion of a 3D printer comes in the form of end stops and thermistors. An end stop goes at end of an axis and send a signal to the microcontroller that a motor has moved too far in one direction and has reached its bounds. Two end stops are used per axis and their use are highly recommended for calibration and unaltered performance of a 3D printer. An end stop only requires three wires, signal, VCC, and ground. The way it works is if VCC is shorted then a signal is send to the microcontroller to note that a motor is at the end of the axis. The schematic for end stops is very simple, the 2 connectors that go out to the physical end stop mechanism are soldered right onto the control board.

Thermistors, schematic seen in figure5, have the important task of relaying temperature information back to the microcontroller. Depending on the thermistor the microcontroller will know if the appropriate temperature has been reached to begin extruding the melted plastic. A faulty thermistor will lead to many jams and will probably destroy the extruder in the process. Three thermistors are present, two for each extruder and one for the heat bed. Power comes from the power section of the control board and is shared with the mosfets in charge of heating. Only a single signal goes to and from the microcontroller and is labeled THERM for each respective thermostat.

[pic]

Figure 5: Schematic for thermistor

V. Power Supply

Having an understanding on the functionality of a power supply is very important implementing the design of a power source that’s adequate for the Pegasus Producer 3D printer. There are many options that are great considering for the 3D printer and a proper understanding on the functionality and process of the different implementations is very important. As the name implies the primary function of a power supply is to supply power that is in a certain form, and convert it to a specified form, that best fits the design specification, hence why they are called “Electric Power Converters”. In the conversion process every power supply consumes the energy that’s demanded in addition to the power dissipated by the internal components. There are some general classifications of the power supplies;

A. Functional

These are the types that carry functional features integrated such are regulating and maintaining a steady voltage/current even when there’s a change on its input whereas the unregulated power supply functions differently and it fluctuates with the change of conditions.

B. Mechanical

A bench source of power supply that tends to be used for purposes such as testing a circuit, this circuitry can be found on mounting bases or even sometimes built in machinery

C. Power conversion

These supplies can be divided into linear and switching types. The more common one linear uses the input power directly along with the transformer and other components such as full wave rectifiers, differently from the switching power supplies; it convers AC to DC in form of pulses before actually processing and these tend to be components that operate predominantly in non-linear modes. Switching coverts are usually more efficiently since components spend less time operating.

When building the power supply there were certain things that had to consider such as the filtering capacitor to make sure that the ripple current was within safe range going into the input to the microprocessor.

D. Filter capacitor selection

In the Pegasus Producer it was imperative to keep the rectifier ripple to 0.5V or less to avoid the alternating lost in the sinusoidal wave from dipping into the microcontroller. For the sake of planning for full load the team assumed a constant load current the voltage on the cap will decrease linearly (ΔV = I*Δt/C). For a full wave rectifier the time between the peaks is 8.3ms (1/120Hz). So, to keep the rectifier ripple voltage to less than 0.5V at a 15A load there must be roughly 47,000uF or larger cap (15A*8.33ms/0.5V)= 47,000uF which case the capacitors were put in parallel in order to reach this desired high capacitance.

The input transformer is likely to be the most expensive part of the entire project. The input voltage to the regulator after it has been fully rectified must be at least several volts higher than the output voltage (12V) so that the regulator can maintain its output, in the process all the components have to be accounted for along with their drops at full load. The rectifier diodes for the Pegasus Producer has to be rate enough so that it’s capable of passing a very high peak forward current, typically 100amps or more because of the high capacitance in the circuit It has an Initial spike. The 7812 IC will only pass 1 amp or less of the output current, the remainder being fed by the outboard pass transistors. The circuit is designed to handle loads of up to 20 amps, and so five TIP2955 are wired in parallel to meet this demand. The dissipation in each power transistor is one sixth of the total load, just to minimize having to run components on their max load. Maximum load current will generate maximum dissipation, so a very decent size heat sink was placed in order to account for that required. Because of the design of the circuit in the event that the power transistors should fail, then the regulator would have to supply full load.

Figure 6: Schematic for the Power Supply

Calculations

In this design there is a fine example of Kirchhoff's current and voltage laws. To summarize, the sum of the currents entering a junction, must equal the current leaving the junction, and the voltages around a loop must equal zero, which is basic understanding as an Electrical Engineer. For example in Figure 6 the input voltage is 24 volts. 4 volts is dropped across R7 and 20 volts across the regulator input, 24 -4 -20 =0. At the output the total load current is 17 amps, the regulator supplies 0.866 A and the 5 transistors 3.4 Amp each, 17 = 5 * 3.4 + 0.866. Each power transistor contributes around 3.4 A to the load. The base current is about 138 mA per transistor.

A DC current gain of 35 at a collector current of 6 amp is required. This is well within the limits of the TIP2955. Resistors in the emitter side that are labeled R1 to R6 are included in the circuitry for stability and in order to prevent current swamping as the manufacturing tolerances of dc current gain will be different for each transistor. Resistor R7 is 100 ohms and develops 4 Volts with maximum load. Power dissipation is hence (4^2)/200 or about 160 mW. In the design a 0.5 Watt resistor for R7 was selected to reassure being able to handle larger current. The input current to the regulator is fed via the emitter resistor and base emitter junctions of the power transistors. Once again applying the profound Kirchhoff’s current laws knowledge, the 871 mA regulator input current is derived from the base chain and the 40.3 mA flowing through the 100 Ohm resistor. 871.18 = 40.3 + 830. 88. The current from the regulator itself cannot be greater than the input current. The regulator is the only equipment that should run cold as it can be seen the regulator only draws about 5 mA and should run cold.

VI. SOFTWARE

The software for the Pegasus Producer had to take into account different aspects, such as the limited memory available among with the large data that has to be read from the card

A. System Concept

As it can be appreciated in Figure 7, the printer is continuously changing between five stages. It stays most of the time between reading data, processing data and printing. When the printer is turned on, it waits for an SD card to be introduced. Once a card has been found it then proceeds to read the data from it. In order to do so, it reads from the file “pegasus.gcode” which is supposed to be located on the root directory of the SD card. If it does not find the file, it proceeds to the write data status, which is basically only used when an error occurred. The errors are written in the file “errors.txt”, and are a short report of the type of error that occurred.

However, if the file exists, the printer proceeds to shift between the three states in which it will spend most of its time while turned on. These are read data, process data and print. The first one retrieves the data from the card, small chunks at a time. The second one process the data, that is, it interprets the G-Code commands and translate them into actions that the printer must do, and store them into an action buffer. Finally the printing state is when the printer actually obtains action commands from the buffer and translates it into motors movement. There is a constant movement among this three states until the end of the file is reached, the printer will finish processing the G-Code commands, and will print the rest of the actions stored in the buffer. It then go back to the read data status, and finally goes back to the idle status to wait for the SD card to be taken out, and placed back in to start a new printing.

In the case that an error is found among any of these states, the printer proceeds to report it as discussed previously.

[pic]

Figure 7: State diagram of the Pegasus Producer

B. Necessary Tools

The commands available in the SD card are produced by an open source software called Cura, which takes as an input a file of type “.obj” or “.stl”. Many designs are available online in these formats, but if the Pegasus Producer user wants to create their own design they could use FreeCAD, which is an open source software that permits the user to create 3D models. This way there is no extra cost added to the user because of software required for its usability. What Cura does is that it translates the previously mentioned files into a text file of type “.gcode” which is a language that has been used for computer-aided manufacturing like CNC machines and 3D printers, although they vary a little bit depending which machine will be using it.

A general form of some of these commands and the different parameters that go along with them can be found on Table 2. The two most used commands are the G and M commands, the first ones represent the movement commands and one of the most common one is the rapid movement. An example of this one is the command: G0 F1500 X2.453 Y3.54. As it can be seen, not all parameters must be used in each of these commands, but if a parameter is used a number must follow it.

The M commands are used for other functionalities in the printer such as, setting the temperature of the thermistor and waiting until it has reached its objective, setting the extruder to relative or absolute mode, and enable/power the stepper motors. An example of an M command would be: M104 S209. This commands sets the temperature of the extruder to 209 °C.

It is important to point out that even though it is not specified, the parameters attached to each of this command have a type, and in case it is not respected it can cause errors in the printing. For example the feeding rate should always be an integer. And the millimeters associated to the axis will always be considered floating points.

|Letter |Meaning |

|Gnnn |Standard GCode command, such as move to a point |

|Mnnn |3D printer defined command |

|Pnnn |Command parameter, such as a time in milliseconds |

|Xnnn |An X coordinate, usually to move to |

|Ynnn |A Y coordinate, usually to move to |

|Znnn |A Z coordinate, usually to move to |

|Fnnn |Feedrate in mm per minute. (Speed of print head movement)|

Table 2: Commands and parameter for G-Code

C. Software Concept

Once the G-Codes have been understood the software can be discussed in more detail. As it can be observed in the flow diagram shown in the Figure 8, there is some necessary configuration information to be stored for the use of the printer. This is the dimensions of the printer, the safe temperature values for both the extruder and the heatbed, the origin information as an extra precaution in case one of the endstops used is damaged, and the minimum step length which is the length for the step of each motor in order to calculate how many steps the motors have to take for a given instruction. This data needs to be stored in the ROM of the board since this data should not change unless some physical changes are done to the printer, such as changing its frame, or one of the motors. Therefore this data is saved in a C++ header file, and included into the file that contains the actual code.

Figure 8: Flow Diagram

When the SD card is detected, the printer will call the initializer function which will be in charge of setting up the Pegasus Producer for printer. This means, making sure that all the axis are at their origins by checking endstops, and checking that the temperature of the extruder and the heatbed are appropriate for the type of plastic that will be printed.

Once it is ready to print, the function that reads from the SD card is called, this actually reads from the SD card and place the G-Code instructions into a buffer, which will be passed to the G-Code interpreter function. Once this level has been reached, the interpreter is in charge of determining which instruction is commanded along with its parameters. If it is a movement instruction, it places the movement into a buffer for movements, which is used by the movement function to actually perform the movements by controlling the motors. The calling of the functions is done multiple times because of the limited space available in the RAM memory, and the large size of the gcode file. Throughout this process, several calls are performed to the functions that control the extruder’s and the heatbed’s temperature to ensure that they stay between an appropriate range.

Lastly, the finalizer function is called, this function ensures that the printer stops the process safely. It calls the axis back to their endstops and waits until the heated elements cool down which is important to prevent any damage to the components.

VII. Extruder

The 3D printer extruder is the perhaps the most important part of the 3D printer and would be the equivalent of an engine for a car. The extruder is what takes in the acrylic plastic and deposits melted plastic from a small metal nozzle that is heated it up. The acrylic plastic is pushed in to the hot nozzle by a motor and extruded out as melted plastic at a constant rate. The extruder is what determines each printers’ speed, printing material, and personality.

An extruder consists of two main parts, the cold end and hot end. The cold end is in charge of holding the motors, connecting to the axis, and pushing the plastic filament into the hot end. The hot end contains the nozzle and contains the heating element required to melt the plastic for extrusion. Due to the availability of 3D printers many reference design are available on the internet and many of them can be printed from another 3D printer.

The extruder for the Pegasus Producer can 3D printed from the UCF 3D printer available in the innovation lab almost completely. The cold end, cogs, and wheels can entirely be 3D printed, their designs are open source and can be easily found online.However, the socket head bolts, nozzle, and heating element must be purchased.

The hot end, on the other hand, consists of a 1.75mm J-Head MK-V Hot End 0.4mm Nozzle. It usually comes with a the thermistor already attached to it using a special tape designed to withstand high temperatures. Everything is put together using various M4 and M3 size socket head and screws. The hot end works a lot like the solder iron and is heated the same way. The hot end lies just above the filament and is used to melt the plastic, the hot end is connected directly to the power supply to heat it up. The hot end needs to be heated up to a correct temperature that can melt the plastic but not destroy it and is usually regulated by the microcontroller. Like any device that uses a heating element the 3D printer has to heat up before it can began printing similar to how an oven has to pre heat to a certain temperature before it can begin to cook food. Filament goes under various changes when being passed through the extruder. First, it begins with the Glass transition temperature (Tg) which is the temperature when the plastic goes from solid to a rubbery, soft state. After that is the melting temperature (Tm), this is when the plastic becomes a liquid. The ideal extrusion temperature is between Tg and Tm which falls around 210 degrees celcius to 225 degreees celcius for standard thickness ABS plastic. Other factors that the extruder mjst handle prior to extrusion is temperature versus extrusion speed. The ratio must follow the following equation:

Vmax = k (THotEnd - Tplastic)

Vmax = max velocity of extruder

THotEnd = temperature of hot end

Tplastic = ideal extrusion temperature

K= nozzle size constant

Our extruder is based off similar designs that exist in the market. Constraints for extruder design demanded for the following: Anti vibratory cog, an insulator known as a bowden tube pass Plastic and prevent heat transfer to cold end, and a mounted stepper motor that will rotate a thoothed pinch which will push the filament towards the hot end. The extruder can be seen in Figure 9.

[pic]

Figure 9: Pegasus Producer 3D extruder

References

[1] Print the Legend. Dir. Luis Lopez and J. Clay Tweel. Netflix, 2014. Netflix.

[2] Mack, Eric. "Here's the 3D-printing Institute in Obama's State of the Union."CNET. CNET, 12 Feb. 2013. Web. 26 Nov. 2014.

[3] "Multiple Winding Transformer and Multicoil Transformers." Basic Electronics Tutorials. N.p., n.d. Web. 04 Dec. 2014.

[4] "Reprap Development and Further Adventures in DIY 3D Printing." : Universal Paste Extruder. N.p., n.d. Web. 17 Nov. 2014.

The Engineers

Roberto Tang is a 24-year old graduating Electrical Engineering student who is taking a job with Orlando Utilities Commission in Orlando, FL as a Distribution Engineer, specialized in Power Systems with plans to pursue a Master’s Degree in Business Administration.

Giovanny Vazquez is a 23-year old Electrical Engineering student who is taking a job at Freescale Semiconductor as a Validation Engineer in Austin, Texas. His aspirations is to continue into his Masters and work in the semiconductor field.

Hector Arenas is a 24- year old graduating Computer Engineering student who is taking a job with Epic in Madison, Wisconsin as a software developer. Among his plans is to pursue a Master’s Degree in database design, as well as an MBA.

................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download