07-27-2009 01:25 PM
I'm getting the following error when I try to run GPIB on Labview:
"Error 2 occured at GPIB write in (filename).vi"
Possible reason(s):
LABVIEW: Memory is full.
---------------------------
---------------------------
NI-488: No Listeners on the GPIB.
This error tends to occur when an improper address string is written to the device. For example, if the device is 15 but the Labview address string is 28, this error will occur. However, I have already checked for that, and the address string is valid.
Furthermore, this is not specific for a particular device. I have tried writing to other devices using Labview and I get the same error! Therefore, I'm inclined to believe that the problem lies with the computer.
07-27-2009 04:25 PM
07-27-2009 07:09 PM
07-28-2009 11:35 AM
The GPIB controller is a PCI card, with NI-488.2 for the software.
Here's what MAX shows for a sample program.
My System |
---|
Operating System | Microsoft Windows XP Professional Service Pack 2 (5.01.2600) |
---|---|
Processor | Pentium / x86 Family 6 Model 8 Stepping 6 / GenuineIntel / 930 MHz |
Memory | 255 MB of RAM |
Disk Space | C:\ 22.6 GB of 29.2 GB free D:\ 24.3 GB of 26.5 GB free |
GPIB0 (PCI-GPIB) |
---|
GPIB Hardware Model : PCI-GPIB
Serial Number : 13F04C2
Primary Address : 0
Secondary Address : None
System Controller : Yes
I/O Timeout : 13 (10 sec)
Autopolling : Yes
Send EOI at End of Write : Yes
Terminate Read on EOS : No
EOS Byte : 0
8-bit EOS Compare : 7-bit
Set EOI with EOS on Write : No
HS488 Cable Length : 0 (Disabled)
Parallel Poll Duration : 0 (2 usec)
Assert REN when SC : No
Bus Timing : 2 (500 nsec)
07-28-2009 11:39 AM
I meant what does MAX show in terms of the instruments on the bus?
The one thing I don't understand is that you're explicitly using GPIB Write as opposed to VISA. Any reason why? New code should be using VISA instead of the GPIB functions.
07-28-2009 12:29 PM
VISA would probably work better. As of right now though, GPIB cables are what I have to work with in the lab.
Now, in the "Advanced System Information" section of the MAX report, for GPIB, the bus type is 'pci', the bus number is 2, and the socket number is d (or 13 in hex).
What specifically are you looking for in terms of other instruments on the bus? Do you mean other instruments on the bus which are not GPIB instruments?
07-28-2009 12:35 PM - edited 07-28-2009 12:38 PM
einone wrote:VISA would probably work better. As of right now though, GPIB cables are what I have to work with in the lab.
.....
Say what?
I think you don't understand the relationship between VISA and GPIB. VISA is an API that works with GPIB, RS-232, Ethernet, PCI, PXI, USB and has been the standard for GPIB communication for a long time. You really don't have any reason to use the low level GPIB functions.
At some point, you should have right clicked on the controller and done a scan for instruments. You instrument should then be listed.
07-29-2009 01:57 PM
Ok, so now I'm trying to use the VISA functions for GPIB, and I get the following error at "VISA Open":
Error -1073807202 occurred at VISA Open in GPIB check.vi
This error code is undefined. No one has provided a description for this code, or you might have wired a number that is not an error code to the error code input.
The resource name is "GPIB0::18::INSTR" because the board index is 0 and the instrument address is 18.
07-29-2009 02:01 PM
Did you try a search? See here: VISA Error -1073807202 (0xBFFF009E).
You still haven't told us what MAX shows for the list of instruments on the GPIB bus.
07-29-2009 04:13 PM
Without the list, it's kind of difficult to figure out what the problem is, but I'm betting that there is no instrument at address 18 connected to your PC. This means that either 1) The GPIB cable is not connected or 2) The instrument is at a different address.
Slight possibilities:
There are two instruments at address 18
One of the other instruments thinks it is the system controller
In any case, (after you get the list from MAX if possible), you should go to each instrument's front panel and find out what address it thinks it is and whether it thinks it's the system controller or not.