ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

how to get catkin package recognized by rosrun

asked 2014-04-23 17:10:18 -0600

vdonkey gravatar image

I created a catkin workspace folder ~/catkin-ws, and downloaded usb_cam ( http://wiki.ros.org/usb_cam ) source into ~/catkin-ws/src. I called catkin_make and ~/catkin-ws/devel/lib/usb_cam/usb_cam_node is created.

But when I type rosrun usb[TAB Key], nothing happened.

I think this is because usb_cam not registered to ros system yet, since there is no usb_cam in /opt/ros/hydro/lib(I am using hydro). so I tried this:

sudo cp -r ~/catkin-ws/devel/lib/* /opt/ros/hydro/lib/

still not working. how to get a catkin complied package recognized by rosrun?

by the way, running "~/catkin-ws/devel/lib/usb_cam/usb_cam_node" directly does work. is that the correct way?

edit retag flag offensive close merge delete

Comments

1

There are some articles about usb_cam in ROS Q&A. For example, check it out (http://answers.ros.org/question/42906/issue-with-usb_cam-cant-open-camera/) .

Ken_in_JAPAN gravatar image Ken_in_JAPAN  ( 2014-04-23 17:47:07 -0600 )edit

Thanks, Ken. It works, you are great. I know cp and run node directly without rosrun can hardly be a good answer, but I just cannot find the correct one after reading tutorials and ppt courses by myself.

vdonkey gravatar image vdonkey  ( 2014-04-23 19:16:17 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
3

answered 2014-04-23 17:43:04 -0600

Ken_in_JAPAN gravatar image

Did you try this command source ~/catkin_ws/devel/setup.bash after compiling the package? I always execute the command to make PC recognize the package. sudo cp -r ~/catkin_ws/devel/lib/* /opt/ros/hydro/lib/ is bad. I think that this behaivior isn't described on wiki.ros.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2014-04-23 17:10:18 -0600

Seen: 2,316 times

Last updated: Apr 23 '14