Siemens SIMATIC Vision Sensor VS 130-2 Manual page 124

Hide thumbs Also See for SIMATIC Vision Sensor VS 130-2:
Table of Contents

Advertisement

Process Interface
Sequence When Changing Codes (COMMAND = W#16#0001)
If the VS 130-2 is currently executing a read job, follow the steps below:
1. Call FB79 with COMMAND=W#16#0000. This stops output of the result string (job
W#16#0081).
2. Make a code change by calling FB79 with COMMAND=W#16#0001 and PARAM=
new code number.
When the job is started, the parameters DONE and ERROR have the value
FALSE. The ACTIVE parameter changes to the value TRUE.
The block changes the code selected on the VS 130-2 to the value specified in the
PARAM1 parameter.
It then queries the code currently selected on the VS 130-2 and outputs this in the
CODE_OUT parameter.
If the currently selected code matches the code specified in the PARAM1
parameter, the ACTIVE parameter has the value FALSE and the DONE
parameter the value TRUE.
If the currently selected code does not match the code specified in the PARAM1
parameter, the ACTIVE parameter has the value FALSE and the ERROR
parameter the value TRUE. The ERRCODE parameter contains an appropriate
error message.
There is also a check to determine if the code change has been blocked by a
"Service" or "User1" user logged on via the setup support who has taken control of
the VS 130-2 and if the newly selected code has been trained. If an error is
detected, the ACTIVE parameter changes to the value FALSE and the ERROR
parameter changes to the value TRUE. The ERRCODE parameter contains an
appropriate error message.
3. Call FB79 again cyclically with COMMAND= W#16#0081.
If you attempt to cancel during an ongoing code change, the ERRCODE parameter
takes the value DW#16#00000002 but the job is processed until the end.
Note
When the code is changed, the processing unit is set to STOP for at least 150 ms
(see Selecting Modes "Select code"). In exceptional cases, a code change can
take up to 15 seconds.
If you specify the value 0 for the PARAM1 parameter, the previously selected code
is retained.
The value of PARAM1 cannot be changed before the job is completed.
Note
The following parameters must be set to PROFIBUS DP or PROFINET IO to
process the job:
Output the result string
Port for the DISA, SEL0 to SEL3, TRN, RES, IN_OP, TRD, RDY signals
6-26
Vision Sensor SIMATIC VS 130-2/VS 130-2vcr
A5E00475759-01

Advertisement

Table of Contents
loading

This manual is also suitable for:

Simatic vision sensor vs 130-2vcr

Table of Contents