-
Notifications
You must be signed in to change notification settings - Fork 195
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
Send points while moving without BUSY in return #447
Comments
you can't. Or at least, not in a single message. MotoROS uses a trajectory streaming approach, meaning So there is no way to send "a whole trajectory", it's always individual points. You could say that a trajectory smaller than the depth of the buffer is transferred "whole", but even that would not be technically correct.
As the size / depth of the mentioned buffer is finite and trajectory execution is typically slower than the time needed for streaming points, at some point the buffer is full. At that point MotoROS starts sending Management of the buffer is independent of the control flow of the task executing the actual motion, so the robot is typically "in motion" while MotoROS is still receiving incoming trajectory points (see my explanation above). Important: whether or not you receive While it's not completely up-to-date any more, you may be interested in Motoplus-ROS Incremental Motion interface - Engineering Design Specifications, which describes the design and implementation of MotoROS. |
As I believe this isn't (going to turn out to be) a problem with any of the packages here in this repository, I'm closing the issue. Feel free to keep commenting on it of course. If it turns out there is indeed something actionable, we can re-open. |
Has this clarified things @tingelst ? |
Yes , a bit. I haven't had the time to test this in the lab, but can our problem then be that we send trajectory points to fast? I see that there is a sleep in the ros driver:
|
I wouldn't know, as I don't believe you've described your problem. Seeing There is no way for a buffer to be "large enough" for all possible trajectories, hence some way to tell the sending side to "back off" for a bit is always needed. That's what a reply with
that sleep is there to avoid a busy wait. It isn't strictly required, as long as |
Just re-read your #447 (comment) and noticed:
if by "too fast" you mean "are we trying to send too many points in too short a time?", then yes, that could be the cause of whatever problem you are having. The The consumer tells the producer to wait sending more information until there is space again in the queue. In this case, space is created by the motion thread having processed a trajectory segment. In other words: space in the queue is created by the robot physically moving through your trajectory. |
Then we agree, thanks @gavanderhoorn! I was just in the lab and managed to send several points resulting in a smooth motion by waiting for a not busy reply. I implemented the same waiting mechanism as in the ros driver. |
We are having some troubles sending new waypoints while the robot is in motion using our own library: https://github.com/ra-mtp-ntnu/moto.
We have some questions:
motoman/motoman_driver/MotoPlus/MotionServer.c
Line 1122 in 2cdbe79
The text was updated successfully, but these errors were encountered: