Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Continuous acquisition using Agilent U2356A and Labview

Hello Steve,

        I am glad that you found something that is going to work for you.  We are trying to get a U2356A on loan to reproduce the problems that you are running into, so if you have an extra one that we can borrow, please email us at instrument.drivers@ni.com.

 

Cheers,

 

NathanT

0 Kudos
Message 21 of 33
(3,131 Views)

Hi Nathan,

 

Unfortunately, I can't loan out any of our equipment, as much as I would like to help you out.  I don't know if you've tried or not, but I know that Test Equity does rent out equipment, and they did just get in the U2300 series, so you could check with them.

 

Steve

0 Kudos
Message 22 of 33
(3,128 Views)

Hello again,

 

Well, I've run into another slight problem, just as I was finishing up the program ... figures.   Anyway,  what I would like to do is to have two separate loops running, with DAQ controls in them.  The first loop will have all of my acquisition stuff in it, and it works just fine to date.  The second loop will be a duty cycle control for one of the two outputs that the DAQ has.  The problem is that I can't just grab the VISA resource wire from the exisiting loop (or just before it enters the loop), because the unit will not function properly.  I also have different timing going on in both loops, so I can't combine them into one big one.

 

Does anyone know how I can run two paths of the resource name in parallel?

 

Thanks,

Steve

0 Kudos
Message 23 of 33
(3,102 Views)

Analog Input and Analog Output tasks can run continuously, just put them in parallel, like so:

2009-06-19_145329.PNG

---

Peter Flores
Applications Engineer
0 Kudos
Message 24 of 33
(3,099 Views)

Thanks for the quick reply.  Does this also work if I'm controlling the equipment with the VISA interface, because that is how the Labview driver is written.

 

The VISA interface requires a resource name, and if I pass the one that is already open, it does not like it at all.

 

Thanks again.

Steve

0 Kudos
Message 25 of 33
(3,098 Views)

krazyups,

 

Sorry about that! I keep thinking you are using NI DAQ. For your device it looks like the input and output are different subsystems, which should imply that they can run in parallel. As far as the LV programming, you must use the same VISA session. This means it should all be in the same loop. You should be able to configure all your settings for the input and output before starting the loop, then read and write in the same loop. All the timing should be taken care of by the device, so all you should need to do from LabVIEW is supply data to be ouputted and read the input buffer every once in a while.

 

Unfortunately, I do not have one of those guys to test it over here. Hopefully this helps!

---

Peter Flores
Applications Engineer
0 Kudos
Message 26 of 33
(3,093 Views)

I think you just confirmed what I was fearing, that everthing needs to be wired into the same path, and that presents a problem.  I ran into this a little earlier with the program, I'm actually using both outputs of the DAQ; one to control the power supply, and one to control a FET which will cycle the output if desired.  Fortunately at the time, the power supply control did not need to be timed in any way, just turned on when the acquisition started and turned off when it stopped.

 

However, this other output needs to be cycled (ideally) at 5Hz, since that is what our system normally operates at.  I just figured that I could have a separate while loop below my main two (producer-consumer type) while loops and just wire in the error and the VISA resource name, and be good to go.  I would just use the function generation block, but unfortunately that doesn't allow for a change in duty cycle, so I have to go with the arbitrary waveform, and input a 1x100 array into it (this gives me control down to 1% duty cycle).  This also unfortunately means that I have to have a separate while loop for that, with a delay of 200ms, in order to achieve the 5Hz output.

 

It's too bad that I don't have a faster computer handy (1.6GHz P4 laptop ... yuck!), because then I could just set all of my delays to 200 ms and I wouldn't have a problem, but the computer I'm using can't crunch the code that fast.  My program has the data being scaled and being outputted to a file, on-screen table and an on-screen graph at the same time (the tab control makes it look a lot nicer than it sounds).

 

I would post the VI's that I've created, but I don't want to get on the list of how you shouldn't code, Smiley Very Happy because it's rather ugly ... and large.

 

Thanks for all of your help.

Steve

Message Edited by krazyups on 06-29-2009 04:55 PM
0 Kudos
Message 27 of 33
(3,091 Views)

Hello Steve,

       We have made updates to both the U2300 and U2500 LabVIEW instrument drivers and would really appreciate it if you could download the updated U2300 and let us know if you see any

problems.

 

Thank you,

 

NathanT

0 Kudos
Message 28 of 33
(2,988 Views)

Sure thing, I'll make sure and do that next week.  What does this update address anyway?

 

Thanks,

Steve

0 Kudos
Message 29 of 33
(2,975 Views)
The updates focus on fixing waveform formatting issues that were reported with some of the models in the 2 series.
0 Kudos
Message 30 of 33
(2,946 Views)