Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

how to generate 0-200kHz square wave using NI 9269 module

Hi, I am using NI-CompactDAQ chassis 9174 with NI 9269 analog output module, I am trying to generate a 0-200 kHz square wave (50% duty cycle) to control a step motor. the frequency should be changed inside the program in response of a feedback signal. the duty cycle is fixed. amplitude 5V.

 

I downloaded the Continuously Generate Voltage using Internal Sample Clock - Non Regeneration.vi

https://decibel.ni.com/content/docs/DOC-12478

 

it works fine for low frequency 0-1Khz, but it is not working right for high frequency above 20khz, the output signal got mixed frequency when I increase the frequency when the program is still running.

 

do anyone has experience using this module to generate square wave? can you provide me a successful example code?

 

thanks.

 

ping

0 Kudos
Message 1 of 2
(3,415 Views)

When you try 20kHz, what is sample clock rate and sample size set to? What exactly do you mean by mixed frequency? Can you attach an image of the output waveform?

0 Kudos
Message 2 of 2
(3,406 Views)