Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

How to Create Pulse train AND Variable width pulse at same time

Solved!
Go to solution

Hello All,

    I have an NI PCI-6251 that comes with 2 counters, a FREQOUT port and then some DIO, DAC's and ADC.  I would like to trigger a variable width pulse (easily done with two counters) and a gated frequency output at the same time.  Thus I would like to end up with one line that will output HIGH for some variable amount of time while another outputs a pulse train for some variable of time.  This is easy to do if you have 4 counters but I only have one.  Does anyone have an idea to implement both of these things AND have them trigger at the same time with the PCI-6251?

0 Kudos
Message 1 of 3
(4,059 Views)
Solution
Accepted by topic author DrNO23

Is the line high for the same duration as your gated pulse train?  

 

If so, configure the first counter as a single pulse output, configure the 2nd as a continuous counter output but with the internal output of the first counter as its pause trigger (pause when low).  Start the 2nd counter before the first.

 

If not, then you would have to use digital output to replace at least one of the counters (the max DO sample rate is 10 MHz so it would give less resolution compared to the 80 MHz timebase of the counters).  So you would just write the pre-determined waveform to the DO buffer and clock it at the desired rate and number of samples to give the signal you want.  You would need to generate the DO clock from some other subsystem like FreqOut.

 

 

Best Regards,

John Passiak
0 Kudos
Message 2 of 3
(4,058 Views)

Thank you so much!

 

I can't use your first method since I would like to have the pulse train start at the beginning of the timed pulse and then end sometime after (I'm trying to capture the pulse and the transient).  But your second method will work perfectly, since I can construct a pulse for DO and then trigger it when I want so that:

 

DO-0: Variable width pulse

CTR0/1: Gated Pulse Train

0 Kudos
Message 3 of 3
(4,035 Views)