"in system" endstop repeatability test

I would like to do a repeatability test on my endstops.
Have you any way to do this on the printer itself, without having to modify the machine's hardware or software?

Even though I need to write simple software to do this test, but I will need some gcode command for this, is there?
Any command that can tell me the position from where the endstop was activated?
As a last option I can think of, that would be a bit trickier (or slower), but if it have a command that tells me the current status of the endstops I could move the Z (for example), check the state of the endstop and repeat this until it is enabled / disabled.
Thank you.

PS: Reasons for my interest:
1. I'm tired of leveling the table and I'm suspicious of my endstops that are really cheap.
2. I'm interested in exploring the possibilities and capabilities of the machine, perhaps even for other automation applications.


  • There is no function returning differences. You can send M111 S70 to see in log directly when end stops are triggered, but this can crash firmware if changes happen to fast in a row so output buffer overflows. So really just for testing. To make the test work you must have end stop testing enabled but then it will not execute all remaining steps when it is triggered. So moving 1mm up/down after a trigger during down will change position a bit higher. Consider this effect while testing.
  • Do you have any other idea for this?

    What about M119 command?
    I could move 0,1mm then do a M119, check and repeat until endstop is triggered.
    What do you think?

    Anyway, maybe this is a nice feature to implement in Repetier, I have heard that Marlin has it.
    Keep as suggestion ;)

  • M111 S70 is more or less the same as constantly sending M119 so makes it just easier.

    What would work is home and then test how far you need to move down to trigger end stop and repeat. G1 S1 disables target position check so you can also go to negative positions.
  • Well, lets try...
    I'm trying to send gcodes to the machine using Putty, printer reports some data then start repeating "wait", anything I send it start repeating "Resend:1

    I cant find anyone talking about this.
    Can you help me?
    There is a initialization protocol?
  • Connect with Repetier-Server or host to send gcodes. Putty is not a good choice - didn't even know it can do that. Thought is was only for ssh connections.
  • Putty can do serial connections too, but, anyway, I can write a software for it but I need to know how to initialize the printer, I'm sure you know how to do.
  • Just connect and send commands without line number and checksum. If you start using them it gets complicated. We send some commands to set current line number to what we have and query for capabilities, but that is not a must.

    Resend:1 means resend line 1. Happens on checksum mismatch but would mean there was a line 1 or it is what firmware expected as it gets initialized with that as well. Make sure printer resets on connect so you see communication begins with a "start" response of firmware. If not hit reset button on printer and then communicate.
    Normally toggling RTS line in communication will reset printer as well.
Sign In or Register to comment.