Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

VISA read timeout error--- Keithley 2400

Solved!
Go to solution

    I am trying to use LabView 2010 to control a Keithley 2400 Sourcemeter on an RS-232 Interface. I want to configure a measurement and take a reading (e.g. plot voltage vs. time)

     I took an example code from the library "Keithley read single", however error 1073807346 pops out from the "Initialize" box. THen i looked into "Initialize. vi" and found there is an error from VISA read (timeout error ?). I have attached both screenshots that shows the errors. Can anyone tell me how to solve the problem? By the way, i am very new to labview, could someone suggest a solution that's not too "advanced"? THanks alot.

 

0 Kudos
Message 1 of 24
(15,979 Views)

Hi Michigan,

 

Thanks for joining the forums! Smiley Very Happy

 

- Do you have any other programs which may be using that COM port?

 

If you do then that could cause this error.  One thing to try is to query the device (from MAX or LabVIEW) with a simple command like *IDN? - if we cannot get a response from this then there could be an issue with your serial port.  Although try sending the command for now, and then we'll work from there.


Regards,

Peter D

0 Kudos
Message 2 of 24
(15,969 Views)

A few possible errors:

1) the serial cable is wrong, you need  "straight through"connection pin 1..1, pin 2..2, pin 3..3 etc.

2) the buadrate is not the same on pc and keithley (or another serial line parameter that I would like to see on the frontpanel of the initialize)

3) the keithley is still configured for GPIB

 

 

so try these first mayb by typing *IDN? in hyperterminal and see what coems back

or directly in MAX on the serial port device.

greetings from the Netherlands
0 Kudos
Message 3 of 24
(15,963 Views)

Hi Pete,

    Thanks for the input.  i opened MAX and selected COM1 which i am currently using as the interface channel. and then i clicked opened VISA test panel, in viWrite under Basic I/O, i typed *IDN? and then press execute, Keithley immediately turns to REM. and the return status is x0. But is this the right way to query the device? and i don't think i have other program using that port.

    i am just starting to learn labview, please advise what i should do next.  THanks.

 

0 Kudos
Message 4 of 24
(15,942 Views)

Hi Albert,

    Thanks for you replies. How can i check this is a straight through cable? i think the  the baudrate as well as other parameters are the same in pc and keithley. Also, the keithley is configured for RS232 mode. I tried query the device in MAX and in my response to Pete, i have detailed the procedures how i do it. I am just not sure if i am doing it right and what i am supposed to get from sending *IDN? command.

0 Kudos
Message 5 of 24
(15,939 Views)

Hi,

 

The *IDN? is an identification query. If the device is properly connected it will respond with its identification string. (such as Manufacturer, Model name, etc). I suggest you first disconnect the device and perform a loopback test on the cable itself. If the cable passes the test you should be able to successfully execute *IDN?. Make sure you follow these steps:

 

Open VISA test panels:

1. In the viWrite tab, type in *IDN?\n and then click Execute. This will send the 488.2 identification command "*IDN?" to your instrument followed by a termination character "\n"
2. Now from the viRead tab, select a count of 100, the length of an expected response. and then hit Execute. Your instrument should return an identification string.

 

Also have a look at this article/lab that gives a good introduction on serial communication.

Sev K.
Senior Systems R&D Engineer | Wireless | CLA
National Instruments
0 Kudos
Message 6 of 24
(15,917 Views)

Hi Sev,

    I tried what you desribed in your previous message and performed a loopback test with the cable, once i execute in viWrite, the device goes to REM, and in viRead, i can see the instrument identification string being returned "Keithley Instrument, blah blah blah".. with a return status shown in red "BFFF0015". is that normal ? if so, i guess my cable passed the loopback test.

    ANy idea about how i should proceed from here ? Thanks

0 Kudos
Message 7 of 24
(15,895 Views)

Hi

did you download the driver from IDnet?

If not do it.

Try to run a small example from that driver and play around with it.

IDnet can be found:

http://www.ni.com/downloads/idnet/

greetings from the Netherlands
0 Kudos
Message 8 of 24
(15,891 Views)

hi Albert

    I downloaded Keithley 24xx meter, certified LabView plug and play (project style) Instrument Driver for Labview 2010. I extracted the zip file in the instr.lib, but the problem still exists. Would you suggest what to do next ?

 

THanks,

 

0 Kudos
Message 9 of 24
(15,885 Views)

take the initialize .vi and select the correct com port, run the vi, make all data control values the new default, and send in the vi.

Then we see what exactly went wrong.

greetings from the Netherlands
0 Kudos
Message 10 of 24
(15,881 Views)