Converting Word (Signed), Double Word (Signed) Type To Word (Unsigned)/16-Bit String Type - Mitsubishi Electric MELSEC-Q/L Programming Manual

Hide thumbs Also See for MELSEC-Q/L:
Table of Contents

Advertisement

Converting word (signed), double word (signed) type to word
(unsigned)/16-bit string type
INT_TO_WORD(_E), DINT_TO_WORD(_E)
High
Basic
Process
Redundant Universal
performance
Structured ladder/FBD
INT_TO_WORD_E
EN
ENO
s
d
The following function(s) can go in the dotted squares.
INT_TO_WORD, INT_TO_WORD_E, DINT_TO_WORD, DINT_TO_WORD_E
■Argument
Input/output
Name
argument
Input argument
EN
s(_INT, _DINT)
Output argument
ENO
d
Processing details
■Operation processing
• INT_TO_WORD, INT_TO_WORD_E
Converts word (signed) type data input to (s) into word (unsigned)/16-bit string type data, and outputs the operation result
from (d).
s
22136
Word (signed) type
• DINT_TO_WORD, DINT_TO_WORD_E
Converts double word (signed) type data input to (s) into word (unsigned)/16-bit string type data, and outputs the operation
result from (d).
s
12345678
Double word (signed) type
12345678
0
0
0
0
0
0
0
0
1
614E
H
High-order 16-bit data is discarded.
LCPU
ST
ENO:=
(EN, s, d);
INT_TO_WORD_E
Description
Executing condition (TRUE: Execution, FALSE:
Stop)
Input
Execution result (TRUE: Normal, FALSE: Error)
Output
d
5678
H
Word (unsigned)/16-bit string type
Word (unsigned)/16-bit string type
0
1
1
1
1
0
0
0
1
1
0
0
0
0
0
1
1
0
0
0
0
Data type
Bit
Word (signed), double word (signed)
Bit
Word (unsigned)/16-bit string
d
614E
H
1
0
1
0
0
1
1
1
0
1
0
1
0
0
1
1
1
0
5 APPLICATION FUNCTIONS
5.1 Type Conversion Functions
5
45

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents