can I run ROS2 and ROS1 on one ubuntu at the same time?
hi all,
on my ubuntu 16.04, I already have a ros1 system setup and up running. however, I need to launch a separate ros2 node at the same time. when I source the /opt/ros/$ros_version/setup.bash, it seems the system can only allow one version of ros up running. I am wondering how I could run ros1 and ros2 simultaneously?
Thanks!
Is there a specific error message? ROS 1 and ROS 2 can definitely be run at the same time. This is how the ros1 bridge works:
https://github.com/ros2/ros1_bridge
Note that ROS2 requires (or at least is prebuild for) at least Ubuntu 18.04. One solution I'm using right now is to install a ROS2 Docker image - I'm currently running Foxy in a Ubuntu 18.04 Docker container (built from source as Foxy is only offered for 20.04+) with ROS1 running
rosbag play
in the base 16.04. (In VSCode's terminal running on Windows+Remote SSH plugin)thanks! very helpful. but to clarify, ROS2 has, for example, ardent, which can run perfectly on ubuntu 16.04. why do you say it requires at least 18.04? thanks
ardent
is quite old, but I was thinking of the versions I've worked on,eloquent
(18.04) andfoxy
(20.04); looking at the ROS Docker repoardent
is the only one offered for 16.04.