Main Content

commands

List of commands available for GigE Vision or GenICam GenTL camera

Description

example

commands(g) lists the available commands for a GigE Vision® camera as a cell array, where g is the object created using the gigecam function. The output depends on the commands that are supported by your specific hardware.

example

commands(src) lists the available commands for a GigE Vision or GenICam™ GenTL camera as a string array, where src is the source object of the videoinput object created using the gige or gentl adaptor.

Examples

collapse all

The commands function tells you what commands are available for your camera to use.

Use the gigecamlist function to ensure that MATLAB® is discovering your cameras.

gigecamlist
ans = 

	Model              Manufacturer           IPAddress       SerialNumber
  ____________________   ___________________   _______________    ______________

  'MV1-D1312-80-G2-12'   'Photonofocus AG'     '169.254.192.165'  '022600017445'

Use the gigecam function to create the object and connect it to the camera.

g = gigecam
g = 

   Display Summary for gigecam:

          DeviceModelName: 'MV1-D1312-80-G2-12'
             SerialNumber: '022600017445'
                IPAddress: '169.254.192.165'
              PixelFormat: 'Mono8'
    AvailablePixelFormats: {'Mono8'  'Mono10Packed'  'Mono12Packed'  'Mono10'  'Mono12'}
                   Height: 1082
                    Width: 1312

   Show Beginner, Expert, Guru properties.
   Show Commands.

Get the list of supported commands from the camera. You can click Show Commands in the property list that is displayed when you create the object, or you can use the commands function.

commands(g)
  Available commands:

    ADCBoardDeviceTemperature_Update
    Average_Update
    CameraHeadFactoryReset
    CameraHeadReset  
    Correction_BusyUpdate
    Correction_CalibrateBlack
    Correction_CalibrateGrey
    Correction_SaveToFlash
    Counter_ImageReset
    Counter_ImageUpdate
    Counter_MissedBurstTriggerReset
    Counter_MissedBurstTriggerUpdate
    Counter_MissedTriggerReset
    Counter_MissedTriggerUpdate
    PLC_ts_trig_Arm
    PLC_ts_trig_FIFOClear
    SensorBoardDeviceTemperature_Update
    SensorDeviceTemperature_Update

The list shows the commands that the camera supports. You can then use the executeCommand function to execute any of these commands.

Create a connection to a GenICam GenTL camera using the videoinput function.

vid = videoinput("gentl");

Retrieve the source object.

src = getselectedsource(vid);

You can click Show Commands in the object property display output or use the commands function to get a list of supported commands for the camera.

commands(src)
ans = 

  18×1 string array

    "ADCBoardDeviceTemperature_Update"
    "Average_Update"
    "CameraHeadFactoryReset"
    "CameraHeadReset"
    "Correction_BusyUpdate"
    "Correction_CalibrateBlack"
    "Correction_CalibrateGrey"
    "Correction_SaveToFlash"
    "Counter_ImageReset"
    "Counter_ImageUpdate"
    "Counter_MissedBurstTriggerReset"
    "Counter_MissedBurstTriggerUpdate"
    "Counter_MissedTriggerReset"
    "Counter_MissedTriggerUpdate"
    "PLC_ts_trig_Arm"
    "PLC_ts_trig_FIFOClear"
    "SensorBoardDeviceTemperature_Update"
    "SensorDeviceTemperature_Update"

You can then use executeCommand to execute any of these commands.

Version History

Introduced in R2014b