コンテンツにスキップ

トランスポート層のパラメーター#

pylon APIで、「トランスポート層」という用語は、GigEやCamera Linkなどの物理インターフェースを表すために使用されます。

pylon APIは、複数の異なるトランスポート層へのアクセスを提供します。

  • PylonGigE(GigE Visionプロトコルを使用したGigabit Ethernetカメラ用)
  • PylonUsb(USB3 Visionに準拠したカメラ用)
  • PylonCLSer(CLシリアルインターフェースを使用したCamera Linkカメラ用。カメラ設定のみに限定。LinuxおよびmacOSプラットフォームでは使用不可)

この項では、トランスポート層に関連するパラメーターについて説明します。

General Parameters#

Command Duplication Enable#

Use the CommandDuplicationEnable parameter to enable sending all commands and receiving all acknowledges twice. This option should only be enabled in case of network problems.

Heartbeat Timeout#

The HeartbeatTimeout parameter specifies the heartbeat timeout on the host side.

This parameter is the equivalent of the GevHeartbeatTimeout parameter, which sets the heartbeat timeout on the camera side.

The HeartbeatTimeout and GevHeartbeatTimeout parameters are synchronized automatically. If you change one parameter, the other one changes accordingly.

Maximum Retry Count Read#

Use the MaxRetryCountRead parameter to specify the maximum number of retries for read operations after a read operation has timed out.

Maximum Retry Count Write#

Use the MaxRetryCountWrite parameter to specify the maximum number of retries for write operations after a read operation has timed out.

Migration Mode Enable#

Use the MigrationModeEnable parameter to enable mapping of certain SFNC 1.x node names to SFNC 2.x node names. This allows you to write code for camera devices that are compatible with different SFNC (Standard Features Naming Convention) versions.

詳細については、「pylon APIドキュメント」の「SFNC 2.xベースのカメラデバイスを使用するための既存コードの移行」セクションを参照してください。

Read Timeout#

Use the ReadTimeout parameter to specify the read access timeout value in milliseconds.

GigE Vision Control Protocolコマンドの実行に予想以上の時間がかかる場合、この値を調整すると有効なことがあります。

書き込みタイムアウト#

Use the WriteTimeout parameter to specify the write access timeout value in milliseconds.

GigE Vision Control Protocolコマンドの実行に予想以上の時間がかかる場合、この値を調整すると有効なことがあります。

統計パラメーター#

Last Error Status#

The Statistic_Last_Error_Status parameter indicates the last error status for a read or write operation.

Last Error Status Text#

The Statistic_Last_Error_Status_Text parameter indicates the status code of the last failed buffer.

Read Operations Failed Count#

The Statistic_Read_Operations_Failed_Count parameter counts the number of failed read operations.

Read Pipe Reset Count#

The Statistic_Read_Pipe_Reset_Count parameter counts the number of read pipe resets.

Read Write Timeout Count#

The StatisticReadWriteTimeoutCount parameter counts the number of timeouts during read and write operations when waiting for a response from the device.

書き込み操作失敗回数#

The Statistic_Write_Operations_Failed_Count parameter counts the number of failed write operations.

パイプリセットカウントの書き込み#

The Statistic_Write_Pipe_Reset_Count parameter counts the number of write pipe resets.

サンプルコード#

// ** General Parameters **
// Command Duplication Enable
camera.GetTLParams().CommandDuplicationEnable.SetValue(true);
// Heartbeat Timeout
camera.GetTLParams().HeartbeatTimeout.SetValue(3000);
// Maximum Retry Count Read
camera.GetTLParams().MaxRetryCountRead.SetValue(2);
// Maximum Retry Count Write
camera.GetTLParams().MaxRetryCountWrite.SetValue(2);
// Migration Mode Enable
camera.GetTLParams().MigrationModeEnable.SetValue(true);
// Read Timeout
camera.GetTLParams().ReadTimeout.SetValue(500);
// Write Timeout
camera.GetTLParams().WriteTimeout.SetValue(500);
// ** Statistics Parameters **
// Last Error Status
int64_t lastErrorStatus = camera.GetTLParams().Statistic_Last_Error_Status.GetValue();
// Last Error Status Text
GenICam::gcstring lastErrorStatusText = camera.GetTLParams().Statistic_Last_Error_Status_Text.GetValue();
// Read Operations Failed Count
int64_t readOperationsFailedCount = camera.GetTLParams().Statistic_Read_Operations_Failed_Count.GetValue();
// Read Pipe Reset Count
int64_t readPipeResetCount = camera.GetTLParams().Statistic_Read_Pipe_Reset_Count.GetValue();
// Read Write Timeout Count
int64_t writePipeResetCount = camera.GetTLParams().StatisticReadWriteTimeoutCount.GetValue();
// Write Operations Failed Count
int64_t writeOperationsFailedCount = camera.GetTLParams().Statistic_Write_Operations_Failed_Count.GetValue();
// Write Pipe Reset Count
int64_t writePipeResetCount = camera.GetTLParams().Statistic_Write_Pipe_Reset_Count.GetValue();
// ** General Parameters **
// Command Duplication Enable
camera.Parameters[PLTransportLayer.CommandDuplicationEnable].SetValue(true);
// Heartbeat Timeout
camera.Parameters[PLTransportLayer.HeartbeatTimeout].SetValue(3000);
// Maximum Retry Count Read
camera.Parameters[PLTransportLayer.MaxRetryCountRead].SetValue(2);
// Maximum Retry Count Write
camera.Parameters[PLTransportLayer.MaxRetryCountWrite].SetValue(2);
// Migration Mode Enable
camera.Parameters[PLTransportLayer.MigrationModeEnable].SetValue(true);
// Read Timeout
camera.Parameters[PLTransportLayer.ReadTimeout].SetValue(500);
// Write Timeout
camera.Parameters[PLTransportLayer.WriteTimeout].SetValue(500);
// ** Statistics Parameters **
// Last Error Status
Int64 lastErrorStatus = camera.Parameters[PLTransportLayer.Statistic_Last_Error_Status].GetValue();
// Last Error Status Text
string lastErrorStatusText = camera.Parameters[PLTransportLayer.Statistic_Last_Error_Status_Text].GetValue();
// Read Operations Failed Count
Int64 readOperationsFailedCount = camera.Parameters[PLTransportLayer.Statistic_Read_Operations_Failed_Count].GetValue();
// Read Pipe Reset Count
Int64 readPipeResetCount = camera.Parameters[PLTransportLayer.Statistic_Read_Pipe_Reset_Count].GetValue();
// Read Write Timeout Count
Int64 writePipeResetCount = camera.Parameters[PLTransportLayer.StatisticReadWriteTimeoutCount].GetValue();
// Write Operations Failed Count
Int64 writeOperationsFailedCount = camera.Parameters[PLTransportLayer.Statistic_Write_Operations_Failed_Count].GetValue();
// Write Pipe Reset Count
Int64 writePipeResetCount = camera.Parameters[PLTransportLayer.Statistic_Write_Pipe_Reset_Count].GetValue();

pylon Viewerを使用して、パラメーターを簡単に設定することもできます。