endstop_phase: Move endstop phase homing code to new "extras" module
Move the endstop phase tracking code from stepper.py to a new extras/endstop_phase.py module. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
@@ -322,33 +322,34 @@
|
||||
# axis is triggered.
|
||||
|
||||
|
||||
# Stepper phase adjusted endstops. The following additional parameters
|
||||
# may be added to a stepper axis definition to improve the accuracy of
|
||||
# endstop switches.
|
||||
#[stepper_z]
|
||||
#homing_stepper_phases:
|
||||
# One may set this to the number of phases of the stepper motor
|
||||
# driver (which is the number of micro-steps multiplied by
|
||||
# four). This parameter must be provided if using stepper phase
|
||||
# adjustments.
|
||||
#homing_endstop_accuracy: 0.200
|
||||
# Stepper phase adjusted endstops. To use this feature, define a
|
||||
# config section with an "endstop_phase" prefix followed by the name
|
||||
# of the corresponding stepper config section (for example,
|
||||
# "[endstop_phase stepper_z]"). This feature can improve the accuracy
|
||||
# of endstop switches.
|
||||
#[endstop_phase stepper_z]
|
||||
#phases:
|
||||
# Set this to the number of phases of the given stepper motor driver
|
||||
# (which is the number of micro-steps multiplied by four). This
|
||||
# parameter must be provided.
|
||||
#endstop_accuracy: 0.200
|
||||
# Sets the expected accuracy (in mm) of the endstop. This represents
|
||||
# the maximum error distance the endstop may trigger (eg, if an
|
||||
# endstop may occasionally trigger 100um early or up to 100um late
|
||||
# then set this to 0.200 for 200um). The default is
|
||||
# homing_stepper_phases*step_distance.
|
||||
#homing_endstop_phase:
|
||||
# phases*step_distance.
|
||||
#endstop_phase:
|
||||
# This specifies the phase of the stepper motor driver to expect
|
||||
# when hitting the endstop. Only set this value if one is sure the
|
||||
# stepper motor driver is reset every time the mcu is reset. If this
|
||||
# is not set, then the stepper phase will be detected on the first
|
||||
# home and that phase will be used on all subsequent homes.
|
||||
#homing_endstop_align_zero: False
|
||||
# If true then the code will arrange for the zero position on the
|
||||
# axis to occur at a full step on the stepper motor. (If used on the
|
||||
# Z axis and the print layer height is a multiple of a full step
|
||||
# distance then every layer will occur on a full step.) The default
|
||||
# is False.
|
||||
#endstop_align_zero: False
|
||||
# If true then the position_endstop of the axis will effectively be
|
||||
# modified so that the zero position for the axis occurs at a full
|
||||
# step on the stepper motor. (If used on the Z axis and the print
|
||||
# layer height is a multiple of a full step distance then every
|
||||
# layer will occur on a full step.) The default is False.
|
||||
|
||||
|
||||
# Heater cooling fans (one may define any number of sections with a
|
||||
|
||||
@@ -12,8 +12,10 @@ endstop_pin: ^!PB6
|
||||
position_endstop: 0.0
|
||||
position_max: 200
|
||||
homing_speed: 50
|
||||
homing_stepper_phases: 32
|
||||
homing_endstop_accuracy: .200
|
||||
|
||||
[endstop_phase stepper_x]
|
||||
phases: 32
|
||||
endstop_accuracy: .200
|
||||
|
||||
[stepper_y]
|
||||
step_pin: PC1
|
||||
@@ -24,8 +26,10 @@ endstop_pin: ^!PB5
|
||||
position_endstop: 0.0
|
||||
position_max: 250
|
||||
homing_speed: 50
|
||||
homing_stepper_phases: 32
|
||||
homing_endstop_accuracy: .200
|
||||
|
||||
[endstop_phase stepper_y]
|
||||
phases: 32
|
||||
endstop_accuracy: .200
|
||||
|
||||
[stepper_z]
|
||||
step_pin: PC2
|
||||
@@ -37,8 +41,10 @@ position_min: 0.1
|
||||
position_endstop: 0.7
|
||||
position_max: 200
|
||||
homing_retract_dist: 2.0
|
||||
homing_stepper_phases: 32
|
||||
homing_endstop_accuracy: .070
|
||||
|
||||
[endstop_phase stepper_z]
|
||||
phases: 32
|
||||
endstop_accuracy: .070
|
||||
|
||||
[extruder]
|
||||
step_pin: PC3
|
||||
|
||||
Reference in New Issue
Block a user