-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed-loop position control mode jumping along a trajectory #10
Comments
Hi again Stefan, Several comments under this Youtube video suggest that it might be a potential firmware issue with the actuator and that the manufacturer could supply you with an updated firmware that allows you to change the acceleration limits to 0 which should fix this behaviour:
I have not come around to test this though. If you try it out (or MyActuator comes back with an explanation), please let me know! |
Hi Tobit, Setting the position planning acceleration and deceleration limits to 0 seems to have worked - each motor I've tested can now follow a smooth curve on position control. Good find on that video. I wonder what setting these parameters to 0 actually does though... Maybe it unlimits the acceleration? FYI MyActuator did get back to me as well. They said:
Which I take to mean a time step of either 2 ms or 4 ms (depending on your interpretation) is required. I'm using 2 ms now and so far its working well. However, prior to changing the acceleration limits the jumping behaviour occurred regardless of time step. For future reference: I have motors of two RMD models and both exhibited the same behaviour (and are fixed by the same method): X8-Pro-H V3 1:6 and X8-Pro V2 1:9. Thank you also for your thoughts re: adjusting the max velocity value as a potential improvement. Doing so changed the speed at which the motor would jump from one position to another but it would still stop at each position for a moment. I wasn't able to find a value that resulted in sufficiently smooth movement. Cheers and thanks again! P.S. This fix is helpful, but I am also still interested in an implementation of Motion Mode Control as #9. Thank you for taking a look at that - I look forward to hearing your thoughts. |
Just to add a couple details: I was able to change the acceleration limits to 0 without a firmware update. I did so with a manually sent (can-utils cansend) CAN frame though, since I think there is a lower bound on the allowable values in your code (though I didn't try to use it). Presumably I could have also done so in their software connecting through the UART module. |
It is likely that you can't send these values through my code. I implemented it according to their protocol documentation. Setting the limits to Yes, I have seen the 2 ms (and therefore 500 Hz update rate) as well in previous tests, see 2b-t/myactuator_rmd_ros#1 (comment). |
Thanks. Yes it may be helpful to have something in the code to change acceleration limit to |
Hello again Tobit,
I have been trying to use closed-loop position control commands (using your repo installed as a python package) to get a motor to follow a smooth position curve: as a simple test, a sin(t) curve with a typical time step of 1 ms (though I have tried various step sizes up to 0.1 s and down to 0.1 ms). Like this:
However, this results in my motor jumping to various positions along the expected curve and stopping at each for a moment (maybe about a half-second), like it is only receiving some of the commands and ignoring the others. The frequency of the jumps does not seem to vary with time step size that I can tell. Have you experienced similar? Do you know if there is a substantial delay between when these motors will accept new closed-loop position commands? I'm using several RMD-X8-Pro-H V3, and each I've tested has done the same.
I have also tried various max velocity inputs, which as expected changes the speed at which the motor jumps from one position to the other, but otherwise is the same.
I'm aware this may be an issue with the motor rather than with your repo, so I apologize if this is an inappropriate forum for this discussion. I just figured you may be knowledgeable, so it was worth asking. I have reached out to myactuator for comment also. If this is just a behaviour of the motor for this control mode, I would like to try Motion Control Mode as an alternative, thus #9.
Thanks again,
Stefan
The text was updated successfully, but these errors were encountered: