Linear Advance

I’ve seen some mention of linear advance around the forums, but when I tried tuning with the Marlin K-factor calibration pattern, all the test lines looked identical on firmware from Lulzbot Cura 2.6.63.

Does anybody know why linear advance has been disabled in this firmware? I’ve seen reports of people using it on these forums going back to May 2017 and was surprised to see the latest firmware does not support M900 K_.

This is a choice Lulzbot is making. I dont know the reasons behind their decision. Maybe they will read your post and address the reasons behind their decision. Any1 who was using it on a Lulzbot had it on a beta firmware that had it activated while they were testing it.

I can tell you that Prusa has activated the feature in their firmware for MK2s and the MK3. All you have to do is select the linear advance profile in sli3er. (100 ms speed) its awesome to watch. In the MK3 video’s with Joe Prusa at the New York maker fair he says MK3 can go 200ms (are you serious). You’ll let you know when they sort out their metal pei sheet issues and I get mine.
I have two other printers (CR10 S4, 3ku Delta) that I control and upgrade the firmware myself. On those printers I have activated the feature. Its not simply turn it on and go. It has to tuned/calibrated to find best K factor for your printer setup. This involves printing out the test lines as you noted above.

For my Delta printer I used this thingiverse square:

But once a good K factor is found you:
Lower retraction distance necessary
No wipe or coast needed
Seams not as visible
Sharper corners resulting in greater dimensional accuracy
No over extrusion at the edges of solid infill
Much faster print speeds are possible with no negative effect on quality

Marlin guys are even working on Linear Advance v2:
good read.

Yeah, I’ve had a Prusa mk3 for a few weeks, and it’s amazing how much linear advance can improve prints. A big reason the smaller printers are able to go so fast is simply lower inertia of their lighter components. I’ve got a pair of TAZ 6 and appreciate their larger capacity and modular design for when we decide to buy a Moarstruder and dual head. I hope linear advance can be enabled in the standard Lulzbot firmware.

Have 4 printers, so i decided to wait for metal pei sheet.

But Big printers can benefit from linear advance also. Matter of fact my CR10s4 - 400mm x 400mm x 400mm with a bowden extruder and a heavy print bed plugs it off. But finding a good K factor takes longer.
For my Taz6’s sake I wish Lulzbot would revisit Linear Advance.

Due to the higher inertia of the larger printer, I expect linear advance will have an even greater affect. Smaller, lighter printers are able to mask the problems of extrusion pressure with higher acceleration and jerk settings.

I discussed this with Marcio while debugging the new Mini firmware and the answer was simple: “Test, test, test, test, time”. My reply that K0 would turn off Lin Advance for those not interested was that that wasn’t tested (enough) :wink:

I’ve used Lin Advance ever since I built Mini firmware myself and am quite happy with it, and yesterday I enabled FW Retract.

I’m happy with the current firmware aside from this. Would it be possible to get a beta release with linear advance enabled?

@mrvanes - Since activating this is just uncommenting one line and compiling… I have to try it. What is a good starting K-factor for the Mini?

Best course is to run the test linked in OP.

Since there is very little difference in parts, performance, settings across Minis – I think I’ll start with what mrvanes has found to work, if it is all the same to you. No reason to re-invent the wheel. :slight_smile:

I suspect there is enough deviation between filament and other factors to warrant running the calibration cycle. By all means, feel free to test his value first, but it will likely take less time to use the linked code generator and run the calibration cycle than it will to compile and flash the firmware. Considering this will test a number of different K factors and allow you to easily identify the correct value for your specific printer and filament, my recommendation is to give it a shot.

Whatever you choose, I wish you luck and hope you will respond with your findings.

Maybe… But I intend to flash the firmware with K=0, then add K-factors into start scripts (I have different start scripts for each filament). Other than filament, there should be negligible (if any) difference between two Mini’s of the same model and speed/accel settings. So if someone else has worked out the numbers for common filaments on the Mini, I’ll start there instead of printing a bunch of calibration patterns.

Question – Why haven’t you built/flashed the Lulzbot firmware with Lin_Advance on?

So I went ahead and built the firmware with Lin_Advance enabled, and default K=0. Loaded some PETG and ran the calibration test – best lines looked like K70 or K75.

Ran a print of a 20mm cube with XYZ on faces, leaving K=0. Then inserted a “M900 K75” into the code and ran it again (same code, only difference the K value). I could definitely see (and hear) the Lin-Advance working by watching the extruder gears – sort of like lots of tiny retractions.

But I’m hard pressed to find any difference between the two prints. The K75 cube has a couple of very tiny voids at end of infill on top surface, but that could probably be resolved by increasing the extrusion rate slightly (I normally run PETG at 96%, but that decrease may not be necessary with Lin-Advance active). Otherwise, the two cubes appear identical.

Just to make sure the Lin_advance wasn’t having any effect with K=0, I reflashed to stock firmware ( and printed again. Now comparing “Lin_Advance disabled”, “Lin_Advance enabled with K=0”, and “Lin_advance enabled with K=75”. Other than that minor void on top infill of the one with K75, there is no detectable difference.

Are there certain types of parts/features or materials that would show more effect from Lin-Advance? Or maybe running at higher speed (my default speed for PETG is 45mm/s)? Or perhaps something larger than 20x20x20 would exercise it more?

I see you’ve already ran the calibration, Scott. For the benefit of those who don’t know, the test is a single ~5 minute print which changes the K factor repeatedly. You print it once and decide which number looks best. Boom. Done.

Fair question. I’ll probably do it at some point. Maybe.

Unfortunately, I only have a small amount of room available for 3d printing at home. Once the Prusa mk3 arrived, I took my TAZ 6 to work. We already have another TAZ 6 there, but 3d printing is a sideline thing for us. We do CNC machine stuff to pay the bills. It’ll probably come down to whether Lulzbot decides to enable linear advance. Maybe they have a good reason for leaving it off. I’ve already began to see a bit of green dust from the herringbone gears wearing. Maybe the standard extruder just isn’t up to it or something. Whatever.

According to the Marlin documentation, it’s important to disable the traditional means of accommodating for extrusion pressure.

Setting the K-Factor for production
Considerations before using Linear Advance

  • Some slicers have options to control the nozzle pressure. Common names are: Pressure advance, Coast at end, extra restart length after retract. Disable these options as they will interfere with Linear Advance.

  • Also disable options like wipe while retract or combing. There should be almost no ooze, once the proper K-Factor is found.

  • Recheck retraction distance, once Linear Advance is calibrated and working well. It may even be as low as 0, since pressure control reduces the material pressure at the end of a line to nearly zero.

  • Theoretically there should be no “extra” movements produced by LIN_ADVANCE. If extra movements were produced, this would tend to increase wear on more fragile parts such as the printed gears of a Wade extruder.

My only experience with this feature is the documentation and its implementation on the Prusa mk3. For what little it’s worth, their PETG profile is using M900 K45. They are using M900 K30 for PLA.

The 90° corners of your calibration cube should be more crisp. I don’t think your speed is wrong, but it might be possible to increase speed further. You have a good point that the size of the calibration cube may not be enough to get up to speed or something. Maybe try printing a long narrow test piece.

Sorry for late reaction, was busy last days. I never did the calibration pattern (only recently learned about them) but searched for rough K factors for my materials and I came up with these numbers: ABS: K25, HIPS: K25, PETG: K45, PLA: K75. Very curious what the pattern tests will bring for my Mini!

update: first PLA test shows best for K50 and it’s quite apparent!

Not quite. It needs to be run multiple times, once for each filament type (and layer height?). And with firmware 1.1.5.xx, particularly on Mini 1.03 or earlier, the generated test script needs to be hand-edited to avoid problems introduced with 1.1.5.xx – otherwise, depending on the size of pattern selected, the generated script may print above the bed or crash into endstops.

This brings up something else, which is start gcode management. Cura 2.6 unifies the start gcode per printer, and there is no placeholder variable for K-factor. That means if using (for example) 6 different filaments that need different K-factors, then 6 “copies” of each printer need to be installed in Cura 2.6 so there can different start scripts (with different K-factor) for each filament. (Note: If Lulzbot proceeds with enabling Lin-Advance in firmware, they could easily add K-factor to the filament/quality settings, and use the placeholder variable to allow one unified script again.)

Already read that. All of those options were disabled before slicing.

I have to disagree somewhat with the “no extra movement” part of that. It is apparent, just from watching the extruder gears, that there is a LOT of extra acceleration/deceleration, even if it doesn’t result in more actual movement. Its visible and to some degree audible. If need for retraction is lessened, that would compensate for some of it I guess.

Not seeing it. I looked at the test cubes again this morning, with and without magnification, and can’t see any difference in the corners, or in the “lettering” on the sides (lots of direction changes there).

Agree – It may be that the short 20mm sides (which also have breaks for the lettering) just don’t give the toolhead time to accelelerate to a speed where LA really becomes beneficial. I’ll have to try a larger test when I get time… I have an Aerostruder coming today (should have been here yesterday, no-thanks-to-usps) – so also curious how LA will differ with it compared to the gearing and longer filament path of the Wade.

Does layer height affect the calibration and K-factor? I suspect it does, since layer height affects volume, but haven’t tested. I used 0.25 for the calibration test I did – what layer height did you use?

I (only) used the default 0.2 and only PLA for now, but it clearly shows the thickening high-speed part towards the higher end of K. Will extend tests as time allows. And as for the seperate K factors per filament: just leave Cura for what it is and join the Slic3r camp :smiley:. Once switched I never looked back. And yes it has it’s (support) quircks, but the preview pane and generated gcode make up for every nook and cranny IMVHO.

Ha… I may end up there. I do have Slic3r PE installed, have tested it a little but haven’t spent the time to really dial it in or create profiles for everything. I mainly use S3D and generally like it better than Cura or Cura2, particularly the profile management, support options, and bridging parameters – but there are also a few things Cura seems to do better. I still have high hopes for Cura2, and want it to work well due to the AlephObjects support, but have so far been disappointed with the number of bugs/problems I experienced with it.

In Slic3r, where do you embed the K-factor? Do you just add a M900 in “filament settings, custom g-code”, or is there some other spot specifically for K-factor?

Exactly there.