Need more information. Are your limit switches also your home switches? It sound like that it your configuration.
yes the limit switches also my home
If your limit switches are also your home switches, how far does the machine move after it first hits the limit switch?
about 1 cm
The PMDX homing sequence intentionally moves a small amount past where the "home" switch first triggers. According to the SmartBOB release notes (look in your "Mach4Hobby\Plugins\PMDX-SmartBOB-USB" directory) it moves 0.50" past where the home switch triggers. The entire homing sequence (and restrictions) are described in the "Homing Features and Restrictions" section of the release notes. Check it out. This additional motion is to ensure that when the machine stops the home switch is still pressed. That allows a more precise "back off" movement. If the machine were to stop as soon as it hit the home switch, there is a chance that the mechanical slop in the drive train and/or home switch (or positional uncertainty if the switch is a prox sensor or optical sensor) might cause the switch to "un press".
can I set ( the 0.5) to zero when it triggers ?
If your limit switches are positioned such that the machine will damage itself if it moves ANY distance past where the switch triggers, don't do that! Depending on the speed of the machine when it hits the limit, it may not be possible to stop it immediately. The SmartBOB can stop sending step pulses, but the mechanical momentum may try to continue motion. Heavy machine at high speed = ain't gonna stop immediately,.
i'll change the speed and rewire it
thanks a lot