I have a smart motor with a 4000 count encoder. I need to have my user input a number in inches and have the motor move that distance relative to its current position.
How do I go about this?
We are calculating velocity as follows:
Velocity = X * Y * Z
where:
X = 4000 (motor is a class 5 4000 count per rev encoder)
Y = User Defined distance in inches
Z = User defined value for Hz (motor counts per inch)
I want to move the motor back and forth between the left limit and right limit of the user specified distance in inches assuming a starting position at the center of the user defined distance.
Right Limit = Current Motor Position + (User Defined Width / 2)
Left Limit = Current Motor Position - (User Defined Width / 2)
how do I convert that user defined distance in terms the motor program will understand?
The first thing that needs to be known how far the linear actuator (be it belt, screw, or rack and pinion) moves for one revolution of the motor shaft.
Ex.
If I have a ballscrew that moves 0.200"/revolution, and a motor with 4000 counts per revolution, then a move of one inch would be 5*4000 or 20000 encoder counts.
We are using an animatics H3-0409025B23MS1N1N4N HLD Actuator with animatics 23165DT class 5 motor. Am I correct in saying this actuator / motor combination will move 2.5mm per revolution?
If so my calculation would be
0.098425 * 4000 or 393.7 counts per inch?
Yes... the H3-0409025B23MS1N1N4N moves 2.5mm/revolution of the motor.
The formula in my previous post was wrong....
(distance / 0.98425)* 4000 would give me the correct motor counts per inch assuming an actuator that moves 2.5mm per revolution of a motor with a 4000 count encoder