Skip to main content

Encapsulation Class

NuGet: GHIElectronics.TinyCLR.EthernetIP.Scanner
Assembly: GHIElectronics.TinyCLR.EthernetIP.Scanner
Namespace: GHIElectronics.TinyCLR.EthernetIP.Scanner

Represents an EtherNet/IP encapsulation packet header plus its command-specific data.

public class Encapsulation

Properties​

Command​

public CommandsEnum Command { get; set; }

The encapsulation command for this packet.

Length​

public ushort Length { get; set; }

The byte length of the command-specific data that follows the header.

SessionHandle​

public uint SessionHandle { get; set; }

The session handle assigned by the target after RegisterSession.

Status​

public StatusEnum Status { get; }

The encapsulation status returned by the target.

Methods​

ArrayList()​

public ArrayList CommandSpecificData = new ArrayList()

The command-specific data bytes appended after the 24-byte header.

Returns ArrayList CommandSpecificData = new

Tobytes()​

public byte[] Tobytes()

Serializes this encapsulation packet (24-byte header plus command-specific data) to a byte array.

Returns byte[]