06-20-2014 10:09 AM
Hello,
I'm attempting to perform a continuous triggered high speed motion capture independent of the motion, and it's not clear that this is possible. Before I spend a few hours on a wild goose chase, I thought I'd ask around.
I have a digital pulse train coming in at about 100 Hz and I'd like to measure the position of my motion system in all 3 axes at each pulse. Having acquired the data, it should then get dumped to a file. This should happend continuously until the user exits the program. The continuous part of this seems unnecessarily complicated, involving on-board programming, if my reading of examples such as onboard-hsi-gpbuffer.vi and continuous_hsc.vi is correct. However, if that's the worst of it, I'll survive.
Meanwhile, the system is undergoing random motion, including starting and stopping of the axes. This is the part that has me particularly concerned. All of the examples that I have seen, both bundled and otherwise, seem to include a single move as part of the program. Since my system will be undergoing multiple moves controlled by the user, I'm concerned that these moves (or the end of the moves) will cancel the capture operations.
Does anyone have any insight into this sort of setup?
Thanks,
Jason
06-23-2014 11:19 AM
Hi Jason_S,
First off, what software are you using? Is this being done with SoftMotion?
It seems like you would want to write your encoder feedback to a file every time you get a pulse. This shouldn't be hard to do. Just put it in the same loop as your acquisition. But I can't look at your code... Does this sound like a reasonable way to do it?
As for multiple moves, SoftMotion has lots of examples with multiple moves, and it really excels in this department. If you haven't tried it, go ahead and download the evaluation version and give it a shot. Doing multiple straight-line moves and multiple contoured moves are very easy with this module. I don't see why doing multiple moves would cancel the capture operation if the moves and the captures are in the same loop.
06-23-2014 02:09 PM
I'm using LabVIEW and NI-Motion. The moves are not preprogrammed, but are controlled by a joystick. Therefore, the moves are of an inderterminate amount of time. Since I don't know how long the moves will be, I can't preprogram the length buffers for the acquisition. I need a continuous-type operation like you'd have with a continuous DAQ acquisition. Perhaps more importantly, I want to capture the position even when there are no moves being executed.
06-24-2014 09:59 AM
Hi Jason_S,
You can send it a velocity as well as a position. I found an example that seems to do what you're talking about: http://www.ni.com/example/29726/en/
It sends it a velocity and then checks to see if the joy stick has changed, and sends a new velocity only if the joystick has changed positions. Is this helpful?
As for checking your position whether your motor is moving or not, you could check your encoder each time the outer loop runs.
06-24-2014 03:28 PM
This seems to do the trick. It's based on the "Onboard Program - Continuous High Speed Capture into General Purpose Buffer" which can be found in the online examples. It implements an on-board program which fills a general purpose buffer. Most importantly, it runs continuously and independent of the motion or stops of the various axes. Hope someone else finds it useful.
Still curious if this is really the easiest way to accomplish this.
Jason