How to run ROSjects locally in Ubuntu 18.04 + ROS melodic + Gazebo9 installed if the original ROSjects are in Ubuntu 16.04 + ROS kinetic + Gazebo7.
- Create a ROS workspace in your local computer
- Download all the ROS packages from the ROSject into the src directory of that workspace
- Compile them. You may need to install extra libraries in your local computer that are already installed in the ROSDS. Also, since you are change ROS version, you may need to solve compilation issues and do the changes yourself in the code.
- Source the compiled packages.
- You are done!
I have downloaded the ROSject of ROS developers live class n58 “Use Moveit to picka dn object”.
I followed the following steps:
- Created a ROS workspace ‘tutorial_ws’ in my local computer.
- Performed catkin_make
- Copied the files form src of ‘simulation_ws’ and ‘catkin_ws’ into the src folder of ‘tutorial_ws’.
- Performed ‘catkin_make’ again.
- Typed ‘roslaunch shadow_gazebo main.launch’.
I get the following error:
roslaunch : “Resource not found: ur_gazebo
ROS path =/opt/ros/melodic/share/ros
ROS path =/home/my_pc/Desktop/tutorial_ws/src
ROS path =/opt/ros/melodic/share
The traceback for the exception was written to the log file”
Could you guide me where I have been wrong so that i can manually update.
This means that you have not installed the
ur_gazebo ROS package in your local computer. As I mentioned, the ROSDS already has many ROS packages installed so you don’t need to care about installing them.
If you want to run the rosject in your local computer you must install all the packages required by the rosject. We cannot tell you which ones are required because the link between dependencies is large. So you have to discover by yourself if you have all the dependencies installed.
The way to do it is by trying to run the rosject in your local machine. Then the system will tell you a message like the one you mentioned. That means, you must install it. Keep launching and installing until everything works.
Bear in mind that you may also have problems of Ubuntu libraries missing, that’s another story.
Finally, take into account that you are changing the ROS and Gazebo version, so you can experience additional errors that will require you to change the actual code of the rosject.
For all that, is why I recommend you to launch on ROSDS. You save a lot of trouble.
Can I ask you why do you prefer to launch in your local computer than in ROSDS?
Sir, I have followed your steps to keep launching and installing packages (ROS_industrial package,gazebo2rviz,pysdf,etc.) Finally, I have been able to
“roslaunch shadow_gazebo main.launch” but still I get 1 error in red:
“[gazebo2moveit-13] process has died [pid 13825, exit code 1, cmd /home/hirak/Desktop/tutorial_ws/src/shadow_robot_smart_grasping_sandbox/gazebo2rviz/src/gazebo2rviz/gazebo2moveit_collision_node.py -f 2 __name:=gazebo2moveit __log:=/home/hirak/.ros/log/ad27fb98-f006-11e9-b4a8-080027b1e8e5/gazebo2moveit-13.log].
log file: /home/hirak/.ros/log/ad27fb98-f006-11e9-b4a8-080027b1e8e5/gazebo2moveit-13*.log”
Could you guide me where to look-up for this error.
And Yes Sir, I have launched it in ROSDS. It is working perfectly fine. Thank You.
But Sir, I am trying to run it in my local computer so that I can edit and learn by trying different things by trial and error on the code. Sorry Sir, for giving you the trouble.