EEIP .NET – Methods

Namespace: Sres.Net.EEIP
Class: EEIPClient


public List<Encapsulation.CIPIdentityItem> ListIdentity()

List and identify potential targets. This command shall be sent as braodcast message using UDP.


public UInt32 RegisterSession(UInt32 address, UInt16 port)

Sends a RegisterSession command to a target to initiate session
Returns the Session Handle

Input Parameters:
address: IP-Address of the target device
port: Port of the target device (default should be 0xAF12)


public UInt32 RegisterSession(string address, UInt16 port)

Sends a RegisterSession command to a target to initiate session
Returns the Session Handle

Input Parameters:
address: IP-Address of the target device
port: Port of the target device (default should be 0xAF12)


public UInt32 RegisterSession(string address)

Sends a RegisterSession command to a target to initiate session using the predefines port (default 0xAF12)
Returns the Session Handle

Input Parameters:
address: IP-Address of the target device


public UInt32 RegisterSession()

Sends a RegisterSession command to a target to initiate session with the Standard or predefined Port and Predefined IPAddress (Standard-Port: 0xAF12)
Returns the Session Handle


public void UnRegisterSession()

Sends a UnRegisterSession command to a target to terminate session


public void ForwardOpen()

Initiates an Implicit Messaging


 

public void ForwardClose()
Teminated Implicit Messaging


public byte[] getAttributeSingle(int classID, int instanceID, int attributeID)

Reads an attribute from the target device.
Returns the data of the attribute
Input Parameters:
classdID, instanceID and attributeID: Access Path of the attribute


public byte[] GetAttributesAll(int classID, int instanceID)

Implementation of Common Service “Get_Attribute_All” – Service Code: 0x01
Returns the data of the attribute
classID: Class id of requested Attributes
instanceID: Instance of Requested Attributes (0 for class Attributes)


public byte[] SetAttributeSingle(int classID, int instanceID, int attributeID, byte[] value)

Sets the value of an Attribute
returns the data of the attribute
classID: Class id of requested Attribute
instanceID: Instance of Requested Attribute
attributeID: Attribute to write


public byte[] GetAttributesAll(int classID)

Implementation of Common Service “Get_Attribute_All” Reads the Class Attributes – Service Code: 0x01
Returns the data of the attribute
classID: Class id of requested Attributes


public static uint ToUint(byte[] byteArray)

Converts a bytearray (received e.g. via getAttributeSingle) to uint


public static bool ToBool(byte inputByte, int bitposition)

Returns the “Bool” State of a byte Received via getAttributeSingle


public static ushort ToUshort(byte[] byteArray)

Converts a bytearray (received e.g. via getAttributeSingle) to ushort