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

How can I program... by demonstration? #28

Closed
jgvictores opened this issue Sep 13, 2017 · 8 comments
Closed

How can I program... by demonstration? #28

jgvictores opened this issue Sep 13, 2017 · 8 comments
Assignees
Labels

Comments

@jgvictores
Copy link
Member

Yes! That is the question... how can I PbD!?

@jgvictores jgvictores self-assigned this Sep 13, 2017
@PeterBowman
Copy link
Member

Something like this?

@jgvictores
Copy link
Member Author

@PeterBowman Probably, with emphasis on this. :-)

@David-Estevez
Copy link

I see this has extended to issues too... ;)

@jgvictores
Copy link
Member Author

jgvictores commented Sep 13, 2017

Esentially, you'll want some gravity compensation to help out. That's [gcmp] off the BasicCartesianControl :
http://robots.uc3m.es/dox-kinematics-dynamics/group__BasicCartesianControl.html

Option 1: Manually grab some "waypoints" and then create a program. For instance, in the joint space, do some yarp rpc /robotName/manipulatorName/rpc:i to get joint positions you can later use in your program as in this example or similar.

Option 2: Use yarpdatadumper (related) to record the full trajectory. Then use stuff from our tools repository. Specifically, you'll want the PlaybackThread. You can find an example of use at examplePlaybackThread and its corresponding test.

Note: There are several alternatives to these approaches, but these are kind of nice. yarpmanager has some record/playback facilities, but I haven't really tried them. Additionally, yarpdataplayer does some playback, but for me it's nice to have something like what we have in the previously mentioned tools repository because it is a small library that can be used independently and is not coupled with any graphical interface.

@jgvictores
Copy link
Member Author

@rsantos88 I'd enjoy some feedback on this! Good to close the issue? Maybe we should document this somewhere (teo-software-manual is looking pretty abandoned)?

@rsantos88
Copy link

@jgvictores yes, for me it's ok. You can close it if you want ;)

@jgvictores
Copy link
Member Author

Cool!

@rsantos88
Copy link

Option 2: Use yarpdatadumper (related) to record the full trajectory. Then use stuff from our tools repository. Specifically, you'll want the PlaybackThread. You can find an example of use at examplePlaybackThread and its corresponding test.

An example to record the left arm trayectory of Teo:

  • Terminal 1: run launchManipulation
  • Terminal 2: run yarpdatadumper --name /log (the file will be saved in /log directory)
  • Terminal 3: yarp connect /teo/leftArm/state:o /log

the acquisition will start.
By pressing CTRL+C the acquisition is terminated.

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

No branches or pull requests

4 participants