Skip to content

Homing with contactless and contact probing together

Mark edited this page Dec 25, 2024 · 8 revisions

We can use the contactless probing at first with higher speed then use the contact probing at second homing with lower speed, that can reduce the time of the whole homing process.

Note

  1. Set the homing_retract_dist to 0, else the nozzle will crash into bed
[stepper_z]
.....
homing_speed: 8
second_homing_speed:2
homing_retract_dist:0

  1. Add the following macro G28
## the homing_retract_dist in the [stepper_z] must be 0
[gcode_macro G28]
rename_existing: G990028
gcode:
      {% if rawparams|length == 0 %}
           { action_respond_info("homing all") }
           G990028 X Y
           ## Homing with contactless probe with the homing_speed in [stepper_z]
           BDSENSOR_SET COLLISION_HOMING=0
           G990028 Z
           ## Homing with contact probe with the second_homing_speed in [stepper_z]
           BDSENSOR_SET COLLISION_HOMING=1
           G990028 Z
      {% else %}
            {% if 'x' in rawparams or 'X' in rawparams  %}
                 { action_respond_info("homing x") }
                 G990028 X
            {% endif %}
            {% if 'y' in rawparams or 'Y' in rawparams  %}
                 { action_respond_info("homing y") }
                 G990028 Y
            {% endif %}
            {% if 'z' in rawparams or 'Z' in rawparams  %}
                 { action_respond_info("homing z") }
                 ## Homing with contactless probe with the homing_speed in [stepper_z]
                 BDSENSOR_SET COLLISION_HOMING=0
                 G990028 Z
                 ## Homing with contact probe with the second_homing_speed in [stepper_z]
                 BDSENSOR_SET COLLISION_HOMING=1
                 G990028 Z
            {% endif %}
      {% endif %}

Tip

Here the speed of collision homing use the second_homing_speed,so please increase the the second_homing_speed if there is warning: triggered in air

Test video:https://youtu.be/90N1mQVQ4Oc