Skip to content

Instantly share code, notes, and snippets.

@justheath
Created April 22, 2023 15:50
Show Gist options
  • Save justheath/a2e2fe85a722a092c2ec79b4f3eb7114 to your computer and use it in GitHub Desktop.
Save justheath/a2e2fe85a722a092c2ec79b4f3eb7114 to your computer and use it in GitHub Desktop.
Ender 3 Pro config with Creality 4.2.7, TH3D EZABL, Sprite Extruder
# This file came from https://github.com/Klipper3d/klipper/blob/master/config/generic-creality-v4.2.7.cfg
# This file contains pin mappings for the Creality "v4.2.7" board. To
# use this config, during "make menuconfig" select the STM32F103 with
# a "28KiB bootloader" and serial (on USART1 PA10/PA9) communication.
# Flash this firmware by copying "out/klipper.bin" to a SD card and
# turning on the printer with the card inserted. The firmware
# filename must end in ".bin" and must not match the last filename
# that was flashed.
# Heath: I copied the firmware to an SD card and rebooted the printer.
# The printer LCD will not give any indication that the firmware update was successful.
# My hardware:
# - Ender 3 Pro
# - Creality silent board 4.2.7
# - Creality Sprite pro Extruder / Hotend
# - Th3d EZABL
# See docs/Config_Reference.md for a description of parameters.
# these are needed by mainsail macros
[gcode_macro _CLIENT_VARIABLE]
variable_use_custom_pos : False ; use custom park coordinates for x,y [True/False]
variable_custom_park_x : 0.0 ; custom x position; value must be within your defined min and max of X
variable_custom_park_y : 0.0 ; custom y position; value must be within your defined min and max of Y
variable_custom_park_dz : 2.0 ; custom dz value; the value in mm to lift the nozzle when move to park position
variable_retract : 1.0 ; the value to retract while PAUSE
variable_cancel_retract : 5.0 ; the value to retract while CANCEL_PRINT
variable_speed_retract : 35.0 ; retract speed in mm/s
variable_unretract : 1.0 ; the value to unretract while RESUME
variable_speed_unretract : 35.0 ; unretract speed in mm/s
variable_speed_hop : 15.0 ; z move speed in mm/s
variable_speed_move : 100.0 ; move speed in mm/s
variable_park_at_cancel : False ; allow to move the toolhead to park while execute CANCEL_PRINT [True,False]
## !!! Caution [firmware_retraction] must be defined in the printer.cfg if you set use_fw_retract: True !!!
variable_use_fw_retract : False ; use fw_retraction instead of the manual version [True/False]
gcode:
# --------------------------------------------------------------------
# Some configuration options are kept in other files - load them now
[include mainsail.cfg]
[include macros.cfg]
[mcu]
# using by-path because by-id fails to distinguish the two printers
# plugged into the USB on my ChromeBook
serial: /dev/serial/by-path/pci-0000:00:14.0-usb-0:2.4:1.0-port0
restart_method: command
[stepper_x]
step_pin: PB9
dir_pin: PC2
enable_pin: !PC3
microsteps: 16
rotation_distance: 40
endstop_pin: ^PA5
position_endstop: 0
position_max: 245
homing_speed: 50
[stepper_y]
step_pin: PB7
dir_pin: PB8
enable_pin: !PC3
microsteps: 16
rotation_distance: 40
endstop_pin: ^PA6
position_endstop: 0
position_max: 235
homing_speed: 50
[stepper_z]
step_pin: PB5
dir_pin: !PB6
enable_pin: !PC3
microsteps: 16
rotation_distance: 8
position_min: -1.25
position_max: 250
# because I use a probe
endstop_pin: probe: z_virtual_endstop
[probe]
# My EZABLE
speed: 10
samples: 2
pin: ^!PA7
# stock mount offsets
# x_offset: -44
# y_offset: -10
# Creality sprite offsets
x_offset: -44
y_offset: -42
# no z_offset - it's calculated w/ probe_calculate
[safe_z_home]
home_xy_position: 158.5,127.5
z_hop:5
# Reduced X because the Sprite interferes with the TH3D Dual-Z bracket
[screws_tilt_adjust]
screw1_name: Front Left
screw1: 69,75
screw2_name: Front Right
screw2: 210,75
screw3_name: Back Right
screw3: 210,230
screw4_name: Back Left
screw4: 69,230
speed: 50
screw_thread: CW-M4
[bed_mesh]
speed: 120
horizontal_move_z: 5
# Coordinates are relative to the probe's location
mesh_min: 10, 10
# probe is on the left, can only go so far right before maxing out
# Reduced X because the Sprite interferes with the TH3D Dual-Z bracket
mesh_max: 170, 190
probe_count: 5,5
algorithm: lagrange
[extruder]
# Only need to change this if go larger - it's only used to calculate max flow warnings
nozzle_diameter: 0.600
step_pin: PB3
dir_pin: PB4
enable_pin: !PC3
microsteps: 16
rotation_distance: 26.359
# sprite = 3.5:1
gear_ratio: 42:12
heater_pin: PA1
sensor_type: EPCOS 100K B57560G104F
sensor_pin: PC5
min_extrude_temp: 170
min_temp: 0
max_temp: 300
filament_diameter: 1.750
# DO NOT UNCOMMENT - These are automated at the end from a PID_CALIBRATE command
#control: pid
#pid_Kp: 21.527
#pid_Ki: 1.063
#pid_Kd: 108.982
[heater_bed]
heater_pin: PA2
sensor_type: EPCOS 100K B57560G104F
sensor_pin: PC4
min_temp: 0
max_temp: 130
# These are automated at the end from a PID_CALIBRATE command
#control: pid
#pid_Kp: 54.027
#pid_Ki: 0.770
#pid_Kd: 948.182
[fan]
pin: PA0
[printer]
kinematics: cartesian
max_velocity: 300
max_accel: 3000
max_z_velocity: 5
max_z_accel: 100
[board_pins]
aliases:
EXP1_1=PC6,EXP1_3=PB10,EXP1_5=PB14,EXP1_7=PB12,EXP1_9=<GND>,
EXP1_2=PB2,EXP1_4=PB11,EXP1_6=PB13,EXP1_8=PB15,EXP1_10=<5V>,
PROBE_IN=PB0,PROBE_OUT=PB1,FIL_RUNOUT=PC6
# This section is used for a Creality "12864" display with a single
# ribbon cable between the display's EXP3 plug and the
# micro-controller board's EXP1 connector.
[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
@MercilessWaysDesigns
Copy link

Hi I am very new to 3D printing and trying to figure out Klipper. I installed Linux Mint on an old laptop and I believe I have it all set but I need this printer.cfg file to install on the printer itself I believe is how it works? I have an Ender 3 Pro with a v4.2.7 board, the creality cr touch and the sprite extruder. Is this the exact file I am missing? Please say yes lol

@justheath
Copy link
Author

justheath commented Apr 21, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment