ERROR: cannot launch node of type [teleop/teleop_key]: can't locate node [teleop_key] in package [teleop]
Hello I took over a project on ROS and I'm still pretty new to the environment. I'm currently using ROS Kinetic and Ubuntu 16.04. I'm trying to launch a simple keyboard_teleop.launch program but get this error:
process[master]: started with pid [27909]
ROS_MASTER_URI=http://localhost:11311
setting /run_id to 25d5ccd0-cd3c-11e8-9d38-74e5f9149b23
process[rosout-1]: started with pid [27922]
started core service [/rosout]
ERROR: cannot launch node of type [teleop/teleop_key]: can't locate node [teleop_key] in package [teleop]
Here is the launch file:
<?xml version="1.0" encoding="UTF-8"?>
<launch>
<!-- teleop_key already has its own built in velocity smoother -->
<node pkg="teleop" type="teleop_key" name="teleop_keyboard" output="screen">
<param name="scale_linear" value="0.5" type="double"/>
<param name="scale_angular" value="1.5" type="double"/>
<remap from="teleop_keyboard/cmd_vel" to="/cmd_vel"/>
</node>
</launch>
And the CMakeLists
cmake_minimum_required(VERSION 2.8.3)
project(teleop)
## Find catkin macros and libraries
find_package(catkin REQUIRED COMPONENTS roscpp geometry_msgs joy)
include_directories(${catkin_INCLUDE_DIRS})
catkin_package(
INCLUDE_DIRS
CATKIN_DEPENDS roscpp geometry_msgs joy
DEPENDS
)
###########
## Build ##
###########
add_executable(teleop_joy src/joy.cpp)
target_link_libraries(teleop_joy ${catkin_LIBRARIES})
#############
## Install ##
#############
## Mark executable scripts (Python etc.) for installation
install(PROGRAMS
scripts/teleop_key
DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)
## Mark executables and/or libraries for installation
install(TARGETS teleop_joy
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)
## Mark all other useful stuff for installation
install(DIRECTORY launch
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION}
)
Do you actually have a node named "teleop_key" in your package? The CMakeLists.txt file you posted compiles a node named "teleop_joy". The answer from @shiv_rar assumes you have a Python script providing "teleop_key", but I'm not sure how that conclusion was arrived at.