Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

In NI-DAQmx, how to change the frequency of a pulse train?

I was using "GPCTR_Change_Parameter()" to change the frequency of my pulse train in Traditional NI-DAQ and Labwindows/CVI; is there any function can do the same thing in NI-DAQmx without restarting the task?
0 Kudos
Message 1 of 3
(3,070 Views)
You can do this in one of two ways, depending on the version of NI-DAQ you are using. If you are using 7.2 or later, you can use the counter write functions (ex: DAQmxWriteCtrFreq()), which are available for each flavor of pulse generation tasks (Freq, Time, Ticks). If you are using NI-DAQ 7.0 or 7.1, you can modify the attributes directly (DAQmx_CO_Pulse_HighTime, DAQmx_CO_Pulse_LowTime, etc). Keep in mind that for each attribute pair, one of the attributes will cause the counter to load the new pair. The attribute that causes the load is LowTime, LowTicks, and Frequency.

I hope this helps!
gus....
Message 2 of 3
(3,070 Views)
Great! Thanks a lot.
0 Kudos
Message 3 of 3
(3,070 Views)