Why 0.7 Z offset in a probe?



  • If I define a probe with M558, and then execute G31 (with no arguments), I see:

    G31
    Current reading 0, threshold 500, trigger height 0.700, offsets X0.0 Y0.0

    Why is the trigger height 0.7?

    I realize I can G31 K0 X0 Y0 Z0... but if I do that, and then undefine the probe and redefine it (which I'm doing to zero a toolchanger in different ways), it is back to 0.7. Again, I realize that undefining the probe 'uncouples' it from the G31, or the G31 'goes away' when the probe is undefined... I'm not asking why that happens... I am asking why 0.7 is wired in there somewhere.

    Why 0.7? Why not 0.0?

    This was very surprising to me, and took a really long time (months) to track down, simply because I couldn't imagine that a newly defined 'thing' in RepRap would have a fixed bias.



  • @Danal i feel that defining g31 z0.25 in config.g has no effect. after a power cycle reboot g31 reports z =0.7. i'll check the effect of g31 z0.25 in config-override.g later today.



  • @spllg said in Why 0.7 Z offset in a probe?:

    @Danal i feel that defining g31 z0.25 in config.g has no effect. after a power cycle reboot g31 reports z =0.7. i'll check the effect of g31 z0.25 in config-override.g later today.

    At this moment, I have added a G31 K0 X0 Y0 Z0 in my config.g, and that does work across reboots, etc. Also, I dynamically re-define probes and endpoints in a script that is designed to calculate tool-to-tool alignment... and that script has been updated to issue G31 commands every time it redefines Z probes.

    Anyway, G31 in config.g is working for me.



  • @Danal Duet 3 6HC (v0.6) - RepRapFirmware 3.01-RC2 with RPi 4B - dwc 2.0.7-1?



  • Board: Duet 3 MB6HC (MB6HC)
    DSF Version: 1.2.4.0
    Firmware: RepRapFirmware for Duet 3 MB6HC v0.6 or 1.0 3.01-RC2 (2020-02-18b1)

    Duet Web Control 2.0.7



  • And, just checked, same thing on:

    Board: Duet WiFi 1.02 or later
    Firmware: RepRapFirmware for Duet 2 WiFi/Ethernet 2.05.1 (2020-02-09b1)
    Duet WiFi Server Version: 1.23



  • @Danal double checked: g31 z0.35 in config.g is ignored and g31 70.25 is honored when in config-overrige.g.

    curretnly i'm unable to do any further tests/checks because of https://forum.duet3d.com/topic/14614/unable-to-home-xyz-using-my-homing-scripts



  • So after that nice discussion about G31...

    Does anyone (hint: @DC42) know why probes have 0.7 Z offset, unless you override it?



  • OK, the physical, literal, reason is this line of code in module "RepRapFirmware/src/Platform.h"

    // Z PROBE
    
    constexpr float Z_PROBE_STOP_HEIGHT = 0.7;						// Millimetres
    

    But that begs the question: Why?

    P.S. That module's header says:

    Version 0.3
    28 August 2013
    Adrian Bowyer
    RepRap Professional Ltd
    http://reprappro.com

    So maybe I should be asking Adrian.


  • Moderator

    @Danal said in Why 0.7 Z offset in a probe?:

    OK, the physical, literal, reason is this line of code in module "RepRapFirmware/src/Platform.h"

    // Z PROBE
    
    constexpr float Z_PROBE_STOP_HEIGHT = 0.7;						// Millimetres
    

    But that begs the question: Why?

    P.S. That module's header says:

    Version 0.3
    28 August 2013
    Adrian Bowyer
    RepRap Professional Ltd
    http://reprappro.com

    So maybe I should be asking Adrian.

    It might be the value that was correct for the very first printer to use Duet, the RepRapPro Ormerod 1, which had an unmodulated IR sensor. I can't quite remember. But even that seems rather low.

    Ian



  • Got an answer from Adrian - for the curious ones 😉

    1e3fc30b-1e35-4978-bca8-6afc5ced2f7b-image.png


Log in to reply