Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Stepper motor control with MyDAQ

Solved!
Go to solution

Hi everyone,

 

I am trying to control a stepper motor using 2 digital inputs (step and direction) and 6 digital outputs (encoder components) with a MyDAQ. I will need the stepper motor to turn at 11 revolutions per second. The stepper motor has an integrated stepper driver that I am using to communicate with. There will be 200 steps per revolution so I need the DIO lines to run at a 2200 Hz. With the VI that I have made, which is very simple because I just began working with, I have only been able to reach around 7 revolutions per minute, or 0.1167 revolutions per second. Based on the other sources that I have looked at, I will need to utilize the MyDAQ counter to write the signal fast enough. Do I need to get a different board or is there a simpler solution?

(This was originally posted in the Academic Section, but I had a feeling it wouldn't gain a response as quickly as here)

Thanks!

0 Kudos
Message 1 of 3
(3,655 Views)
Solution
Accepted by topic author lucas171

myDAQ has 8 DIO lines but they are software timed.

It means that it is difficult for myDAQ to work with precision and fast timing.

(I found a blog which accomplished desired project with myDAQ... Controlling Stepper Motors with NI myDAQ)

A workaround is using counter feature. See manual below.

USER GUIDE NI myDAQ (Page 16)

 

Changing to other device which has Hardware Timed DIO is best way.

There are many candidate, DAQ, FPGA....

Certified LabVIEW Developer
There are only two ways to tell somebody thanks: Kudos and Marked Solutions

GCentral
0 Kudos
Message 2 of 3
(3,634 Views)

I figured as much, I'll just be coding an arduino to work at the frequency desired to save money. My plan is to have the MyDAQ send code to the isolated Arduino to run at the desired frequency and pulse a certain amount of times. I tried using the arduino before the MyDAQ but I ran into the same software-timed issues. I just was hoping to avoid having to buy another DAQ system or code in arduino. But it appears coding the Arduino will be the cheapest solution. Thanks!

0 Kudos
Message 3 of 3
(3,620 Views)