TcAdsClient Methods

The TcAdsClient type exposes the following members.

Methods

 

Name

Description

TcAdsClient Methods 1:

AddDeviceNotification(String, AdsStream, AdsTransMode, Int32, Int32, Object)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 2:

AddDeviceNotification(String, AdsStream, AdsTransMode, TimeSpan, TimeSpan, Object)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 3:

TcAdsClient Methods 4:

AddDeviceNotification(UInt32, UInt32, AdsStream, AdsTransMode, Int32, Int32, Object)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 5:

TcAdsClient Methods 6:

AddDeviceNotification(UInt32, UInt32, AdsStream, AdsTransMode, TimeSpan, TimeSpan, Object)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 7:

AddDeviceNotification(String, AdsStream, Int32, Int32, AdsTransMode, Int32, Int32, Object)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 8:

AddDeviceNotification(String, AdsStream, Int32, Int32, AdsTransMode, TimeSpan, TimeSpan, Object)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 9:

TcAdsClient Methods 10:

AddDeviceNotification(UInt32, UInt32, AdsStream, Int32, Int32, AdsTransMode, Int32, Int32, Object)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 11:

TcAdsClient Methods 12:

AddDeviceNotification(UInt32, UInt32, AdsStream, Int32, Int32, AdsTransMode, TimeSpan, TimeSpan, Object)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 13:

TcAdsClient Methods 14:

AddDeviceNotificationEx(String, AdsTransMode, Int32, Int32, Object, Type)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 15:

TcAdsClient Methods 16:

AddDeviceNotificationEx(String, AdsTransMode, TimeSpan, TimeSpan, Object, Type)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 17:

TcAdsClient Methods 18:

AddDeviceNotificationEx(String, AdsTransMode, Int32, Int32, Object, Type, .Int32.)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 19:

TcAdsClient Methods 20:

AddDeviceNotificationEx(String, AdsTransMode, TimeSpan, TimeSpan, Object, Type, .Int32.)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 21:

TcAdsClient Methods 22:

AddDeviceNotificationEx(UInt32, UInt32, AdsTransMode, Int32, Int32, Object, Type)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 23:

TcAdsClient Methods 24:

AddDeviceNotificationEx(UInt32, UInt32, AdsTransMode, TimeSpan, TimeSpan, Object, Type)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 25:

TcAdsClient Methods 26:

AddDeviceNotificationEx(UInt32, UInt32, AdsTransMode, Int32, Int32, Object, Type, .Int32.)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event. If type is a string type, the first element of the parameter args specifies the number of characters of the string. If type is an array type, the number of elements for each dimension has to be specified in the parameter args. At the moment only 1 dimensional Arrays are supported.

TcAdsClient Methods 27:

AddDeviceNotificationEx(UInt32, UInt32, AdsTransMode, TimeSpan, TimeSpan, Object, Type, .Int32.)

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event. If type is a string type, the first element of the parameter args specifies the number of characters of the string. If type is an array type, the number of elements for each dimension has to be specified in the parameter args. At the moment only 1 dimensional Arrays are supported.

TcAdsClient Methods 28:

Close

Closes this IConnection

TcAdsClient Methods 29:

Connect(Int32)

Establishes a connection to a ADS device using the local netID.

TcAdsClient Methods 30:

Connect(AmsAddress)

Establishes a connection to a ADS device.

TcAdsClient Methods 31:

Connect(.Byte., Int32)

Establishes a connection to a ADS device.

TcAdsClient Methods 32:

Connect(String, Int32)

Establishes a connection to a ADS device.

TcAdsClient Methods 33:

Connect(AmsNetId, Int32)

Establishes a connection to a ADS device.

TcAdsClient Methods 34:

Connect(AmsNetId, AmsPort)

Establishes a connection to a ADS device.

TcAdsClient Methods 35:

TcAdsClient Methods 36:

CreateSymbolInfoLoader

Obsolete.

Creates a new instance of the TcAdsSymbolInfoLoader class (Symbol Browser V1, obsolete).

TcAdsClient Methods 37:

CreateVariableHandle

Generates a unique handle for an ADS variable.

TcAdsClient Methods 38:

TcAdsClient Methods 39:

DeleteDeviceNotification

Deletes an existing notification.

TcAdsClient Methods 40:

DeleteVariableHandle

Releases the handle of a ADS variable again.

TcAdsClient Methods 41:

Disconnect

Disconnects the TcAdsClient

TcAdsClient Methods 42:

Dispose.

Releases the resources used by TcAdsClient.

TcAdsClient Methods 43:

Dispose(Boolean)

Disposes the TcAdsClient.

TcAdsClient Methods 44:

Equals

Determines whether the specified object is equal to the current object. (Inherited from Object.)

TcAdsClient Methods 45:

Finalize

Finalizes an instance of the TcAdsClient class. (Overrides Object.Finalize..)

TcAdsClient Methods 46:

GetHashCode

Serves as the default hash function. (Inherited from Object.)

TcAdsClient Methods 47:

GetType

Gets the Type of the current instance. (Inherited from Object.)

TcAdsClient Methods 48:

TcAdsClient Methods 49:

InvokeRpcMethod(String, Int32, .Object.)

Invokes the specified RPC Method

TcAdsClient Methods 50:

TcAdsClient Methods 51:

InvokeRpcMethod(String, String, .Object.)

Invokes the RPC method.

TcAdsClient Methods 52:

TcAdsClient Methods 53:

InvokeRpcMethod(ITcAdsSymbol, Int32, .Object.)

Invokes the specified RPC Method

TcAdsClient Methods 54:

InvokeRpcMethod(ITcAdsSymbol, String, .Object.)

Invokes the RPC method.

TcAdsClient Methods 55:

MemberwiseClone

Creates a shallow copy of the current Object. (Inherited from Object.)

TcAdsClient Methods 56:

OnBeforeDisconnect

Called when before the TcAdsClient is disconnected.

TcAdsClient Methods 57:

OnConnectionStateChanged

Called when the ConnectionState of the TcAdsClient has changed.

TcAdsClient Methods 58:

Read(Int32, AdsStream)

Reads data synchronously from an ADS device and writes it to the given stream.

TcAdsClient Methods 59:

Read(UInt32, UInt32, AdsStream)

Reads data synchronously from an ADS device and writes it to the given stream.

TcAdsClient Methods 60:

Read(Int32, AdsStream, Int32, Int32)

Reads data synchronously from an ADS device and writes it to the given stream.

TcAdsClient Methods 61:

Read(UInt32, UInt32, .Byte., Int32, Int32)

Reads data synchronously from an ADS device and writes it to the given stream.

TcAdsClient Methods 62:

Read(UInt32, UInt32, AdsStream, Int32, Int32)

Reads data synchronously from an ADS device and writes it to the given stream.

TcAdsClient Methods 63:

ReadAny(Int32, Type)

Reads data synchronously from an ADS device and writes it to an object.

TcAdsClient Methods 64:

ReadAny(Int32, Type, .Int32.)

Reads data synchronously from an ADS device and writes it to an object.

TcAdsClient Methods 65:

TcAdsClient Methods 66:

ReadAny(UInt32, UInt32, Type)

Reads data synchronously from an ADS device and writes it to an object.

TcAdsClient Methods 67:

ReadAny(UInt32, UInt32, Type, .Int32.)

Reads data synchronously from an ADS device and writes it to an object.

TcAdsClient Methods 68:

TcAdsClient Methods 69:

ReadAnyString(Int32, Int32, Encoding)

Reads the string.

TcAdsClient Methods 70:

TcAdsClient Methods 71:

ReadAnyString(UInt32, UInt32, Int32, Encoding)

Reads the string

TcAdsClient Methods 72:

ReadDeviceInfo

Reads the identification and version number of an ADS server.

TcAdsClient Methods 73:

ReadState

Reads the ADS status and the device status from an ADS server.

TcAdsClient Methods 74:

ReadSymbol(ITcAdsSymbol)

Reads the value of a symbol and returns it as an object. Strings and all primitive datatypes(UInt32, Int32, Bool etc.) are supported. Arrays and structures cannot be read.

TcAdsClient Methods 75:

ReadSymbol(String, Type, Boolean)

Reads the value of a symbol and returns the value as object. The parameter type must have the same layout as the ADS symbol.

TcAdsClient Methods 76:

ReadSymbolInfo

Call this method to obtain information about the individual symbols (variables) in ADS devices.

TcAdsClient Methods 77:

ReadWrite(UInt32, UInt32, AdsStream, AdsStream)

Writes data synchronously to an ADS device and then Reads data from this device.

TcAdsClient Methods 78:

ReadWrite(Int32, AdsStream, Int32, Int32, AdsStream, Int32, Int32)

Writes data synchronously to an ADS device and then Reads data from this device.

TcAdsClient Methods 79:

ReadWrite(UInt32, UInt32, .Byte., Int32, Int32, .Byte., Int32, Int32)

Writes data synchronously to an ADS device and then Reads data from this device.

TcAdsClient Methods 80:

ReadWrite(UInt32, UInt32, AdsStream, Int32, Int32, AdsStream, Int32, Int32)

Writes data synchronously to an ADS device and then Reads data from this device.

TcAdsClient Methods 81:

ToString

Returns a string that represents the current object. (Inherited from Object.)

TcAdsClient Methods 82:

TryAddDeviceNotification

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 83:

TryAddDeviceNotificationEx

Connects a variable to the ADS client. The ADS client will be notified by the AdsNotification event.

TcAdsClient Methods 84:

TryDeleteDeviceNotification

Deletes an existing notification.

TcAdsClient Methods 85:

TryInvokeRpcMethod(String, Int32, .Object., Object.)

Invokes the specified RPC Method

TcAdsClient Methods 86:

TryInvokeRpcMethod(String, String, .Object., Object.)

Tries to invoke the RPC method.

TcAdsClient Methods 87:

TryInvokeRpcMethod(ITcAdsSymbol, Int32, .Object., Object.)

Invokes the specified RPC Method

TcAdsClient Methods 88:

TryInvokeRpcMethod(ITcAdsSymbol, String, .Object., Object.)

Tries to invoke a RPC method.

TcAdsClient Methods 89:

TryRead(UInt32, UInt32, AdsStream, Int32.)

Reads data synchronously from an ADS device and writes it to the given stream.

TcAdsClient Methods 90:

TryRead(Int32, AdsStream, Int32, Int32, Int32.)

Reads data synchronously from an ADS device and writes it to the given stream.

TcAdsClient Methods 91:

TryRead(UInt32, UInt32, .Byte., Int32, Int32, Int32.)

Reads data synchronously from an ADS device and writes it to the given stream.

TcAdsClient Methods 92:

TryRead(UInt32, UInt32, AdsStream, Int32, Int32, Int32.)

Reads data synchronously from an ADS device and writes it to the given stream.

TcAdsClient Methods 93:

TryReadState

Reads the ADS status and the device status from an ADS server. Unlike the ReadState method this method does not call an exception on failure. Instead an AdsErrorCode is returned. If the return value is equal to AdsErrorCode.NoError the call was successfull.

TcAdsClient Methods 94:

TryReadWrite(Int32, .Byte., Int32, Int32, .Byte., Int32, Int32, Int32.)

Writes data synchronously to an ADS device and then Reads data from this device.

TcAdsClient Methods 95:

TryReadWrite(Int32, AdsStream, Int32, Int32, AdsStream, Int32, Int32, Int32.)

Writes data synchronously to an ADS device and then Reads data from this device.

TcAdsClient Methods 96:

TryReadWrite(UInt32, UInt32, .Byte., Int32, Int32, .Byte., Int32, Int32, Int32.)

Writes data synchronously to an ADS device and then Reads data from this device.

TcAdsClient Methods 97:

TryReadWrite(UInt32, UInt32, AdsStream, Int32, Int32, AdsStream, Int32, Int32, Int32.)

Writes data synchronously to an ADS device and then Reads data from this device.

TcAdsClient Methods 98:

TryWrite(Int32, AdsStream, Int32, Int32)

Writes data synchronously to an ADS device.

TcAdsClient Methods 99:

TryWrite(UInt32, UInt32, .Byte., Int32, Int32)

Writes data synchronously to an ADS device.

TcAdsClient Methods 100:

TryWrite(UInt32, UInt32, AdsStream, Int32, Int32)

Writes data synchronously to an ADS device.

TcAdsClient Methods 101:

TryWriteControl(StateInfo)

Changes the ADS status and the device status of an ADS server.

TcAdsClient Methods 102:

TryWriteControl(StateInfo, AdsStream, Int32, Int32)

Changes the ADS status and the device status of an ADS server.

TcAdsClient Methods 103:

Write(Int32, Int32)

Trigger Client Method/Command.

TcAdsClient Methods 104:

Write(Int32, AdsStream)

Writes data synchronously to an ADS device.

TcAdsClient Methods 105:

Write(UInt32, UInt32)

Trigger Client Method/Command.

TcAdsClient Methods 106:

Write(Int32, Int32, AdsStream)

Writes data synchronously to an ADS device.

TcAdsClient Methods 107:

Write(UInt32, UInt32, AdsStream)

Writes data synchronously to an ADS device.

TcAdsClient Methods 108:

Write(Int32, AdsStream, Int32, Int32)

Writes data synchronously to an ADS device.

TcAdsClient Methods 109:

Write(Int32, Int32, .Byte., Int32, Int32)

Writes data synchronously to an ADS device.

TcAdsClient Methods 110:

Write(Int32, Int32, AdsStream, Int32, Int32)

Writes data synchronously to an ADS device.

TcAdsClient Methods 111:

Write(UInt32, UInt32, .Byte., Int32, Int32)

Writes data synchronously to an ADS device.

TcAdsClient Methods 112:

Write(UInt32, UInt32, AdsStream, Int32, Int32)

Writes data synchronously to an ADS device.

TcAdsClient Methods 113:

WriteAny(Int32, Object)

Writes an object synchronously to an ADS device.

TcAdsClient Methods 114:

WriteAny(Int32, Object, .Int32.)

Writes an object synchronously to an ADS device.

TcAdsClient Methods 115:

TcAdsClient Methods 116:

WriteAny(UInt32, UInt32, Object)

Writes an object synchronously to an ADS device.

TcAdsClient Methods 117:

WriteAny(UInt32, UInt32, Object, .Int32.)

Writes an object synchronously to an ADS device.

TcAdsClient Methods 118:

TcAdsClient Methods 119:

WriteAnyString(Int32, String, Int32, Encoding)

Writes the string (Potentially unsafe!)

TcAdsClient Methods 120:

TcAdsClient Methods 121:

WriteAnyString(UInt32, UInt32, String, Int32, Encoding)

Writes the string (Potentially unsafe!)

TcAdsClient Methods 122:

WriteControl(StateInfo)

Changes the ADS status and the device status of an ADS server.

TcAdsClient Methods 123:

WriteControl(StateInfo, AdsStream, Int32, Int32)

Changes the ADS status and the device status of an ADS server.

TcAdsClient Methods 124:

WriteSymbol(ITcAdsSymbol, Object)

Writes a value to the symbol. Strings and all primitive data types(UInt32, Int32, Bool etc.) are supported. Array and structures are not supported. If a string is passed as parameter, the method attempts to parse the string according to the ADS data type of the symbol.

TcAdsClient Methods 125:

WriteSymbol(String, Object, Boolean)

Writes the passed object value to the specified ADS symbol.The parameter type must have the same layout as the ADS symbol.

Extension Methods

 

Name

Description

TcAdsClient Methods 126:

TcAdsClient Methods 127:

PollAdsState(IObservable.Unit.)

Overloaded.

Gets an observable sequence of AdsStates via Polling. (Defined by AdsClientExtensions.)

TcAdsClient Methods 128:

TcAdsClient Methods 129:

PollAdsState(TimeSpan)

Overloaded.

Gets an observable sequence of AdsStates via Polling. (Defined by AdsClientExtensions.)

TcAdsClient Methods 130:

PollValues(String, Type, IObservable.Unit.)

Overloaded.

Polls the symbol values on timepoints where the polling observable streams data / triggers (Defined by AnyTypeExtensions.)

TcAdsClient Methods 131:

PollValues(String, Type, TimeSpan)

Overloaded.

Polls the symbol as value sequence of object values with a specified period time. (Defined by AnyTypeExtensions.)

TcAdsClient Methods 132:

PollValues(String, Type, .Int32., TimeSpan)

Overloaded.

Polls the symbol as value sequence of object values with a specified period time. (Defined by AnyTypeExtensions.)

TcAdsClient Methods 133:

PollValues(String, Type, IObservable.Unit., Func.Exception, Object.)

Overloaded.

Polls the symbol values on timepoints where the polling observable streams data / triggers (Defined by AnyTypeExtensions.)

TcAdsClient Methods 134:

PollValues(String, Type, TimeSpan, Func.Exception, Object.)

Overloaded.

Polls the symbol as value sequence of object values with a specified period time. (Defined by AnyTypeExtensions.)

TcAdsClient Methods 135:

PollValues(String, Type, .Int32., IObservable.Unit., Func.Exception, Object.)

Overloaded.

Polls the symbol values on time points where the polling observable streams data / triggers (Defined by AnyTypeExtensions.)

TcAdsClient Methods 136:

PollValues(String, Type, .Int32., TimeSpan, Func.Exception, Object.)

Overloaded.

Polls the symbol as value sequence of object values with a specified period time. (Defined by AnyTypeExtensions.)

TcAdsClient Methods 137:

PollValues.T.(String, IObservable.Unit.)

Overloaded.

Polls the symbol values on timepoints where the polling observable streams data / triggers (Defined by AnyTypeExtensions.)

TcAdsClient Methods 138:

PollValues.T.(String, TimeSpan)

Overloaded.

Polls the symbol as value sequence of object values with a specified period time. (Defined by AnyTypeExtensions.)

TcAdsClient Methods 139:

PollValues.T.(String, IObservable.Unit., Func.Exception, T.)

Overloaded.

Polls the symbol values on timepoints where the polling observable streams data / triggers (Defined by AnyTypeExtensions.)

TcAdsClient Methods 140:

PollValues.T.(String, TimeSpan, Func.Exception, T.)

Overloaded.

Polls the symbol as value sequence of object values with a specified period time. (Defined by AnyTypeExtensions.)

TcAdsClient Methods 141:

PollValues.T.(String, .Int32., IObservable.Unit.)

Overloaded.

Polls the symbol values on time points where the polling observable streams data / triggers (Defined by AnyTypeExtensions.)

TcAdsClient Methods 142:

TcAdsClient Methods 143:

PollValues.T.(String, .Int32., TimeSpan)

Overloaded.

Polls the symbol as value sequence of object values with a specified period time. (Defined by AnyTypeExtensions.)

TcAdsClient Methods 144:

PollValues.T.(String, .Int32., IObservable.Unit., Func.Exception, T.)

Overloaded.

Polls the symbol values on timepoints where the polling observable streams data / triggers (Defined by AnyTypeExtensions.)

TcAdsClient Methods 145:

TcAdsClient Methods 146:

PollValues.T.(String, .Int32., TimeSpan, Func.Exception, T.)

Overloaded.

Polls the symbol as value sequence of object values with a specified period time. (Defined by AnyTypeExtensions.)

TcAdsClient Methods 147:

TcAdsClient Methods 148:

WhenAdsStateChanges

Gets an observable sequence of AdsStates. (Defined by AdsClientExtensions.)

TcAdsClient Methods 149:

WhenNotification(ISymbol)

Overloaded.

Gets an observable sequence of Notifications. (Defined by AdsClientExtensions.)

TcAdsClient Methods 150:

TcAdsClient Methods 151:

WhenNotification(ISymbolCollection)

Overloaded.

Gets an observable sequence of Notification objects. (Defined by AdsClientExtensions.)

TcAdsClient Methods 152:

WhenNotification(ISymbol, NotificationSettings)

Overloaded.

Gets an observable sequence of Notifications. (Defined by AdsClientExtensions.)

TcAdsClient Methods 153:

TcAdsClient Methods 154:

WhenNotification(ISymbolCollection, NotificationSettings)

Overloaded.

Gets an observable sequence of Notification objects. (Defined by AdsClientExtensions.)

TcAdsClient Methods 155:

TcAdsClient Methods 156:

WhenValueChanged

Observable sequence of Values driven by ADS Notifications on the specified symbol. (Defined by ValueSymbolExtensions.)

TcAdsClient Methods 157:

TcAdsClient Methods 158:

WriteValues.T.(String, IObservable.T.)

Overloaded.

Writes the sequence of values to the symbol specified by the instance path. (Defined by AnyTypeExtensions.)

TcAdsClient Methods 159:

TcAdsClient Methods 160:

WriteValues.T.(String, IObservable.T., Action.Exception.)

Overloaded.

Writes the sequence of values to the symbol specified by the instance path. (Defined by AnyTypeExtensions.)

Reference

TcAdsClient Class

TwinCAT.Ads Namespace