ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

Signal Generators

cancel
Showing results for 
Search instead for 
Did you mean: 

Example for AWG in streaming mode?

Hello all,

Does anyone have some example code for using an Arbitrary Waveform Generator in what i believe is "streaming" mode?

Basically, I am trying to do the following:

1) Generate a new block of samples in Labview
2) Write them to the hardware
3) Repeat from step 1...
....

*However*,   physically I want the first sample of each block to be on the wire immediately after the last sample of the previous block... In other words, I don't want any delay or idle time between the blocks....    I realize real-time issues are relevant here, but that's already been taken care of....  I just don't know how to setup the hardware...  When I installed Labview & the drivers, I got a nice set of examples for NI-SCOPE,  but no *Labview* examples for NI-FGEN.   I haven't been able to find any discussions of this on the NI website,  hence this posting...


I'd appreciate any assistance anyone can offer..


Thanks

-Alex
0 Kudos
Message 1 of 8
(10,322 Views)
Hi Alex,

If you included support for LabVIEW when you installed the NI-FGEN drivers, examples should have been included and installed.  They would be found in the NI Example Finder under Hardware Input and Output>>Modular Instruments>>NI-FGEN>>Arbitrary Waveform Generation.  There is an example in this directory that will probably work in getting you started in your application, and it is named niFgen_Arb_Waveform_Streaming_Example.vi.  If these examples are not present in your installation of LabVIEW, I would recommend modifying the installation of the NI-FGEN drivers and choosing to install LabVIEW support.  Let us know if you run into any problems.

Regards,
Andrew W
National Instruments
0 Kudos
Message 2 of 8
(10,300 Views)
I have to pass a waveform from Labview to AWG420 and I don't know own how I do it....Do anybody know how do it????

0 Kudos
Message 3 of 8
(9,572 Views)

I have to pass a waveform from Labview to AWG420 and I don't know own how I do it....Do anybody know how do it????

I tried to pass with waveform with this command: MAGIC 1000<CR><LF>#<Num_digit><Data(1)><Data(2)>.......Data(n) [ClOCK<Clock><CR><LF>]  

but I can not do it.....

   

 

0 Kudos
Message 4 of 8
(9,571 Views)

Hi Vici,

Are you trying to use Gpib or Rj-45 to communicate with your device? There does not appear to be an instrument driver for this device. Can you post the vis you are using? I’m a bit unclear as to what you meant in your post.

Matt

Matt
Applications Engineer
National Instruments
0 Kudos
Message 5 of 8
(9,540 Views)
Can you give me any example of how use this AWG command: MMEMory: DATA <file_name>,<data> for sending a waveform from LAbview to AWG. What kind are array elements???
0 Kudos
Message 6 of 8
(9,518 Views)

The AWG420 progrmmer's manual states that the <data> field should be specified in "488.2 block format". It is not very clear what this means, but I found this site that states:

 

 The BASIC program will send the following data

:MMEMory:DATA ’amiqsico.wv’, #3140 <binary data>

 


#             The ASCII character # initiates binary block transfer
3             Number of digits of subsequent length information in ASCII
140           Length in ASCII of binary data record bytes
<binary data> 140 bytes of curve form

 

So, a valid string may be:

 

 

"MMEMory:DATA 'waveOne.wv', #15 0001020304"

 

 

 

Unfortunately, I have not had experience with this device, so this is an educated guess  :smileyhappy:

 

As far as sending this from LabVIEW, check out Instrument Control in LabVIEW or one of the many articles on GPIB instrument control.

Message Edited by pflores on 06-19-2009 04:26 PM
Message Edited by pflores on 06-19-2009 04:28 PM
---

Peter Flores
Applications Engineer
0 Kudos
Message 7 of 8
(9,502 Views)
Also, since they share the same programming manual, you should be able to use most of the functions in the Tek AWG500 series drivers found at ni.com/idnet.
---

Peter Flores
Applications Engineer
0 Kudos
Message 8 of 8
(9,501 Views)