コンテンツにスキップ

GigE Line Scan Use Case Descriptions and Diagrams#

This topic describes common use cases for Basler line scan GigE and 5GigE cameras and how to configure these cameras for the given use cases.

The use cases in this topic are intended to help you in developing an initial understanding of how triggers and parameters interact.

概要#

  • The camera provides multiple trigger functions, e.g., Line Start trigger or Frame Active trigger, that can be set by the Trigger Selector parameter. Where applicable in the following use case descriptions, the setting of the trigger selector is indicated under To set the parameters. All parameters related to the trigger configuration that aren't indicated in the To set the parameters section of the respective use case example, are assumed to remain at their factory default values.
    For further triggering background information, see the Triggered Image Acquisition and Aquisition Timing Information topics.
  • For the sake of simplicity, the frame height in the following use case examples is set to only a few lines (e.g., 2 or 3). However, for real-world applications Basler recommends a frame height of at least 100 to 1000 lines per frame.
  • The Features section and its sub-sections (e.g., the Line Timeout and Spatial Correction topics) provide detailed information about the features and how to configure them.

情報

  • GigE Vision line scan cameras combine multiple lines to a larger frame. This can greatly reduce the processing load for the recipient (e.g., host computer, transport layer).
  • If an acquisition stop command is issued when not all lines of the current frame are acquired yet, a partial frame will be transmitted.

Use Case 1: Endless Stream of Objects or Material#

This is the most basic way of using a GigE line scan camera. The camera transmits a continuous stream of image frames. The host computer can combine multiple frames to build a larger image or process each frame on its own.

The objects or the endless material are moved through the camera’s field of view. The camera acquires the first line; afterwards, the object or the material is moved by one line and the camera acquires the next line, and so on.

The following sections describe two variants of use case 1:

  • Use case 1 a: Objects moving at a constant speed
  • Use case 1 b: Endless material moved by rollers at a varying speed

Case 1 a: Objects Moving at a Constant Speed#

When objects are free-falling, e.g., when sorting rice, cotton, or material for recycling, these objects move at a predictable speed and the camera can be set to a fixed line rate. No triggers are necessary to acquire geometrically correct images.

To set the parameters:

  1. Set the frame height to the example value of 3, i.e., 3 lines per frame:
    Set the Height parameter to 3.
  2. Enable the acquisition line rate control:
    Set the AcquisitionLineRateEnable parameter to true.
  3. Slow down the line rate to the desired speed:
    Set the AcquisitionLineRate parameter to 10 kHz.
  4. Enable the Continuous frame mode:
    Set the AcquisitionMode parameter to ContinuousFrame.
    Note: This feature is not available via the pylon Viewer feature tree. Instead, use the Continuous Shot button in the toolbar of the pylon Viewer.

Line Scan Use Case 1a Timing

Case 1 b: Endless Material Moved by Rollers at Variable Speed#

Endless material is often moved by and over rollers. Load changes and vibrations cause the transport speed to vary. This fluctuation in speed can be compensated when a shaft encoder is used to generate a line trigger each time the material moves forward by a certain distance.

In the following example, the shaft encoder signal is connected to input line 2. The shaft encoder is set up to generate one encoder pulse per line.

For further information about how an encoder works, see the Encoder Control feature topic.

To set the parameters:

  1. Set the frame height to the example value of 3, i.e., 3 lines per frame:
    Set the Height parameter to 3.
  2. Enable the line start trigger:
    Set the TriggerSelector parameter to LineStart and the TriggerMode parameter to On.
  3. Set the trigger to act on the rising edge of the trigger signal:
    Set the TriggerActivation parameter to RisingEdge.
  4. Select line 2 as the signal source for the line start trigger:
    Set the TriggerSource parameter to Line2.
  5. Enable the Continuous frame mode:
    Set the AcquisitionMode parameter to ContinuousFrame.
    Note: This feature is not available via the pylon Viewer feature tree. Instead, use the Continuous Shot button in the toolbar of the pylon Viewer.

Line Scan Use Case 1b Timing

Use Case 2: Individual Objects on a Conveyor Belt#

When inspecting objects on a moving conveyor belt, it is often desirable to receive one image per object. This facilitates image processing and avoids the waste of processing resources. In this setup, the system usually provides an object trigger that indicates the arrival of the next object. The object trigger can be generated, e.g., by a light barrier or by a PLC (programmable logic control) unit.

The conveyor belt speed may fluctuate. It is therefore often advisable to use a shaft encoder to synchronize the line trigger to the mechanical movement of the belt. The following examples assume that a line trigger is used.

The following sections describe four variants of use case 2:

  • Use case 2 a: One frame per object
  • Use case 2 b: Multiple frames per object
  • Use case 2 c: Varying number of frames per object
  • Use case 2 d: Variable size of frames per object

Case 2 a: One Frame per Object#

When the objects are small enough so that each fits in one frame, the object trigger can be used as a direct frame trigger.

For information about the maximum number of lines per frame, see the Image ROI topic (info box for line scan cameras).

To set the parameters:

  1. Set the frame height to the example value of 3, i.e., 3 lines per frame:
    Set the Height parameter to 3.
  2. Enable the frame start trigger:
    Set the TriggerSelector parameter to FrameStart and the TriggerMode parameter to On.
  3. Set the trigger to act on the rising edge of the trigger signal:
    Set the TriggerActivation parameter to RisingEdge.
  4. Select line 1 as the signal source for the frame start trigger:
    Set the TriggerSource parameter to Line1.
  5. Enable the line start trigger:
    Set the TriggerSelector parameter to LineStart and the TriggerMode parameter to On.
  6. Set the trigger to act on the rising edge of the trigger signal:
    Set the TriggerActivation parameter to RisingEdge.
  7. Select line 2 as the signal source for the line start trigger:
    Set the TriggerSource parameter to Line2.
  8. Enable the Continuous frame mode:
    Set the AcquisitionMode parameter to ContinuousFrame.
    Note: This feature is not available via the pylon Viewer feature tree. Instead, use the Continuous Shot button in the toolbar of the pylon Viewer.

Line Scan Use Case 2a Timing

Case 2 b: Multiple Frames per Object#

When the objects are too large to fit in one frame, a frame burst trigger can be used to trigger multiple frames for each individual object trigger. The image processing application may combine all frames of a frame burst into one image.

To set the parameters:

  1. Set the frame height to the example value of 3, i.e., 3 lines per frame:
    Set the Height parameter to 3.
  2. Set the number of frames for each frame burst to the example value of 2:
    Set the AcquisitionBurstFrameCount parameter to 2.
  3. Enable the frame burst start trigger:
    Set the TriggerSelector parameter to FrameBurstStart and the TriggerMode parameter to On.
  4. Set the trigger to act on the rising edge of the trigger signal:
    Set the TriggerActivation parameter to RisingEdge.
  5. Select line 1 as the signal source for the line start trigger:
    Set the TriggerSource parameter to Line1.
  6. Enable the line start trigger:
    Set the TriggerSelector parameter to LineStart and the TriggerMode parameter to On.
  7. Set the trigger to act on the rising edge of the trigger signal:
    Set the TriggerActivation parameter to RisingEdge.
  8. Select line 2 as the signal source for the line start trigger:
    Set the TriggerSource parameter to Line2.
  9. Enable the Continuous frame mode:
    Set the AcquisitionMode parameter to ContinuousFrame.
    Note: This feature is not available via the pylon Viewer feature tree. Instead, use the Continuous Shot button in the toolbar of the pylon Viewer.

Line Scan Use Case 2b Timing

Case 2 c: Varying Number of Frames per Object#

When a mix of objects of varying sizes is inspected on the same conveyor belt, the frame start trigger can be used to acquire exactly the required number of frames for each object. The frame trigger signal should be generated by a presence detector, e.g., a light barrier, to ensure the signal is active whenever the object is in the camera’s field of view.

To set the parameters:

  1. Set the frame height to the example value of 3, i.e., 3 lines per frame:
    Set the Height parameter to 3.
  2. Enable the frame start trigger:
    Set the TriggerSelector parameter to FrameStart and the TriggerMode parameter to On.
  3. Set the trigger to act on a high level of the presence detector's output signal:
    Set the TriggerActivation parameter to LevelHigh.
    This results in a sequence of frame triggers issued while the trigger signal is active.
  4. Select line 1 as the signal source for the line start trigger:
    Set the TriggerSource parameter to Line1.
  5. Enable the line start trigger:
    Set the TriggerSelector parameter to LineStart and the TriggerMode parameter to On.
  6. Set the trigger to act on the rising edge of the trigger signal:
    Set the TriggerActivation parameter to RisingEdge.
  7. Select line 2 as the signal source for the line start trigger:
    Set the TriggerSource parameter to Line2.
  8. Enable the Continuous frame mode:
    Set the AcquisitionMode parameter to ContinuousFrame.
    Note: This feature is not available via the pylon Viewer feature tree. Instead, use the Continuous Shot button in the toolbar of the pylon Viewer.

Line Scan Use Case 2c Timing

Case 2 d: Variable Size of Frames per Object#

When the gap between objects on a conveyor belt is smaller than a frame, the frame active trigger can be used to end the frame immediately behind the object. This prepares the camera for the next trigger as quickly as possible and it avoids transmitting unnecessary data.

To set the parameters:

  1. Set the frame height to the example value of 3, i.e., 3 lines per frame:
    Set the Height parameter to 3.
  2. Enable the frame active trigger:
    Set the TriggerSelector parameter to FrameActive and the TriggerMode parameter to On.
  3. Set the trigger to act on a high level of the presence detector's output signal:
    Set the TriggerActivation parameter to LevelHigh.
    This results in a sequence of one or multiple frame triggers issued while the trigger signal is active, but the frame will end immediately with the falling edge of the trigger signal.
  4. Select line 1 as the signal source for the frame active trigger:
    Set the TriggerSource parameter to Line1.
  5. Enable the line start trigger:
    Set the TriggerSelector parameter to LineStart and the TriggerMode parameter to On.
  6. Set the trigger to act on the rising edge of the trigger signal:
    Set the TriggerActivation parameter to RisingEdge.
  7. Select line 2 as the signal source for the line start trigger:
    Set the TriggerSource parameter to Line2.
  8. Enable the Continuous frame mode:
    Set the AcquisitionMode parameter to ContinuousFrame.
    Note: This feature is not available via the pylon Viewer feature tree. Instead, use the Continuous Shot button in the toolbar of the pylon Viewer.

Line Scan Use Case 2d Timing

Use Case 3: Using the Chunk Mode for Identifying Frames#

When a camera is configured to acquire a variable number of frames per object as described for use cases 2 b or 2 d, it is not clear for the application where objects begin and end. The Data Chunks feature, in combination with the Counter feature, can be used to tag frames as belonging to the same object trigger, thus making it unnecessary to spend processing power on grouping frames together.

The following use case is an example of how to configure the counters and the data chunks for use case 2 c. The counters can be used individually or together.

To set the parameters:

  1. Set the first counter to increment after each incoming frame start trigger:
    1. Set the CounterSelector parameter to Counter1.
    2. Set the CounterEventSource parameter to Line2 to select the frame trigger signal for line 2 as the signal source for the counter event (i.e. for incrementing).
    3. Set the CounterEventActivation parameter to FallingEdge to select the end of the active frame trigger signal to increment the counter.
  2. Set the second counter to count the number of frames while the frame trigger is continuously active:
    1. CounterSelectorパラメーターをCounter2に設定します。
    2. Set the CounterTriggerSource parameter to Line2 and the CounterTriggerActivation parameter to LevelHigh to set the counter to count only while line 2 is active.
    3. Set the CounterEventSource parameter to FrameActive and the CounterEventActivation parameter to FallingEdge to set the counter to increment at the end of each frame.
    4. Set the CounterResetSource parameter to Line2 and the CounterResetActivation parameter to Falling Edge to set the counter to be reset when line 2 becomes inactive.
  3. Activate the transmission of counter values:
    1. ChunkModeActiveパラメーターをtrueに設定します。
    2. Set the ChunkSelector parameter to CounterValue.
    3. Set the ChunkEnable parameter to true to enable the selected chunk.

Line Scan Use Case 3 Timing