From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

PXI

cancel
Showing results for 
Search instead for 
Did you mean: 

generating single cycle sine wave using pxi5402

Hi,

 

I'm a relatively new user of NI hardware, had some experience with cRIO systems but not PXI

 

I've got a PXI chassis with a PXI5402 fgen card, I'm trying to generate a single, double and triple cycle sinewave (user selectable) but have very little experience with creating waveform files, is there a guide to doing this or is there a vi which lets me create a (relatively) custom waveform, I'm using the 'fgen function generator.vi' example and was hoping to build on this, I'd like to be able to continually transmit my waveform or set a specific number of transmissions

 

any help appreciated!

0 Kudos
Message 1 of 6
(5,617 Views)

Hi there, 

I belive that what you are trying to achieve would be best achieved using the arbitrary function mode, unfortunately this isn't supported by the PXI-5402. As it is a  A PXI-5412 would be better suited to this task. 

That is not to say, however, that this is impossible. I believe you can achieve single cycle generation using list frequency mode. http://zone.ni.com/reference/en-XX/help/370524M-01/siggenhelp/mode_frequency_list/

This forum post explains a little more: http://forums.ni.com/t5/PXI/PXI-5402-Burst-generation/m-p/2163496

Although the forum above mentions using multiple frequencies, list mode allows you to set a duration of signal generation allowing you to choose the number of cycles to generate through timing. 

I recommend modifying the Fgen Sweep Generator.vi example to generate only one frequency for a specified duration. 

I hope this helps. 


Tim, CLD, CTD
National Instruments (UK & Ireland)
________________________________________________
"No problem is insoluble in all conceivable circumstances"
Message 2 of 6
(5,593 Views)

many thanks Tim! I will give it a try and report back with my success/failure!

0 Kudos
Message 3 of 6
(5,585 Views)

Hi there,

 

the example from the burst generator post was very useful, I've built something very similar myself, however I'm struggling to generate 3 cycles at 5MHz, is this a hardware/software limitation? it works if I drop the frequency to 1MHz but the transducers I'm trying to drive have their peak sensitivity at 5MHz

 

any suggestions?

0 Kudos
Message 4 of 6
(5,573 Views)

Hi, 

The PXI-5402 can generate signals up to 20 MHz so this should not be a problem for it. 

http://sine.ni.com/nips/cds/view/p/lang/en/nid/202642

Could I see the code that you have written with the numbers you are using?

What occurs when you try to generate 3 cycles at 5 MHz? Have you been seeing any errors? If so what are their error codes?

Cheers,

Tim, CLD, CTD
National Instruments (UK & Ireland)
________________________________________________
"No problem is insoluble in all conceivable circumstances"
0 Kudos
Message 5 of 6
(5,555 Views)

Hi Tim,

 

I believe I've cracked this, according to the datasheet for the PXI5402 the minimum step duration is 1.28uS, 3 cycles of a 5MHz sine wave are only 600ns in duration, so at 5MHz, the shortest step duration in a frequency list will be 8 cycles

 

As my final application is likely to be used at lower frequencies (plus I'm looking at purchasing an AWG rather than AFG) this will probably not be an issue in future

0 Kudos
Message 6 of 6
(5,553 Views)