# Servo Z-Probe - Unable to retract because still in contact with bed after beeing triggered

**URL:** <https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614>\
**Category:** General Discussion\
**Created:** [July 12, 2024, 6:40pm UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614 "2024-07-12T18:40:48Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![groomit](https://avatars.discourse-cdn.com/v4/letter/g/43a26b/32.png) [@groomit](https://klipper.discourse.group/u/groomit)\
**Post date:** [July 12, 2024, 6:40pm UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/1 "2024-07-12T18:40:48Z")

</div>

### Basic Information:

Printer Model: Fabtotum  
 MCU / Printerboard: RAMPS like “Totumduino”  
 Host / SBC: Raspberry Pi 3B  
 klippy.log  
[klippy(1).log](https://klipper.discourse.group/uploads/short-url/oq8qi8D4IrWQILooy2aGuUgdzlX.log) (2.2 MB)

### Describe your issue:

I successfully implemented control for a servo controlled Z-Probe installed in the X-carriage. It is basically a needle with one end attached to the servo. By successful I mean I am able to manually retract and extend the probe to the desired angle. The endstop is triggering upon contact.

However, when probing for example using PROBE command or PROBE\_CALIBRATE command the bed and probe are still in contact when the probe is triggered. So the servo is not able to retract the probe. I would expect the head to lift a small amount for the probe to be freely movable.

I tried to lift the head a small amount within the probe end-gcode. But this way i get an error when probing with PROBE\_CALIBRATE stating something like “Z axis moved before probe end”.

I looked at the probe sample config.  
I scanned through the documentation reference.

Being aware that this type of probe is quite primitive, I can’t believe there is no clean solution for that. Any suggestions from the community?

---

<div class="post-metadata">

**Author:** ![EddyMI3D](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/eddymi3d/32/1981_2.png) [@EddyMI3D](https://klipper.discourse.group/u/EddyMI3D)\
**Post date:** [July 12, 2024, 6:50pm UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/2 "2024-07-12T18:50:48Z")

</div>

Hello @groomit !

Any chance you could attach the klippy.log to your **next post**?

---

<div class="post-metadata">

**Author:** ![groomit](https://avatars.discourse-cdn.com/v4/letter/g/43a26b/32.png) [@groomit](https://klipper.discourse.group/u/groomit)\
**Post date:** [July 12, 2024, 7:04pm UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/3 "2024-07-12T19:04:20Z")

</div>

Sure thing, here you go.  
Did not have physical access to the printer to turn it on and download  
[klippy(1).log](https://klipper.discourse.group/uploads/short-url/oq8qi8D4IrWQILooy2aGuUgdzlX.log) (2.2 MB)  
upon posting.

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [July 13, 2024, 6:17pm UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/4 "2024-07-13T18:17:42Z")

</div>

> [@groomit](#):
>
> However, when probing for example using PROBE command or PROBE\_CALIBRATE command the bed and probe are still in contact when the probe is triggered. So the servo is not able to retract the probe. I would expect the head to lift a small amount for the probe to be freely movable.

Not sure that I fully understand but sounds a bit like BTT’s MicroProbe. The relevant settings are:

```auto
[output_pin probe_enable]
pin: P2.0
value: 0

[gcode_macro Probe_Deploy]
gcode:
    SET_PIN PIN=probe_enable VALUE=1

[gcode_macro Probe_Stow]
gcode:
    SET_PIN PIN=probe_enable VALUE=0

[probe]
pin: !P1.27
deactivate_on_each_sample: False
...
activate_gcode:
    Probe_Deploy
    G4 P500 # Allow 500 milliseconds for the probe to deploy
deactivate_gcode:
    Probe_Stow

```

---

<div class="post-metadata">

**Author:** ![groomit](https://avatars.discourse-cdn.com/v4/letter/g/43a26b/32.png) [@groomit](https://klipper.discourse.group/u/groomit)\
**Post date:** [July 13, 2024, 6:46pm UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/5 "2024-07-13T18:46:51Z")

</div>

Thanks for your reply. Not quite the same. The BTT, like the BLTouch has a linear motion.  
On my Setup there is a servo inside the carriage that that moves a needle probe from 0° (retracted) to 90° (extended). It’s a rotating movement. Think of it like one leg of a scissor.

So in order to retract, the probe needs to be rotated back to its 0° position. Because the bed is still touching the probe, the servo is not able to move it.

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [July 13, 2024, 7:29pm UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/6 "2024-07-13T19:29:32Z")

</div>

> [@groomit](#):
>
> The BTT, like the BLTouch has a linear motion.

I wasn’t very clear, sorry: I’m not referring to the motion but to the process flow of the probing.

Klipper by default has a [sample\_retract\_dist](https://www.klipper3d.org/Config_Reference.html#probe) of 2 mm, so it should backoff after each probe trigger. It is not clear, why it does not do it in your case.  
Does setting `deactivate_on_each_sample: false` change anything?

---

<div class="post-metadata">

**Author:** ![groomit](https://avatars.discourse-cdn.com/v4/letter/g/43a26b/32.png) [@groomit](https://klipper.discourse.group/u/groomit)\
**Post date:** [July 14, 2024, 7:02am UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/7 "2024-07-14T07:02:11Z")

</div>

> I wasn’t very clear, sorry: I’m not referring to the motion but to the process flow of the probing.

Ah I see.  
Unfortunately it does not change anything.  
 ![z-homing - probe stuck to bed](https://global.discourse-cdn.com/free1/uploads/klipper/original/2X/0/031b99665a321310c2f2472acaf2cfae3a421554.gif)

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [July 14, 2024, 8:29am UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/8 "2024-07-14T08:29:55Z")

</div>

Are you sure you are getting a trigger signal?

---

<div class="post-metadata">

**Author:** ![groomit](https://avatars.discourse-cdn.com/v4/letter/g/43a26b/32.png) [@groomit](https://klipper.discourse.group/u/groomit)\
**Post date:** [July 14, 2024, 8:59am UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/9 "2024-07-14T08:59:36Z")

</div>

Yes I’m sure. You can see that the bed triggers the probe, then backs off and approaches the probe slower again. Standard homing procedure.  
Query\_probe returns triggered, when the probe is pushed.

---

<div class="post-metadata">

**Author:** ![Sineos](https://yyz2.discourse-cdn.com/free1/user_avatar/klipper.discourse.group/sineos/32/18_2.png) [@Sineos](https://klipper.discourse.group/u/Sineos)\
**Post date:** [July 14, 2024, 1:13pm UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/10 "2024-07-14T13:13:15Z")

</div>

Sorry, no further idea.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/free1/uploads/klipper/original/1X/64419bf2aac6639e6ef5cef200dcd456b0a01ac3.png) [@system](https://klipper.discourse.group/u/system)\
**Post date:** [September 12, 2024, 1:13pm UTC](https://klipper.discourse.group/t/servo-z-probe-unable-to-retract-because-still-in-contact-with-bed-after-beeing-triggered/17614/11 "2024-09-12T13:13:49Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
