Siemens SIMATIC S7-200 System Manual page 313

Programmable controller
Hide thumbs Also See for SIMATIC S7-200:
Table of Contents

Advertisement

Understanding the Command Byte for the Position Module
The Position module provides one byte of discrete outputs which is used as the command byte.
Figure 9-20 shows the command byte definition. Table 9-20 shows the Command_code
definitions.
A write to the command byte where the
R bit changes from 0 to 1 is interpreted
by the module as a new command.
If the module detects a transition to idle
(R bit changes state to 0) while a
command is active, then the operation in
progress is aborted and, if a motion is in
progress, then a decelerated stop is
progress then a decelerated stop is
performed.
After an operation has completed, the module must see a transition to idle before a new command
is accepted. If an operation is aborted, then the module must complete any deceleration before a
new command is accepted. Any change in the Command_code value while a command is active
is ignored.
The response of the Position module to a
change in the operating mode of the
S7-200 or to a fault condition is governed
by the effect that the S7-200 exerts over the
discrete outputs according to the existing
definition of the S7-200 function:
If the S7-200 changes from STOP to
-
RUN: The program in the S7-200
controls the operation of the Position
module.
If the S7-200 changes from RUN to
-
STOP: You can select the state that
the discrete outputs are to go to on a
transition to STOP or that the outputs
are to retain their last state.
--
If the R bit is turned off when
going to STOP: The Position
module decelerates any
motion in progress to a stop
--
If the R bit is turned on when going to STOP: The Position module completes any
command that is in progress. If no command is in progress, the Position module
executes the command which is specified by the Command_code bits.
--
If the R bit is held in its last state: The Position module completes any motion in
progress.
If the S7-200 detects a fatal error and turns off all discrete outputs: The Position module
-
decelerates any motion in progress to a stop.
The Position module implements a watchdog timer that turns the outputs off if communications
with the S7-200 are lost. If the output watchdog timer expires, the Position module decelerates
any motion in progress to a stop.
If a fatal error in the hardware or firmware of the module is detected, the Position module sets the
P0, P1, DIS and CLR outputs to the inactive state.
Open Loop Motion Control with the S7-200
MSB
7
6
5
QBx
R
Command_code
R
0 =
Idle
1 =
Execute the command specified
in Command_code (See Table 9-25)
Figure 9-20 Definition of the Command Byte
Table 9-25
Command_code Definitions
Command_code
Command
000 0000 to
0 to
000 1111
24
100 0000 to
25 to
111 0101
117
111 0110
118
111 0111
119
111 1000
120
111 1001
121
111 1010
122
111 1011
123
111 1100
124
111 1101
125
111 1110
126
111 1111
127
Chapter 9
LSB
4
3
2
1
0
Execute motion specified in
Profile Blocks 0 to 24
Reserved
(Error if specified)
Activate the DIS output
Deactivate the DIS output
Pulse the CLR output
Reload current position
Execute motion specified in
the Interactive Block
Capture reference point
offset
Jog positive rotation
Jog negative rotation
Seek to reference point
position
Reload configuration
299

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents