-
Notifications
You must be signed in to change notification settings - Fork 23
Camera Drivers and Setup
Basheer Subei edited this page Jun 9, 2015
·
3 revisions
- 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.
- do this
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)
- Copy the entire DUOSDK folder into
/usr/local/
. Export the variableDUO_SDK
to point to that folder. Just place this in your .bashrc file:export DUO_SDK=/usr/local/DUOSDK
. - Copy the file
libduo.so
into/usr/local/lib
. - Copy the file
DUOLib.h
into/usr/local/include
. - 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 atchown
command). - Don't forget to run
ldconfig
again to reload your.so
libraries (thanks to the awesome comment in this SO question). - If the camera device won't open, check that you have permissions on the usb device (run
chmod
if needed)
Use the ROS driver
- Fork the repository for the driver.
- 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. - Now you can build using
catkin_make
and it should work. Userosrun duo3d_ros duo_node
to run it.
- 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 the FireWire (IEEE1394) cable in. Note: the laptop FireWire port doesn't supply power. Refer to the next step.
- 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.
- Check that the green light is on (on the front of the Bumblebee).
- 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. - 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. - 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).
- To display the images:
TODO
- Plug USB cable in (this is important and cause of 80% of our WTF moments)
- Start up the
usb_cam
ROS node (USB camera driver). You can just use launch files (look in the launch folder inside theline_detection
package). - Make sure the
image_proc
node is running. It's just a node that takes in your raw image data (fromusb_cam
) and removes distortion. It publishesimage_rect_color
, which is probably what you want to use. You can find that in the launch files mentioned above. - You can bag images and stuff if you want (see the Bumblebee section above).