What is ideal way to (position) control Steppers/AC servos?

Thread Starter

abuhafss

Joined Aug 17, 2010
255
Hi

I have using Steppers and AC servos with Arduino for quite some time, without any library simply by pulsing the PULSE pin with digitalWrite HIGH/LOW. Recently, while using an AC servo, I realized that it is probably not the best way.

The servo is coupled to a roller set which feeds predefined length of a metallic strip to a processing unit. The feeding is done when a signal is received from a sensor. The problem I am facing is that the feed length is not consistent. After, say 3 or 4 times, the length would reduce by about a millimeter and then next few lengths would be OK and it goes on.

Looking for some guidance to rectify the issue or to some other approach.
 

KeithWalker

Joined Jul 10, 2017
2,604
You are assuming that the way you are driving the servo is causing the problem. Have you checked the rest of the system for mechanical slippage. e.g. the coupling between the motor and the roller, the metal strip on the roller, etc?
 

Thread Starter

abuhafss

Joined Aug 17, 2010
255
Yes, I have already checked all the factors involved except the spider coupler. I will definitely check it tomorrow morning.

Meanwhile, for the sake of knowledge I want to know about some dedicated method of generating pulse train for position control.
 

LowQCab

Joined Nov 6, 2012
2,620
The "Metallic-Strip" is being moved by "Rollers" ????
Can the "Rollers" slip ?

The most accurate way would be several Photo-Sensors that
actually detect and report exactly were the end of the part is.

Plus or minus 1-Millimeter accuracy might be impossible using "Rollers".

Solenoid-actuated, physical "Material-Stops", might be what You need.
This would let the "Rollers" push the part hard against the Movable-Stop,
guaranteeing accurate positioning.
.
.
.
 

Thread Starter

abuhafss

Joined Aug 17, 2010
255
My set-up is basically a replica of a Chinese unit which is controlled with a PLC. Its feeding length is quite accurate. I am using Arduino (as I have no experience of Ladder programming).

As for the rollers, both have a gear at one end for proper synchronization. Hence, slippage is only possible if the tension between the rollers is inadequate.

The processing part has no possibility to accommodate a sensor.

EDIT:
I have checked the communication cable between the PLC and drive. It has only 4 wires, 2 for +ve 24V and one for each, PULSES and DIRECTION. I have also followed the same. The Chinese unit is running for more than 3 years with accuracy. I have simply replicated it except the PLC.
 
Last edited:

Thread Starter

abuhafss

Joined Aug 17, 2010
255
Have you checked the rest of the system for mechanical slippage. e.g. the coupling between the motor and the roller, the metal strip on the roller, etc?
I checked the spider coupler. To my surprise it has worn out, though quite early.
Anyway, I will replace it and come back to report if the issue has been resolved.

BTW, bundle of thanks for drawing my attention to it.
 

Thread Starter

abuhafss

Joined Aug 17, 2010
255
I have replaced the spider coupler and yes, the issue has been resolved.

However, my question is still not answered. What is the ideal way to drive Steppers for position control?
 

LowQCab

Joined Nov 6, 2012
2,620
First,
find the best compromise between Speed and Gear/Belt-Reduction,
and the required Resolution / Positional-Accuracy.

These are all mostly mechanical design considerations,
and, your Motor choice, ( Power and number of Steps available ),
will limit the ultimate accuracy and speed of positioning.
---------------------------------------------------------------------------------------------
Then use a Rotary-Encoder to provide an Absolute-Position-Signal which
will act as Feedback to the Computer.

The Encoder should be attached to the Motor-Shaft
and match the resolution of the Motor exactly.

The Software being used will benefit from a customized P.I.D. Algorithm to
reduce target-over-shoot and possible oscillations.
.
.
.
 

MaxHeadRoom

Joined Jul 18, 2013
26,243
Yes, I have already checked all the factors involved except the spider coupler. I will definitely check it tomorrow morning.

Meanwhile, for the sake of knowledge I want to know about some dedicated method of generating pulse train for position control.
If you want some precise machine control, you could take a leaf out of the DIY'ers CNC method, i.e. use a Gecko drive and download a copy of the free Mach3 software
https://www.geckodrive.com/
 
Top