AndrewEllis93 / Print-Tuning-Guide

1.95k stars 260 forks source link

Pause macro with BTT Smart Filament Sensor V2 #99

Open drpeej opened 11 months ago

drpeej commented 11 months ago

I have a BTT SFS 2 and am having problems with my PAUSE macro

I have decided to change my PAUSE macro to the one you publish as you mention the BTT sfs.

You say "f you use a filament sensor, put its name in the SET_FILAMENT_SENSOR command". However the BTT SFS 2 contains 2 filament sensors. Which one should I choose or should I define both.

This is my sensor definition in printer.cfg:

[filament_switch_sensor switch_sensor] switch_pin: ^PG13 # as shown in Figure 2, switch sensor IO is PA0 pause_on_runout: False runout_gcode: PAUSE # [pause_resume] is required in printer.cfg M117 Filament switch runout insert_gcode:
M117 Filament switch inserted

[filament_motion_sensor encoder_sensor] switch_pin: ^PG12 # as shown in Figure 2, motion sensor IO is PC2 detection_length: 2.88 # accuracy of motion sensor 2.88mm extruder: extruder pause_on_runout: False runout_gcode:
PAUSE # [pause_resume] is required in printer.cfg M117 Filament encoder runout insert_gcode: M117 Filament encoder inserted

eduhoribe commented 11 months ago

While the BTT SFS V2 is just one piece of hardware, it has two different sensors on it, the micro-switch and the encoder, that's why you set it up as two sensors in Klipper.

I don't see a reason why would you want to disable just one of the sensors in the PAUSE macro, so you probably want to disable both.

To make things neater, you can also create a macro like this one to enable and disable both sensors. I found it specially useful if you do it in more than one macro (like the RESUME).

And as a side note, the detection_length suggested by BTT was giving me a lot of false-positives, so it's a good idea to do some tinkering on it too.