10-19-2009 06:01 PM
I am using a vi from Newport called ESP Example for RS-232 and I would like to unstack a sequence structure so that I can see all of the axes at once. At present I have only the option of looking at each one, reading it and writing to it and then selecting another axis and doing the same.
Thanks for any help,
Kevin
10-19-2009 08:46 PM
Not sure what you really are trying to do, but the code you sent only does one axis at a time. It is also a classic demonstation of using caution when a vendor states they have LabVIEW drivers or code. You could fairly easily rewrite it to use an event structure, and update this to newer VISA calls rather than the "classic serial" used.
10-19-2009 11:19 PM
I'm not sure what you mean by all the axes, but you can flatten a sequence structure.
Right click on the boundary of a stacked sequence structure and select Replace >> Replace with Flat Sequence.
One problem you'll have is that for some reason most of the other structures do not have Auto Grow checked, so the replacement will disappear off the border of the next structure. So with the next while loop or case structure, right click and select Auto Grow. Now that structure will grow large enough to show the flat sequence structure.
I recommend turning on Auto Grow for all of your structures.
If you are using a newer version of LV, I would recommend updating the code so that it uses VISA functions instead of those ancient serial port functions.
10-20-2009 02:09 AM
Depending on the Newport model translating everything to use VISA may be a bit more complicated. I have worked with the ESP300 and decided to write my own driver after having tried the various Newport variants and others around. I needed GPIB operation. And what should have been a job of two or three days turned out to be almost 2 weeks because the darn thing operated rather eratically.
A half day session with a Newport support engineer, after the client had really pressured them, finally turned up some specific settings that needed to be changed in the GPIB interface settings. With that I could at least communicate with the thing and do what it needed to do. But several commands simply didn't do what they should have done, and certain operations such as waiting for motion complete status never worked properly. Polling was the only solution in the end.