Trajectory with both velocity and position #175
Replies: 9 comments 7 replies
-
The trajectory produced by the "trajectory generation" tool encapsulates the full state information thanks to differential flatness. If you want to specify velocity constraints for each waypoint, you can quite easily modify the "trajectory generation" tool to add these constraints. We have an old branch with such changes https://github.com/ctu-mrs/mrs_uav_trajectory_generation/tree/matous so you can take the commits in there as an example. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Hey, thanks for finding this! I can replicate the issue, so I will solve it asap. Will keep you posted. |
Beta Was this translation helpful? Give feedback.
-
Hey @PrimaryComet, I fixed the issue. It is now available on the unstable PPA and tomorrow, if the tests pass, on stable. Thanks for reaching out! |
Beta Was this translation helpful? Give feedback.
-
Thank you, it now works with the trajectory loader! My current problem is regarding the in-built collision avoidance:
Since I am attempting to evaluated trajectory generators, and safety is one of the key metrics, could you advice on how I might turn all collision avoidance off? I have guessed it is a collision avoidance problem as the issue occurs very close to obstacles. Many thanks again |
Beta Was this translation helpful? Give feedback.
-
Thank you again, that has solved that issue! However, I now think I have found a potential solution to my first problem. The trajectory generator that I am testing outputs commands which seem to be compatible with your TrackerCommand. That is, it generates position, velocity, acceleration, heading, and heading rate at a frequency sufficient to be used by a controller, rather than a tracker. Is there a method you would suggest for disabling the tracker such that I can publish TrackerCommand messages directly, or is that not possible? I have looked at creating tracker plugin to pass the commands directly but that seems somewhat daunting at the moment, particularly as the tracker plugins are designed to accept one of Position, Velocity, or Trajectory commands. Thank you again for all your help! |
Beta Was this translation helpful? Give feedback.
-
I have now successfully implemented a custom tracker as you described. I have one more question that will hopefully be my final query: Additionally, I cannot for the life of me find where your "waitForRos, waitForControl" elements are defined in session.yml. I would like to add another file to be launched after takeoff, but I cannot figure out where I would even begin to look for these waitForX commands. Thank you so much again! |
Beta Was this translation helpful? Give feedback.
-
Ah good, I shall keep an eye out for those, and I found the waitFor* function I needed thank you, I didn't even need to make one! The tracker I have implemented that forwards commands directly from the trajectory planner I'm testing is able to track very closely, but I'm still getting some deviation from the trajectory, and I was wondering what I could do to reduce that. Obviously some deviation is expected, but I'm getting a few centimeters of RMS error in the tracking, which causes crashes in some challenging scenarios. I've included an example screen shot below. The main issue in terms of collisions is the tendency of the drone to take the corner wider than the trajectory allows as you can see. [Red = commands sent, blue = path traced by odom] The trajectory I'm generating in the screenshot has velocity, acceleration, and jerk limits, all of which are lower than the limits set in the constraint manager (I'm currently using your default "medium" constraints). I can reduce the tracking error by lowering the trajectory constraints naturally, but surely the controller should be able to follow these commands since they are within the constraints set by the manager. |
Beta Was this translation helpful? Give feedback.
-
I am currently providing all derivatives down to Jerk (along with heading and heading rate), as that is all the planner I'm trying to benchmark can output. As we would expect, when I removed the higher order derivates, the performance became worse. As for the reasons for control error: Oh and that's good to know about the dynamic constraints, thank you! Also I forgot to mention that I'm using the SE3 controller as it has a lower error than the MPC controller. |
Beta Was this translation helpful? Give feedback.
-
Hi, I'm looking to evaluate some methods of trajectory generating using the MRS UAV system. The output of these trajectory generators is intended to be a feasible trajectory with position, velocity, acceleration, yaw, and yaw-rate. As I understand, you cannot control (for example) position and velocity simultaneously using the control manager. Is there a way to achieve this natively with your system?
Many thanks for your time
Beta Was this translation helpful? Give feedback.
All reactions