Freeport Initialization; Using The Xmt Instruction To Transmit Data - Siemens SIMATIC S7-200 System Manual

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

Advertisement

SIMATIC Instructions

Freeport Initialization

SMB30 and SMB130 configure the communication ports, 0 and 1, respectively, for
Freeport operation and provide selection of baud rate, parity, and number of data
bits. The Freeport control byte(s) description is shown in Table 9-25.
Table 9-25 Special Memory Bytes SMB30 and SMB130
Port 0
Format of
SMB30
SM30.6
and
SM30.7
SM30.5
SM30.2 to
SM30.4
SM30.0
and
SM30.1
Note: One stop bit is generated for all configurations.

Using the XMT Instruction to Transmit Data

The XMT instruction lets you send a buffer of one or more characters, up to a
maximum of 255. An interrupt is generated (interrupt event 9 for port 0 and
interrupt event 26 for port 1) after the last character of the buffer is sent, if an
interrupt routine is attached to the transmit complete event. You can make
transmissions without using interrupts (for example, sending a message to a
printer) by monitoring SM4.5 or SM4.6 to signal when transmission is complete.
9-188
Port 1
Format of
MSB
7
SMB130
p p
d
SM130.6
pp:
Parity select
and
00 =
SM130.7
01 =
10 =
11 =
SM130.5
d:
Data bits per character
0 =
1 =
SM130.2
bbb: Freeport Baud rate
to
000 = 38,400 baud
SM130.4
001 = 19,200 baud
010 = 9,600 baud
011 = 4,800 baud
100 = 2,400 baud
101 = 1,200 baud
110 = 600 baud
111 =
SM130.0
mm: Protocol selection
and
00 =
SM130.1
01 =
10 =
11 =
Description
LSB
0
Freeport mode control byte
b b b m m
no parity
even parity
no parity
odd parity
8 bits per character
7 bits per character
300 baud
Point-to-Point Interface protocol (PPI/slave mode)
Freeport protocol
PPI/master mode
Reserved (defaults to PPI/slave mode)
S7-200 Programmable Controller System Manual
A5E00066097-02

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents