Skip to content

Camera Drivers and Setup

Basheer Subei edited this page Jun 9, 2015 · 3 revisions

Pointgrey GigE cameras

  • Use the pointgrey driver.
  • Make sure your entire network (from camera to PC) can do GigE speeds.
  • Subscribe to /camera/image_color for debayered raw images.
  • Fix some bugs they have causing it to crash very often.

How to setup multiple ethernet cameras

How to get the DUO mini-lx camera up and running in ROS (using our ROS driver)

Installing the SDK and libraries (essentially just DUOLib.h and libduo.so), assuming Ubuntu 12.04 (should work on 14.04 but not tested)

  1. Copy the entire DUOSDK folder into /usr/local/. Export the variable DUO_SDK to point to that folder. Just place this in your .bashrc file: export DUO_SDK=/usr/local/DUOSDK.
  2. Copy the file libduo.so into /usr/local/lib.
  3. Copy the file DUOLib.h into /usr/local/include.
  4. Make sure all the above three files/folders have correct permissions (just run sudo chmod -R 775 DUOSDK/ for example, to change the permissions of the DUOSDK folder to rwxrwxr-x recursively). Just do that for all three files. Note: you might have to also change ownership to your username (look at chown command).
  5. Don't forget to run ldconfig again to reload your .so libraries (thanks to the awesome comment in this SO question).
  6. If the camera device won't open, check that you have permissions on the usb device (run chmod if needed)

Use the ROS driver

  1. Fork the repository for the driver.
  2. Clone your fork onto your hard drive (to make a local copy). Make sure it's placed inside <your_catkin_ws>/src/, because it's just another ROS package.
  3. Now you can build using catkin_make and it should work. Use rosrun duo3d_ros duo_node to run it.

Obviously, you have to have the DUO mini-lx camera connected through USB.

  1. Don't break it. Seriously, Krystian will kill you! In general, you should never have access to it without Krystian's direct supervision.

How to get the stereo camera (Bumblebee2) up and running in ROS

Plug 'er in

  1. Plug the FireWire (IEEE1394) cable in. Note: the laptop FireWire port doesn't supply power. Refer to the next step.
  2. Connect the power pins on the Bumblebee connector (VCC is pin 11 and GND is pin 10) to a decent power supply. Give her a voltage around 14-15V and make sure you limit the current to 1A. Check the manual for more.
  3. Check that the green light is on (on the front of the Bumblebee).

Start up the ROS nodes

  1. Start up the stereo 1394 camera driver: roslaunch camera1394stereo stereo_camera.launch . This node will now publish the raw images and camera_info to topics (probably /stereo_camera). An alternate camera driver someone should try out is Pointgrey's driver.
  2. Start up stereo_image_proc (the node that takes the two separate images and finds the disparity): ROS_NAMESPACE=stereo_camera rosrun stereo_image_proc stereo_image_proc. Note: make sure you set the ROS_NAMESPACE to the correct namespace (the prefix for the topic published by the camera driver above). Now the disparity and cloud images are being published to their topics.
  3. Now you can display the images if you want, or bag them, or whatever.
    • To display the images: rosrun image_view stereo_view stereo:=stereo_camera image:=image_raw.
    • To bag the images: rosbag record -O my_bagfile_name.bag /stereo_camera/left/image_raw /stereo_camera/right/image_raw /stereo_camera/disparity. Notice that you can choose your output file name and what topics to record (do not record all topics when running the camera, this will result in choppy framerates).

How to calibrate the Bumblebee2 (intrinsic parameters)

TODO

How to get a generic USB monoscopic camera up and running in ROS

  1. Plug USB cable in (this is important and cause of 80% of our WTF moments)
  2. Start up the usb_cam ROS node (USB camera driver). You can just use launch files (look in the launch folder inside the line_detection package).
  3. Make sure the image_proc node is running. It's just a node that takes in your raw image data (from usb_cam) and removes distortion. It publishes image_rect_color, which is probably what you want to use. You can find that in the launch files mentioned above.
  4. You can bag images and stuff if you want (see the Bumblebee section above).