Belay multiplier changes do not affect an already queued/active extrusion move
Summary
When using Belay with extruder_type: extruder_stepper, the high/low multiplier appears to update only for future extrusion moves. It does not seem to affect an extrusion move that is already queued or currently running.
This becomes a practical limitation for external filament feeder systems, where Belay is expected to react to buffer state changes while extrusion is actively happening.
Setup
I am using Belay with an extruder_stepper as an external filament feeder:
[extruder_stepper sheep_feeder]
extruder: extruder
# stepper pins etc.
[belay sheep_belay]
extruder_type: extruder_stepper
extruder_stepper_name: sheep_feeder
sensor_pin: ^sheep_feeder:PB8
multiplier_high: 1.05
multiplier_low: 0.95
debug_level: 1
The external feeder is placed before the toolhead extruder, with a reverse Bowden path between them. The Belay is used as a filament buffer sensor to slightly increase or decrease the secondary feeder output.
Observed behavior
Belay can be enabled successfully:
ENABLE_BELAY BELAY=sheep_belay
The sensor state can be queried and changes correctly:
QUERY_BELAY BELAY=sheep_belay
The issue appears when extrusion is already in progress.
Example test:
If the Belay sensor state changes while this extrusion move is already running, the high/low multiplier does not appear to affect that active extrusion move. The secondary extruder continues as if the multiplier that was active when the move was queued is still being used.
The multiplier change appears to affect later/new extrusion moves instead.
Expected behavior
When the Belay sensor changes state during extrusion, the secondary extruder multiplier should affect the feeder output as soon as possible, ideally during the active extrusion move.
For an external filament feeder and buffer system, the intended behavior is more like real-time buffer correction:
- Belay compressed during forward extrusion: secondary feeder should increase feed rate.
- Belay expanded during forward extrusion: secondary feeder should reduce feed rate.
- The correction should take effect while extrusion is happening, not only on the next G-code move.
Why this matters
For normal sliced print moves, this may be less visible because the print consists of many short extrusion segments.
However, it becomes a problem in cases such as:
- long UI extrusion moves
- long purge moves
- filament loading/unloading
- vase mode or long continuous paths
- high-flow printing
- external feeder systems with long reverse Bowden paths
- feeder/buffer setups where the buffer can hit its mechanical limit before the next move boundary
In these cases, waiting until the next planned move can be too late.
Current implementation concern
From reading the current implementation, the multiplier for extruder_stepper is applied by changing the secondary stepper rotation distance:
self.set_multiplier = lambda m: stepper.set_rotation_distance(
base_rotation_dist / m
)
The multiplier is updated when the Belay sensor callback fires:
def sensor_callback(self, eventtime, state):
self.last_state = state
if self.enabled:
self.update_multiplier()
This does update the multiplier state, but it does not appear to modify already planned/queued step generation for an active extrusion move.
Question
Is this behavior expected due to how Klipper/Kalico queues extrusion moves and step generation?
If so, would it be possible to document this limitation clearly?
If not, would there be a way to make Belay correction affect an active extrusion move, or should Belay be considered a move-boundary-based correction system rather than real-time buffer control?
Possible directions
Some possible approaches could be:
- Document that Belay multiplier changes affect future moves only.
- Add a warning/example for long extrusion moves.
- Improve status/debug output so it is clearer when a multiplier changed but cannot affect already queued motion.
- Investigate whether a different correction approach is needed for real-time external feeder/buffer control.
Belay multiplier changes do not affect an already queued/active extrusion move
Summary
When using Belay with
extruder_type: extruder_stepper, the high/low multiplier appears to update only for future extrusion moves. It does not seem to affect an extrusion move that is already queued or currently running.This becomes a practical limitation for external filament feeder systems, where Belay is expected to react to buffer state changes while extrusion is actively happening.
Setup
I am using Belay with an
extruder_stepperas an external filament feeder:The external feeder is placed before the toolhead extruder, with a reverse Bowden path between them. The Belay is used as a filament buffer sensor to slightly increase or decrease the secondary feeder output.
Observed behavior
Belay can be enabled successfully:
ENABLE_BELAY BELAY=sheep_belayThe sensor state can be queried and changes correctly:
The issue appears when extrusion is already in progress.
Example test:
If the Belay sensor state changes while this extrusion move is already running, the high/low multiplier does not appear to affect that active extrusion move. The secondary extruder continues as if the multiplier that was active when the move was queued is still being used.
The multiplier change appears to affect later/new extrusion moves instead.
Expected behavior
When the Belay sensor changes state during extrusion, the secondary extruder multiplier should affect the feeder output as soon as possible, ideally during the active extrusion move.
For an external filament feeder and buffer system, the intended behavior is more like real-time buffer correction:
Why this matters
For normal sliced print moves, this may be less visible because the print consists of many short extrusion segments.
However, it becomes a problem in cases such as:
In these cases, waiting until the next planned move can be too late.
Current implementation concern
From reading the current implementation, the multiplier for
extruder_stepperis applied by changing the secondary stepper rotation distance:The multiplier is updated when the Belay sensor callback fires:
This does update the multiplier state, but it does not appear to modify already planned/queued step generation for an active extrusion move.
Question
Is this behavior expected due to how Klipper/Kalico queues extrusion moves and step generation?
If so, would it be possible to document this limitation clearly?
If not, would there be a way to make Belay correction affect an active extrusion move, or should Belay be considered a move-boundary-based correction system rather than real-time buffer control?
Possible directions
Some possible approaches could be: