11-17-2008 08:44 PM
Hi,
I have a stepper motor move back and forth along an axis.
The problem is that there is a delay between one move and the next.
The delay appears to be the same duration every time.
Can anyone suggest how to troubleshoot this.
Thanks.
11-18-2008 02:57 PM
Hey cosmund,
So, your stepper is controlling a stage, I assume?
About how long of a delay is it?
Is it torque control or velocity control?
How have you set your trajectory?
Any more information that you can think of will help me out. Currently, I can't narrow down the problem far enough to be much help.
Thanks.
11-18-2008 05:15 PM
Hi Chris,
Thanks for your reply.
What do you mean by "controlling a stage"?
The delay is about a 100ms.
I am using velocity control.
I am using a trapezoid tragectory generation VI in Labview (with acceleration, max velocity and deceleration values)
Thanks,
cosmund.
-------------------------------------------
Hey cosmund,
So, your stepper is controlling a stage, I assume?
About how long of a delay is it?
Is it torque control or velocity control?
How have you set your trajectory?
Any more information that you can think of will help me out. Currently, I can't narrow down the problem far enough to be much help.
Thanks.
11-18-2008 09:41 PM
11-19-2008 09:50 AM
cosmund,
could you please give us some more details about your application? Which motion control hardware are you using? What exactly are you trying to accomplish?
To me it sounds like "blending" could be a solution for you, but I'm not really sure. Please refer to the shipping examples.
Thanks and kind regards,
Jochen Klier
National Instruments
11-19-2008 10:27 AM
cosmund,
I meant controlling a linear stage, but thats not really a big deal. As said by other posters, we do need some more details on what exactly you are doing, and how you are going about it.
Blending also sounds like it could be a good idea to me, but with the lack of information, I'm not sure.
11-19-2008 04:34 PM
Guys, thanks for your responses.
I've attached the VI that does the moves, to give a clearer picture.
I'm using the MID-7604 motion controller connnected to a motor with a lead screw on a platform.
I'm only doing a single axis move, back and forth.
Everytime the motor changes direction I get this delay.
In the program, the moves are executed immediately after each other, so there should be no delay.
Thanks,
cosmund
11-20-2008 02:59 AM
Hi cosmund,
thank you for the delay. Some subvis were missing, but I still could get the idea of what you are doing. With this simple approach you always will see some delay between the moves, as everything is running sequentially in software. As long as you are not using a real-time system, the delay will also be non-deterministic. As I don't have them, I can't see, what's going on inside the vis, but maybe there is even some programmatic delay introduced with these vis.
Anyway. If you want to make sure, that the new move starts with zero delay, then blending is the best option, as this shifts everything to the onboard processor, which allows you to start a new move immediately after the first one has ended. Please refer to the example "Sequence of Blended One-Axis Moves.vi", which should be a good starting point. For your application you should set the blend factor to "0".
Jochen
11-20-2008 05:26 PM
Thanks Jochen,
The sequence of two VIs that do the moves were generated from Motion Assistant.
I created those moves in Assistant, and then auto-generated the LabView code.
If there is a delay between the execution of two VIs, isint that purely a LabView issue?
Thanks for your links about blending.
cosmund
11-21-2008 02:01 AM
cosmund,
I had a look into the vis generated by Motion Assistant and that explains pretty well, why you see a 100 ms delay. That's exactly the delay that is used in a while loop inside these vis to poll the axis' status.
You could lower this delay, but you probably won't be able to decrease the effective delay below a value of approximately 10 ms. Decreasing the delay results also in higher CPU loads and you still will see a high amount of jitter, so blending is still the recommended method.
Jochen