klipper循环打印

背景:

使用klipper固件的打印机,实现在Z轴不变的情况下,让喷嘴循环走路径,比如在气溶胶打印、激光打标等应用中。

问题:

klipper不支持M98指令,不能通过调用子程序的方式实现循环。

解决思路:

使用klipper的sdcard_loop和M808质量,参考网址:
https://www.klipper3d.org/zh/Config_Reference.html#sdcard_loop
https://github.com/Klipper3d/klipper/blob/master/config/sample-macros.cfg

具体过程:

(1)在printer.cfg中插入:

# SDCard 'looping' (aka Marlin M808 commands) support
#
# Support SDCard looping
[sdcard_loop]

# 'Marlin' style M808 compatibility macro for SDCard looping
[gcode_macro M808]
gcode:
    {% if params.K is not defined and params.L is defined %}SDCARD_LOOP_BEGIN COUNT={params.L|int}{% endif %}
    {% if params.K is not defined and params.L is not defined %}SDCARD_LOOP_END{% endif %}
    {% if params.K is defined and params.L is not defined %}SDCARD_LOOP_DESIST{% endif %}

(2)在Gcode文件中需要循环的路径段添加M808指令:

.....
;以M808开始,以M808结束,L 指定循环次数
M808 L5
;需要循环的gcode指令
M808
### Klipper Dual Extruder Macro Commands Configuration In the context of configuring a dual extruder setup with two print heads using Klipper firmware, specific macros and configurations are necessary to ensure both extruders operate correctly. The provided code snippet offers insight into how conditional compilation can be used for button definitions but does not directly address dual extruder setups. For setting up dual extruders in Klipper, one must define each extruder separately within `printer.cfg`. Each extruder requires its own section defining parameters such as stepper motors, heaters, thermistors, etc.[^1] A typical configuration might look like this: ```ini [extruder] heater_pin: ^RES_07 sensor_type: EPCOS 100K B57560G104F sensor_pin: ^ADC_P2_2 step_pin: P2_01 dir_pin: !P2_02 enable_pin: !P2_03 microsteps: 16 rotation_distance: 8.17 gear_ratio: 3:1 [extruder1] heater_pin: ^RES_09 sensor_type: EPCOS 100K B57560G104F sensor_pin: ^ADC_P2_3 step_pin: P2_04 dir_pin: !P2_05 enable_pin: !P2_06 microsteps: 16 rotation_distance: 8.17 gear_ratio: 3:1 ``` To manage operations between these extruders effectively, custom G-code macros should be created. These macros allow switching between extruders or performing actions on either head based on user-defined conditions. An example macro could preheat both beds simultaneously before starting a multi-material print job. Example macro definition: ```gcode [gcode_macro PREHEAT_BOTH_EXTRUDERS] gcode: M140 S{preheat_temp_bed} ; Start heating bed M109 R{preheat_temp_extruder} T0 ; Wait for first extruder temp M109 R{preheat_temp_extruder} T1 ; Wait for second extruder temp G4 S5 ; Wait additional seconds after reaching target temps ``` This approach ensures that all components reach their operational temperatures concurrently, reducing overall preparation time while ensuring optimal printing conditions. --related questions-- 1. How do you configure temperature sensors for multiple extruders in Klipper? 2. What steps need to be taken when calibrating two independent extrusion systems? 3. Can Klipper support more than two extruders? If so, what changes would be required? 4. Is it possible to create automated tool change sequences using G-codes in Klipper? 5. Which parts of the printer hardware require modification to accommodate a secondary extruder system? : Provided information about conditional compilation related to buttons rather than direct details on dual extruder setup; however, similar principles apply regarding configuration through conditionals and defines.
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值