Actually, I already have all the kinematic formula done for my robot, even the jacobian for speed control.
I know gear ratio will lower the speed, but some joint like shoulder and elbow doesnt need to move very fast. However, they do need alot of torque to lift all the weight of the steppers. Industrial robot usually have gear ratio beetwen 100:1 and 200:1 but they use dc motors with encoders.
To move the robot, I send it coordinate in x y z and tool orientation vectors relative to base referential. I made the Inverse kinematics script in python.
So the only problem i have now is the control of the motors with variable speed relative to position. I can send a number of step and a speed value to the motor but im not sure how to make it check the position and recalculate the speed needed after every step.
I tryed this : the motor move 1 step at time with a certain speed, than check the direct and inverse kinematic, recalculate speed with jacobian, and move 1 step again with a new calculated speed and so on… the problem is that if i dont use waitforrobot() after each step, the robot doesnt wait for the step to be moved to recalculate speed and it do all at once, resulting in the robot motors moving only 1 step in total. With waitforrobot() however, the robot stop at every step, making it shake like crazy.
I need to find a way to change the speed on every step done by the motors, and make it move smoothly.
Its the control of the stepper motor that is giving me trouble, not the kinematics. Some motors need to change speed and even change direction while the tool is going from a to b in a lineare or rotary trajectory, thats what we want. im sure there is a way to do that.