Autocommit from 2025-11-24 15:20:03
Klipper version: v0.13.0-403-gb4c7cf4a Moonraker version: v0.9.3-125-g3129d89 Mainsail version: v2.14.0
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
# Below you can include specific configuration files depending on what you want KAMP to do:
|
# Below you can include specific configuration files depending on what you want KAMP to do:
|
||||||
|
|
||||||
[include ./KAMP/Adaptive_Meshing.cfg] # Include to enable adaptive meshing configuration.
|
# [include ./KAMP/Adaptive_Meshing.cfg] # Include to enable adaptive meshing configuration.
|
||||||
# [include ./KAMP/Line_Purge.cfg] # Include to enable adaptive line purging configuration.
|
# [include ./KAMP/Line_Purge.cfg] # Include to enable adaptive line purging configuration.
|
||||||
[include ./KAMP/Voron_Purge.cfg] # Include to enable adaptive Voron logo purging configuration.
|
[include ./KAMP/Voron_Purge.cfg] # Include to enable adaptive Voron logo purging configuration.
|
||||||
[include ./KAMP/Smart_Park.cfg] # Include to enable the Smart Park function, which parks the printhead near the print area for final heating.
|
[include ./KAMP/Smart_Park.cfg] # Include to enable the Smart Park function, which parks the printhead near the print area for final heating.
|
||||||
|
|||||||
@@ -1,164 +0,0 @@
|
|||||||
[gcode_macro BED_MESH_CALIBRATE]
|
|
||||||
variable_buffer: 20
|
|
||||||
rename_existing: _BED_MESH_CALIBRATE
|
|
||||||
; Do not change any of the existing values below.
|
|
||||||
variable_last_area_start_x: -1 ; Do not change
|
|
||||||
variable_last_area_start_y: -1 ; Do not change
|
|
||||||
variable_last_area_end_x: -1 ; Do not change
|
|
||||||
variable_last_area_end_y: -1 ; Do not change
|
|
||||||
variable_probing:False
|
|
||||||
|
|
||||||
gcode:
|
|
||||||
STATUS_MESHING
|
|
||||||
SET_GCODE_VARIABLE MACRO=_KNOMI_STATUS VARIABLE=probing VALUE=True
|
|
||||||
|
|
||||||
{% if params.FORCE_NEW_MESH != null %}
|
|
||||||
{ action_respond_info("Force New Mesh: %s" % (params.FORCE_NEW_MESH)) }
|
|
||||||
{% endif %}
|
|
||||||
{% if printer["bed_mesh"].profile_name == '' %}
|
|
||||||
{ action_respond_info("No existing bed mesh found.") }
|
|
||||||
{% set last_area_end_x=-1 %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if printer.toolhead.homed_axes != "xyz" %}
|
|
||||||
G28
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% set klicky_available = printer['gcode_macro _Probe_Variables'] != null %}
|
|
||||||
{% set euclid_available = printer['gcode_macro EuclidProbe'] != null %}; Requires v5 macros https://github.com/nionio6915/Euclid_Probe/blob/main/Firmware_Examples/Klipper/00-euclid_exampleV5.cfg
|
|
||||||
{% if params.PRINT_MIN %}
|
|
||||||
{ action_respond_info("print_min: %s" % params.PRINT_MIN) }
|
|
||||||
{ action_respond_info("print_max: %s" % params.PRINT_MAX) }
|
|
||||||
|
|
||||||
{% set blTouchConfig = printer['configfile'].config["bltouch"] %}
|
|
||||||
{% if blTouchConfig %}
|
|
||||||
{% set OffsetX = blTouchConfig.x_offset|default(0)|float %}
|
|
||||||
{% set OffsetY = blTouchConfig.y_offset|default(0)|float %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% set probeConfig = printer['configfile'].config["probe"] %}
|
|
||||||
{% if probeConfig %}
|
|
||||||
{% set OffsetX = probeConfig.x_offset|default(0)|float %}
|
|
||||||
{% set OffsetY = probeConfig.y_offset|default(0)|float %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% set print_min_x = params.PRINT_MIN.split(",")[0]|float %}
|
|
||||||
{% set print_min_y = params.PRINT_MIN.split(",")[1]|float %}
|
|
||||||
{% set print_max_x = params.PRINT_MAX.split(",")[0]|float %}
|
|
||||||
{% set print_max_y = params.PRINT_MAX.split(",")[1]|float %}
|
|
||||||
|
|
||||||
{% if last_area_start_x > 0 %}
|
|
||||||
{ action_respond_info("last_bed_mesh: %s,%s %s,%s" % (last_area_start_x, last_area_start_y, last_area_end_x, last_area_end_y)) }
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if (params.FORCE_NEW_MESH != null) or (print_min_x < last_area_start_x) or (print_max_x > last_area_end_x) or (print_min_y < last_area_start_y) or (print_max_y > last_area_end_y) %}
|
|
||||||
{% if klicky_available %}
|
|
||||||
_CheckProbe action=query
|
|
||||||
Attach_Probe
|
|
||||||
{% elif euclid_available %}
|
|
||||||
DEPLOY_PROBE
|
|
||||||
{% endif %}
|
|
||||||
{% if (print_min_x < print_max_x) and (print_min_y < print_max_y) %}
|
|
||||||
|
|
||||||
# Get bed_mesh config (probe count, mesh_min and mesh_max for x and y
|
|
||||||
{% set bedMeshConfig = printer['configfile'].config["bed_mesh"] %}
|
|
||||||
{% set minimum_probe_count = 3 %}
|
|
||||||
{% if bedMeshConfig.algorithm == "bicubic" %}
|
|
||||||
{% set minimum_probe_count = 5 %}
|
|
||||||
{% endif %}
|
|
||||||
{% set probe_count = bedMeshConfig.probe_count.split(",") %}
|
|
||||||
{% set probe_count_x = probe_count[0]|int %}
|
|
||||||
{% if probe_count.__len__() > 1 %}
|
|
||||||
{% set probe_count_y = probe_count[1]|int %}
|
|
||||||
{% else %}
|
|
||||||
{% set probe_count_y = probe_count_x|int %}
|
|
||||||
{% endif %}
|
|
||||||
{% set relative_reference_index = bedMeshConfig.relative_reference_index %}
|
|
||||||
{% set mesh_min_x = bedMeshConfig.mesh_min.split(",")[0]|float %}
|
|
||||||
{% set mesh_min_y = bedMeshConfig.mesh_min.split(",")[1]|float %}
|
|
||||||
{% set mesh_max_x = bedMeshConfig.mesh_max.split(",")[0]|float %}
|
|
||||||
{% set mesh_max_y = bedMeshConfig.mesh_max.split(",")[1]|float %}
|
|
||||||
|
|
||||||
# If print area X is smaller than 50% of the bed size, change to to 3 probe counts for X instead of the default
|
|
||||||
{% if print_max_x - print_min_x < (mesh_max_x - mesh_min_x) * 0.50 %}
|
|
||||||
{% set probe_count_x = minimum_probe_count %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
# If print area Y is smaller than 50% of the bed size, change to to 3 probe counts for Y instead of the default
|
|
||||||
{% if print_max_y - print_min_y < (mesh_max_y - mesh_min_y) * 0.50 %}
|
|
||||||
{% set probe_count_y = minimum_probe_count %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if print_min_x - buffer >= mesh_min_x %}
|
|
||||||
{% set mesh_min_x = print_min_x - buffer %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if print_min_y - buffer >= mesh_min_y %}
|
|
||||||
{% set mesh_min_y = print_min_y - buffer %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if print_max_x + buffer <= mesh_max_x %}
|
|
||||||
{% set mesh_max_x = print_max_x + buffer %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if print_max_y + buffer <= mesh_max_y %}
|
|
||||||
{% set mesh_max_y = print_max_y + buffer %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{ action_respond_info("mesh_min: %s,%s" % (mesh_min_x, mesh_min_y)) }
|
|
||||||
{ action_respond_info("mesh_max: %s,%s" % (mesh_max_x, mesh_max_y)) }
|
|
||||||
{ action_respond_info("probe_count: %s,%s" % (probe_count_x,probe_count_y)) }
|
|
||||||
|
|
||||||
; Set variables so they're available outside of macro
|
|
||||||
SET_GCODE_VARIABLE MACRO=BED_MESH_CALIBRATE VARIABLE=last_area_start_x VALUE={print_min_x}
|
|
||||||
SET_GCODE_VARIABLE MACRO=BED_MESH_CALIBRATE VARIABLE=last_area_start_y VALUE={print_min_y}
|
|
||||||
SET_GCODE_VARIABLE MACRO=BED_MESH_CALIBRATE VARIABLE=last_area_end_x VALUE={print_max_x}
|
|
||||||
SET_GCODE_VARIABLE MACRO=BED_MESH_CALIBRATE VARIABLE=last_area_end_y VALUE={print_max_y}
|
|
||||||
|
|
||||||
{% if printer["gcode_macro status_meshing"] != null %}
|
|
||||||
status_meshing
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if relative_reference_index == 0 or relative_reference_index == null %}
|
|
||||||
_BED_MESH_CALIBRATE mesh_min={mesh_min_x},{mesh_min_y} mesh_max={mesh_max_x},{mesh_max_y} probe_count={probe_count_x},{probe_count_y}
|
|
||||||
{% else %}
|
|
||||||
{% set relative_reference_index = ((probe_count_x * probe_count_y - 1) / 2)|int %}
|
|
||||||
{ action_respond_info("relative_reference_index: %s" % relative_reference_index) }
|
|
||||||
_BED_MESH_CALIBRATE mesh_min={mesh_min_x},{mesh_min_y} mesh_max={mesh_max_x},{mesh_max_y} probe_count={probe_count_x},{probe_count_y} relative_reference_index={relative_reference_index}
|
|
||||||
{% endif %}
|
|
||||||
{% else %}
|
|
||||||
{% if printer["gcode_macro status_meshing"] != null %}
|
|
||||||
status_meshing
|
|
||||||
{% endif %}
|
|
||||||
_BED_MESH_CALIBRATE
|
|
||||||
{% endif %}
|
|
||||||
{% if klicky_available %}
|
|
||||||
Dock_Probe
|
|
||||||
{% elif euclid_available %}
|
|
||||||
STOW_PROBE
|
|
||||||
{% endif %}
|
|
||||||
{% else %}
|
|
||||||
{ action_respond_info("No need to recreate Bed Mesh since it's same as current mesh or smaller") }
|
|
||||||
{% endif %}
|
|
||||||
{% else %}
|
|
||||||
{% if klicky_available %}
|
|
||||||
_CheckProbe action=query
|
|
||||||
Attach_Probe
|
|
||||||
{% elif euclid_available %}
|
|
||||||
STOW_PROBE
|
|
||||||
{% endif %}
|
|
||||||
{% if printer["gcode_macro status_meshing"] != null %}
|
|
||||||
STATUS_MESHING
|
|
||||||
{% endif %}
|
|
||||||
_BED_MESH_CALIBRATE
|
|
||||||
{% if klicky_available %}
|
|
||||||
Dock_Probe
|
|
||||||
{% endif %}
|
|
||||||
{% if euclid_available %}
|
|
||||||
STOW_PROBE
|
|
||||||
{% endif %}
|
|
||||||
{% endif %}
|
|
||||||
{% if printer["gcode_macro status_ready"] != null %}
|
|
||||||
STATUS_READY
|
|
||||||
{% endif %}
|
|
||||||
SET_GCODE_VARIABLE MACRO=_KNOMI_STATUS VARIABLE=probing VALUE=False
|
|
||||||
@@ -80,7 +80,7 @@ press_gcode:
|
|||||||
gcode:
|
gcode:
|
||||||
STATUS_MESHING
|
STATUS_MESHING
|
||||||
SET_GCODE_VARIABLE MACRO=_KNOMI_STATUS VARIABLE=probing VALUE=True
|
SET_GCODE_VARIABLE MACRO=_KNOMI_STATUS VARIABLE=probing VALUE=True
|
||||||
BED_MESH_CALIBRATE
|
BED_MESH_CALIBRATE ADAPTIVE=1
|
||||||
SET_GCODE_VARIABLE MACRO=_KNOMI_STATUS VARIABLE=probing VALUE=False
|
SET_GCODE_VARIABLE MACRO=_KNOMI_STATUS VARIABLE=probing VALUE=False
|
||||||
STATUS_READY
|
STATUS_READY
|
||||||
|
|
||||||
|
|||||||
@@ -24,7 +24,7 @@ shutdown_value: 1
|
|||||||
enable_pin: !PF14
|
enable_pin: !PF14
|
||||||
step_pin: PF13
|
step_pin: PF13
|
||||||
dir_pin: PF12
|
dir_pin: PF12
|
||||||
microsteps: 128
|
microsteps: 64
|
||||||
endstop_pin: tmc5160_stepper_x:virtual_endstop
|
endstop_pin: tmc5160_stepper_x:virtual_endstop
|
||||||
|
|
||||||
[tmc5160 stepper_x]
|
[tmc5160 stepper_x]
|
||||||
@@ -44,7 +44,7 @@ stealthchop_threshold: 0
|
|||||||
enable_pin: !PG5
|
enable_pin: !PG5
|
||||||
step_pin: PF11
|
step_pin: PF11
|
||||||
dir_pin: PG3
|
dir_pin: PG3
|
||||||
microsteps: 128
|
microsteps: 64
|
||||||
endstop_pin: tmc5160_stepper_y:virtual_endstop
|
endstop_pin: tmc5160_stepper_y:virtual_endstop
|
||||||
|
|
||||||
[tmc5160 stepper_y]
|
[tmc5160 stepper_y]
|
||||||
|
|||||||
@@ -193,13 +193,14 @@ speed: 450
|
|||||||
horizontal_move_z: 5
|
horizontal_move_z: 5
|
||||||
#mesh_min: 40, 40
|
#mesh_min: 40, 40
|
||||||
#mesh_max: 310,310
|
#mesh_max: 310,310
|
||||||
mesh_min: 35, 30
|
mesh_min: 30, 30
|
||||||
mesh_max: 316,308
|
mesh_max: 325,325
|
||||||
fade_start: 0.6
|
fade_start: 0.6
|
||||||
fade_end: 10.0
|
fade_end: 10.0
|
||||||
probe_count: 5,5 # Values should be odd, so one point is directly at bed center
|
probe_count: 5,5 # Values should be odd, so one point is directly at bed center
|
||||||
algorithm: bicubic
|
algorithm: bicubic
|
||||||
#relative_reference_index: 12 #40 #12 # Update when changing probe_count, to ((x points * y points) - 1) / 2. (the center point)
|
#relative_reference_index: 12 #40 #12 # Update when changing probe_count, to ((x points * y points) - 1) / 2. (the center point)
|
||||||
|
adaptive_margin: 5
|
||||||
|
|
||||||
|
|
||||||
[include macros/main.cfg]
|
[include macros/main.cfg]
|
||||||
|
|||||||
Reference in New Issue
Block a user