Linear Advance - is there a problem with the custom code?
 
Notifications
Clear all

[Solved] Linear Advance - is there a problem with the custom code?  

  RSS
OLLE3770
(@olle3770)
New Member
Linear Advance - is there a problem with the custom code?

This code from the Custom G-code in Filament Settings:

M900 K{if printer_notes=~/.*PRINTER_MODEL_MINI.*/ and nozzle_diameter[0]==0.6}0.12{elsif printer_notes=~/.*PRINTER_MODEL_MINI.*/}0.2{elsif nozzle_diameter[0]==0.6}0.04{else}0.05{endif} ; Filament gcode LA 1.5
{if printer_notes=~/.*PRINTER_MODEL_MINI.*/};{elsif printer_notes=~/.*PRINTER_HAS_BOWDEN.*/}M900 K200{elsif nozzle_diameter[0]==0.6}M900 K18{else}M900 K30{endif} ; Filament gcode LA 1.0

Always generates this gcode:

M900 K0.05 ; Filament gcode LA 1.5
M900 K30 ; Filament gcode LA 1.0

First one sets code for LA 1.5, then it resets to LA 1.0??

Is it supposed to be like this?

This topic was modified 4 years ago by OLLE3770
Posted : 13/10/2020 11:11 am
JoanTabb
(@joantabb)
Veteran Member Moderator
RE: Linear Advance - is there a problem with the custom code?

at a guess, I would suspect that LA 1.5 ignores massive K values, and LA 1.0 ignores miniscule values...

but that could be wrong...   I haven't updated to 3.9.1 firmware yet...

regards Joan

I try to make safe suggestions,You should understand the context and ensure you are happy that they are safe before attempting to apply my suggestions, what you do, is YOUR responsibility. Location Halifax UK

Posted : 13/10/2020 11:18 am
OLLE3770 liked
OLLE3770
(@olle3770)
New Member
Topic starter answered:
RE: Linear Advance - is there a problem with the custom code?

Thanks for the answer. It says in the manual that La 1.5 should be enabled by default (by the custom gcode from the pre-defined filament settings) but all my gcode that's been sliced have these two conflicting lines. Obviously my printer qualifies for LA 1.5 according to the first line of the (default supplied code from Prusa) but then it doesn't qualify by the second line (also default supplied from Prusa). Is this an error or am I missing something?

Posted : 13/10/2020 11:32 am
bobstro
(@bobstro)
Illustrious Member
RE: Linear Advance - is there a problem with the custom code?

IIRC, if a LA1.5 value is specified, it will be used. If a LA1.0 value is specified, it will automatically be converted by firmware on the printer. If both are specified, the more specific LA1.5 value will be used.

My notes and disclaimers on 3D printing

and miscellaneous other tech projects
He is intelligent, but not experienced. His pattern indicates two dimensional thinking. -- Spock in Star Trek: The Wrath of Khan

Posted : 13/10/2020 2:29 pm
OLLE3770 liked
Friedhelm B.
(@friedhelm-b)
Eminent Member
RE: Linear Advance - is there a problem with the custom code?
Posted by: @bobstro

IIRC, if a LA1.5 value is specified, it will be used. If a LA1.0 value is specified, it will automatically be converted by firmware on the printer. If both are specified, the more specific LA1.5 value will be used.

 

correct. See here. If you want to dive in like an expert (and screw things up), print this and adjust the LA-Value per filament. For example, my Start Gcode for Extrudr ASA looks like this:

M900 K0.04; Filament gcode LA 1.5 for ASA Extrudr 0.4mm Nozzle, calibrated 20201009 

Or you can go directly to marlin and generate the gcode for LA-calibration.

Posted : 13/10/2020 2:44 pm
OLLE3770 and bobstro liked
OLLE3770
(@olle3770)
New Member
Topic starter answered:
RE: Linear Advance - is there a problem with the custom code?

Thanks all

Matter resolved. I guess you sort of need a "backup-value" in the gcode to not screw things up on older firmware. Didn't think about that. Great to get fast answers that makes sense. Glad I bought a Prusa.

Posted : 13/10/2020 4:29 pm
Share: