I need to drive a steppermotor (with a stepper driver). For this I'm using a cDAQ-9714 and a NI-9472. The speed of the stepper motor has to follow the profile on the figure below:
How could I do this?
I have tried something but I'm not able to control the number of steps with is (because I use continuous samples).
What DAQ hardware do you have for this? In a previous thread a couple months back, I didn't think your hardware would support what you're trying to do. Did I get that wrong? Or have you upgraded your cDAQ chassis? One way or the other, is your hardware in fact capable of buffered counter pulse train output?
Have you confirmed that your hardware will generate the buffered frequencies you calculate? Have you tried Finite Sampling instead of Continuous?
Note: you should write the buffer of freq/duty cycles before calling DAQmx Start. The query of "Is Task Done?" is mainly for Finite Sampling tasks -- a Continuous task should *never* be done. The trajectory you made is linear by index, but is by *no* means linear by time.