SOLAR_ENCODER_IO¶
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 |
The SOLAR_ENCODER_IO is used to easily integrate, with any S500 I/O card, Incremental encoders (A, B) plus inductive sensor (Z) as positioning sensors for Solar Trackers.
- This function uses the Fast Counters which have several I/O modules to integrate Incremental encoders. The counting modules with Fast Counters, and its features, are described in the chapter The
- Fast Counters of S500 I/O Devices: Fast Counter
Note
The functionality Fast Counter only works with expansion modules which are mounted at the I/O bus of an AC500 CPU. An exception is the CS31 Bus Module DC551-CS31, which contains a Fast Counter that is made operationally by the address setting on the module.
The I/O modules on the I/O bus have two inputs of Fast Counters per module, which are activated via software in the PLC configuration. Each module counter can be configured up to 10 possible modes. After that, it is activated during the initialization phase (power-on, cold start, warm start).
The Function Block SOLAR_ENCODER_IO should be used configuring the module parameter “Fast counter” with the operating modes 7, 9 or 10, to determine the counting procedure in x1, x2 or x4 count respectively. The different meanings of each “Fast counter” mode are explained down below:
Example: Configuration of module DC522 to use the “Fast counter” to integrate an Incremental encoder in x1 mode:
In Contol Builder Plus V2.0 and above:
Fast Counter: “7-1 UpDown directional \ discriminator”
The x1 counting mode is used. The encoder module discriminates the rotating way and count one pulse for each rising edge of the A signal.
In this mode the maximum counting frequency is 35 kHz.
The rotation is identified with a shift angle (90°) between A and B signal. In the I/O module, the clockwise rotation is identified with A signal in advance to B (see picture below).
Example: Direction identification using A and B signals:
Fast Counter: “9-1 UpDown directional \ discriminator X2”
The x2 counting mode is used. The module counts both the positive edges and the negative edges of trace A.
The result is the double number of counting pulses, so the precision increases correspondingly.
In this operating mode, the maximum counting frequency is 30 kHz.
Fast Counter: “10-1 UpDown directional \ discriminator X4”
The x4 counting mode is used. The counter counts the positive and negative edges of the traces A and B. In this operating mode, the maximum counting frequency is 15 kHz.
The I/O modules provide 2 Fast Counter inputs to use for relative positioning with 2 signals (A, B).
Note
To acquire the Z signal, a conventional input channel should be used.
Due to that, the Z signal will be set at least:
CPU | Minimum time to warranty the Z signal will be acquire |
---|---|
<583 | T>10 ms |
>590 | T>1 ms |
This table represents the time necessary to read the Z signal, using a task configured at the maximum frequency for each CPU.
The following table shows the S500 modules that contain a Fast Counter and which of the digital inputs are reserved for the counter.
MODULE | ASIGNED INPUTS | |
---|---|---|
CHANNEL A | CHANNEL B | |
DC522 | C8 | C9 |
DC523 | C16 | C17 |
DC532 | C24 | C25 |
DC524 | I24 | I25 |
DX522 | I0 | I1 |
DC531-CS31 | C16 | C17 |