405
S1: it is the command trigger input point, which can select the external interrupt input
point or ordinary input point, trigger the command at the rising edge and falling edge,
and grab the encoder value.
S2: it is the number of the high-speed counter used together, which is used for encoder
signal input. The high-speed counting mode is single-phase incremental mode.
S3: three 16 bits registers (single word) are occupied continuously to set the number of
stations, the number of workpieces, and the filtering time. It is recommended to use the
power-off holding register.
The specific register allocation is as follows:
S3: set the number of stations, recorded as n, range: 1~32;
S3+1: set the maximum number of workpieces that can be processed, recorded as m,
range: 1~64;
S3+2: set the filtering time, range: 0~32767, unit: ms. This parameter can be used to
prevent errors caused by mechanical jitter. If the filtering time is set to 0, it means no filtering.
If it is less than 0, it will be treated as 0. Assuming that the filtering time is set to t and the
trigger input point is X4, the capture of the input signal adopts the following methods:
Rising edge: after X4 off state is maintained for at least t ms, the first detected rising edge is
the trigger signal;
Falling edge: after the X4 on state is maintained for at least t ms, the first falling edge
detected is the trigger signal.
S4: 3n 32-bit registers (double words) are occupied continuously, which are used to set
the reference value, workpiece entry deviation value and workpiece departure deviation
value of each station. Each parameter occupies 2 registers continuously. It is
recommended to use the power-off holding register. The specific register address
allocation is as follows:
Reference value(double
word)
Workpiece entry deviation
value(double word)
Workpiece departure
deviation value(double
word)
When the reference value of a station is set to 0, it means that the station does not
operate.
The workpiece entry deviation value and the workpiece departure deviation value are
mainly used for position calibration. When the encoder value of the workpiece entering
and leaving the corresponding station is found to be inconsistent with the setting during
actual use, it can be calibrated by adjusting the workpiece entry deviation value and the
workpiece departure deviation value. For example, the reference value of station 1 is set
to 1000, which means that the workpiece enters station 1 after triggering the rising edge
of X4 through 1000 high-speed count values. If in actual use, the workpiece enters
station 1 with only 990 high-speed count values, the workpiece entry deviation value can
be set to -10.
tudonghoatoancau.com