10-12-2008 04:53 AM
Hi
IM using a number of Zero up power suppliers throw a Zero up controller connected by GPIB.
since I have to read different channels of the controller IM using the attached VI and initializing the communication each time.
the problem is that every now and then the initialize VI gives me the following error:
<ERR> nlZUP Initialize
The ID Query failed. This may mean that you selected the wrong instrument or your instrument did not respond. You may also be using a model that is not officially supported by this driver. If you are sure that you have selected the correct instrument and it is responding, try disabling the ID Query.
what should i do??
thanks
Shai
10-12-2008 11:23 AM
There is no reason to initialize/close every time. That's just a waste of time. The VISA session will remain available until you explicitly close it or you close out of LabVIEW. How are you running this VI? Are you using the "Run Continuously" button? If so, stop. That button should not be used that way.
The error is being generated with the "nlZUP chechInstrumentType" VI. That VI is fed a string from the "nlZUP setPSAddress" VI, and is fed the result of the ":MDL?; " command. My guess is that sometimes you're not getting the right string returned. This could be a communication error, or perhaps the instrument is busy, and the wait time for the response is too short. As I said, unless you're physically changing the instrument on the fly while the VI is running, there is no point in always asking what kind it is.
10-15-2008 06:01 AM
What i do have to do is to change channels (address) to operate different power supplies via the controller "on the fly"
but the loop isn't very fast (about every 200msec)
is there any other reason for which i will get that massage?
shai
10-15-2008 08:44 AM
10-16-2008 04:03 AM
it seemes like the device just dosent give a reply (empty string)
by the way im not sure if iv allready said that it some times happens but mostly it works fine
i have allso wantes to ask what does a property mode reciving the visa address and the user data (as seen in the problamtic VI) do?
thanks again
shai
10-16-2008 07:09 AM
This is the what i meant (in the attachment)
10-16-2008 01:46 PM
I can't really tell you exactly why the instrument sometimes returns an empty string. As I said, maybe it's busy, or maybe the driver doesn't take into account a partial message, which can happen. As has been pointed out, though, it's still pointless to keep initializing and closing every time.
As for your question regarding the "User Data", that's just a place where one can store whatever information one may want to store regarding the instrument. VISA provides this. With some instrument drivers I've seen this used to hold the model number so other VIs can act based on the model number so the right command is sent in case the instrument drivers can be used for multiple models.