Skip to content

Commit ebacc39

Browse files
authored
Release v1.0.35
Release v1.0.35, merging DEV into main
2 parents 2f5855c + 5323611 commit ebacc39

31 files changed

Lines changed: 1579 additions & 440 deletions

CHANGELOG.md

Lines changed: 100 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,105 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [2026-01-22]
9+
### Changed:
10+
- The install-afc.sh script will now allow users to install as root if it detects the user is running a SAF K1 environment.
11+
12+
## [2026-01-15]
13+
### Added:
14+
- The afc-debug.sh script will now upload the AFC statistics from moonraker for easier troubleshooting.
15+
16+
## Fixed
17+
- Updates to help with false clog/feed detections
18+
- Resetting filament position for clog detection when starting a new print
19+
20+
## [2026-01-14]
21+
### Fix:
22+
- Implemented some fixes to prevent klipper crashing when calibrating HTLF units
23+
24+
## [2026-01-12]
25+
### Added:
26+
- Added debugging messages when doing unloading filament from toolhead for tool_stn_unload movements
27+
28+
## [2026-01-10]
29+
### Added:
30+
- Check to verify user's macros positions are set correctly and not left as default values. Changed default values to -99,-99 etc, just in case someone does truly have their positions at -1,-1.
31+
32+
## [2026-01-09]
33+
### Changed:
34+
- Restructured how extruder load/unload counts are stored in moonraker database to work better for toolchangers.
35+
- Added ability to track cuts per toolhead for toolchangers.
36+
- Changed how average times are calculated. Use `AFC_RESET_STATS EXTRUDER=all` to use new `total_time/count` calculation.
37+
- Merged normal and skinny AFC_STATS printout into one function and changed printout format to work better with toolchangers.
38+
39+
## [2025-12-26]
40+
### Changed:
41+
- Updated AFC_CUT macro to move to pin first before doing filament retraction.
42+
- Updated AFC_CUT macro so that is more safe for toolheads with cutters that move in the forwards/backwards movement.
43+
- Updated AFC_CUT macro to clear pin once cutting is done so that is safer for toolheads with forward/backward cutters.
44+
45+
## [2025-12-18]
46+
### Fixed
47+
- Fixing issue where order mattered when creating flat config files, replaced lookup_object with load_object so klipper would not error out and instead load object if it was not already loaded.
48+
49+
## [2025-12-17]
50+
### Fixed
51+
- Fixed issue where AFC would crash klipper when trying to find git version when git folder does not exist
52+
- Fixed issue where AFC would cause error if log file variable was not passed into klipper service
53+
54+
## [2025-12-11]
55+
### Fixed
56+
- Fix output of `AFC_TOGGLE_MACRO` to correctly report state of WIPE macro
57+
58+
## [2025-12-07]
59+
### Added
60+
- Updated spool assist cruise time calculations to be more linear with spool weight
61+
62+
## [2025-12-06]
63+
### Fixed
64+
- Fixes issue where klipper would crash for HTLF units when homing and moving lanes during prep
65+
866
## [2025-12-03]
9-
### Fixes
67+
### Fixed
68+
- Fixes bug where print current is not correctly set back to correct value after using LANE_MOVE macro.
1069
- Fixed a bug when installing a HTLF, all MCU definition files would be copied over instead of just the selected board type.
1170

71+
## [2025-11-26]
72+
### Added
73+
- Added `spool_id` field to `lane_data` namespace for Spoolman integration (#575)
74+
75+
## [2025-11-25]
76+
### Added
77+
- **Buffer Fault Detection System**: New filament fault detection feature for AFC buffers to detect clogs, and feeding issues.
78+
- Monitors extruder position and buffer state changes to detect abnormal conditions
79+
- Configurable sensitivity (0-10 scale, where 0 disables, 1 is least sensitive, 10 is most sensitive)
80+
- Automatically pauses print and provides diagnostic messages when faults are detected
81+
- Distinguishes between clog detection (buffer advancing/expanding state) and AFC feeding issues (buffer trailing/compressing state)
82+
- Timer-based monitoring with configurable CHECK_RUNOUT_TIMEOUT (0.5s default)
83+
- **New Command: `SET_ERROR_SENSITIVITY`**: Allows dynamic adjustment of fault detection sensitivity during runtime without restarting Klipper
84+
- Supports values 0-10 (0 disables fault detection, 1 least sensitive/100mm, 10 most sensitive/10mm)
85+
- Automatically enables/disables fault detection timers based on sensitivity changes
86+
- Usage: `SET_ERROR_SENSITIVITY BUFFER=<buffer_name> SENSITIVITY=<0-10>`
87+
- Enhanced `QUERY_BUFFER` command to report fault detection status and current sensitivity level
88+
89+
### Changed
90+
- Reversed buffer fault detection sensitivity scale: sensitivity value of 1 is now the least sensitive (100mm fault distance) and 10 is now the most sensitive (10mm fault distance). This makes the scale more intuitive where higher numbers mean more sensitive detection
91+
- Buffer callbacks (`advance_callback` and `trailing_callback`) now integrate with fault detection system
92+
- When fault detection is enabled during printing, buffer automatically adjusts monitoring with extra-low/extra-high multipliers
93+
- Stops fault timer when buffer is not actively engaged
94+
- Buffer enable/disable now properly manages fault detection timers to prevent false positives
95+
96+
### Fixed
97+
- Buffer fault detection now respects the `enable` state and only triggers during active printing with movement
98+
99+
## [2025-11-14]
100+
### Update
101+
- Changed unload order for infinite spool to prevent excess nozzle oozing when ejecting spool. New unload order is: Unload Tool->Eject Spool->Load rollover lane
102+
103+
## [2025-11-09]
104+
### Fixes
105+
- Fixes an issue where spoolman was not updating a loaded spool in toolhead
106+
12107
## [2025-11-04]
13108
### Changed
14109
- Updated error message when using the SET_LANE_LOADED command to be more descriptive.
@@ -17,6 +112,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
17112
### Fixes
18113
- Clarified fix message if during AFC calibration, the filament fails to reach to hub sensor.
19114

115+
## [2025-11-02]
116+
### Changed
117+
- Consolidated all variables for the `POOP` macro to be in the `AFC_Macro_Vars.cfg` file instead of being split in two places.
118+
20119
## [2025-11-01]
21120
### Changed
22121
- Removed code for Belay.

config/AFC_Macro_Vars.cfg

Lines changed: 18 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ gcode: # Leave empty
2929

3030
# This should be the position of the toolhead where the cutter arm just
3131
# lightly touches the depressor pin
32-
variable_pin_loc_xy : -1, -1 # x,y coordinates of depressor pin
32+
variable_pin_loc_xy : -99, -99 # x,y coordinates of depressor pin
3333

3434
# Accel during cut. This will overwrite the global accel for this macro. Set to 0 to use global accel
3535
variable_cut_accel : 0
@@ -90,7 +90,7 @@ variable_pushback_dwell_time : 20 # Time to dwell between the pushba
9090
# we make a safer but longer move if we are closer to the pin than this
9191
# specified margin. Usually setting these to the size of the toolhead
9292
# (plus a small margin) should be good enough
93-
variable_safe_margin_xy : 30, 30 # Approx toolhead width +5mm, height +5mm)
93+
variable_safe_margin_xy : 60, 60
9494

9595
# Some printers may need a boost of power to complete the cut without skipping steps.
9696
# One option is to increase the current for the steppers in printer.cfg. Another
@@ -126,7 +126,7 @@ description: Poop macro configuration variables
126126
gcode: # Leave empty
127127

128128

129-
variable_purge_loc_xy : -1, -1 # (x,y) Location of where to purge
129+
variable_purge_loc_xy : -99, -99 # (x,y) Location of where to purge
130130
variable_purge_spd : 6.5 # Speed, in mm/s, of the purge.
131131
variable_z_purge_move : True # Set to False to not move in Z during poop
132132

@@ -171,6 +171,18 @@ variable_purge_length_minimum : 60.999
171171
# forget to increase the purge_length_modifier
172172
#variable_purge_length_addition : 0
173173

174+
# Advanced settings for the poop macro
175+
# Max amount of filament to purge for each purge step
176+
variable_max_iteration_length: 40
177+
# Z amount to raise during a purge step
178+
variable_iteration_z_raise: 6
179+
# Z amount to raise between each purge step
180+
variable_iteration_z_change: 0.6
181+
# Max number of steps when forming a poop/blob
182+
variable_max_iterations_per_blob: 3
183+
# Base Z height
184+
variable_purge_z: 0
185+
174186

175187
#--=================================================================================-
176188
#------- Kick ----------------------------------------------------------------------
@@ -179,7 +191,7 @@ variable_purge_length_minimum : 60.999
179191
description: Kick macro configuration variables
180192
gcode: # Leave empty
181193

182-
variable_kick_start_loc : -1,-1,5 # Location to move before kick
194+
variable_kick_start_loc : -99,-99,5 # Location to move before kick
183195
variable_kick_z : 1.5 # Height to drop to for kick move
184196
variable_kick_speed : 150 # Speed of kick movement
185197
variable_kick_accel : 0 # Accel of kick moves. This will overwrite the global accel for this macro. Set to 0 to use global accel
@@ -196,7 +208,7 @@ description: Brush macro configuration variables
196208
gcode: # Leave empty
197209

198210

199-
variable_brush_loc : -1,-1,-1 # Position of the center of the brush (Set z to -1 if you dont want a z move)
211+
variable_brush_loc : -99,-99,-1 # Position of the center of the brush (Set z to -1 if you dont want a z move)
200212
variable_brush_clean_speed : 150 # Speed of cleaning moves when brushing
201213
# Accel of cleaning moves when brushing. This will overwrite the global accel for this macro. Set to 0 to use global accel
202214
variable_brush_clean_accel : 0
@@ -222,7 +234,7 @@ variable_z_move : -1
222234
description: Park macro configuration variables
223235
gcode: # Leave empty
224236

225-
variable_park_loc_xy : -1, -1 # Position to park the toolhead
237+
variable_park_loc_xy : -99, -99 # Position to park the toolhead
226238
# If you want z_hop during toolchanges please set the value in the AFC.cfg
227239
variable_z_hop : 0 # Height to raise Z when moving to park. Leave 0 to disable
228240
variable_park_z : 0 # Absolute height to lower to after park move. Leave 0 to disable

config/macros/Brush.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,7 @@ gcode:
144144
SET_VELOCITY_LIMIT ACCEL={saved_accel}
145145

146146
AFC_ENABLE_SKEW
147+
M400
147148

148149
#--=================================================================================-
149150
#------- Helper macro for brush servo -----------------------------------------------

config/macros/Cut.cfg

Lines changed: 82 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,11 @@ gcode:
7575

7676
AFC_DISABLE_SKEW
7777

78+
G90 # Absolute positioning
79+
M83 # Relative extrusion
80+
G92 E0
81+
_MOVE_TO_CUTTER_PIN PIN_PARK_X_LOC={pin_park_x_loc} PIN_PARK_Y_LOC={pin_park_y_loc}
82+
7883
G90 # Absolute positioning
7984
M83 # Relative extrusion
8085
G92 E0
@@ -100,8 +105,6 @@ gcode:
100105
{% if verbose > 1 %}
101106
RESPOND TYPE=command MSG='AFC_Cut: Move to Cut Pin Location'
102107
{% endif %}
103-
_MOVE_TO_CUTTER_PIN PIN_PARK_X_LOC={pin_park_x_loc} PIN_PARK_Y_LOC={pin_park_y_loc}
104-
105108
# Extend servo if enabled
106109
{% if tool_servo_enable %}
107110
{% if verbose > 1 %}
@@ -226,7 +229,7 @@ gcode:
226229

227230
# Reset acceleration values to what it was before
228231
SET_VELOCITY_LIMIT ACCEL={saved_accel}
229-
232+
_CLEAR_PIN PIN_PARK_X_LOC={pin_park_x_loc} PIN_PARK_Y_LOC={pin_park_y_loc}
230233
AFC_ENABLE_SKEW
231234

232235
# Restore state and optionally position
@@ -245,24 +248,38 @@ gcode:
245248
{% set travel_speed = gVars['travel_speed'] * 60|float %}
246249
{% set vars = printer['gcode_macro _AFC_CUT_TIP_VARS'] %}
247250
{% set cut_direction = vars['cut_direction']|default('')|lower %}
251+
{% set act_x = printer.toolhead.position.x|float %}
252+
{% set act_y = printer.toolhead.position.y|float %}
253+
{% set max_x = printer.toolhead.axis_maximum.x|float %}
254+
{% set max_y = printer.toolhead.axis_maximum.y|float %}
248255
{% set safe_margin_x, safe_margin_y = vars.safe_margin_xy|map('float') %}
256+
{% set verbose = gVars['verbose'] |default(1) | int %}
249257

250-
{% if ((printer.gcode_move.gcode_position.x - pin_park_x_loc)|abs < safe_margin_x) or ((printer.gcode_move.gcode_position.y - pin_park_y_loc)|abs < safe_margin_y) %}
251-
# Make a safe but slower travel move
252-
{% if cut_direction == "left" or cut_direction == "right" %}
253-
G1 X{pin_park_x_loc} F{travel_speed}
254-
G1 Y{pin_park_y_loc} F{travel_speed}
255-
{% elif cut_direction == "front" or cut_direction == "back" %}
256-
G1 Y{pin_park_y_loc} F{travel_speed}
257-
G1 X{pin_park_x_loc} F{travel_speed}
258-
{% else %}
259-
{ action_raise_error("Invalid cut direction. Check the cut_direction in your AFC_Macro_Vars.cfg file!") }
258+
# Make traveling to cutter pin safer overall
259+
{% if cut_direction == "front" or cut_direction == "back" or cut_direction == "left" or cut_direction == "right"%}
260+
{% if verbose > 1 %}
261+
RESPOND TYPE=command MSG='AFC_Cut: Moving to cutter pin'
262+
{% endif %}
263+
#assume left side pin
264+
{% if (pin_park_x_loc) < (max_x/2) %}
265+
{% if act_x <= safe_margin_x+pin_park_x_loc %}
266+
G1 X{safe_margin_x+pin_park_x_loc} Y{pin_park_y_loc} F{travel_speed}
267+
G1 X{pin_park_x_loc} F{travel_speed}
268+
{% else %}
269+
G1 X{pin_park_x_loc} Y{pin_park_y_loc} F{travel_speed}
270+
{% endif %}
271+
#assume right side pin
272+
{% elif (pin_park_x_loc) > (max_x/2) %}
273+
{% if act_x >= pin_park_x_loc-safe_margin_x %}
274+
G1 X{pin_park_x_loc-safe_margin_x} Y{pin_park_y_loc} F{travel_speed}
275+
G1 X{pin_park_x_loc} F{travel_speed}
276+
{% else %}
277+
G1 X{pin_park_x_loc} Y{pin_park_y_loc} F{travel_speed}
278+
{% endif %}
260279
{% endif %}
261280
{% else %}
262-
G1 X{pin_park_x_loc} Y{pin_park_y_loc} F{travel_speed}
281+
{ action_raise_error("Invalid cut direction. Check the cut_direction in your AFC_Macro_Vars.cfg file!") }
263282
{% endif %}
264-
265-
266283
#--=================================================================================-
267284
#------- Helper macro for tip cutting -----------------------------------------------
268285
#--=================================================================================-
@@ -321,14 +338,14 @@ gcode:
321338
{% if full_cut_loc_x > x_max or full_cut_loc_x < x_min %}
322339
{ action_raise_error("X Cut move is outside your printer bounds. Check the cut_move_dist in your AFC_Macro_Vars.cfg file!") }
323340
{% else %}
324-
G1 X{fast_slow_transition_loc_x} F{cut_fast_move_speed} # Fast move to initiate contact of the blade with filament
325-
G1 X{full_cut_loc_x} F{cut_slow_move_speed} # Do the cut in slow move
326-
G4 P{cut_dwell_time}
327-
{% if rip_length > 0 %}
328-
G1 E-{rip_length} F{rip_speed}
329-
{% endif %}
341+
G1 X{fast_slow_transition_loc_x} F{cut_fast_move_speed} # Fast move to initiate contact of the blade with filament
342+
G1 X{full_cut_loc_x} F{cut_slow_move_speed} # Do the cut in slow move
343+
G4 P{cut_dwell_time}
344+
{% if rip_length > 0 %}
345+
G1 E-{rip_length} F{rip_speed}
346+
{% endif %}
330347
G4 P200
331-
G1 X{pin_park_x_loc} F{evacuate_speed} # Evacuate
348+
G1 X{pin_park_x_loc} F{evacuate_speed} # Evacuate
332349
G4 P200
333350
{% endif %}
334351
{% elif cut_direction == "front" or cut_direction == "back" %}
@@ -338,14 +355,14 @@ gcode:
338355
{% if full_cut_loc_y > y_max or full_cut_loc_y < y_min %}
339356
{ action_raise_error("Y Cut move is outside your printer bounds. Check the cut_move_dist in your AFC_Macro_Vars.cfg file!") }
340357
{% else %}
341-
G1 Y{fast_slow_transition_loc_y} F{cut_fast_move_speed} # Fast move to initiate contact of the blade with filament
342-
G1 Y{full_cut_loc_y} F{cut_slow_move_speed} # Do the cut in slow move
343-
G4 P{cut_dwell_time}
344-
{% if rip_length > 0 %}
345-
G1 E-{rip_length} F{rip_speed}
346-
{% endif %}
358+
G1 Y{fast_slow_transition_loc_y} F{cut_fast_move_speed} # Fast move to initiate contact of the blade with filament
359+
G1 Y{full_cut_loc_y} F{cut_slow_move_speed} # Do the cut in slow move
360+
G4 P{cut_dwell_time}
361+
{% if rip_length > 0 %}
362+
G1 E-{rip_length} F{rip_speed}
363+
{% endif %}
347364
G4 P200
348-
G1 Y{pin_park_y_loc} F{evacuate_speed} # Evacuate
365+
G1 Y{pin_park_y_loc} F{evacuate_speed} # Evacuate
349366
G4 P200
350367
{% endif %}
351368
{% else %}
@@ -371,3 +388,38 @@ gcode:
371388
{action_respond_info("Cutter Servo: provide POS=[in|out]")}
372389
{% endif %}
373390
SET_SERVO SERVO={c1.tool_servo_name} WIDTH=0
391+
392+
#--=================================================================================-
393+
#------- Helper macro for tip cutting -----------------------------------------------
394+
#--=================================================================================-
395+
[gcode_macro _CLEAR_PIN]
396+
description: Helper to move the toolhead to the target pin in either safe or faster way, depending on toolhead clearance
397+
gcode:
398+
{% set pin_park_x_loc = params.PIN_PARK_X_LOC|float %}
399+
{% set pin_park_y_loc = params.PIN_PARK_Y_LOC|float %}
400+
{% set gVars = printer['gcode_macro _AFC_GLOBAL_VARS'] %}
401+
{% set travel_speed = gVars['travel_speed'] * 60|float %}
402+
{% set vars = printer['gcode_macro _AFC_CUT_TIP_VARS'] %}
403+
{% set cut_direction = vars['cut_direction']|default('')|lower %}
404+
{% set act_x = printer.toolhead.position.x|float %}
405+
{% set act_y = printer.toolhead.position.y|float %}
406+
{% set max_x = printer.toolhead.axis_maximum.x|float %}
407+
{% set max_y = printer.toolhead.axis_maximum.y|float %}
408+
{% set safe_margin_x, safe_margin_y = vars.safe_margin_xy|map('float') %}
409+
{% set verbose = gVars['verbose'] |default(1) | int %}
410+
411+
# Make moving away from cutter pin safer overall
412+
{% if cut_direction == "front" or cut_direction == "back" or cut_direction == "left" or cut_direction == "right" %}
413+
{% if verbose > 1 %}
414+
RESPOND TYPE=command MSG='AFC_Cut: Clearing cutter pin'
415+
{% endif %}
416+
#assume left side pin
417+
{% if (pin_park_x_loc) < (max_x/2) %}
418+
G1 X{pin_park_x_loc+safe_margin_x} F{travel_speed}
419+
#assume right side pin
420+
{% elif (pin_park_x_loc) > (max_x/2) %}
421+
G1 X{pin_park_x_loc-safe_margin_x} F{travel_speed}
422+
{% endif %}
423+
{% else %}
424+
{ action_raise_error("Invalid cut direction. Check the cut_direction in your AFC_Macro_Vars.cfg file!") }
425+
{% endif %}

config/macros/Kick.cfg

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@ gcode:
1313
{% set z_after_kick = vars['z_after_kick'] | default(10) | float %}
1414
{% set kick_speed = vars['kick_speed'] | default(150)*60 | float %}
1515
{% set kick_accel = vars['kick_accel'] | default(0) | float %}
16-
16+
17+
M400
1718
# Get printer bounds to make sure none of our kick moves fall outside of them
1819
# Check for IDEX
1920
{% if printer.dual_carriage is defined %}

0 commit comments

Comments
 (0)