NET iCube User Manual

NET iCube User Manual

Cmos cameras
Hide thumbs Also See for iCube:

Advertisement

1
SDK API Manual
USB3.0 CMOS cameras
USB2.0 CMOS cameras

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the iCube and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

Summary of Contents for NET iCube

  • Page 1 SDK API Manual USB3.0 CMOS cameras USB2.0 CMOS cameras...
  • Page 2: Before You Start

    All the materials in this document are protected by copyright and other laws for intellectual property. They are not allowed to be copied, reproduced or modified for any use without the permission of NET GmbH. NET GMBH reserves the right to make changes in specifications, functions or designs at any time and without any notice.
  • Page 3: Table Of Contents

    APPLICATIONS …………………………………………………………………………………………………………………………….…………….. 19 ...……………………………………………………………………………………………………………………………………..19 ICUBE ICONTROL ...………………………………………………………………………………………………………..…………………… 19 CALIBRATION (OPTIONAL) ...…………………………………………………………………………………………………………………..…………. 20 ICUBE DX-REGISTRATION .……………………………………………………………………………………………………………….…….. 21 ICUBE SDK SAMPLES (WINDOWS) SDK-INTERFACE ..……………………………………………………………………………………………………………………..………………... 22 ..………………………………………………………………………………………………..………………….. 22 MICROSOFT VISUAL STUDIO / C++ ……………………………………………………………………………………………………………………………………………….. 22 C++ BUILDER …………………………………………………………………………………………………………………………………………. 22 VISUAL BASIC .NET .…………………………………………………………………………………..…………………………………………………….
  • Page 4 EXPOSURE FUNCTIONS ...…………………………………………………………………………………………..…………………. 49 ADDITIONAL PARAMETER FUNCTIONS ERROR CODES ………………………………………………………….………………………………………………………………………………… 51 DIRECTSHOW-INTERFACES ..………………………………………………………………………………………………………………………. 52 …...……………………………………………………………………………………………. 52 SUPPORTED STANDARD-DIRECTSHOW-INTERFACES ……………………………………………………………………………………………………………………….. 52 ICUBE-DIRECTSHOW-INTERFACES …………………………………………………………………………………………………………………………… 53 ICUBE-DIRECTSHOW-SETTING ...………………………………………………………………………………………………………………………. 54 VIDEO CONTROL PARAMETERS ……………………………………………………………………………………………………………….. 56 VIDEO STREAM CONTROL PARAMETERS TECHNICAL SUPPORT…………………………………………………………………………………………………………………………………. 57 IMPRINT…………………………………………………………………………………………………………………………………………………….. 58...
  • Page 5: License

    End User License Agreements (EULA). The SOFTWARE includes NET GmbH and NET GmbH suppliers’ intellectual property. Please read NET GmbH and NET GmbH suppliers’ EULA before installing the SOFTWARE. If you do not accept the terms of the license agreements, please do not install copy or use this SOFTWARE.
  • Page 6: List Of Figures

    List of Figures ..........................13 IGURE OUNT ........................... 17 IGURE EVICE MANAGER ......................19 IGURE ONTROL VIEWER SOFTWARE ....................19 IGURE ACBETH STANDARD COLOR CHECKER ........................20 IGURE UBE DX REGISTRATION ......................53 IGURE IDEO CONTROL PARAMETERS ......................55 IGURE AMERA CONTROL PARAMETERS ....................
  • Page 7: Standard Conformity

    Standard Conformity Legal Notice The cameras fully implement theUSB3.0 standard. RoHS II The product fulfills the requirements of the EU directive RoHS 2011/65/EU in the currently valid version from 8.June 2011 regarding the restrictive use of certain hazardous materials in electric applications within the allowable limits.
  • Page 8: General Handing

    Safety Signs Description Indicates a potentially hazardous situation that may result in death or serious injury (*1) in the event of improper handling. WARNING Indicates a potentially hazardous situation that may result in light to moderate injuries (*2) or only in property damage (*3) in the event of CAUTION improper handling.
  • Page 9 Do not disassemble, repair, or modify the equipment. Otherwise, fire or electric shock may result. For internal repair, inspection or cleaning, contact your sales representative. Never pull apart Do not place anything on the equipment. If metallic objects, liquid, or other foreign matter enters the equipment, fire or electric shock may result.
  • Page 10 Instruction Do not give strong impact against the equipment. It may cause the trouble. Avoid When performing connection, turn off power. When connecting the power cable and the connection cable, turn off the equipment power. Otherwise, fire or electric shock may result. Instruction Do not expose the camera head to any intensive light (such as direct sunlight).
  • Page 11: System Requirements

    System Requirements Hardware requirements - USB 3.0 on board Interface. NET successfully tested USB 3.0 adapters, which use the Renesas chipset µPD720202 or µPD720200A. Please be sure that you installed the latest USB 3.0 adapter driver. - lockable SuperSpeed USB3.0 cable up to 3m. If you want to use your own USB 3.0 cables, you have to ensure that the data quality and shielding of the cable is sufficient.
  • Page 12: Usage Notes

    Environmental 20 %–90 % non-condensing The conditions for shock and vibrations are on request by NET. Maintenance Turn off power to the equipment and wipe it with a dry cloth. If it becomes severely contaminated, gently wipe the affected areas with a soft cloth dampened with diluted neutral detergent. Never use alcohol, benzene, thinner, or other chemicals because such chemicals may damage or discolor the paint and indications.
  • Page 13: Figure 1: C-Mount Lens

    Cleaning the sensor window Avoid cleaning the sensor window if possible. Keep lens cap closed as long as no lens is attached, avoid touching the sensor. If necessary, clean the sensor window using compressed air. If further cleaning is required, use lint-free, ESD-safe cloth wiper. Avoid cloth that could generate static charge or that could scratch the window.
  • Page 14 Occurrence of moiré If you shoot thin stripe patterns, moiré patterns (interference fringes) may appear. This is not a malfunction. Electromagnetic fields Keep the camera away from strong electromagnetic fields. Avoid static charging and handle the camera in ESD protected area. If an intense magnetic or electromagnetic field is generated near the camera or connection cable, noise may be generated on the screen.
  • Page 15: Software

    - iCubeSDKSample_x32_x64_vs2010: (Visual Studio 2010 32bit/64bit SDK Example) - vb.6: (Visual Basic 6.0 SDK Example) -VB.NET (VB.NET SDK Example) 06_Tools dxRegistration: Register more than one device as direct show -filter; fix positioning for direct show and (see readme.txt in this folder)
  • Page 16 (describes requirements of usbfs and libudev packets) 99-netusbcam.rules: (rules for netusbcam libudev packet) 05_Interfaces SDK (SDK.tar.gz): (SDK packet) API: (NETUSBCAM_API.h ) HelloICube: (minimal iCube example) MultiROI_SIMR_Test: (multi roi sdk example ) MultiROITest (multi roi sdk example ) sdk_sample1: (QT based SDK example) 16 / 58...
  • Page 17: Software Installation

    4. Follow the instruction of the Windows plug and play manager. 5. After the 3iCube driver is installed, you can see on the device Manager / imaging devices the recognized 3iCube camera. 3iCube:  NET ICube_Cam Device USB30 Windows (german version) Windows (english version)
  • Page 18: Software And Driver Update

    Software and Driver update The latest drivers and documentations are available on NET´s homepage www.net-gmbh.com The software package includes following files: - iControl viewer software - USB driver - API - iCube Cognex AIK Setup Please install the full package (iControl and USB driver) to get the right function.
  • Page 19: Applications

    Applications iCube iControl viewer software The iControl software allows you to test the functionalities of the 3iCube camera on your own application. Apart from controlling the 3iCube camera, you can grab images and save them as jpg, bmp and tiff files.
  • Page 20: Icube Dx-Registration

    The selection of the dx-capture filter in 2) will change automatically, when changing the device. 2) Register the selected device. The name in the square brackets is the dx-friendly-name, which will appear in amcap for example. Additional functionalities are explained in Tools\dxRegistration\readme.txt Figure 5: iCube dx registration 20 / 58...
  • Page 21: Icube Sdk Samples (Windows)

    SDK samples (windows) The iCube SDK samples shows, how you can develop or integrate the 3iCube in your own application software. On the CD-Rom you can find examples for following development software: - 4133_MultiROI: (Microsoft Visual Studio multi-roi example ) This example works with 4133 and 4203 cameras only.
  • Page 22: Sdk-Interface

    Uncomment the define „#define BORLAND_C“ in the "NET_iCube_API.h" file. dynamic linking: Comment the define „#define LIBFILE“ in the "NET_iCube_API.h" file. Visual Basic .NET: available Visual Basic.NET example: Interface definitions: iCube_API.vb Visual basic 6.0 available Visual Basic 6.0 example: Interface definitions: ICube_API.bas...
  • Page 23 C# example: Interface definitions: ICube.cs 23 / 58...
  • Page 24: Available Functions

    Differences are explained at the respective function explanations. Table 1: Standard camera function control Category Function Description initializes the camera connected to iCube SDK Init your computer iCube SDK Open opens the camera interface iCube SDK Close closes the camera interface...
  • Page 25 SDK_SetMode the basic format (e.g. 640x480) iCube SDK_GetMode get the basic format Mode function get the possible formats of the iCube SDK_GetModeList camera set the camera into a skipping or iCube SDK_SetBinSkip binning mode get the current skipping or binning...
  • Page 26: Function Detailed Overview

    Functions detailed overview: Camera control functions: Init() iCube SDK_ Purpose: initializes the camera connected to your pc. Description Parameters Return value Int CamCount Return value: CamCount: number of connected cameras. Open(int nCamIndex) iCube SDK_ Purpose: opens the camera interface. Description...
  • Page 27 IsOpen (int nCamIndex) iCube SDK_ Purpose: checks for open camera interfaces. Description Parameters int CamIndex Return value Return value: stat: camera is open OFF: camera is not open Parameters: nCamIndex: index of camera. 27 / 58...
  • Page 28 SetCallback (int nCamIndex,int nMode,long iCube SDK_ (CALLBACK *CallbackFunc,void* pCBContext) Purpose: sets the callback function. Only necessary, if Callback-Flag in “iCubeSDK_Start” is true. The structure of the callback-function has to be as follows: long CALLBACK CallbackFunc(BYTE * pBuffer, long lBufferSize,PVOID pContext )
  • Page 29 Start (int nCamIndex,HWND ImgHandle,bool Preview,bool Callback) iCube SDK_ Purpose: starts the video stream Linux: NETUSBCAM_Start uses only the parameter nCamIndex, because there is no internal preview functionality implemented. Description Parameters int CamIndex, HWND ImgHandle, bool Preview, bool CallBack Return value...
  • Page 30 Stop (int nCamIndex) iCube SDK_ Purpose: stops the video stream. Closes the default preview window, if used. Stop resets the trigger status to stop Description Parameters int CamIndex Return value int stat Return value: stat IC_SUCCESS: success else: error Parameters: nCamIndex: index of camera.
  • Page 31 GetName(int nCamIndex,char* Name) iCube SDK_ Purpose: get the name of the selected camera Description Parameters int CamIndex, int* Name Return value int stat Return value: stat: IC_SUCCESS: success else: error Parameters: nCamIndex: index of camera. char* Name name of the camera.
  • Page 32 GetGoodFrames(int nCamIndex,int* pnFrames) iCube SDK_ Purpose: get the number of good frames since the last start. Description Parameters int CamIndex, int* pnFrames Return value int stat Return value: stat IC_SUCCESS: success else: error Parameters: nCamIndex: index of camera. int* pnFrames: the number of good frames since the last start.
  • Page 33: Version Functions

    Version functions: void GetVersion(int nType ,char* pVersion) iCube SDK_ Purpose: get the SDK version Description Parameters int nType, char* pVersion Return value Return value: none. Parameters: Type: type of parameter to get. (See Parameter Definitions in API Header) char* version...
  • Page 34 GetFPGAVersion(int nCamIndex,char* pVersion) iCube SDK_ Purpose: get the camera FPGA firmware version. This functions returns IC_SUCCESS if the hardware uses a FPGA. Description Parameters int CamIndex, char* pVersion Return value int stat Return value: stat: IC_SUCCESS: success else: error...
  • Page 35: Roi Functions

    ROI functions: SetResolution(int nCamIndex,ROI_PROPERTY *property) iCube SDK_ Purpose: set the resolution and position of the Region of Interest (ROI). enable/disable the ROI mode. This function can be called anytime after “iCubeSDK_Open”. This function has to be called after “iCubeSDK_SetMode”, if “iCubeSDK_SetMode”is used.
  • Page 36 GetResolutionRange(int nCamIndex,ROI_RANGE_PROPERTY *property) iCube SDK_ Purpose: get the min/max resolution of the Region of Interest (ROI). Description Parameters int CamIndex, ROI_PROPERTY *property Return value int stat Return value: stat IC_SUCCESS: success else: error Parameters: nCamIndex: index of camera. ROI_RANGE_PROPERTY *property: pointer to the ROI_RANGE_PROPERTY structure.
  • Page 37: Mode Functions

    Mode functions: SetMode(int nCamIndex,int nMode) iCube SDK_ Purpose: set the basic format (e.g. 640x480). This function has to be called before “iCubeSDK_Start”. If iCubeSDK_SetMode is not used, the camera will start with the default mode (highest resolution). Description Parameters int CamIndex, int nMode...
  • Page 38 GetMode(int nCamIndex,int* pMode) iCube SDK_ Purpose: get the basic format. Description Parameters int CamIndex, int nMode Return value int stat Return value: stat: IC_SUCCESS: success else: error Parameters: nCamIndex: index of camera. int* pMode: current format. GetModeList(int nCamIndex,int* pLength,int* pList)
  • Page 39: Bin Skip Functions

    Bin Skip functions: SetBinSkip(int nCamIndex,int nParameter,int nMode) iCube SDK_ Purpose: set the camera into a skipping or binning mode. This function has to be called before “iCubeSDK_Start”. This function has to be called after “iCubeSDK_SetMode”, if “iCubeSDK_SetMode”is used. The availability of BinSkip modes is camera dependent and can be identified with “iCubeSDK_GetBinSkipList”...
  • Page 40 GetBinSkip(int nCamIndex,int* pParameter,int nMode) iCube SDK_ Purpose: get the current skipping or binning mode. Description Parameters int CamIndex, int* nParameter, int nMode Return value int stat Return value: stat: IC_SUCCESS: success else: error Parameters: nCamIndex: index of camera. int* pParameter: (BIN_SKIP_OFF,BIN_SKIP_2ND_PIXEL or BIN_SKIP_4TH_PIXEL).
  • Page 41: Save Functions

    Save functions: SaveToFile(int nCamIndex,char * Name) iCube SDK_ Purpose: saves a bitmap, jpg or tiff. Linux: tiff is not supported by the linux api tiff can be used to save 16bit per color channel pictures (3iCube only). This is only possible, if REG_DATA_TRANSMISSION is set to 1.
  • Page 42 int ICubeSDK_SaveAvi(int nCamIndex,char* Name,int nMode,int nTimeInSecs) Purpose: saves an avi stream to the hard disk. If an avi stream is saved without the use of an preview window, a window_handle has also being provided with ICubeSDK_Start(). ICubeSDK_GetCamParameter(REG_AVI_STATE) get the avi stream save status (ON||OFF), whereat ON means saving is still in progress and OFF saving is finished.
  • Page 43: Trigger Functions

    If the last sensor line is not arriving in time the return value will be an error. IMMEDIATE_TRIGGER_RETURN: SetTrigger(TRIG_SW_DO) returns immediately. 3iCube: IMMEDIATE_TRIGGER_RETURN is default and the only possible mode. iCube: DELAYED_TRIGGER_RETURN is default, but it is more common to use IMMEDIATE_TRIGGER_RETURN. Description Parameters...
  • Page 44 GetTrigger(int nCamIndex,int* nMode) iCube SDK_ Purpose: gets the current trigger mode. Description Parameters int nCamIndex, int* nMode Return value int stat Return value: stat IC_SUCCESS: success else: error Parameters: nCamIndex: index of camera. Int* nMode: current trigger mode. 44 / 58...
  • Page 45: Parameter Functions

    Parameter functions: SetCamParameter(int nCamIndex,int Type,unsigned long Value) iCube SDK_ Purpose: set parameter value If ICubeSDK_SetCamParameter is used with multi roi applications, the correct roi ID (2-4) has to set before this function with ICubeSDK_SetCamParameter(nCamIndex,REG_ROI_ID, roi ID) See 4133_MultiROI SDK Example.
  • Page 46 SDK_GetCamParameterRange(int nCamIndex,int Type,PARAM_PROPERTY*property) Purpose: get parameter min/max values, default value, auto, onepush and enabled information. Description Parameters int nCamIndex, int Type, PARAM_PROPERTY *property Return value int stat Return value: stat: IC_SUCCESS: success else: error Parameters nCamIndex: index of camera.
  • Page 47: Exposure Functions

    This functions can be used alternatively to parameter functions, for manipulating exposure only. Parameter value is in milli-seconds. Be aware that every change of clock and width will lead to different exposure values. SetExposure(IN int nCamIndex, IN float Value) iCube SDK_ Pupose: set Exposure time (Input) Description...
  • Page 48 GetExposureRange(IN int nCamIndex, PARAM_PROPERTY_f *property) iCube SDK_ Pupose: get Exposure time Range (Output) Description Parameters int CamIndex, PARAM_PROPERTY_f *property Return value int stat Return value: stat: IC_SUCCESS: success else: error Parameters: nCamIndex: index of camera PARAM_PROPERTY_f *property: pointer to the PARAM_PROPERTY_f...
  • Page 49: Additional Parameter Functions

    Additional Parameter functions: (Also useable with Exposure functions) int iCube SDK_GetParamAuto(int nCamIndex,int Type,int* bAuto) Purpose: check, if the parameter supports auto mode. Description Parameters int CamIndex, int Type, int* bAuto Return value int stat Return value: stat: IC_SUCCESS: success else:...
  • Page 50 SDK_SetParamDef(int nCamIndex,int Type) Purpose: set parameter to default setting Description Parameters int CamIndex, int Type Return value int stat Return value: stat: IC_SUCCESS: success else: error Parameters: nCamIndex: index of camera. Type: type of parameter to set. (See Parameter Definitions in API Header)
  • Page 51: Error Codes

    Error Codes Table 3: Error codes Name value Description IC_SUCCESS no error IC_ERROR unspecified error IC_IF_NOT_OPEN camera-interface is not open IC_WRONG_PARAM parameter is out of range IC_OUT_OF_MEMORY memory could not be allocated IC_ALREADY_DONE e.g. Interface already open wrong PLL value (more information on operation manual / IC_WRONG_CLOCK_VAL camera specification) IC_COM_LIB_INIT...
  • Page 52: Directshow-Interfaces

    These are the interfaces for controlling camera parameters. Other implemented interfaces (e.g. IAMStreamConfig ) are not shown here. iCube-DirectShow-Interface: With the iCube-DirectShow-interface, it is possible to control all camera parameters, including Trigger-mode, ROI-mode and Bin/Skip-modes. (In DirectShow, ROI-mode is, unlike to the SDK, a basic format, like 640x480) For further documentation see DirectShow-SDK-Files (iCubeInterface.h,iCubeInterface.cpp).
  • Page 53: Icube-Directshow-Setting

    Video Control Parameters Figure 7: Video control parameters 53 / 58...
  • Page 54: Video Control Parameters

    Table 4: Video Control Parameters Video Control Brightness Eeprom Contrast Eeprom Gamma Eeprom BlackLevel Eeprom BlackLevel Auto Eeprom Exposure Time Exposure Time Auto Eeprom Rough Eeprom Fine Eeprom Exp. Target Eeprom Gain Eeprom Default Registry (default parameters) Color Enhancement Color Enhancement enable Eeprom Saturation Eeprom...
  • Page 55: Table 4: Camera Control Parameters

    Camera Control Parameters Figure 8: Camera control parameters Table 5: Camera Control Parameters Trigger Trigger enable not saved Software Trigger not saved Hardware Trigger not saved Trigger Delay Eeprom Push SW trigger not saved Strobe Strobe Delay Eeprom Strobe Length Eeprom Other flip V...
  • Page 56: Video Stream Control Parameters

    Video Stream Control Parameters Figure 9: Video stream control parameters Table 6: Video stream control parameters Videoformat Videostandard display only Video Format Registry Framerate calculation (PLL, H, Shutter) Resolution Registry Region of Interest Start Position Horizontal Registry Vertical Registry Size Horizontal Registry Vertical...
  • Page 57: Technical Support

    Asia +81 45 476 2423 In case of an RMA, you must first contact NET and obtain an RMA Number before sending the product to us. We are not responsible for any problems caused by not following the RMA procedure.
  • Page 58: Imprint

    IMPRINT NET New Electronic Technology GmbH Address: Lerchenberg 7 D-86923 Finning Germany Contact: Phone: +49-88 06-92 34-0 Fax: +49-88 06-92 34-77 www.net-gmbh.com E-mail: info@net-gmbh.com VAT- ID: DE 811948278 Register Court: Augsburg HRB 18494 Copyright © 2014 NEW ELECTRONIC TECHNOLOGY GMBH All rights reserved.

This manual is also suitable for:

3icube

Table of Contents