SOLAR_ENCODER_CD522

../_images/71ab0582409b0bcc0a33139000eba54e
Available as of PLC runtime system: V1.3 and above
Included in library: Solar_AC500_V22.lib
Type Function Block with historical values
Group Package of functions to get the sun position

Function Block to easily integrate, with the CD522 card, incremental encoders (A, B, Z) as positioning sensors for Solar Trackers.

The SOLAR_ENCODER_CD522 is used to easily integrate, with the CD522 card, incremental encoders (A, B, Z) as positioning sensors for Solar Trackers.

The module CD522 can be used in 12 different configurable operating modes. The operating mode is configured in PLC Configuration using module parameters. After that, it is activated during the initialization phase (power-on, cold start, warm start).

In order to configure and use the function encoder of module CD522, different operating modes are available. The Function Block SOLAR_ENCODER_CD522 should be used by configuring the parameter 6 or 14 (“Mode counter 0” or “Mode counter 1”) in modes 11, 12 or 13 to use the incremental encoder as: Incremental encoder, Incremental encoder X2 or Incremental encoder X4 respectively.

See user manual CD522: Encoder & PWM Module CD522

Example: Configuration of module CD522 to control an incremental encoder:

In Control Builder Plus V2.0 and above:

../_images/76762ce4409b0c780a33139000eba54e

The meaning of the different operating modes available to control an incremental encoder is:

Operating Mode 11     “Incremental encoder”

Should be specified in PLC Configuration; parameter “Mode counter” in order to use one up/down counter for position sensor x1 count.

Operating Mode 12      “Incremental encoder X2”

Should be specified in PLC Configuration; parameter “Mode counter” in order to use one up/down counter for position sensor x2 count.

Operating Mode 13      “Incremental encoder X4”

Should be specified in PLC Configuration; parameter “Mode counter” in order to use one up/down counter for position sensor x4 count.

The module CD522 provides 2 encoder functions for relative positioning with 3 signals. 2 signals are used for rotation discrimination and pulse count, identified by A0 and B0 for counter0 and A1 and B1 for counter1. The third one is used in multi-turn encoder to count the number of rotation (mechanical zero), identified by Z0 for counter0 and Z1 for counter1. Signals Z0 and Z1 are used in synchronization process. Inputs I3 and I11 needs to be defined as touch input.

Note

If the setup needs both Calibration & Synchronization then the Z pulse from the encoder to be connected to both Z0 & I3 inputs for counter0 and Z1 & I11 inputs for counter1.

The rotation is identified with a shift angle (90°) between A and B signal. In the module CD522, the clockwise rotation is identified with A signal in advance to B (see picture below).

Example: Direction identification using A and B signals:

../_images/f6022408409b0cc60a33139000eba54e

Depending on which kind of operating mode is specified, the counting procedure will be x1, x2 or x4 count. Basically the x1 counting mode is used (mode 11). The encoder module discriminates the rotating way and count one pulse for each rising edge of the A signal.

In order to increase resolution, the x2 counting mode can be specified (mode 12). The encoder module counts both the positive edges and the negative edges of trace A. This results in the double number of counting pulses. The precision increases correspondingly.

The resolution could be multiplied by 4, using the x4 counting mode (mode 13). The encoder module counts a pulse on both rising and falling edge of A signal and B signal.