Configuring our printer for use
- Intro to RepRapFirmware
- Setup preparations
- RepRapFirmware Configuration
Intro to RepRapFirmware
Now that we have connected to our Duet WiFi controller and updated all relevant firmware we are going to configure it to our needs. In this case as a classic 3D printer movement mechanisms as a Cartesian source printer.
I am setting it up same as an Ultimaker 2 works, meaning XY axes are moving up top, and bed are going up and down. Z homes to MAX.
The Duet WiFi uses RepRapFirmware which is drastically different from the Marlin and Smoothieware setup I’m used to, as all setups are done using regular Gcodes and Gcodes specific for RepRapFirmware, which are put into files and in turn are executed (read into memory of the controller) on startup.
You can change any settings by issuing new Gcodes via a Gcode terminal either in the webpanel or by using Pronterface over USB or similar. Any Gcodes issued this way are not retained after a reboot (unless current running configuration is saved).
It’s a big change from the Marlin and Smoothieware, but luckily we can find a lot of information in the RepRap Firmware FAQ, which is quiet extensive.
Before continuing we are going to clean up in our files, as some of them are really meant for Delta printers.
Files listed under System Editor tab with description.
- bed.g is autoleveling for Delta printers – Removing this.
- config.g our – This is our primary configuration file, where the core configs are stored.
- deployprobe.g is for deploying a probe for Delta printers – Removing this.
- DuetWebControl.bin – our Web Interface firmware file.
- DuetWiFiServer.bin – our WiFi Server firmware file.
- homedelta.g is a file for homing on a Delta printers – Removing this.
- iap4e.bin – our Electronics firmware file.
- pause.g is for pausing the printer.
- rResume.g Resume file.
- retractprobe.g is to retract a probe – Removing this.Deleting the following 4 files.
We are going to use the RepRapFirmware Configuration Tool to do our initial setup and will refer to the Duet WiFi overview I made for my previous blog-post: Duet WiFi controller from the previous Duet WiFi – Intro & Explained.
As you can see, they have a nice and clear start page, where we are going to start our setup by choosing the Custom configuration option and click next.
Next up we setup some basic settings, like board type, firmware version and compatibilty.
Our board is Duet WiFi, and Firmware version is the newest if you updated firmware before this point.
Enable non-volatile memory enables the use of custom commands loaded during startup, which we havn’t put into the firmware – I hanv’t looked much into this to be honest (yet), so leaving it unchecked.*
The compatibility really means how the printer is going to print outputs to terminal when you issue commands, and not as it operates.
In short, it emulates output responses. You can choose from several systems of your chouse: RepRapFirmware, Marlin, Teacup, Sprinter and Repetier.
Marlin is default, but we are selecting RepRapFirmware here.
Type of Ultimaker printer is Cartesian. I’m leaving distance at default and find the exact length of each axis later.
I only changed Firmware compatibility in this step.
In the motors section we have a lot of options. Here’s a screenshot of default settings.
I’m changing the Microstepping for each axis to x32 and enable interpolation.
Note: Interpolation is in fact only supported when setting Microstepping to x16. Interpolation means it interpolates (chops up) each physical step and in effect turn out 1/256 microstepping, leading to incredible smooth and silent workings.
In order to find steps/mm we will click on the Calculate steps per mm on the far top-right side/corner.
We’ll be presented by a pop-up window where we can insert our parameters.
Our XY motors are the same, using standard 1.8 motors driven by standard GT2 belts using 20-GT2 pulleys.
This leads to 160mm pr steps for x32 microstepping for our X motor.
Click on Y, to check settings and then go to Z.
An 8mm standard (most common cheap) lead screw used on the Ultimakers, also called Trapezoidal screws are rightly named TR8*8 (the ones I have), which means it is 8mm diameter and has, according to this calculator, at pitch of 8mm.
Rightly this leadscrew has a pitch(distance between the raised ridges) of just 2mm and 4 starts (seperate ridges).
Multiplying pitch and starts on a lead-screw equals the length of travel for a full revolution of the screw, which is 8mm.
The last 8 in TR8*8 denotes this travel length. We are using this 8mm as pitch in the configurator.
You can also buy TR8*4 and TR8*2 screws, but the 8mm is the most commonly used and the cheapest.
Click Apply this value botton and the values are automatically inserted into your Steps pr mm section.
Our steps are now updated:
Next we change our Y axis to match X and update maximum for Z axis to 100. I’m leaving the Motor current at 800mA as that is matching what I used on Smoothieware. Drivers are different though, so it might be subject for a future change. But the same applies for the instantaneous speed change, Maximum speed and Acceleration.
The Motor driver is the variable used in the Gcodes used to setup everything.
I’m using just 1 extruder which is my own Belted Extruder. It is highly geared on it’s own and silent, so I don’t need high microstepping for any of these reasons.
I’ll set it at 32(on) to try out the new driver and change it later if I feel the need. If you follow the above link, and look all the way at the bottom of the page, you can see the steps needed.
In my case I’ll set the steps at 2050 – still need to tune it later.
I’m only changing microstepping and steps here. I really have no idea about the other settings for now, but might change by testing.
Motor current should match my motor just fine.
I have no experience in using this feature, so leaving it at default.
I can see how it might help keep the Z-stage in place if it tends to drop. On the other hand it makes manual movement all but impossible, say if you want to change filament in the middle of a print and need to manually retract and insert new filament.
Subject for change later as much else 🙂
Next stop on our way is configuring our Endstops.
Here’s the Default settings shown.
I always use Normally Closed on my endstops as they trigger if some error happens, like broken wire or switch – Ie. they are carrying a small amount of current through always and if this is broken, the switch is seen as triggered.
The endstops are located at X min and YZ max on my Ultimaker clone, as is regular ultimakers.
Making changes to the speed to more closely fit an ultimaker style printer.
Since I do not have a z-probe, I just leave as is and click next.
The default settings for heaters are show here:
I only have 1 heater, so leaving that alone.
I’m raising maximum heater temperature to 320 as I do print Polycarbonate now and then.
People using the full metal E3D hotends should raise it to at least 290c in order to be able to tighten the nozzle as recommended by E3D.
I’m changing the control method of the bed to PID from Bang-bang, as I’m using a powerfull 500w AC heater and it needs to be tightly controlled.
Now it gets hairy! In all honesty, I really hope this section is tweaked in the future to make it more userfriendly by implementing some options of thermistors, brands and thermocouplers + pt100 settings.
As it is now It’s completely above all but the most expert users and there’s no links to more userfriendly info, so it will leave most users pretty stumped.
In short we just leave it alone.
The Output scale factor is later modified when do a PID-tuning after applying these configurations.
The Series resistance refers to onboard components, so I’m a bit at a loss why we have this option here.
The first value under Thermistor coefficients is how much resistance your thermistor is having at 25c degrees. Not much worth when using PT100 or Thermocoupler though, but just leaving as is.
Note: I later found I had to put in the same number for Bed as for E0 here.
Second value K, is based on type of thermistor used, while the third C, is coefficent of steinhart-hart equation! I can’t explain this, so just leave as is.
The Sensor channel denotes the channel we connect our sensors to. We leave the Bed sensor channel at ADC0 and E0 at ADC1
Note: You might wonder at my top temperature at 320 and now I use thermistor! I’m normally using a thermocoupler, but using thermistor for the case of this configuration.
From the Duet Wifi documentation on Heater and Thermistor settings, the B value (K) of the Semitec 104GT-2 thermistor is 4388 at 220c.
For the sake of ease, I leave it as is for now and click Next.
Here’s the default settings show for our tools.
For each hotend, or maybe for each color on a multi-color hotend, we define a tool.
I only have a single E3Dv6 on my setup, so leaving Number of tools as is.
I’m putting a mark in Select first tool on start-up, which makes it available as default and define which tool I select, which is just Tool number 1.
I only have 1 extruder E0, so can’t pick and choose any different extruders.
Leaving offset as is and click Next.
Next up is the compensation settings.
Compensation and autolevel is used by many people interchangeably, but that is for another time.
I’m leaving as is, as I have nothing of the sort on this machine, and just press Next.
Here you can disable the network.. maybe you would want this for security reasons and only use it over USB if in a school or company.
I’m configuring the Printer Name as DuetUM2 and do not type a password. It’s really annoying having a password during setup, but do what fits your usage scenario.
You can leave DHCP on, if you want the printer to aquire IP automatically (or if you configure it on your router/dhcp server).
Note how the default gateway is set at the last IP in the range, and not as the first IP which is more commonly accepted standard by Cisco, so you might need to change this as well.
Subnet mask should not be changed in most normal home networks.
We have several options for our fans and the setup GUI here, is really nice to handle it.
Before continuing, lets take a look at our Duet WiFi controller from the previous Duet WiFi – Intro & Explained blog-post, to see where the fan connectors are located:
If you want to read some more about Duet WiFi fans there is a nice section about Connecting and configuring fans on Duet Wiki.
In order to choose, we have 1 piece of important information: FAN1 is always on at bootup, so this one is ideally used as heatsink fan for the hotend.
That one picked, we choose FAN0 as our object cooling fan and FAN2 as control for the fans I have on my motors to cool them when my bed is heating up my printer case, as a sort of “passive” heating chamber.
Value: I’m leaving FAN0 at default 30% and set Fan1 and Fan2 at 50%
Invert output: This is required for 4pin pwm fans, so leaving them at No.
Frequency: I don’t honestly know how to figure out what to pick, so leaving it at 500 Hz. By using Mouse-over, it says PWM should be put at 25000 Hz instead.
Thermostatic Control: No for my FAN0 as we need to control this more dynamically to cool our objects. FAN1 and FAN0 is on Yes.
Monitored Heaters: This denotes the heater a fan is looking at when thermostatic control is on. FAN1 which is for Hotend Heatsink, it is set to E0, while FAN2 which is for the fans on my motors, which needs cooling when heated bed is hot, is set to Bed.
Thermostatic mode trigger temperature (heat controlled): Default is 45c, but I’m just used to having it at 50c for Hotend Heatsink, so I’ll do that for FAN1. I put FAN2 at 60c for Bed.
I do not have any Custom settings for config.g now, so just pressing Finish.
You’ll be presented with this pop up window with some help text. We are allready using Duet Web Control and is choosing Download files as ZIP.
See this page for further information about the purpose of these files.
Navigate to your downloaded file, which is named config.zip
Click here to download the files I just generated: config,zip
In your Duet Web Panel, click on Settings and either click on Upload File(s) and pick your config.zip, or simply drag and drop the config.zip file onto the Upload File(s) section.
The files will be uploaded super fast, so fast I didn’t have time to capture it, and you are presented with a dialogue box about rebooting the Duet. Click Yes.
Lets take a look at our files in Settings -> System Editor
Here we now have a full compliment of files to control our printer.
As it is right now, you should have basic usage of the printer, but many things might need to be modified like:
- Direction of motor/axis movement
- Temperature measurements
- Speed of movement
We are going to do the final adjustments in the next blog-post, where we are going to set all of these things right, by digging into the config.g file.