What exactly Linear advance means and how does it affects your 3D print’s quality and finish? Is there any way you can improve your print’s quality using this method? These are the questions which will be answered in this blog post. Lets get started
Before answering what exactly Linear advance is, let us take a look on what exactly happens inside the extruder and hot-end while it is printing. It is really important to know the background story first. It might not take that long. So just keep calm and keep reading
In 3D printers with Bowden extruder, the fixed extruder feeds the filament to the moving hot-end by pushing the filament through a tube, which protects the filament from breaking. Extruder is relatively heavy when compared against the hot-end which in itself comprise of heater and the nozzle where the filament is actually melted and comes out from. A simple depiction is shown below in figure 1. Separating the extruder and hot-end makes the hot-end light which results in precise movements of hot-end while printing
Now as the filament moves across the tube enclosing the filament, it often tends to build pressure. In other words, when the extruder which is connected to a motor, pushes the filament in the tube, towards the hot-end, filament forms wave like structure. And the reason for this is simple. The size of nozzle opening is usually of the range 0.4 mm while a filament is 1.75 mm thick in girth. When the PLA melts, it oozes out of nozzle at a fixes pace. If the extruder pushes the filament more towards the hot-end, the filament would end up building some pressure in the tube and hence it will form some kind of wave inside the tube as shown in figure 2 below. Now, even if the extruder has stopped pushing the filament towards the hot-end, the pressure already built up inside the tube needs to be release and there is only one opening from where it can be released, the Nozzle. Therefore, the nozzle end up oozing out a little extra material, which it should NOT.
Due to this phenomenon, the layers we get are not uniform. If we take a closer look on each layer, it will have regions with under-extrusion which happen as the hot-end quickly starts moving at the beginning of layer, then comes good-extrusion which is region with even layer thickness and finally the layer end has region with over-extrusion which appears like a BLOB which forms as the nozzle keeps oozing out PLA even after the hot-end has stopped moving at the end of layer printing, as shown in figure 3.
This will cause 3D prints to have unwanted tiny blobs at the ends of each horizontal layer as shown in figure 4. The blobs are exaggerated slightly to make the blob effect conspicuous. However, this problem of extra material oozing out of nozzle, can be mitigated by enabling the Linear Advance.
What is Linear Advance ?
Linear advance is basically an algorithm which predicts the existing pressure in the tube. It is now-a-days included in almost all of the modern firmware of every 3D printers. All you need to do is enable it as it is disabled by default.
It basically separates the extruder from the other stepper motors in terms of movements. For example, when some stepper motor is calibrated, it’ll move the distance, say 0 to 100 mm in exact same manner (covering exact same distance with same speed) every time. But with extruder, it is different. In case of extruder, it can be compared to the process of icing on a cake. The reason being, as mentioned above, we’ve a 1.75 mm thick filament which melts and is squeezed out from a 0.4 mm thick Nozzle. So, the pressure needs to be applied evenly, such that the liquid PLA oozing out of Nozzle doesn’t spread out too much.
How does it function ?
Linear Advance calculates the pressure build up in the extruder and causes the hot-end to stop printing slightly early before reaching the end of layer. So, the extra material still oozes out while extruder is still moving and printing the last region of each horizontal layer which creates smooth layers. This way, it mitigates the formation of blobs
It also adds a slight delay to the movement of hot-end at the beginning of each layer. So that, the hot-end’s movement aligns with the oozing of material which reduces under-extrusion at the beginning of each horizontal layer.
- With Linear Advance enabled, you get sharp corner
- It speeds up the printing process slightly
- It decreases the blob formation.
- Setting it up is very easy, in case of MARLIN firmware which is used or can be flashed in most of the Chinese 3D printer companies like Creality, AnyCubic and FlashForge etc.
- It may take some time to download the firmware, setting it up especially when you are a beginner.
Enabling Linear Advance
Before enabling Linear Advance, there are some pre-requisites that needs to be fulfilled.
- Setup bootloader and access to firmware
- Make sure to calculate E-Step from calibration.
- Make sure you have a consistent first layer.
Now, after making sure all the pre-requisites are met, Linear Advance can be enabled in Marlin using the following procedure
- Download Marlin by clicking on the Button shown below (just scroll down to find two buttons) and downloading the latest build available for your platform. Its a small ~14 MB zip file.
- After downloading the Marlin, extract it to a location you can easily find (e.g,on Desktop or perhaps in Downloads folder, whichever you like)
- COPY : Go to folder config -> examples -> Creality (or the company of your 3D printer, in case it is different from Creality) -> Ender-3 (or the model of your 3D printer) and then copy all the files.
- PASTE: Go to folder Marlin and paste all the copied files here. It will replace two files ( configuration.h and configuration_adv.h )
- Now simply open the file Marlin.ino with Arduino IDE which will open all the necessary files automatically in Arduino IDE in different tabs (if you don’t have it installed, press the button below to go to Arduino website, download the software and install it). Go to tab “Configuration_adv.h”.
- Press CTRL + F (on Windows) or / (on linux or if opening the file in vim) and search “LIN_ADVANCE”.
- Uncomment the line saying #define LIN_ADVANCE (basically delete the two forward slashes ‘//’ in the beginning of the line). In build 2.0.x, it is on line 1415. You can simply press CTRL + G and type 1415 to directly go to that line, but in future builds line number might change as well.
- Save the code. We will use this updated code to flash the Marlin firmware to 3D printer.
- Connect you 3D printer to the computer using USB cable. Your computer will assign a COM port to your 3D printer.
- At this point, chances are that your printer’s motherboard is not installed by default on your computer. So to do that, click on the button Printer boards below to open the website. You need to find which board your 3D printer uses. In case of Creality Ender-3, it uses Sanguino , the repository of which is maintained by Kristian Sloth Lauszus. Simply copy the path (or URL which is mentioned on the website, ending with .json)
- Next, go back to Arduino IDE -> File -> Preferences and paste the URL under Additional Boards Manager URLs as shown in figure 5 below. This only tells Arduino IDE the address from where to download, but it has not downloaded the profile yet. To do so, go Arduino IDE -> Tools -> Boards (currently selected board) -> Board Manager as shown in figure 6 below. Once it opens, search for board called “Sanguino” and install it by clicking on the Install button on the lower right corner.
- After installing the board, you also need to select it(pretty obvious, isn’t it, why would you install it otherwise ! Duh,.. :p). Simply go to Tools -> Boards -> Sanguino and select it.
- We are almost there, don’t worry. After this, you also need to select the right processor used by your 3D printer. In case of Creality Ender-3, it uses ATmega 1284P. Select the board by going to Tools -> Processors -> Atmega 1284P (16 Mhz). Done too much selection. Phew, i know….!!
- We need one last thing – U8glib.h library. To to do, click on button below for “U8glib” to open the link in a new tab, scroll down and go to “U8glib for Arduino” (or simply select this hyperlink), download the version which is not too recent (at the time of writing this blog, v1.17 seems a good choice as v1.18 is the latest one) as a zip file.
- Go to Sketch -> Include Library -> Add .Zip Library and select the downloaded file as shown in figure 7.
- Now, all configurations are done. Click the Compile button (shaped like a tick) in Arduino IDE to compile. It might take some time depending on the speed of your computer and available RAM but it should compile successfully without errors.
In case you still face issues, check out the video tutorial below by Thomas Sanladerer on how to upgrade Marlin Firmware.