-
Notifications
You must be signed in to change notification settings - Fork 0
/
printer-20221002_203426.cfg
435 lines (366 loc) · 14 KB
/
printer-20221002_203426.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
# This file contains common pin mappings for the BIGTREETECH SKR
# MINI 2.0. To use this config, the firmware should be compiled for
# the STM32F103 with a "28KiB bootloader". Also select "enable extra
# low-level configuration options" and configure "GPIO pins to set
# at micro-controller startup" to "!PA14".
# The "make flash" command does not work on the SKR mini. Instead,
# after running "make", copy the generated "out/klipper.bin" file to a
# file named "firmware.bin" on an SD card and then restart the SKR
# mini with that SD card.
# See the example.cfg file for a description of available parameters.
#[include InputShaper.cfg]
[include mainsail.cfg]
[include speedtest.cfg]
[include klicky-probe.cfg]
[mcu]
## Obtain mcu value by "ls -l /dev/serial/by-id/"
serial: /dev/serial/by-id/usb-Klipper_stm32f103xe_32FFD6055646363310791643-if00
restart_method: command
[stepper_x]
step_pin: PB13
dir_pin: PB12 # check https://docs.vorondesign.com/build/startup/#v0 if moving in the wrong direction
enable_pin: !PB14
rotation_distance: 40
#microsteps: 16
microsteps: 32 #Änderung
endstop_pin: PC0
position_endstop: 120
position_max: 121
homing_speed: 20 # Increase after initial setup, Max 100
homing_retract_dist: 5
homing_positive_dir: true
[tmc2209 stepper_x]
uart_pin: PC11
tx_pin: PC10
uart_address: 0
#interpolate: true
interpolate: false #Änderung
run_current: 0.5 # For V0.1 spec NEMA14 40Ncm
hold_current: 0.25
sense_resistor: 0.110
#stealthchop_threshold: 500
stealthchop_threshold: 999999. #Änderung
[stepper_y]
step_pin: PB10
dir_pin: PB2 # check https://docs.vorondesign.com/build/startup/#v0 if moving in the wrong direction
enable_pin: !PB11
rotation_distance: 40
#microsteps: 16
microsteps: 32 #Änderung
endstop_pin: PC1
position_endstop: 122
position_max: 122
homing_speed: 20 # Increase after initial setup, Max 100
homing_retract_dist: 5
homing_positive_dir: true
[tmc2209 stepper_y]
uart_pin: PC11
tx_pin: PC10
uart_address: 2
#interpolate: true
interpolate: false #Änderung
run_current: 0.5 # For V0.1 spec NEMA14 40Ncm
hold_current: 0.25
sense_resistor: 0.110
#stealthchop_threshold: 500
stealthchop_threshold: 999999. #Änderung
[stepper_z]
#step_pin: PB0
#dir_pin: PC5 # Remove ! if moving opposite direction
#enable_pin: !PB1
step_pin: PB3
dir_pin: PB4 # Add ! if moving opposite direction
enable_pin: !PD2
rotation_distance: 8 # For T8x8 integrated lead screw
#microsteps: 16
microsteps: 128 #Änderung 128
endstop_pin: PC2
#position_endstop: -0.10
position_max: 120
position_min: -1.5
homing_speed: 10 # Max 100
second_homing_speed: 3.0
homing_retract_dist: 3.0
[tmc2209 stepper_z]
uart_pin: PC11
tx_pin: PC10
#uart_address: 1
uart_address: 3
#interpolate: true
interpolate: false #Änderung
run_current: 0.37 # For V0.1 spec NEMA17 LDO-42STH25-1004CL200E 1.0A
hold_current: 0.35
#run_current: 0.2 # For V0.1 spec NEMA17 OMC 17LS13-0404E-200G 0.4A
#hold_current: 0.15
sense_resistor: 0.110
stealthchop_threshold: 500
[extruder]
#step_pin: PB3
#dir_pin: !PB4 # Add ! if moving opposite direction
#enable_pin: !PD2
step_pin: PB0
dir_pin: !PC5 # Remove ! if moving opposite direction
enable_pin: !PB1
full_steps_per_rotation: 200 # 1.8° motor LDO
#full_steps_per_rotation: 400 # 0.9° motor i.e OMC 14HR07-1004VRN
rotation_distance: 22.67895 # See calibrating rotation_distance on extruders doc
gear_ratio: 50:10 # For Mini Afterburner
microsteps: 16
nozzle_diameter: 0.400
filament_diameter: 1.750
heater_pin: PC8
sensor_type: EPCOS 100K B57560G104F # Adjust for your hotend thermistor (see options below)
sensor_pin: PA0
#control: pid # Do PID calibration
#pid_Kp: 28.182
#pid_Ki: 1.978
#pid_Kd: 100.397
min_temp: 0
max_temp: 280
min_extrude_temp: 170
max_extrude_only_distance: 780.0
max_extrude_cross_section: 0.8
pressure_advance: 0.04 # See tuning pressure advance doc
#PLA 0.045
#ESUN ABS 0.04
#ABS 0.033
pressure_advance_smooth_time: 0.040
[tmc2209 extruder]
#uart_address: 3
uart_pin: PC11
tx_pin: PC10
uart_address: 1
interpolate: True
#run_current: 0.35 # for LDO 36STH17-1004AHG
#hold_current: 0.35 # for LDO 36STH17-1004AHG
run_current: 0.4 # for OMC 14HR07-1004VRN rated at 1A
#hold_current: 0.15 # for OMC 14HR07-1004VRN rated at 1A
sense_resistor: 0.110
stealthchop_threshold: 0
#stealthchop_threshold: 500 #Änderung
[heater_bed]
heater_pin: PC9
sensor_type: Generic 3950 # For Keenovo, verify yours
sensor_pin: PC3
smooth_time: 3.0
max_power: 0.9 # Only need this for 100w pads
min_temp: 0
max_temp: 120
#control: pid # Do PID calibration
#pid_kp: 68.453
#pid_ki: 2.749
#pid_kd: 426.122
[temperature_sensor Chamber_Temp]
sensor_type: Generic 3950
sensor_pin: PA7 # PA7 is MOSI on the SPI header. Has an on board 10K pullup to 3v3. Connect other leg of thermistor to ground
pullup_resistor: 10000
[printer]
kinematics: corexy
max_velocity: 400
max_accel: 4000
max_accel_to_decel: 4000
max_z_velocity: 15
max_z_accel: 45
square_corner_velocity: 5.0
[heater_fan hotend_fan]
pin: PC7
max_power: 1.0
kick_start_time: 0.5
heater: extruder
heater_temp: 50.0
#fan_speed: 1.0 # You can't PWM the delta fan unless using blue wire
[fan]
pin: PB8
max_power: 1.0
kick_start_time: 1
#depending on your fan, you may need to increase or reduce this value
#if your fan will not start
off_below: 0.13
cycle_time: 0.010
[idle_timeout]
timeout: 1800
#[safe_z_home]
#home_xy_position: 120,120
#speed: 50.0
#z_hop: 5
# Tool to help adjust bed leveling screws. One may define a
# [bed_screws] config section to enable a BED_SCREWS_ADJUST g-code
# command.
[bed_screws]
screw1: 60,5
screw1_name: front screw
screw2: 5,115
screw2_name: back left
screw3: 115,115
screw3_name: back right
[input_shaper]
shaper_freq_x: 62.4
shaper_type_x: mzv
shaper_freq_y: 56.6
shaper_type_y: ei
[skew_correction]
[temperature_sensor raspberry_pi]
sensor_type: temperature_host
min_temp: 10
max_temp: 100
[temperature_sensor mcu_temp]
sensor_type: temperature_mcu
min_temp: 0
max_temp: 100
#[exclude_object]
[gcode_macro PRINT_START]
gcode:
# Parameters
{% set bedtemp = params.BED|int %}
{% set hotendtemp = params.HOTEND|int %}
{% set chambertemp = params.CHAMBER|default(0)|int %}
CG28
#BED_MESH_PROFILE LOAD=default
# <insert your routines here>
M104 S{hotendtemp}
M190 S{bedtemp} ; set & wait for bed temp
TEMPERATURE_WAIT SENSOR="temperature_sensor Chamber_Temp" MINIMUM={chambertemp} ; wait for chamber temp
# <insert your routines here>
M109 S{hotendtemp} ; set & wait for hotend temp
# <insert your routines here>
G28 Z ; final z homing
G90 ; absolute positioning
[gcode_macro PRINT_END]
# Use PRINT_END for the slicer ending script - please customize for your slicer of choice
gcode:
M400 ; wait for buffer to clear
G92 E0 ; zero the extruder
G1 E-4.0 F3600 ; retract filament
G91 ; relative positioning
# Get Boundaries
{% set max_x = printer.configfile.config["stepper_x"]["position_max"]|float %}
{% set max_y = printer.configfile.config["stepper_y"]["position_max"]|float %}
{% set max_z = printer.configfile.config["stepper_z"]["position_max"]|float %}
# Check end position to determine safe direction to move
{% if printer.toolhead.position.x < (max_x - 20) %}
{% set x_safe = 20.0 %}
{% else %}
{% set x_safe = -20.0 %}
{% endif %}
{% if printer.toolhead.position.y < (max_y - 20) %}
{% set y_safe = 20.0 %}
{% else %}
{% set y_safe = -20.0 %}
{% endif %}
{% if printer.toolhead.position.z < (max_z - 2) %}
{% set z_safe = 2.0 %}
{% else %}
{% set z_safe = max_z - printer.toolhead.position.z %}
{% endif %}
G0 Z{z_safe} F3600 ; move nozzle up
G0 X{x_safe} Y{y_safe} F20000 ; move nozzle to remove stringing
TURN_OFF_HEATERS
M107 ; turn off fan
G90 ; absolute positioning
G0 X60 Y{max_y} F3600 ; park nozzle at rear
[gcode_macro LOAD_FILAMENT]
gcode:
M83 ; set extruder to relative
G1 E30 F300 ; load
G1 E15 F200 ; prime nozzle with filament
M82 ; set extruder to absolute
[gcode_macro UNLOAD_FILAMENT]
gcode:
M83 ; set extruder to relative
G1 E10 F300 ; extrude a little to soften tip
G1 E-70 F1800 ; retract some, but not too much or it will jam
M82 ; set extruder to absolute
#ELLIS KRAM
[gcode_macro CG28]
gcode:
{% if "xyz" not in printer.toolhead.homed_axes %}
G28
{% endif %}
[gcode_macro M600]
gcode:
PAUSE ; Pause
[gcode_macro PAUSE]
rename_existing: BASE_PAUSE
gcode:
# Parameters
{% set z = params.Z|default(10)|int %} ; z hop amount
{% if printer['pause_resume'].is_paused|int == 0 %}
SET_GCODE_VARIABLE MACRO=RESUME VARIABLE=zhop VALUE={z} ; set z hop variable for reference in resume macro
SET_GCODE_VARIABLE MACRO=RESUME VARIABLE=etemp VALUE={printer['extruder'].target} ; set hotend temp variable for reference in resume macro
SAVE_GCODE_STATE NAME=PAUSE ; save current print position for resume
BASE_PAUSE ; pause print
{% if (printer.gcode_move.position.z + z) < printer.toolhead.axis_maximum.z %} ; check that zhop doesn't exceed z max
G91 ; relative positioning
G1 Z{z} F900 ; raise Z up by z hop amount
{% else %}
{ action_respond_info("Pause zhop exceeds maximum Z height.") } ; if z max is exceeded, show message and set zhop value for resume to 0
SET_GCODE_VARIABLE MACRO=RESUME VARIABLE=zhop VALUE=0
{% endif %}
G90 ; absolute positioning
G1 X{printer.toolhead.axis_maximum.x/2} Y{printer.toolhead.axis_minimum.y+5} F6000 ; park toolhead at front center
SAVE_GCODE_STATE NAME=PAUSEPARK ; save parked position in case toolhead is moved during the pause (otherwise the return zhop can error)
M104 S0 ; turn off hotend
SET_IDLE_TIMEOUT TIMEOUT=43200 ; set timeout to 12 hours
{% endif %}
[gcode_macro RESUME]
rename_existing: BASE_RESUME
variable_zhop: 0
variable_etemp: 0
gcode:
# Parameters
{% set e = params.E|default(2.5)|int %} ; hotend prime amount (in mm)
{% if printer['pause_resume'].is_paused|int == 1 %}
#RESETRGB ; reset LCD color
SET_IDLE_TIMEOUT TIMEOUT={printer.configfile.settings.idle_timeout.timeout} ; set timeout back to configured value
{% if etemp > 0 %}
M109 S{etemp|int} ; wait for hotend to heat back up
{% endif %}
RESTORE_GCODE_STATE NAME=PAUSEPARK MOVE=1 MOVE_SPEED=100 ; go back to parked position in case toolhead was moved during pause (otherwise the return zhop can error)
G91 ; relative positioning
M83 ; relative extruder positioning
{% if printer[printer.toolhead.extruder].temperature >= printer.configfile.settings.extruder.min_extrude_temp %}
G1 Z{zhop * -1} E{e} F900 ; prime nozzle by E, lower Z back down
{% else %}
G1 Z{zhop * -1} F900 ; lower Z back down without priming (just in case we are testing the macro with cold hotend)
{% endif %}
RESTORE_GCODE_STATE NAME=PAUSE MOVE=1 MOVE_SPEED=60 ; restore position
BASE_RESUME ; resume print
{% endif %}
[gcode_macro CANCEL_PRINT]
rename_existing: BASE_CANCEL_PRINT
gcode:
SET_IDLE_TIMEOUT TIMEOUT={printer.configfile.settings.idle_timeout.timeout} ; set timeout back to configured value
CLEAR_PAUSE
SDCARD_RESET_FILE
PRINT_END
BASE_CANCEL_PRINT
# Sensor Types
# "EPCOS 100K B57560G104F"
# "ATC Semitec 104GT-2"
# "NTC 100K beta 3950" (Keenovo Heater Pad)
# "Honeywell 100K 135-104LAG-J01"
# "NTC 100K MGB18-104F39050L32"
# "AD595"
# "PT100 INA826"
#*# <---------------------- SAVE_CONFIG ---------------------->
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated.
#*#
#*# [heater_bed]
#*# control = pid
#*# pid_kp = 41.267
#*# pid_ki = 1.304
#*# pid_kd = 326.525
#*#
#*# [extruder]
#*# control = pid
#*# pid_kp = 30.258
#*# pid_ki = 2.430
#*# pid_kd = 94.179
#*#
#*# [stepper_z]
#*# position_endstop = -0.425
#*#
#*# [skew_correction my_skew_profile]
#*# xy_skew = 0.00100626709
#*# xz_skew = 0.0
#*# yz_skew = 0.0