#I tried adding this macro to my printer cfg but now I get this error

37 messages · Page 1 of 1 (latest)

thorny ridge
#

[gcode_macro LOAD_FILAMENT]
default_parameter_SPEED: 400 <---- Im not very familliar with klipper what do I have to change here to fix the error
default_parameter_PRIME_SPEED: 300
gcode:
SAVE_GCODE_STATE NAME=__filament__load
M83
G1 E5 F75
G1 E50 F{SPEED}
G1 E35 F{SPEED}
G1 E20 F{PRIME_SPEED}
G1 E-1 F{SPEED}

signal foxBOT
#

Ahoi @thorny ridge!
It looks like you did not provide all the necessary information we need to help you.
Please upload your logfiles and a detailed description of your problem.
For further information see: https://docs.mainsail.xyz/faq/getting-help/discord#provide-information
Note: We only accept .log and .txt files as log files.
This is an automated message

We are glad to help and chat with you on our Community Discord, but if you need help and want the best support possible you should, follow a few simple rules:

remote trail
#

Where did you copy the macro from?

thorny ridge
#

a random github

#

what would you suggest I do instead?

remote trail
#

write your own macro or/and dont copy macros from random (outdated) github repos...

#

how familiar are you with gcode in general?

thorny ridge
#

not very

#

I will try to find a more up to date macro thankyou

#

for now I just replaced all the spots where it calls for the varible with a regular number

remote trail
#
[gcode_macro LOAD_FILAMENT]
gcode:
  M83
  G1 E5 F75
  G1 E50 F400
  G1 E35 F400
  G1 E20 F300
  G1 E-1 F400
#

you can also remove the SAVE_GCODE_STATE. its not needed here

#

you can also move the filament faster instead of 400, in the area where your filament will not be pressed threw your nozzle. the 300 part is your purge part. this should be flow. but you have to change the lengh of the first gcodes where it is "loose" in your toolhead (the length between our gears and your nozzle)

thorny ridge
#

in my testing 400 seems fast enough

#

can I ask you an unrealted question?

#

Im tuning presure advance

#

and im using the equation provided pressure_advance = <start> + <measured_height> * <factor>

#

is <factor> my layer hight?

#

b/c the measured hight would change based on that

remote trail
#

for example this command:

#
TUNING_TOWER COMMAND=SET_PRESSURE_ADVANCE PARAMETER=ADVANCE START=0 FACTOR=.005
thorny ridge
#

cool

remote trail
#

the last value "FACTOR" is the the factor you need in the calculation

thorny ridge
#

do I have to figure out what layer Im measuring

#

b/c how does it know what setting it was at for a given hight

remote trail
#

just mesure the height with a ruler

remote trail
#

just mesure the height and fill in all values, then you get the value from the special layer/height of your print

thorny ridge
#

I trust you but how does it know what layer im looking at based on the mesured hight

#

for example i measured 10.17 mm at 0.3 mm layer hight but that would be a completely diffrent layer at 0.2mm layer hight

remote trail
#

the temp tower (the command above) works in mm and not in layer. klipper dont know the layer. only the height

#

(every time z_height and now layer count)

thorny ridge
#

oh ok