Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

ERR-1073807195 in GPIB communication with Keithley 2401 and Agilent 34970A

Solved!
Go to solution

Hi all!

My previous post regarding this problem did not garner much response, hence I'm reposting to report the issue along with some progress I've had:

 

I am using LabVIEW 18 for automating a battery life cycling test. This is an old code which has been handed down to me by a senior to run the testing setup. Recently, the CPU for the workstation on which this testing setup resides was changed and hence, there are some errors showing up while communicating with devices.

 

I am using Agilent 34970A for data acquisition and Keithley 2401 source meter as a power supply/DMM. I have connected the KE2401 source meter via a USB-GPIB cable to the CPU. And the Agilent 34970A is connected with a GPIB-GPIB cable to a National Instruments GPIB card in the PCI slot of my CPU.

 

I have the LV instrument drivers for Agilent 34970A and Keithley 24XX installed. Also, I've installed the Keithley IO libraries and communication expert along with the Keithley VISA as secondary. I set both the instruments in the GPIB mode via their front panels. Keithley 2400 is in GPIB SCPI mode (I have also tried with GPIB 488.1 mode). Agilent 34970A is in GPIB 488 mode. I have also checked that their primary addresses are the same in the front panel and my code. I have NI 488.2 installed and have enabled TULIP.

 

Now, both the instruments are being detected by NI MAX under miscellaneous VISA resources and I am able to communicate with them by querying the IDN command. Here are some screenshots:

GPIB devices in NI MAXGPIB devices in NI MAXKE2401 comms via VISA Test PanelKE2401 comms via VISA Test PanelAg34970A comms via VISA Test PanelAg34970A comms via VISA Test Panel

However, when I run the LabVIEW code which communicates with these, I am encountering an error with the initialize.vi. The error is -1073807195: The interface type is valid but the specified interface number isn't configured.

 

I also read some forums which asked me to uninstall the Keithley secondary VISA, but that results in NI MAX not identifying my GPIB devices. How do I troubleshoot this issue?

0 Kudos
Message 1 of 11
(4,505 Views)

Hi

You are using 2 gpib boards. And from 2 different suppliers. Why?

Each gpib board can address 31 instruments but due to hardware loads 16 or so is max. So 2 instruments can be controlled by 1 board from one vendor by one software communication layer.

Just try it. Connect both machines with each other and connect the combination to the usb dongle gpib connector from ni.

greetings from the Netherlands
Message 2 of 11
(4,449 Views)

Albert is correct on trying to use just a single bus controller if possible.  Also, I am curious as I have normally seen the second GPIB bus appear as GPIB1:: and not under the duplicate controller name (GPIB0::) when using two separate controllers.

Help the Community (and future reviewers) by marking posts as follows:
If it helped - KUDOS
If it answers the issue - SOLUTION
0 Kudos
Message 3 of 11
(4,388 Views)

Hey, thanks for the replies, people. I tried out the suggestions:

 

1) So first of all, I just rechecked the connections and I made a mistake in my post earlier as Minions pointed out. So both the instruments are cascaded together and are connected to the CPU with a USB-GPIB cable. I haven't connected anything to the NI GPIB card. In this situation too, the ERR-1073807195 in the LabVIEW code persists. However, NI-MAX is able to recognize the GPIB devices and I am able to communicate with them via VISA Test Panel.

 

2) I tried connecting both the instruments to the NI-GPIB card, but in that case, NI-MAX doesn't recognize the two GPIB devices at all. And the same error is encountered in the LabVIEW code. Is there any software/setup/configuration required for the NI GPIB card? I've just connected it in the PCI slot.

 

Thanks a lot for the help.

0 Kudos
Message 4 of 11
(4,378 Views)

Try posting your code as it might be something as simple as a missing NEWLINE character in your code that is causing an issue with your LV code versus the NI-Max panels.  Also, make sure to close NI-Max before running your LV code as the GPIB bus controller is usually NOT a shared piece of hardware.

Help the Community (and future reviewers) by marking posts as follows:
If it helped - KUDOS
If it answers the issue - SOLUTION
0 Kudos
Message 5 of 11
(4,374 Views)

Hey!

PFA the labview code. Actually, it requires installing Agilent 34970A and KE24XX drivers. I've also included the subVIs which it uses.

 

Following screenshot shows the two blocks which are giving out ERR-1073807195:

LVnew.png

Download All
0 Kudos
Message 6 of 11
(4,372 Views)

Vendsoni,

 

You can actually control both of these instruments without the drivers by using SCPI.  It uses the same commands as seen in the NI-Max screens.  You can use this Simple VISA controller to send the commands/queries using SCPI.  Select the VISA instrument then enter the following into the write buffer:

*IDN?\n

Now run the VI and watch the response in the read buffer

LV2012 VISAwrc.png

In your example, you are trying to initialize a single bus with both instruments.  The bus can control either instrument at a time, but not multiples unless the individual instruments are configured to accept a trigger or such.

Help the Community (and future reviewers) by marking posts as follows:
If it helped - KUDOS
If it answers the issue - SOLUTION
0 Kudos
Message 7 of 11
(4,363 Views)

Hey!

 

I don't have much experience with using VISA in LV, but I've replicated the VI shown in that image. Here are the images, do let me know it anything's amiss:

 

 

VI Default caseVI Default caseVI 'no match' caseVI 'no match' case

I used this on both the instruments (one at a time) and I encountered the same error in LabVIEW, -1073807195. I also used a more broken down version of this VI, but still the same error:

LVnew4.png

0 Kudos
Message 8 of 11
(4,356 Views)

Check these items first:

  1. Within NI-Max, run the check for instruments on the bus
  2. Make sure to exit NI-Max or it will hold the bus captive and cause errors for your LabVIEW program
  3. Exit LabVIEW completely to ensure all connections are then closed
  4. Re-open LabVIEW and run one of the test connections

 

Which is the correct connection?

In Message 6: the instruments are on GPIB1 bus

In Message 8: the instruments are on GPIB0 bus

 

 

Help the Community (and future reviewers) by marking posts as follows:
If it helped - KUDOS
If it answers the issue - SOLUTION
0 Kudos
Message 9 of 11
(4,341 Views)

Something doesn't seem right with your setup. In NI-MAX, how are those instrument listed under miscellaneous?  Why don't they show up under a GPIB interface?  They should be under either the USB-GPIB or PCI-GPIB card.  Can you clarify brand/make/model or your USB-GPIB and PCI cards.  What drivers did you install?

 

Message #4 >> "Is there any software/setup/configuration required for the NI GPIB card?"

 

Yes, once you've installed LabVIEW, and NI-VISA then you should plug in your PCI card.  It will be automatically detected by the PC and Windows will install the NI driver for it to work properly.  It should then show up in NI-MAX and attached instruments will be listed below it.  This is much like when you first plugged in the USB-GPIB interface. 

 

If you had the PCI card plugged in before you installed LabVIEW and NI-VISA then it might not be properly configured.  If its not an NI card then you might need to install additional drivers beyond NI-VISA.

 

To follow on Minions last comments..  

In NI-MAX test panels you show GPIB0::09::INSTR and GPIB0::24 INSTR. (working)

In LabVIEW you use GPIB1::09:INSTR and GPIB1::24::INSTR. (not working)

 

Have you changed things around in NI-MAX?  You should use the same addresses in LabVIEW. 

0 Kudos
Message 10 of 11
(4,327 Views)