LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Error with Agilent B2902A configure source.vi

Hello,

 

 I am having issues with the drivers for Agilent B2900. I am using an Agilent B2902A instrument and I am trying to configure the source, perform and measure a sweep, and then output all values into a CSV file. However, I keep getting the same error of -113, "Undefined Header" followed by +0, "No Error". This seems to only happen when I have configure source.vi and I'm not sure if there's another method to get a sweep to work using other vi's. I have also tried the given examples that are in the driver itself with the same error occurring due to configure source.vi. I know that the example should work so I am unsure why this is failing and if there is a installation error or some file that I am missing. The system I am trying to run is also interfacing with a Keithley 707B which works well and I have tested both instrument's addresses to see that both can be queried. I have attached the original error that I get along with my current system. Any and all help is appreciated!

0 Kudos
Message 1 of 9
(1,060 Views)

If you back save for LabVIEW 2021 I can have a look.

But that error is usually a syntax error in a command.  Providing a string when a number is expected.  

Craig

0 Kudos
Message 2 of 9
(1,031 Views)

Here is the 2021 Labview version of the code. I also added the custom sub-VIs that I made for the interface between the Keithley and the Agilent instruments

0 Kudos
Message 3 of 9
(1,003 Views)

There are lots of potential problems with your code.

 

- As a first step, take the instrument initialization (both K700 and B2900) outside of the FOR loop. You should not be re-intializing every itteration, it appears you simply want to change some switch parameters and biases.  You aren't closing communications in the loop, so trying to re-establish a link might be the issue.  If you are using the INIT vis to reset the instrument, don't.  Simply issue the reset command, and make sure the timeout for that instrument is appropriately long so it doesn't return an error. 

 

- After sending a string of commands to B2900, and before executing a measurement, check for errors and handle the errors.

 

- For some reason your channel controls are v16 when i32 is expected.  That shouldn't cause an issue, but its good to look at the red coersion dots to see if some input is in a format the subvi is not equipped to handle.

 

- It would be good practice to make a subvi for the B2900 measurement setup, that would make your code easier to read.  Bundle all the settings that are now inside the loop and feed to a subvi and unbundle as needed.  It looks like all those settings are not changed within the loop anyway.

 

I suggest making the changes to the for loop then running this in Highlight execution and specify where the error occurs.  Narrow it down and perhaps it will be obvious.

 

Hope that helps.

Craig

0 Kudos
Message 4 of 9
(968 Views)

Honestly this would not be the first time an Agilent (or any other) instrument driver had a bug in it.

 

I remember the old drivers for the Agilent 3497xA series was missing a semicolon in one of the VI's that caused a similar error. 

 

You might have to get the SCPI programming manual for that instrument out and make sure the Initialize VI is sending the commands using proper syntax

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 5 of 9
(964 Views)

I got some help and found that it was missing a source item for proper initialization. I saved it and have it here in case anyone else has a similar problem with this driver. This belongs under "public/configure/source output" for the driver folder.

0 Kudos
Message 6 of 9
(952 Views)

thank you for the advise! I was going to make some of those changes. I had issues when I had stripped it down to the bare system until a friend went through the configure source VI and found a missing part. I'll also make those changes since I am new to LabVIEW and still learning. 

0 Kudos
Message 7 of 9
(950 Views)

Perhaps a backsaved copy or a screen shot to see what you have done?

Thanks.

 

0 Kudos
Message 8 of 9
(944 Views)

Here's what I got when I back saved for the 21.0 version.

0 Kudos
Message 9 of 9
(937 Views)