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

Reset World Feature #17

Open
ndehio opened this issue Nov 7, 2016 · 4 comments
Open

Reset World Feature #17

ndehio opened this issue Nov 7, 2016 · 4 comments

Comments

@ndehio
Copy link

ndehio commented Nov 7, 2016

I implemented an simple example for demonstrating and testing the "Reset World Feature" in
https://github.com/cogimon/workshop-extended-example/ -> branch resetWorldExample

Could you please check whether this is done in a correct way? I am not sure exactly at which point between configuring, starting, stopping and cleaning of components one should (de-)activate the dynamics via "toggleDynamicsSimulationGazebo()". It seems that sometimes the robot crashes.

@EnricoMingo
Copy link
Collaborator

There are 2 basic functions that you should use to do this:

  1. coman.reset_model_config that puts the robot to the initial
    configuration in joint space
  2. gazebo.reset_model_pose that puts the robot to the initial pose in world
    frame

For example: if you are testing different walking algorithm you can run the
first algorithm, when it finish you can call these 2 methods (the order is
not important) and the robot will be placed at the starting point with the
initial configuration. Is also not important to stop the dynamics.

In the case there are also object involved then there is another method in
gazebo that reset the world completely but you should call just after it
the coman.reset_model_config (calling just the first one the world will be
reset but the robot will take the last configuration in joint space). Also
in this case the order should not be important (you can take the robot to
the initial configuration and then reset the world).

2016-11-07 15:48 GMT+01:00 ndehio [email protected]:

I implemented an simple example for demonstrating and testing the "Reset
World Feature" in
https://github.com/cogimon/workshop-extended-example/ -> branch
resetWorldExample

Could you please check whether this is done in a correct way? I am not
sure exactly at which point between configuring, starting, stopping and
cleaning of components one should (de-)activate the dynamics via "
toggleDynamicsSimulationGazebo()". It seems that sometimes the robot
crashes.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
#17, or mute the
thread
https://github.com/notifications/unsubscribe-auth/AFQaypp684NUEc3qxUTzo23AvG5yy17Zks5q7zo0gaJpZM4KrSsv
.

PhD Mingo Hoffman Enrico
Istituto Italiano di Tecnologia, Genova

@OpenSoT
Copy link

OpenSoT commented Feb 1, 2017

This can be closed?

@ndehio
Copy link
Author

ndehio commented Feb 1, 2017

Actually not...
The simple example still does not work. It uses a fixed-base kuka robot arm which is why gazebo.reset_model_pose does not has any effect.
Please have a look to the example

@EnricoMingo
Copy link
Collaborator

EnricoMingo commented Feb 1, 2017 via email

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

No branches or pull requests

3 participants