LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Need a Example VI to get screenshoots transfered from a Agilent N8973 via GPIB ?

Hi Community,

we have here in our lab nearly 20 years old Agilent N 8973 Noise Figure Equipment.

I want to transfer the Screenshoots (.WMF or PNG) via GPIB to the Labview 14  PC instead of using the 3.5 Floppy Disk.
I have installed the Labview Driver for the N 8973 but i found no function in the examples.
Has somebody a hint for me  how I can mange this ?

Thanks

Michael

0 Kudos
Message 1 of 8
(2,764 Views)

I don't think there is an easy way to do it, but it can be done. The way I did it in the past (on other HP/Agilent/Keysight equipment), is to save it to the equipment's internal hard drive first. Then transfer the file across GPIB. Here is an rough outline how I did it:


Step 1 (Optional): Set Display to full screen (I don't like to see the softkeys displayed in the screenshot)

full screen.PNG

 

Step 2: Save the .gif or .wmf to the internal hard drive. Pretty sure .png is not supported. I believe you need to provide the full path with the correct suffix for the <file name>. Probably can save it to the root directory. Ex. "C:\my_screenshot.gif"

save_gif.PNG

 

Step 3: Transfer the file from the internal hard drive to you computer. It comes across as "arbitrary block data". The N8973 driver you installed probably has this function.

transfer file.PNG

block data.PNG

Step 4: Delete the screenshot file on the c: drive that you created. I remember getting errors (in step 2) creating a screenshot if the filename already exists. So you can either delete the file and reuse the same name, OR you need to create unique filenames each time.

delete.PNG

 

Step 5: Save the binary data to your local hard drive. Use the "Write to Binary File" function, make sure you wire a "False" to the "prepend array or string size?" terminal.

 

Message 2 of 8
(2,726 Views)

Hi Jamiva,

 

thx for your feedback.

 

I am not sure if I understand it cVorrecht, what is the difference between step 3 and 5, i thought the file is already transfered in Step 3 to the labview pc or ?

 

If you have a simple VI Example for labview 14 compatible that you can share with me, that are very helpful to solve this problem in my brain.

 

 

Have a great day 

Michael 

0 Kudos
Message 3 of 8
(2,714 Views)

Step 3 is a query, which is actually 2 steps. A VISA write (which tells the instrument to send the data file), followed by a VISA read.

 

All the VISA read does is transfer the data to an indicator in your LabVIEW program running on your PC. You close/quit your program, you lose your data. So I would think you would like to store that data somewhere permanently. Step 5 saves it to your PC's hard drive.

0 Kudos
Message 4 of 8
(2,707 Views)

Here's an example of step #3 and #5 using the method jamiva suggested.  This is taken from an example posted on the forum for a different model scope a few months back (sorry I can't find the original source to credit!). 

 

I did try it with an old scope I had and it worked, but your mileage may vary.

0 Kudos
Message 5 of 8
(2,695 Views)

Hi cstorey,

 

thank you for your example VI.

 

I try to modify it but I get only on the Labview PC an WMF file without picture and the  filelength is only "0 kb" big,

 

Attached is the modify VI and the Picture , can you crosscheck where the failure is ?

 

Thank you for your help

 

Michael

 

 

 

Download All
0 Kudos
Message 6 of 8
(2,677 Views)

You have lots of problems in your VI. No wonder it didn't work. I started from scratch and attached a VI showing the way I would do it. It's probably not perfect but it's a start. It may just work as-is, or may need a few tweaks.

 

EDIT: I'm not sure that the path is correct. It may need the "\". If what is shown doesn't work, try using "C:\TST00216.WMF."

 

get_screenshot.png

0 Kudos
Message 7 of 8
(2,669 Views)

Hi Jamiva,

 

cool thank you for your helpful tips.

 

The .wmf file is now transfered to the Windows PC, so far so good.

 

But if the file c:TST00216 is not exist in the N 8973 Internal Memory before I start your VI there is no data Transfer to the PC started.

If the file C:TST00216 exist in the Memory of the N 8973 there is no update of the Screenshoot.wmf information to the PC, if I want start a new measurement.


@jamiva wrote:

You have lots of problems in your VI. No wonder it didn't work. I started from scratch and attached a VI showing the way I would do it. It's probably not perfect but it's a start. It may just work as-is, or may need a few tweaks.

 

EDIT: I'm not sure that the path is correct. It may need the "\". If what is shown doesn't work, try using "C:\TST00216.WMF."

 

get_screenshot.png


You mention I should delete it after the measurement, but than it doesn't work for the next measurement session.

 

Please can you give me an additional hint, to solve this ?

 

Thank your for your efforts

 

Michael

 

 

 

0 Kudos
Message 8 of 8
(2,654 Views)