Use the following template to help create your post:
What model(s) of servo are you using?
3 - MX-28 AT (2.0) motors connected in a daisy chain.
Describe your control environment. Include the controller or interface, operating system (and version #) of your computer, and how you are powering your robot.
U2D2 controller, Windows 10 OS, SMPS 12 volts by Dynamixel
For programming posts, state any libraries or example code you are using. For software posts, be clear about which version of software! R+ Task 3.0, R+ Task 2.0, and RoboPlus Task (“1.0”) can have very different troubleshooting steps, as just one example.
I used sync-readwrite code and tweaked it according to my requirement. I will attach a snippet of my code here. The issue is my motors are working fine when I am running the default code whereas when I run my code, one of the motors is showing a lag in the movement.
Following are the equations to control the motors :
alpha = 90/(2tanh(2.7)) * tanh(2.7sin(2pift)); % For motor 1
phi = -140/(2asin(0.8)) * asin(0.8* cos(2pif*t)) ; % For motor 2 ,3
q1 = alpha(1,n)/0.0879 ; Q(1,n) = q1 ; m_pos(1) = p1 + Q(1,n); %motor2 q1 = phi(1,n)/0.0879 ; Q(2,n) = q1 ; m_pos(2) = p2 + Q(2,n); %motor3 q3 = phi(1,n)/0.0879 ; Q(3,n) = q3 ; m_pos(3) = p3 + Q(3,n);
In this code as shown , motor 1 moves at the end even after other 2 motors came to rest. I am unable to figure out why ?
- Remember to mark your post Solved when applicable!