03-13-2012 10:47 AM
Hi,
I am using square waveform.vi to porduce square waveform but the output is analog output. I want to change it to digital output, how to change it? I am using NI DAQ 6036E (DAQ Card). due to this DAQ card has only 2 analog output, but i need more output . So, i have to convert these Analog output to digital output for my project.
Can any one teach me how to change the Analog output to Digital Output for this example ?
thanks
Regards,
Sam
03-13-2012 11:04 AM
The Analog to Digital function is the obvious choice except your card does not support hardware timed digital I/O. What sort of frequency are you planning on using?
03-13-2012 11:09 AM
I am using the square waveform.vi to produce PWM to control stepper motor.
03-13-2012 01:24 PM
That is not what I asked.
In any case, you would not create an analog waveform to generate a frequency with one of the digital lines. Since it is software timed, get the period, divide by two and use that as the wait after a DAQmx Write of a logic one then after a DAQmx Write of a logic 0. However, this would be a poor method of generating a PWM signal. Why don't you use the counter output?