LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

hp 5385A or hp 5386A LV Drivers? HPIB seems to Predate VISA Spec?

I have tried the HP 5385 or 5386 A Frequency Counter stand alone and still unable to get it to function properly using VISA.  HP 5385/5386 generates GHOST Sessions in MAX and ERROR 52 appears on LCD of OLD HP 5385/5386.  I am giving up for now as someone convinced the Company to buy a AG 53131a, I found a LV corrected drivers that work fine with this instrument through this forem.   

If I get some time, I will look into this.

THANKS ALL AND PUTNAM!!


@briancam wrote:
Have 7 GPIB New Instruments and 8 Instruments in PXI Chassis that Function Correctly in MAX.
Want to use OLD HP 5385 or 5386 A Frequeny Counter on same GPIB with NI GPIB controller set to 0.
 
OLD HP 5385/5386 generates GHOST Sessions in MAX and ERROR 53 appears on LCD of OLD HP 5385/5386?
 
OLD HP 5385/5386 Manual informs me it is HPIB compatable and I use the old GPIB -- NON-VISA vi's to program the instrument.
 
However, once it is put on the 7 GPIB New Instruments GPIB, I cannot read the instrument?
 
OLD HP 5385/5386 seems to predate VISA Standard?  Does it?
Is there any way I can interface the OLD HP 5385/5386 to our 7 GPIB New Instruments GPIB?



 

0 Kudos
Message 11 of 18
(3,746 Views)
If you have problems with MAX detecting it with nothing else connected, you've got a GPIB problem. Again, VISA has nothing to do with MAX detecting instruments. Your "ghost" sessions are probably caused by a defective GPIB interface in the instrument. It could probably be fixed but you're I'm sure you are better off with something new and in warranty.
0 Kudos
Message 12 of 18
(3,740 Views)
I just had the same experience with HP5386A.  The unit displayed error 52 when there was no signal on input B and I tried to measure frequency using a GPIB command. 
 
I know what creates the "ghost images".  Everytime you initialize the meter using a VISA session, you create a new session.  In order to close each session, call the VISA close function for each instance of the VISA session, or exit LABVIEW. 
 Multiple copies look like this:  GPIB::03::INSTR
                                                GPIB::03::INSTR 1...
 
                                             ...GPIB::03::INSTR N
You can build a VI just to close all the open sessions.  In a new VI diagram, drop a VISA close function, a stop control button and a 10ms wait function into a while loop.  Place the wiring tool over the top left corner of the VISA close function, right click->create control.  An IO control will be automatically placed on the front panel do the same for the stop while loop control.  If necessary wire the IO control into the top left corner of the VISA Close function.  Run the VI.  Select each of the VISA sessions using the IO control and press the stop button on your front panel when you have closed all of the open sessions.
 
  
0 Kudos
Message 13 of 18
(3,697 Views)

I too need to use the Agilent 5386A Frequency Counter. I too have experienced error 52 on attempting to address it, “generating Ghost sessions” of the instrument and not being able to communicate with it in MAX.

To quantify further what I have seen, I have not been able to access the device through MAX and I cannot determine the true GPIB address of the instrument in LabVIEW and communticate with it. I know that it is set up to be on GPIB port 3, but addressing any commands to GPIB0::3 results in an error, and LabVIEW is seeing 31 instruments on this port, (GPIB0::3::0::INSTR, GPIB0::3::1::INSTR … GPIB0::3::30::INSTR) each of the secondary addresses is different. I have tried to communicate with each of them in turn (I put "GPIB0::" "::INSTR" and concatented them together with the iteration count of a For loop, attempt to Open, Write "ID?;" Read 50bytes, Close, and create a popup to notify to press reset on 5386 to clear error)

I need to get comms working with this instrument fast. If anyone has any suggestions - Dennis? please help.

No other GPIB devices turned on (strung together, but not turned on so not detected)

To summarise, the Ghost Sessions I can see are all of the possible secondary addresses, NOT duplicate VISA sessions open at the same time.

CLD; LabVIEW since 8.0, Currently have LabVIEW 2015 SP1, 2018SP1 & 2020 installed
0 Kudos
Message 14 of 18
(3,036 Views)

The first thing I would recomend is that you turn ON all instruments that are connected to the bus. One of the requirements of GPIB is that something like 2/3 must be powered on. If you don't want them interferring, then disconnect them.

 

Other than that, I have no other suggestions right now.

0 Kudos
Message 15 of 18
(3,024 Views)
I can give you the vi's I have been using for the last 8 years.  They are specific for my application.  They should be in LabVIEW 7.1 or 8.0.  I still have an occasional problem with the frenquency counter's GPIB bus being busy and ignoring commands.  I have not found a work around.  It happens on occasion.  I have to recycle power on the frequency counter.
0 Kudos
Message 16 of 18
(3,012 Views)

Thanks for the feedback guys,

 

Dennis - I did not know that, I thought merely turning off the instruments was enough. I'v now only got the 1 device (5386A) attached.

 

grenoble - thanks for the VIs, I tried using the initialse function, changing the instrument descriptor to "INSTR{GPIB::3}" but I just got error -1073807343 (VISA:  (Hex 0xBFFF0011) Insufficient location information or the device or resource is not present in the system.) occuring at the Old VISA Open.

I've tried every other possible combination I can think of, but no results yet. (no 5386A error with open old VISA is a good result, but not opening the session is a problem to me)

 

I have been in contact with Agilent Tech Support, and they reccomended downloading their IO Libs, but even with these installed as secondary VISA libs, I still can't get comms established and get error 52 popping up 5386A if I do something silly or modern.

 

I'm waiting to here back from Agilent later today, if anyone has any more ideas I'm willing to try anything (within limits) to get this thing working today.

Thanks again.

CLD; LabVIEW since 8.0, Currently have LabVIEW 2015 SP1, 2018SP1 & 2020 installed
0 Kudos
Message 17 of 18
(2,989 Views)

I have finally succeeded in achieving instrument control!!

The requirements were:

NI Open VISA old function (to open the session)

Correct Instrument addressing.

I had been using the correct addressing with the new Open VISA, but thought I needed to change it from GPIB0::3::0 INSTR to INSTR{GPIB::3} according to the description in the VIs posted above.

 

The VISA can be opened with no error on the 8657A using Open VISA old, description = GPIB::3 INSTR , or any of the VISA session created for the GPIB primary address from the VISA drop down menu wired into the description (e.g. GPIB0::3::2 INSTR or GPIB0::3::29 INSTR)

 

Thanks to grenoble, Dennis and Agilent for their help

CLD; LabVIEW since 8.0, Currently have LabVIEW 2015 SP1, 2018SP1 & 2020 installed
0 Kudos
Message 18 of 18
(2,982 Views)