-
-
Save thinkstylestudio/0dae180e320d4fea14079333d8d448e5 to your computer and use it in GitHub Desktop.
printer.cfg
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This file contains common pin mappings for the BIGTREETECH SKR mini | |
# E3 v2.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 E3. 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 E3 with that SD card. | |
# See the example.cfg file for a description of available parameters. | |
# ====================================================================== | |
[bltouch] | |
stow_on_each_sample: False | |
probe_with_touch_mode: True | |
sensor_pin: ^PC14 | |
control_pin: PA1 | |
pin_move_time: 0.5 | |
pin_up_touch_mode_reports_triggered: False | |
x_offset: -43 | |
y_offset: -13 | |
speed: 10 | |
lift_speed: 20 | |
samples: 3 | |
sample_retract_dist: 5 | |
samples_tolerance_retries: 3 | |
[screws_tilt_adjust] | |
horizontal_move_z: 10 | |
screw1: 70,200 | |
screw1_name: back left | |
screw2: 235,200 | |
screw2_name: back right | |
screw3: 70,47 | |
screw3_name: front left | |
screw4: 235,47 | |
screw4_name: front right | |
[force_move] | |
enable_force_move: True | |
[safe_z_home] | |
home_xy_position: 161.5,131.5 | |
speed: 150 | |
z_hop: 15 | |
z_hop_speed: 20 | |
[bed_mesh] | |
speed: 250 | |
horizontal_move_z: 6 | |
mesh_min: 5,5 | |
mesh_max: 192,187 | |
probe_count: 5 | |
mesh_pps: 2,2 | |
algorithm: bicubic | |
# ====================================================================== | |
[stepper_x] | |
step_pin: PB13 | |
dir_pin: !PB12 | |
enable_pin: !PB14 | |
step_distance: .0125 | |
endstop_pin: ^PC0 | |
position_endstop: 0 | |
position_max: 235 | |
homing_speed: 50 | |
second_homing_speed: 20 | |
[tmc2209 stepper_x] | |
uart_pin: PC11 | |
tx_pin: PC10 | |
uart_address: 0 | |
microsteps: 16 | |
run_current: 0.580 | |
hold_current: 0.500 | |
stealthchop_threshold: 250 | |
# ====================================================================== | |
[stepper_y] | |
step_pin: PB10 | |
dir_pin: !PB2 | |
enable_pin: !PB11 | |
step_distance: .0125 | |
endstop_pin: ^PC1 | |
position_endstop: -12 | |
position_min:-12 | |
position_max: 200 | |
homing_speed: 50 | |
second_homing_speed: 20 | |
[tmc2209 stepper_y] | |
uart_pin: PC11 | |
tx_pin: PC10 | |
uart_address: 2 | |
microsteps: 16 | |
run_current: 0.580 | |
hold_current: 0.500 | |
stealthchop_threshold: 250 | |
# ====================================================================== | |
[stepper_z] | |
step_pin: PB0 | |
dir_pin: PC5 | |
enable_pin: !PB1 | |
step_distance: .0025 | |
endstop_pin: probe:z_virtual_endstop | |
position_min: -5 | |
position_max: 250 | |
[tmc2209 stepper_z] | |
uart_pin: PC11 | |
tx_pin: PC10 | |
uart_address: 1 | |
microsteps: 16 | |
run_current: 0.580 | |
hold_current: 0.500 | |
stealthchop_threshold: 5 | |
# ====================================================================== | |
#SET_EXTRUDER_STEP_DISTANCE EXTRUDER=extruder DISTANCE=0.010706 | |
# Measure 120mm, then extrude 100mm | |
# G1 E100 F100 | |
# step_distance = old_e_steps * ((120 - distance_to_mark) / 100) | |
[extruder] | |
step_pin: PB3 | |
dir_pin: !PB4 | |
enable_pin: !PD2 | |
step_distance: 0.010706 | |
nozzle_diameter: 0.400 | |
filament_diameter: 1.750 | |
heater_pin: PC8 | |
sensor_type: EPCOS 100K B57560G104F | |
sensor_pin: PA0 | |
min_temp: 0 | |
min_extrude_temp: 0 | |
max_extrude_only_distance: 500 | |
max_temp: 280 | |
pressure_advance: 0.091 | |
pressure_advance_smooth_time: 0.040 | |
[tmc2209 extruder] | |
uart_pin: PC11 | |
tx_pin: PC10 | |
uart_address: 3 | |
microsteps: 16 | |
run_current: 0.650 | |
hold_current: 0.500 | |
stealthchop_threshold: 5 | |
# ====================================================================== | |
[heater_bed] | |
heater_pin: PC9 | |
sensor_type: EPCOS 100K B57560G104F | |
sensor_pin: PC3 | |
min_temp: 0 | |
max_temp: 130 | |
# ====================================================================== | |
[fan] | |
pin: PC6 | |
[heater_fan hotend_fan] | |
pin: PC7 | |
heater: extruder | |
heater_temp: 50.0 | |
[controller_fan case_fan] | |
pin: host:gpio18 | |
heater: heater_bed | |
# ====================================================================== | |
[temperature_sensor rpi_cpu_temp] | |
sensor_type: rpi_temperature | |
[temperature_sensor mcu_temp] | |
sensor_type: temperature_mcu | |
sensor_mcu: mcu | |
# The micro-controller to read from. The default is "mcu". | |
#sensor_temperature1: | |
#sensor_adc1: | |
# Specify the above two parameters (a temperature in Celsius and an | |
# ADC value as a float between 0.0 and 1.0) to calibrate the | |
# micro-controller temperature. This may improve the reported | |
# temperature accuracy on some chips. A typical way to obtain this | |
# calibration information is to completely remove power from the | |
# printer for a few hours (to ensure it is at the ambient | |
# temperature), then power it up and use the QUERY_ADC command to | |
# obtain an ADC measurement. Use some other temperature sensor on | |
# the printer to find the corresponding ambient temperature. The | |
# default is to use the factory calibration data on the | |
# micro-controller (if applicable) or the nominal values from the | |
# micro-controller specification. | |
#sensor_temperature2: | |
#sensor_adc2: | |
# If sensor_temperature1/sensor_adc1 is specified then one may also | |
# specify sensor_temperature2/sensor_adc2 calibration data. Doing so | |
# may provide calibrated "temperature slope" information. The | |
# default is to use the factory calibration data on the | |
# micro-controller (if applicable) or the nominal values from the | |
# micro-controller specification. | |
# ====================================================================== | |
[mcu] | |
serial: /dev/serial/by-id/usb-Klipper_stm32f103xe_31FFD6054248313014761257-if00 | |
[mcu host] | |
serial: /tmp/klipper_host_mcu | |
# ====================================================================== | |
[printer] | |
kinematics: cartesian | |
max_velocity: 300 | |
max_accel: 7000 | |
max_accel_to_decel: 7000 | |
max_z_velocity: 40 | |
max_z_accel: 100 | |
square_corner_velocity: 8 | |
[input_shaper] | |
shaper_freq_x: 43.38 | |
shaper_freq_y: 46.67 | |
[static_digital_output usb_pullup_enable] | |
pins: !PA14 | |
[board_pins] | |
aliases: | |
# EXP1 header | |
EXP1_1=PB5, EXP1_3=PA9, EXP1_5=PA10, EXP1_7=PB8, EXP1_9=<GND>, | |
EXP1_2=PA15, EXP1_4=<RST>, EXP1_6=PB9, EXP1_8=PB15, EXP1_10=<5V> | |
[display] | |
lcd_type: st7920 | |
cs_pin: EXP1_7 | |
sclk_pin: EXP1_6 | |
sid_pin: EXP1_8 | |
encoder_pins: ^EXP1_5, ^EXP1_3 | |
click_pin: ^!EXP1_2 | |
[output_pin beeper] | |
pin: EXP1_1 | |
# ====================================================================== | |
[filament_switch_sensor Filament_Runout] | |
pause_on_runout: True | |
# When set to True, a PAUSE will execute immediately after a runout | |
# is detected. Note that if pause_on_runout is False and the | |
# runout_gcode is omitted then runout detection is disabled. Default | |
# is True. | |
#runout_gcode: | |
# A list of G-Code commands to execute after a filament runout is | |
# detected. See docs/Command_Templates.md for G-Code format. If | |
# pause_on_runout is set to True this G-Code will run after the | |
# PAUSE is complete. The default is not to run any G-Code commands. | |
#insert_gcode: | |
# A list of G-Code commands to execute after a filament insert is | |
# detected. See docs/Command_Templates.md for G-Code format. The | |
# default is not to run any G-Code commands, which disables insert | |
# detection. | |
event_delay: 3.0 | |
# The minimum amount of time in seconds to delay between events. | |
# Events triggered during this time period will be silently | |
# ignored. The default is 3 seconds. | |
pause_delay: 5 | |
# The amount of time to delay, in seconds, between the pause command | |
# dispatch and execution of the runout_gcode. It may be useful to | |
# increase this delay if OctoPrint exhibits strange pause behavior. | |
# Default is 0.5 seconds. | |
switch_pin: !PC15 | |
# The pin on which the switch is connected. This parameter must be | |
# provided. | |
# ====================================================================== | |
# MACROS | |
# ====================================================================== | |
# Replace the slicer's custom start and end g-code scripts with | |
# START_PRINT and END_PRINT. | |
[gcode_macro START_PRINT] | |
default_parameter_BED_TEMP: 0 | |
default_parameter_EXTRUDER_TEMP: 0 | |
gcode: | |
;Put printing message on LCD screen | |
M117 Heating... | |
M140 S{BED_TEMP} ; set bed temp | |
G28 X Y; Home X Y | |
G1 Y10 F3000; this is a good start heating position | |
M190 S{BED_TEMP} ; wait for bed temp | |
G28 Z ; Home Z | |
M104 S{EXTRUDER_TEMP} ; set extruder temp | |
; Auto Leveling | |
BED_MESH_PROFILE LOAD=default | |
M109 S{EXTRUDER_TEMP} ; wait for extruder temp | |
M117 Priming | |
; Start of print | |
G21; metric values | |
G90 ; absolute positioning | |
M82; set extruder to absolute mode | |
G1 Z5; Move nozzle above 5 mm of the bed | |
; now print a line of filament to prepare extrusion | |
G92 E0 ; reset extruder | |
G1 X5 Y15 F5000.0 ; move to start-line position | |
G1 X5 Y15 Z0.3 F5000.0 | |
G1 Y20 F1000 E0.8 | |
G92 E0 ; reset extruder | |
G1 X5 Y200.0 Z0.3 F1500.0 E15 ; draw 1st line | |
G1 X5.4 Y200.0 Z0.3 F5000.0 ; move to side a little | |
G1 X5.4 Y20 Z0.3 F1500.0 E30 ; draw 2nd line | |
G1 E34 ; Retract extruder | |
G92 E0 ; reset extruder | |
G1 Z3.0 F3000 ; move z up little to prevent scratching of surface | |
G1 X100 Y100 F15000 | |
;Tuning params | |
;Put printing message on LCD screen | |
M117 Printing... | |
M83 | |
; Start of actual GCode for the print | |
[gcode_macro END_PRINT] | |
gcode: | |
M140 S0 | |
M104 S0 | |
G92 E1 | |
G1 E-1 F300 | |
M106 S0 | |
G28 X0 | |
G90 | |
M84 | |
SAVE_IF_SET | |
[gcode_macro G29] | |
gcode: | |
G28 | |
G1 Z10 F600 | |
BED_MESH_CLEAR | |
BED_MESH_CALIBRATE | |
BED_MESH_PROFILE LOAD=default | |
[gcode_macro M204] | |
rename_existing: M204.1 | |
default_parameter_F: 0.75 | |
gcode: | |
{% if 'S' in params %} | |
SET_VELOCITY_LIMIT ACCEL={ S } ACCEL_TO_DECEL={ S|float * F|float } | |
{% endif %} | |
[gcode_macro M205] | |
gcode: | |
{% if 'X' in params %} | |
SET_VELOCITY_LIMIT SQUARE_CORNER_VELOCITY={ X } | |
{% endif %} | |
[virtual_sdcard] | |
path: ~/gcode_files | |
[display_status] | |
# ====================================================================== | |
# Save at end macros | |
# ====================================================================== | |
[gcode_macro SAVE_AT_END] | |
variable_save: 0 | |
gcode: | |
SET_GCODE_VARIABLE MACRO=SAVE_AT_END VARIABLE=save VALUE=1 | |
[gcode_macro SAVE_IF_SET] | |
gcode: | |
{% if printer["gcode_macro SAVE_AT_END"].save == 1 %} | |
{printer.gcode.action_respond_info("saving and restarting now")} | |
SAVE_CONFIG | |
{% endif %} | |
# ====================================================================== | |
# Filament load and unload macros | |
# ====================================================================== | |
[pause_resume] | |
# M600: Filament Change. This macro will pause the printer, move the | |
# tool to the change position, and retract the filament 50mm. Adjust | |
# the retraction settings for your own extruder. After filament has | |
# been changed, the print can be resumed from its previous position | |
# with the "RESUME" gcode. | |
[gcode_macro PAUSE] | |
rename_existing: BASE_PAUSE | |
default_parameter_X: 200 # edit to your preferred park position | |
default_parameter_Y: 200 # edit to your preferred park position | |
default_parameter_Z: 100 # edit to your preferred park position | |
default_parameter_E: 1 # edit to your preferred retract length | |
gcode: | |
SAVE_GCODE_STATE NAME=PAUSE_state | |
BASE_PAUSE | |
G91 | |
G1 E-{E} F2100 | |
G1 Z{Z} | |
G90 | |
G1 X{X} Y{Y} F6000 | |
[gcode_macro RESUME] | |
rename_existing: BASE_RESUME | |
default_parameter_E: 1 # edit to your preferred retract length | |
gcode: | |
G91 | |
G1 E{E} F2100 | |
G90 | |
RESTORE_GCODE_STATE NAME=PAUSE_state MOVE=1 | |
BASE_RESUME | |
[gcode_macro CANCEL_PRINT] | |
rename_existing: BASE_CANCEL_PRINT | |
gcode: | |
TURN_OFF_HEATERS | |
CLEAR_PAUSE | |
SDCARD_RESET_FILE | |
BASE_CANCEL_PRINT | |
[gcode_macro PARK] | |
gcode: | |
G1 X125 Y200.0 Z200.0 F4000 | |
[gcode_macro FILAMENT_LOAD] | |
gcode: | |
M83 ; set e to relative positioning | |
G92 E0.0 | |
G1 E40 F1000 ; Initially go fast | |
G92 E0.0 | |
G1 E100 F200 ; then go slow | |
G92 E0.0 | |
[gcode_macro FILAMENT_UNLOAD] | |
gcode: | |
M83 ; set e to relative positioning | |
# wiggle filament out of the nozzle | |
G1 E0.5 F1000 | |
G1 E-0.5 F1000 | |
G1 E1.0 F1000 | |
G1 E-1.0 F1000 | |
G1 E1.5 F1000 | |
G1 E-1.5 F1000 | |
G1 E2.0 F1000 | |
G1 E-450 F3000 ;fully unload | |
G92 E0.0 | |
# M600: Filament Change. This macro will pause the printer, move the | |
# tool to the change position, and retract the filament 50mm. Adjust | |
# the retraction settings for your own extruder. After filament has | |
# been changed, the print can be resumed from its previous position | |
# with the "RESUME" gcode. | |
[gcode_macro M600] | |
default_parameter_X: 50 | |
default_parameter_Y: 0 | |
default_parameter_Z: 10 | |
gcode: | |
SAVE_GCODE_STATE NAME=M600_state | |
PAUSE | |
G91 | |
G1 E-.8 F2700 | |
G1 Z{Z} | |
G90 | |
G1 X{X} Y{Y} F3000 | |
G91 | |
G1 E-50 F1000 | |
RESTORE_GCODE_STATE NAME=M600_state | |
# ====================================================================== | |
# MENU MACRO | |
# ====================================================================== | |
[menu __main __cal] | |
type: list | |
name: Calibration | |
enable: true | |
# Stand alone CAL Menus | |
# ====================================================================== | |
[menu __main __cal __probe_accuracy] | |
type: command | |
name: Test Z Probe Accuracy | |
enable: true | |
gcode: | |
G28 | |
PROBE_ACCURACY | |
[menu __main __cal __firmware_restart] | |
type: command | |
name: Restart firmware | |
enable: true | |
gcode: | |
FIRMWARE_RESTART | |
[menu __main __cal __homeXYZ] | |
type: command | |
name: Home XYZ | |
enable: true | |
gcode: | |
G28 | |
[menu __main __cal __bed_mesh_calibrate] | |
type: command | |
name: Generate bed mesh | |
enable: true | |
gcode: | |
G29 | |
[menu __main __cal __screws_tilt_calculate] | |
type: command | |
name: Calculate Bed Tilt | |
enable: true | |
gcode: | |
SCREWS_TILT_CALCULATE | |
# ====================================================================== | |
[menu __main __cal __calibratez] | |
type: list | |
name: Adjust Z offset | |
enable: true | |
[menu __main __cal __calibratez __test_z] | |
type: input | |
name: Test Z: {['++','+','+.01','+.05','+.1','+.5','-.5','-.1','-.05','-.01','-','--'][menu.input|int]} | |
input: 6 | |
input_min: -2 | |
input_max: 11 | |
input_step: 1 | |
gcode: | |
{%- if menu.event == 'long_click' -%} | |
TESTZ Z={['++','+','+.01','+.05','+.1','+.5','+1','-1','-.5','-.1','-.05','-.01','-','--'][menu.input|int]} | |
{%- endif -%} | |
[menu __main __cal __calibratez __execute] | |
type: command | |
name: Execute | |
enable: true | |
gcode: | |
G28 | |
PROBE_CALIBRATE | |
[menu __main __cal __calibratez __accept] | |
type: command | |
name: Accept | |
enable: true | |
gcode: | |
ACCEPT | |
[menu __main __cal __calibratez __abort] | |
type: command | |
name: Abort | |
enable: true | |
gcode: | |
ABORT | |
[menu __main __cal __calibratez __save_config] | |
type: command | |
name: Save config | |
enable: true | |
gcode: | |
SAVE_CONFIG | |
[menu __main __cal __calibratez __minus] | |
type: command | |
name: "-" | |
enable: true | |
gcode: | |
TESTZ Z=- | |
[menu __main __cal __calibratez __minus_minus] | |
type: command | |
name: "--" | |
enable: true | |
gcode: | |
TESTZ Z=-- | |
[menu __main __cal __calibratez __plus] | |
type: command | |
name: "+" | |
enable: true | |
gcode: | |
TESTZ Z=+ | |
[menu __main __cal __calibratez __plus_plus] | |
type: command | |
name: "++" | |
enable: true | |
gcode: | |
TESTZ Z=++ | |
[menu __main __cal __calibratez __minus_1] | |
type: command | |
name: "-1.0" | |
enable: true | |
gcode: | |
TESTZ Z=-1 | |
[menu __main __cal __calibratez __plus_1] | |
type: command | |
name: "+1.0" | |
enable: true | |
gcode: | |
TESTZ Z=+1 | |
[menu __main __cal __calibratez __minus_point_1] | |
type: command | |
name: "-0.1" | |
enable: true | |
gcode: | |
TESTZ Z=-0.1 | |
[menu __main __cal __calibratez __plus_point_1] | |
type: command | |
name: "+0.1" | |
enable: true | |
gcode: | |
TESTZ Z=+0.1 | |
#*# <---------------------- SAVE_CONFIG ----------------------> | |
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated. | |
#*# | |
#*# [bltouch] | |
#*# z_offset = 2.651 | |
#*# | |
#*# [bed_mesh default] | |
#*# version = 1 | |
#*# points = | |
#*# 0.053333, 0.032500, 0.040833, 0.002500, 0.044167 | |
#*# 0.002500, 0.012500, 0.020000, 0.014167, 0.030833 | |
#*# 0.004167, 0.015000, 0.034167, 0.006667, 0.037500 | |
#*# 0.021667, 0.042500, 0.050000, 0.037500, 0.045000 | |
#*# 0.012500, 0.019167, 0.031667, -0.005000, 0.029167 | |
#*# x_count = 5 | |
#*# y_count = 5 | |
#*# mesh_x_pps = 2 | |
#*# mesh_y_pps = 2 | |
#*# algo = bicubic | |
#*# tension = 0.2 | |
#*# min_x = 5.0 | |
#*# max_x = 192.0 | |
#*# min_y = 5.0 | |
#*# max_y = 187.0 | |
#*# | |
#*# [extruder] | |
#*# control = pid | |
#*# pid_kp = 21.564 | |
#*# pid_ki = 0.871 | |
#*# pid_kd = 133.429 | |
#*# | |
#*# [heater_bed] | |
#*# control = pid | |
#*# pid_kp = 72.936 | |
#*# pid_ki = 1.993 | |
#*# pid_kd = 667.362 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment