12-08-2010 11:37 AM
12-08-2010 02:35 PM
It seems that you have a nice way of generating commands for instruments.
In principle you can do the same in LabVIEW.
For your fileformat you need to write a loader that loads all commands into memory and for each command per instrument can spit out the correct visa string. Exactly the same as you do now.
Your only problem is that you are new to LabVIEW so let somebody help you.
One of the nice things in this forum is that all (most anyway) of us are independent from NI and "work" or "play" for free.
You can learn about action engines from Ben (search the forum) and see that such an approach is good for your question.
Or somewhat later you could even opt for an object oriented approach.
But also build for the future: GPIB is going to disappear because of too thick and too short cabling and especially pricing.
USB and ethernet will take over so make sure that both busses (via visa) are also included in your approach and too make live even better.
There are already a lot of nstrumentdrivers available on the network and they only need a unifying layer that can "easily" be done with objects in LabVIEW.
So start using to get used to LabVIEW and ask specfic problems when they arise or when you have read about action engines.
12-10-2010 08:46 AM
Hello,
I am sending you a tutorial that might give you basic informations about NI-VISA
http://zone.ni.com/devzone/cda/tut/p/id/3702
I hope it will be useful for you
Sabrina
12-11-2010 12:17 PM
Lab-Lurker
12-12-2010 02:43 AM
Hi lablurker
Good work in reading so much. I know there is a lot to learn when switching languages, especcially when the basic princile behind is not the same. In this case LabVIEW as a dataflow language took me more that half a year to get used and that was in the first LabVIEW version on pc, already 17 years ago and LaVIEW hasn een extended a lot since then.
In esence your problem was already solved when you wrote the previous language interpretation.
You need a relative simple visa vi that performs a query. Meaning sending a command and reading back an expected answer.
Around this you need to have for each datatype a function that "knows" the command to send and "interprete" the returned data.
Above this you need to ave a way from your instrument description file which vi to call for which command.
e.g. for the serial number you probably have to send *IDN? followed by reading a string of probably max 256 characters, but for some instruments you only need IDN? and others IDN each followed by a terminal character like CR and or LF.
In LAbVIEW instrumentdrivers do exist that solve most of the work only these instrumentdrivers are not standardized in functions. So as an example the Source Measurement Units from Keithley are not equal in interface to those from Agilent or NI. Even worse the 2400 series from Keithley are quite different from the 2600 series. (as seen in the forum and known by experience)
So succes with the implemtation and in two months I'll be ready with a paper on Source Measurement Units.