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

usb_cam package and head_camera.yaml missing

asked 2016-07-29 12:30:07 -0500

submetu gravatar image

Hello, I am new to ROS. I have been trying to do usb camera integration into a robotics project at our university's lab. I will write the steps i did and the errors that i got.

  1. I went into my ~/catkin_ws/src folder and i ran

    git clone https://github.com/bosch-ros-pkg/usb_cam

  2. Then I went into my ~/catkin_ws folder and ran

    source /devel/setup.bash

  3. Then I ran

    roscore

  4. Then I ran

    roslaunch usb_cam usb_cam-test.launch

  5. This was the output ... logging to /home/submetu/.ros/log/1fd73732-55ad-11e6-a65d-d8fc93edb7dc/roslaunch-submetu-9724.log Checking log directory for disk usage. This may take awhile. Press Ctrl-C to interrupt Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://submetu:40095/

SUMMARY

PARAMETERS * /image_view/autosize: True * /rosdistro: kinetic * /rosversion: 1.12.2 * /usb_cam/camera_frame_id: usb_cam * /usb_cam/image_height: 480 * /usb_cam/image_width: 640 * /usb_cam/io_method: mmap * /usb_cam/pixel_format: yuyv * /usb_cam/video_device: /dev/video0

NODES / image_view (image_view/image_view) usb_cam (usb_cam/usb_cam_node)

ROS_MASTER_URI=http://localhost:11311

core service [/rosout] found process[usb_cam-1]: started with pid [9742] ERROR: cannot launch node of type [image_view/image_view]: can't locate node [image_view] in package [image_view] terminate called after throwing an instance of 'boost::exception_detail::clone_impl<boost::exception_detail::error_info_injector<boost::lock_error> >' what(): boost: mutex lock failed in pthread_mutex_lock: Invalid argument [usb_cam-1] process has died [pid 9742, exit code -6, cmd /home/submetu/catkin_ws/devel/lib/usb_cam/usb_cam_node __name:=usb_cam __log:=/home/submetu/.ros/log/1fd73732-55ad-11e6-a65d-d8fc93edb7dc/usb_cam-1.log]. log file: /home/submetu/.ros/log/1fd73732-55ad-11e6-a65d-d8fc93edb7dc/usb_cam-1*.log all processes on machine have died, roslaunch will exit shutting down processing monitor... ... shutting down processing monitor complete done

I tried the tutorial of http://wiki.ros.org/camera_calibration , but I am not getting any camera output because the above error comes everytime. So I cant calibrate i.e. i cant get the head_camera.yaml file. I looked at many tutorials but I could not find anything helpful to me.

Please help :(

Thank you in advance (im using a lenovo thinkpad e440 with ubuntu. My camera is a logitech camera(it is connected as cheese is giving video output))

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
0

answered 2016-07-31 11:52:24 -0500

submetu gravatar image

I solved this problem by installing Ubuntu 12.04 and ROS indigo. Apparently usb_cam package is not working on ROS kinetic. Also ROS indigo doesn't work on Ubuntu 16.04 so I had to downgrade to 12.04 for that.

I'm still getting calibration errors but there are online tutorials to calibrate it. I'm getting video output now on Rviz so i can calibrate it.

edit flag offensive delete link more

Comments

Hi! no need for downgrading, usb_cam hadn't been added to ROS Kinetic repositories yet, but you can install it from source by following the step-by-step commands as described here.

Horse-man gravatar image Horse-man  ( 2016-08-01 01:12:13 -0500 )edit

Hi, the installation was not a problem. It installed just fine. I was receiving errors when i ran rosrun usb_cam usb_cam_node or the roslaunch usb_cam usb_cam-test.launch commands. The system would quit after giving a bunch of errors. I listed the errors above in my question.

submetu gravatar image submetu  ( 2016-08-02 06:31:54 -0500 )edit

I see. I submitted an issue in their repository once asking them to fix the compatibility with Kinetic, but they didn't fix anything.

Horse-man gravatar image Horse-man  ( 2016-08-02 08:00:46 -0500 )edit

fingers crossed :)

submetu gravatar image submetu  ( 2016-08-02 09:29:56 -0500 )edit
0

answered 2016-07-31 13:58:57 -0500

Marcin Bogdanski gravatar image

I was running simple usb_cam setup on Ubuntu 14.04 and ROS Jade. usb_cam installed from ros repository with apt-get. Didn't try on kinetic yet.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2016-07-29 12:30:07 -0500

Seen: 2,718 times

Last updated: Jul 31 '16