Signal Generators

cancel
Showing results for 
Search instead for 
Did you mean: 

How to generate sine pulse on PXI-5412 at a user-specified rate?

Hello,

 

I am trying to generate a sine pulse (e.g., 10 cylces at 100 kHz) at a user specified rate (~ 0.5 sec) using a NI PXI-5412.  Is there a property to specify the repetition rate for the pulse generation?  The NI examples I have found repeat the generation by incorporating the niFgen Initiate Generation.vi inside a while loop.  I would like to generate the pulses continuously while acquiring on a NI PXI-5105 and performing several measurements on the acquired waveforms.

 

Thanks for any and all help!

 

Barbara

0 Kudos
Message 1 of 5
(7,079 Views)

Hi Barbara,

 

I think that the best way to set the rate you retrigger your sine wave output is going to be using the Stepped Trigger Mode for an Arbitrary Sequence. In this case you actually have to use either an external "gating/retriggering" signal or you can use a software trigger to retrigger your sine waveform generation. There is a good Knowledgebase article on our website that has a good example VI attached that does just this.

 

http://digital.ni.com/public.nsf/allkb/94A0C5C91F3E162086256E78007A5F15?OpenDocument

 

In this example VI an arbitrary sequence is created from a sine wave, a square wave and a sawtooth wave. For your purposes you could just use the sine wave and have it loop 10 times. The frequency of the output signal is going to be based off of your sampling rate and the amount of points you choose to use to represent one period of your sine wave from the pre-loaded sine wave that is in the onboard memory of your 5412. If you're curious about how the NI-Fgen functions work for this example check out the NI Signal Generators Help and search for "Arbitrary Sequency Mode." 

 

I have take the example VI in this Knowledgebase article and modified it so it should be a little more usable in your application. The most important thing to remember is that in order to control the rate at which this waveform retriggers/regenerates, you will need to use some sort of "timing" signal, like pulse train generation of a frequency that you choose. This sort of thing can be achieved with a pulse train generation task with any of our multifunction DAQ boards or any of our Counter/Timer boards such as the NI-6601 or NI-6602. Thanks.

 

Chris W

0 Kudos
Message 2 of 5
(7,066 Views)

Hi Chris,

 

Thanks for your help.  I should have been more clear and told you that I am able to generate the pulses using "Arbitrary Sequence Mode" and setting NIFGEN_ATTR_ARB_REPEAT_COUNT to the number of cycles in the pulse.  I am familiar with using the counter on a multifuction DAQ board (PCI-6110) but this board is no longer available to me.  Using the NI PXI boards that are available (PXI-5412 and PXI-5105) do you know if it is possible to generate the timing signal (e.g., using the onboard clock of the PXI-5105) with either board?

 

Best regards,

Barbara

0 Kudos
Message 3 of 5
(7,041 Views)

Hi Barbara,

 

I guess I am still unclear on exactly what your end goal is. I'm not sure what you mean when you are talking about generating the timing signal with either board. Where does generating your arbitrary sequence come in to play here? 

 

What it sounds like to me is that you just want a common reference clock between the 5105 and the 5412. If this is the case you can PLL your onboard reference clock of both of these cards to the PXI_CLK_10, which is the 10MHz clock on the backplane of your chassis, so that both of your cards will be using that clock as their reference clocks. This means that both the cards can derive a sample clock from the same reference clock. Using this and a common trigger to start a generation/acquisition will synchronize the generation/acquisition with both of these boards.

 

Take a look at the specifications documents for the 5105 and the 5412 and also the NI Signal Generators Help and the NI High-Speed Digitzers Help for more information about this option.

 

5105 Documents

 

5412 Documents

 

Chris W

Message Edited by Chris W. on 12-16-2008 12:12 PM
0 Kudos
Message 4 of 5
(7,025 Views)

Hi Barbara, Chris

 

I am having a similar problem wherein I want to generate a 1 MHz 10 cyled windowed waveform at a specific rep rate (say 10 waveforms per second)

 

However once I configure my waveform, I get a continuous stream of waveforms. Is there anyway to configure the rep rate of the PXI-5412 so that I get just one windowed waveform every specified time interval?

Message 5 of 5
(5,381 Views)