I’m using the PXI-7344 and the latest NI-motion driver on Labview realtime. When I reach a forward or reverse limit switch the motion is not stopping. The limit switches are working properly and are properly detected when looking at the limit switch status. We enable the limit switch at the beginning of our program.
When the limit switch is activated the motion will not start (so that works) but it will not stop the motion while it is executing a trajectory.
Any idea what the problem is?
The limit switch will not stop the motion if the motors are moving in the direction opposite to the switch. It's possible that the reverse limit switch and forward switch and inverted and we would thus not see motion stop when the switch is triggered. Another possibility is that the voltage drops to zero from the UMI and that there maybe an offset on the drive itself, is there any offset in the voltage you are applying to the drive? Do you see any change in output on the UM-7764 after the switch is triggered?
Thanks for the response.
The limit switches are wired properly and they work to prevent to start a motion from starting but will not stop a motion that is in execution. It is not an offset problem. The motion continues to execute its path until it is completed (until it reaches the commanded position).
If the forward and reverse limit switches are enabled, then any triggering of either the forward or reverse switch during movement in Measurement and Automation Explorer should trigger a halt to the motion. Please note that this will not kill the drive as doing so would cause the motor to overshoot the switch. If the limit switch is not enabled it will still show up in Measurement and Automation Explorer (will light up) but will not affect the motion in anyway. Check under Motion I/O settings and confirm that both the forward limit switch and reverse limit switch are active.
Hi Matt and Eric,
I am seeing the same issue with a PCI-7354 with hardware limits wired into a UMI-7764 breakout board. The limit switches work fine and will even stop the motion if the number of counts moved is < 1000 counts. If you try and stop the motion after about 1000 counts it continues to move until it reaches the programmed position. It doesn't make logical sense, but its definitely a repeatable error.
So I am trying to understand your setup a little more. I wonder if you use step, or servo motors. What environment are you experiencing this in? Is it LV, MAX, or something else, and what version of the NI-IMAQ driver are you using? Also, it would be really helpful if you could post a screenshot of your MAX sittings.
Also if you could please attach a (.nce) of your MAX configuration with these settings in the Motion IO section:
I am using servo motors for this application. I am experiencing this issue both in MAX and in our VC++ application that calls the motion control libraries. The version of NI-IMAQ is version 2.2. I've attached my current max settings and but it won't let me attach the .nce file. I can email it directly to you if you'd like.
I've also figured out the root of the problem. When I try to press the halt button under the same conditions the motion also doesn't stop - but hitting the kill switch does. I think I need to reconfigure my setup to kill the motor once a harware limit is triggered rather than just halt it (its a piezo motor with a very high holding torque, so it stops pretty quick when killed). I've read a few forums related to changing the default action to a kill rather than a halt but most of the suggestions require writing a VI, which I believe only applies to Labview (and consequently does not apply to me). Others have suggested configuring the motion i/o map to force the inhibit in to activate the inhibit out once a limit is triggered, but I also had difficulty getting this to work. Any suggestions would be greatly appreciated.