Skip to content

Add supervisor tutorial - #3882

Merged
ad-daniel merged 25 commits into
releasedfrom
feature-supervisor-tutorial
Nov 15, 2021
Merged

ad-daniel merged 25 commits into
releasedfrom
feature-supervisor-tutorial

Conversation

@ad-daniel

@ad-daniel ad-daniel commented Nov 11, 2021 •

Copy link
Copy Markdown
Contributor

Description
Add basic tutorial for the usage of a supervisor

preview: https://www.cyberbotics.com/doc/guide/tutorial-8-the-supervisor?version=feature-supervisor-tutorial

PS: I don't have Matlab, can somebody test it?
You need to setup up the world as explained in the first section and all the code is available at the end.

@ad-daniel ad-daniel added the documentation Improve or fix the documentation (MD files only, no software development) label Nov 11, 2021
@ad-daniel ad-daniel added this to the R2021b-rev1 milestone Nov 11, 2021
@ad-daniel ad-daniel self-assigned this Nov 11, 2021
@ad-daniel
ad-daniel marked this pull request as ready for review November 12, 2021 13:31
@ad-daniel
ad-daniel requested review from a team and BenjaminDeleze November 12, 2021 13:31

@BenjaminDeleze BenjaminDeleze left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems very good and useful to me! Maybe @omichel could read it to review the English style as I am quite bad at it.

It would maybe be better to do the tutorial directly in ENU/FLU ?

It may be useful to add a warning regarding the physic instabilities that can be caused by using the Supervisor to move objects.

Comment thread docs/guide/tutorial-8-the-supervisor.md Resolved
Comment thread docs/guide/tutorial-8-the-supervisor.md Outdated
Finally, now that a reference to the translation field is available, all that remains to do is to set it to a different value.
Once again, the supervisor API has all the necessary tools to do so.
The `translation` field is of type `SFVec3`, which just means it is a three dimensional vector.
The value of this field can be set by using the `wb_supervisor_field_set_sf_vec3f` function.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When speaking about a function, we could maybe put a link toward its documentation (https://www.cyberbotics.com/doc/reference/supervisor?tab-language=python#wb_supervisor_field_set_sf_vec3f, for example)?

Comment thread docs/guide/tutorial-8-the-supervisor.md Resolved
Comment thread docs/guide/tutorial-8-the-supervisor.md Resolved

@omichel omichel left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The English looks very good to me.
I just have have a minor suggestion.

Comment thread docs/guide/tutorial-8-the-supervisor.md Resolved
Comment thread docs/guide/tutorial-8-the-supervisor.md Resolved
@ad-daniel

Copy link
Copy Markdown
Contributor Author

The problem with doing it with ENU is that it won't touch released branch until December. I was planning on just doing the changes in the feature-enu-branch next week when we synchronize the branches, I've kept it simple enough that it will just take a few changes when merging. Being a new file, there won't be any conflicts. What do you think?

@omichel

omichel commented Nov 12, 2021

Copy link
Copy Markdown
Member

What do you think?

Sounds good to me.

Co-authored-by: Olivier Michel <Olivier.Michel@cyberbotics.com>
BenjaminDeleze
BenjaminDeleze previously approved these changes Nov 12, 2021

@BenjaminDeleze BenjaminDeleze left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@omichel omichel left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tested the Matlab controller and it works fine.
Thank you.

@ad-daniel
ad-daniel merged commit 65c2b6c into released Nov 15, 2021
@ad-daniel
ad-daniel deleted the feature-supervisor-tutorial branch November 15, 2021 11:11
ad-daniel added a commit that referenced this pull request Nov 18, 2021
* Fix auto-regeneration crash (#3869)

* Fix auto-regeneration crash

* Fix typo

* Changelog entry

* Proper fix

* Update src/webots/nodes/utils/WbSupervisorUtilities.cpp

Co-authored-by: Olivier Michel <Olivier.Michel@cyberbotics.com>

* Fix Clang format

Co-authored-by: Olivier Michel <Olivier.Michel@cyberbotics.com>

* Update discord docs. (#3877)

Co-authored-by: DavidMansolino <DavidMansolino@github.com>

* Fixed line endings (#3880)

* Fixed line endings

* added driver.def

* Added car.def

* Update Solid.wrl (#3881)

* Fix lights cast shadow (#3883)

* Fix visibility distance

* remove comment

* max value + comment

* Update src/wren/Scene.cpp

Co-authored-by: Olivier Michel <Olivier.Michel@cyberbotics.com>

* clang format

Co-authored-by: Olivier Michel <Olivier.Michel@cyberbotics.com>

* Add supervisor tutorial (#3882)

* Beginning

* Handson 2

* Hands-on 3

* continuation

* hands-on 4

* format

* format test

* test

* Finalize

* Finalize

* Fix sources

* Fix errors

* Fix referenceS

* Remove reference

* Fix

* Add function links

* Fix

* Update docs/guide/tutorial-8-the-supervisor.md

Co-authored-by: Olivier Michel <Olivier.Michel@cyberbotics.com>

* Review fixes

* minor

* Fix

* Fix matlab

Co-authored-by: Olivier Michel <Olivier.Michel@cyberbotics.com>

* Cleanup wheel acceleration computation (#3854)

* Fix

* fix

* Update driver.c

Co-authored-by: Olivier Michel <Olivier.Michel@cyberbotics.com>

* Update discord docs. (#3929)

Co-authored-by: DavidMansolino <DavidMansolino@github.com>

* fix arccos boundaries (#3934)

* fix acos boundaries + add ToString

* include boundaries for performance

* fix clang

Co-authored-by: Olivier Michel <Olivier.Michel@cyberbotics.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: DavidMansolino <DavidMansolino@github.com>
Co-authored-by: Benjamin Délèze <benjamin.deleze@cyberbotics.com>
Co-authored-by: joachimhgg <48200998+joachimhgg@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improve or fix the documentation (MD files only, no software development)

Development

Successfully merging this pull request may close these issues.

3 participants