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

Can anybody please tell how to use web camera in ROS? [closed]

asked 2014-09-20 08:43:20 -0500

ish45 gravatar image

updated 2014-09-20 08:43:45 -0500

I want to use webcamera to test images in ROS. I am programming using OPENCV and want to see the live video stream from my laptop in a window on ROS. When I try to launch a file whose contents are given below, I get an error that "ERROR: cannot launch node of type [uvc_cam/uvc_cam_node]: can't locate node [uvc_cam_node] in package [uvc_cam] No processes to monitor :". I launch the file using the command : roslaunch ishan_vision uvc_cam.launch device:=/dev/video0

uvc_cam.launch file :

<launch> <arg name="device" default="/dev/video0"/>

<node name="uvc_cam_node" pkg="uvc_cam" type="uvc_cam_node" output="screen">
    <remap from="camera/image_raw" to="camera/rgb/image_color" />
    <param name="device" value="$(arg device)" />
    <param name="width" value="320" />
    <param name="height" value="240" />
    <param name="frame_rate" value="20" />
    <param name="exposure" value="0" />
    <param name="gain" value="100" /> 
</node>

</launch>

Can anybody please help?

Thanks

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by ish45
close date 2014-09-21 04:23:29.960161

2 Answers

Sort by ยป oldest newest most voted
3

answered 2014-09-20 09:11:38 -0500

paulbovbel gravatar image

updated 2014-09-20 09:12:44 -0500

It looks like roslaunch can't find the node, which shouldn't happen if you've:

  • installed uvc_camera sudo apt-get install ros-<distro>-uvc-camera
  • sourced your ros installation source /opt/ros/<distro>/setup.bash
edit flag offensive delete link more

Comments

Thanks a lot. Now, its working. I did not install the uvc camera thats why it was giving the error. Thanks.

ish45 gravatar image ish45  ( 2014-09-21 04:23:13 -0500 )edit

sudo apt-get install ros-`rosversion -d`-uvc-camera is shorter version

arzo gravatar image arzo  ( 2015-03-20 14:54:48 -0500 )edit

Dear Sir,

I have installed uvc-camera and have even sourced my ros installation. However still roslaunch is unable to find the launch file.

Using ROS Kinetic

aaditya_saraiya gravatar image aaditya_saraiya  ( 2017-08-24 04:58:55 -0500 )edit
1

answered 2014-09-20 18:54:12 -0500

jseal gravatar image

Try uvc_camera instead of uvc_cam and uvc_camera_node instead of uvc_cam_node

Also you can test your webcam with: guvcview

edit flag offensive delete link more

Comments

thanks...it worked

eskay gravatar image eskay  ( 2018-01-17 05:16:22 -0500 )edit

Thank you! Using guvcview works for me!

dolphinlove gravatar image dolphinlove  ( 2018-06-30 04:30:29 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2014-09-20 08:43:20 -0500

Seen: 9,277 times

Last updated: Sep 20 '14