-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Feature extern controllers launcher #5629
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
Conversation
|
I have resolved all mentioned issues, including the ability to launch the extern controller from any location, as it will automatically execute from its own directory. Running the controller launcher within the target controller's directory can be done without the need for "./" prefix, and Windows users can now use both forward and backward slashes. Robot names with spaces are now supported. Although I have tested in all languages and platforms, there may still be undiscovered edge cases, and I could not retest Matlab as my license has expired since my last test. |
ad-daniel
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nothing else from me, works well on linux both for python, C and java
omichel
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks good to me.
I just have a very minor change request.
Co-authored-by: Olivier Michel <[email protected]>
omichel
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All good for me.
Thank you.
Resolves #5565.
The new launcher is compiled to
WEBOTS_HOME/webots-controller.Available options are:
--protocol: can be eitheripcortcp.ipcis used for local connections (i.e. Webots is started on the same machine as the controller).tcpis used for remote connections (e.g. Webots is started on a different machine than the controller).ipcis used by default if this option is not given.--ip_address: The IP address of the remote machine on which the Webots instance is running. Mandatory fortcpconnections and can be omitted when usingipc.--port: 1234 is used by default, as it is the default port of Webots. This parameter allows to connect to a specific instance of Webots if multiple of them are running on the target machine. The port of a Webots instance can be set at its launch.--robot_name: Target a specific robot by specifying its name in case multiple robots wait for an extern controller in the Webots instance.--matlab-path: For MATLAB controllers, this option allows to specify the path to the executable of a specific MATLAB version. By default, the launcher checks in the default MATLAB installation folder.--stdout-redirect: Redirect the stdout of the controller to the Webots console.--stderr-redirect: Redirect the stderr of the controller to the Webots console.Example:
./webots-controller $WEBOTS_HOME/projects/samples/devices/controllers/gps/gps --protocol=tcp --ip_address=localhost --port=1234 --robot_name=MyBotTasks: