Class Encoder
The Encoder class represents an encoder device and provides access to its functions, parameters, and state. It uses an AdsClient to communicate with the encoder via the TwinCAT ADS protocol. The class contains three main properties:
- Functions: Provides methods to interact with and control the encoder.
- Parameters: Allows reading and writing various encoder settings.
- State: Provides access to various encoder states and properties.
public class Encoder
- Inheritance
-
Encoder
- Inherited Members
Properties
Functions
The EncoderFunctions class provides methods to interact with and control encoder devices via the TwinCAT ADS protocol. It includes functionalities to set and reinitialize the actual position of the encoder, activate and deactivate touch probes and external latches, and set external latch events. The class uses an AdsClient to communicate with the encoder and sends commands using specific index groups and offsets.
public EncoderFunctions Functions { get; }
Property Value
Parameters
The EncoderParameters class provides an interface to interact with encoder parameters via an AdsClient. It allows reading and writing various encoder settings such as ID, name, type, scaling factor, position offset, count direction, modulo factor, mode, soft end monitoring, soft end positions, evaluation direction, and filter times. The class uses an AdsClient to communicate with the encoder and retrieve or update these parameters.
public EncoderParameters Parameters { get; }
Property Value
State
The EncoderState class provides access to various encoder states and properties through an AdsClient instance. It allows reading and writing of encoder-related data such as error codes, actual positions, velocities, accelerations, and other relevant metrics.
public EncoderState State { get; }