MVTec Software GmbH
  Building Vision For Business
Halcon

HALCON 8.0 Image Acquisition Interface for Daheng Cameras

This page provides the documentation of the HALCON DahengCAM interface for USB 2.0 and 1394IIDC cameras from Daheng Group. Registered customers can download the latest revision of this interface from the MVTec WWW server.

Revision: 3.3

System Requirements

  • Intel compatible PC with Windows 2000/XP.
  • DahengCAM driver <camera name>.sys, e.g., HV3103UC.sys from driver CD (2008-05-30).
    Typically, this file resides in the directory %WINDIR\system32\drivers. If you do not have this driver, please contact Daheng Group or the vendor from which you bought the camera.
  • Needed DLL files: Raw2Rgb.dll, HVDailt.dll, HVUtil.dll from driver CD (2008-05-30).
    These files must be within your search path %PATH% (typically, it resides in the directory %WINDIR%\system32). If you do not have these DLLs, please contact Daheng Group or the vendor from which you bought the camera.
  • HALCON image acquisition interface hAcqDahengCAM.dll or parhAcqDahengCAM.dll, respectively.
    If you have properly installed the interface, both DLLs should reside in bin\%HALCONARCH% within the HALCON base directory %HALCONROOT% you have chosen during the installation of HALCON.

Features

  • Multiple cameras.
  • Synchronous and asynchronous grabbing.
  • External trigger.
  • Software control of gain, shutter, and white balancing.

Limitations

  • grab_data and grab_data_async not supported.
  • No LUTs.

Using Multiple Cameras

When using multiple Daheng USB 2.0 cameras each camera has an unique ID number starting with '1'.

Using Asynchronous Grabbing

Daheng USB 2.0 cameras differ only between continuous grabbing and triggered grabbing. Thus, when calling grab_image_async in continuous mode you will always get the newest available image.

Description

Parameters for open_framegrabber():

Name 'DahengCAM' The name of the HALCON image acquisition interface.
HorizontalResolution --- Ignored.
VerticalResolution --- Ignored.
ImageWidth width The width of the desired image part ('0' stands for the complete image). Default: 0.
ImageHeight height The height of the desired image part ('0' stands for the complete image). Default: 0.
StartRow row The row coordinate of the upper left pixel within the desired image part. Default: 0.
StartColumn column The column coordinate of the upper left pixel within the desired image part. Default: 0.
Field --- Ignored.
BitsPerChannel --- Ignored.
ColorSpace 'default', 'gray', 'rgb' Specify the desired color space and thus the number of image channels of the resulting HALCON image. Default: 'gray'.
Generic --- Ignored.
ExternalTrigger 'true', 'false' Activate/deactivate external triggering. Default: 'false'.
CameraType 'HV-13xx', 'HV-20xx', 'HV-30xx', 'HV-31xx', 'SV-xxxx' The type of the connected camera series. Default: 'HV-13xx'.
Device '1', '2', '3', ... The ID of the camera. If you have two cameras connected the first one has device ID '1', the second has device ID '2'. Default: '1'.
Port --- Ignored.
LineIn --- Ignored.

Parameters for set_framegrabber_param():

'adc_level' 'adc0', 'adc1', 'adc2', 'adc3' Sets the level of the A/D translation:
  • adc0: low-order 7 bits of 10 bits data are used.
  • adc1: low-order 8 bits of 10 bits data are used.
  • adc2: mid-order 8 bits of 10 bits data are used.
  • adc3: high-order 8 bits of 10 bits data are used.
Default: 'adc2'.
'bayer_convert_type' 'low', 'normal', 'high' Sets one of the possible conversion types. Default: 'low'.
'bayer_layout' 'bayer_gb', 'bayer_gr', 'bayer_bg', 'bayer_rg' Sets the associated bayer mode to the camera. In case of using a SV-13xx camera default is 'bayer_rg', else 'bayer_gr'.
'color_space' 'gray', 'rgb', 'yuv' Sets the desired color space. Default: 'gray'.
'dh_lut_table' file name Sets the LUT table via reading the information from the specified file (supported by SV-xxxx cameras only).
'gain' 0.0 ... 127.0 (float) Specifies the gain value of the camera.
'grab_timeout' 100 ... 327680 (long) Specifies the desired timeout (milliseconds passed as an integer) for aborting a pending grab. Default: 5000.
'image_height' height (long) Sets the height of the image.
'image_width' width (long) Sets the width of the image.
'output_io_0' 'integration_signal', 'trigger_ready', 'user_set', 'strobe' Sets the desired I/O to output 0 of the camera (supported by SV-xxxx cameras only). Default: 'strobe'.
'output_io_1' 'integration_signal', 'trigger_ready', 'user_set', 'strobe' Sets the desired I/O to output 1 of the camera (supported by SV-xxxx cameras only). Default: 'trigger_ready'.
'output_io_2' 'integration_signal', 'trigger_ready', 'user_set', 'strobe' Sets the desired I/O to output 2 of the camera (supported by SV-xxxx cameras only). Default: 'integration_signal'.
'resolution' 'mode0', 'mode1', 'mode2', 'mode3' Specifies the resolution of the image depending of the camera model. Mode0 always is the maximum resolution of the camera. Default: 'mode0'.
'shutter' 0 ... 16383 (long) Sets the shutter (exposure time) of the camera.
'shutter_unit' 'us', 'ms', 's' Sets the unit of the shutter. Default: 'ms'.
'snap_mode' 'continuous', 'trigger', 'trigger_edge', 'trigger_level' Sets the snap mode of the camera. If set to 'trigger' an external trigger signal is needed to grab an image. In continuous mode the camera grabs images continuously. Default: 'continuous'.
'snap_speed' 'normal', 'high' Sets the snap speed modus. Default: 'high'.
'start_column' column (long) Sets the start column of the image. Default: 0.
'start_row' row (long) Sets the start row of the image. Default: 0.
'strobe' 'enable', 'disable' Enables/disables the strobe mode (supported by SV-xxxx cameras only). Default: 'enable'.
'trigger_signal' 'high_active', 'low_active' Specifies the desired type of the trigger signal. Default: 'high_active'.
'trigger_source' 'input0', 'input1', 'input2' Sets the desired trigger source (supported by SV-xxxx cameras only). Default: 'input0'.
'white_balance' 'enable', 'disable' Enables or disables the white balance mode. Default: 'disable'.
'white_balance_b' white_balance_b (float) Sets the white balance for the blue channel.
'white_balance_g' white_balance_g (float) Sets the white balance for the green channel.
'white_balance_r' white_balance_r (float) Sets the white balance for the red channel.

Parameters for get_framegrabber_param():

Additional parameters supported by get_framegrabber_param only. Note that all parameters supported by set_framegrabber_param can also be accessed by get_framegrabber_param. Furthermore, corresponding to the parameters supported by set_framegrabber_param, there may exist additional read-only parameters with the following postfixes:

  • '_description': These parameters provide the tooltip of the corresponding parameter as a string.
  • '_range': These parameters provide the minimum, maximum, stepwidth, and default values for the corresponding integer or float parameter as a tuple with 4 elements, e.g., get_framegrabber_param(..,'exposure_range',..) will return the output tuple [min,max,step,default]. Optionally, this tuple can also contain additional valid string values like 'auto' or 'manual'.
  • '_values': These parameters provide the valid value list for the corresponding parameter as a tuple, e.g., get_framegrabber_param(..,'volatile_values',..) will return the output tuple ['enable','disable'].
All these postfixed parameter names are not returned when calling info_framegrabber(..,'parameters',..) and are used to enable the easy parameterization via a generic graphical user interface, particularly the HDevelop Image Acquisition Assistant.

'revision' revision The revision number of the HALCON DahengCAM interface.

Release Notes

  • Revision 3.3 (Sep 3, 2010):
    • Fixed memory problem in info_framegrabber(..,'info_boards',..).
    • Added missing descriptions ('paramname__description') for 9 parameters.
  • Revision 3.2 (Dec 1, 2008):
    • Added support of the SV-xxxx camera series.
    • Added parameters 'color_space', 'output_io_0', 'output_io_1', 'output_io_2', 'strobe', and 'trigger_source'.
  • Revision 3.1 (Apr 22, 2008):
    • Added read-only parameters with postfix '_description', '_range', and '_values' to enable the easy parameterization via a generic graphical user interface.
  • Revision 3.0 (May 15, 2007):
    • HALCON 8.0 version of the interface (included in HALCON 8.0 DVD).
    • Added support of SV-13xx camera series.
    • Bugfix using multiple cameras.
    • Added parameters 'bayer_convert_type', 'bayer_layout', 'dh_lut_table', 'image_height', 'image_width', 'shutter_unit', 'snap_speed', 'start_col', and 'start_row'.
    • Added 'trigger_edge' and 'trigger_level' to parameter 'snap_mode'.
    • Changed camera type names.
    • Changed type of gain parameter from float to long (float still supported).
  • Revision 2.0 (Jul 28, 2006):
    • First official release.


© Copyright 2012, MVTec Software GmbH, corporate/legal/privacy information