Using USS Protocol Instructions to Communicate with Drives
11-5
S7-200 Programmable Controller System Manual
A5E00066097-02
11.3 USS Protocol Instructions
USS_INIT
The USS_INIT instruction is used to enable and initialize,
or to disable MicroMaster Drive communication. Before
any other USS Protocol instruction can be used, the
USS_INIT instruction must be executed without errors
being returned. The instruction completes and the Done
bit is set immediately, before continuing to the next
instruction.
The instruction is executed on each scan when the EN
input is on. The USS_INIT instruction should be executed
exactly once for each change in communication state.
Therefore, the EN input should be pulsed on through an
edge detection element. Once USS Protocol has been
initiated, it must be disabled by execution of a new
USS_INIT instruction before a change in initialization
parameters can be made.
The value for the USS input selects the communication protocol. 1 assigns port 0
to USS protocol and enables the protocol. 0 assigns port 0 to PPI and disables the
USS protocol.
BAUD sets the baud rate at 1200, 2400, 4800, 9600, or 19,200.
ACTIVE indicates which drives are active. Some drives only support addresses 0
through 30. Figure 11-2 shows the description and format of the active drive input.
Any drive that is marked as ACTIVE is automatically polled in the background to
control the drive, collect status, and prevent serial link timeouts in the drive. Refer
to Table 11-1 on page 11-3 to compute the time between status polls. Refer to
Section 11.5 for information about how to configure the serial link timeout
parameter (P093).
MSB LSB
30 29 28 3 2 1 0
D0D1D2D30 D29
D0 Drive 0 active bit; 0 - drive not active, 1 - drive active
D1 Drive 1 active bit; 0 - drive not active, 1 - drive active
.
.
.
D31
31
Figure 11-2 Active Drive Description and Format
L
A
D
S
T
L
CALL USS_INIT,
USS,
BAUD,
ACTIVE, ERR
USS_INIT
EN
USS
ACTIVE
F
B
D
ERR
222 224
✓✓✓
221 226
✓
BAUD
DONE