LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Error-85 on instrument driver VI

Hi, 

 

I'm trying to modify an instrument driver in from an instrument control course tutorial. I followed the tutorial and I can't see any mistakes on my but when I run the instrument driver vi, I get an error 85 message saying that labview scan failed. Possible reasons, the input string does not contain data in the expected format. Please see attached VI. I will appreciate any help.

 

Thanks.

 

 

0 Kudos
Message 1 of 12
(3,565 Views)
Yes, one of your scan from strings has the incorrect format string. You should probe the input to see what is being passed. Since no one without the instrument can run the VI, you would need to provide that detail if you continue to have problems
0 Kudos
Message 2 of 12
(3,554 Views)

Hi Dennis,

 

The instrument is a NI instrument simulator v2.0.  It is set in GPIB multi-instrument mode and the driver is for the oscilloscope simulator. The problem is that I can't tell which format is right or wrong since I followed the directions of NI Instrument control course manual. Perhaps somebody can try it with the same simulator and see if they can figure out why the error continues to occur.

 

 

 

0 Kudos
Message 3 of 12
(3,540 Views)
If you really wanted help, why didn't you do what I suggested and post the string you get? It would have taken you all of a minute and you could have gotten an answer from anyone. Oh well, I guess you aren't in a hurry to fix your programming error.
0 Kudos
Message 4 of 12
(3,533 Views)

Hi Dennis,

 

Sorry, I thought explaining what was happening the way I did would be enough. Anyways, the data at the input is pretty long but here is the starting section below. The only thing I noticed here is that the first data point has a different format than the rest. 

 

8.8531e-17,

0.31395,0.62667,0.93691,1.2434,1.5451,1.8406,2.1289,2.4088,2.6791,2.9389,3.1871,3.4227,3.6448,3.8526,4.0451,4.2216,4.3815,4.5241,4.6489,4.7553,4.8429,4.9114,4.9606,4.9901,5,4.9901,4.9606,4.9114,4.8429,4.7553,4.6489,4.5241,4.3815,4.2216,4.0451,3.8526,3.6448,3.4227,3.1871,2.9389,2.6791,2.4088,2.1289,1.8406,1.5451,1.2434,0.93691,0.62667,0.31395,-1.4742e-14,-0.31395,-0.62667,-0.93691,-1.2434,-1.5451,-1.8406,-2.1289,-2.4088,-2.6791,-2.9389,-3.1871,-3.4227,-3.6448,-3.8526,-4.0451,-4.2216,-4.3815,-4.5241,-4.6489,-4.7553,-4.8429,-4.9114,-4.9606,-4.9901,-5,-4.9901,-4.9606,-4.9114,-4.8429,-4.7553,-4.6489,-4.5241,-4.3815,-4.2216,-4.0451,-3.8526,-3.6448,-3.4227,-3.1871,-2.9389,-2.6791,-2.4088,-2.1289,-1.8406,-1.5451,-1.2434,-0.93691,-0.62667,-0.31395,8.8531e-17,0.31395,0.62667,0.93691,1.2434,1.5451,1.8406,2.1289,2.4088,2.6791,2.9389,3.1871,3.4227,3.6448,3.8526,4.0451,4.2216,4.3815,4.5241,4.6489,4.7553,4.8429,4.9114,4.9606,4.9901,5,4.9901,4.9606,4.9114,4.8429,4.7553,4.6489,4.5241,4.3815,4.2216,4.0451,3.8526,3.6448,3.4227,3.1871,2.9389,2.6791,2.4088,2.1289,1.8406,1.5451,1.2434,0.93691,0.62667,0.31395,-1.4742e-14,-0.31395,-0.62667,-0.93691,-1.2434,-1.5451,-1.8406,-2.1289,-2.4088,-2.6791,-2.9389,-3.1871,-3.4227,-3.6448,-3.8526,-4.0451,-4.2216,-4.3815,-4.5241,-4.6489,-4.7553,-4.8429,-4.9114,-4.9606,-4.9901,-5,-4.9901,-4.9606,-4.9114,-4.8429,-4.7553,-4.6489,-4.5241,-4.3815,-4.2216,-4.0451,-3.8526,-3.6448,-3.4227,-3.1871,-2.9389,-2.6791,-2.4088,-2.1289,-1.8406,-1.5451,-1.2434,-0.93691,-0.62667,-0.31395,8.8531e-17,0.31395,0.62667,0.93691,1.2434,1.5451,1.8406,2.1289,2.4088,2.6791,2.9389,3.1871,3.4227,3.6448,3.8526,4.0451,4.2216,4.3815,4.5241,4.6489,4.7553,4.8429,4.9114,4.9606,4.9901,5,4.9901,4.9606,4.9114,4.8429,4.7553,4.6489,4.5241,4.3815,4.2216,4.0451, 

0 Kudos
Message 5 of 12
(3,517 Views)

And without seeing the actual string, how could anyone know what is wrong with the format?

 

Your format string is saying that there should be a '#' character before a numeric. Obviously there is not.

0 Kudos
Message 6 of 12
(3,515 Views)
What string are you talking about? Do you mean the format specifier? Weren't you able to open the VI? Here is what I have in the format specifier of the first format into string function #%1d.  What changes do I have to make to fix this problem?
0 Kudos
Message 7 of 12
(3,501 Views)
I know that you have #%1d in the format string and as I said, that is incorrect because there is no '#' in your string. You can see that yourself and saw it before I did. If there is no # in the string, the scan will fail so remove the # in the format specifier. You should read the online help on format specifiers if you do not understand what they do.
0 Kudos
Message 8 of 12
(3,499 Views)

Dennis,

 

I removed the # from the format specifier in the first format into string function and I'm now getting the error code 85 on the last/3rd format into string function with the same error message that the input string isn't in the expected format. I probed the input and the values were similar to the data I posted earlier.  Here are the first few points below: 

 

                            .8531e-17,0.31395,0.62667,0.93691,1.2434,1.5451,1.8406,2.1289,

 

 I really don't know how to make any changes or correction in that last function. 

0 Kudos
Message 9 of 12
(3,490 Views)
What exactly are you trying to extract from the VISA Read? It seems you have not written the format specifiers to match that. Since you cannot alter what the instrument is returning, you have to change the format specifiers.
0 Kudos
Message 10 of 12
(3,488 Views)