Using self-defined ros-msg types

Hey,

I am using the orocos-toolchain-ros stack with unstable/diamondback. I already successfully used self-defined ros messages in Orocos but now a specific .msg file is giving problems and I don't see directly why...

Linking CXX shared library ../lib/orocos/libDaq-gnulinux.so
make[3]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
[ 40%] Built target Daq
make[3]: Entering directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
Scanning dependencies of target rtt-ros-FTmeas_controller-transport
make[3]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
make[3]: Entering directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
[ 60%] Building CXX object CMakeFiles/rtt-ros-FTmeas_controller-transport.dir/src/orocos/types/ros_FTmeas_controller_transport.cpp.o
Linking CXX shared library ../lib/orocos/types/librtt-ros-FTmeas_controller-transport-gnulinux.so
make[3]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
[ 60%] Built target rtt-ros-FTmeas_controller-transport
make[3]: Entering directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
Scanning dependencies of target rtt-ros-FTmeas_controller-typekit
make[3]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
make[3]: Entering directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
[ 80%] Building CXX object CMakeFiles/rtt-ros-FTmeas_controller-typekit.dir/src/orocos/types/ros_FTmeas_controller_typekit.cpp.o
[100%] Building CXX object CMakeFiles/rtt-ros-FTmeas_controller-typekit.dir/src/orocos/types/ros_MsgForces_typekit_plugin.cpp.o
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:1:47: error: FTmeas_controller/boost/MsgForces.h: No such file or directory
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp: In function ‘void ros_integration::rtt_ros_addType_MsgForces():
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: ‘FTmeas_controller’ was not declared in this scope
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: template argument 1 is invalid
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: invalid conversion from ‘const char*’ to ‘int/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: no matching function for call to ‘RTT::types::TypeInfoRepository::addType(int*)/opt/ros/unstable/stacks/orocos_toolchain_ros/rtt/install/include/rtt/types/TypeInfoRepository.hpp:78: note: candidates are: bool RTT::types::TypeInfoRepository::addType(RTT::types::TypeInfo*)
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: ‘FTmeas_controller’ cannot appear in a constant-expression
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: template argument 1 is invalid
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: template argument 2 is invalid
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: template argument 1 is invalid
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: invalid conversion from ‘const char*’ to ‘int/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: no matching function for call to ‘RTT::types::TypeInfoRepository::addType(int*)/opt/ros/unstable/stacks/orocos_toolchain_ros/rtt/install/include/rtt/types/TypeInfoRepository.hpp:78: note: candidates are: bool RTT::types::TypeInfoRepository::addType(RTT::types::TypeInfo*)
make[3]: *** [CMakeFiles/rtt-ros-FTmeas_controller-typekit.dir/src/orocos/types/ros_MsgForces_typekit_plugin.cpp.o] Error 1
make[3]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
make[2]: *** [CMakeFiles/rtt-ros-FTmeas_controller-typekit.dir/all] Error 2
make[2]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
make: *** [all] Error 2
bwillaert@ins:~/workspace1/Ros_Pkg_Bert/Master_controller$ 

'Master_controller' is een Orocos pkg and 'FTmeas_controller' is a ros-pkg containing a ros plugincontroller, it is build and the dependency is added to the manifest file of 'Master_controller'. Any idea? Thanks!

Bert

Re: Using self-defined ros-msg types

Hmm, after creating a new ros package for the message containing 'FTmeas_controller' pkg and copying everything in there, the problem is gone! Apparently something was wrong with that pkg although it worked fine under ros... Thanks anyway ;)

bwillaert wrote:
Hey,

I am using the orocos-toolchain-ros stack with unstable/diamondback. I already successfully used self-defined ros messages in Orocos but now a specific .msg file is giving problems and I don't see directly why...

Linking CXX shared library ../lib/orocos/libDaq-gnulinux.so
make[3]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
[ 40%] Built target Daq
make[3]: Entering directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
Scanning dependencies of target rtt-ros-FTmeas_controller-transport
make[3]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
make[3]: Entering directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
[ 60%] Building CXX object CMakeFiles/rtt-ros-FTmeas_controller-transport.dir/src/orocos/types/ros_FTmeas_controller_transport.cpp.o
Linking CXX shared library ../lib/orocos/types/librtt-ros-FTmeas_controller-transport-gnulinux.so
make[3]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
[ 60%] Built target rtt-ros-FTmeas_controller-transport
make[3]: Entering directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
Scanning dependencies of target rtt-ros-FTmeas_controller-typekit
make[3]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
make[3]: Entering directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
[ 80%] Building CXX object CMakeFiles/rtt-ros-FTmeas_controller-typekit.dir/src/orocos/types/ros_FTmeas_controller_typekit.cpp.o
[100%] Building CXX object CMakeFiles/rtt-ros-FTmeas_controller-typekit.dir/src/orocos/types/ros_MsgForces_typekit_plugin.cpp.o
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:1:47: error: FTmeas_controller/boost/MsgForces.h: No such file or directory
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp: In function ‘void ros_integration::rtt_ros_addType_MsgForces():
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: ‘FTmeas_controller’ was not declared in this scope
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: template argument 1 is invalid
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: invalid conversion from ‘const char*’ to ‘int/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: no matching function for call to ‘RTT::types::TypeInfoRepository::addType(int*)/opt/ros/unstable/stacks/orocos_toolchain_ros/rtt/install/include/rtt/types/TypeInfoRepository.hpp:78: note: candidates are: bool RTT::types::TypeInfoRepository::addType(RTT::types::TypeInfo*)
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: ‘FTmeas_controller’ cannot appear in a constant-expression
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: template argument 1 is invalid
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: template argument 2 is invalid
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: template argument 1 is invalid
/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: invalid conversion from ‘const char*’ to ‘int/u/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/src/orocos/types/ros_MsgForces_typekit_plugin.cpp:10: error: no matching function for call to ‘RTT::types::TypeInfoRepository::addType(int*)/opt/ros/unstable/stacks/orocos_toolchain_ros/rtt/install/include/rtt/types/TypeInfoRepository.hpp:78: note: candidates are: bool RTT::types::TypeInfoRepository::addType(RTT::types::TypeInfo*)
make[3]: *** [CMakeFiles/rtt-ros-FTmeas_controller-typekit.dir/src/orocos/types/ros_MsgForces_typekit_plugin.cpp.o] Error 1
make[3]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
make[2]: *** [CMakeFiles/rtt-ros-FTmeas_controller-typekit.dir/all] Error 2
make[2]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/wg/stor2a/bwillaert/workspace1/Ros_Pkg_Bert/Master_controller/build'
make: *** [all] Error 2
bwillaert@ins:~/workspace1/Ros_Pkg_Bert/Master_controller$ 

'Master_controller' is een Orocos pkg and 'FTmeas_controller' is a ros-pkg containing a ros plugincontroller, it is build and the dependency is added to the manifest file of 'Master_controller'. Any idea? Thanks!

Bert