Week 11

About Me Assignments Final Project Fab Lab 2017
About Me Assignments Final Project Fab lab 2017
×

Wally - The 3D Printer

Fully Funcitional Wally

MM board checking

Wally Project

Wally Timelapse

Machine Design

Task Division

  1. Electrnoics Assembly and Programming - Fida Hussain
  2. Wireless Communication - Muhammad Asim
  3. Preprocessor Programming - Nisar Ahmed
  4. Electronics and Programming - Sohail Ahmed Soomro
  5. Hot End Extruder Management, Electrnoics Assembly Tomas
Assembly of a 3D printer is a massive task due to the ultraprecise nature. We had an idea that designing and setting up the hardware will be easy but caliberating software and hardware would be nothing less than challenging. So we just took a big leap of faith thinking that if nothing else we will get a thorough experience.

Hardware / Software platforms

over the past few years numerous hardware/software platforms have appearead for 3d printing. Here we present a brief of the most common hardware / software platforms.

Replicating Rapid prototyper (RepRap) project was founded about a decade ago and this project has evolved massively with world wide interest of enthausiasts. Over time this platform has matured into very stable (feature rich) 3D printers which cost less than 500 USD. In market there exist several varients of freely available software and hardware. Two of the most popular software (firmware) and hardware we came across are listed below:

Software
Hardware


Since support for Marlin is widely available in our fablab therefore there was no discussion for the choice of firmware. There were acouple of RAMPS 1.4 boards available in the 3D printer room and we were lucky enough to borrow them there was no discussion on the choice of hardware either.

The picture is pretty much self explainatory.

RAMPS

RepRap Arduino Mega Pololu Shield, or RAMPS for short. It is designed to fit the entire electronics needed for a RepRap in one small package for low cost. RAMPS interfaces directly onto an Arduino Mega with the powerful Arduino MEGA platform and has plenty room for expansion. The modular design includes plug in stepper drivers and extruder control electronics on an Arduino MEGA shield for easy service, part replacement, upgradability and expansion. Additionally, a number of Arduino expansion boards can be added to the system as long as the main RAMPS board is kept to the top of the stack. The useful user manual for RAMPS is available here.

Circuit Design

RAMPS Circuit

RAMBo

RAMBo (RepRap Arduino-compatible Mother Board) is an all in one RAMPS class motherboard targeting convenience, reliability, and performance.

Circuit Design

RAMBo Circuit

Repetier Host    

Repetier-Firmware is a firmware for RepRap like 3d-printer powered with an arduino compatible controller. This firmware is a nearly complete rewrite of the sprinter firmware by kliment which based on Tonokip RepRap firmware rewrite based off of Hydra-mmm firmware. Some ideas were also taken from Teacup, Grbl and Marlin.

Repetier also provides a very handy tool Repetier Host this tool is a ideal platform of basic control and caliberation of the system. This software interfaces directly with the Arduino Mega board through USB interface allowing us to retrieve sensor information and pass G-code scripts. We found the following youtube tutorial very useful to this end.
We used Repetier Host extensively to caliberate the XYZ, Extruder and Endstops.

Repetier Host G-Code Tutorial

Marlin   

Marlin is firmware for RepRap single-processor electronics, supporting RAMPS, RAMBo, Ultimaker, BQ, and several other Arduino-based 3D printers. It supports printing over USB or from SD cards with folders, and uses lookahead trajectory planning. Marlin is licensed under the GNU GPL v3 or later. It is based on Sprinter firmware, licensed under GPL v2 or later.

The bill of materials of electronic components necessary for the Wally project is listed here.

1. Electrical Assembly

Circuit Design

Typical Circuit Diagram

We started putting together the power supply, stepper motor and interconnection with RAMPs hardware. A good user manual is avaliable at reprap website . After double checking all connections we powered up the circuit.

Circuit Design

Assembly of electronic components.

2. Firmware Setup

The next step was to download the updated marlin firmware from HERE

We also had to study in details the marlin framework to be able to configure the board to operate the stepper motors and hot-end, endstops and thermal sensor information. We took help from the following youtube tutorial.

Merlin Framework Setup Tutorial

As this toturial described when we open the marlin project in arduino platform, it contains multitude of files, however only configuration.h should be modified for setting up the system. Most of the features can be activated/deactivated by simply commenting/uncommenting the code.

Our modified configuration file is available HERE .

3. XYZ, Extruder and Endstop Caliberation

Once all the cables were connected we were in a position to powerup the circuit. The next and most important thing was to caliberate the system. Using default feeds and speeds values from firmware or taking values from any internet directly would not work and we had determine them through simple calculations, trial and error.



Once we got going , we had to write a simple G-code script to test our system. Tomas looked up on the reprap and created this list of important g-code commands which we utilized in our subsequent test scripts.

G-Code preprocessor commands

Command Explanation
M303 E0 S200 C8 This will heat the first nozzle (E0), and cycle around the target temperature 8 times (C8) at the given temperature (S200) and return values for P I and D
M301 Pxx.xx Ix.xx Dxxx.xx The Kp, Ki, and Kd values can be entered with
M500 Save the changes
G1 Xnnn Ynnn Znnn Ennn Fnnn Snnn feedrate per minute of the move between the starting point and ending point
G28 Move to Origin (Home)
G21 Set Units to Millimeters
G90 Set to Absolute Positioning
G91 Set to Relative Positioning
G92 Set Position
M0 Stop
M17 Enable/Power all stepper motors
M18 Disable all stepper motors
M82 Set extruder to absolute mode
M92 Set axis_steps_per_unit
M104 Set Extruder Temperature
M105 Get Extruder Temperature
M108 Set Extruder Speed
M109 Set Extruder Temperature and Wait
M114 Get Current Position
M115 Get Firmware Version and Capabilities
M117 Hello World:print
M201 Set max printing acceleration
M203 Set maximum feedrate
M208 Set axis max travel
M300 Play beep sound
M360 Report firmware configuration
M550 Set Name


Tomas spent sometime writing simple gcode script to take wally for a test drive. And the results were encouraging.

Circuit Design

Results of simple G-Code script



4. G-Code Preprocessor

This was the task given to me from the Group, initially I felt quite difficulties as GCode is rather difficult to manage, but soon I got a hang of it

In assignment 5 we came accross G-code which is a simple set of instructions followed by 3D printer to traverse and render filament material. We didn't have deeper understanding of the code before, but to work with a 3D printer we had to delve into details of the G-code and even wrote our own sample scripts to analyze and caliberate our printer. A basic set of commands which we have found very useful are listed above for reference. An exhaustive list of commands can be found here.

Normally, linear 3D printers don't need any G-Code preprocessing, because the z-axis is either static or the extruder moves linearly in the z direction. But in case of the Wally, the bed moves in an arc. So we need compensate for this curvelinear trajectory. Luckily there exist a python script which can compensate these effects.

Circuit Design

Results of simple G-Code script

There are many specific commands provided in the Wally G-Code preprocessor, some important of those are explained here.

These are the bed caliberation points on certain height the value of x, y and z, as the Wally moves the bed in arc so we had to take into account this movements.

Circuit Design

Results of simple G-Code script

For the wally segmentizer to generate accurate code it requires several parameters from the hardware setup. Some of the parameters which we configured listed here:

There are few commands which are important to be explained here:

The modified preprocessing file considered our printer can be here found here.



Once the modified code is availabe is really makes sense to simulate the code using any of the numerous g-code simulation and analysis softwares to validate the operations because (as in our case) if g-code preprocessor has not been carefully configured the modified g-code may veer completely off course. For a large g-code file it may not be possible to located anamolies without exhasustive review. We found following gcode analyzers.

MM board checking

MM board checking

Interface to Network:

To improve the usefulness of our system we decided to connect wally with a remote computer using octaprint platform. This platform is webserver application running on Raspberry Pi which is connected to a RepRap printer through USB interface. Through this application we can load jobs to a printer remotely and manage/monitor it's performace from a remote location.

We found very good youtube tutorial here

Network Tutorial

Octoprint:

  1. The list of stuff required for octoprinter.
    • Raspberry Pi
    • 8G SD Card
    • 1A 5V DC power supply
    • USB Cable
    • Ethernet cable (Easily Wifi-able)
    • Webcam (optional)
    • PuTTY
    • Octopi 0.13
  2. Connections
    Circuit Design

    Electrical Connections to Raspberry Pi.

  3. The step by step procedure to setup octaprint server are as follows
    • Download the image file for Octopi 0.13 from here , unzip it and install.
    • Insert your SD Card into the computer and format it.
    • Download the Win32DiskImager-0.9.5-install.exe , and run the program for install the program.
    • Run Win32DiskImager.exe
    • Select your SD Card drive letter in Device droplist.
    • Select the image file that you download from Octoprint. e.g. 2014-06-20-wheezy-octopi-0.9.0.img
    • Click "Write”.
    • When the image is successfully written, Do not remove It from the PC.
    • Open the SD card drive and find the file “ octopi-network.txt” and open it.
    • In "octopi-network.txt" you will find comments, following them and configure it with your internet connection.
    • Now remove the SD card from computer and plug it into the Raspberry pi.
    • Now make the connections and connect power supply, Ethernet cable or Wi-Fi and Arduino mega with raspberry pi as shown in figure given above.
    • Power On the raspberry pi now. And access it from your browser by writing http://octopi.local
      Circuit Design

      Login screen

  4. You can also access the octopi server from "Networks" Option in My PC of your operating system.
    Circuit Design

    Access to Raspberry pi from windows network.

  5. After opening the webpage of octoprint, the first thing to do is to set the username and Passward.
    Circuit Design

    Access to Raspberry pi from windows network.

  6. The last step is to log in to the octoprint webpage and click on the connect button to make connection with the printer. You can set any baud rate from the group of given baud rate. We are using 115200. Octo printer is ready now, just drag and drop your gcode file and hit print to start.

Suggestions for further improvement

Wally has been a very rapid project. Although its more of assembly and caliberation based project. This project has been a wonderful opportunity for us to learn variety of things related to machines that make machines.
  1. The output quality of system could be improved through further fine tuning of the system parameters.
  2. The printing tray is not perfectly flat and this problem surfaces.