Owner's manual

KEYENCE CORPORATION. Vision System Division
‐ 17 ‐ www.keyence.com
Command Execution Procedure Example: Rewrite Judgment Conditions (DW)
Here is an example of a representative command execution procedure. This section explains an example of executing the DW
(Rewrite Judgment Conditions) command, which specifies numeric values as command parameters, with Command Execute
Event set to "Polling". The screens with blue frames show when the "Registration monitor" function of KV STUDIO is used for
confirmation.
1
Check the DW (Rewrite Judgment Conditions) command operation.
1. Enter "45", the DW command No., in the data memory
corresponding to the PLC Command Address (DM100 in
this example), and enter the parameters in order. The
figure on the right shows an example of rewriting the upper
limit of the area of "T101" to "12345".
Parameter 1 101 (Tool ID: 101)
Par
ameter 2 105 (judgment condition item ID for "Area")
For information about the judgment condition item ID,
refer to the user's manual.
Par
ameter 3 0 ("0" represents the upper limit)
Parameter 4 12345000 (value)
→I
f "Decimal Point" is set to "Fixed- point", specify the
value multiplied by 1000 (12345000).
→If "Decimal Point" is set to "Floating- point", specify
a single precision floating point number (12345.000).
* The address to use is 1 word for Command No. and 2
words for other parameters.
2. Enter 1 in the data memory corresponding to the PLC
Command Execution Address (bit) (DM002 in this
example).
* The address to use is 1 word.
3. The command is executed.
4. Check if the values of the data memory corresponding to
the PLC Command Complete Address (bit) and Command
Result Address (DM003 and DM200 respectively in this
example) have changed.
When the command is successful: CVX writes "1" into Command
Complete Address (bit), and "0" into Command Result Address.
When the command fails: CVX writes "1" into Command
Complete Address (bit), and an error code into Command Result
Address.