Skip to content

How to loop a circular course? #4644

Answered by soblin
yhisaki asked this question in Q&A
Discussion options

You must be logged in to vote

One constraint of current autoware is that you cannot set the goal on the same behind ego vehicle. So if the map is circular, your goal must be always

  • ahead of ego position on the same lane
  • on a different lane

In the most simple scenario you can achieve infinite loop by

  • set two circulating lanes, namely A and B
  • starting from A, set the goal somewhere on B
    • the route message should be like {route: {A, B}, goal: g_B}
  • when ego arrived B, reset the route message to something like this using the service:
    • {route: {B, A}, goal: original_start_position_on_A}

you may need more frequent switching / more lanes to always reset the goal to a position ahead of ego and on a different lane

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by yhisaki
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants