CogEthernetPortAccess GetActiveEthernetPort Method Cognex VisionPro
Returns a reference to a currently active Ethernet port object held by the Comm Card, or null if no currently active Ethernet port object exists for the given index.

An active Ethernet port will only exist if CreateEthernetPort(Int32) has been called previously.

Namespace: Cognex.VisionPro.Comm
Assembly: Cognex.VisionPro.Comm (in Cognex.VisionPro.Comm.dll) Version: 65.1.0.0
Syntax

public virtual CogEthernetPort GetActiveEthernetPort(
	int index
)

Return Value

Type: CogEthernetPort
Exceptions

ExceptionCondition
CogHardwareInUseException Thrown if the hardware is in use by another process. Only a single process may access the hardware. When this exception is thrown, you must close any other processes that are using the hardware, and re-start this process in order to access the hardware.
CogIncompatibleFirmwareException Thrown if the version of the Comm Card firmware is incompatible with the version of the host library. Run "%VPRO_ROOT%\bin\fwuphost.exe --pkg vm56_firmware_X_X_X_X.pkg" to upgrade firmware."
See Also