Last active
September 14, 2022 16:30
-
-
Save arrowcircle/ba8c293b1110ce76430aa745b38bcbc8 to your computer and use it in GitHub Desktop.
Oleg Klipper
This file contains 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
[include mainsail.cfg] | |
[mcu] | |
serial: /dev/serial/by-id/usb-Klipper_stm32g0b1xx_3F0057001050415833323520-if00 | |
[printer] | |
kinematics: corexy | |
max_velocity: 200 | |
max_accel: 3000 | |
max_z_velocity: 15 | |
max_z_accel: 200 | |
square_corner_velocity: 5.0 | |
[fan] | |
# FAN0 | |
pin: PD2 | |
max_power: 1.0 | |
kick_start_time: 0.5 # Depending on your fan, you may need to increase this value if your fan will not start | |
off_below: 0.16 | |
cycle_time: 0.010 | |
[heater_fan hotend_fan] | |
# FAN1 | |
pin: PD4 | |
max_power: 1.0 | |
kick_start_time: 0.5 | |
heater: extruder | |
heater_temp: 50.0 | |
cycle_time: 0.010 | |
#fan_speed: 1.0 # You can't PWM the delta fan unless using blue wire | |
[fan_generic fan2] | |
# FAN2 | |
pin: PD3 | |
max_power: 1.0 | |
kick_start_time: 0.5 # Depending on your fan, you may need to increase this value if your fan will not start | |
off_below: 0.13 | |
[idle_timeout] | |
timeout: 1800 | |
##################################################################### | |
# X/Y Stepper Settings | |
##################################################################### | |
[stepper_x] | |
step_pin: PC6 | |
## Refer to https://docs.vorondesign.com/build/startup/#v0 | |
dir_pin: PA14 # Check motor direction in link above. If inverted, add a ! before PB12 | |
enable_pin: !PC7 | |
rotation_distance: 40 | |
microsteps: 16 | |
full_steps_per_rotation: 400 # Set to 400 for 0.9° degree stepper motor, 200 is for 1.8° stepper motors | |
endstop_pin: ^PC0 | |
position_endstop: 0 | |
position_max: 195 | |
homing_speed: 50 # Can be increased after initial setup, Max 100 | |
homing_retract_dist: 5 | |
homing_positive_dir: false | |
[tmc2209 stepper_x] | |
uart_pin: PB12 | |
interpolate: True | |
run_current: 0.5 | |
sense_resistor: 0.110 | |
stealthchop_threshold: 999999 # Set to 999999 to turn stealthchop on, and 0 to use spreadcycle | |
[stepper_y] | |
step_pin: PB10 | |
## Refer to https://docs.vorondesign.com/build/startup/#v0 | |
dir_pin: PB2 # Check motor direction in link above. If inverted, add a ! before PB2 | |
enable_pin: !PB11 | |
rotation_distance: 40 | |
microsteps: 16 | |
full_steps_per_rotation: 400 # Set to 400 for 0.9° degree stepper motor, 200 is for 1.8° stepper motors | |
endstop_pin: ^PC1 | |
position_endstop: 0 | |
position_max: 1195 | |
homing_speed: 50 # Can be increased after initial setup, Max 100 | |
homing_retract_dist: 5 | |
homing_positive_dir: false | |
[tmc2209 stepper_y] | |
uart_pin: PC10 | |
interpolate: True | |
run_current: 0.5 | |
sense_resistor: 0.110 | |
stealthchop_threshold: 999999 # Set to 999999 to turn stealthchop on, and 0 to use spreadcycle # Set to 999999 to turn stealthchop on, and 0 to use spreadcycle | |
##################################################################### | |
# Z Stepper Settings | |
##################################################################### | |
[stepper_z] | |
step_pin: PB0 | |
dir_pin: PC5 # Remove the ! before PC5 if motor direction is inverted. | |
enable_pin: !PB1 | |
rotation_distance: 8 # For T8x8 integrated lead screw | |
microsteps: 16 | |
endstop_pin: ^PC2 | |
position_endstop: 209 | |
position_max: 209 | |
position_min: 0 | |
homing_speed: 20 | |
second_homing_speed: 3.0 | |
homing_retract_dist: 3.0 | |
[tmc2209 stepper_z] | |
uart_pin: PC9 | |
interpolate: True | |
## For OMC (StepperOnline) 17LS13-0404E-200G 0.4A | |
#run_current: 0.2 | |
## For LDO-42STH25-1004CL200E 1.0A | |
run_current: 0.5 | |
sense_resistor: 0.110 | |
stealthchop_threshold: 999999 # Set to 999999 to turn stealthchop on, and 0 to use spreadcycle # Set to 999999 to turn stealthchop on, and 0 to use spreadcycle | |
##################################################################### | |
# Extruder | |
##################################################################### | |
[extruder] | |
step_pin: PB3 | |
dir_pin: !PB4 # Add ! if moving opposite direction | |
enable_pin: !PD5 | |
full_steps_per_rotation: 400 # Set to 200 for LDO 1.8° stepper motor, and set to 400 for OMC(StepperOnline) 0.9° stepper motor | |
rotation_distance: 15.7 # 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 | |
## Check what thermistor type you have. See https://www.klipper3d.org/Config_Reference.html#common-thermistors for common thermistor types. | |
## Use "Generic 3950" for NTC 100k 3950 thermistors | |
sensor_type: PT1000 | |
sensor_pin: PA0 | |
#control: pid # Do PID calibration after initial checks | |
#pid_Kp: 28.182 | |
#pid_Ki: 1.978 | |
#pid_Kd: 100.397 | |
min_temp: 0 | |
max_temp: 270 | |
min_extrude_temp: 170 | |
max_extrude_only_distance: 150 | |
max_extrude_cross_section: 0.8 | |
pressure_advance: 0.0 # See tuning pressure advance doc | |
pressure_advance_smooth_time: 0.040 | |
[tmc2209 extruder] | |
uart_pin: PA13 | |
interpolate: True | |
## For OMC (StepperOnline) 14HR07-1004VRN 1A 0.9° | |
#run_current: 0.5 # for OMC 14HR07-1004VRN rated at 1A | |
## For LDO LDO 36STH17-1004AHG 1A 1.8° | |
run_current: 0.3 # for LDO 36STH17-1004AHG | |
## For LDO LDO 36STH20-1004AHG 1A 1.8° | |
#run_current: 0.6 # for LDO 36STH20-1004AHG | |
sense_resistor: 0.110 | |
stealthchop_threshold: 999999 # Set to 0 for spreadcycle, avoid using stealthchop on extruder | |
##################################################################### | |
# Bed Heater | |
##################################################################### | |
[heater_bed] | |
heater_pin: PD8 | |
## Check what thermistor type you have. See https://www.klipper3d.org/Config_Reference.html#common-thermistors for common thermistor types. | |
## Use "Generic 3950" for Keenovo heaters | |
sensor_type: Honeywell 100K 135-104LAG-J01 | |
sensor_pin: PC4 | |
smooth_time: 3.0 | |
#max_power: 0.6 # Only needed for 100w pads | |
min_temp: 0 | |
max_temp: 120 | |
#control: pid # Do PID calibration after initial checks | |
#pid_kp: 68.453 | |
#pid_ki: 2.749 | |
#pid_kd: 426.122 | |
##################################################################### | |
# Macros | |
##################################################################### | |
[gcode_macro PRINT_START] | |
# Use PRINT_START for the slicer starting script - please customize for your slicer of choice | |
gcode: | |
G28 ; home all axes | |
G1 Z20 F3000 ; move nozzle away from bed | |
[gcode_macro PRINT_END]0 | |
# 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 F150 ; 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-40 F1800 ; retract some, but not too much or it will jam | |
M82 ; set extruder to absolute | |
#*# <---------------------- SAVE_CONFIG ----------------------> | |
#*# DO NOT EDIT THIS BLOCK OR BELOW. The contents are auto-generated. | |
#*# | |
#*# [extruder] | |
#*# control = pid | |
#*# pid_kp = 20.432 | |
#*# pid_ki = 0.846 | |
#*# pid_kd = 123.356 | |
#*# | |
#*# [heater_bed] | |
#*# control = pid | |
#*# pid_kp = 74.350 | |
#*# pid_ki = 1.669 | |
#*# pid_kd = 828.070 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment