Home
Mitsubishi Electric
Controller
MELSEC iQ-R Series
Programming Manual
Page 1873
Mitsubishi Electric MELSEC iQ-R Series - Page 1873
2110 pages
Manual
To Next Page
To Next Page
To Previous Page
To Previous Page
Loading...
25 TYPE CONVERSION FUNCTIONS
25.56 Converting STRING to INT
1871
25
Oper
ation e
rror
Error code
(SD0)
Description
3401H
An out-of-ran
ge value
is in
put to (s
).
•
ASC
II code: oth
er tha
n 30H to 39
H, 20H
, and 00H
•
STRIN
G data
type valu
e: othe
r than -3
2768 t
o 3276
7
1872
1874
Table of Contents
Main Page
Default Chapter
3
Conditions of Use for the Product
3
Safety Precautions
3
Introduction
5
Table of Contents
6
Relevant Manuals
25
Terms
26
Manual Page Organization
29
Chapter 1 Overview
35
Part 1 Overview
35
Instruction Configuration
36
Data Specification Method
38
Bit Data
42
16-Bit Data (Word Data)
44
32-Bit Data (Double Word Data)
47
Real Number Data (Floating-Point Data)
50
String Data
53
Execution Condition
55
High-Speed Instruction Processing
56
Subset Processing
56
Checking the Ranges of Instruction Runtime Devices and Labels
57
Errors Common to Instructions
57
Precautions on Programming
57
Operation When a Long Timer or Long Retentive Timer Device Is Used
59
Operations Arising When the OUT, SET/RST, and PLS/PLF Instructions of the same Device Are Used
61
Restrictions on Using File Registers
67
Part 2 Lists of Instructions and Fun/Fb
69
Chapter 2 Cpu Module Instructions
70
Sequence Instructions
70
Basic Instructions
74
Application Instructions
93
Built-In Ethernet Function Instructions
120
PID Control Instructions
122
PID Operation Instruction
122
Process Control Instructions
124
Multiple CPU Dedicated Instructions
129
SFC Program Instructions
130
Redundant System Instructions
132
Chapter 3 Module Dedicated Instructions
133
Network Common Instructions
133
Ethernet Instructions
135
CC-Link IE Controller Network Instructions
137
CC-Link IE Field Network Instructions
139
CC-Link Instructions
141
Serial Communication Instructions
142
A/D Conversion Instructions
144
Positioning Instructions
145
High Speed Data Logger Module Instructions
146
C Intelligent Function Module Instructions
147
Chapter 4 Standard Functions/Function Blocks
148
Standard Functions
148
Standard Function Flocks
159
Part 3 Cpu Module Instructions
161
Chapter 5 Sequence Instructions
162
Contact Instructions
162
Operation Start, Series Connection, Parallel Connection
162
Pulse Operation Start, Pulse Series Connection, Pulse Parallel Connection
164
Pulse NOT Operation Start, Pulse NOT Series Connection, Pulse NOT Parallel Connection
167
Association Instructions
170
Ladder Block Series/Parallel Connection
170
Storing/Reading/Clearing the Operation Result
171
Inverting the Operation Result
173
Converting the Operation Result into a Pulse
174
Converting the Edge Relay Operation Result into a Pulse
175
Out (Excluding the Timer, Counter, and Annunciator)
177
Output Instructions
177
Timer
179
Long Timer
183
Counter
186
Long Counter
188
Annunciator
190
Setting Devices (Excluding Annunciator)
191
Resetting Devices (Excluding Annunciator)
193
Setting Annunciator
195
Resetting Annunciator
197
Rising Edge Output
199
Falling Edge Output
201
Inverting the Bit Device Output
203
Converting the Direct Access Output into a Pulse
205
Shift Instructions
207
Shifting Bit Devices
207
Master Control Instructions
209
Setting/Resetting a Master Control
209
Ending the Main Routine Program
213
Termination Instructions
213
Ending the Sequence Program
215
Stop Instruction
217
Stopping the Sequence Program
217
No Operation (NOP)
218
No Operation Instruction
218
No Operation (NOPLF)
219
Chapter 6 Basic Instructions
220
Comparing 16-Bit Binary Data
220
Comparison Operation Instructions
220
Comparing 32-Bit Binary Data
222
Outputting a Comparison Result of 16-Bit Binary Data
224
Outputting a Comparison Result of 32-Bit Binary Data
226
Outputting a Band Comparison Result of 16-Bit Binary Data
228
Outputting a Band Comparison Result of 32-Bit Binary Data
230
Comparing 16-Bit Binary Block Data
232
Comparing 32-Bit Binary Block Data
234
Adding 16-Bit Binary Data
237
Arithmetic Operation Instructions
237
Subtracting 16-Bit Binary Data
241
Adding 32-Bit Binary Data
245
Subtracting 32-Bit Binary Data
249
Multiplying 16-Bit Binary Data
253
Dividing 16-Bit Binary Data
255
Multiplying 32-Bit Binary Data
257
Dividing 32-Bit Binary Data
259
Adding BCD 4-Digit Data
261
Subtracting BCD 4-Digit Data
264
Adding BCD 8-Digit Data
268
Subtracting BCD 8-Digit Data
272
Multiplying BCD 4-Digit Data
276
Dividing BCD 4-Digit Data
278
Multiplying BCD 8-Digit Data
280
Dividing BCD 8-Digit Data
282
Adding 16-Bit Binary Block Data
284
Subtracting 16-Bit Binary Block Data
286
Adding 32-Bit Binary Block Data
288
Subtracting 32-Bit Binary Block Data
291
Incrementing 16-Bit Binary Data
294
Decrementing 16-Bit Binary Data
296
Incrementing 32-Bit Binary Data
298
Decrementing 32-Bit Binary Data
300
Logical Operation Instructions
302
Performing an and Operation on 16-Bit Data
302
Performing an and Operation on 32-Bit Data
306
Performing an and Operation on 16-Bit Block Data
310
Performing an or Operation on 16-Bit Data
312
Performing an or Operation on 32-Bit Data
316
Performing an or Operation on 16-Bit Block Data
320
Performing an XOR Operation on 16-Bit Data
322
Performing an XOR Operation on 32-Bit Data
326
Performing an XOR Operation on 16-Bit Block Data
330
Performing an XNOR Operation on 16-Bit Data
332
Performing an XNOR Operation on 32-Bit Data
336
Performing an XNOR Operation on 16-Bit Block Data
340
Bit Processing Instructions
342
Setting a Bit in the Word Device
342
Resetting a Bit in the Word Device
344
Performing a 16-Bit Test
346
Performing a 32-Bit Test
348
Batch-Resetting Bit Devices
350
Shift Instructions
352
Shifting 16-Bit Binary Data to the Right by N Bit(S)
352
Shifting 16-Bit Binary Data to the Left by N Bit(S)
354
Shifting N-Bit Data to the Right by One Bit
356
Shifting N-Bit Data to the Left by One Bit
358
Shifting N-Word Data to the Right by One Word
360
Shifting N-Word Data to the Left by One Word
362
Shifting N-Bit Data to the Right by N Bit(S)
364
Shifting N-Bit Data to the Left by N Bit(S)
368
Shifting N-Word Data to the Right by N Word(S)
372
Shifting N-Word Data to the Left by N Word(S)
376
Converting Binary Data to BCD 4-Digit Data
380
Data Conversion Instructions
380
Converting Binary Data to BCD 8-Digit Data
382
Converting BCD 4-Digit Data to 16-Bit Binary Data
384
Converting BCD 8-Digit Data to 32-Bit Binary Data
386
Converting Single-Precision Real Number to 16-Bit Signed Binary Data
388
Converting Single-Precision Real Number to 16-Bit Unsigned Binary Data
390
Converting Single-Precision Real Number to 32-Bit Signed Binary Data
392
Converting Single-Precision Real Number to 32-Bit Unsigned Binary Data
394
Converting Double-Precision Real Number to 16-Bit Signed Binary Data
396
Converting Double-Precision Real Number to 16-Bit Unsigned Binary Data
398
Converting Double-Precision Real Number to 32-Bit Signed Binary Data
400
Converting Double-Precision Real Number to 32-Bit Unsigned Binary Data
402
Converting 16-Bit Signed Binary Data to 16-Bit Unsigned Binary Data
404
Converting 16-Bit Signed Binary Data to 32-Bit Signed Binary Data
406
Converting 16-Bit Signed Binary Data to 32-Bit Unsigned Binary Data
408
Converting 16-Bit Unsigned Binary Data to 16-Bit Signed Binary Data
410
Converting 16-Bit Unsigned Binary Data to 32-Bit Signed Binary Data
412
Converting 16-Bit Unsigned Binary Data to 32-Bit Unsigned Binary Data
414
Converting 32-Bit Signed Binary Data to 16-Bit Signed Binary Data
416
Converting 32-Bit Signed Binary Data to 16-Bit Unsigned Binary Data
418
Converting 32-Bit Signed Binary Data to 32-Bit Unsigned Binary Data
420
Converting 32-Bit Unsigned Binary Data to 16-Bit Signed Binary Data
422
Converting 32-Bit Unsigned Binary Data to 16-Bit Unsigned Binary Data
424
Converting 32-Bit Unsigned Binary Data to 32-Bit Signed Binary Data
426
Converting 16-Bit Binary Data to Gray Code Data
428
Converting 32-Bit Binary Data to Gray Code Data
430
Converting 16-Bit Binary Gray Code Data to 16-Bit Binary Data
432
Converting 32-Bit Binary Gray Code Data to 32-Bit Binary Data
434
Converting 16-Bit Binary Data Block to BCD 4-Digit Data Block
436
Converting BCD 4-Digit Block Data to 16-Bit Binary Block Data
438
Converting Decimal ASCII Data to 16-Bit Binary Data
440
Converting Decimal ASCII Data to 32-Bit Binary Data
443
Converting Hexadecimal ASCII Data to 16-Bit Binary Data
447
Converting Hexadecimal ASCII Data to 32-Bit Binary Data
450
Converting Decimal ASCII Data to BCD 4-Digit Data
453
Converting Decimal ASCII Data to BCD 8-Digit Data
456
Converting Decimal String Data to 16-Bit Binary Data
459
Converting Decimal String Data to 32-Bit Binary Data
462
Converting Hexadecimal ASCII to Hexadecimal Binary Data
465
Converting Single-Precision Real Number to BCD Format Data
467
Two's Complement of 16-Bit Binary Data (Sign Inversion)
469
Two's Complement of 32-Bit Binary Data (Sign Inversion)
471
Decoding 8-Bit Data to 256-Bit Data
473
Encoding 256-Bit Data to 8-Bit Data
475
Decoding Data to Seven-Segment Display Data
477
Separating Data in Units of 4 Bits
480
Combining Data in Units of 4 Bits
482
Separating Data in Units of Bits
484
Combining Data in Units of Bits
486
Separating Data in Units of Bytes
488
Combining Data in Units of Bytes
490
Data Transfer Instructions
492
Transferring 16-Bit Binary Data
492
Transferring 32-Bit Binary Data
494
Inverting and Transferring 16-Bit Binary Data
496
Inverting and Transferring 32-Bit Binary Data
498
Shifting Data in Units of 4 Bits
500
Inverting and Transferring 1-Bit Data
503
Transferring 16-Bit Binary Data Block (16 Bits)
505
Transferring 16-Bit Binary Data Block (32 Bits)
507
Transferring the same 16-Bit Binary Data Block (16 Bits)
509
Transferring the same 16-Bit Binary Data Block (32 Bits)
511
Transferring the same 32-Bit Binary Data Block (16 Bits)
513
Transferring the same 32-Bit Binary Data Block (32 Bits)
515
Exchanging 16-Bit Binary Data
517
Exchanging 32-Bit Binary Data
519
Exchanging 16-Bit Binary Block Data
521
Exchanging the Upper and Lower Bytes of 16-Bit Binary Data
523
Exchanging the Upper and Lower Bytes of 32-Bit Binary Data
524
Transferring 1-Bit Data
525
Transferring N-Bit Data
527
Chapter 7 Application Instructions
529
Rotating 16-Bit Binary Data to the Right
529
Rotation Instructions
529
Rotating 16-Bit Binary Data to the Left
532
Rotating 32-Bit Binary Data to the Right
535
Rotating 32-Bit Binary Data to the Left
537
Pointer Branch
539
Program Branch Instructions
539
Jumping to END
542
Disabling/Enabling Interrupt Programs
543
Program Execution Control Instructions
543
Disabling Interrupt Programs with Specified Priority or Lower
546
Interrupt Program Mask
551
Disabling/Enabling the Specified Interrupt Pointer
553
Returning from the Interrupt Program
555
Resetting the Watchdog Timer
556
Performing the for to NEXT Instruction Loop
557
Structure Creation Instructions
557
Forcibly Terminating the for to NEXT Instruction Loop
559
Calling a Subroutine Program
561
Returning from the Subroutine Program Called
565
Calling a Subroutine Program and Turning the Output off
566
Calling a Subroutine Program in the Specified Program File
570
Calling a Subroutine Program in the Specified Program File and Turning the Output off
575
Calling a Subroutine Program
580
Data Table Operation Instructions
585
Reading the Oldest Data from the Data Table
585
Reading the Newest Data from the Data Table
587
Writing Data to the Data Table
589
Inserting Data to the Data Table
591
Deleting Data from Data Table
593
Reading/Writing Data Instructions
595
Reading Data from the Data Memory
596
Writing Data to the Data Memory
598
Reading Data from the Specified File
601
Writing Data to the Specified File
618
Debugging and Failure Diagnostic Instructions
630
Resetting the Error Display and the Annunciator Display
630
Generating a Continuation Error
631
Generating a Stop Error
632
Comparing String Data
633
String Processing Instructions
633
Concatenating String Data
636
Transferring String Data
640
Transferring Unicode String Data
642
Converting 16-Bit Binary Data to Decimal ASCII
644
Converting 32-Bit Binary Data to Decimal ASCII
648
Converting 16-Bit Binary Data to Hexadecimal ASCII
653
Converting 32-Bit Binary Data to Hexadecimal ASCII
657
Converting 16-Bit Binary Data to String Data
661
Converting 32-Bit Binary Data to String Data
664
Converting BCD 4-Digit Data to Decimal ASCII Code
667
Converting BCD 8-Digit Data to Decimal ASCII Code
671
Converting Single-Precision Real Number to String Data
676
Converting Hexadecimal Binary Data to Hexadecimal ASCII Code
681
Converting Unicode Character String to Shift JIS Character String
683
Converting Shift JIS Character String to Unicode Character String (Without Byte Order Mark)
685
Converting Shift JIS Character String to Unicode (with Byte Order Mark)
687
Detecting a String Length
689
Extracting String Data from the Right
691
Extracting String Data from the Left
693
Extracting the Specified String Data
695
Replacing the Specified String Data
697
Searching String Data
700
Inserting String Data
702
Deleting String Data
704
Comparing Single-Precision Real Numbers
706
Real Number Instructions
706
Comparing Double-Precision Real Numbers
708
Outputting a Comparison Result of Single-Precision Real Numbers
711
Outputting a Comparison Result of Double-Precision Real Numbers
713
Outputting a Band Comparison Result of Single-Precision Real Number
715
Outputting a Band Comparison Result of Double-Precision Real Number
717
Adding Single-Precision Real Numbers
719
Subtracting Single-Precision Real Numbers
723
Adding Double-Precision Real Numbers
727
Subtracting Double-Precision Real Numbers
731
Multiplying Single-Precision Real Numbers
735
Dividing Single-Precision Real Numbers
737
Multiplying Double-Precision Real Numbers
739
Dividing Double-Precision Real Numbers
741
Converting 16-Bit Signed Binary Data to Single-Precision Real Number
743
Converting 16-Bit Unsigned Binary Data to Single-Precision Real Number
745
Converting 32-Bit Signed Binary Data to Single-Precision Real Number
747
Converting 32-Bit Unsigned Binary Data to Single-Precision Real Number
749
Converting Double-Precision Real Number to Single-Precision Real Number
751
Converting 16-Bit Signed Binary Data to Double-Precision Real Number
753
Converting 16-Bit Unsigned Binary Data to Double-Precision Real Number
755
Converting 32-Bit Signed Binary Data to Double-Precision Real Number
757
Converting 32-Bit Unsigned Binary Data to Double-Precision Real Number
759
Converting Single-Precision Real Number to Double-Precision Real Number
761
Converting String Data to Single-Precision Real Number
763
Converting BCD Format Data to Single-Precision Real Number
767
Inverting the Sign of Single-Precision Real Number
769
Inverting the Sign of Double-Precision Real Number
770
Transferring Single-Precision Real Number
771
Transferring Double-Precision Real Number
772
Calculating the Sine of Single-Precision Real Number
773
Calculating the Cosine of Single-Precision Real Number
775
Calculating the Tangent of Single-Precision Real Number
777
Calculating the Arc Sine of Single-Precision Real Number
779
Calculating the Arc Cosine of Single-Precision Real Number
781
Calculating the Arc Tangent of Single-Precision Real Number
783
Calculating the Sine of Double-Precision Real Number
785
Calculating the Cosine of Double-Precision Real Number
787
Calculating the Tangent of Double-Precision Real Number
789
Calculating the Arc Sine of Double-Precision Real Number
791
Calculating the Arc Cosine of Double-Precision Real Number
793
Calculating the Arc Tangent of Double-Precision Real Number
795
Calculating the Sine of BCD Data
797
Calculating the Cosine of BCD Data
799
Calculating the Tangent of BCD Data
801
Calculating the Arc Sine of BCD Data
803
Calculating the Arc Cosine of BCD Data
805
Calculating the Arc Tangent of BCD Data
807
Converting Single-Precision Real Number Angle to Radian
809
Converting Single-Precision Real Number Radian to Angle
811
Converting Double-Precision Real Number Angle to Radian
813
Converting Double-Precision Real Number Radian to Angle
815
Calculating the Square Root of Single-Precision Real Number
817
Calculating the Square Root of Double-Precision Real Number
819
Calculating the Exponent of Single-Precision Real Number
821
Calculating the Exponent of Double-Precision Real Number
823
Calculating the Natural Logarithm of Single-Precision Real Number
825
Calculating the Natural Logarithm of Double-Precision Real Number
827
Calculating the Square Root of BCD 4-Digit Data
829
Calculating the Square Root of BCD 8-Digit Data
831
Calculating the Exponentiation of Single-Precision Real Number
833
Calculating the Exponentiation of Double-Precision Real Number
835
Calculating the Common Logarithm of Single-Precision Real Number
837
Calculating the Common Logarithm of Double-Precision Real Number
839
Searching the Maximum Value of Single-Precision Real Number
841
Searching the Maximum Value of Double-Precision Real Number
843
Searching the Minimum Value of Single-Precision Real Number
845
Searching the Minimum Value of Double-Precision Real Number
847
Generating Random Number
849
Random Number Instructions
849
Changing Random Sequence
850
Index Register Instructions
851
Saving All Data of the Index Register
851
Returning All Data of the Index Register
853
Saving the Selected Data of the Index Register and Long Index Register
854
Returning the Selected Data of the Index Register and Long Index Register
857
Data Control Instructions
859
Upper and Lower Limit Control of 16-Bit Binary Data
859
Upper and Lower Limit Control of 32-Bit Binary Data
861
Dead Band Control of 16-Bit Binary Data
863
Dead Band Control of 32-Bit Binary Data
865
Zone Control of 16-Bit Binary Data
867
Zone Control of 32-Bit Binary Data
869
Scaling 16-Bit Binary Data (Point Coordinates)
871
Scaling 32-Bit Binary Data (Point Coordinates)
874
Scaling 16-Bit Binary Data (XY Coordinates)
877
Scaling 32-Bit Binary Data (XY Coordinates)
879
Counting up or down the Current Value (1-Phase Input)
881
Special Counter Instructions
881
Counting up or down the Current Value (2-Phase Input)
883
Special Timer Instructions
885
Teaching Timer
885
Special Function Timer
887
Rotary Table Shortest Direction Control
890
Shortcut Control Instruction
890
Ramp Signal
893
Ramp Signal Instruction
893
Measuring the Density of Pulses
896
Pulse Related Instructions
896
Outputting Pulses at Regular Intervals
898
Performing the Pulse Width Modulation
900
Matrix Input
902
Matrix Input Instruction
902
Check Code
905
Check Code Instructions
905
Data Processing Instructions
908
Searching 16-Bit Binary Data
908
Searching 32-Bit Binary Data
910
Searching 16-Bit Binary Data (Minimum, Match, Maximum)
912
Searching 32-Bit Binary Data (Minimum, Match, Maximum)
914
Checking 16-Bit Binary Data
916
Checking 32-Bit Binary Data
918
Checking the Bit Status in 16-Bit Binary Data
920
Checking the Bit Status in 32-Bit Binary Data
922
Searching the Maximum Value of 16-Bit Binary Data
924
Searching the Maximum Value of 32-Bit Binary Data
926
Searching the Minimum Value of 16-Bit Binary Data
928
Searching the Minimum Value of 32-Bit Binary Data
930
Sorting 16-Bit Binary Data
932
Sorting 32-Bit Binary Data
934
Adding 16-Bit Binary Data
936
Adding 32-Bit Binary Data
938
Calculating the Mean Value of 16-Bit Binary Data
940
Calculating the Mean Value of 32-Bit Binary Data
942
Calculating the Square Root of 16-Bit Binary Data
944
Calculating the Square Root of 32-Bit Binary Data
945
CRC Operation
946
Database Access Instructions
948
Importing Data to the Data Base
948
Exporting Data from the Data Base
951
Opening the Data Base
954
Closing the Data Base
956
Adding a Record to the Data Base
958
Updating the Record in the Data Base
964
Searching the Record in the Data Base
970
Deleting the Record in the Data Base
978
Starting a Transaction
982
Committing a Transaction
984
Performing a Database Rollback
986
Error Codes Related to Database Access Instructions
988
File Register Operation Instructions
993
Switching the File Register Block Number
993
Changing the File Register File Name
995
File Register Read/Write Instructions
997
Reading 1-Byte Data from the File Register
997
Writing 1-Byte Data to the File Register
999
Indirect Address Read Instructions
1001
Reading the Indirect Address
1001
Clock Instructions
1003
Reading Clock Data
1003
Writing Clock Data
1005
Adding Clock Data
1007
Subtracting Clock Data
1009
Converting Time Data from Hour/Minute/Second to Second
1011
Converting Time Data from Second to Hour/Minute/Second
1013
Comparing Date Data
1015
Comparing Time Data
1019
Outputting a Comparison Result of Time Data
1023
Outputting a Band Comparison Result of Time Data
1025
Reading Expansion Clock Data
1027
Adding Expansion Clock Data
1029
Subtracting Expansion Clock Data
1031
Generating Timing Pulses
1033
Timing Check Instructions
1033
Measuring Time of the Specified Data
1035
Hour Meter
1037
Module Access Instructions
1041
Performing I/O Refresh
1041
Selecting Refresh to be Performed
1043
Performing Module Refresh
1045
Reading 1-Word/2-Word Data from Another Module (16-Bit Specification)
1047
Writing 1-Word/2-Word Data to a Module (16-Bit Specification)
1051
Reading 1-Word/2-Word Data from Another Module (32-Bit Specification)
1056
Writing 1-Word/2-Word Data to a Module (32-Bit Specification)
1060
Reading the Module Model Name
1065
Reading Module Specific Information
1069
Reading Routing Information
1074
Routing Information Instructions
1074
Registering Routing Information
1076
Logging Instructions
1078
Setting Trigger Logging
1078
Resetting Trigger Logging
1080
Changing the Program Execution Type to Standby Type
1081
Program Control Instructions
1081
Changing the Program Execution Type to Standby Type (Output Off)
1083
Changing the Program Execution Type to Scan Execution Type
1085
Chapter 8 Built-In Ethernet Function Instructions
1087
Open/Close Processing Instructions
1087
Opening a Connection
1087
Closing a Connection
1090
Reading Receive Data During the END Processing
1092
Socket Communications Instructions
1092
Reading Receive Data When the Instruction Is Executed
1095
Sending Data
1098
Reading Connection Information
1101
Changing the Communication Target (UDP/IP)
1103
Changing the Receive Mode
1105
Reading Socket Communications Receive Data
1109
Executing the Registered Protocols
1111
Predefined Protocol Support Function Instruction
1111
Sending an SLMP Frame
1119
SLMP Frame Send Instruction
1119
File Transfer Function Instructions
1125
Sending FTP Client Files
1125
Retrieving FTP Client Files
1130
Chapter 9 Pid Operation Instruction
1136
Overview
1136
Control Data
1138
Auto Tuning
1145
PID Operation Instruction
1147
Chapter 10 Pid Control Instructions
1151
Operation Method
1151
Overview
1151
PID Control Procedure
1152
Helpful Functions
1158
PID Control Instructions (Inexact Differential)
1160
Registering the PID Control Data to the CPU Module
1162
Performing PID Operation
1165
Stopping the Operation of Specified Loop Number
1168
Starting the Operation of Specified Loop Number
1169
Changing the Parameters of Specified Loop Number
1170
PID Control Instructions (Exact Differential)
1172
Registering the PID Control Data to the CPU Module
1174
Performing PID Operation
1176
Stopping the Operation of Specified Loop Number
1179
Starting the Operation of Specified Loop Number
1180
Changing the Parameters of Specified Loop Number
1181
Basic Loop Types
1183
Chapter 11 Process Control Instructions
1183
Overview
1183
Process Control Instructions and Data Configuration
1185
Data Used by Process Control Instructions
1188
Loop Tag Memory Assignments
1191
How to Execute Process Control Instructions
1194
Execution Condition Switching
1196
Tracking
1196
Precautions
1198
Analog Input Processing
1199
I/O Control Instructions
1199
Output Processing 1 with Mode Switching
1205
Output Processing 2 with Mode Switching
1211
Manual Output
1216
Time Proportioning
1219
Batch Counter
1225
Pulse Integration
1229
Basic PID Control
1234
Control Operation Instructions
1234
Two-Degree-Of-Freedom PID Control
1241
Position Type PID Control
1248
Sample PI Control
1256
I-PD Control
1264
Blend PI Control
1271
Ratio Calculation
1278
Upper/Lower Limit Alarm
1283
Lead-Lag Compensation
1289
Integral Control
1292
Derivative Control
1294
Dead Time
1297
High Selector
1301
Low Selector
1303
Middle Value Selector
1305
Average Value Calculation
1308
Upper/Lower Limiter
1310
Variation Rate Limiter 1
1313
Variation Rate Limiter 2
1316
Two-Position (On/Off) Control
1319
Three-Position (On/Off) Control
1325
Dead Band
1332
Program Setter
1334
Loop Selector
1340
Bumpless Transfer
1346
Analog Memory
1349
Correction Operation Instructions
1352
Function Generator
1352
Inverse Function Generator
1355
Standard Filter
1358
Integration
1361
Temperature/Pressure Correction
1363
Engineering Value Transformation
1366
Engineering Value Inverse Transformation
1368
Addition
1370
Arithmetic Operation Instructions
1370
Subtraction
1372
Multiplication
1374
Division
1376
Square Root
1378
Absolute Value
1380
Comparing Data
1382
Comparison Operation Instructions
1382
Auto Tuning
1392
Auto Tuning Instructions
1395
Another CPU Module Access Instructions
1403
Chapter 12 Multiple Cpu Dedicated Instructions
1403
Reading Device Data from Another CPU Module
1407
Writing Device Data to Another CPU Module
1410
Chapter 13 Sfc Program Instructions
1413
Checking the Status of a Step
1413
SFC Control Instructions
1413
Checking the Status of a Block
1416
Batch-Reading the Status of Steps
1418
Starting a Block
1427
Ending a Block
1429
Pausing a Block
1431
Restarting a Block
1433
Activating a Step
1435
Deactivating a Step
1437
Switching a Target Block
1439
Creating a Dummy Transition Condition
1441
SFC Dedicated Instruction
1441
Chapter 14 Redundant System Instructions
1442
System Switching
1442
Disabling/Enabling System Switching
1446
Part 4 Module Dedicated Instructions
1449
Chapter 15 Network Common Instructions
1450
Link Dedicated Instructions
1456
Reading Data from the Programmable Controller on Another Station
1456
Reading Data from the Programmable Controller on Another Station (with Notification)
1463
Writing Data to the Programmable Controller on Another Station
1471
Writing Data to the Programmable Controller on Another Station (with Notification)
1479
Sending Data to the Programmable Controller on Another Station
1487
Receiving Data from the Programmable Controller on Another Station
1494
Receiving Data from the Programmable Controller on Another Station (for Interrupt Programs)
1499
Reading Data from the Programmable Controller (Q Series-Compatible)
1503
Writing Data to the Programmable Controller (Q Series-Compatible)
1508
Remote RUN/STOP
1513
Reading/Writing Clock Data
1520
CC-Link Dedicated Instructions
1527
Reading Data from the Target Station
1527
Writing Data to the Target Station
1532
Chapter 16 Ethernet Instructions
1537
Open/Close Processing Instructions
1537
Opening a Connection
1537
Closing a Connection
1541
Opening a Connection
1543
Closing a Connection
1547
Reading Receive Data
1550
Socket Communications Instructions
1550
Reading Receive Data (for Interrupt Programs)
1552
Sending Data
1554
Fixed Buffer Communications Instructions
1556
Reading Receive Data
1556
Reading Receive Data (for Interrupt Programs)
1559
Sending Data
1561
Reinitializing the Module
1564
Executing the Protocols Registered for the Predefined Protocol Support Function
1568
Clearing Error Information
1573
Reading Error Information
1576
Chapter 17 CC-Link Ie Controller Network Instructions
1578
Remote RUN
1578
Remote STOP
1583
Reading Clock Data from the Programmable Controller on Another Station
1588
Writing Clock Data to the Programmable Controller on Another Station
1593
Setting the Station Number to Own Station
1599
Chapter 18 CC-Link Ie Field Network Instructions
1602
Reading Data from the Intelligent Device Station/Remote Device Station (16-Bit Address Specified)
1602
Writing Data to the Intelligent Device Station/Remote Device Station (16-Bit Address Specified)
1607
Reading Data from the Intelligent Device Station/Remote Device Station (32-Bit Address Specified)
1612
Writing Data to the Intelligent Device Station/Remote Device Station (32-Bit Address Specified)
1617
Reading the Module Model Information of an Intelligent Device Station
1622
Reading the Module Status Information of an Intelligent Device Station
1626
Setting Parameters
1631
Setting the Station Number to Own Station
1637
Sending an SLMP Frame
1640
Chapter 19 CC-Link Instructions
1645
Reading Data from the Target Station
1645
Writing Data to the Target Station
1649
Reading Data from the Buffer Memory of the Specified Intelligent Device Station
1653
Writing Data to the Buffer Memory of the Specified Intelligent Device Station
1656
Reading Data from the Automatic Update Buffer
1659
Writing Data to the Automatic Update Buffer
1661
Setting Network Parameters
1663
Performing a Message Transmission to a Remote Device Station
1669
Chapter 20 Serial Communication Instructions
1675
Sending Data Using the On-Demand Function
1675
Executing the Protocols Registered for the Predefined Protocol Support Function
1679
Sending Data Using the Nonprocedural Protocol
1684
Receiving Data Using the Nonprocedural Protocol
1687
Sending Data Using the Bidirectional Protocol
1690
Receiving Data Using the Bidirectional Protocol
1693
Reading the Data Send/Receive Status
1696
Receiving Data Using an Interrupt Program
1698
Sending Data by Using User Frames
1701
Clearing Receive Data
1704
Registering/Canceling the Programmable Controller CPU Monitoring
1707
Initial Setting
1712
Registering User Frames
1716
Reading User Frames
1719
Switching the Mode
1723
Chapter 21 A/D Conversion Instructions
1726
Switching the Mode
1726
Reading the User Range Setting Values
1729
Restoring the User Range Setting Values
1748
Chapter 22 Positioning Instructions
1767
Restoring the Absolute Position
1767
Starting the Positioning
1771
Teaching
1774
Backing up Module Data (Writing Data to the Flash ROM)
1777
Initializing the Module
1780
CHAPTER 23 High Speed Data Logger Module Instructions
1783
File Access Instructions
1783
Recipe Write
1783
Recipe Read
1786
Chapter 24 C Intelligent Function Module Instructions
1789
User Function Execution Instruction
1789
Part 5 Standard Functions
1793
Chapter 25 Type Conversion Functions
1794
Converting BOOL to WORD
1794
Converting BOOL to DWORD
1796
Converting BOOL to INT
1797
Converting BOOL to DINT
1798
Converting BOOL to TIME
1799
Converting BOOL to STRING
1800
Converting WORD to BOOL
1801
Converting WORD to DWORD
1802
Converting WORD to INT
1803
Converting WORD to DINT
1804
Converting WORD to TIME
1806
Converting WORD to STRING
1807
Converting DWORD to BOOL
1808
Converting DWORD to WORD
1809
Converting DWORD to INT
1811
Converting DWORD to DINT
1813
Converting DWORD to TIME
1814
Converting DWORD to STRING
1815
Converting INT to BOOL
1816
Converting INT to WORD
1817
Converting INT to DWORD
1818
Converting INT to DINT
1820
Converting INT to BCD
1821
Converting INT to REAL
1823
Converting INT to LREAL
1824
Converting INT to TIME
1825
Converting INT to STRING
1826
Converting DINT to BOOL
1828
Converting DINT to WORD
1829
Converting DINT to DWORD
1831
Converting DINT to INT
1832
Converting DINT to BCD
1833
Converting DINT to REAL
1835
Converting DINT to LREAL
1836
Converting DINT to TIME
1837
Converting DINT to STRING
1838
Converting BCD to INT
1840
Converting BCD to DINT
1842
Converting BCD to STRING
1845
Converting REAL to INT
1847
Converting REAL to DINT
1849
Converting REAL to LREAL
1851
Converting REAL to STRING
1853
Converting LREAL to INT
1856
Converting LREAL to DINT
1858
Converting LREAL to REAL
1860
Converting TIME to BOOL
1862
Converting TIME to WORD
1863
Converting TIME to DWORD
1864
Converting TIME to INT
1865
Converting TIME to DINT
1866
Converting TIME to STRING
1867
Converting STRING to BOOL
1869
Converting STRING to WORD
1870
Converting STRING to DWORD
1871
Converting STRING to INT
1872
Converting STRING to DINT
1874
Converting STRING to BCD
1876
Converting STRING to REAL
1878
Converting STRING to TIME
1881
Converting Bit Array to INT
1883
Converting Bit Array to DINT
1884
Converting INT to Bit Array
1885
Converting DINT to Bit Array
1886
Copying the Bit Array
1887
Reading the Specified Bit of the Word Label
1888
Writing the Specified Bit of the Word Label
1890
Copying the Specified Bit of the Word Label
1892
Getting the Start Data
1894
Calculating the Absolute Value
1895
Chapter 26 Single Variable Functions
1895
Calculating the Square Root
1897
Calculating the Natural Logarithm
1898
Calculating the Common Logarithm
1899
Calculating the Exponent
1901
Calculating the Sine
1902
Calculating the Cosine
1903
Calculating the Tangent
1904
Calculating the Arc Sine
1905
Calculating the Arc Cosine
1906
Calculating the Arc Tangent
1907
Addition
1908
Chapter 27 Arithmetic Operation Functions
1908
Multiplication
1910
Subtraction
1912
Division
1914
Remainder
1916
Exponentiation
1918
Assignment (Move Operation)
1919
Chapter 28 Bit Shift Functions
1921
Shifting Data to the Left by N Bit(S)
1921
Shifting Data to the Right by N Bit(S)
1923
Rotating Data to the Left by N Bit(S)
1925
Rotating Data to the Right by N Bit(S)
1927
AND Operation, or Operation, and XOR Operation
1929
Chapter 29 Boolean Functions
1929
NOT Operation
1932
Chapter 30 Selection Functions
1933
Selecting a Value
1933
Selecting the Maximum/Minimum Value
1935
Controlling the Upper/Lower Limit
1937
Multiplexer
1940
Chapter 31 Comparison Functions
1942
Comparing Data
1942
31.2 Comparing Data
1944
Chapter 32 String Functions
1946
Detecting a String Length
1946
Extracting String Data from the Left/Right
1948
Extracting String Data
1951
Concatenating String Data
1953
Inserting String Data
1955
Deleting String Data
1957
Replacing String Data
1959
Searching String Data
1962
Addition
1964
Chapter 33 Time Data Type Functions
1964
Subtraction
1966
Multiplication
1968
Division
1970
Part 6 Standard Function Blocks
1973
Bistable Function Block (Set-Dominant)
1974
Chapter 34 Bistable Function Blocks
1974
Bistable Function Block (Reset-Dominant)
1976
Chapter 35 Edge Detection Function Blocks
1978
Detecting a Rising Edge
1978
Detecting a Falling Edge
1980
Chapter 36 Counter/Timer Function Blocks
1982
Up Counter
1982
Down Counter
1984
Up/Down Counter
1986
Counter Function Block
1989
Pulse Timer
1991
On Delay Timer
1994
Off Delay Timer
1997
Timer Function Block
1999
Appendices
2003
Appendix 1 Instruction Processing Time
2003
Time Added to Instruction Processing Time
2032
Appendix 2 Number of Basic Steps and Availability of Subset Processing
2033
Appendix 3 Determining Three PID Constants
2058
Appendix 4 PID Operation Program Examples
2060
Auto Tuning (Step Response Method) + PID Control Program Example
2061
Auto Tuning (Step Response Method) Program Example
2063
Appendix 5 PID Control Program Examples
2065
Program Examples for PID Control in Automatic Mode
2065
Program Examples for PID Control When Switching Modes
2072
Appendix 6 Process Control Program Examples
2079
Appendix 7 List of Loop Tag Memory Areas Used by Process Control Instructions
2084
PID Control (SPID), Two-Degree-Of-Freedom PID Control (S2PID), Sample PI Control (SSPI)
2084
I-PD Control (SIPD), Blend PI Control (SBPI)
2086
Manual Output (SMOUT), Monitor (SMON)
2088
Manual Output with Monitor (SMWM), PIDP Control (SPIDP)
2089
Two-Position (On/Off) Control (SONF2), Three-Position (On/Off) Control (SONF3)
2090
Batch Counter (SBC)
2091
Ratio Control (SR)
2092
Instruction Index
2095
Revisions
2106
Warranty
2107
Trademarks
2108
Other manuals for Mitsubishi Electric MELSEC iQ-R Series
User Manual
760 pages
Reference Manual
498 pages
Configuration Manual
214 pages
Manual
126 pages
Safety Function Block Reference
124 pages
Migration Guide
84 pages
Installation Manual
40 pages
Safety Guide
258 pages
Quick Start Guide
84 pages
Introduction Guide
98 pages
Reference
60 pages
Module Function Block Reference
22 pages
Related product manuals
MELSEC iQ-R-R6SFM
1028 pages
MELSEC iQ-R-R00CPU
1028 pages
MELSEC iQ-R RD78G4
188 pages
MELSEC iQ-R-R04CPU
1028 pages
MELSEC iQ-R-R6PSFM
1028 pages
MELSEC iQ-R R60TD8-G
52 pages
MELSEC iQ-R-R04ENCPU
1028 pages
MELSEC iQ-F FX5
958 pages
MELSEC iQ-R08CPU
416 pages
MELSEC iQ-R02CPU
416 pages
MELSEC iQ-R08ENCPU
416 pages
MELSEC iQ-F Series
318 pages