Software > Software

Stepper acceleration/deceleration

(1/2) > >>

Azraels:
Hello everyone! While I could probably spend time searching for this information with google I thought I may as well use it as my first post. I am in the middle of building an arm with salvaged steppers. This is the second arm I have built. The first one was built using steppers and servos and only had 4 dof plus gripper and was controlled by an arduino and a couple of parallax joysticks. It was pretty limited in range of movement.
The new arm will have 6 dof and substantial more power.
My question is about accelerating steppers from stop. I have been using the 'for' statement in arduino to accelerate and decelerate. example: for(x=0; x<100; x++) { stepper.setSpeed(x); step(1); }.......then continue stepping at speed and then to stop reverse that process. I have tested this and it does work and keeps the stepper from rough stop/starts.
Is this the best way to accomplish this and should I start and stop at 0 speed or higher?

jwatte:
That seems like a reasonable way of doing it, assuming you can get the timing right -- there's no delay built-in that loop, so it may get to full speed pretty quickly. (Maybe "step" does some delaying?)

Also, if step() does the delay based on speed, then you will actually speed up at a slower rate of acceleration in the beginning.

Best would be to use (or build) a library that has built-in support for trajectory ballistics like this, where you can say "go to speed X with an acceleration of Y" and it takes care of it using proper math and interrupts/timers.

newInRobotics:

--- Quote from: Azraels on February 18, 2013, 03:54:02 PM ---Is this the best way to accomplish this [...]
--- End quote ---
In industry it is common to use fuzzy logic to achieve what You want.

jwatte:

--- Quote ---In industry it is common to use fuzzy logic to achieve what You want.
--- End quote ---

Really? I can't find a "fuzzy logic" controller from Kollmorgen or Allen Bradley or Delta Tau, all of whom are large, industry leading motion control companies.
What industry, and what controllers, are you suggesting use bona fide "fuzzy logic"?

newInRobotics:

--- Quote from: jwatte on February 20, 2013, 11:19:37 AM ---
--- Quote ---In industry it is common to use fuzzy logic to achieve what You want.
--- End quote ---


Really? I can't find a "fuzzy logic" controller from Kollmorgen or Allen Bradley or Delta Tau, all of whom are large, industry leading motion control companies.
What industry, and what controllers, are you suggesting use bona fide "fuzzy logic"?

--- End quote ---
Just because You can't find any it does not mean it is not used :) Fuzzy Application Library/Technical Applications/Industrial Automation

Navigation

[0] Message Index

[#] Next page

Go to full version