23.06.2014 Views

5. Commands and Functions - Sanyo Denki America, Inc.

5. Commands and Functions - Sanyo Denki America, Inc.

5. Commands and Functions - Sanyo Denki America, Inc.

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>5.</strong> <strong>Comm<strong>and</strong>s</strong> <strong>and</strong> <strong>Functions</strong><br />

Comm<strong>and</strong> Code: 135 (87h)<br />

Data Length: 0 bytes<br />

Communication Error<br />

This comm<strong>and</strong> returns the history of all past communication errors; the data is cleared at power OFF.<br />

Returned data The returned data is 8 bytes (returned in the order of most recent to oldest)<br />

Communication error codes<br />

Name<br />

Code (hex)<br />

Checksum error 01<br />

Timeout 02<br />

Parity error 08<br />

Framing error 10<br />

Overrun error 20<br />

Comm<strong>and</strong> Code: 137 (89h)<br />

Data Length: 0 bytes<br />

Software Revision<br />

This comm<strong>and</strong> reads the software revision.<br />

Returned<br />

The returned data is 2 bytes.<br />

data<br />

DAT Bit7 Bit6 Bit5 Bit4 Bit3 Bit2 Bit1 Bit0<br />

DAT1 *<br />

DAT2<br />

Software Rev<br />

Comm<strong>and</strong> Code: 138 (8Ah)<br />

Data Length: 0 bytes<br />

Program Stop Line<br />

This comm<strong>and</strong> reads the line where the program stopped if a STOP, program stop, or ALM aborts the<br />

running program.<br />

Returned The returned data is 2 bytes.<br />

data<br />

DAT Bit7 Bit6 Bit5 Bit4 Bit3 Bit2 Bit1 Bit0<br />

DAT1<br />

Stop line (lower byte)<br />

DAT2<br />

Stop line (higher byte)<br />

Comm<strong>and</strong> Code: 140 (8Ch)<br />

Data Length: 0 bytes<br />

Loop Counter Read<br />

This comm<strong>and</strong> is exclusively used in programs; it returns the current value of the For/Next loop counter.<br />

The returned data contains the values of all variables from 0 through A, in that order.<br />

The returned data is 2 bytes (in the order of most recent to oldest)<br />

Returned<br />

DAT Bit7 Bit6 Bit5 Bit4 Bit3 Bit2 Bit1 Bit0<br />

data<br />

DAT1 to 10<br />

Loop counter (variable 0~Ah)<br />

5-45

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!