Functions Block

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 15

Timer

Page 1 of 15

Timer Function description


Timer has 8 modes, described as following.
1.Coil mode

Function description:
The function of timer mode 0 is same to coils.
2.On delay timer mode 1

Function description:
1. The time 't' is the preset value. When the present value reaches the preset value, it will stop. And the output will be ON till the enable
changed to OFF.
2. When the Enable is ON, the present value increases , or the preset value will be cleared to 0 as the enable is OFF.
3.On delay timer mode 2

Function description: 3 4
The time 't' is the preset time. (Diagram 1: t=t1+t2), the present value will increase till equal to the preset value and stop. And the output is ON
till reset is ON.
4.Off delay timer mode 1

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 2 of 15

Function description:
1. The time 't' is the preset value. The output will change from ON t o OFF as the present value reaches the preset value. What is more, the
present value also reset to zero.
2.Output will be OFF once the Reset input is ON. Also, the present value is reset to zero.
3.The present value will be cleared to zero as the Enable input OFFON during the present value increasing process.
4.The Output will be ON as Enable is positive triggered (OFFON), while the present value holding. On the contrary, the present value will
increase as the enable is negative triggered (ONOFF).
5.Off delay timer mode 2

Function description:
1. The time 't' is the preset value . The output will change from ON t o OFF as the present value reaches the preset value. What is more, the
present value is reset to zero.
2.Output will be OFF once the Reset input is ON. Also, the present value is reset to zero.
3.The resent value will be cleared to zero as the Enable is positive triggered (input OFFON) during the present value increasing process.
4.When Enable is change from OFF to ON, the output is Low, and present value is holding. Till the enable is negative triggered, the output
becomes ON, and the present value increases.
6.Flash timer mode 1

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 3 of 15

Function Description:
1. The time 't' is the preset value.
2. The output state will change from ON to OFF as the present value reaches the preset value while the Enable is holding ON. And the present
value will be reset to Zero. The operation will be repeated till the Enable state changes to OFF.
3. The output will be OFF and the present value will be reset to zero when the Enable becomes OFF.
7.Flash timer mode 2

Function Description:
1. The time 't' is the preset value.
2. The output state will change from ON to OFF as the present value reaches the preset value while the Enable is holding ON or positive
triggered. And the present value will be reset to Zero. The operation will be repeated till the Enable state changes to ON.
3. The output will be OFF and the present value will be reset to zero when the Reset becomes ON.
8.Flash timer mode 3

Function Description:
Time 't1', 't2' are both the preset values for two continuous timers (Tn and Tn+1).

Counter Function Description


Counter has 8 operation modes:
1.Coil mode

Function description:

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 4 of 15

The function of counter mode 0 is same to coils.


2.Counter without overtaking and without power retain

Function description:
1. When increasing counting (Dir is OFF), reset pulse set the present value of counter to zero, whereas decreasing, reset signal set the present
value of the counter to target value.
2. The raising edge produces counting pulses. Increasing counting, output will be ON as the present value reaches the preset value and the
present value is holding.
3. Decreasing counting, the output is ON as the present value reduces to '0', and it is holding.
4. Power on initialization: the present value initialize to 0/preset value according counting direction (increasing / decreasing).(Volatile )
3.Counter with overtaking but without power retain

Function description:
1. When increasing counting (Dir is OFF), reset pulse set the present value of counter to zero, whereas decreasing, reset signal set the present
value of the counter to target value.
2. The raising edge produces counting pulses. Increasing counting, output will be ON as the present value reaches the preset value and the
present value is holding.
3. Decreasing counting, the output is ON as the present value reduces to '0', and it is holding.
4. Power on initialization: the present value initialize to 0/preset value according counting direction (increasing / decreasing).(volatile)
4.Counter without overtaking but with power retain

Function description:
1. The counter mode 3 is similar to mode 1 except the mode 3 is non-volatile. The operation will continue as the power resupplied.
2. When increasing counting (Dir is OFF), reset pulse set the present value of counter to zero, whereas decreasing (Dir is ON), reset signal set
the present value of the counter to target value.
3. The raising edge produces counting pulses. Increasing counting, output will be ON as the present value reaches the preset value and the
present value is holding.
4. Power on initialization: the present value initialize to the value at the moment latest power failure.

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 5 of 15

5.Counter with overtaking and with power retain

Function description:
1. The counter mode 4 is similar to mode 2 except the mode 4 is non-volatile. The operation will continue as the power resupplied.
2. When increasing counting (Dir is OFF), reset pulse set the present value of counter to zero, whereas decreasing (Dir is On), reset signal set
the present value of the counter to target value.
3. The raising edge produces counting pulses. Increasing counting, output will be ON as the present value reaches the preset value and the
present value continues to increase.
4. Decreasing counting, the output is ON as the present value reduces to '0', and it is holding.
5. Power on initialization: the present value initialize to the value at the moment latest power failure.
6.With overtaking & without power down Compare Counter

Function description:
1. As increasing / decreasing counting, the reset signals set the present value of the counter to zero.
2. The raising edge produces counting pulses. Increasing counting, output will be ON as the present value reaches the preset value and the
present value continues to increase as the input pulses.
3. Decreasing counting, the output is OFF as long as the present value is less than preset value. The present value is holding as it reaches the
target value.
4. Power on initialization: the present value initialize to Zero.
7.With overtaking & with power down Compare Counter

Function description:
1. As increasing / decreasing counting, the reset signals set the present value of the counter to zero.
2. The raising edge produces counting pulses. Increasing counting, output will be ON as the present value reaches the preset value and the
present value continues to increase as the input pulses.
3. Decreasing counting, the output is OFF as long as the present value is less than preset value. The present value is holding as it reaches 0.
4. Power on initialization: the present value initialize to the value at the moment latest power failure (non-volatile).

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 6 of 15

8.1KHz input counter

Function description:
1. The input pulses of the counter are provided by HS-I01 or HS-I02.
2. The raising edge produces the counting pulses. Increasing counting, output will be ON as the present value reaches preset value. And the
present value is holding.
3. Volatile.
9.1KHz input compare counter

Function description:
1. The input pulses of the counter are provided by HS-I01 or HS-I02.
2. When enable is available (EN=HIGH), the output will be ON in the next time interval as the input pulse is larger than or equal to Upper value
in a fixed timer interval. Vice versa. As Lower value < input pulse < Upper value, the output is holding as former state.
3. When enable is unavailable (EN=LOW), the output will be OFF.
4. Power on initialization: the present value initialize to 0 (volatile).

RTC Function Description


RTC has 5 operation modes.
Mode 0.Coil mode

The function of RTC mode 0 is same to coils.


Parameter
setting
WW-WW
ON
OFF

Diagram

SUSU
0:00
0:00

Mode 1.Daily mode

Sample 1:

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Parameter
setting
WW-WW
ON
OFF

Page 7 of 15

Diagram

TUFR
8:00
17:00

Sample 2
Parameter
setting
WW-WW
ON
OFF

Diagram

TUFR
17:00
8:00

Sample 3
Parameter
setting
WW-WW
ON
OFF

Diagram

FRTU
8:00
17:00

Sample 4
Parameter
setting
WW-WW
ON
OFF

Diagram

FRTU
17:00
8:00

Sample 5
Parameter
setting
WW-WW
ON
OFF

Diagram

SUSU
8:00
17:00

Sample 6
Parameter
setting
WW-WW
On
OFF

Diagram

SUSU
17:00
8:00

Note: The output of RTC is always OFF as the Enable is LOW.


Mode 2.Weekly mode

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 8 of 15

Sample 1
Parameter
setting
WW-WW
On
OFF

Diagram

TUSA
8:00
17:00

Sample 2
Parameter
setting

WW-WW
On
OFF

Diagram

TUSA
17:00
8:00

Sample 3
Parameter
setting
WW-WW
On
OFF

Diagram

SATU
8:00
17:00

Sample 4
Parameter
setting

WW-WW
On
OFF

Diagram

SATU
17:00
8:00

Sample 5
Parameter
setting
WW-WW
On
OFF

Diagram

SASA
8:00
17:00

Sample 6
Parameter
setting
WW-WW
On
OFF

Diagram

SASA
17:00
8:00

Note: The output of RTC is always OFF as the Enable is LOW.


Mode 3.Year-month-day mode.

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 9 of 15

Sample 1
Parameter setting

Diagram

Begin time 03/05/23


End time 04/12/22

Sample 2
Parameter setting

Diagram

Begin time 04/12/22


End time 03/05/23

Note:The output of RTC is always OFF as the Enable is LOW.


Mode 4.30s Modify mode

Sample1
Parameter
setting

Diagram

WEEK TH
ON
08:00:20

Note: The output of RTC is always OFF as the Enable is LOW.


Note: At 80020s of Thursday, if Rn Output is off, 30s modify function take effect, the RTC is set to 80000, and Rn Output is On. When
RTC goes to 80020 again, Rn Output is set off (ON duration of Rn Output is 20s ).
Sample 2
Parameter
setting

Diagram

WEEK TH
ON
08:00:40

Note: The output of RTC is always OFF as the Enable is LOW.


Note: At 80040s of Thursday, 30s modify function take effect, and Rn output is set ON for one-scan time when the RTC is set to 801
00.

Analog Function Description


Analog function has 8 operation modes, covered as follows:
Mode

Icon

Requirement for
output ON

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 10 of 15

En On

Ay-Ref<=Ax<=Ay+Ref

Ax<=Ay

Ax>=Ay

Ref>=Ax

Ref<=Ax
5

Ref=Ax

Ref><Ax

Add-Subtract function description


Add-Subtract function described as following:

The ADD-SUB Addition and/or Subtraction function enables simple operations to be carried out on integers. There are three input values and one
code of coil which will be set when the calculation result is error.
calculation formula:
CALCULATION OUTPUT = INPUT1+INPUT2-INPUT3
Inputs/Outputs
INPUT1: first input value or other data code of the formula (integer).
INPUT2: second input value or other data code of the formula (integer).
INPUT3: third input value or other data code of the formula (integer).
OUTPUT: this is the value of the calculation formula output (integer).
NOTE: If the INPUTS are not connected, they are set to 0, If the input value is other data code, then decode the code to get value to operating.

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 11 of 15

The error can be coil M, N, and NOP. The error coil will be settled to 1 when error thing happens, but do nothing if the error code means
NOP.

Multiply-Divide function description


Multiply-Divide function described as following:

The MUL-DIV multiplication and/or Division function enables simple operations to be carried out on integer.
Calculation formula:
CALCULATION OUTPUT = INPUT1*INPUT2/INPUT3
Inputs/Outputs
INPUT1: first input value or other data code of the formula (integer).
INPUT2: second input value or other data code of the formula (integer).
INPUT3: third input value or other data code of the formula (integer).
OUTPUT: this is the value of the calculation formula output (integer).
NOTE: If the INPUTS are not connected, they are set to 0. If the input value is other data code, then decode the code to get value to operating.
The error coil can be M, N and NOP. The error coil will be settled to 1 when error thing happens, but do nothing if the error code means
NOP.

PID function description


PID function described as following:

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 12 of 15

The PID enables control operations to be carried out to integers. There are eight inputs as following:
SV: target value, the value range is : -32768 ~ 32767.
PV: test value, the value range is : -32768 ~ 32767.
Ts: sampling time, the value range is : -32768 ~ 32767(x10ms).
Kp: multiple, the value range is : 0~32767(%).
Ti: integer time, the value range is: 0~32767(x100ms).
Td: differential time, the value range is: 0~32767(x10ms)
The error coil can be M, N or NOP.
NOTE: these inputs except error coil and base can be other data code, the value will be decoded to operate when the PID function is enabled,
and the decode value can not overflow the PID's limit.
If the Sam.T or Gain is 0, then the error coil will be settled to 1, and the PID operation will not be operated.

MX function description
MX function described as following:

This special function displays 0 or one of 4 data values on the output. There are eight inputs, including one enable coil, two select coil, four data
parameters and P parameter, and one output.
Inputs/Outputs
Description of the inputs and output:
Enable coil: 1 one input En (the enable coil's state is 1)switches, dependent on S1 and S2, a parameterized value to the output MX.
0 on input EN (the enable coil's state is 0)switches 0 to the output MX.
S1 and S2: they are two coil's code, for selecting the value to be issued. The rule of selecting which value of the four value to output MX:
S1=0 and S2=0: the value 1 is issued;
S1=0 and S2=1: the value 2 is issued;
S1=1 and S2=0: the value 3 is issued;

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 13 of 15

S4=1 and S2=1: the value 4 is issued.


Parameters V1...V4: The V1~V4 value will be issued, the value range is -32768~32767.
Output MX: output value range is -32768~32767.
Note: The parameter V1...V4 can be other data code, they will be decoded to get the data value when the function is operated, then transfer the
value to the output MX.
Description of Function
If input En is set, then the function issues one of 4 possible values V1 to V4 at the output MX, depending on the parameter S1 and S2. If the
input En is not set, then the function issues the value 0 ant output MX.

AR function description
AR function described as following:

Description
The Analog Ramp instruction allows the output to be changed from the current level to the selected level at a specified rate. It has three inputs,
eight parameters, and two outputs.
Inputs/Outputs
Description of the inputs, parameters and output:
En: A change in the status from 0 to 1 at input En (Enable) applies the start/stop level (Offset "B"+StSp) to the output for 100ms and starts the
ramp operation to the selected level.
A change in the status from 1 to 0 immediately sets the current level to Offset "B", which makes output AR equal to 0.

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 14 of 15

Sel: Sel = 0, The step 1 (level 1) is selected.


Sel = 1, The step 2 (level 2) is selected.
A change in status of Sel causes the current level to start changing to the selected level at the specified rate.
St: A change in the status from 0 to 1 at input St (Decelerated Stop) causes the current level to decrease at a constant rate until the start/stop
level (Offset "B" + StSp) is reached. The start/stop level is maintained for 100ms and then the current level set to Offset "B", which makes output
AR equal to 0.
Parameters: Level 1 and Level 2: Levels to be reached, value range for each level: -10000 to +20000.
MaxL: Maximum value that must not be exceeded, value range:-10000 to +20000.
StSp: Start/Stop offset: value that is added to Offset"B" to create the start/stop level. If the Start/Stop offset is 0, then the
start/stop level is offset"B", value range: 0 to +20000.
Rate: Speed with which level 1, level 2 or Offset is reachted, Steps/seconds are issued, value range: 0 to 10000.
A: Gain value range: 0 to 1000.
B: Offset value range: +/- 10.000.
P: Number of decimal places value range: 0, 1, 2, 3. Only applies for displaying the values of AQ, level 1, level 2, MaxL, StSp,
and Rate in a message text.
Output AR: The output AR is scaled using the formula: (Current Level - Offset"B")/Gain"A".
When AR is displayed in parameter mode or message mode, it is displayed as an unscaled value (engineering units: current level). Value range
for AR: 0...+32767.
Error coil: The error coil can be M, N or NOP. When the A is equal 0, then error coil will be set to 1, but do nothing if the error coil means NOP.
Note: The parameters except P can be other data code, the value that is decoded from the code joining operation when the functions is
operated.
Description of function
If the input En is set, then the function sets the value StSp + Offset"B" for 100ms. Then, depending on the connection of Sel, the function runs
from the level StSp + Offset"B" to either level 1 or level 2 at the acceleration set in Rate.
If the input St is set, the function runs to a level of StSp + B at the acceleration set in Rate. Then the function holds the level at StSp + Offset"B"
for 100ms. After 100ms, the level is set to Offset"B". Output AQ. The scaled value (output AQ) is 0.
If the input St is set, the function can only be restarted once the inputs St and En have been reset.
If input Sel has been changed, depending on the connection of Sel, the function runs from the current target level to the new target level at the
rate that is specified.
If the input En is reset, the function immediately sets the current level to Offset"B".
The current level is updated every 100ms. Note the relationship between output AQ and the current level:
Output AQ = (current level - Offset"B") / Gain"A"

DR Function description
DR function described as following:

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

Timer

Page 15 of 15

The DR function is transferring data. When the En bit of the DR is set, the DR transfers data from DR previously register to DR current register.
The content of the DR previously register can be data or other data code. If it is other data code, then the code will be decoded when the DR
function is operated. The value range is : -32768 ~ 32767(signed), or 0~65535(unsigned).

file:///C:/Users/stelios/AppData/Local/Temp/~hh6292.htm

6/10/2016

You might also like