Only released in EOL distros:  

Package Summary


hrl_camera was designed for simpler usage and management of cameras. It includes 3 components. First, it includes scripts for making cameras accessible over ROS. Second, it provides a method to uniquely reference different cameras. Finally, it provides a python interfrace for cameras to be accessed using Python code.


In Python, to use cameras declared in this package's

 import hrl_camera.hrl_camera as hc
 camera_object = hc.find_camera('CAMERA_NAME')

The function find_camera takes as input a string, looks up that string in the dictionary declared in, then instantiate and returns an object of the appropriate class.

Entries in

For the above steps to work, each entry in needs to be a dictionary entry mapping from a human friendly name (CAMERA_NAME in the above snipplet) to a dictionary of parameters containing the keys 'class' and 'uuid'. The value specified by 'class' must be the Python legal class name of the object that needs to be instantiated and must be in the PYTHON_PATH of the process that executes find_camera. The value in 'uid' should be the camera's UID provided by the utility

Writing a New Camera Class

To be compatible with this package new camera classes needs to have an init() method that takes in the configuration dictionary defined in For examples, look at and Utilities

  • Prints out connected cameras and associated UIDs
  • CAMERA_NAME Publishes images over ROS (topic "cv_camera_" + CAMERA_NAME with type Image). Publishes CameraInfo messages on topic "cv_camera_" + CAMERA_NAME + "_info". Works with cameras defined in

  • OPENCV_ID Publishes images over ROS (topic "cv_camera" + str(OPENCV_ID) with type Image). Works with any camera openable by OpenCV2.

Wiki: hrl_camera (last edited 2010-03-19 19:16:48 by HaiDNguyen)