03.01.2013 Views

Toshiba PROSEC T1-16S PLC User's Manual - CTi Automation

Toshiba PROSEC T1-16S PLC User's Manual - CTi Automation

Toshiba PROSEC T1-16S PLC User's Manual - CTi Automation

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.

7. Instructions<br />

FUN 032 D− Double-word subtraction<br />

Expression<br />

Input −[ A+1⋅A D− B+1⋅B → C+1⋅C ]− Output<br />

148 <strong>T1</strong>-<strong>16S</strong> User’s <strong>Manual</strong><br />

6F3B0253<br />

Function<br />

When the input is ON, the double-word data of B+1⋅B is subtracted from A+1⋅A, and the result is<br />

stored in C+1⋅C. The data range is -2147483648 to 2147483647.<br />

If the result is greater than 2147483647, the upper limit value 2147483647 is stored in C+1⋅C, and<br />

the output is turned ON. If the result is smaller than -2147483648, the lower limit value<br />

-2147483648 is stored in C+1⋅C, and the output is turned ON.<br />

Execution condition<br />

Input Operation Output<br />

OFF No execution OFF<br />

ON Execution (normal) OFF<br />

Execution (overflow or underflow occurred) ON<br />

Operand<br />

Name Device Register Constant Index<br />

X Y R S T. C. XWYWRWSW T C D I J K<br />

A Minuend √ √ √ √ √ √ √ √<br />

B Subtrahend √ √ √ √ √ √ √ √<br />

C Difference √ √ √ √ √ √<br />

Example<br />

When R005 is ON, the double-word data of RW25⋅RW24 is subtracted from the double-word<br />

data of D0101⋅D0100, and the result is stored in D0103⋅D0102.<br />

If the data of D0101⋅D0100 is 1580000 and the data of RW25⋅RW24 is 80000, the result<br />

1500000 is stored in D0103⋅D0102, and R010 is turned OFF. (No overflow/underflow)<br />

D0101⋅D0100 1580000<br />

RW25⋅RW24 80000<br />

− D0103⋅D0102 1500000 R010 is OFF<br />

<strong>CTi</strong> <strong>Automation</strong> - Phone: 800.894.0412 - Fax: 208.368.0415 - Web: www.ctiautomation.net - Email: info@ctiautomation.net

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

Saved successfully!

Ooh no, something went wrong!