-
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathprinter.cfg
More file actions
366 lines (317 loc) · 8.79 KB
/
printer.cfg
File metadata and controls
366 lines (317 loc) · 8.79 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
# This file contains common pin mappings for the Fysetc Spider board.
# To use this config, the firmware should be compiled for the STM32F446.
# When calling "menuconfig", enable "extra low-level configuration setup"
# and select the "12MHz crystal" as clock reference.
# For flashing, write the compiled klipper.bin to memory location 0x08000000
# See docs/Config_Reference.md for a description of parameters.
# just a test line
[duplicate_pin_override]
pins: PB14
[mcu]
## Obtain definition by "ls -l /dev/serial/by-id/" then unplug to verify
#serial: /dev/serial/by-id/usb-Klipper_stm32f407xx_3A0037000C50414238323520-if00
serial: /dev/ttyS0
restart_method: command
[mcu rpi]
serial: /tmp/klipper_host_mcu
[adxl345]
cs_pin: rpi:None
spi_bus: spidev0.2
[resonance_tester]
accel_chip: adxl345
probe_points: 150,150,10
[printer]
kinematics: corexy
max_velocity: 500
max_accel: 20000
max_accel_to_decel: 20000 #Max 4000
max_z_velocity: 25 #Max 15 for 12V TMC Drivers, can increase for 24V
max_z_accel: 300
square_corner_velocity: 50
[bed_mesh]
speed: 300
horizontal_move_z: 10
mesh_min: 10, 36.6
mesh_max: 290, 290
probe_count: 4,4
# mesh_pps: 5,5
# algorithm: bicubic
# bicubic_tension: 0.2
# relative_reference_index: 5
[stepper_x]
step_pin:PC14
dir_pin:!PC13
enable_pin:!PC15
microsteps: 16
rotation_distance: 40
full_steps_per_rotation:200 #set to 400 for 0.9 degree stepper
endstop_pin:tmc2209_stepper_x:virtual_endstop
position_min: -10
position_endstop: 0
position_max: 315
homing_speed:25
homing_retract_dist:0
homing_positive_dir:false
[stepper_y]
step_pin:PE5
dir_pin:!PE4
enable_pin:!PD14
microsteps:16
rotation_distance: 40
full_steps_per_rotation:200
endstop_pin:tmc2209_stepper_y:virtual_endstop
position_min: 0
position_endstop:0
position_max:320
homing_speed:25
homing_retract_dist:0
homing_positive_dir:false
[stepper_z]
step_pin:PE1
dir_pin:PE0
enable_pin:!PE2
microsteps: 16
rotation_distance: 2.141
full_steps_per_rotation: 200
endstop_pin: PB14
position_min: -100
# position_endstop: 14.78(值越大越往下)
position_endstop: -0.2
position_max: 300
homing_speed: 5
homing_retract_dist: 0
homing_positive_dir: false
[extruder]#挤出机
step_pin:PB5
dir_pin:PB4
enable_pin:!PB6
microsteps:16
rotation_distance: 50.24 #Bondtech 5mm Drive Gears
gear_ratio: 9.54647:1
full_steps_per_rotation: 200 #200 for 1.8 degree, 400 for 0.9 degree
nozzle_diameter: 0.4
filament_diameter: 1.750
min_temp: 0.0
max_temp: 300
heater_pin: PB1
sensor_type: NTC 100K MGB18-104F39050L32
sensor_pin: PC2
max_power: 1.0
control = pid
pid_kp = 36.860
pid_ki = 5.119
pid_kd = 66.348
pressure_advance: 0.05
pressure_advance_smooth_time: 0.040
# 挤出线条横截面的最大面积(以平方毫米为单位)
# 默认值是:4.0 * 喷嘴直径 ^ 2
max_extrude_cross_section: 6.4
max_extrude_only_distance: 300
[heater_bed]
heater_pin: PD12
sensor_type: NTC 100K MGB18-104F39050L32
sensor_pin: PC3
max_power: 1.0
control = pid
pid_kp = 71.039
pid_ki = 2.223
pid_kd = 567.421
min_temp: 0
max_temp: 200
#fan for printed model FAN0
[fan]
pin: PA2
#fan for hotend FAN1
#[heater_fan my_nozzle_fan]
[heater_fan fan1]
pin: PA1
shutdown_speed: 1
#fan for control board FAN2
#[heater_fan my_control_fan]
#[heater_fan fan2]
#pin: PA2
#shutdown_speed: 1
#####################################################################
# Homing and Gantry Adjustment Routines
#####################################################################
[idle_timeout]
timeout: 3600000
[safe_z_home]
home_xy_position: 150,150 # Change coordinates to the center of your print bed
speed: 100
z_hop: 5 # Move up 10mm
z_hop_speed: 25
# [safe_z_home]
# home_xy_position: 39,305.7 # Change coordinates to the center of your print bed
# speed: 100
# z_hop: 20 # Move up 10mm
# z_hop_speed: 10
#####################################################################
# Probe
#####################################################################
[probe]
pin: PB14
x_offset: 0
y_offset: 30
z_offset: 0
speed: 20
samples: 2
samples_result: median
sample_retract_dist: 3.0
samples_tolerance: 0.05
samples_tolerance_retries: 5
[tmc2209 stepper_x]
uart_pin: PE6
interpolate: true
run_current: 1.0
hold_current: 1.0
sense_resistor: 0.110
stealthchop_threshold: 0
diag_pin: ^PA14
driver_SGTHRS:60
[tmc2209 stepper_y]
uart_pin: PE3
interpolate: true
run_current: 1.0
hold_current: 1.0
sense_resistor: 0.110
stealthchop_threshold: 0
diag_pin: ^PA15
driver_SGTHRS:60
[tmc2209 stepper_z]
uart_pin: PB7
interpolate: true
run_current: 1.0
hold_current: 0.8
sense_resistor: 0.110
stealthchop_threshold: 0
# diag_pin: PB15
# driver_SGTHRS:60
[tmc2209 extruder]
uart_pin: PB3
interpolate: true
run_current: 1
hold_current: 0.5
sense_resistor: 0.110
stealthchop_threshold: 0
[board_pins]
aliases:
# EXP1 header
EXP1_1=PB2, EXP1_3=PE11, EXP1_5=PD9, EXP1_7=PE15, EXP1_9=<GND>,
EXP1_2=PE10, EXP1_4=PD10, EXP1_6=PD8, EXP1_8=PE7, EXP1_10=<5V>,
# EXP2 header
EXP2_1=PA6, EXP2_3=PE9, EXP2_5=PE8, EXP2_7=PD13, EXP2_9=<GND>,
EXP2_2=PA5, EXP2_4=PA4, EXP2_6=PA7, EXP2_8=<RST>, EXP2_10=<3.3v>
# See the sample-lcd.cfg file for definitions of common LCD displays.
# Some alternate glyphs for use with 128x64 LCDs. These are used by
# adding them to your printer.cfg.
# See docs/Config_Reference.md for a description of parameters.
######################################################################
# MKS Mini 12864v3.0 (with neopixel backlight leds)
######################################################################
[output_pin beeper]
pin: EXP1_1
[neopixel fysetc_mini12864]
pin: EXP1_6
chain_count: 3
color_order: RGB
initial_RED: 1.0
initial_GREEN: 1.0
initial_BLUE: 0.0
[gcode_macro SENSORLESS_HOME_X]
gcode:
{% set HOME_CUR = 0.700 %}
{% set driver_config = printer.configfile.settings['tmc2209 stepper_x'] %}
{% set RUN_CUR = driver_config.run_current %}
# 为无传感器归位设置电流
SET_TMC_CURRENT STEPPER=stepper_x CURRENT={HOME_CUR}
# 暂停,以确保驱动器失速标志被清除
G4 P2000
# 归位
G28 X0
# 移开
G90
G1 X5 F1200
# 打印过程中设置电流
SET_TMC_CURRENT STEPPER=stepper_x CURRENT={RUN_CUR}
[gcode_macro SENSORLESS_HOME_Y]
gcode:
{% set HOME_CUR = 0.700 %}
{% set driver_config = printer.configfile.settings['tmc2209 stepper_y'] %}
{% set RUN_CUR = driver_config.run_current %}
# 为无传感器归位设置电流
SET_TMC_CURRENT STEPPER=stepper_y CURRENT={HOME_CUR}
# 暂停,以确保驱动器失速标志被清除
G4 P2000
# 归位
G28 Y0
# 移开
G90
G1 Y5 F1200
# 打印过程中设置电流
SET_TMC_CURRENT STEPPER=stepper_y CURRENT={RUN_CUR}
# 自动加载热床补偿
[gcode_macro START_PRINT]
gcode:
BED_MESH_PROFILE LOAD=default
[gcode_macro PRINT_END]
# Use PRINT_END for the slicer ending script - please customise for your slicer of choice
gcode:
M400 ; wait for buffer to clear
G92 E0 ; zero the extruder
G1 E-10.0 F3600 ; retract filament
G91 ; relative positioning
G0 Z1.00 X20.0 Y20.0 F20000 ; move nozzle to remove stringing
TURN_OFF_HEATERS
M107 ; turn off fan
G1 Z2 F3000 ; move nozzle up 2mm
G90 ; absolute positioning
G0 X125 Y250 F3600 ; park nozzle at rear
BED_MESH_CLEAR
# 0829 add G-code of Bambu by XXX;
[gcode_arcs]
resolution: 0.1
[gcode_macro M205]
gcode:
{% set x_jerk = params.X|default(5)|float %}
{% set y_jerk = params.Y|default(5)|float %}
SET_VELOCITY_LIMIT SQUARE_CORNER_VELOCITY={x_jerk}
#*# <---------------------- SAVE_CONFIG ---------------------->
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
#*#
[mcu rpi]
serial: /tmp/klipper_host_mcu
[adxl345]
cs_pin: rpi:None
spi_bus: spidev0.2
[resonance_tester]
accel_chip: adxl345
probe_points: 150,150,10
[input_shaper]
shaper_freq_x: 68.4
shaper_type_x: mzv
shaper_freq_y: 45.6
shaper_type_y: mzv
[virtual_sdcard]
path: ~/printer_data/gcodes
[pause_resume]
[gcode_macro CANCEL_PRINT]
description: Cancel the actual running print
rename_existing: CANCEL_PRINT_BASE
gcode:
TURN_OFF_HEATERS
CANCEL_PRINT_BASE
[display_status]
# Phrozen多色/续料设备
[phrozen_dev]
dev_port: /dev/ttyUSB0
auto_connect: false
fila_cut_x_pos: 310
fila_cut_x_pos_up: 1.2
fila_exist_value: 0.17
fila_empty_value: 0.45
fila_sensor_pin: PC0
wait_max_velocity: 180 # 可选, 等待时喷头的最大移动速度(mmpm)
wait_line_width: 0.5 # 可选, 等待时画线的线宽(mm)
wait_timeout: 60 # 可选, 等待换线的默认时间(s)
switch_fila_zup_by_gcode: 0 # 可选, 换色时Z轴抬升由gcode代码控制高度