-
Notifications
You must be signed in to change notification settings - Fork 47
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 to start a python script from mbzirc_seed #207
Comments
hi, checking to see if your solution a ROS2 package and the python scripts are ros2 nodes? If so, ros2 launch files support launching nodes written in python as well. Here is a simple example I found where you just need to specify your package name and the python script name. Using a ros2 launch file to launch your solution is optional. You can just do |
Actually, I am still not sure that, How can I launch robot-specific nodes based on the robot names as you have provided in the seed_solution example directly by using info from the config.yaml. Also, if I directly launch Nodes/include other launch files in the mbzirc_seed.launch.py instead of launching them with composableNode format, won't it be a problem for you in terms of making sure that the Nodes aren't accessing data from other robots bypassing the simulation communication structure (I mean the TX/RX topics)? |
Due to some error in the beginning of part here, all robots are not getting spawned .....
|
|
|
Not sure if this helps but here is what we are doing:
In our example seed solution, we did not put these
In terms of making sure nodes aren't accesing data from other robots, this will not be a problem for us. In final evaluation, we have set up networking so that the solution container launched for a robot is only able to see its own topics and not able to talk to another container launched for a different robot.
From the console output, looks like your code is expecting a different type here?
|
Hello sir,
That part I understand but before that some robots are not getting spawned at all. If I am spawning 20 robots in total, I can see only 8 in the simulator. What could be the reason? |
You could be hitting a ROS2 DDS issue? Do you see any |
if you're using the docker compose file, try removing the |
Yes I see this error when using the compose file, also without the ROS_LOCAL_HOST_ONLY line, I am getting display errors (OGRE issue):
|
that looks like the graphics driver issue in docker container. One thing to try is add the env var |
I am getting the following error now:
|
One workaround for this is to run the docker compose simulation headless and attach a gui to it from another container, e.g.
Run docker compose with the new yaml file:
Then launch a docker container:
Attach a gui to it:
The downside is that the simulator maynot be able to find certain meshes (gripper) in the GUI but they should be there in the simulation. It's more of a GUI visualization issue. I added more instructions here. |
Hello sir,
The current solution seed which you have provided assumes that the solution plugins are in cpp. However, we have our scripts in python. How are we supposed to modify the launch file "mbzirc_seed.launch.py" in this case?
Thank you
The text was updated successfully, but these errors were encountered: