• No results found

Setting DCAM-Specific Trigger Modes

In document Image Acquisition Matlab (Page 152-159)

You can now use all trigger modes and all trigger inputs that DCAM cameras support. Previous toolbox releases supported only trigger mode0. Support for additional trigger modes and inputs do not affect any existing code you use.

Control trigger functionality using thetriggerinfoandtriggerconfig functions and thetriggersourceproperty. Before R2010a, one

triggersourcewas available,externalTrigger. SelectingexternalTrigger configures the camera to use trigger mode0with trigger source0.

Thetriggersourceproperty is now composed of the trigger type (internal or external), the trigger source (0, 1, 2, etc.), and the mode number (0 through 5, 14 and 15). The following table summarizes the options.

Trigger

For example, the secondtriggersourcefor trigger mode 1 is called externalTrigger1-mode1. To use mode 3, the triggersourceis internalTrigger-mode3.

Note Toolbox versions before R2010a supported DCAM trigger mode 0 with the first availabletriggersourceasexternalTrigger. The existing externalTriggerproperty will be maintained so to prevent backward compatibility issues. In addition, in order to preserve symmetry with the new functionality,triggersource externalTrigger0-mode0, which is synonymous, will also be supported. The new trigger modes do not work before R2010a.

Usage Notes

If a trigger mode has multiple trigger sources (modes0,1,2,4, and5), then triggersourcehas a digit indicating the corresponding camera source, even if only one camera source is available. For example, if the camera has only a singletriggersourceavailable, the toolbox reports thetriggersource name asexternalTrigger0-modeX. If the trigger mode does not have multiple sources (mode3), then no source digit appears in the name (i.e, internalTriggerMode3instead ofinternalTriggerMode3-Source0).

The DCAM adaptor includes aTriggerParameterproperty that is passed to the camera when you set trigger configurations. TheTriggerParameter property is validated when you callSTARTafter selecting a hardware trigger mode.

If the selected trigger mode prohibits multiple frames per trigger, then an error appears when you callSTARTwithout settingFramesPerTriggerto1. If the camera supports only trigger mode0with source0, then the original functionality of having only theexternalTrigger triggersourceis supported.

Trigger modes 14 and 15 are vendor-specific and are assumed to be external triggers and have no restrictions on any settings. You must validate any settings you use.

The following sections detail the trigger modes.

Trigger Mode 0

This is the only trigger mode supported before R2010a. When a trigger is received, a frame is acquired. You can acquire multiple frames per trigger by switching the camera for hardware triggered mode to free running mode when a triggered frame is acquired.

No parameter is required.

The camera starts the integration of the incoming light from the external trigger input falling edge.

Trigger Mode 1

In this mode, the duration of the trigger signal is used to control the integration time of the incoming light. This mode is used to synchronize the exposure time of the camera to an external event.

No parameter is required.

The camera starts the integration of the incoming light from the external trigger input falling edge. Integration time is equal to the low state time of the external trigger input iftriggersourceisfallingEdge, otherwise it is equal to the high state time.

Trigger Mode 2

This mode is similar to mode1, except the duration of the trigger signal does govern integration time. Instead the number of trigger signals received does.

Integration commences upon the start of the first trigger signal and continues until the start of theNth trigger signal.

ParameterNis required and describes the number of trigger signals in an integration.

The camera starts the integration of the incoming light from the first external trigger input falling edge. At theNth external trigger input falling edge, integration stops. ParameterNis required and must be2or greater. (N >= 2).

Trigger Mode 3

Use this internal trigger mode to achieve a lower frame rate. When the trigger generates internally, a frame is acquired and returned. A new frame is not acquired forNx Tf whenNis the parameter and Tf is the cycle time of the fastest frame rate supported by the camera.

A parameter is required, as described above.

This is an internal trigger mode. The camera issues the trigger internally and cycle time is N times of the cycle time of the fastest frame rate. Integration

time of incoming light is described in the shutter register. ParameterNis required and must be1or greater (N >= 1).

Trigger Mode 4

This mode is the “multiple shutter preset mode.” It is similar to mode 1, but the exposure time is governed by the shutter property. On each trigger, shutter property defines the exposure duration. When N triggers are received, a frame is acquired.

ParameterNis required and describes the number of triggers.

The camera starts integration of incoming light from the first external trigger input falling edge and exposes incoming light at shutter time. Repeat this sequence until the Nth external trigger input falling edge, then finish integration. ParameterNis required and must be1or greater (N >= 1).

Trigger Mode 5

This mode is the “multiple shutter pulse width mode.” It is a combination of modes 1 and 2. The exposure time is governed by the duration of the trigger signal and a number of trigger signals can be integrated into a single readout.

If the trigger parameter is1, this mode is degenerate with mode 1.

A parameter is required. The parameter describes the number of triggers.

The camera starts integration of incoming light from first the external trigger input falling edge and exposes incoming light until the trigger is inactive.

Repeat this sequence until the Nth external trigger input falling edge, then finish integration. ParameterNis required and must be1or greater (N >= 1).

Trigger Mode 14

This is a vendor-specific mode and no information is available. Consult the documentation for your camera.

Trigger Mode 15

This is a vendor-specific mode and no information is available. Consult the documentation for your camera.

In document Image Acquisition Matlab (Page 152-159)

Related documents