Many users are looking for ways to improve the quality of their 3D printers. What most of a lot of them don’t know is that you can improve quality by enabling a function called linear advance.
That’s why I wrote this article, to teach you what is Linear Advance and how to set it up on your 3D printer.
What Does Linear Advance Do? Is It Worth It?
Linear Advance is essentially a function in your firmware that adjusts for the pressure that accumulates in your nozzle as a result of extrusion and retractions.
This function takes this into consideration and performs additional retractions according to how quickly the movements are made. Since even when your nozzle travels quickly, pauses, or goes slowly, there is still pressure in it.
You can enable it via a plugin on Cura or by editing your firmware. You’ll need to properly tune this feature so it works properly. That means setting the correct K-value, which is the parameter that will decide how much linear advance will affect your model.
The advantages of a well-configured Linear Advance are more precise curves, control in reducing the speed of the curves besides an increase in speed without reducing quality.
One user recommends using the Linear Advance function as it can provide excellent results, with sharper corners and smoother top layers. He also noted that you’ll need to tune the function according to the material you’re using and the model you are printing.
Another user recommends enabling linear advance as it has allowed him to produce some high-quality results using it.
Making sure your printer is in good working order with the extruder calibrated is a very important first step. You should also check if the slicer settings are optimized before you begin with how to set up the linear advance.
It’s important to note that linear advance won’t fix any issues present on your printer so if you are experiencing any problems, try to fix them before enabling this function.
Check out the video below for more information about Linear Advance.
How to Use Linear Advance in Marlin
Marlin is the most well-known firmware used in 3D printers. Although you may want to upgrade it over time, it is typically the default firmware for most printers.
Here’s how to use linear advance in Marlin:
- Change and reflash the firmware
- Adjust the K-value
1. Change and Reflash the Firmware
To use Linear Advance in Marlin, you’ll need to change and reflash your printer’s firmware.
You’ll do that by uploading your existing Marlin firmware to a firmware editor, then removing the “//” text from the line “#define LIN ADVANCE” under “Configuration adv.h”.
It’s possible to find any Marlin version on GitHub. Just download the one you are using on your printer and upload it to a firmware editor.
Users recommend using VS Code as a firmware editor since you can find it for free online and it allows you to easily edit your firmware. After removing the line, you’ll just need to save and upload the firmware to your printer.
Check out the video below for more detailed information on how to edit Marlin using VS Code.
2. Adjust the K-Value
The final step before having linear advance working on your printer is to adjust the K-value. It’s important to adjust it so you can properly use linear advance.
Adjust the slicer settings on the interface of the Marlin K-Value Generator to correspond to the ones you’re using. That means nozzle diameter, retraction, temperature, speed, and print bed.
The generator will create a G-code file for your printer with a series of straight lines. The lines will start slow and change velocity. The difference between each line is the K-value it is using.
At the bottom of the website’s slicer settings section, go to “Generate G-code”. The G-code script should be downloaded and loaded onto your printer.
You can now start printing but be aware that you will need to change your K-value anytime you alter the speed, temperature, retraction, or change filament type.
One user suggests using the Marlin K-value generator as it will help you find the optimal K-value for your printer.
Another user recommends using a range of 0.45 – 0.55 for different brands of PLA and 0.6 – 0.65 for PETG as he found a lot of success using these K-values, though it depends on your set up. The user also added that you’ll know it is working when you see the extruder moving back a bit at the end of each line.
Check out the video below for more information on how to use linear advance on Marlin.
How to Use Linear Advance in Cura
Cura is a very popular slicer that is very well-known in the 3D printing world.
Here’s how to use linear advance in Cura:
- Download the linear advance settings plugin
- Add G-code
1. Download the Linear Advance Settings Plugin
The first method you can do to use linear advance in Cura is to add the linear advance settings plugin from the Ultimaker Marketplace. To do that, first sign into your Ultimaker Account.
After finding the plugin on the marketplace and adding it you will need to approve Cura’s pop-up request to sync the settings. The plugin will start working after a few more pop-ups.
The “Setting Visibility” dialog will appear if you navigate to the “Print Settings” menu and select the three lines symbol next to the search field.
To make all options visible, select “All” from the dropdown menu, then click OK to end the window.
In the search box, type “linear advance,” and then enter the K-factor value in the entry for the linear advance factor.
Linear Advance will be enabled if the Linear Advance Factor option has a value other than 0. Users recommend both this method and the one covered in the next section as two easy ways of enabling linear advance in Cura.
One user also recommends taking a look at the “Material Settings Plugin” which enables you to set a different linear advance factor per material.
2. Add G-Code
Another method of turning on linear advance in Cura is to utilize the G-code Start Scripts, which makes the slicer send the Linear Advance G-code to the printer before beginning the printing process.
To do that just select “Settings” from Cura’s top menu. Then select “Manage Printers” from the dropdown menu.
Click the “Machine Settings” option after selecting the printer that has to be customized.
Then you will need to add a final line of the Start G-code input, with the Linear Advance G-Code (M900) and the K-factor. For a K-factor of 0.45, for example, you’ll add “M900 K0.45” to properly enable linear advance.
Linear Advance will automatically be activated by Cura once you begin the printing process since the G-Codes in the Start G-Code input run before each print, eliminating the need for you to manually activate it each time you print.
To disable this feature you can either change the K-factor to 0 or remove the line from the box. Be aware that if your firmware does not support linear advance then the G-Code will just be ignored by your printer, as one user stated.
Check out the video below for more information on editing G-Codes on Cura.
How to Use Linear Advance in Klipper
Klipper is another very popular 3D printing firmware. In Klipper, you can also use the linear advance function but it’s important to note that it has another name.
“Pressure Advance” is how this feature is labeled over at Klipper. To properly use the Pressure Advance feature, you’ll need to correctly determine its settings.
Here’s how to use linear advance in Klipper:
- Print test model
- Determine the optimal Pressure Advance value
- Calculate the Pressure Advance value
- Set the value in Klipper
1. Print Test Model
The first recommended step is printing a test model, like the Square Tower test model, which will allow you to raise the Pressure Advance value gradually.
It’s always good to have a test model ready when tuning in more advanced settings like Pressure Advance, that way you can easily reach the optimal values.
2. Determine the Optimal Pressure Advance Value
You should determine the optimal pressure advance value by measuring the height of the test print, through its corners.
The height should be in millimeters and must be calculated by measuring from the test print’s base up to the point where it looks the best.
You should be able to notice that point by looking at it as too much pressure advance will deform the print. If the corners present different heights, choose the lowest to measure.
To properly measure your test print, users recommend using a Digital Caliper, which you can find over at Amazon for great prices.
3. Calculate the Pressure Advance Value
For the next step, you’ll need to do a calculation to determine the Pressure Advance value.
You can do the calculation following: Start + measured height in millimeters * factor = Pressure Advance.
Start is usually 0 as it is the bottom of your tower. The factor number will be how often your Pressure Advance is changing during the test print. For Bowden tube printers, that value is 0.020 and for direct drive printers, it is 0.005.
For instance, if you apply an incrementing factor of 0.020 and find the best corners were 20 mm then you’ll need to enter 0 + 20.0 * 0.020, and you will get a Pressure Advance value of 0.4.
4. Set the Value in Klipper
After doing the calculation, you’ll be able to change the value in the Klipper configuration file section. Go to the Klipper configuration section, found on the top bar, and open the printer.cfg file.
That’s the configuration file, there’s an extruder section where you will add the input “pressure_advance = pa value” at the end of it.
If we used the previous example, the entry would look like this: “advance_pressure = 0.4”
After inputting the value, you’ll just need to restart your firmware so that the function is enabled correctly. To restart Klipper just go to the option “Save and Restart” in the right upper corner.
Users recommend using Pressure Advance in Klipper as you can optimize the settings in a way that will really improve your prints.
One user got to print a nice 3D Benchy in just 12 minutes while experimenting with different configurations of Pressure Advance in Klipper.
Check out the video below to see more information on using Pressure Advance on Klipper.
How to Use Linear Advance on Ender 3
If you own an Ender 3, you’ll also be able to use linear advance but be aware that you may need to upgrade your motherboard to do so.
That’s because the Creality motherboard version 4.2.2 and inferior has drivers being hard-wired into legacy mode, as stated by one user.
He stated the function will work great on motherboards 4.2.7 and any newer model. That’s the case for the Official Creality 3D Printer Ender 3 Upgraded Silent Board Motherboard V4.2.7 which you can find available at Amazon.
Users recommend this motherboard as it is silent and made of high-quality materials, making it a worthwhile upgrade to the Ender 3.
Besides checking the motherboard versions, there are no concerns about using linear advance on the Ender 3 and you can enable it via Marlin, Cura, or Klipper.
You can check the previous sections for information on how to enable linear advance using your preferred firmware.
How to Use Linear Advance on Direct Drive
Direct drive machines can use linear advance, although Bowden-type setups benefit the most from it.
Having a direct drive 3D printer means your printer is using a direct extrusion system that pushes the filament into the hot end by mounting the extruder on the print head.
That’s different from a Bowden system, which often has the extruder located on the printer’s frame. To get to the printer, the filament then passes via a PTFE tube.
One user with a direct drive setup enabled linear advance but could not see much improvement from it.
Other users think using linear advance will really improve any printer with a Bowden setup while not being entirely critical to people who are using printers with direct drive.
Another user recommends starting with a K-value of 0.0 and increasing incrementally by 0.1 to 1.5 if you own a direct drive printer. He has never gone past 0.17 with his K-value and he only got that high when printing with nylon.
It’s important to have the Linear Advance defined in your firmware as previously mentioned, when you remove the “//” text as one user figured out.
Here are his results from doing a test, where he picked 0.8 as the ideal value.
Best Linear Advance Test Prints
Enabling linear advance usually requires that a few test prints are made. Users created different models that can help you with those tests. With these test prints, you’ll be able to find the optimal linear advance value a lot easier as they are made with that function in mind.
It will also help you determine how sluggish your filaments are behaving with linear advance enabled. Some of the test models below can also help you tune in other helpful settings.
Here are some of the best linear advance test prints you can find on Thingiverse: