FC6A S
ERIES
MICROS
MART
L
ADDER
P
ROGRAMMING
M
ANUAL
FC9Y-B1726
26-41
26: S
CRIPT
Indirect assignment
Example 7.33
Indirect read
Script
Operation Description
When the value of D0020 is 8, the value of D0018, the device 8 words from D0010, is read and stored in D0200.
Example 7.34
Indirect write
Script
Operation Description
When the value of D0020 is 3, the constant 1234 is stored in D0013, the device 3 words from D0010.
8. Data Type Designations
Example 8.1
Processing that mixes F (float), D (double word), and W (word) data types using data type designations
Script
Operation Description
The value of D0100 (data type F (float)) is converted to data type D (double word) and stored in D0200 and D0201.
The value of D0110 (data type F (float)) is converted to data type D (double word) and stored in D0210 and D0211.
Logical XOR (exclusive OR) is performed on each bit of D0200 and D0210 (data type D (double word)) and the result is stored in
D0300 and D0301.
The value of D0301, which is the low word of D0300 (data type D (double word)), is stored in D0400.
In the above example script, F (float) is selected as the data type in Script Editor, and
From Upper Word
is selected in
Device
Settings
.
The method to store 32-bit data in devices conforms to the data storage method specified in the function area settings.
For details, see "32-bit Data Storage" on page 3-9.
[D0200] = OFFSET([D0010],[D0020]);
0000
D0010
0008
D0020
+8
1234
D0018
Read
1234
D0200
OFFSET([D0010],[D0020]) = 1234;
0000
D0010
0003
+3
1234
D0013
Write
1234
D0020
[D0100] = 1.5;
[D0110] = 10.5;
asd
{
[D0200] = FLOAT2BIN([D0100]);
[D0210] = FLOAT2BIN([D0110]);
[D0300] = [D0200]^[D0210];
}
asword
{
[D0400] = [D0301];
}
Summary of Contents for MICROSmart FC6A Series
Page 1: ...B 1726 7 FC6A SERIES Ladder Programming Manual ...
Page 8: ...Preface 7 FC6A SERIES MICROSMART LADDER PROGRAMMING MANUAL FC9Y B1726 ...
Page 32: ...1 OPERATION BASICS 1 20 FC6A SERIES MICROSMART LADDER PROGRAMMING MANUAL FC9Y B1726 ...
Page 96: ...3 INSTRUCTIONS REFERENCE 3 18 FC6A SERIES MICROSMART LADDER PROGRAMMING MANUAL FC9Y B1726 ...
Page 130: ...4 BASIC INSTRUCTIONS 4 34 FC6A SERIES MICROSMART LADDER PROGRAMMING MANUAL FC9Y B1726 ...
Page 192: ...9 SHIFT ROTATE INSTRUCTIONS 9 12 FC6A SERIES MICROSMART LADDER PROGRAMMING MANUAL FC9Y B1726 ...
Page 272: ...12 DISPLAY INSTRUCTIONS 12 24 FC6A SERIES MICROSMART LADDER PROGRAMMING MANUAL FC9Y B1726 ...
Page 284: ...14 REFRESH INSTRUCTIONS 14 6 FC6A SERIES MICROSMART LADDER PROGRAMMING MANUAL FC9Y B1726 ...
Page 502: ...25 DATA LOG INSTRUCTIONS 25 22 FC6A SERIES MICROSMART LADDER PROGRAMMING MANUAL FC9Y B1726 ...
Page 546: ...26 SCRIPT 26 44 FC6A SERIES MICROSMART LADDER PROGRAMMING MANUAL FC9Y B1726 ...
Page 598: ...APPENDIX A 14 FC6A SERIES MICROSMART LADDER PROGRAMMING MANUAL FC9Y B1726 ...