Operator Library: Hardware Platform
此 operator 會為相機產生觸發訊號 (Exsync)。 它也負責將擷取到的行組合成影像。
您可以使用內部訊號產生器 (GrabberControlled),或是透過外部訊號來觸發訊號產生器, 這些外部訊號可以來自觸發擴充板(TTL Trigger board 或 OPTO Trigger board)的輸入訊號,或是透過軟體觸發。 訊號產生器可以產生具備彈性延遲、脈衝寬度和極性的 Exsync 訊號。 此外,還會產生一個可在觸發擴充板上使用的閃光訊號。
此 operator 會佔用 4 個數位輸出以及一個用於 CC 訊號的相機連接埠。 因此,會使用一個類型為 CameraControl 的 VisualApplets 資源。 若資源索引設為 0,則會使用數位輸出 0 至 2 以及相機連接埠 A。 若資源索引設為 1,則會使用數位輸出 4 至 6 以及相機連接埠 B。 輸出 3 和 7 不會被此 operator 使用。 請注意,其他 operator 無法使用這些硬體資源。 請在資源對話方塊中設定資源索引。
| 適用於硬體平台 |
|---|
| microEnable IV VD1-CL/-PoCL |
| microEnable IV VD4-CL/-PoCL |
| Link Parameter | Input Link I | Output Link O |
|---|---|---|
| Bit Width | [1, 64] | as I |
| Arithmetic | {unsigned, signed} | as I |
| Parallelism | any | as I |
| Kernel Columns | 1 | as I |
| Kernel Rows | 1 | as I |
| Img Protocol | VALT_LINE1D | VALT_IMAGE2D |
| Color Format | any | as I |
| Color Flavor | any | as I |
| Max. Img Width | any | as I |
| Max. Img Height | 65536 | as I |
| YOffset | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | 0 |
| Range | [0, 224] |
|
此參數定義了在畫格開頭處略過的行數。 |
|
| YLength | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | 1024 |
| Range | [8, 224] |
|
此參數定義了畫格的行數。 |
|
| MaxGatedHeight | ||||
|---|---|---|---|---|
| Type | 動態讀取/寫入參數 | |||
| Default | restricted | |||
| Range | {restricted, unrestricted} | |||
|
當影像觸發模式 (ImgTriggerMode) 設為 ExternSw_Gate 時,參數 MaxGatedHeight 可讓您限制最大影像高度。 如果影像觸發模式 (ImgTriggerMode) 設為 ExternSw_Gate, 且參數 MaxGatedHeight 設為 unrestricted(不受限制), 則影像高度由閘道開啟的時間決定,亦即 由外部影像觸發訊號的脈衝寬度或軟體觸發值為 1 的持續時間決定。 因此,如果閘道開啟時間很長,影像高度就會變大。 如果參數 MaxGatedHeight 設為 restricted(受限制),即使閘道仍然開啟, 影像高度也會被限制為 YLength 影像行。 Operator 將會捨棄任何後續的行,並等待下一個開啟的閘道來開始新的畫格。 相較之下,如果參數設為 unrestricted,影像高度僅由閘道決定。
|
||||
| LineTriggerMode | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | GrabberControlled |
| Range | {GrabberControlled, Extern_Trigger, GrabberControlled_Gated_by_Img, Extern_Trigger_Gated_by_Img} |
|
此參數可選擇內部 Exsync 訊號產生器的作業模式。 外部觸發輸入的來源可透過參數 LineTrgInSourceA 和 LineTrgInSourceB 進行選擇(請參閱下方)。 GrabberControlled:由內部訊號產生器週期性地產生 Exsync Extern_Trigger:使用外部觸發訊號來啟動訊號產生器一次 GrabberControlled_Gated_by_Img:在擷取畫格期間,由內部訊號產生器週期性地產生 Exsync Extern_Trigger_Gated_by_Img:在擷取畫格期間,使用外部觸發訊號來觸發訊號產生器 |
|
| ExsyncEnable | |
|---|---|
| Type | 動態讀取/寫入參數 |
| Default | OFF |
| Range | {OFF, ON} |
|
啟用或停用傳送至相機的 Exsync 輸出。 |
|
| LineTrgInSourceA | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | InSignal0 |
| Range | {InSignal0, InSignal1, InSignal2, InSignal3, InSignal4, InSignal5, InSignal6, InSignal7} |
|
此參數指定用於觸發 Exsync 訊號產生器的訊號來源。 這僅在 TriggerMode 設為 Extern_Trigger 時才有作用。 |
|
| LineTrgInSourceB | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | InSignal0 |
| Range | {InSignal0, InSignal1, InSignal2, InSignal3, InSignal4, InSignal5, InSignal6, InSignal7} |
|
此參數指定用於觸發 Exsync 訊號產生器的訊號來源。 這僅在 TriggerMode 設為 Extern_Trigger 且 EncoderABMode 設為 Signal_AB_Filter 時才有作用。 |
|
| EncoderABMode | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | Signal_A_Only |
| Range | {Signal_A_Only, Signal_AB_Filter, Signal_ABx2_Filter, Signal_ABx4_Filter} |
|
此參數指定是用單一觸發輸入(僅 A)還是同時使用 A 和 B 訊號來產生 Exsync。 ![]() 訊號 A/B 支援可用於判斷軸encoder(旋轉編碼器)的旋轉方向,並抑制與補償反向移動: ![]()
![]() Signal_A_Only:使用由 LineTrgInSourceA 所選取的觸發輸入來產生 Exsync。 Signal_AB_Filter:針對軸encoder(旋轉編碼器)的正向旋轉以單倍解析度產生 Exsync,亦即 針對 LineTrgInSourceA 的上升緣產生一個觸發脈衝。 Signal_ABx2_Filter:針對軸encoder(旋轉編碼器)的正向旋轉以雙倍解析度產生 Exsync,亦即 針對 LineTrgInSourceA 的上升緣和下降緣產生觸發脈衝。會使用 LineTrgInSourceA 的兩個邊緣。 Signal_ABx4_Filter:針對軸encoder(旋轉編碼器)的正向旋轉以四倍解析度產生 Exsync,亦即 針對 LineTrgInSourceA 的上升緣與下降緣,以及 LineTrgInSourceB 的上升緣與下降緣產生觸發脈衝。 啟用 AB 支援時的相關 Property:
您可以透過將 EncoderABMode Property 設定為 Signal_A_Only 值來重設旋轉編碼器。 |
|
| EncoderABLead | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | Signal_AB |
| Range | {Signal_AB, Signal_BA} |
|
如果將 Property 設定為 Signal_AB,則正向運動定義為信號 A 在信號 B 之前出現上升緣,反之亦然: Signal_AB: 正向定義為 A 超前於 B Signal_BA:正向定義為 B 在 A 之前 |
|
| LineTrgInPolarity | |
|---|---|
| Type | 動態讀取/寫入參數 |
| Default | LowActive |
| Range | {LowActive, HighActive} |
|
此 Property 定義外部輸入 Trigger Mode 信號 LineTrgInSourceA 和 LineTrgInSourceB 的極性。設定為 LowActive 時,Exsync 產生器會在由 ImgTrgInSource Property 指定的信號之下降緣上啟動。否則,Exsync 產生會在上升緣啟動。這僅在 Trigger Mode 設定為 Extern_Trigger 時才有意義。 |
|
| LineTrgDownscaler | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | 1 |
| Range | [1, 256] |
|
此 Property 指定產生 Exsync 所需的外部輸入 Trigger Mode 信號數量。這僅在 Trigger Mode 設定為外部 Trigger Mode 時才有意義。 |
|
| LineTrgPhase | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | 1 |
| Range | [1, 256] |
|
此 Property 指定產生影格的第一個 Exsync 所需的外部輸入 Trigger Mode 信號數量。這僅在 Trigger Mode 設定為 Extern_Trigger_Gated_by_Img 時才有意義。 |
|
| ExsyncPeriod | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | 100 µs |
| Range | [1.024, 4000] μs |
|
此 Property 指定 Exsync 信號的週期。因此,在使用擷取卡控制模式來觸發所連接的相機時,它會定義行頻。 |
|
| ExsyncExposure | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | 20 µs |
| Range | [1.024, 2000] μs,不得超過 ExsyncPeriod |
|
此 Property 指定 Exsync 信號的脈衝寬度,許多相機都可以使用此脈衝寬度來指定 Exposure Time。因此,即使在擷取過程中,也可以透過軟體調整 Exposure Time。 |
|
| Exsync2Delay | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | 0 μs |
| Range | [0, 2000] μs,不得超過 ExsyncPeriod |
|
此 Property 指定產生的 Exsync 信號相對於外部 Trigger Mode 輸入的延遲。因此,Exsync2 信號是 Exsync 的延遲複製版本(極性、週期等與 Exsync 相同)。 |
|
| ExsyncPolarity | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | LowActive |
| Range | {LowActive, HighActive} |
|
此 Property 會將 Exsync 信號產生器的極性調整為所連接相機接受的極性。如果相機在下降緣開啟快門,請使用 LowActive,否則使用 HighActive。 |
|
| ImgTriggerMode | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | FreeRun |
| Range | {FreeRun, ExternSw_Trigger, ExternSw_Gate} |
|
此參數選擇內部 Image Gate 的運作模式。 圖像觸發輸入信號可由外部(周邊)設備(例如旋轉編碼器)或軟體建立。 您可透過 ImgTrgInSource Property 選擇外部圖像觸發輸入的來源,請見下方)。 The values of parameter ImgTriggerMode induce the following behaviour:
|
|
| ImgTrgInSource | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | InSignal0 |
| Range | {InSignal0, InSignal1, InSignal2, InSignal3, InSignal4, InSignal5, InSignal6, InSignal7} |
|
此參數指定用於觸發影像擷取的訊號來源。這僅在 ImgTriggerMode 設定為 ExternSw_Trigger 或 ExternSw_Gate 時才有意義。 |
|
| ImgTrgInPolarity | |
|---|---|
| Type | 動態讀取/寫入參數 |
| Default | LowActive |
| Range | {LowActive, HighActive} |
|
此參數定義外部輸入觸發訊號的極性。 |
|
| ImgTrgDelay | |
|---|---|
| Type | 動態讀取/寫入參數 |
| Default | 0 |
| Range | {0, 4095} |
|
此參數會將影像觸發訊號延遲指定的影像行數。 |
|
| FlashEnable | |
|---|---|
| Type | 動態讀取/寫入參數 |
| Default | OFF |
| Range | {OFF, ON} |
|
啟用或停用閃光燈輸出。 閃光燈訊號的脈衝寬度等於一個行週期。 |
|
| FlashPolarity | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | LowActive |
| Range | {LowActive, HighActive} |
|
此參數定義所產生的 Flash 信號的極性。 |
|
| FlashDelay | |
|---|---|
| Type | dynamic/static read/write parameter |
| Default | 0 |
| Range | {0, 4095} |
|
此參數指定相對於外部觸發輸入,所產生的閃光燈訊號要延遲的行數。 因此,可以將閃光燈與外部觸發輸入進行同步。 閃光訊號的脈衝寬度等於一個行週期。 |
|
| SoftwareTrgPulse | |
|---|---|
| Type | 動態/靜態寫入參數 |
| Default | |
| Range | {1} |
|
將此參數設定為 1 將會產生軟體觸發。這僅在 Trigger Mode 設定為外部觸發模式且 ImgTrgInSource 設定為 SoftwareTrigger 時才有效。 |
|
| SoftwareTrgInput | |
|---|---|
| Type | 動態/靜態寫入參數 |
| Default | |
| Range | {0, 1} |
|
使用此參數可以為圖像觸發模式 ExternSw_Gate 產生軟體閘道。 |
|
| ImgTrgIsBusy | |
|---|---|
| Type | 動態/靜態讀取 Property |
| Default | 0 |
| Range | {0, 1} |
|
ImgTrgIsBusy 參數允許透過軟體讀取圖像觸發的忙碌狀態。 如果處於忙碌狀態,此參數會設為 1 以反映正在進行的圖像擷取。 如果設為 0,則運算子未處於忙碌狀態。 |
|
| CC1output | |
|---|---|
| Type | 動態/靜態寫入參數 |
| Default | Exsync |
| Range | {Exsync, ExsyncInvert, Hdsync, HdsyncInvert, Flash, FlashInvert, Gnd, Vcc} |
|
此 Property 指定 CameraLink 連接線之 CC1 線路上可用的訊號。 |
|
| CC2output | |
|---|---|
| Type | 動態/靜態寫入參數 |
| Default | Exsync |
| Range | {Exsync, ExsyncInvert, Hdsync, HdsyncInvert, Flash, FlashInvert, Gnd, Vcc} |
|
此 Property 指定 CameraLink 連接線之 CC2 線路上可用的訊號。 |
|
| CC3output | |
|---|---|
| Type | 動態/靜態寫入參數 |
| Default | Exsync |
| Range | {Exsync, ExsyncInvert, Hdsync, HdsyncInvert, Flash, FlashInvert, Gnd, Vcc} |
|
此 Property 指定 CameraLink 連接線之 CC3 線路上可用的訊號。 |
|
| CC4output | |
|---|---|
| Type | 動態/靜態寫入參數 |
| Default | Exsync |
| Range | {Exsync, ExsyncInvert, Hdsync, HdsyncInvert, Flash, FlashInvert, Gnd, Vcc} |
|
此 Property 指定 CameraLink 連接線之 CC4 線路上可用的訊號。 |
|
| ImgTrgDebouncingMaxTime | |
|---|---|
| Type | 靜態寫入參數 |
| Default | 65.520 us |
| Range | [0.016, 1000000] us |
|
此參數指定 ImgTrgDebouncingTime 參數的最大時間。最大時間越小,實作去彈跳 Timer 所需的 FPGA 資源就越少。 |
|
| ImgTrgDebouncingTime | |
|---|---|
| Type | 動態/靜態寫入參數 |
| Default | 0.112 us |
| Range | [0.016, ImgTrgDebouncingMaxTime] us |
|
此參數指定輸入圖像觸發訊號必須保持相同值才能被偵測為觸發訊號的去彈跳時間。去彈跳時間內的快速訊號變更將被過濾掉。 |
|
| LineTrgDebouncingMaxTime | |
|---|---|
| Type | 靜態寫入參數 |
| Default | 65.520 us |
| Range | [0.016, 1000000] us |
|
此參數指定 LineTrgDebouncingTime 參數的最大時間。最大時間越小,實作去彈跳 Timer 所需的 FPGA 資源就越少。 |
|
| LineTrgDebouncingTime | |
|---|---|
| Type | 動態/靜態寫入參數 |
| Default | 0.112 us |
| Range | [0.016, ImgTrgDebouncingMaxTime] us |
|
此參數指定輸入行觸發訊號必須保持相同值才能被偵測為觸發訊號的去彈跳時間。去彈跳時間內的快速訊號變更將被過濾掉。 |
|
以下範例顯示了 TrgPortLine 運算子的使用方式:
-
了解運算子的裝置資源配置。
-
'Camera Link Line Scan Cameras '
Examples - Basic Acquisition
-
'Filter for Line Scan Cameras'
範例 - 解釋如何為線陣相機實作濾波器。

![[警告]](../common/images/admon/warning.png)








上一頁

