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

Launch individual vehicle name #672

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

carvee1
Copy link
Contributor

@carvee1 carvee1 commented Jun 8, 2023

After PR #644, this modification in the file competition.launch.py offers the user the possibility to specify a custom name and type for the vessel. (Compare spawn.launch.py file).
It can be specified by adding the name:= and model:= argument when launching the vrx world. The name defaults to "wamv" while the type defaults to "wam-v".

The changes are based on PR #644, which has been tested by @j-herman. The new modifications have been tested with Ubuntu-22.04 and ros2 humble.

carvee1 and others added 4 commits May 16, 2023 08:18
When trying to launch a second vessel with the name wamv2, the following error message was shown
"[ERROR] [launch]: Caught exception in launch (see debug for traceback): Error Code 20: Msg: Child frame with name[wamv/base_link] specified by joint with name[wamv_external_pivot_joint] not found in model with name[WAM-V]"
The problem was found in line 103 of the wamv_gazebo.urdf.xacro file, in which the namespace was not properly referenced to the namespace but only to the standard topic namespace of "wamv/base_link". As a result without changing the child to "$(arg namespace)/base_link, it is not possible to spawn a second vehicle with a different namespace. Therefor, without the change, it would not be possible to control the vessels independent of each other, as both subscribe to the same topic.
Added the option to change the name and type of the launched vessel. Defaults to name:=wamv and type:=wam-v
can be called by 'ros2 launch vrx_gz competition.launch.py world:=sydney_regatta name:=custom_name model:=custom_model_type
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

Successfully merging this pull request may close these issues.

3 participants