First off, a "real" microswitch costs only about $0.50 if you buy them on
eBay 10 at a time and on Amazon Prime, I paid about double that.  What you
want is repeatability and microswitches are good at that to better than
0.001 inch.   Test your push buttons to see if they always click on/off at
the same amount of depression.  They might be really good or really poor.

Next, you need to decide how to handle contact bounce.  The switch will
open and close perhaps a dozen times when ever it changes state.   If the
goal is to stop quickly you don't want the software to see a bouncing
switch.   Or for the first few milliseconds, the software will see "home"
and stoart slowing only to see "not home" and continue searching and flip
about a dozen times before seeing a solid signal.     SOme switches are
MUCH better and some are much worse.     I just tested a bunch of mine.   I
got the best performance from a small micro switch with a resistor and very
small capacitor soldered across the terminals.  It changed state in a few
nanoseconds, others were as bad as 20 milliseconds.    Yes, a factor of
about 100,000 different.

How to know if you are skipping steps with an open loop stepper?   Measure
where to table stops AFTER it stops.  If steps were skipped it will
overshoot the mark.  But you need to find a way to measure one step of
travel. Maybe clamp a block to the table and measure the distance to
spindle but with spindle just above the block?
Make it stop quicker un till it overshoots then divide the speed by maybe
two.    Do the testing with a typical weight bolted to the table to
simulate the weight of a part.

Also, if you are trying to stop WAY to fast, you will hear the
motor skipping steps.    But don't depend on that because I doubt you could
hear just one missed step.

How to mount the switch.   A real micro switch can have a roller on a
lever.  Mount the switch so that a cam or "bump" on the table triggers the
switch the roller reduces friction as the cam passes.   If overshoot no
longer matters you can mount the switch at the center of the table, not on
the end.

One more idea uses two switches.  Switch one trips about an inch before the
real home switch and simply tells the software to "slow down".

The other way to just to ram the home switch at full speed. The machine
stops, likely after overrunning the home position.  But then it backs up
about 1/4 inch and approaches the switch very slowly.     I have seen
systems where it repeats this backoff and then go slow perhaps three times
and then takes an average of all three positions.   Or if one of the three
positions is not a good match to the other two raise an error.

But in all cases mount the switch to the side so that a software error does
not destroy the switch.    Then if you like, build a "'safety stop" switch
that the software never sees.  It simply disables the motor if tripped.
 (the "step" pulse has to go through an NC switch.) This could be mounted
on a spring or block of foam.  Even 1mm accuracy is overkill for this
safety-stop.





On Sun, Mar 31, 2019 at 7:02 AM Gene Heskett <ghesk...@shentel.net> wrote:

> Greetings everybody;
>
> I think I've got the coolant pump starting problem fixed.  Ignore that
> faint knocking sound.
>
> Now I would like to use a teeny little pushbutton (6x6x2.5mm tall)
> between two solid parts of this machine for home and potentially as
> limit switches.
>
> However the amount of available overtravel after the switch has clicked
> is quite limited unless this switch is mounted on something crushable so
> that the getting stopped overtravel does not crush the switch like a
> Coors can.
>
> Is there a way to determine how much overtravel vs approach speeds is
> occuring?
>
> I ask because a wide open x or y move  can do around 220 ipm on this
> machine, and that stopping distance is not an ignoreable distance when
> the switch only has maybe .010" of overtravel after its clicked.
>
> So I first would like to determine the maximum safe SEARCH_VEL I can use
> for homeing, then from that, be able to set MAX and MIN LIMITS far
> enough away from the crash stop to provide crash protection in the space
> between the LIMIT set in the ini file, or how much crush room I have to
> build into the switch mount?
>
> Also, in attempting to minimize this stopping distance, what or how can
> one detect a motor step slip if the ACCEL's are stopping the motor
> faster than it can stop? Hopefully without pounding a $90 dial into
> junk.
>
> Thanks all;
>
> Cheers, Gene Heskett
> --
> "There are four boxes to be used in defense of liberty:
>  soap, ballot, jury, and ammo. Please use in that order."
> -Ed Howdershelt (Author)
> Genes Web page <http://geneslinuxbox.net:6309/gene>
>
>
>
> _______________________________________________
> Emc-users mailing list
> Emc-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-users
>


-- 

Chris Albertson
Redondo Beach, California

_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to