-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathprinter.cfg
560 lines (438 loc) · 11.4 KB
/
printer.cfg
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
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
#MAX3
# This file contains common pin mappings for MKS SKIPR b
# boards. To use this config, the firmware should be compiled for the
# stm32f407. When running "make menuconfig", select the 48KiB
# bootloader, and enable "Serial for communication" and select the "on USART1 PA10/PA9"
# The "make flash" command does not work on the MKS SKIPR. Instead,
# after running "make", copy the generated "out/klipper.bin" file to a
# file named "mks_skipr.bin" on an SD card and then restart the
# MKS SKIPR with that SD card.
# This file contains common pin mappings for MKS SKIPR
# boards. To use this config, the firmware should be compiled for the
# stm32f407. When running "make menuconfig", select the 48KiB
# bootloader, and enable "Serial for communication" and select the "on USART1 PA10/PA9"
# The "make flash" command does not work on the MKS SKIPR. Instead,
# after running "make", copy the generated "out/klipper.bin" file to a
# file named "mks_skipr.bin" on an SD card and then restart the
# MKS SKIPR with that SD card.
# See docs/Config_Reference.md for a description of parameters.
########################################
# Included Files
########################################
[include config_backup.cfg]
[include macros.cfg]
[include sensorless_homing.cfg]
[include variable.cfg]
[include timelapse.cfg]
[include K-ShakeTune/*.cfg]
[include klipperscreen_shutdown.cfg]
[include sfs.cfg]
#[include cartographer.cfg]
[include scanner.cfg]
[exclude_object]
[gcode_arcs]
resolution: 1.0
[pause_resume]
[display_status]
####################Force_move##############################
[force_move]
enable_force_move : true #if bed gets stuck at top and BL touch wont deploy make true and move bed down.
[input_shaper]
shaper_freq_x: 53.2
shaper_type_x: mzv
shaper_freq_y: 47
shaper_type_y: zv
[idle_timeout]
timeout: 5400
[virtual_sdcard]
path: /home/mks/printer_data/gcodes
[duplicate_pin_override]
pins: PA1,PC9
# A comma separated list of pins that may be used multiple times in
# a config file without normal error checks. This parameter must be
# provided.
[pause_resume]
recover_velocity: 50.0
[scanner]
#scanner_touch_z_offset: 0.05
########################################
# Printer & MCU Settings
########################################
[mcu]
# The hardware use USART1 PA10/PA9 connect to RK3328
#serial: /dev/serial/by-id/usb-Klipper_stm32f407xx_4D0045001850314335393520-if00
#canbus_uuid: 11aa22bb33cc
serial: /dev/ttyS0
restart_method: command
[mcu MKS_THR]
serial:/dev/serial/by-id/usb-Klipper_rp2040_45044E15377B6458-if00
[printer]
kinematics:corexy
max_velocity: 600
max_accel: 20000
#max_accel_to_decel: 10000 Depreciated
max_z_velocity: 10
max_z_accel: 500
square_corner_velocity: 8
########################################
# Input Shaper Settings
########################################
[adxl345] #Toolhead
cs_pin: MKS_THR:gpio13
spi_software_sclk_pin: MKS_THR:gpio14
spi_software_mosi_pin: MKS_THR:gpio15
spi_software_miso_pin: MKS_THR:gpio12
axes_map: -x, z, -y
#[lis2dw]
#cs_pin: scanner:PA3
#spi_bus: spi1
[resonance_tester]
#accel_chip: lis2dw
accel_chip:adxl345
probe_points:
162, 162, 20
min_freq: 30
max_freq: 150
[gcode_macro SHAPER_CALIBRATE]
rename_existing: RESHAPER_CALIBRATE
gcode:
RESHAPER_CALIBRATE FREQ_START=30 FREQ_END=150#########
########################################
# Extruder & Driver Settings
########################################
[extruder]
step_pin: MKS_THR:gpio5
dir_pin: MKS_THR:gpio4
enable_pin: !MKS_THR:gpio10
rotation_distance: 53.5 #22.6789511 #Bondtech 5mm Drive Gears
gear_ratio: 1628:170
microsteps: 16
full_steps_per_rotation: 200 #200 for 1.8 degree, 400 for 0.9 degree
nozzle_diameter: 0.400
filament_diameter: 1.75
min_temp: 0
max_temp: 360
min_extrude_temp: 170
smooth_time: 0.08
heater_pin: MKS_THR:gpio0
sensor_type:MAX6675
# One of "MAX6675", "MAX31855", "MAX31856", or "MAX31865".
# One of "MAX6675", "MAX31855", "MAX31856", or "MAX31865".
sensor_pin:MKS_THR:gpio17
# The chip select line for the sensor chip. This parameter must be
# provided.
spi_speed: 100000
# The SPI speed (in hz) to use when communicating with the chip.
# The default is 4000000.
#spi_bus:spi1
spi_software_sclk_pin:MKS_THR:gpio18
spi_software_mosi_pin:MKS_THR:gpio19
spi_software_miso_pin:MKS_THR:gpio16
# See the "common SPI settings" section for a description of the
# above parameters.
#tc_type: K
#tc_use_50Hz_filter: False
#c_averaging_count: 1
# The above parameters control the sensor parameters of MAX31856
# chips. The defaults for each parameter are next to the parameter
# name in the above list.
max_power: 1.0
control : pid
pid_kp = 43.290
pid_ki = 4.976
pid_kd = 94.155
##pid_Kp=14.734
##pid_Ki=6.549
##pid_Kd=8.288
pressure_advance: 0.032
pressure_advance_smooth_time: 0.03
max_extrude_cross_section:500
instantaneous_corner_velocity: 10.000
max_extrude_only_distance: 100.0
max_extrude_only_velocity:5000
max_extrude_only_accel:2000
[tmc2209 extruder]
uart_pin: MKS_THR:gpio6
interpolate: True
run_current: 0.8
#hold_current: 0.5
#sense_resistor: 0.110
stealthchop_threshold: 0
########################################
# X Stepper Motor & Driver Settings
########################################
[stepper_x]
step_pin:PB4
dir_pin:PB3
enable_pin:!PB5
microsteps:64
rotation_distance: 39.94
full_steps_per_rotation:200 #set to 400 for 0.9 degree stepper
endstop_pin:tmc2209_stepper_x:virtual_endstop
position_min: -7
position_endstop:-7
position_max:325
homing_speed:40
homing_retract_dist:0
homing_positive_dir:False
[tmc2209 stepper_x]
uart_pin: PD2
run_current:1.07
#hold_current: 0.5
interpolate: False
stealthchop_threshold: 0
diag_pin:^PB8
driver_SGTHRS: 85
#driver_SGTHRS: 130
########################################
# Y Stepper Motor & Driver Settings
########################################
[stepper_y]
step_pin:PC14
dir_pin:PC13
enable_pin:!PC15
microsteps: 64
rotation_distance: 39.94
full_steps_per_rotation:200 #set to 400 for 0.9 degree stepper
endstop_pin:tmc2209_stepper_y:virtual_endstop
position_min: -10.5
position_endstop: -10.5
position_max: 325
homing_speed:40
homing_retract_dist:0
homing_positive_dir:False
[tmc2209 stepper_y]
uart_pin: PB9
run_current: 1.07
#hold_current: 0.5
interpolate: False
stealthchop_threshold: 0
diag_pin:^PC0
driver_SGTHRS: 110
#driver_SGTHRS: 145
########################################
# Z Stepper Motor & Driver Settings
########################################
[stepper_z]
step_pin:PC10
dir_pin:PA15
enable_pin: !PC11
microsteps: 16
rotation_distance: 8
full_steps_per_rotation: 200
endstop_pin:probe:z_virtual_endstop #!PC3 #for Z-max; endstop have'!' is NO
#position_endstop:326
position_max:325
position_min: -1
homing_speed: 10
homing_retract_dist: 0 # cartographer needs this to be set to 0 default #8.0
second_homing_speed: 8
homing_positive_dir:false
[tmc2209 stepper_z]
uart_pin: PC5
run_current: 0.90
#hold_current: 0.6
interpolate: True
stealthchop_threshold: 999999
########################################
# Bed Settings
########################################
[heater_bed]
heater_pin:PC8
sensor_type: NTC 100K MGB18-104F39050L32
sensor_pin: PA0
max_power: 1.0
control = pid
pid_kp = 71.039
pid_ki = 2.223
pid_kd = 567.421
min_temp: -50
max_temp: 125
########################################
# Temp Settings
########################################
[verify_heater chamber_heater]
max_error: 120
check_gain_time:480
hysteresis: 5
heating_gain: 1
[verify_heater extruder]
max_error: 120
check_gain_time:20
hysteresis: 5
heating_gain: 1
[verify_heater heater_bed]
max_error: 120
check_gain_time:60
hysteresis: 5
heating_gain: 1
[temperature_sensor RPI]
sensor_type: rpi_temperature # alternate def
sensor_type: temperature_host
min_temp: 10
max_temp: 100
[temperature_sensor mcu_temp]
sensor_type: temperature_mcu
[temperature_sensor host_temp]
sensor_type: temperature_host
##########################
# Chamber, Fans &
#############################
########CHAMBER#########
[heater_generic chamber_heater]
heater_pin:PB10
max_power:1.0
sensor_type:NTC 100K MGB18-104F39050L32
sensor_pin:PA1
control:pid
control = pid
pid_Kp=63.418
pid_Ki=1.342
pid_Kd=749.125
min_temp:0
max_temp:70
#########Dual SIDE FAN FAN2#################
[output_pin fan2] #fan2
pin: PA8
pwm: True
cycle_time: 0.0100
hardware_pwm: false
value: 0.00
scale: 255
shutdown_value: 0.0
##########CHAMBER FAN FAN###################
[output_pin fan3]
pin:PC9
pwm: True
cycle_time: 0.0100
hardware_pwm: false
value: 0.0
scale: 255
shutdown_value: 0.0
[temperature_fan chamber_fan] #fan3
pin:PC9
max_power: 1
#-shutdown_speed:
#-cycle_time:
hardware_pwm: false
#-kick_start_time:
off_below:.1
#- See the "fan" section in example.cfg for a description of the
#- above parameters.
sensor_type: NTC 100K MGB18-104F39050L32
sensor_pin: PA1
control : pid
pid_kp : 60
pid_ki : 1
pid_kd : 900
pid_deriv_time:120
min_temp:0
max_temp:90
#- See the "extruder" section in example.cfg for a description of the
#- above parameters.
target_temp: 35.0
#- A temperature (in Celsius) that will be the target temperature.
#- The default is 40 degrees.
max_speed: 1
min_speed: 0.0
######## Hotend fan ###############
[heater_fan hotend_fan]
pin:MKS_THR:gpio1
max_power: 1.0
kick_start_time: 0.5
heater: extruder
heater_temp: 50.0
fan_speed: 1.0
off_below: 0
########### PARTS FAN FAN0#############
[output_pin fan0]
pin: MKS_THR:gpio2
pwm: True
cycle_time: 0.0100
hardware_pwm: false
value: 0
scale: 255
shutdown_value: 0.0
#########Beeper##########
[output_pin beeper]
pin: PA2
pwm: false
shutdown_value:0
value:0
##############################
## Bed mesh #### See cart cfg
##############################
##[bed_mesh]
##speed:150
##horizontal_move_z:10
##mesh_min:25,25
##mesh_max:310,310
##probe_count: 9,9
##algorithm:bicubic
##bicubic_tension:0.2
##mesh_pps: 4, 4
##[bltouch]
##ensor_pin:^MKS_THR:gpio21
##control_pin:MKS_THR:gpio11
##stow_on_each_sample: False
#[probe]
#pin: ^!MKS_THR:gpio21
#x_offset: 28
#y_offset: 4.4
#z_offset: 0.0
#speed: 5
#samples: 3
#samples_result: average
#sample_retract_dist: 3.0
#samples_tolerance: 0.08
#samples_tolerance_retries:3
[respond]
#default_type: echo
# Sets the default prefix of the "M118" and "RESPOND" output to one
# of the following:
# echo: "echo: " (This is the default)
# command: "// "
# error: "!! "
#default_prefix: echo:
# Directly sets the default prefix. If present, this value will
# override the "default_type".
#*# <---------------------- SAVE_CONFIG ---------------------->
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
#*#
#*# [scanner model default]
#*# model_coef = 1.4507020884211754,
#*# 1.8994706395571126,
#*# 0.726591760520041,
#*# 0.17591388045572592,
#*# 0.4889800519597397,
#*# 0.8769513465421855,
#*# -0.5159434179952811,
#*# -1.030387197038306,
#*# 0.39971892121136543,
#*# 0.5297080864701382
#*# model_domain = 3.2796276795745996e-07,3.363225160525418e-07
#*# model_range = 0.100000,5.000000
#*# model_temp = 31.238070
#*# model_offset = 0.00000
#*#
#*# [scanner]
#*# scanner_touch_threshold = 2750
#*# scanner_touch_z_offset = 0.250
#*#
#*# [bed_mesh default]
#*# version = 1
#*# points =
#*# -0.021733, -0.008265, -0.011218, -0.008455
#*# -0.004596, -0.002382, 0.000900, 0.001598
#*# -0.012059, -0.003258, 0.002718, -0.002722
#*# -0.030929, -0.020697, -0.016661, -0.026981
#*# x_count = 4
#*# y_count = 4
#*# mesh_x_pps = 3
#*# mesh_y_pps = 3
#*# algo = bicubic
#*# tension = 0.1
#*# min_x = 99.0
#*# max_x = 226.0
#*# min_y = 113.5
#*# max_y = 211.5