UVC_camera fails

asked 2016-12-10 18:06:35 -0600

David_Zizu gravatar image

updated 2016-12-11 02:59:15 -0600

gvdhoorn gravatar image

I have a problem with uvc_camera. When I run:

rosrun uvc_camera uvc_camera_node

it just says:

[ INFO] [1481414376.278537346]: using default calibration URL
[ INFO] [1481414376.278608501]: camera calibration URL: file:///home/solmaz/.ros/camera_info/camera.yaml
Segmentation fault

When I run my launch file:

roslaunch work_space camera.launch

I get the following results:

[camera_1/uvc_camera_node_1-1] process has died [pid 4942, exit code -11, cmd /opt/ros/indigo/lib/uvc_camera/uvc_camera_node __name:=uvc_camera_node_1 __log:=/home/solmaz/.ros/log/5910aa52-bf33-11e6-bdb3-e03f494ac521/camera_1-uvc_camera_node_1-1.log].
log file: /home/solmaz/.ros/log/5910aa52-bf33-11e6-bdb3-e03f494ac521/camera_1-uvc_camera_node_1-1*.log

The log file is empty that makes it harder to find the problem.

My launch file this:

<?xml version="1.0"?>
<launch>
  <node ns="camera_1" pkg="uvc_camera" type="uvc_camera_node" name="uvc_camera_node_1">
    <param name="width" type="int" value="640" />
    <param name="height" type="int" value="480" />
    <param name="fps" type="int" value="30" />
    <param name="frame" type="string" value="webcam" />
    <param name="device" type="string" value="/dev/video0" />
    <param name="auto_focus" type="bool" value="0" />
  </node>
</launch>

This web camera works fine on another machine. And guvcview also works.

edit retag flag offensive close merge delete

Comments

One way to approach this would probably be to get uvc_camera_node to run in gdb (see How to Roslaunch Nodes in Valgrind or GDB). Preferably even a debug build of that node.

gvdhoorn gravatar imagegvdhoorn ( 2016-12-11 03:01:46 -0600 )edit

Also: please always include your OS, its version, the version of ROS you are using, how you installed it (from sources or binary pkgs), etc.

gvdhoorn gravatar imagegvdhoorn ( 2016-12-11 03:02:33 -0600 )edit

Finally: uvc_camera is deprecated (from the wiki page):

This package is no longer actively maintained. Please use another driver, such as libuvc_camera (github).

gvdhoorn gravatar imagegvdhoorn ( 2016-12-11 03:04:13 -0600 )edit

I use Linux Ubuntu 14.04; ROS Indigo; installed from packages. I tried to use libuvc_camera, but there was the same problem.

David_Zizu gravatar imageDavid_Zizu ( 2016-12-11 03:18:37 -0600 )edit

I tried to use libuvc_camera, but there was the same problem.

that could point to a more general problem with drivers / sw-hw interaction then. Debugging using gdb (or any other tool) is probably the best course of action.

gvdhoorn gravatar imagegvdhoorn ( 2016-12-11 03:25:42 -0600 )edit

Does file:///home/solmaz/.ros/camera_info/camera.yaml exist?

gvdhoorn gravatar imagegvdhoorn ( 2016-12-11 04:06:52 -0600 )edit

yes, this file exists

David_Zizu gravatar imageDavid_Zizu ( 2016-12-12 19:58:22 -0600 )edit

I am sure completely sure of how to debug with gdb. Could you help me with that?

David_Zizu gravatar imageDavid_Zizu ( 2016-12-12 20:16:16 -0600 )edit