05-05-2021 10:36 AM
Hello,
In my project I control 4 stepper motors with 4 drivers DM542T.
I don't have problem to control each stepper motor but I wonder if there is a way to make acceleration and deceleration ?
There is an easy way or I need to make a custom command to use an Arduino library like accelstepper.h ?
Thanks
07-20-2021 10:55 AM
Hi! Would you mind posting the VI you're using to control the motors? I'm using the same DM542T driver to control a Nema 23 with an Arduino Uno, and I'm a little lost on how to make LabVIEW communicate.
Thanks!
07-20-2021 11:15 AM
Hey, tck1378
Sinc have posted this video? https://www.youtube.com/watch?v=qwvP2AzoB_M
he uses uln2003, which requires a much more complicated VI to make it work.
since you only need to provide step and dir signals, you can use his implementation considering only activating these two signals.
hope it helps you.
07-20-2021 11:51 AM
I did watch that video, and it was helpful logic-wise but my motor is bipolar 4-wire and this video uses unipolar 5-wire. His four controls correspond to the 4 phases in the stepper motor, whereas my wiring need to control just a step and pulse, so basically the functionality of the program is different.
07-20-2021 12:00 PM
yes, you are correct. abstract the fact that he uses a different motor, since it does not matter.
note that his code runs in a while loop, at the frequency of the desired step speed. Instead of using four digital write in sequence at 4 different channels, your application is much simpler: you only need to write true and false how many times your desired step quantity is needed.
07-21-2021 03:30 AM
The best way I found in my case is to use "LINX custum command" and use an arduino library to control the stepper motor (AccelStepper).
You have to modify the firmware of your board to include a custom command that use a function of AccelStepper.
Then you need to use "Custom Command.vi" to send the amount of step you whant to move with the custom command number.
The AccelStepper library works really well with a lot of functions.