Skip to content
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

Orunav_mpc exits abrutly. #33

Open
MFernandezCarmona opened this issue Aug 15, 2019 · 4 comments
Open

Orunav_mpc exits abrutly. #33

MFernandezCarmona opened this issue Aug 15, 2019 · 4 comments

Comments

@MFernandezCarmona
Copy link
Contributor

Hi,
orunav_mpc exits with an error due to several reasons. Whenever this happens, is quite disruptive for the rest of the navigation stack (I always end up restarting the entire stack). For example, here https://github.com/OrebroUniversity/navigation_oru-release/blob/master/orunav_mpc/src/commandSender.cpp#L85

@ksatyaki, @h72a65 , I wonder if it's possible to prevent mpc from exiting or to make vehicle_execution_node able to "restart" (forgetting whatever trajectories sent to the robot and going back to initial status)

@ksatyaki
Copy link
Contributor

ksatyaki commented Aug 15, 2019

I haven't looked deeper into the problem. But, I am guessing that the commands are sent as they are received. And if they weren't sent at the right time, it fails. Maybe it should hold a buffer and send commands from the buffer? I have no idea what happens when the 'laser-emergency' is triggered. Because the robot stop. It should recompute controls from where it left off? Just thinking out loud here.

@MFernandezCarmona
Copy link
Contributor Author

Hi,
'laser-emergency' case is recoverable. Robot resumes after laser detection is cleared.
I'm speaking about other situations, like an illegal speed change is sent to mpc from vehicle execution node.

@h72a65
Copy link
Contributor

h72a65 commented Aug 19, 2019 via email

@MFernandezCarmona
Copy link
Contributor Author

You're right. Probably the best is let mpc to die, as something really concerning has happened and figure out how to "recover" vehicle execution node. Correct me if I'm wrong but we don't need to create any new service: ExecuteTask service has a Task as request, and Task msgs have an abort flag that means discard current task.

Let me put an example:

  • Coordinator creates a new trajectory.
  • MPC is not able to execute it (speed change violation ...) and dies.
  • We manually relaunch MPC.
  • We manually call the service "abort" from coordinator, who purgues current trajectory.
  • We manually call the service "ExecuteTask" from vehicle execution node and set the flag "abort" from msg Task to true.
  • [And the new code] vehicle execution node discards the task he was doing, re-checks mpc state and goes to wait state.

What do you think?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants