API
139 RPR
P S1 S2 Read the AC motor drive’s parameters Bit Devices Word Devices
X Y M K H KnX KnY KnM T C D
S1 * * *
S2 *
Operands: none
16-bit command (5 STEPS)
RPR RPRP
32-bit command
- - - -
Flag signal: none
Explanation S1: Data address for reading S2: The register that saves the read data
API
140 WPR
P S1 S2 Write the AC motor drive’s parameters Bit Devices Word Devices
X Y M K H KnX KnY KnM T C D
S1 * * *
S2 * * *
Operands: None
16-bit command (5 STEPS)
WPR WPRP
32-bit command
- - - - Flag signal: none
Explanation S1: The data for writing. S2: The parameters address for the write data.
Example 1. It will read the data in parameter H2100 of the CT2000 and write into D0; H2101 is read and write into D1.
2. When M0=On, data in D10 will be written into Pr. H2001 of CT2000.
3. When M1=ON, data in H2 will be written into Pr. H2001 of CT2000, which is to activate the AC motor drive.
4. When M2=ON, data in H1 will be written into H2000 of CT2000, which is to stop the AC motor drive.
5. When data writing successfully, M1017 will be on.
END M1000
RPR H2100 D0
RPR H2101 D1
WPR WPRP WPRP
D10 H2
H1 H2000 H2001 H2000
Y0 M1017
M1 M2 M0
Chapter 16 PLC Function |CT2000 Series
16-72
API
141 FPID
P S1 S2 S3 S4 PID control for the AC motor drive Bit Devices Word Devices
X Y M K H KnX KnY KnM T C D
S1 * * *
S2 * * *
S3 * * *
S4 * * *
Operands: None
16-bit command (9 STEPS)
FPID FPIDP
32-bit command
- - - -
Flag signal: None
Explanation 1. S1: PID Set Point Selection, S2: Proportional Gain P, S3: Integral Time I, S4: Derivative control D
2. This command FPID can control the PID parameters of the AC motor drive directly, including Pr.08.00 PID set point selection, Pr.08.01 Proportional gain (P), Pr.08.02 Integral time (I) and Pr.08.03 Derivative control (D)
Example 1. Assume that when M0=ON, S1 is set to 0 (PID function is disabled), S2=0, S3 =1 (unit: 0.01 seconds) and S4=1 (unit: 0.01 seconds).
2. Assume that when M1=ON, S1 is set to 0 (PID function is disabled), S2=1 (unit:
0.01), S3 =0 and S4=0.
3. Assume that when M2=ON, S1 is set to 1(frequency is inputted by digital keypad), S2=1 (unit: 0.01), S3 =0 and S4=0.
4. D1027: frequency command after PID calculation.
END
H0
M2 M1 M0
M1000
H1 H0
H0
H1 H1
H1 H1
H0 H0
H0 H0
FPID
MOV D1027 D1
FPID
FPID
Chapter 16 PLC Function |CT2000 Series
16-73
API
142 FREQ
P S1 S2 S3 Operation control of the AC motor drive Bit Devices Word Devices
X Y M K H KnX KnY KnM T C D
S1 * * *
S2 * * *
S3 * * *
Operands: None
16-bit command (7 STEPS)
FREQ FREQP
32-bit command
- - - - Flag signal: M1028
Explanation 1. S1: frequency command, S2: acceleration time, S3: deceleration time
2. This command FREQ can control frequency command, acceleration time and deceleration time of the AC motor drive. Special register control is shown as following:
M1025: controls RUN (On)/STOP (Off) of the drive. (Run is valid when Servo On (M1040 On).)
M1026: Operation directions FWD (On)/REV (Off) of the drive.
M1040: controls Servo On (On)/ Servo Off (Off).
M1042: enable quick stop(ON)/ disable quick stop(Off) M1044: enable Stop (On)/ disable stop(Off)
M1052: frequency locked (On)/ disable frequency locked(Off)
Example 1. M1025: controls RUN (On)/STOP (Off) of the drive. M1026: operation direction FWD (On)/REV (Off) of the drive. M1015: frequency attained.
2. When M10=ON, setting frequency command of the AC motor drive to K300(3.00Hz) and acceleration/deceleration time is 0.
3. When M11=ON, setting frequency command of the AC motor drive to K3000(30.00Hz), acceleration time is 50 and deceleration time is 60.
END M13
M1044 M14
M1052
FREQP K300 K0 K0
FREQ K3000 K50 K60 M11
M10
M10 M11
M1000
M1040 M12
M1042 M1000
M1025 M11
M1026
Chapter 16 PLC Function |CT2000 Series
16-74
API
263 TORQ
P S1 S2 Torque Control of AC Motor Drive Bit Devices Word Devices
X Y M K H KnX KnY KnM T C D
S1 * * *
S2 * * *
Operands: None
16-bit command (7 STEPS)
TORQ TORQ P
32-bit command
- - - -
Flag signal: M1063
Explanation 1. S1: torque command (display in signed decimal with one decimal place) S2: speed limit
2. This command can control torque command and speed limi. Special register control is shown as following:
M1040: controls Servo On(On)/ Servo Off(Off). Torque output and speed limit are defined by the setting of TORQ command when TORQ command is set when Servo is ON.
Example 1. M1040: control Servo On(On)/ Servo Off(Off). M1063: target torque attained.
D1060: control mode setting. D1053: actual torque.
2. When M0=Off, setting torque command of the AC motor drive to K+300(+30.0%) and speed limit to 3000(30Hz).
3. When M0=On, setting torque command of AC motor drive to K-300(-30.0%) and speed limit to 3000(30Hz)。
4. When M10=On, AC motor drive begins to execute torque command.
5. When target torque is attained, M1063 will switch ON and flag signal will be blinking.
Chapter 16 PLC Function |CT2000 Series
16-75
API
262 DPOS
P S1 Point to Point Position Control of AC Motor Drive Bit Devices Word Devices
X Y M K H KnX KnY KnM T C D
S1 * * *
Operands: None
16-bit command (7 STEPS)
- - - -
32-bit command(5 steps)
DPOS DPOSP
Flag signal: M1064, M1070
Explanation S1: target position (signed decimal)
This DPOS command can control the motor position of AC motor drive. Special register control is shown as following:
M1040: controls Servo On(On)/ Servo Off(Off). M1055: searching origin point.
M1048: operate to the new position point. In the condition D1060 = 1 (control mode is set to position mode), M1040=1 (Servo ON), and DPOS command is given; when M1048 is set from OFF to ON the AC motor drive will operate till the new position point.
Example 1. M1040: controls Servo On(On)/ Servo Off(Off). M1064: target position attained.
D1060: control mode setting. D1051(L) and D1052(H): actual position point.
2. When X0=On, setting M1040 to ON (Servo On).
3. When X1=On, setting DPOS position command to +300000. It will delay for 1 second then set M1048 to ON (operate to the new position). Please observe if the D1051 value changes. When position is attained, M1064 will set to ON and Y0 will output an ON signal.
API CANRX S1 S2 S3 D Read CANopen slave data
Chapter 16 PLC Function |CT2000 Series
16-76
261 P
Bit Devices Word Devices
X Y M K H KnX KnY KnM T C D
S1 * *
S2 * *
S3 * *
D * * *
Operand: none
16-bit command (7 STEPS)
FREQ FREQP
32-bit command
- - - -
Flag signal: M1028
Explanation 1. S1: Slave station number, S2: main index, S3: sub-index + bit length, D: save address
2. Command CANRX can read the corresponding slave. Index. When executing this command, it will send SDO message to the slave. At this time, M1066 and M1067 are 0 but when reading is complete M1066 will set to 1. If the slave replied an accurate response, the value will be written to the designated register and M1067 is now set to 1. However, if the slave replied an inaccurate response, this error message will be recorded in D1076~D1079.
Example M1002: touch once to activate PLC and change K4M400=K1. After the change, different message will be displayed when M1066 is set to 1.
Chapter 16 PLC Function |CT2000 Series
16-77
API
264 CANTX
P S1 S2 S3 S4 Write CANopen slave data Bit Devices Word Devices
X Y M K H KnX KnY KnM T C D
S1 * *
S2 * * * * *
S3 * *
S4 * *
Operands: None
16-bit command (7 STEPS)
FREQ FREQP
32-bit command
- - - - Flag signal: M1028
Explanation 1. S1: slave station number, S2: the address to write, S3: main index, S4: sub-index+
bit length.
2. Command CANTX can read the corresponding index of the slave. When executing this command, it will send SDO message to the slave. At this time, M1066 and M1067 are 0 but when reading is complete M1066 will set to 1. If the slave replied an accurate response, the value will be written to the designated register and M1067 is now set to 1. However, if the slave replied an inaccurate response, this error message will be recorded in D1076~D1079.
Chapter 16 PLC Function |CT2000 Series
16-78
API
265 CANFLS
P D Update the mapping special D of CANopen Bit Devices Word Devices
X Y M K H KnX KnY KnM T C D
D * *
Operands: None
16-bit command (7 STEPS)
FREQ FREQP
32-bit command
- - - - Flag signal: M1028
Explanation 1. D: the special D for update.
2. CANFLS can update the Special D command. When it executes in read only mode, it sends equivalent message as CANRX to the slave and saves the slave response to this particular Special D. When it executes in read/write mode, it sends equivalent message as CANTX to the slave and saves this special D value to the corresponding slave.
3. M1066 and M1067 are both 0. When reading is complete, M1066 will be 1 and this value will write to the designated register if the slave replies an accurate response. When slave replies a fault response then M1067 will be 0 and this error message will be recorded to D1076~D1079.
Chapter 16 PLC Function |CT2000 Series
16-79