-
-
Notifications
You must be signed in to change notification settings - Fork 19.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Marlin "RCBugFix" ignores endstops after homing #4304
Comments
I can now confirm that Marlin isn't calling Endstops::update() at all when in the bugged state. (I had it toggle a pin for each call to the function and watched it on my scope. In normal operation I saw the expected square wave, but in the bugged post-home state, I did not.) |
And my search has led me to the advanced "ENDSTOPS_ONLY_FOR_HOMING", which defaults to true. I disabled it and am getting the expected behavior. Duh. My only remaining question is: why is ENDSTOPS_ONLY_FOR_HOMING the default? If you have a 3D printer, wouldn't you still want to stop at endstops instead of barreling through them? |
@tkbletsc There are a few facilities related to movement limiting.
It's historical. No one knows especially why. But we can try to justify it. First, it saves a little bit of CPU to ignore the endstops during a print (and outside of homing), unless you need them for a feature, so why not leave them off? When enabling And actually |
Thanks for the feedback! I can think of one reason to have the option disabled by default -- machines experiencing motion problems (missing steps, misconfiguration, etc.) can damage themselves if they blow past an end stop. I found it surprising because I tested my endstops extensively to avoid damage while I work on the machine, and I didn't notice the homing behavior until very late. It seems like a trap waiting to catch people doing a build, which is troubling since many people using Marlin are doing so on home-brew machines. As for the argument in favor, it doesn't seem very strong to me. What are we saving CPU for? It's not as though avoiding endstop checks makes the machine behave better, and we're not trying to save energy or CPU time -- it's not a cellphone. To me, it seems like a realtime system -- either meeting deadlines or not, and it clearly can meet deadlines while checking endstops. That said, I understand that changing a default option could impact machines everywhere in an unexpected way, so I'd understand if the default has to stay simply for historic compatibility for now. I just worry about new builds getting torn up...perhaps it could be considered for the next major version increment? |
That would be an entirely new feature, to have endstops limit motion generally, outside of SD printing. Of course we already have the feature to kill an SD print based on an endstop hit to deal with the unattended printer. The option is well known, and is disabled by default in a few of the example configurations according to vendor preference. To make the option more clear, at least, I am proposing #4306. |
It was default because several probe configurations did not work without it and because DELTAS react very allergic on unplanned detected endstop hits . There are several more issues with endstops, like
For now activating |
Thanks, this answers my question. |
I think one of the reasons we don't hear more about these things is that in general-use people print relatively small objects in the middle of the bed, so weird endstop triggers are very rare in the wild. |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
UPDATE: I'm dumb and didn't know about the "ENDSTOPS_ONLY_FOR_HOMING" option, which explains all of the below. Issue resolved.
I have a Mostly Printed CNC machine with a fairly normal configuration: RAMPS 1.4 board, near-stock configuration.h.
When I first boot the machine and have it move to an endstop, it triggers and stops successfully.
However, if I home the machine (G28), then have it move to an endstop, IT IGNORES THE ENDSTOP! This occurs on both X and Y axis in both positive and negative direction. Further, I've added debug output to Stepper::endstop_triggered, and in the bugged case, this function is apparently not called.
In all cases, the M119 command correctly prints the state of all endstop switches, so the firmware is getting the switch state properly, it's just not triggering a movement stoppage if moved after a homing operation.
To make clear the issue, I've recorded a brief video demoing the problem.
Also, here's my configuration file.
The text was updated successfully, but these errors were encountered: