Skip to content

Controlling cameras with the service interface

furgalep edited this page Mar 26, 2013 · 1 revision

To connect to a camera, you must remap the service that the interface driver will connect to. For example:

> rosservice list
/mv_37/mv_camera/get_loggers
/mv_37/mv_camera/poll_property_list
/mv_37/mv_camera/set_camera_info
/mv_37/mv_camera/set_logger_level
/mv_37/mv_camera/set_parameters
/mv_41/mv_camera/get_loggers
/mv_41/mv_camera/poll_property_list
/mv_41/mv_camera/set_camera_info
/mv_41/mv_camera/set_logger_level
/mv_41/mv_camera/set_parameters
/rosout/get_loggers
/rosout/set_logger_level
/rqt_gui_cpp_node_18651/get_loggers
/rqt_gui_cpp_node_18651/set_logger_level

we see that we would like to hook up the interface to the mv_41 camera. So we run:

> rosrun mv_camera mv_camera_interface poll_property_list:=/mv_41/mv_camera/poll_property_list

The interface implements a simple command line:

help
Commands are: 
	 quit: exit the program 
	 list: list all available properties 
	 set: set a property 
	 info: get property details 
	 save: save camera configuration 
	 load: load camera configuration 
	 capture: start continuous capture
	 stop: stop continuous capture 
	 single: get a single image 
	 restart: close and reopen device 
	 close: close device 
	 open: open device 
         find: find a parameter based on a substring search

For rolling shutter cameras, the line delay parameter may be adjusted by adjusting the pixel clock. Let P be the pixel clock in Hz. Let Np be the number of pixels in a row (including blank pixels)

Clone this wiki locally