Page 1 of 1

Custom message in sim_ros_interface

Posted: 25 Jan 2021, 20:16
by lubosvarecha
Hello
I am using ROS Melodic, Ubuntu 18.04 and CoppeliaSim V4.1.0 and I want to send custom messages from package box_msgs that I created. I have problem load ROS interface.
So far I cloned melodic brunch of sim_ros_interface to my catkin workspace and then I modified it:
  • followed message types was added to: catkin_ws/src/simExtROS/meta/messages.txt
box_msgs/Box_scan
box_msgs/Box_array
box_msgs/Box
box_msgs/Dimensions
box_msgs/Orientation
box_msgs/Position
  • in catkin_ws/src/simExtROS/package.xml I added

Code: Select all

<depend>box_msgs</depend>
  • in catkin_ws/src/simExtROS/CMakeList.txt I added box_msgs to

Code: Select all

find_package(catkin REQUIRED COMPONENTS)
Then I exported COPPELIASIM_ROOT_DIR=/home/lubos/CoppeliaSim_Edu_V4_1_0_Ubuntu18_04 and successfully built it by:

Code: Select all

catkin build --cmake-args -DCMAKE_BUILD_TYPE=Release
Both packages are showing in rospack list and custom messages are listed in rosmsg list.

After that I copied libsimExtROSInterface.so from catkin_ws/devel/lib to CoppeliaSim root directory and tried to run CoppeliaSim but ros interface does not load i getting error:

Code: Select all

 bash [CoppeliaSim:error]   plugin 'ROSInterface': load failed (could not load). The plugin probably couldn't load dependency libraries. For additional infos, modify the script 'libLoadErrorCheck.sh', run it and inspect the output.
I don't know what caused error. Did I missed some steps? I appreciate any help or advice.