Hi everyone!
I made a custom service following this tutorial: http://wiki.ros.org/ROS/Tutorials/CreatingMsgAndSrv#Common_step_for_msg_and_srv
I edited the CMakeLists.txt and package.xml files as instructed.
I can see my service when I run rossrv list, but the .py file does not appear in devel/lib/python2.7/dist-packages/my_package/srv. The full path exists, but the srv directory is empty.
When I try and import the service in my python file using
from my_package.srv import my_service
I get the error:
ImportError: No module named srv
Here is my CMakeLists.txt file for your review:
cmake_minimum_required(VERSION 2.8.3)
project(my_package)
find_package(catkin REQUIRED COMPONENTS
geometry_msgs
nav_msgs
roscpp
rospy
std_msgs
message_generation
)
add_service_files(
FILES
my_service.srv
)
generate_messages(
DEPENDENCIES
geometry_msgs nav_msgs std_msgs
)
catkin_package(
CATKIN_DEPENDS geometry_msgs nav_msgs roscpp rospy std_msgs message_runtime
)
include_directories(
${catkin_INCLUDE_DIRS}
)
Any help?
Ubuntu 12.04 ROS Hydro
Originally posted by Robocop87 on ROS Answers with karma: 255 on 2014-06-12
Post score: 1