Operation, Sample program – Toshiba SX 2000 User Manual

Page 53

Attention! The text in this document has been recognized automatically. To view the original document, you can use the "Original mode".

Advertising
background image

Operation:

Chapt.1 System Configuration

When the input condition of the XFER instruction comes ON, the read operation

is started. The execution status is monitored by

B+1

as follows.

B+1

(Execution status): HOOOO ^ Normal complete

H0001 ^ Communication error (parity error, framing error)

H0002 ^ Message length over (more than 512 bytes)

H0003 ^ Receive buffer over flow

H0004 _ Receive time-out (see below)

The receive time-out is detected when the time from the starting character to the
trailing code exceeds the following time.

Long scan cyele or short receive message, low baudrate avoid the receive time-out.

Baudrate

Time-out setting

300, 600, 1200 bps

30 seconds

2400 bps

15 seconds

4800 bps

7 seconds

9600 bps

3 seconds

19200 bps

1.5 seconds

Sample program:

00048 MOU D10001C 00000 MOU D1001T-

-C 00004 MOU D1002TC 01100 MOU D1003T-

- I-C 00Z56 MOU D10041C 00000 MOU D10051C 00000 MOU D1006]--------------------------------------

R0100 R0101 R0102

Tf--- T1—rC

RST S00511CD1000 XFER D1004

^

D1002]-------------------------

SO051

Li—

T-CD1005

= 000001CD1006 <> 00000TC SET R0101>

H51005 <> 00000T-

S0051

-[SET R0102T-

R010O

—Ml------ [ RST R0101TC RST R01021-

Rung 1: Sets the parameters for the XFER instruction.

The registers of 256 words starting with Dll00 are reserved to store
the received message.

Rung 2: When R0100 is set to ON, the read operation is started.

If the operation is completed normally, the received message is

stored in D1100 and after, and R0101 is set to ON.

If the message could not be received normally by some error, R0102
is set to ON.

Rung 3: When R0100 is reset to OFF, the result status (R0101 and R0102)

are reset to OFF.

36

Sequence Controller S2T

Advertising