background image

284

7  BASIC INSTRUCTIONS
7.5  Data Conversion Instructions

Converting binary data to BCD 8-digit data

DBCD(P)

These instructions convert the binary data in the device specified by (s) to BCD data, and store the converted data in the 
device specified by (d).
Binary data is used in operations in CPU module. Use this instruction to display numeric values on seven-segment display 
unit equipped with BCD decoder.

Setting data

Descriptions, ranges, and data types

Applicable devices

Processing details

 • These instructions convert 32-bit binary data (0 to 99999999) in device specified by (s) to BCD 8-digit data, and store the 

converted data in the device specified by (d).

Ladder diagram

Structured text

ENO:=DBCD(EN,s,d);
ENO:=DBCDP(EN,s,d);

FBD/LD

Operand

Description

Range

Data type

Data type (label)

(s)

Binary data or the head device where the binary data is 
stored

0 to 99999999

32-bit signed binary

ANY32

(d)

Head device for storing the BCD data

BCD 8-digit

ANY32

EN

Execution condition

Bit

BOOL

ENO

Execution result

Bit

BOOL

Operand

Bit

Word

Double word Indirect 

specification

Constant

Others

X, Y, M, L, SM, 
F, B, SB, S

T, ST, C, D, W, 
SD, SW, R

U

\G

Z

LC

LZ

K, H

E

$

(s)

(d)

(1): Set 0s to the upper 5 bits.

(s)

(d)

EN

ENO

d

s

(s)

(d)

BIN 99999999

0

0 0 0 1 0 1 1 1 1 1 0 1 0 1 1 1 1 0 0 0 0 0 1 1 1 1 1 1 1 1

BCD 99999999 1

0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1 1 0 0 1

8

2 1 8 4 2 1 8 4 2 1 8 4 2 1 8 4 2 1 8 4 2 1 8 4 2 1 8 4 2 1

×10

7

×10

6

×10

5

×10

4

×10

3

×10

2

×10

1

×10

0

2

31

2

30

2

29

2

28

2

27

2

26

2

25

2

24

2

23

2

22

2

21

2

20

2

19

2

18

2

17

2

16

2

15

2

14

2

13

2

12

2

11

2

10

2

9

2

8

2

7

2

6

2

5

2

4

2

3

2

2

2

1

2

0

(s)+1 (Upper 16 bits)

(s) (Lower 16 bits)

(d)+1 (Upper 4 digits)

(d) (Lower 4 digits)

(1)

BCD

Summary of Contents for MELSEC iQ-F FX5

Page 1: ...MELSEC iQ F FX5 Programming Manual Instructions Standard Functions Function Blocks ...

Page 2: ......

Page 3: ...r special purposes such as nuclear power electric power aerospace medicine or passenger movement vehicles consult with Mitsubishi Electric This product has been manufactured under strict quality control However when installing the product where major accidents or losses could occur if the product fails install appropriate backup or failsafe functions in the system Note If in doubt at any stage dur...

Page 4: ...ions of the Same Device are Used 39 2 4 Standard Function Function Block Return Values 44 PART 2 INSTRUCTION FUNCTION LIST CHAPTER 3 CPU MODULE INSTRUCTION 46 3 1 Sequence Instruction 46 3 2 Basic Instruction 50 3 3 Application Instruction 64 3 4 Step Ladder Instructions 83 3 5 Built in Ethernet Function Instructions 84 3 6 PID Control Instruction 84 CHAPTER 4 MODULE SPECIFIC INSTRUCTION 85 4 1 Ne...

Page 5: ...ing reading clearing the operation result 111 Inverting the operation result 112 Converting the operation result into a pulse 113 6 3 Output Instructions 114 Out excluding the timer counter and annunciator 114 Timer 115 Counter 117 Long counter 118 Annunciator 120 Setting devices excluding annunciator 121 Resetting devices excluding annunciator 123 Setting annunciator 125 Resetting annunciator 127...

Page 6: ... 182 Adding 16 bit binary data 182 Subtracting 16 bit binary data 188 Adding 32 bit binary data 194 Subtracting 32 bit binary data 199 Multiplying 16 bit binary data 205 Dividing 16 bit binary data 209 Multiplying 32 bit binary data 213 Dividing 32 bit binary data 217 Adding BCD 4 digit data 221 Subtracting BCD 4 digit data 223 Adding BCD 8 digit data 225 Subtracting BCD 8 digit data 227 Multiplyi...

Page 7: ... unsigned binary data 294 Converting 16 bit signed binary data to 32 bit signed binary data 295 Converting 16 bit signed binary data to 32 bit unsigned binary data 296 Converting 16 bit unsigned binary data to 16 bit signed binary data 297 Converting 16 bit unsigned binary data to 32 bit signed binary data 298 Converting 16 bit unsigned binary data to 32 bit unsigned binary data 299 Converting 32 ...

Page 8: ...anging the upper and lower bytes of 32 bit data 363 Transferring 1 bit data 364 Transferring octal bits 16 bit data 365 Transferring octal bits 32 bit data 367 Transferring n bit data 369 CHAPTER 8 APPLICATION INSTRUCTION 371 8 1 Rotation Instruction 371 Rotating 16 bit data to the right 371 Rotating 16 bit data to the left 374 Rotating 32 bit data to the right 377 Rotating 32 bit data to the left...

Page 9: ...2 Storing the specified number of character strings 464 Replacing the specified number of character strings 467 Searching character string 470 Inserting character string 472 Deleting character string 474 8 9 Real Number Instruction 476 Comparing single precision real numbers 476 Single precision real number comparison 478 Single precision real number data band comparison 480 Adding single precisio...

Page 10: ...ll data of the index register 548 Saving the selected data of the index register and long index register 549 Returning the selected data of the index register and long index register 551 8 12 Data Control Instruction 552 Upper and lower limit control of 16 bit binary data 552 Upper and lower limit control of 32 bit binary data 554 Dead band control of 16 bit binary data 556 Dead band control of 32...

Page 11: ... Calculating the mean value of 32 bit data 678 Calculating the square root of 16 bit data 680 Calculating the square root of 32 bit data 681 CRC calculation 682 8 23 Indirect Address Read Instruction 684 Reading the indirect address 684 8 24 Clock Instruction 686 Reading clock data 686 Writing clock data 688 Adding clock data 690 Subtracting clock data 692 Converting time data from hour minute sec...

Page 12: ...P frame 757 CHAPTER 11 PID CONTROL INSTRUCTION 762 11 1 PID Control Loop 762 PART 4 MODULE DEDICATED INSTRUCTION CHAPTER 12 NETWORK COMMON INSTRUCTION 766 12 1 Link Dedicated Instructions 768 Reading data from another station programmable controller 768 Reading data from another station programmable controller with notification 772 Writing data to another station programmable controller 776 Writin...

Page 13: ...th 32 bit data DOG search 845 16 bit data interrupt positioning 847 32 bit data interrupt positioning 850 Positioning by one table operation 853 Positioning by multiple table operation 855 Multiple axes concurrent drive positioning 857 32 bit data ABS current value read 859 16 bit data variable speed pulse 861 32 bit data variable speed pulse 863 16 bit data relative positioning 865 32 bit data re...

Page 14: ...27 Converting DINT to DWORD 931 18 28 Converting DINT to INT 932 18 29 Converting DINT to BCD 933 18 30 Converting DINT to REAL 935 18 31 Converting DINT to TIME 936 18 32 Converting DINT to STRING 937 18 33 Converting BCD to INT 939 18 34 Converting BCD to DINT 941 18 35 Converting REAL to INT 943 18 36 Converting REAL to DINT 945 18 37 Converting REAL to STRING 947 18 38 Converting TIME to BOOL ...

Page 15: ...tiplication 989 20 3 Subtraction 991 20 4 Division 993 20 5 Remainder 995 20 6 Exponentiation 997 20 7 Move Operation 999 CHAPTER 21 BIT SHIFT FUNCTIONS 1001 21 1 n bit Left Shift 1001 21 2 n bit Right Shift 1003 21 3 n bit Left Rotation 1005 21 4 n bit Right Rotation 1007 CHAPTER 22 STANDARD BITWISE BOOLEAN FUNCTIONS 1009 22 1 AND Operation OR Operation XOR Operation 1009 22 2 Logical Negation 10...

Page 16: ...Reset Priority 1052 CHAPTER 28 EDGE DETECTION FUNCTION BLOCKS 1054 28 1 Rising Edge Detector 1054 28 2 Falling Edge Detector 1056 CHAPTER 29 COUNTER FUNCTION BLOCKS 1058 29 1 Up Counter 1058 29 2 Down Counter 1060 29 3 Up down Counter 1062 29 4 Counter Function Block 1065 CHAPTER 30 TIMER FUNCTION BLOCKS 1067 30 1 Pulse Timer 1067 30 2 On delay Timer 1069 30 3 Off delay Timer 1071 30 4 Timer Funct...

Page 17: ...15 CONTENTS ...

Page 18: ...ce that is communicating with the CPU module by SLMP to read and write the data of the CPU module MELSEC iQ F FX5 User s Manual CC Link IE JY997D64201 Describes CC Link IE field network module MELSEC iQ F FX5 User s Manual CC Link SH 081793ENG Describes CC Link system master intelligent device module MELSEC iQ F FX5 User s Manual ASLINK SH 081796ENG Describes AnyWireASLINK system master module MEL...

Page 19: ...utput modules and High speed pulse input output modules Input module Generic term for Input modules extension cable type and Input modules extension connector type Input module extension cable type Generic term for FX5 8EX ES and FX5 16EX ES Input module extension connector type Generic term for FX5 C16EX D FX5 C16EX DS FX5 C32EX D FX5 C32EX DS and FX5 C32EX DS TS Output module Generic term for Ou...

Page 20: ...ector type Different name for FX5 CNV BUSC Connector conversion module Generic term for Connector conversion module extension cable type and Connector conversion module extension connector type Connector conversion module extension cable type Different name for FX5 CNV IF Connector conversion module extension connector type Different name for FX5 CNV IFC Extended extension cable Generic term for F...

Page 21: ...ng device range 3405H The value specified by s2 is outside the following range 1 to 32767 564 8 APPLICATION INSTRUCTION 8 11 Special Timer Instruction 8 Special function timer STMR This instruction uses the four devices from the device specified by d to perform four types of timer output Setting data Descriptions ranges and data types Applicable devices 1 Only T can be used Control data Ladder dia...

Page 22: ...ANDFI ORPI ORFI OUT RST BKRST MOVB P CMLB P 4 is described in positions where word device or bit specification of word device is available 5 Devices which can be set are described in the Others column Depending on the instruction the control data to set the operation of the instruction exists When the Set by column is User the value must be specified according to the setting range Indicates the fu...

Page 23: ...ERSION FUNCTIONS 18 28 Converting DINT to INT 18 28 Converting DINT to INT DINT_TO_INT _E These functions convert DINT type data to INT type data Setting data Descriptions types and data types Processing details Operation processing These functions convert the DINT type data input to s to INT type data and output from d A value input to s is the DINT type data value Operation result 1 Function wit...

Page 24: ...22 MEMO ...

Page 25: ...23 PART 1 PART 1 OVERVIEW Part 1 consists of the following chapter 1 OVERVIEW 2 PRECAUTIONS ON PROGRAMMING ...

Page 26: ...cter strings use numerical values to specify the number of devices transfers data and character strings Ex Block transfer instruction A numerical value from 0 to 65535 or 0 to 4294967295 can be set for the size such as the number of devices transfers or characters 1 Note however that when the size specification such as the number of devices transfers or characters is 0 the relevant instruction res...

Page 27: ...nge varies depending on whether the value is signed or unsigned Page 29 16 bit data word data 16 bit unsigned binary Double word Double word data can be handled Page 31 32 bit data double word data Word device Double word device Nibble specification of bit devices K1 to K8 2 Decimal constant Hexadecimal constant 32 bit signed binary Two consecutive sets of 32 bit data or 16 bit data can be handled...

Page 28: ... Nibble specified bit type label K1 to K8 Current value of long timer long retentive timer type label Current value of long counter type label Word signed INT Word signed type label Nibble specified bit type label K1 to K4 Current value of timer retentive timer type label Current value of counter type label Double word signed DINT Double word signed type label Nibble specified bit type label K1 to...

Page 29: ...string 32 bits hour ANY32_S Double word signed hour ANY32_U Double word unsigned bit string 32 bits ANY_REAL Single precision real number ANYREAL_32 Single precision real number ANY_STRING Character string ANYSTRING_SINGLE Character string ANY_STRUCT 1 Structures ANY_DT Word signed word unsigned bit string 16 bits ANY_TM Word signed word unsigned bit string 16 bits STRUCT Structures ANY16_OR_STRIN...

Page 30: ...fied in hexadecimal in the range from 0 to F For example bit 5 b5 of D0 is specified as D0 5 and bit 10 b10 of D0 is specified as D0 A The following word devices support bit specification Handling bit data with word type labels By specifying a bit number for a word unsigned bit string 16 bits type label or word signed type label bit data of the specified bit number can be handled A bit in a word t...

Page 31: ...it data by performing nibble specification The following table shows the notation for handling a bit type array label as 16 bit data by nibble specification Data name Data size Value range Decimal notation Hexadecimal notation Signed 16 bit data 16 bits 1 word 32768 to 32767 0000H to FFFFH Unsigned 16 bit data 0 to 65535 Item Notation Example Bit device K Bit device start number Number of digits S...

Page 32: ...ble specification in the destination d When a nibble specification is made in the destination of an instruction the number of points by the nibble specification is applicable in the destination The bit devices after the number of points specified by nibble remain unchanged Nibble specification Decimal notation Hexadecimal notation K1 0 to 15 0H to FH K2 0 to 255 00H to FFH K3 0 to 4095 000H to FFF...

Page 33: ...fication Handling 32 bit data with bit type array labels A bit type array label can be handled as 32 bit data by performing nibble specification The following table shows the notation for handling a bit type array label as 32 bit data by nibble specification Data name Data size Value range Decimal notation Hexadecimal notation Signed 32 bit data 32 bits 2 word 2147483648 to 2147483647 00000000H to...

Page 34: ...s from X0 to X23 K6X0 24 points from X0 to X27 K7X0 28 points from X0 to X33 K8X0 32 points from X0 to X37 Nibble specification Decimal notation Hexadecimal notation K1 0 to 15 0H to FH K2 0 to 255 00H to FFH K3 0 to 4095 000H to FFFH K4 0 to 65535 0000H to FFFFH K5 0 to 1048575 00000H to FFFFFH K6 0 to 16777215 000000H to FFFFFFH K7 0 to 268435455 0000000H to FFFFFFFH K8 Signed 32 bit data 214748...

Page 35: ...specified by nibble remain unchanged Handling 32 bit data with word devices labels Word device Two points of word device can handle 32 bit data Note however that one point of the following devices can handle 32 bit data Long counter LC Long index register LZ Double word type label One point of double word device can handle 32 bit data Ladder example Processing 32 bit data instruction Ladder exampl...

Page 36: ...table shows the relationships between the exponent value and N of a single precision real number Precautions When setting an input value of single precision real number from the engineering tool The number of significant digits is about 7 because the engineering tool processes single precision real number data in 32 bit single precision When the input value of single precision real number data exc...

Page 37: ... of the following range to 0 Single precision real number data b0 to b31 The setting range of real number data is as follows Single precision real number data 2128 single precision real number data 2 126 0 2 126 single precision real number data 2128 Do not specify 0 only the most significant bit is 1 in real number data Performing a real number operation using 0 results in an operation error ...

Page 38: ... strings In each character string storage image NULL indicates a NULL code 00H Type Character code Last character Character string ASCII code NULL 00H 1 Character code string Type Maximum number of character strings 1 Maximum number of character strings that can be handled in the program Character string 255 single byte characters excluding the last NULL character 16383 characters excluding the la...

Page 39: ...executed only once on the falling edge on to off of the precondition of the instruction and is no longer executed later even when the condition turns off Always An instruction is always executed regardless of whether the precondition of the instruction is on or off When the precondition is off the instruction performs off processing Execution condition of each instruction The execution condition v...

Page 40: ... assigned to a device is specified in an instruction in the program Create such a program that the operation result falls within the range of the relevant device or label Ex When a global device is specified Error content 1 Error code SD0 SD8067 An I O number which corresponds to no module is specified 2801H An I O number which is out of range 0 to 1777 Octal number is specified The device or labe...

Page 41: ...pending on the operation result up to each OUT instruction while it is in execution In this case the device may turn on off during one scan because the on off state of the specified device is determined during execution of each OUT instruction The following figure shows the behavior arising when a circuit turning on off the same internal relay M0 is created with input X0 and X1 If output Y is spec...

Page 42: ...fied device turns on even if one execution command is off If the SET and RST instructions of the same device exist in one scan If the SET and RST instructions of the same device exist in one scan the SET instruction turns on the specified device if the execution command is on and turns off the specified device if it is on If both the SET and RST instructions are off the on off state of the specifi...

Page 43: ... device is turned on when the execution command of each PLS instruction specifies an off to on change The specified device is turned off unless the execution command specifies an off to on change Thus if two or more PLS instructions are issued during one scan the device turned on by a PLS instruction may not turn on for one scan If X0 and X1 differs in the on off timing i e the specified device do...

Page 44: ...tput Y is specified using a PLS instruction the on off state of the last PLS instruction executed during the one scan will be output 1 Since X0 turns on M0 turns on 2 Since X1 turns on M0 remains on 3 Since X0 is other than turning on M0 turns off 4 Since X1 is other than turning on M0 remains off ON X1 X0 PLS M0 PLS M0 PLS M0 X1 X0 PLS ON OFF OFF OFF M0 X1 X0 END END END ON 1 2 3 4 OFF OFF M0 ...

Page 45: ...is turned on when the execution command of each PLF instruction specifies an on to off change The specified device is turned off unless the execution command specifies an on to off change Thus if two or more PLF instructions are issued during one scan the device turned on by a PLF instruction may not turn on for one scan If X0 and X1 differs in the on off timing i e the specified device does not t...

Page 46: ...on Block Return Values When standard functions function blocks are used always set a device or label for the output variable and make sure to receive the return value If the output variable is not set an error may occur after writing to the PLC 1 Since X0 turns off M0 turns on 2 Since X1 turns off M0 remains on 3 Since X0 is other than turning off M0 turns off 4 Since X1 is other than turning off ...

Page 47: ...45 PART 2 PART 2 INSTRUCTION FUNCTION LIST This part consists of the following chapters 3 CPU MODULE INSTRUCTION 4 MODULE SPECIFIC INSTRUCTION 5 STANDARD FUNCTIONS FUNCTION BLOCKS ...

Page 48: ...ption Reference LDP Starts rising edge pulse operation Page 106 LDF Starts falling edge pulse operation ANDP Rising edge pulse series connection ANDF Falling edge pulse series connection ORP Rising edge pulse parallel connection ORF Falling edge pulse parallel connection Instruction symbol Description Reference LDPI Starts rising edge pulse NOT operation Page 108 LDFI Starts falling edge pulse NOT...

Page 49: ...S T High speed timer OUT ST Low speed retentive timer OUTH ST Retentive timer OUTHS ST High speed retentive timer Instruction symbol Description Reference OUT C Counter Page 117 OUT LC Long counter Page 118 Instruction symbol Description Reference OUT F Annunciator Page 120 Instruction symbol Description Reference SET Sets devices Page 121 Instruction symbol Description Reference RST Resets device...

Page 50: ... Instruction symbol Description Reference SFT 1 bit shift of the device Page 139 SFTP Instruction symbol Description Reference SFR Page 141 SFRP SFL Page 143 SFLP Instruction symbol Description Reference BSFR Page 145 BSFRP BSFL Page 146 BSFLP Instruction symbol Description Reference DSFR Page 147 DSFRP DSFL Page 148 DSFLP b0 bn bn 1 b15 b0 b15 0 0 SM700 SM8022 b0 bn 1 bn b15 b0 b15 0 0 SM700 SM80...

Page 51: ...TL Page 151 SFTLP Instruction symbol Description Reference WSFR Page 153 WSFRP WSFL Page 155 WSFLP Instruction symbol Description Reference MC Starts master control Page 157 MCR Releases master control Instruction symbol Description Reference FEND Ends the main routine program Page 161 Instruction symbol Description Reference END Ends the sequence program Page 162 Instruction symbol Description Re...

Page 52: ... OR _U Instruction symbol Description Reference LDD ANDD ORD s1 1 s1 s2 1 s2 Conductive s1 1 s1 s2 1 s2 Non Conductive Page 167 LDD _U ANDD _U ORD _U LDD ANDD ORD s1 1 s1 s2 1 s2 Conductive s1 1 s1 s2 1 s2 Non Conductive LDD _U ANDD _U ORD _U LDD ANDD ORD s1 1 s1 s2 1 s2 Conductive s1 1 s1 s2 1 s2 Non Conductive LDD _U ANDD _U ORD _U LDD ANDD ORD s1 1 s1 s2 1 s2 Conductive s1 1 s1 s2 1 s2 Non Cond...

Page 53: ...the device area n points from s1 with the 16 bit binary data in the device area n points from s2 and stores the result in the device area n points from d Page 177 BKCMP P BKCMP P BKCMP P BKCMP P BKCMP P BKCMP P BKCMP _U BKCMP _U BKCMP _U BKCMP _U BKCMP _U BKCMP _U BKCMP P_U BKCMP P_U BKCMP P_U BKCMP P_U BKCMP P_U BKCMP P_U Instruction symbol Description Reference DBKCMP DBKCMP DBKCMP DBKCMP DBKCMP...

Page 54: ...n instruction Adding subtracting 16 bit binary data Instruction symbol Description Reference d s d Page 182 P _U P_U s1 s2 d Page 184 P _U P_U ADD s1 s2 d Page 186 ADDP ADD_U ADDP_U d s d Page 188 P _U P_U s1 s2 d Page 190 P _U P_U SUB s1 s2 d Page 192 SUBP SUB_U SUBP_U ...

Page 55: ...5 D P D _U D P_U DADD s1 1 s1 s2 1 s2 d 1 d Page 197 DADDP DADD_U DADDP_U D d 1 d s 1 s d 1 d Page 199 D P D _U D P_U D s1 1 s1 s2 1 s2 d 1 d Page 201 D P D _U D P_U DSUB s1 1 s1 s2 1 s2 d 1 d Page 203 DSUBP DSUB_U DSUBP_U Instruction symbol Description Reference s1 s2 d 1 d Page 205 P _U P_U MUL s1 s2 d 1 d Page 207 MULP MUL_U MULP_U s1 s2 quotient d remainder d 1 Page 209 P _U P_U DIV s1 s2 quot...

Page 56: ...P_U DDIV s1 1 s1 s2 1 s2 quotient d 1 d remainder d 3 d 2 Page 219 DDIVP DDIV_U DDIVP_U Instruction symbol Description Reference B d s d Page 221 B P B s1 s2 d Page 222 B P B d s d Page 223 B P B s1 s2 d Page 224 B P Instruction symbol Description Reference DB d 1 d s 1 s d 1 d Page 225 DB P DB s1 1 s1 s2 1 s2 d 1 d Page 226 DB P DB d 1 d s 1 s d 1 d Page 227 DB P DB s1 1 s1 s2 1 s2 d 1 d Page 228...

Page 57: ...he result in the device area n points from d Page 238 BK P BK _U BK P_U Instruction symbol Description Reference DBK Adds the 32 bit binary bit data in the device area n points from s1 and the 32 bit data or constants in the device area n points from s2 and stores the result in the device area specified by d and later Page 240 DBK P DBK _U DBK P_U DBK Subtracts the 32 bit binary bit data in the de...

Page 58: ...d Page 250 WANDP DAND d 1 d s 1 s d 1 d Page 251 DANDP DAND s1 1 s1 s2 1 s2 d 1 d Page 252 DANDP Instruction symbol Description Reference BKAND Page 253 BKANDP Instruction symbol Description Reference WOR d s d Page 255 WORP WOR s1 s2 d Page 256 WORP DOR d 1 d s 1 s d 1 d Page 257 DORP DOR s1 1 s1 s2 1 s2 d 1 d Page 258 DORP Instruction symbol Description Reference BKOR Page 259 BKORP Instruction ...

Page 59: ...Page 267 WXNRP WXNR Page 268 WXNRP DXNR Page 269 DXNRP DXNR Page 270 DXNRP Instruction symbol Description Reference BKXNR Page 271 BKXNRP Instruction symbol Description Reference BSET Page 273 BSETP BRST Page 274 BRSTP Instruction symbol Description Reference TEST Page 275 TESTP DTEST Page 277 DTESTP Instruction symbol Description Reference BKRST Page 279 BKRSTP s d d s2 d s1 d 1 d s 1 s d 1 d s1 ...

Page 60: ...IN Converts the specified BCD 4 digit data 0 to 9999 to 16 bit binary data Page 286 BINP DBIN Converts the specified BCD 8 digit data 0 to 99999999 to 32 bit binary data Page 288 DBINP Instruction symbol Description Reference FLT2INT Converts the specified single precision real number 32768 to 32767 to 16 bit signed binary data 1 Real number Page 290 FLT2INTP FLT2DINT Converts the specified single...

Page 61: ...by d Page 297 UINT2INTP UINT2DINT Converts 16 bit unsigned data in the device specified by s to 32 bit signed data and stores the converted data in the device specified by d Page 298 UINT2DINTP Instruction symbol Description Reference UINT2UDINT Converts 16 bit unsigned data in the device specified by s to 32 bit unsigned data and stores the converted data in the device specified by d Page 299 UIN...

Page 62: ...6 bit binary Gray code data 0 to 65535 to 16 bit binary data Gc Gray code GBINP_U DGBIN Converts the specified 32 bit binary Gray code data 2147483648 to 2147483647 to 32 bit binary data Gc Gray code Page 309 DGBINP DGBIN_U Converts the specified 32 bit binary Gray code data 0 to 4294967295 to 32 bit binary data Gc Gray code DGBINP_U Instruction symbol Description Reference DABIN Converts a 5 digi...

Page 63: ...age 321 DVALP DVAL_U DVALP_U Instruction symbol Description Reference NEG Page 324 NEGP DNEG Page 325 DNEGP Instruction symbol Description Reference DECO Page 326 DECOP Instruction symbol Description Reference ENCO Page 328 ENCOP Instruction symbol Description Reference SEGD Decoded to data for the seven segment display unit in the device specified by s and stores in the device specified by d Page...

Page 64: ... Description Reference WTOB Breaks n points of 16 bit data from the device specified by s into 8 bit units and stores in the devices starting from the one specified by d Page 341 WTOBP BTOW Connects the lower 8 bits of 16 bit data of n points from the device specified by s into 16 bit units and stores in the devices starting from the one specified by d Page 343 BTOWP Instruction symbol Description...

Page 65: ...ion Reference SWAP Page 362 SWAPP Instruction symbol Description Reference DSWAP Page 363 DSWAPP Instruction symbol Description Reference MOVB Stores the bit data specified by s in d Page 364 MOVBP Instruction symbol Description Reference PRUN Handles device number specified by s in nibble specification and d as octal and stores into d from s Page 365 PRUNP Instruction symbol Description Reference...

Page 66: ... Description Reference ROL Rotates the 16 bit binary data to the left by n bit s not including the carry flag 1 n bit left rotation Page 374 ROLP RCL Rotates the 16 bit binary data to the left by n bit s including the carry flag 1 n bit left rotation RCLP Instruction symbol Description Reference DROR Rotates the 32 bit binary data to the right by n bit s not including the carry flag 1 n bit right ...

Page 67: ... is met jump to pointer P Page 381 CJP Instruction symbol Description Reference GOEND When the input condition is met jump to END instruction Page 384 Instruction symbol Description Reference DI Disables the execution of interrupt programs Page 385 EI Releases the execution disabled state of interrupt program Instruction symbol Description Reference DI Disables the execution of the interrupt progr...

Page 68: ...ption Reference BREAK Forcibly end execution between FOR instruction and NEXT instruction and jump to pointer P Page 397 BREAKP Instruction symbol Description Reference CALL Executes a subroutine program specified by P when the input condition is met Page 399 CALLP Instruction symbol Description Reference RET Returns from the subroutine program Page 403 SRET Instruction symbol Description Referenc...

Page 69: ...ge 414 FDELP Instruction symbol Description Reference S DEVLD Reads data from the device data storage file in data memory Page 417 SP DEVLD Instruction symbol Description Reference SP DEVST Writes the specified number of points of data to the device data storage file in data memory Page 419 Instruction symbol Description Reference ERREAD Reads the current value of the extended file register ER to ...

Page 70: ...racter string s1 with the character string s2 one character at a time 1 Character string s1 Character string s2 Conductive state Character string s1 Character string s2 Non Conductive state LD AND OR Compares the character string s1 with the character string s2 one character at a time 1 Character string s1 Character string s2 Conductive state Character string s1 Character string s2 Non Conductive ...

Page 71: ...data stored in the device specified by s in the device specified by d Page 458 LENP Instruction symbol Description Reference RIGHT Stores the n characters from the last character of the character string specified by s in the device specified by d Page 460 RIGHTP LEFT Stores the n characters from the first character of the character string specified by s in the device specified by d Page 462 LEFTP ...

Page 72: ... to three bit devices Page 478 DECMPP DEZCP This instruction compares two data values single precision real numbers and outputs the result larger smaller or data band to three bit devices Page 480 DEZCPP Instruction symbol Description Reference E In case of 2 operands d 1 d s 1 s d 1 d Page 482 E P E In case of 3 operands s1 1 s1 s2 1 s2 d 1 d Page 484 E P DEADD Page 490 DEADDP E In case of 2 oper...

Page 73: ...device specified by s to single precision real number and stores the converted data in d Page 505 UDINT2FLTP Instruction symbol Description Reference EVAL Converts the character string specified by s to a single precision real number and stores the converted data in d Page 506 EVALP DEVAL DEVALP Instruction symbol Description Reference DEBCD Converts the binary floating point specified by s into d...

Page 74: ...on symbol Description Reference TAN Tan s 1 s d 1 d Page 519 TANP DTAN DTANP Instruction symbol Description Reference ASIN Sin 1 s 1 s d 1 d Page 521 ASINP DASIN DASINP Instruction symbol Description Reference ACOS Cos 1 s 1 s d 1 d Page 523 ACOSP DACOS DACOSP Instruction symbol Description Reference ATAN Tan 1 s 1 s d 1 d Page 525 ATANP DATAN DATANP Instruction symbol Description Reference RAD Co...

Page 75: ...ption Reference POW s1 1 s1 s2 1 s2 d 1 d Page 537 POWP Instruction symbol Description Reference LOG10 log10 s 1 s d 1 d Page 539 LOG10P DLOG10 DLOG10P Instruction symbol Description Reference EMAX These instructions search for the maximum value in the n points of single precision real number block data specified by the device starting from the one specified by s and store the maximum value in the...

Page 76: ...ices specified by d onwards Page 549 ZPUSHP ZPOP Reads data in the devices specified by d onwards to the index registers and long index registers Page 551 ZPOPP Instruction symbol Description Reference LIMIT s3 s1 The s1 value is stored in d s1 s3 s2 The s3 value is stored in d s2 s3 The s2 value is stored in d Page 552 LIMITP LIMIT_U LIMITP_U DLIMIT s3 1 s3 s1 1 s1 The s1 1 s1 value is stored in ...

Page 77: ...s Page 567 DSCLP DSCL_U DSCLP_U Instruction symbol Description Reference SCL2 Executes scaling using the scaling conversion data 16 bit data units specified by s2 for the input value specified by s1 and then stores the result in the device specified by d The scaling conversion is executed based on the scaling conversion data stored in the device specified by s2 onwards Page 570 SCL2P SCL2_U SCL2P_...

Page 78: ...n Reference RAMPF Shifts the value from the one specified by s1 to the one specified by s2 in n scans The current value is stored in the device specified by d1 0 Page 585 Instruction symbol Description Reference SPD Counts the pulse input from the device specified by s1 for the duration of time specified by s2 and stores the count in the device specified by d Page 588 DSPD Page 592 Instruction sym...

Page 79: ...aving n lines starting from s1 which occupies n lines 1 device If the counter value is equivalent to the table data the current output is reset and the ON OFF status of the specified sequential outputs is controlled Page 641 Instruction symbol Description Reference CCD This instruction calculates the sum data and horizontal parity value of data stored in s to s n 1 The sum data is stored in d and ...

Page 80: ... DMIN This instruction searches the data of n points from the device specified by s in 32 bit units and stores the minimum value in the device specified by d Page 662 DMINP DMIN_U DMINP_U Instruction symbol Description Reference SORTTBL In the data table sorting source having n1 n2 points specified by s sorts the data lines in the ascending order based on the group data in the column number n3 and...

Page 81: ... 674 DWSUM_U DWSUMP DWSUMP_U Instruction symbol Description Reference MEAN These instructions calculate the mean value of n points 16 bit binary data in the devices starting from the one specified by s and store the result in the device specified by d Page 676 MEANP MEAN_U MEANP_U DMEAN These instructions calculate the mean value of n points 32 bit binary data in the devices starting from the one ...

Page 82: ... Month d 2 Day d 3 Hour d 4 Minute d 5 Seconds d 6 Day of week 1 Clock element Page 688 TWRP Instruction symbol Description Reference TADD Page 690 TADDP Instruction symbol Description Reference TSUB Page 692 TSUBP Instruction symbol Description Reference HTOS Page 694 HTOSP DHTOS Page 696 DHTOSP Instruction symbol Description Reference STOH Page 698 STOHP DSTOH Page 700 DSTOHP d 0 d 1 d 2 d 3 d 4...

Page 83: ...ar year day month day month 1 s1 s1 2 s1 1 s2 s2 2 s2 1 year year day month day month 1 s1 s1 2 s1 1 s2 s2 2 s2 1 year year day month day month 1 s1 s1 2 s1 1 s2 s2 2 s2 1 year year day month day month 1 s1 s1 2 s1 1 s2 s2 2 s2 1 year year day month day month 1 s1 s1 2 s1 1 s2 s2 2 s2 1 year year day month day month 1 s1 s1 2 s1 1 s2 s2 2 s2 1 1 hour minute seconds hour minute seconds s1 s1 2 s1 1...

Page 84: ...binary data to d1 1 in units of seconds Page 714 DHOURM This instruction adds the time during which the input contact is ON in units of 1 hour turns ON the device specified by d2 when the total ON time exceeds the time specified by s 32 bit binary data and stores the current value in units of 1 hour 32 bit binary data to d1 and the current value that is less than one hour 16 bit binary data to d1 ...

Page 85: ...ructions write the n 2 word data to the buffer memory of the intelligent function module DTOP Instruction symbol Description Reference FROMD These instructions read the n word data from the buffer memory of the intelligent function module Page 726 FROMDP DFROMD These instructions read the n 2 word data from the buffer memory of the intelligent function module DFROMDP Instruction symbol Description...

Page 86: ...ived data of the connection specified by s1 from the socket communication receive data area during the END processing Page 743 Instruction symbol Description Reference SP SOCSND This instruction sends the data set in s3 to the target device of the connection specified by s1 Page 746 Instruction symbol Description Reference SP SOCCINF This instruction reads the connection information of the connect...

Page 87: ...hat data has been read by the GP SREAD instruction Page 772 Instruction symbol Description Reference GP WRITE Writes data to another station PLC device in units of words Page 776 Instruction symbol Description Reference GP SWRITE Writes data to another station PLC device in units of words When writing data has finished a device in the other station is turned on This makes it possible for the other...

Page 88: ... of CH specified by s2 is changed to the value specified by s1 Page 804 Instruction symbol Description Reference DHSCR Turns OFF the bit device of d when the current value of the high speed counter of CH specified by s2 is changed to the value specified by s1 Page 806 Instruction symbol Description Reference DHSZ Compares whether the current value of the high speed counter is within or outside the...

Page 89: ...f the corresponding instruction code to the specified inverter station number Page 824 Instruction symbol Description Reference IVRD Reads a parameter from the specified inverter station number Page 826 Instruction symbol Description Reference IVWR Writes a parameter to the specified inverter station number Page 828 Instruction symbol Description Reference IVBWR Writes the range of the specified d...

Page 90: ...on Reference TBL When FX3 compatible operand is specified Outputs 1 table operation from the table set by the parameter as pulse with specified device Y When FX5 operand is specified Outputs 1 table operation from the table set by the parameter as pulse with specified axis number Page 853 Instruction symbol Description Reference DRVTBL Outputs continuous multiple table operations from the table se...

Page 91: ... G ABRST1 Restores the absolute position of specified axis Page 880 G ABRST2 Instruction symbol Description Reference GP PSTRT1 Starts positioning of the specified axis Page 883 GP PSTRT2 Instruction symbol Description Reference GP TEACH1 Performs teaching for the specified axis Page 886 GP TEACH2 Instruction symbol Description Reference GP PFWRT Writes the positioning data and block start data in...

Page 92: ...01 BOOL_TO_DWORD_E Function symbol Description Reference BOOL_TO_INT Converts BOOL type data to INT type data Page 902 BOOL_TO_INT_E BOOL_TO_DINT Converts BOOL type data to DINT type data Page 903 BOOL_TO_DINT_E Function symbol Description Reference BOOL_TO_TIME Converts BOOL type data to TIME type data Page 904 BOOL_TO_TIME_E Function symbol Description Reference BOOL_TO_STRING Converts BOOL type...

Page 93: ...ORD_TO_BOOL Converts DWORD type data to BOOL type data Page 911 DWORD_TO_BOOL_E Function symbol Description Reference DWORD_TO_WORD Converts DWORD type data to WORD type data Page 912 DWORD_TO_WORD_E Function symbol Description Reference DWORD_TO_INT Converts DWORD type data to INT type data Page 914 DWORD_TO_INT_E DWORD_TO_DINT Converts DWORD type data to DINT type data Page 916 DWORD_TO_DINT_E F...

Page 94: ...AL Converts INT type data to REAL type data Page 924 INT_TO_REAL_E Function symbol Description Reference INT_TO_TIME Converts INT type data to TIME type data Page 925 INT_TO_TIME_E Function symbol Description Reference INT_TO_STRING Converts INT type data to STRING type data Page 926 INT_TO_STRING_E Function symbol Description Reference DINT_TO_BOOL Converts DINT type data to BOOL type data Page 9...

Page 95: ...data Page 936 DINT_TO_TIME_E Function symbol Description Reference DINT_TO_STRING Converts DINT type data to STRING type data Page 937 DINT_TO_STRING_E Function symbol Description Reference BCD_TO_INT Converts BCD type data to INT type data Page 939 BCD_TO_INT_E BCD_TO_DINT Converts BCD type data to DINT type data Page 941 BCD_TO_DINT_E Function symbol Description Reference REAL_TO_INT Converts RE...

Page 96: ... TIME_TO_STRING Converts TIME type data to STRING type data Page 955 TIME_TO_STRING_E Function symbol Description Reference STRING_TO_ BOOL Converts STRING type data to BOOL type data Page 956 STRING_TO_ BOOL_E Function symbol Description Reference STRING_TO_INT Converts STRING type data to INT type data Page 957 STRING_TO_INT_E STRING_TO_DINT Converts STRING type data to DINT type data Page 959 S...

Page 97: ...iption Reference CPY_BITARR Copies specified number of bits of a bit array Page 969 CPY_BITARR_E Function symbol Description Reference GET_BIT_OF_INT Reads a value of a specified bit of INT type data Page 970 GET_BIT_OF_INT_E Function symbol Description Reference SET_BIT_OF_INT Writes a value to a specified bit of INT type data Page 971 SET_BIT_OF_INT_E Function symbol Description Reference CPY_BI...

Page 98: ...thm operation result of an input value Page 977 LN_E Function symbol Description Reference LOG Outputs the operation result of the common logarithm the logarithm whose base is 10 of an input value Page 978 LOG_E Function symbol Description Reference EXP Outputs the exponential operation result of an input value Page 980 EXP_E Function symbol Description Reference SIN Outputs the sine of the angle ...

Page 99: ...eference ADD Outputs the sum of input values s1 s2 s28 Page 987 ADD_E Function symbol Description Reference MUL Outputs the product of input values s1 s2 s28 Page 989 MUL_E Function symbol Description Reference SUB Outputs the difference of input values s1 s2 Page 991 SUB_E Function symbol Description Reference DIV Outputs the quotient of input values s1 s2 Page 993 DIV_E Function symbol Descripti...

Page 100: ...ut value leftward by n bits and outputs the result Page 1005 ROL_E ROR Rotates an input value rightward by n bits and outputs the result Page 1007 ROR_E Function symbol Description Reference AND Outputs the logical product of input values Page 1009 AND_E OR Outputs the logical sum of input values OR_E XOR Outputs the exclusive logical sum of input values XOR_E NOT Outputs the logical negation of i...

Page 101: ..._E EQ EQ_E LE LE_E LT LT_E NE Page 1022 NE_E Function symbol Description Reference LEN Detects the length of an input character string and outputs the result Page 1024 LEN_E Function symbol Description Reference LEFT Outputs specified number of characters from the left of input character string data Page 1025 LEFT_E RIGHT Outputs specified number of characters from the right of input character str...

Page 102: ... symbol Description Reference REPLACE Replaces an arbitrary range of a character string and outputs the result Page 1035 REPLACE_E Function symbol Description Reference FIND Searches for a character string and outputs the result Page 1038 FIND_E Function symbol Description Reference ADD_TIME Outputs the sum of input values time data s1 s2 Page 1040 ADD_TIME_E Function symbol Description Reference ...

Page 103: ...ALSE Reset priority Page 1052 RS_E Function block symbol Description Reference R_TRIG Detects the rising edge of a signal and outputs a pulse signal Page 1054 R_TRIG_E Function block symbol Description Reference F_TRIG Detects the falling edge of a signal and outputs a pulse signal Page 1056 F_TRIG_E Function block symbol Description Reference CTU Counts up the number of times of rising of a signa...

Page 104: ...Function block symbol Description Reference TON Turns ON a signal after a specified time Page 1069 TON_E TON_10 TON_10_E Function block symbol Description Reference TOF Turns OFF a signal after a specified time Page 1071 TOF_E TOF_10 TOF_10_E Function block symbol Description Reference TIMER_1_FB_M When the execution condition is established these function blocks start the timer count to the set t...

Page 105: ...LE INSTRUCTIONS This part consists of the following chapters 6 SEQUENCE INSTRUCTIONS 7 BASIC INSTRUCTIONS 8 APPLICATION INSTRUCTION 9 STEP LADDER INSTRUCTIONS 10 BUILT IN ETHERNET FUNCTION INSTRUCTIONS 11 PID CONTROL INSTRUCTION ...

Page 106: ...These instructions capture the ON OFF information of the device specified by s OR with the operation result so far and use the result as the operation result Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text This becomes a assignment statement operator control syntax etc In the ST language there are sometimes no instructions symbols that directly cor...

Page 107: ...d bit There is no limitation to the number of series contacts Any number of contacts can use this instructions consecutively Output to other coils through contacts after the OUT instruction is called cascade output and these outputs can be repeated any number of times as long as their order is correct OR ORI The OR instruction is NO contact parallel connection and the ORI instruction is NC contact...

Page 108: ... with the operation result so far and uses the result as the operation result ORP Rising edge pulse parallel connection ORF Falling edge pulse parallel connection This instruction ORs the bit device specified by s with the operation result so far and uses the result as the operation result Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text ENO LDP EN ...

Page 109: ... the specified bit changes to 1 0 ANDP ANDF The ANDP instruction is the rising edge pulse series connection instruction and the ANDF instruction is the falling edge pulse series connection These instructions AND with the operation result so far and uses the result as the operation result The table below shows the ON OFF information used by these instructions ORP ORF The ORP instruction is the risi...

Page 110: ...specified by s with the operation result so far and uses the result as the operation result ORPI Rising edge pulse NOT parallel connection instruction ORFI Falling edge pulse NOT parallel connection instruction This instruction ORs the bit devices specified by s with the operation result so far and uses the result as the operation result Setting data Descriptions ranges and data types Applicable d...

Page 111: ...s the falling edge pulse NOT series connection instruction These instructions AND with the operation result so far and use the result as the operation result The table below shows the ON OFF information used by these instructions ORPI ORFI The ORPI instruction is the rising edge pulse NOT parallel connection instruction and the ORFI instruction is the falling edge pulse NOT parallel connection ins...

Page 112: ...n is not NO contact symbol but a connection symbol ORB This instruction ORs the A and B blocks and uses the result as the operation result This instruction connects the ladder blocks of two contacts or more in parallel For parallel connection of only one contact use the OR and ORI instructions there is no need to use this instruction The symbol of this instruction is not NO contact symbol but a co...

Page 113: ...ly When MPP instruction is used in between the number of uses of MPS instruction is decremented by 1 MRD This instruction reads the operation result stored by the MPS instruction to memory and executes operations from the next step using that operation result MPP This instruction reads the operation result stored by the MPS instruction to memory and executes operations from the next step using tha...

Page 114: ...struction This instruction cannot be used at positions where the LD and OR instructions are programmed If a ladder block is used the operation result is inverted within the range of the ladder block When operating a ladder with this instruction and the ANB instruction pay attention to the inversion range Broken line part Inversion range For details ANB instruction refer to the following Page 110 A...

Page 115: ... easier when multiple contacts are connected in series MEF This instruction turns ON conductive state at the falling edge ON to OFF of the operation result up to this instruction This instruction turns OFF non conductive state in instances other than the falling edge of the operation result up to this instruction Use of this instruction makes conversion to pulse easier when multiple contacts are c...

Page 116: ...cified 4 When using LC refer to Page 118 OUT LC Processing details This instruction outputs the operation result up to this instruction to the specified device Operation error There is no operation error Ladder diagram Structured text ENO OUT EN d FBD LD Operand Remarks Range Data type Data type label d Number of the device that turns ON OFF Bit ANY_BOOL EN Execution condition Bit BOOL ENO Executi...

Page 117: ...s ON and the coil of the timer retentive timer specified by d turns ON When the timer reaches the end of its count current value set value NO contact becomes conductive and NC contact becomes non conductive Operation is as follows when the operation result up to the OUT instruction changes from ON to OFF Ladder diagram Structured text ENO OUT_T EN Coil Value ENO OUTH EN Coil Value ENO OUTHS EN Coi...

Page 118: ...ing a program for measuring another timer at a timer contact program in order starting with the timer to be measured later on In the following instance all timers turn on in the same scan when the program is created in the measurement order When the set value is shorter than the scan time When the set value is 1 Ex When the T0 to T2 timers are programmed in order from the timer that is measured la...

Page 119: ...o OUT instruction changes from OFF to ON and when the counter reaches the end of its count current value set value NO contact becomes conductive and NC contact becomes non conductive The counter does not count while the operation result remains on Count input does not need to be converted to pulses After a count up the count value and contact status do not change until the RST instruction is execu...

Page 120: ... counter reaches the end of its count current value set value NO contact becomes conductive and NC contact becomes non conductive The counter does not count while the operation result remains on Count input does not need to be converted to pulses After a count up the count value and contact status do not change until the RST or ZRST instruction is executed When the set value is 0 the same processi...

Page 121: ...6 SEQUENCE INSTRUCTIONS 6 3 Output Instructions 119 6 Operation error Error code SD0 SD8067 Remarks 2821H When the high speed counter is assigned to the specification long counter ...

Page 122: ...dder diagram Structured text ENO OUT EN d FBD LD OUT enters Operand Remarks Range Data type Data type label d Annunciator number that turns ON Bit ANY_BOOL EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E d 1 The annunciator number F number that turns ON is stor...

Page 123: ...hat is turned ON is held on even if the execution command turns OFF Devices that are turned ON by the SET instruction can be turned OFF by the RST instruction When the execution command is OFF the device status does not change Ladder diagram Structured text ENO SET EN d FBD LD Operand Remarks Range Data type Data type label d Bit device number Bit specification of word device to be set turns ON Bi...

Page 124: ... Output Instructions Precautions When the SET and RST instructions are executed on the same output relay Y the result of the instruction nearer the END instruction end of program is output Operation error There is no operation error ...

Page 125: ...ed by the RST instruction is the same as the following circuit Precautions When the RST instruction for a timer or counter is executed by a program containing a jump or by a subroutine program or interrupt program the timer or counter is held in a reset state and the timer or counter may not work normally Ladder diagram Structured text ENO RST EN d FBD LD Operand Remarks Range Data type Data type ...

Page 126: ...124 6 SEQUENCE INSTRUCTIONS 6 3 Output Instructions Operation error There is no operation error ...

Page 127: ...red in SD64 to SD79 even if a new annunciator turns ON Ladder diagram Structured text ENO SET EN d FBD LD SET enters Operand Remarks Range Data type Data type label d Annunciator number F number that is set Bit ANY_BOOL EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ...

Page 128: ...ror Device Name Remarks SD62 Annunciator F Detection No This register stores the earliest detected annunciator F No SD63 Annunciator F Detection Number This register stores the number of annunciator F detections SD64 to SD79 Annunciator F Detection No table This register stores the annunciator F detection No ...

Page 129: ...ces 1 Only F can be used Ladder diagram Structured text ENO RST EN d FBD LD RST enters Operand Remarks Range Data type Data type label d Annunciator number F number that is reset Bit ANY_ELEMENTARY EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E d 1 d EN ENO d ...

Page 130: ...ented by 1 when the numbers not registered in SD64 to SD79 are turned OFF Related devices Operation error There is no operation error 1 F90 is reset 2 When F number that is not registered in SD79 is stored this remains as 16 When SD79 is 0 the number is decremented by 1 to become 15 3 The F number in SD66 is shifted to this area 4 F number of SD67 is stored 5 Not registered F number or 0 is stored...

Page 131: ...d Remarks Range Data type Data type label s Timer number for evaluation time 16 bit signed binary ANY16 n Evaluation time data 1 to 32767 16 bit unsigned binary ANY16_U d Annunciator device to be set Bit ANY_BOOL EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E ...

Page 132: ...130 6 SEQUENCE INSTRUCTIONS 6 3 Output Instructions Operation error There is no operation error ...

Page 133: ...mber among annunciators F devices that are operating Related devices Precautions When ANR instruction is used annunciators in the ON status are reset in turn in each operation cycle This is executed for only 1 operation cycle only once when the ANRP instruction is used Operation error There is no error Ladder diagram Structured text ENO ANR EN ENO ANRP EN FBD LD Device Name Remarks SM8049 On statu...

Page 134: ...vice for one scan when the PLS command turns from OFF to ON and turns OFF in other cases When there is one PLS instruction programmed for the device specified by d during a scan the specified device turns ON for one scan Ladder diagram Structured text ENO PLS EN d FBD LD Operand Remarks Range Data type Data type label d Device to be converted to pulse Bit ANY_BOOL EN Execution condition Bit BOOL E...

Page 135: ...ot executed regardless of the ON OFF status of the device that is set as the operation condition The instruction is executed when the target device and the device in the operation conditions is set from OFF to ON again Note that the device specified by d sometimes turns ON for one scan or more when the PLS instruction is made to jump by the CJ instruction or the executed subroutine program was not...

Page 136: ...When there is one PLF instruction programmed for the device specified by d during a scan the specified device turns ON for one scan If the RUN STOP RESET switch is changed from RUN to STOP after execution of the PLF instruction the PLF instruction will not be executed even if the switch is set to RUN again Ladder diagram Structured text ENO PLF EN d FBD LD Operand Remarks Range Data type Data type...

Page 137: ...ge instruction PLF instruction the instruction is not executed regardless of the ON OFF status of the device that is set as the operation condition The instruction is executed when the target device and the device in the operation conditions is set from ON to OFF again Note that the device specified by d sometimes turns ON for one scan or more when the PLF instruction is made to jump by the CJ ins...

Page 138: ...evice specified by d when the execution command changes from OFF to ON Operation error There is no operation error Ladder diagram Structured text ENO FF EN d FBD LD Operand Remarks Range Data type Data type label d Device number to be reversed Bit ANY_BOOL EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others DY X Y M L SM...

Page 139: ...tput Precautions When the CPU module is programmed with the ALT instruction reversal operation is performed at every operation cycle To perform reversal operation by command ON OFF either use the ALTP instruction pulse execution type or set a command contact as LDP etc pulse execution type Ladder diagram Structured text ENO ALT EN d ENO ALTP EN d FBD LD Operand Remarks Range Data type Data type la...

Page 140: ...138 6 SEQUENCE INSTRUCTIONS 6 3 Output Instructions Operation error There is no operation error ...

Page 141: ...ion shifts the ON OFF status of the device before the device specified by d to the device specified by d The device before the device specified by d turns OFF Ex When M11 is specified by the SFTP instruction and the SFTP instruction is executed the ON OFF status of M10 is shifted to M11 and M10 is turned OFF Turn ON the first device to be shifted by the SET instruction Ladder diagram Structured te...

Page 142: ... shifted to b5 and b4 is set to 0 Operation error 1 X2 ON 2 After the 1st shift input 3 After the 2nd shift input 4 X2 ON 5 After the 3rd shift input 6 After the 4th shift input 7 After the 5th shift input 8 First device of shift 9 Shift range 1 Before shift execution 2 After shift execution Error code SD0 SD8067 Remarks 2820H The device specified by d exceeds the corresponding device range 0 0 M1...

Page 143: ...cation When n 4 Ladder diagram Structured text ENO SFR EN n d ENO SFRP EN n d FBD LD Operand Remarks Range Data type Data type label d Head device number where the shift target data is stored 16 bit signed binary ANY16 n Number of shifts 0 to 15 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Ot...

Page 144: ...n bits are shifted to the right by the remainder value of n 16 For example when n is 18 data is shifted by 2 bits to the right because 18 divided by 16 equals 1 with a remainder of 2 Related devices Operation error There is no operation error Device Name Remarks SM700 Carry ON OFF according to the status 1 0 of the n 1 th bit SM8022 ...

Page 145: ...e specification When n 3 Ladder diagram Structured text ENO SFL EN n d ENO SFLP EN n d FBD LD Operand Remarks Range Data type Data type label d Head device number where the shift target data is stored 16 bit signed binary ANY16 n Number of shifts 0 to 15 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Co...

Page 146: ... n bit s are shifted to the left by the remainder value of n 16 For example when n is 18 data is shifted by 2 bits to the left because 18 divided by 16 equals 1 with a remainder of 2 Related devices Operation error There is no operation error Device Name Remarks SM700 Carry ON OFF according to the status 1 0 of the n 1 th bit SM8022 ...

Page 147: ...ENO BSFR EN n d ENO BSFRP EN n d FBD LD Operand Remarks Range Data type Data type label d Head device number to be shifted Bit ANY_BOOL n Number of devices to be shifted 0 to 65535 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E d 1...

Page 148: ...BSFL EN n d ENO BSFLP EN n d FBD LD Operand Remarks Range Data type Data type label d Head device number to be shifted Bit ANY_BOOL n Number of devices to be shifted 0 to 65535 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E d 1 n D...

Page 149: ...m Structured text ENO DSFR EN n d ENO DSFRP EN n d FBD LD Operand Remarks Range Data type Data type label d Head device number to be shifted Word ANY16 n Number of devices to be shifted 0 to 65535 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z...

Page 150: ...Structured text ENO DSFL EN n d ENO DSFLP EN n d FBD LD Operand Remarks Range Data type Data type label d Head device number to be shifted Word ANY16 n Number of devices to be shifted 0 to 65535 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z L...

Page 151: ... EN s n1 n2 d ENO SFTRP EN s n1 n2 d FBD LD Operand Remarks Range Data type Data type label s Head device number stored to the shift data after the shift Bit ANY_BOOL d Head device number to be shifted Bit ANY_BOOL n1 1 Data length of shift data 0 to 65535 16 bit unsigned binary ANY16_U n2 1 Number of shifts 0 to 65535 16 bit unsigned binary ANY16_U EN Execution condition Bit BOOL ENO Execution re...

Page 152: ... the shift Operation error 1 When s K0 it is 0 Error code SD0 SD8067 Remarks 2820H The n2 points of data starting from the device specified by s exceed in the corresponding device The n1 points of data starting from the device specified by d exceed in the corresponding device 2821H The transfer source data s overlaps with shift device d 3405H A constant other than K0 or K1 is specified when the co...

Page 153: ...N s n1 n2 d ENO SFTLP EN s n1 n2 d FBD LD Operand Remarks Range Data type Data type label s Head device number stored to the shift data after the shift Bit ANY_BOOL d Head device number to be shifted Bit ANY_BOOL n1 1 Data length of shift data 0 to 65535 16 bit unsigned binary ANY16_U n2 1 Number of shifts 0 to 65535 16 bit unsigned binary ANY16_U EN Execution condition Bit BOOL ENO Execution resu...

Page 154: ...Operation error 1 When s K0 it is 0 Error code SD0 SD8067 Remarks 2820H The n2 points of data starting from the device specified by s exceed in the corresponding device The n1 points of data starting from the device specified by d exceed in the corresponding device 2821H The transfer source data s overlaps with shift device d 3405H A constant other than K0 or K1 is specified when the constant s is...

Page 155: ...specified for n1 or n2 is 0 the processing is not performed Ladder diagram Structured text ENO WSFR EN s n1 n2 d ENO WSFRP EN s n1 n2 d FBD LD Operand Remarks Range Data type Data type label s Head device number stored to the shift data after the shift Word ANY16 d Head device number to be shifted Word ANY16 n1 1 Data length of shift data 0 to 65535 16 bit unsigned binary ANY16_U n2 1 Number of sh...

Page 156: ...ce specified by s exceed in the corresponding device The n1 points of data starting from the device specified by d exceed in the corresponding device 2821H The transfer source data s overlaps with shift device d 3405H A constant other than K0 or K1 is specified when the constant s is specified The values specified in n1 and n2 are such that n1 n2 ...

Page 157: ...ecified for n1 or n2 is 0 the processing is not performed Ladder diagram Structured text ENO WSFL EN s n1 n2 d ENO WSFLP EN s n1 n2 d FBD LD Operand Remarks Range Data type Data type label s Head device number stored to the shift data after the shift Word ANY16 d Head device number to be shifted Word ANY16 n1 1 Data length of shift data 0 to 65535 16 bit unsigned binary ANY16_U n2 1 Number of shif...

Page 158: ...ce specified by s exceed in the corresponding device The n1 points of data starting from the device specified by d exceed in the corresponding device 2821H The transfer source data s overlaps with shift device d 3405H A constant other than K0 or K1 is specified when the constant s is specified The values specified in n1 and n2 are such that n1 n2 ...

Page 159: ... N displays as n Applicable devices 1 T ST C cannot be used Ladder diagram Structured text 1 Master control ladder ENO MC EN n d ENO MCR EN n FBD LD Operand Remarks Range Data type Data type label N 1 Nesting 0 to 14 Device name ANY16_S d Number of device to be turned ON Bit ANY_BOOL EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification C...

Page 160: ...When this instruction is ON the coil of the device specified by d turns ON Also the coil becomes a double coil when the same device is used by the OUT instruction for example So do not use the device specified by d in other instructions MCR This instruction indicates the end of the master control range by the master control release instruction Do not prefix this instruction with NO contact instruc...

Page 161: ...ate a ladder for successively restricting program execution conditions A nested structure ladder is illustrated as follows Left Display on the engineering tool Right Actual operation 1 Executed when A is ON 2 Executed when A and B are ON 3 Executed when A B and C are ON 4 Regardless of A B and C MC N0 M15 MC N1 M16 MC N2 M17 MCR N2 MCR N1 MCR N0 N0 M15 N1 M16 N2 M17 A B C MC N0 M15 MC N1 M16 MC N2...

Page 162: ...5 levels N0 to N14 is possible When nesting instructions the MC instruction is used starting from the smallest N number and the MCR instruction is started starting from the biggest number Programming in reverse order does not produce a nested structure and hence the CPU module cannot execute operations properly When the MCR instruction is nested at a single location all master controls can be ende...

Page 163: ...used Right When there are subroutine programs and interrupt programs Operation error Ladder diagram Structured text Not supported FBD LD Not supported A Main routine program B Subroutine program C Interrupt Program 1 Operation when the CJ instruction is not executed 2 Jump by the CJ instruction 3 Operation when the CJ instruction has been executed Error code SD0 SD8067 Remarks 3340H The FEND instr...

Page 164: ...rogramming is performed using the engineering tool in ladder edit mode the END instruction is automatically input and cannot be edited The following illustrates how the END and FEND instructions are used properly when a program contains a main routine program subroutine program and interrupt program The END instruction executed while a program is divided into multiple program blocks indicates the ...

Page 165: ...n after the FOR instruction is executed 3381H The END instruction is executed before the RET instruction after the CALL P instruction is executed 33E3H The END instruction is programmed between FOR NEXT 33E4H The END instruction is programmed between MC MCR 33E5H The END instruction is programmed between STL RETSTL 33E7H The END instruction is programmed between I IRET ...

Page 166: ...same as setting the switch to STOP To restart operation of the CPU module after this instruction is executed return the switch from RUN STOP and set it to RUN again Operation error Ladder diagram Structured text ENO STOP EN FBD LD Error code SD0 SD8067 Remarks 3340H The STOP instruction is executed before the NEXT instruction is executed after the FOR instruction is executed 3381H The STOP instruc...

Page 167: ...U _U _U enters ENO LD_ EN s1 s2 ENO AND_ EN s1 s2 ENO OR_ EN s1 s2 ENO LD_ _U EN s1 s2 ENO AND_ _U EN s1 s2 ENO OR_ _U EN s1 s2 EQ NE GT LE LT GE enters 2 FBD LD _EQ _U _NE _U _GT _U _LE _U _LT _U _GE _U enters 2 Operand Description Range Data type Data type label s1 LD AND OR Comparison data or device where the comparison data is stored 32768 to 32767 16 bit signed binary ANY16_S LD _U AND _U OR ...

Page 168: ...on result of each instruction Precautions When the most significant bit is 1 in the data stored in s1 or s2 it is regarded as a negative binary value for comparison Excluding unsigned operation Operation error There is no operation error Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E s1 s2 Instruction symbol Condition Re...

Page 169: ...s2 ENO ORD_ _U EN s1 s2 EQ NE GT LE LT GE enters 2 FBD LD D_EQ _U D_NE _U D_GT _U D_LE _U D_LT _U D_GE _U enters 2 Operand Description Range Data type Data type label s1 LDD ANDD ORD Comparison data or head device where the comparison data is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S LDD _U ANDD _U ORD _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 LDD ANDD ORD Comparison ...

Page 170: ... 1 in the data stored in s1 or s2 it is regarded as a negative binary value for comparison Excluding unsigned operation For comparison of 32 bit counter LC specify an instruction LDD etc that handles 32 bit data If an instruction LD etc that handles 16 bit data is specified a program error or operation error occurs Same applies for index device LZ as well Operation error There is no operation erro...

Page 171: ...l s1 CMP P Comparison value data or the device where the comparison value data is stored 32768 to 32767 16 bit signed binary ANY16_S CMP P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 CMP P Comparison source data or the device where the comparison source data is stored 32768 to 32767 16 bit signed binary ANY16_S CMP P _U 0 to 65535 16 bit unsigned binary ANY16_U d The starting bit device to whi...

Page 172: ...ions Three devices are occupied from the device specified in d Make sure that these devices are not used in other controls Operation error With sign 10 FFF6H 2 0002H Without sign 32767 7FFFH 65280 FF00H 1 Even if the command input turns OFF and the CMP instruction is not executed d to d 2 latches the status just before the command input turns from ON to OFF Error code SD0 SD8067 Description 2820H ...

Page 173: ...son value data or the head device where the comparison value data is stored 2147483647 to 2147483647 32 bit signed binary ANY32_S DCMP P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DCMP P Comparison source data or the head device where the comparison source data is stored 2147483647 to 2147483647 32 bit signed binary ANY32_S DCMP P _U 0 to 4294967295 32 bit unsigned binary ANY32_U d The s...

Page 174: ...s are occupied from the device specified in d Make sure that these devices are not used in other controls Operation error With sign 125400 FFFE1628H 224566 00036D36H Without sign 16776690 00FFFDF2H 4294967176 FFFFFF88H 1 Even if the command input turns OFF and the DCMP instruction is not executed d to d 2 latches the status just before the command input turns from ON to OFF Error code SD0 SD8067 D...

Page 175: ...e Data type label s1 ZCP P Lower limit comparison data or the device where the comparison data is stored 32768 to 32767 16 bit signed binary ANY16_S ZCP P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 ZCP P Upper limit comparison data or the device where the comparison data is stored 32768 to 32767 16 bit signed binary ANY16_S ZCP P _U 0 to 65535 16 bit unsigned binary ANY16_U s3 ZCP P Compariso...

Page 176: ...ebraically Large and small comparison is executed algebraically Precautions Set s1 to a value less than s2 Three devices are occupied from the device specified in d Make sure that these devices are not used in other controls Operation error With sign 10 FFF6H 2 0002H 10 000AH Without sign 0 0000H 32767 7FFFH 40000 9C40H 1 Even if the command input turns OFF and the ZCP instruction is not executed ...

Page 177: ...wer limit comparison data or the head device where the comparison data is stored 2147483647 to 2147483647 32 bit signed binary ANY32_S DZCP P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DZCP P Upper limit comparison data or the head device where the comparison data is stored 2147483647 to 2147483647 32 bit signed binary ANY32_S DZCP P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s3 D...

Page 178: ...lgebraically Precautions Set s1 to a value less than s2 Three devices are occupied from the device specified in d Make sure that these devices are not used in other controls Operation error With sign 125400 FFFE1628H 22466 000057C2H 1015444 000F7E94H Without sign 0 00000000H 2147483647 7FFFFFFFH 4026531840 F0000000H 1 Even if the command input turns OFF and the DZCP instruction is not executed d t...

Page 179: ... d ENO BKCMP_ P EN s1 s2 n d ENO BKCMP_ _U EN s1 s2 n d ENO BKCMP_ P_U EN s1 s2 n d EQ NE GT LE LT GE enters 2 FBD LD BKCMP_EQ P _U BKCMP_NE P _U BKCMP_GT P _U BKCMP_LE P _U BKCMP_LT P _U BKCMP_GE P _U enters 2 Operand Description Range Data type Data type label s1 BKCMP P Comparison data or the device where the comparison data is stored 32768 to 32767 16 bit signed binary ANY16_S BKCMP P _U 0 to ...

Page 180: ...rom d SM704 and SM8090 block comparison signal turns ON Operation error Instruction symbol Condition Result BKCMP P _U s1 s2 On 1 BKCMP P _U s1 s2 BKCMP P _U s1 s2 BKCMP P _U s1 s2 BKCMP P _U s1 s2 BKCMP P _U s1 s2 BKCMP P _U s1 s2 Off 0 BKCMP P _U s1 s2 BKCMP P _U s1 s2 BKCMP P _U s1 s2 BKCMP P _U s1 s2 BKCMP P _U s1 s2 Error code SD0 SD8067 Description 2820H The n point s starting from the devic...

Page 181: ...s2 n d ENO DBKCMP_ _U EN s1 s2 n d ENO DBKCMP_ P_U EN s1 s2 n d EQ NE GT LE LT GE enters 2 FBD LD DBKCMP_EQ P _U DBKCMP_NE P _U DBKCMP_GT P _U DBKCMP_LE P _U DBKCMP_LT P _U DBKCMP_GE P _U enters 2 Operand Description Range Data type Data type label s1 DBKCMP P Comparison data or the head device where the comparison data is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DBKCMP P _ U 0...

Page 182: ... from the one specified by s2 The following table lists the comparison operation result of each instruction When the comparison operation result is all ON 1 in all n point s starting from d SM704 and SM8090 block comparison signal turns ON Precautions If a 32 bit counter high speed counter included is used make sure to compare using the 32 bit operation DBKCMP DBKCMP DBKCMP etc Instruction symbol ...

Page 183: ...the n point s of data starting from the device specified by d exceeds said device 2821H When d specifies D b the n point s of data starting from the device specified by d and the device range of the n 2 points of data starting from the device specified by s1 overlap When d specifies D b the n point s of data starting from the device specified by d and the device range of the n 2 points of data sta...

Page 184: ...ata Descriptions ranges and data types Applicable devices Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s P Addend data or the device where the data that is added to another is stored 32768 to 32767 16 bit signed binary ANY16_S P _U 0 to 65535 16 bit unsigned binary ANY16_U d P Device where the data to which another is added i...

Page 185: ...vice specified by d When underflow or overflow occurs in the operation result the following processing is executed In this case the carry flag SM700 SM8022 does not turn ON Operation error There is no operation error In case of P In case of P _U b15 b0 5678 BIN d s d 1234 BIN 6912 BIN b15 b0 b15 b0 b15 b0 32767 BIN d s d 2 BIN 32767 BIN b15 b0 b15 b0 b15 b0 32768 BIN d s d 2 BIN 32766 BIN b15 b0 b...

Page 186: ...iption Range Data type Data type label s1 P Augend data or the device where the data to which another is added is stored 32768 to 32767 16 bit signed binary ANY16_S P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 P Addend data or the device where the data that is added to another is stored 32768 to 32767 16 bit signed binary ANY16_S P _U 0 to 65535 16 bit unsigned binary ANY16_U d P Device for s...

Page 187: ...ce specified by d When underflow or overflow occurs in the operation result the following processing is executed In this case the carry flag SM700 SM8022 does not turn ON Operation error There is no operation error In case of P In case of P _U b15 b0 5678 BIN s1 s2 d 1234 BIN 6912 BIN b15 b0 b15 b0 b15 b0 32767 BIN s1 s2 d 2 BIN 32767 BIN b15 b0 b15 b0 b15 b0 32768 BIN s1 s2 d 2 BIN 32766 BIN b15 ...

Page 188: ...ENO ADDP EN s1 s2 d ENO ADD_U EN s1 s2 d ENO ADDP_U EN s1 s2 d FBD LD 1 ADDP ADD_U ADDP_U enters Operand Description Range Data type Data type label s1 ADD P Addend data or the device where the data that is added to another is stored 32768 to 32767 16 bit signed binary ANY16_S ADD P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 ADD P Addend data or the device where the data that is added to anot...

Page 189: ...tion is similar to P instruction and INC P instruction described later except for the contents shown in the table below Operation error There is no operation error Device Name Description SM700 SM8022 Carry When the operation result exceeds the upper limit of the data setting range the carry flag is turned ON SM8020 Zero When the operation result is 0 the zero flag is turned ON SM8021 Borrow When ...

Page 190: ...ssing is executed In this case the carry flag SM700 SM8022 does not turn ON Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s P Subtrahend data or the device where the data to be subtracted from another is stored 32768 to 32767 16 bit signed binary ANY16_S P _U 0 to 65535 16 bit unsigned binary ANY16_U d P Device where the data ...

Page 191: ...7 BASIC INSTRUCTIONS 7 2 Arithmetic Operation Instructions 189 7 Operation error There is no operation error ...

Page 192: ...n Range Data type Data type label s1 P Minuend data or the device where the data from which another is to be subtracted is stored 32768 to 32767 16 bit signed binary ANY16_S P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 P Subtrahend data or the device where the data to be subtracted from another is stored 32768 to 32767 16 bit signed binary ANY16_S P _U 0 to 65535 16 bit unsigned binary ANY16_...

Page 193: ... underflow or overflow occurs in the operation result the following processing is executed In this case the carry flag SM700 SM8022 does not turn ON Operation error There is no operation error In case of P In case of P _U b15 b0 5678 BIN s1 s2 d 1234 BIN 4444 BIN b15 b0 b15 b0 b15 b0 32768 BIN s1 s2 d 2 BIN 32766 BIN b15 b0 b15 b0 b15 b0 32767 BIN s1 s2 d 2 BIN 32767 BIN b15 b0 b15 b0 b15 b0 0 BIN...

Page 194: ...BP EN s1 s2 d ENO SUB_U EN s1 s2 d ENO SUBP_U EN s1 s2 d FBD LD 1 SUBP SUB_U SUBP_U enters Operand Description Range Data type Data type label s1 SUB P Minuend data or the device where the data from which another is to be subtracted is stored 32768 to 32767 16 bit signed binary ANY16_S SUB P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 SUB P Subtrahend data or the device where the data to be su...

Page 195: ...instruction is similar to P instruction and DEC P instruction described later except for the contents shown in the table below Operation error There is no operation error Device Name Description SM700 SM8022 Carry When the operation result exceeds the upper limit of the data setting range the carry flag is turned ON SM8020 Zero When the operation result is 0 the zero flag is turned ON SM8021 Borro...

Page 196: ... ON Operation error There is no operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s D P Addend data or the head device where the data that is added to another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S D P _U 0 to 4294967295 32 bit unsigned binary ANY32_U d D P Head device where the data to whi...

Page 197: ... Data type label s1 D P Augend data or the head device where the data to which another is added is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S D P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 D P Addend data or the head device where the data that is added to another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S D P _U 0 to 4294967295 32 bit unsigned binar...

Page 198: ...operation result the following processing is executed In this case the carry flag SM700 SM8022 does not turn ON Operation error There is no operation error In case of D P In case of D P _U b0 567890 BIN s1 123456 BIN 691346 BIN s1 1 s2 s2 1 d d 1 b31 b16 b15 b0 b31 b16 b15 b0 b31 b16 b15 b15 b0 2147483647 BIN 2 BIN 2147483647 BIN b15 b0 b15 b0 b15 b0 2147483648 BIN 2 BIN 2147483646 BIN b15 b0 b15 ...

Page 199: ... or the head device where the data that is added to another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DADD P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DADD P Addend data or the head device where the data that is added to another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DADD P _U 0 to 4294967295 32 bit unsigned binary ANY32_U d DADD P Head dev...

Page 200: ... D P instruction and DINC P instruction in a program for adding 1 When DADD P instruction is used to add 1 to the contents of D0 every time X1 turns from OFF to ON DADD P instruction is similar to D P instruction and DINC P instruction described later except for the contents shown in the table below Operation error There is no operation error Device Name Description SM700 SM8022 Carry When the ope...

Page 201: ...diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s D P Subtrahend data or the head device where the data to be subtracted from another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S D P _U 0 to 4294967295 32 bit unsigned binary ANY32_U d D P Head device where the data from which another is to be subtracted is stored 214...

Page 202: ...200 7 BASIC INSTRUCTIONS 7 2 Arithmetic Operation Instructions Operation error There is no operation error ...

Page 203: ... type label s1 D P Minuend data or the head device where the data from which another is to be subtracted is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S D P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 D P Subtrahend data or the head device where the data to be subtracted from another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S D P _U 0 to 4294967295 32 ...

Page 204: ...processing is executed In this case the carry flag SM700 SM8022 does not turn ON Operation error There is no operation error In case of D P In case of D P _U b0 567890 BIN s1 123456 BIN 444434 BIN s1 1 s2 s2 1 d d 1 b31 b16 b15 b0 b31 b16 b15 b0 b31 b16 b15 b15 b0 2147483648 BIN 2 BIN 2147483646 BIN b15 b0 b15 b0 b15 b0 2147483647 BIN 2 BIN 2147483647 BIN b15 b0 b15 b0 s1 s1 1 s2 s2 1 d d 1 s1 s1 ...

Page 205: ...ead device where the data from which another is to be subtracted is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DSUB P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DSUB P Subtrahend data or the head device where the data to be subtracted from another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DSUB P _U 0 to 4294967295 32 bit unsigned binary ANY32_U d D...

Page 206: ...on D P instruction and DDEC P instruction in a program for subtracting 1 When DSUB P instruction is used to subtract 1 from the contents of D0 every time X1 turns from OFF to ON SUB P instruction is similar to D P instruction and DDEC P instruction described later except for the contents shown in the table below Operation error There is no operation error Device Name Description SM700 SM8022 Carry...

Page 207: ...ructured text 1 ENO MULTI EN s1 s2 d ENO MULTIP EN s1 s2 d ENO MULTI_U EN s1 s2 d ENO MULTIP_U EN s1 s2 d FBD LD MULTI MULTIP MULTI_U MULTIP_U enters Operand Description Range Data type Data type label s1 P Multiplicand data or the device where the data to be multiplied by another is stored 32768 to 32767 16 bit signed binary ANY16_S P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 P Multiplier d...

Page 208: ...206 7 BASIC INSTRUCTIONS 7 2 Arithmetic Operation Instructions Operation error Error code SD0 SD8067 Description 2820H The range of the device specified by d exceeds said device range ...

Page 209: ...enters Operand Description Range Data type Data type label s1 MUL P Multiplicand data or the device where the data to be multiplied by another is stored 32768 to 32767 16 bit signed binary ANY16_S MUL P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 MUL P Multiplier data or the device where the data by which another is to be multiplied is stored 32768 to 32767 16 bit signed binary ANY16_S MUL P _...

Page 210: ... can be obtained out of the product 32 bits Related flag Operation error 1 Not output 2 K2Y0 operation result is output Device Name Description SM8304 Zero When the operation result is 0 the zero flag is turned ON Error code SD0 SD8067 Description 2820H The range of the device specified by d exceeds said device range b15 b0 5678 BIN s1 s2 1234 BIN 7006652 BIN b15 b0 d d 1 b0 b31 b16 b15 MUL K53 K1...

Page 211: ...IVISON DIVISIONP DIVISION_U DIVISIONP_U enters Operand Description Range Data type Data type label s1 P Dividend data or the device where the data to be divided by another is stored 32768 to 32767 16 bit signed binary ANY16_S P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 P Divisor data or the device where the data by which another is to be divided is stored 32768 to 32767 16 bit signed binary ...

Page 212: ...32 bit is used for word device to store the quotient and remainder and 16 bit is used for bit device to store quotient only Operation error d Quotient d 1 Remainder Quotient Stored in the lower 16 bits Remainder Stored in the upper 16 bits This data can be stored for word device only Error code SD0 SD8067 Description 2820H The range of the device specified by d exceeds the range of said device 340...

Page 213: ... ENO DIV_U EN s1 s2 d ENO DIVP_U EN s1 s2 d FBD LD 1 DIVP DIV_U DIVP_U enters Operand Description Range Data type Data type label s1 DIV P Dividend data or the device where the data to be divided by another is stored 32768 to 32767 16 bit signed binary ANY16_S DIV P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 DIV P Divisor data or the device where the data by which another is to be divided is ...

Page 214: ... specified with nibble specification Operation error Device Name Description SM700 Carry When the operation result of the signed operation exceeds 32767 the carry flag is turned ON SM8304 Zero When the operation result is 0 the zero flag is turned ON SM8306 Carry When the operation result of the signed operation exceeds 32767 the carry flag is turned ON Error code SD0 SD8067 Description 2820H The ...

Page 215: ..._U DMULTIP_U enters Operand Description Range Data type Data type label s1 D P Multiplicand data or the head device where the data to be multiplied by another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S D P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 D P Multiplier data or the head device where the data by which another is to be multiplied is stored 2147483648 to 21474...

Page 216: ... specified If the upper 32 bits data of the multiplication operation result are required temporarily store the result in a word device and transfer the data stored in word device d 2 and d 3 to the specified bit devices Ex Multiplication result when d is a bit device Operation error K1 Lower 4 bits b0 to b3 K4 Lower 16 bits b0 to b15 K8 Lower 32 bits b0 to b31 Error code SD0 SD8067 Description 282...

Page 217: ...ata to be multiplied by another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DMUL P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DMUL P Multiplier data or the head device where the data by which another is to be multiplied is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DMUL P _U 0 to 4294967295 32 bit unsigned binary ANY32_U d DMUL P Head device for stor...

Page 218: ... flag Precautions Even if word devices are used the operation result 64 bits binary data cannot be monitored at one time In such a case a floating point operation is recommended Operation error Device Name Description SM8304 Zero When the operation result is 0 the zero flag is turned ON Error code SD0 SD8067 Description 2820H The range of the device specified by d exceeds the range of said device ...

Page 219: ...1 ENO DDIVISION EN s1 s2 d ENO DDIVISIONP EN s1 s2 d ENO DDIVISION_U EN s1 s2 d ENO DDIVISIONP_U EN s1 s2 d FBD LD DDIVISION DDIVISIONP DDIVISION_U DDIVISIONP_U enters Operand Description Range Data type Data type label s1 D P Dividend data or the head device where the data to be divided by another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S D P _U 0 to 4294967295 32 bit unsign...

Page 220: ... INSTRUCTIONS 7 2 Arithmetic Operation Instructions Operation error Error code SD0 SD8067 Description 2820H The range of the device specified by d exceeds the range of said device 3400H 0 is specified for s2 value ...

Page 221: ... 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DDIV P Divisor data or the head device where the data by which another is to be divided is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DDIV P _U 0 to 4294967295 32 bit unsigned binary ANY32_U d DDIV P Head device for storing the operation result 64 bit signed binary ANY32_S_ARRAY Number of elements 2 DDIV P _U 64 bit unsigned bina...

Page 222: ...n either s1 or s2 is negative The remainder is negative when the s1 is negative Device specified by d The remainder is not obtained when a bit device is specified with nibble specification Operation error Error code SD0 SD8067 Description 2820H The range of the device specified by d exceeds the range of said device 3400H 0 is specified for s2 value 3403H Signed operation is performed and the opera...

Page 223: ...ceeds 9999 carry is ignored In this case the carry flag SM700 does not turn ON Operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Addend data or the device where the data that is added to another is stored 0 to 9999 BCD 4 digit ANY16 d Device where the data to which another is added is stored 0 to 9999 BCD 4 digit...

Page 224: ...ed text ENO BPLUS EN s1 s2 d ENO BPLUSP EN s1 s2 d FBD LD BPLUS BPLUSP enters Operand Description Range Data type Data type label s1 Augend data or the device where the data to which another is added is stored 0 to 9999 BCD 4 digit ANY16 s2 Addend data or the device where the data that is added to another is stored 0 to 9999 BCD 4 digit ANY16 d Device for storing the operation result 0 to 9999 BCD...

Page 225: ...will be as follows In this case the carry flag SM700 does not turn ON Operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Subtrahend data or the device where the data to be subtracted from another is stored 0 to 9999 BCD 4 digit ANY16 d Device where the data from which another is to be subtracted is stored 0 to 999...

Page 226: ...INUS EN s1 s2 d ENO BMINUSP EN s1 s2 d FBD LD BMINUS BMINUSP enters Operand Description Range Data type Data type label s1 Minuend data or the device where the data from which another is to be subtracted is stored 0 to 9999 BCD 4 digit ANY16 s2 Subtrahend data or the device where the data to be subtracted from another is stored 0 to 9999 BCD 4 digit ANY16 d Device for storing the operation result ...

Page 227: ...t turn ON Operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Addend data or the head device where the data that is added to another is stored 0 to 99999999 BCD 8 digit ANY32 d Head device where the data to which another is added is stored 0 to 99999999 BCD 8 digit ANY32 Operand Bit Word Double word Indirect specif...

Page 228: ... Operand Description Range Data type Data type label s1 Augend data or the head device where the data to which another is added is stored 0 to 99999999 BCD 8 digit ANY32 s2 Addend data or the head device where the data that is added to another is stored 0 to 99999999 BCD 8 digit ANY32 d Head device for storing the operation result 0 to 99999999 BCD 8 digit ANY32 EN Execution condition Bit BOOL ENO...

Page 229: ...dder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Subtrahend data or the device where the data to be subtracted from another is stored 0 to 99999999 BCD 8 digit ANY32 d Minuend data or the device where the data from which another is to be subtracted is stored 0 to 99999999 BCD 8 digit ANY32 Operand Bit Word Double word Indirect sp...

Page 230: ...ata type label s1 Minuend data or the head device where the data from which another is to be subtracted is stored 0 to 99999999 BCD 8 digit ANY32 s2 Subtrahend data or the head device where the data to be subtracted from another is stored 0 to 99999999 BCD 8 digit ANY32 d Head device for storing the operation result 0 to 99999999 BCD 8 digit ANY32 EN Execution condition Bit BOOL ENO Execution resu...

Page 231: ... Data type Data type label s1 Multiplicand data or the device where the data to be multiplied by another is stored 0 to 9999 BCD 4 digit ANY16 s2 Multiplier data or the device where the data by which another is to be multiplied is stored 0 to 9999 BCD 4 digit ANY16 d Head device for storing the operation result BCD 8 digit ANY32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand...

Page 232: ...ored Ladder diagram Structured text Not supported FBD LD BDIVISION BDIVISIONP enters Operand Description Range Data type Data type label s1 Dividend data or the device where the data to be divided by another is stored 0 to 9999 BCD 4 digit ANY16 s2 Divisor data or the device where the data by which another is to be divided is stored 0 to 9999 BCD 4 digit ANY16 d Head device for storing the operati...

Page 233: ...code SD0 SD8067 Description 2820H Device specified by d exceeds the allowable device range 3400H 0 is specified for s2 value 3405H BCD data in the device specified by s1 is outside of the valid range 0 to 9999 BCD data in the device specified by s2 is outside of the valid range 0 to 9999 ...

Page 234: ...scription Range Data type Data type label s1 Multiplicand data or the head device where the data to be multiplied by another is stored 0 to 99999999 BCD 8 digit ANY32 s2 Multiplier data or the head device where the data by which another is to be multiplied is stored 0 to 99999999 BCD 8 digit ANY32 d Head device for storing the operation result BCD 16 digit ANY32_ARRAY Number of elements 2 EN Execu...

Page 235: ...he higher 8 nibbles 32 bits cannot be specified Ex Multiplication result when d is a bit device Operation error K1 Lower 1 nibble b0 to b3 K4 Lower 4 nibbles b0 to b15 K8 Lower 8 nibbles b0 to b31 Error code SD0 SD8067 Description 2820H Device specified by d exceeds the allowable device range 3405H BCD data in the device specified by s1 is outside of the valid range 0 to 99999999 BCD data in the d...

Page 236: ...and Description Range Data type Data type label s1 Dividend data or the head device where the data to be divided by another is stored 0 to 99999999 BCD 8 digit ANY32 s2 Divisor data or the head device where the data by which another is to be divided is stored 0 to 99999999 BCD 8 digit ANY32 d Head device for storing the operation result BCD 16 digit ANY32_ARRAY Number of elements 2 EN Execution co...

Page 237: ... is not stored Operation error d 1 d 3 d d 2 Upper 4 digits Lower 4 digits Quotient BCD 8 digit Stored in lower 32 bit s Remainder BCD 8 digit Stored in upper 32 bit s Error code SD0 SD8067 Description 2820H Device specified by d exceeds the allowable device range 3400H 0 is specified for s2 value 3405H BCD data in the device specified by s1 is outside of the valid range 0 to 99999999 BCD data in ...

Page 238: ...ers Operand Description Range Data type Data type label s1 BK P Head device where the data to which another data is added is stored 32768 to 32767 16 bit signed binary ANY16_S BK P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 BK P Addend data or the head device where the data that is added to another is stored 32768 to 32767 16 bit signed binary ANY16_S BK P _U 0 to 65535 16 bit unsigned binary...

Page 239: ... the device specified by s1 s2 or d exceed the corresponding device range 2821H The device range for n point s beginning from s1 overlaps with that of n point s starting from d Does not apply when same device has been specified for s1 and d The device range for n point s beginning from s2 overlaps with that of n point s starting from d Does not apply when same device has been specified for s2 and ...

Page 240: ...rs Operand Description Range Data type Data type label s1 BK P Head device where the data from which another is to be subtracted is stored 32768 to 32767 16 bit signed binary ANY16_S BK P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 BK P Subtrahend data or the head device where the data to be subtracted from another is stored 32768 to 32767 16 bit signed binary ANY16_S BK P _U 0 to 65535 16 bit...

Page 241: ...om the device specified by s1 s2 or d exceed the corresponding device range 2821H The device range for n point s beginning from s1 overlaps with that of n point s starting from d Does not apply when same device has been specified for s1 and d The device range for n point s beginning from s2 overlaps with that of n point s starting from d Does not apply when same device has been specified for s2 an...

Page 242: ...perand Description Range Data type Data type label s1 DBK P Head device where the data to which another is added is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DBK P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DBK P Addend data or the head device where the data that is added to another is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DBK P _U 0 to 429496729...

Page 243: ...rs for operation result the result will be as follows In this case the carry flag SM700 does not turn ON 1 Because it is a perfect match operation is possible 1 An operation error occurs if they partially match If signed is specified If unsigned is specified 20000 60000 60000 40000 n 30000 BIN 40000 BIN 50000 BIN 60000 BIN n b31 b0 50000 BIN 20000 BIN 10000 BIN 20000 BIN BIN BIN BIN BIN n b31 b0 s...

Page 244: ...ied by s1 s2 or d exceed the corresponding device range 2821H The device range for n point s beginning from s1 overlaps with that of n point s starting from d Does not apply when same device has been specified for s1 and d The device range for n point s beginning from s2 overlaps with that of n point s starting from d Does not apply when same device has been specified for s2 and d ...

Page 245: ...2 n d ENO DBKMINUSP EN s1 s2 n d ENO DBKMINUS_U EN s1 s2 n d ENO DBKMINUSP_U EN s1 s2 n d FBD LD DBKMINUS DBKMINUSP DBKMINUS_U DBKMINUSP_U enters Operand Description Range Data type Data type label s1 DBK P Head device where the data from which another is to be subtracted is stored 2147483648 to 2147483647 32 bit signed binary ANY32_S DBK P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DBK ...

Page 246: ...xceed the corresponding device range 2821H The device range for n point s beginning from s1 overlaps with that of n point s starting from d Does not apply when same device has been specified for s1 and d The device range for n point s beginning from s2 overlaps with that of n point s starting from d Does not apply when same device has been specified for s2 and d 1000000 30000 54444 1234 n 55555 BI...

Page 247: ... the device specified by d If unsigned is specified Flags zero carry and borrow are not activated at this time Precautions Note that data is incremented in every operation cycle in a continuous operation type INC instruction Operation error There is no operation error Ladder diagram Structured text ENO INC EN d ENO INCP EN d ENO INC_U EN d ENO INCP_U EN d FBD LD Operand Description Range Data type...

Page 248: ... in the device specified by d If unsigned is specified Flags zero carry and borrow are not activated at this time Precautions Note that data is decremented in every operation cycle in a continuous operation type DEC instruction Operation error There is no operation error Ladder diagram Structured text ENO DEC EN d ENO DECP EN d ENO DEC_U EN d ENO DECP_U EN d FBD LD Operand Description Range Data t...

Page 249: ...ce specified by d If unsigned is specified Flags zero carry and borrow are not activated at this time Precautions Note that data is incremented in every operation cycle in a continuous operation type instruction Operation error There is no operation error Ladder diagram Structured text ENO DINC EN d ENO DINCP EN d ENO DINC_U EN d ENO DINCP_U EN d FBD LD Operand Description Range Data type Data typ...

Page 250: ...fied by d If unsigned is specified Flags zero carry and borrow are not activated at this time Precautions Note that data is decremented in every operation cycle in a continuous operation type DDEC instruction Operation error There is no operation error Ladder diagram Structured text ENO DDEC EN d ENO DDECP EN d ENO DDEC_U EN d ENO DDECP_U EN d FBD LD Operand Description Range Data type Data type l...

Page 251: ...from device specified by s and store the results in the device specified by d Bit devices subsequent to number of points by nibble specification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Data for AND or device where the data is stored 32768 to 32767 16 bit s...

Page 252: ...bble specification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text ENO WAND EN s1 s2 d ENO WANDP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Data for AND or device where the data is stored 32768 to 32767 16 bit signed binary ANY16 s2 Data for AND or device where the data is stored 32768 to 32767 16 bit signed binary ANY16 ...

Page 253: ...he results in the device specified by d Bit devices subsequent to number of points by nibble specification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Data for AND or head device where the data is stored 2147483648 to 2147483647 32 bit signed binary ANY32 d He...

Page 254: ...culated as 0 Operation error There is no operation error Ladder diagram Structured text ENO DAND EN s1 s2 d ENO DANDP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Data for AND or head device where the data is stored 2147483648 to 2147483647 32 bit signed binary ANY32 s2 Data for AND or head device where the data is stored 2147483648 to 2147483647 32 bit signed binary AN...

Page 255: ...on Range Data type Data type label s1 Head device that stores data for AND 32768 to 32767 16 bit signed binary ANY16 s2 Data for AND or head device where the data is stored 32768 to 32767 16 bit signed binary ANY16 d Head device for storing AND results 16 bit signed binary ANY16 n Number of data 0 to 65535 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL O...

Page 256: ...ecified by s1 s2 or d exceed the corresponding device range 2821H Device range of n point s from s1 partially overlaps with device range of n point s from d Does not apply when same device has been specified for s1 and d Device range of n point s from s2 partially overlaps with device range of n point s from d Does not apply when same device has been specified for s2 and d ...

Page 257: ...y s and store the results in the device specified by d Bit devices subsequent to number of points by nibble specification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Data for OR or head device where data is stored 32768 to 32767 16 bit signed binary ANY16 d He...

Page 258: ... specification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text ENO WOR EN s1 s2 d ENO WORP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Data for OR or head device where data is stored 32768 to 32767 16 bit signed binary ANY16 s2 Data for OR or head device where data is stored 32768 to 32767 16 bit signed binary ANY16 d Head...

Page 259: ...e results in the device specified by d Bit devices subsequent to number of points by nibble specification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Data for OR or head device where data is stored 2147483648 to 2147483647 32 bit signed binary ANY32 d Head dev...

Page 260: ... calculated as 0 Operation error There is no operation error Ladder diagram Structured text ENO DOR EN s1 s2 d ENO DORP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Data for OR or head device where data is stored 2147483648 to 2147483647 32 bit signed binary ANY32 s2 Data for OR or head device where data is stored 2147483648 to 2147483647 32 bit signed binary ANY32 d He...

Page 261: ... s2 n d ENO BKORP EN s1 s2 n d FBD LD Operand Description Range Data type Data type label s1 Head device where the logical operation data is stored 32768 to 32767 16 bit signed binary ANY16 s2 Logical operation data or the head device where the logical operation data is stored 32768 to 32767 16 bit signed binary ANY16 d Head device for storing the operation result 16 bit signed binary ANY16 n Numb...

Page 262: ... point s from s1 partially overlaps with device range of n point s from d Does not apply when same device has been specified for s1 and d Device range of n point s from s2 partially overlaps with device range of n point s from d Does not apply when same device has been specified for s2 and d 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 1 0 0 0 0 b7 1 1 1 1 1 1 0 0 1 1 1 1 1 1 0 0 1 1 0 0 ...

Page 263: ...d by s and store the results in the device specified by d Bit devices subsequent to number of points by nibble specification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Data for exclusive OR or head device where data is stored 32768 to 32767 16 bit signed bina...

Page 264: ...cification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text ENO WXOR EN s1 s2 d ENO WXORP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Data for exclusive OR or head device where data is stored 32768 to 32767 16 bit signed binary ANY16 s2 Data for exclusive OR or head device where data is stored 32768 to 32767 16 bit signed b...

Page 265: ... the results in the device specified by d Bit devices subsequent to number of points by nibble specification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Data for exclusive OR or head device where data is stored 2147483648 to 2147483647 32 bit signed binary ANY...

Page 266: ...culated as 0 Operation error There is no operation error Ladder diagram Structured text ENO DXOR EN s1 s2 d ENO DXORP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Data for exclusive OR or head device where data is stored 2147483648 to 2147483647 32 bit signed binary ANY32 s2 Data for exclusive OR or head device where data is stored 2147483648 to 2147483647 32 bit signed...

Page 267: ...ange Data type Data type label s1 Data for exclusive OR or head device where data is stored 32768 to 32767 16 bit signed binary ANY16 s2 Data for exclusive OR or head device where data is stored 32768 to 32767 16 bit signed binary ANY16 d Head device for storing the operation result 16 bit signed binary ANY16 n Number of data 0 to 65535 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ...

Page 268: ...ecified by s1 s2 or d exceed the corresponding device range 2821H Device range of n point s from s1 partially overlaps with device range of n point s from d Does not apply when same device has been specified for s1 and d Device range of n point s from s2 partially overlaps with device range of n point s from d Does not apply when same device has been specified for s2 and d ...

Page 269: ...d by s and store the results in the device specified by d Bit devices subsequent to number of points by nibble specification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Data for exclusive NOR or head device where data is stored 32768 to 32767 16 bit signed bin...

Page 270: ...ification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text ENO WXNR EN s1 s2 d ENO WXNRP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Data for exclusive NOR or head device where data is stored 32768 to 32767 16 bit signed binary ANY16 s2 Data for exclusive NOR or head device where data is stored 32768 to 32767 16 bit signed ...

Page 271: ... the results in the device specified by d Bit devices subsequent to number of points by nibble specification are calculated as 0 Operation error There is no operation error Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label s Data for exclusive NOR or head device where data is stored 2147483648 to 2147483647 32 bit signed binary AN...

Page 272: ...ulated as 0 Operation error There is no operation error Ladder diagram Structured text ENO DXNR EN s1 s2 d ENO DXNRP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Data for exclusive NOR or head device where data is stored 2147483648 to 2147483647 32 bit signed binary ANY32 s2 Data for exclusive NOR or head device where data is stored 2147483648 to 2147483647 32 bit signe...

Page 273: ...R EN s1 s2 n d ENO BKXNRP EN s1 s2 n d FBD LD Operand Description Range Data type Data type label s1 Head device where the logical operation data is stored 32768 to 32767 16 bit signed binary ANY16 s2 Logical operation data or the head device where the logical operation data is stored 32768 to 32767 16 bit signed binary ANY16 d Head device for storing the operation result 16 bit signed binary ANY1...

Page 274: ...n point s from s1 partially overlaps with device range of n point s from d Does not apply when same device has been specified for s1 and d Device range of n point s from s2 partially overlaps with device range of n point s from d Does not apply when same device has been specified for s2 and d 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 1 0 0 0 0 b7 1 1 0 0 0 0 1 1 1 1 0 0 0 0 1 1 1 1 0 0...

Page 275: ...of n Operation error There is no operation error Ladder diagram Structured text ENO BSET EN n d ENO BSETP EN n d FBD LD Operand Description Range Data type Data type label d Head device for which bit is to be set 16 bit signed binary ANY16 n Number of bit s to be set 0 to 15 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indi...

Page 276: ...or There is no operation error Ladder diagram Structured text ENO BRST EN n d ENO BRSTP EN n d FBD LD Operand Description Range Data type Data type label d Head device for which bit is to be reset 16 bit signed binary ANY16 n Number of bit s to be reset 0 to 15 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specifica...

Page 277: ...f word data If 16 or more is specified for s2 the value of the remainder of s2 16 is the bit position Ex For s2 18 the remainder for 18 16 is 2 so it becomes data of b2 Ladder diagram Structured text ENO TEST EN s1 s2 d ENO TESTP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Device number where bit data to be extracted is stored 16 bit signed binary ANY16 s2 Position of ...

Page 278: ...276 7 BASIC INSTRUCTIONS 7 4 Bit Processing Instructions Operation error There is no operation error ...

Page 279: ...word data If 32 or more is specified for s2 the value of the remainder of s2 32 is the bit position Ex For s2 34 the remainder for 34 32 is 2 so it becomes data of b2 Ladder diagram Structured text ENO DTEST EN s1 s2 d ENO DTESTP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Device number where bit data to be extracted is stored 32 bit signed binary ANY32 s2 Position of ...

Page 280: ...278 7 BASIC INSTRUCTIONS 7 4 Bit Processing Instructions Operation error There is no operation error ...

Page 281: ...ary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E d n Device Status Annunciator F n point s from annunciator F number specified by d are turned OFF Annunciator numbers from SD64 to SD79 that were turned OFF are deleted and the subsequent numbers are shi...

Page 282: ...he entire range of devices from d1 to d2 all at once if d1 and or d2 are word devices Ladder diagram Structured text ENO ZRST EN d1 d2 ENO ZRSTP EN d1 d2 FBD LD Operand Description Range Data type Data type label d1 Head bit or word device number to be reset Bit 16 bit signed binary ANY_ELEMENTARY d2 Last bit or word device number to be reset Bit 16 bit signed binary ANY_ELEMENTARY EN Execution co...

Page 283: ...ber only the device specified by d1 is reset The ZRST P instruction is a 16 bit instruction but long counter LC and long index register LZ can be specified for d1 and d2 Operation error 1 M0 is reset 2 The current value of T0 is reset 3 D0 is reset 1 K0 is written to D0 to D99 Error code SD0 SD8067 Description 2820H The number of devices to be reset is 32768 or more when module access device has b...

Page 284: ... by s to BCD 4 digit data and store the converted data in the device specified by d Ladder diagram Structured text ENO BCD EN s d ENO BCDP EN s d FBD LD Operand Description Range Data type Data type label s Binary data or the head device where the binary data is stored 0 to 9999 16 bit signed binary ANY16 d Head device for storing the BCD data BCD 4 digit ANY16 EN Execution condition Bit BOOL ENO ...

Page 285: ...ary coded decimal BCD format into a CPU module use the BIN P instructions for converting BCD data into binary data Furthermore to output data to seven segment display unit handling binary coded decimal BCD data use the BCD P instructions for converting binary data into BCD data Operation error d Number of digits Data range K1Y0 1 digit 0 to 9 K2Y0 2 digit 00 to 99 K3Y0 3 digit 000 to 999 K4Y0 4 di...

Page 286: ...N s d FBD LD Operand Description Range Data type Data type label s Binary data or the head device where the binary data is stored 0 to 99999999 32 bit signed binary ANY32 d Head device for storing the BCD data BCD 8 digit ANY32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G...

Page 287: ...CD format into a CPU module use the BIN P instructions for converting BCD data into binary data Furthermore to output data to seven segment display unit handling binary coded decimal BCD data use the BCD P instructions for converting binary data into BCD data Operation error d 1 d Number of digits Data range K1Y0 1 digit 0 to 9 K2Y0 2 digit 00 to 99 K3Y0 3 digit 000 to 999 K4Y0 4 digit 0000 to 999...

Page 288: ...specified by s to 16 bit binary data and store the converted data in the device specified by d Ladder diagram Structured text ENO BIN EN s d ENO BINP EN s d FBD LD Operand Description Range Data type Data type label s Binary coded decimal data or the head device where the binary coded decimal data is stored 0 to 9999 BCD 4 digit ANY16 d Head device for storing the binary data 16 bit signed binary ...

Page 289: ...D format into a CPU module use the BIN P instructions for converting BCD data into binary data Furthermore to output data to seven segment display unit handling binary coded decimal BCD data use the BCD P instructions for converting binary data into BCD data Operation error d Number of digits Data range K1X0 1 digit 0 to 9 K2X0 2 digit 00 to 99 K3X0 3 digit 000 to 999 K4X0 4 digit 0000 to 9999 Err...

Page 290: ...cified by d Ladder diagram Structured text ENO DBIN EN s d ENO DBINP EN s d FBD LD Operand Description Range Data type Data type label s Binary coded decimal data or the head device where the binary coded decimal data is stored 0 to 99999999 BCD 8 digit ANY32 d Head device for storing the binary data 32 bit signed binary ANY32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand B...

Page 291: ... data Furthermore to output data to seven segment display unit handling binary coded decimal BCD data use the BCD instruction for converting binary data into BCD data Operation error s 1 s Number of digits Data range K1X0 1 digit 0 to 9 K2X0 2 digit 00 to 99 K3X0 3 digit 000 to 999 K4X0 4 digit 0000 to 9999 K5X0 5 digit 00000 to 99999 K6X0 6 digit 000000 to 999999 K7X0 7 digit 0000000 to 9999999 K...

Page 292: ... of the single precision real number specified with s are truncated Operation error Ladder diagram Structured text 1 ENO FLT2INT EN s d ENO FLT2INTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 32768 to 32767 Single precision real number ANYREAL_32 d Data after conversion 16 bit signed binary ANY16_S EN Execution condition Bit BOOL ENO Execution result...

Page 293: ... point of the single precision real number specified with s are truncated Operation error Ladder diagram Structured text 1 ENO FLT2UINT EN s d ENO FLT2UINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 0 to 65535 Single precision real number ANYREAL_32 d Data after conversion 16 bit unsigned binary ANY16_U EN Execution condition Bit BOOL ENO Execution ...

Page 294: ... real number specified with s are truncated Operation error Ladder diagram Structured text 1 ENO FLT2DINT EN s d ENO FLT2DINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 2147483648 to 2147483647 Single precision real number ANYREAL_32 d Data after conversion 32 bit signed binary ANY32_S EN Execution condition Bit BOOL ENO Execution result Bit BOOL Op...

Page 295: ...e precision real number specified with s are truncated Operation error Ladder diagram Structured text 1 ENO FLT2UDINT EN s d ENO FLT2UDINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 0 to 4294967295 Single precision real number ANYREAL_32 d Data after conversion 32 bit unsigned binary ANY32_U EN Execution condition Bit BOOL ENO Execution result Bit B...

Page 296: ...cified by s to 16 bit unsigned binary data and store the result in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO INT2UINT EN s d ENO INT2UINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 32768 to 32767 16 bit signed binary ANY16_S d Data after conversion 16 bit unsigned binary ANY16_U EN Exe...

Page 297: ...onverted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO INT2DINT EN s d ENO INT2DINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 32768 to 32767 16 bit signed binary ANY16_S d Data after conversion 32 bit signed binary ANY32_S EN Execution condition Bit BOOL ENO Execution result Bit B...

Page 298: ...data and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO INT2UDINT EN s d ENO INT2UDINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 32768 to 32767 16 bit signed binary ANY16_S d Data after conversion 32 bit unsigned binary ANY32_U EN Execution condition Bit BOOL EN...

Page 299: ...e specified by s to 16 bit signed binary data and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO UINT2INT EN s d ENO UINT2INTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 0 to 65535 16 bit unsigned binary ANY16_U d Data after conversion 16 bit signed binary ANY16_S...

Page 300: ...y data and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO UINT2DINT EN s d ENO UINT2DINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 0 to 65535 16 bit unsigned binary ANY16_U d Data after conversion 32 bit signed binary ANY32_S EN Execution condition Bit BOOL ENO ...

Page 301: ...ary data and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO UINT2UDINT EN s d ENO UINT2UDINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 0 to 65535 16 bit unsigned binary ANY16_U d Data after conversion 32 bit unsigned binary ANY32_U EN Execution condition Bit BOO...

Page 302: ...ry data and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO DINT2INT EN s d ENO DINT2INTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 2147483648 to 2147483647 32 bit signed binary ANY32_S d Data after conversion 16 bit signed binary ANY16_S EN Execution condition Bi...

Page 303: ...nary data and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO DINT2UINT EN s d ENO DINT2UINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 2147483648 to 2147483647 32 bit signed binary ANY32_S d Data after conversion 16 bit unsigned binary ANY16_U EN Execution condit...

Page 304: ...nary data and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO DINT2UDINT EN s d ENO DINT2UDINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 2147483648 to 2147483647 32 bit signed binary ANY32_S d Data after conversion 32 bit unsigned binary ANY32_U EN Execution cond...

Page 305: ...ed binary data and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO UDINT2INT EN s d ENO UDINT2INTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 0 to 4294967295 32 bit unsigned binary ANY32_U d Data after conversion 16 bit signed binary ANY16_S EN Execution condition ...

Page 306: ...ed binary data and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO UDINT2UINT EN s d ENO UDINT2UINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 0 to 4294967295 32 bit unsigned binary ANY32_U d Data after conversion 16 bit unsigned binary ANY16_U EN Execution condit...

Page 307: ...ned binary data and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO UDINT2DINT EN s d ENO UDINT2DINTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 0 to 4294967295 32 bit unsigned binary ANY32_U d Data after conversion 32 bit signed binary ANY32_S EN Execution conditi...

Page 308: ... module Operation error There is no operation error Ladder diagram Structured text ENO GRY EN s d ENO GRYP EN s d ENO GRY_U EN s d ENO GRYP_U EN s d FBD LD Operand Description Range Data type Data type label s GRY P Binary data or the head device where the binary data is stored 0 to 32767 16 bit signed binary ANY16_S GRY P _U 0 to 65535 16 bit unsigned binary ANY16_U d GRY P Head device for storin...

Page 309: ...ed text ENO DGRY EN s d ENO DGRYP EN s d ENO DGRY_U EN s d ENO DGRYP_U EN s d FBD LD Operand Description Range Data type Data type label s DGRY P Binary data or the head device where the binary data is stored 0 to 2147483647 32 bit signed binary ANY32_S DGRY P _U 0 to 4294967295 32 bit unsigned binary ANY32_U d DGRY P Head device for storing the gray code data after conversion 32 bit signed binary...

Page 310: ...U module Input filter constant Operation error There is no operation error Ladder diagram Structured text ENO GBIN EN s d ENO GBINP EN s d ENO GBIN_U EN s d ENO GBINP_U EN s d FBD LD Operand Description Range Data type Data type label s GBIN P Gray code data or head device storing the gray code data 0 to 32767 16 bit signed binary ANY16_S GBIN P _U 0 to 65535 16 bit unsigned binary ANY16_U d GBIN ...

Page 311: ...Ladder diagram Structured text ENO DGBIN EN s d ENO DGBINP EN s d ENO DGBIN_U EN s d ENO DGBINP_U EN s d FBD LD Operand Description Range Data type Data type label s DGBIN P Gray code data or head device storing the gray code data 0 to 2147483647 32 bit signed binary ANY32_S DGBIN P _U 0 to 4294967295 32 bit unsigned binary ANY32_U d DGBIN P Head device for storing the binary data after conversion...

Page 312: ...U EN s d ENO DABINP_U EN s d FBD LD Operand Description Range Data type Data type label s ASCII data or the head device where the ASCII data is stored Character string ANYSTRING_SINGLE d DABIN P Head device for storing the converted data 16 bit signed binary ANY16_S DABIN P _U 16 bit unsigned binary ANY16_U EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word ...

Page 313: ...ace of the ASCII code If a value 20H or 00H is set the value will be processed as 30H Operation error Error code SD0 SD8067 Description 2820H The device specified by s exceeds the corresponding device range 3401H The signed data is other than 20H 2DH A value specified by s to s 2 for each place of the ASCII code is other than 30H to 39H 20H and 00H The ASCII data in the device specified by s to s ...

Page 314: ... diagram Structured text ENO DDABIN EN s d ENO DDABINP EN s d ENO DDABIN_U EN s d ENO DDABINP_U EN s d FBD LD Operand Description Range Data type Data type label s ASCII data or the head device where the ASCII data is stored Character string ANYSTRING_SINGLE d DDABIN P Head device for storing the converted data 32 bit signed binary ANY32_S DDABIN P _ U 32 bit unsigned binary ANY32_U EN Execution c...

Page 315: ...eds place ASCII 103 ASCII code for the thousands place ASCII 104 ASCII code for the ten thousands place ASCII 105 ASCII code for the hundred thousands place ASCII 106 ASCII code for the millions place ASCII 107 ASCII code for the ten millions place ASCII 108 ASCII code for billions place ASCII 109 ASCII code for the billions place 1 Ignore 2 Upper 16 bits 3 Lower 16 bits Error code SD0 SD8067 Desc...

Page 316: ...tured text ENO HEXA EN s n d ENO HEXAP EN s n d FBD LD Operand Description Range Data type Data type label s Head device for storing the ASCII data to be converted to hexadecimal code Character string ANYSTRING_SINGLE d Head device for storing the hexadecimal code after conversion 16 bit signed binary ANY16 n Number of characters number of bytes of ASCII data to be converted 1 to 16383 16 bit unsi...

Page 317: ...specified by s In the following program conversion is executed as follows 1 16 bit conversion mode Conversion source data s ASCII data Hexadecimal code D200 low order 30H 0 D200 high order 41H A D201 low order 42H B D201 high order 43H C D202 low order 31H 1 D202 high order 32H 2 D203 low order 33H 3 D203 high order 34H 4 D204 low order 35H 5 Number of specified characters and conversion result in...

Page 318: ...on mode as many points as the number of characters 2 are occupied The SM8161 flag is also used for the RS2 ASCI P CCD P and CRC P instructions When using these instructions and the HEXA P instructions in the same program make sure to set SM8161 to ON or OFF just before each instruction so that SM3161 does not affect another instruction Conversion source data s ASCII data Hexadecimal code D200 30H ...

Page 319: ...n 2820H The n number of devices specified by s and d exceeds the corresponding device range 2821H The range specified by s and d overlaps 3401H An ASCII code other than 30H to 39H and 41H to 46H is set in the device specified by s 3405H The value specified in n is outside the range specified below 1 to 16383 ...

Page 320: ...e number specified by s to a device number storing 00H is handled as a character string Ladder diagram Structured text ENO VAL EN s d1 d2 ENO VALP EN s d1 d2 ENO VAL_U EN s d1 d2 ENO VALP_U EN s d1 d2 FBD LD Operand Description Range Data type Data type label s Character string to be converted to binary data or head device for storing the character string Character string ANYSTRING_SINGLE d1 VAL P...

Page 321: ...umeric value 20H is set in the sign and when representing a negative numeric value 2DH is set 2EH is set in the decimal point When 20H space or 30H 0 exists between the sign and the first non zero number in a character string specified by s 20H or 30H is ignored during conversion to a binary value Ex When 20H exists between the sign and the first non zero number a signed value is specified Ex When...

Page 322: ...ring specified by s is other than 0 to 5 characters The relationship between the total number of characters specified by s and the number of characters of the decimal part is other than that described below Total number of characters 3 Number of characters in the decimal part An ASCII code other than 20H 2DH is set in the sign a signed value is specified An ASCII code other than 30H to 39H and 2EH...

Page 323: ...D LD Operand Description Range Data type Data type label s Character string to be converted to binary data or head device for storing the character string Character string ANYSTRING_SINGLE d1 DVAL P Head device for storing the number of digits of the binary data after conversion 16 bit signed binary ANY16_S_ARRAY Number of elements 2 DVAL P _U 16 bit unsigned binary ANY16_U_ARRAY Number of element...

Page 324: ...racters However be sure to specify Total number of digits 3 or below The range of the character string of the numeric value that can be converted to a binary value is 2147483648 to 2147483647 for a signed value with the decimal point ignored and 0 to 4294967295 for an unsigned value A character string of a numeric value excluding the sign and decimal point can be specified only within the range of...

Page 325: ... device specified in s 3401H The number of characters of the character string specified by s is other than 2 to 13 characters The number of characters of the decimal part of the character string specified by s is other than 0 to 10 characters The relationship between the total number of characters specified by s and the number of characters of the decimal part is other than that described below To...

Page 326: ... Note that data is inverted in every operation cycle in a continuous operation type NEG instruction Operation error There is no operation error Ladder diagram Structured text ENO NEG EN d ENO NEGP EN d FBD LD Operand Description Range Data type Data type label d Head device for storing the data that performs two s complement 32768 to 32767 16 bit signed binary ANY16 EN Execution condition Bit BOOL...

Page 327: ...ns Note that data is inverted in every operation cycle in a continuous operation type DNEG instruction Operation error There is no operation error Ladder diagram Structured text ENO DNEG EN d ENO DNEGP EN d FBD LD Operand Description Range Data type Data type label d Head device for storing the data that performs two s complement 2147483648 to 2147483647 32 bit signed binary ANY32 EN Execution con...

Page 328: ...e contents of the device specified by d do not change The bit device is handled as a device storing one bit data and the word device is handled as a device storing 16 bit data Ladder diagram Structured text ENO DECO EN s n d ENO DECOP EN s n d FBD LD Operand Description Range Data type Data type label s Decode data or device number for storing the decode data Bit 16 bit signed binary ANY_ELEMENTAR...

Page 329: ...ode SD0 SD8067 Description 2820H The device specified by s exceeds the corresponding device range The device specified by d exceeds the corresponding device range 3401H d is specified as a bit device and n is other than 0 to 8 d is specified as a word device and n is other than 0 to 4 ...

Page 330: ... position is processed Operation error Ladder diagram Structured text ENO ENCO EN s n d ENO ENCOP EN s n d FBD LD Operand Description Range Data type Data type label s Head device for storing the encode data Bit 16 bit unsigned binary ANY_ELEMENTARY 1 d Device number for storing the encoding result 16 bit signed binary ANY_ELEMENTARY n Valid bit length 1 to 8 16 bit unsigned binary ANY16 EN Execut...

Page 331: ... text ENO SEGD EN s d ENO SEGDP EN s d FBD LD Operand Description Range Data type Data type label s Head device to be decoded 32768 to 32767 16 bit signed binary ANY16 d Device number storing the data to be displayed in the seven segment display unit 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant...

Page 332: ...ponents d Display data Hexadec imal b3 b2 b1 b0 b15 to b8 b7 b6 b5 b4 b3 b2 b1 b0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 0 0 0 1 0 0 0 0 0 0 0 0 1 1 0 2 0 0 1 0 0 0 0 0 1 0 1 1 0 1 1 3 0 0 1 1 0 0 0 0 1 0 0 1 1 1 1 4 0 1 0 0 0 0 0 0 1 1 0 0 1 1 0 5 0 1 0 1 0 0 0 0 1 1 0 1 1 0 1 6 0 1 1 0 0 0 0 0 1 1 1 1 1 0 1 7 0 1 1 1 0 0 0 0 0 1 0 0 1 1 1 8 1 0 0 0 0 0 0 0 1 1 1 1 1 1 1 9 1 0 0 1 0 0 0 0 1 1 0 1 1 1 ...

Page 333: ...uctured text ENO SEGL EN s n d FBD LD Operand Description Range Data type Data type label s Head device converted into the BCD format 0 to 9999 16 bit signed binary ANY16 d Head Y number to be output bit ANY_BOOL n Parameter number 0 to 7 16 bit unsigned binary ANY16_U EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others ...

Page 334: ... the 4 digit display While the command input is ON the operation is repeated When the command contact is set to OFF in the middle of an operation the operation is paused When the command contact is set to ON again the operation is started from the beginning When one set of 4 digits is used one device is occupied from the device specified in s and eight devices are occupied from the device specifie...

Page 335: ...arting from the one specified by s becomes 0 When n is 0 no processing is performed and the contents of the n number of devices starting from the one specified by d do not change Ladder diagram Structured text ENO DIS EN s n d ENO DISP EN s n d FBD LD Operand Description Range Data type Data type label s Head device for storing the data to be separated 16 bit signed binary ANY16 d Head device stor...

Page 336: ...IC INSTRUCTIONS 7 5 Data Conversion Instructions Operation error Error code SD0 SD8067 Description 2820H The range of n number of points from d exceed the corresponding device range 3401H n is other than 0 to 4 ...

Page 337: ...der 4 n nibble bits of the device specified by d becomes 0 When n is 0 no processing is performed and the contents of the device specified by d do not change Ladder diagram Structured text ENO UNI EN s n d ENO UNIP EN s n d FBD LD Operand Description Range Data type Data type label s Head device for storing the data to be linked 16 bit signed binary ANY16 d Head device for storing the linked data ...

Page 338: ...IC INSTRUCTIONS 7 5 Data Conversion Instructions Operation error Error code SD0 SD8067 Description 2820H The range of n number of points from d exceed the corresponding device range 3401H n is other than 0 to 4 ...

Page 339: ... Ladder diagram Structured text ENO NDIS EN s1 s2 d ENO NDISP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Head device for storing the data to be separated 16 bit signed binary ANY16 d Head device for storing the separated data 16 bit signed binary ANY16 s2 Head device for storing the separation unit 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Executi...

Page 340: ...Operation error s2 to s2 6 Number of bits specified by s2 to s2 6 1 The value 0 indicates the end of setting Error code SD0 SD8067 Description 2820H The usage range of the device specified by s1 or d exceeds the corresponding device range due to the specification of the number of separation bits specified by s2 2821H The s1 s2 devices are overlapping The s1 d devices are overlapping The s2 d devic...

Page 341: ...s Ladder diagram Structured text ENO NUNI EN s1 s2 d ENO NUNIP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Head device for storing the data to be linked 16 bit signed binary ANY16 d Head device for storing the linked data 16 bit signed binary ANY16 s2 Head device for storing the link unit size 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution res...

Page 342: ...r s2 to s2 6 Number of bits specified by s2 to s2 6 1 The value 0 indicates the end of setting Error code SD0 SD8067 Description 2820H The usage range of the device specified by s1 or d exceeds the corresponding device range due to the specification of the number of link bits specified by s2 2821H The s1 s2 devices are overlapping The s1 d devices are overlapping The s2 d devices are overlapping 3...

Page 343: ... Values after the decimal point are rounded up Ladder diagram Structured text ENO WTOB EN s n d ENO WTOBP EN s n d FBD LD Operand Description Range Data type Data type label s Head device where the separation target data is stored 16 bit signed binary ANY16 d Head device for storing the result of separation in byte unit 16 bit signed binary ANY16 n Number of byte units 0 to 65535 16 bit unsigned b...

Page 344: ...oring the separated data overlap the processing is performed normally Operation error 1 The data FEH is ignored when n is 5 1 00H is automatically stored Device range where the data to be separated is stored Device range for storing the separated data d 0 to d n 1 Error code SD0 SD8067 Description 2820H The range of no of bytes specified in n from the device number specified in s onwards exceed th...

Page 345: ...s stored in device numbers starting from the one specified by s are ignored If n is an odd number 0 is stored in the higher order 8 bits of the device for storing the data of the n th byte 1 Values after the decimal point are rounded up Ladder diagram Structured text ENO BTOW EN s n d ENO BTOWP EN s n d FBD LD Operand Description Range Data type Data type label s Head device for storing the data t...

Page 346: ...ce range for storing the linked data overlap the processing is performed normally Operation error 1 Filled with 00H Device range where the data to be linked is stored Device range for storing the linked data s 0 to s n 1 Error code SD0 SD8067 Description 2820H The range of n points of devices from the device number specified in s onwards exceed the corresponding device range The range of no of byt...

Page 347: ...ption Range Data type Data type label s Head device number connected to a digital switch Bit ANYBIT_ARRAY Number of element 4 d1 Head device number to which the strobe signal is output Bit ANYBIT_ARRAY Number of element 4 d2 Device number storing the numeric value of a digital switch 0 to 9999 16 bit signed binary ANY16 n Total number of 4 digit switch sets 1 2 16 bit unsigned binary ANY16_U EN Ex...

Page 348: ...F FX5UC User s Manual Hardware Precautions Though the contents of d2 do not change all of d1 to d1 3 turn OFF When one set of 4 digits n K1 are used four devices are occupied starting from s When two sets of 4 digits n K2 are used eight devices are occupied starting from s and two devices are occupied starting from d2 When connecting a digital switch of less than 4 digits it is not necessary to wi...

Page 349: ...by d Operation error There is no operation error Ladder diagram Structured text ENO MOV EN s d ENO MOVP EN s d FBD LD Operand Description Range Data type Data type label s Transfer source data or device number for storing data 32768 to 32767 16 bit signed binary ANY16 d Transfer destination device number 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Opera...

Page 350: ...eration error Ladder diagram Structured text ENO DMOV EN s d ENO DMOVP EN s d FBD LD Operand Description Range Data type Data type label s Transfer source data or device number for storing data 2147483648 to 2147483647 32 bit signed binary ANY32 d Transfer destination device number 32 bit signed binary ANY32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word...

Page 351: ...device specified by d Operation error There is no operation error Ladder diagram Structured text ENO CML EN s d ENO CMLP EN s d FBD LD Operand Description Range Data type Data type label s Data to be inverted or device number in which data is stored 32768 to 32767 16 bit signed binary ANY16 d Device number for storing the inversion result 16 bit signed binary ANY16 EN Execution condition Bit BOOL ...

Page 352: ... Operation error There is no operation error Ladder diagram Structured text ENO DCML EN s d ENO DCMLP EN s d FBD LD Operand Description Range Data type Data type label s Data to be inverted or device number in which data is stored 2147483648 to 2147483647 32 bit signed binary ANY32 d Device number for storing the inversion result 32 bit signed binary ANY32 EN Execution condition Bit BOOL ENO Execu...

Page 353: ...data whose nibbles will be moved 16 bit signed binary ANY16 n1 1 Head nibble position to be moved 1 to 4 16 bit unsigned binary ANY16_U n2 1 Number of nibbles to be moved 1 to 4 16 bit unsigned binary ANY16_U d Word device number storing data whose nibbles are moved 16 bit signed binary ANY16 n3 1 Head digit position of movement destination 1 to 4 16 bit unsigned binary ANY16_U EN Execution condit...

Page 354: ...he specified digits in the transfer destination d are changed The transfer source s and unspecified digits in the transfer destination d do not change 1 s is converted from binary to BCD data 2 n2 digits starting from the n1 th digit are transferred combined to d starting from the n3 th digit The first and fourth digits of d are not affected even if data is transferred from s 3 The combined data B...

Page 355: ...d by s and transfer the result in the device specified by d Operation error There is no operation error Ladder diagram Structured text ENO CMLB EN s d ENO CMLBP EN s d FBD LD Operand Description Range Data type Data type label s Transfer source data Bit ANY_BOOL d Transfer destination data Bit ANY_BOOL EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indir...

Page 356: ... BMOV EN s n d ENO BMOVP EN s n d FBD LD Operand Description Range Data type Data type label s Head device for storing the data to be transferred 16 bit signed binary 32 bit signed binary ANY16 d Head number of the transfer destination device 16 bit signed binary 32 bit signed binary ANY16 n Number of transfers 1 to 65535 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution r...

Page 357: ...mber transfer from s n 1 Ex When transferring data to a device having a smaller device number When transferring data to a device having a larger device number Precautions To perform nibble specification of bit device for both s and d be sure to set the same number of nibbles for s and d To use a module access device for s and d specify either s or d Operation error Error code SD0 SD8067 Descriptio...

Page 358: ...n the possible range When a constant K is specified as the transfer source s it is automatically converted into binary Ladder diagram Structured text ENO FMOV EN s n d ENO FMOVP EN s n d FBD LD Operand Description Range Data type Data type label s Data to be transferred or the head device for storing the data to be transferred 32748 to 32767 16 bit signed binary ANY16 d Head device of the transfer...

Page 359: ...C INSTRUCTIONS 7 7 Data Transfer Instructions 357 7 Precautions When the value specified in n is 0 an operation error does not occur but no processing is performed Operation error There is no operation error ...

Page 360: ...sible range When a constant K is specified as the transfer source s it is automatically converted into binary Ladder diagram Structured text ENO DFMOV EN s n d ENO DFMOVP EN s n d FBD LD Operand Description Range Data type Data type label s Data to be transferred or the head device for storing the data to be transferred 2147483648 to 2147483647 32 bit signed binary ANY32 d Head device of the trans...

Page 361: ...C INSTRUCTIONS 7 7 Data Transfer Instructions 359 7 Precautions When the value specified in n is 0 an operation error does not occur but no processing is performed Operation error There is no operation error ...

Page 362: ...Operand Description Range Data type Data type label d1 Head device for storing the data to be exchanged 16 bit signed binary ANY16 d2 Head device for storing the data to be exchanged 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E d1 ...

Page 363: ... Operand Description Range Data type Data type label d1 Head device for storing the data to be exchanged 32 bit signed binary ANY32 d2 Head device for storing the data to be exchanged 32 bit signed binary ANY32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E d1...

Page 364: ... operation type instruction is used swap is done in each operation cycle Operation error There is no operation error Ladder diagram Structured text ENO SWAP EN d ENO SWAPP EN d FBD LD Operand Description Range Data type Data type label d Head device for storing the data to be swapped 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double wo...

Page 365: ... operation cycle Operation error There is no operation error Ladder diagram Structured text ENO DSWAP EN d ENO DSWAPP EN d FBD LD Operand Description Range Data type Data type label d Head device for storing the data to be swapped 32 bit signed binary ANY32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F...

Page 366: ...ror Ladder diagram Structured text ENO MOVB EN s d ENO MOVBP EN s d FBD LD Operand Description Range Data type Data type label s Head device for storing the transfer source data Bit ANY_BOOL d Head device for storing the transfer destination data Bit ANY_BOOL EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM...

Page 367: ...ed text ENO PRUN EN s d ENO PRUNP EN s d FBD LD Operand Description Range Data type Data type label s Nibble specification 1 16 bit signed binary ANY16 d Device number of transfer destination 1 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC L...

Page 368: ...Description 2820H The devices specified by s and d exceed the range of the corresponding device PRUN K4M0 K4Y0 s d Y17 Y16 Y15 Y14 Y13 Y12 Y11 Y10 Y7 Y6 Y5 Y4 Y3 Y2 Y1 Y0 M15 M14 M13 M12 M11 M9 M8 M7 M6 M5 M4 M3 M2 M1 M0 M17 M16 M10 Octal bit device X Decimal bit device M Not transferred M0 to M7 M10 to M17 Y0 to Y17 Command input ...

Page 369: ...uctured text ENO DPRUN EN s d ENO DPRUNP EN s d FBD LD Operand Description Range Data type Data type label s Nibble specification 1 32 bit signed binary ANY32 d Device number of transfer destination 1 32 bit signed binary ANY32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G...

Page 370: ...scription 2820H The devices specified by s and d exceed the range of the corresponding device DPRUN K6M0 K6Y0 Y27 Y20 Y17 Y10 Y7 Y6 Y5 Y4 Y3 Y2 Y1 Y0 M19 M18 M17 M9 M8 M7 M6 M5 M4 M3 M2 M1 M0 M27 M20 M10 s d Octal bit device X Decimal bit device M Not transferred M0 to M7 M10 to M17 M20 to M27 Y0 to Y27 Not transferred Command input ...

Page 371: ...anged Functions Ladder diagram Structured text ENO BLKMOVB EN s n d ENO BLKMOVBP EN s n d FBD LD Operand Description Range Data type Data type label s Head device for storing the transfer source bit data Bit ANY_BOOL d Head device for storing the transfer destination bit data Bit ANY_BOOL n Number of transfers 0 to 65535 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution re...

Page 372: ...ied by d Data can be transferred even when the device range of the transfer source device and transfer destination device is overlapping Operation error Error code SD0 SD8067 Description 2820H The range of n point s of data starting from the device specified by s and d exceed the corresponding device range 3420H A module access device is specified for both s and d 1 0 1 1 0 1 1 1 n n s n 1 s 2 s 1...

Page 373: ...rted by the ST language and the FBD LD language Use ROR of the standard function Page 1007 ROR _E Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text 1 ENO RORP EN n d ENO RCR EN n d ENO RCRP EN n d FBD LD 1 Operand Description Range Data type Data type label d Head device number where the rotation target data is stored 16 bit signed binary ANY16 n Num...

Page 374: ...2 equals 1 with a remainder of 3 Specify any value between 0 and 15 for n If a value 16 or bigger is specified bits are rotated by the remainder value of n 16 For example when n is 18 2 bits are rotated because 18 divided by 16 equals 1 with a remainder of 2 1 d 0 d 1 d 0 d 0 0 0 1 0 0 0 0 0 0 0 0 1 0 0 0 b0 b7 b15 b8 b14 b13 b12 b11 b10 b9 b6 b5 b4 b3 b2 b1 b0 b7 b15 b8 b14 b13 b12 b11 b10 b9 b6 ...

Page 375: ...der value of n 16 For example when n is 18 2 bits are rotated because 18 divided by 16 equals 1 with a remainder of 2 Precautions Do not set a negative value to the number of bits to be rotated n In the case of continuous operation type instructions ROR and RCR note that shift and rotation are executed in every scan time operation cycle Operation error There is no operation error 1 d 0 d 1 0 d d 0...

Page 376: ...the FBD LD language Use ROL of the standard function Page 1005 ROL _E Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text 1 ENO ROLP EN n d ENO RCL EN n d ENO RCLP EN n d FBD LD 1 Operand Description Range Data type Data type label d Head device number where the rotation target data is stored 16 bit signed binary ANY16 n Number of rotations 0 to 15 16 ...

Page 377: ...equals 1 with a remainder of 3 Specify any value between 0 and 15 for n If a value 16 or bigger is specified bits are rotated by the remainder value of n 16 For example when n is 18 2 bits are rotated because 18 divided by 16 equals 1 with a remainder of 2 b0 b7 b15 b8 b14 b13 b12 b11 b10 b9 b6 b5 b4 b3 b2 b1 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 b0 b7 b15 b8 b14 b13 b12 b11 b10 b9 b6 b5 b4 b3 b2 b1 1 0...

Page 378: ...r value of n 16 For example when n is 18 2 bits are rotated because 18 divided by 16 equals 1 with a remainder of 2 Precautions Do not set a negative value to the number of bits to be rotated n In the case of continuous operation type instructions ROL and RCL note that shift and rotation are executed in every scan time operation cycle Operation error There is no operation error b0 b7 b15 b8 b14 b1...

Page 379: ...range specified by nibble specification The number of bits actually to be rotated is the remainder of n specified number of bits For example when n is 31 and the specified number of bits is 24 7 bits are rotated because 31 divided by 24 equals 1 with a remainder of 7 Specify any value between 0 and 31 for n If a value 32 or bigger is specified bits are rotated by the remainder value of n 32 For ex...

Page 380: ... the specified number of bits is 24 7 bits are rotated because 31 divided by 24 equals 1 with a remainder of 7 Specify any value between 0 and 31 for n If a value 32 or bigger is specified bits are rotated by the remainder value of n 32 For example when n is 34 2 bits are rotated because 34 divided by 32 equals 1 with a remainder of 2 Precautions Do not set a negative value to the number of bits t...

Page 381: ...nge specified by nibble specification The number of bits actually to be rotated is the remainder of n specified number of bits For example when n is 31 and the specified number of bits is 24 7 bits are rotated because 31 divided by 24 equals 1 with a remainder of 7 Specify any value between 0 and 31 for n If a value 32 or bigger is specified bits are rotated by the remainder value of n 32 For exam...

Page 382: ...the specified number of bits is 24 7 bits are rotated because 31 divided by 24 equals 1 with a remainder of 7 Specify any value between 0 and 31 for n If a value 32 or bigger is specified bits are rotated by the remainder value of n 32 For example when n is 34 2 bits are rotated because 34 divided by 32 equals 1 with a remainder of 2 Precautions Do not set a negative value to the number of bits to...

Page 383: ...e next step is executed Precautions If the timer with its coil on is skipped by these instructions time cannot be measured correctly If the OUT instruction is skipped by these instructions the scan time will be shortened If these instructions specify and jump to a later step the scan time will be shortened Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range ...

Page 384: ...shows programming of a label When creating a circuit program move the cursor to the left side of the bus line in the ladder diagram and input a label P at the head of the circuit block A label can be programmed in a smaller number step than CJ instruction However note that a watchdog timer error occurs when the scan time exceeds 200 ms default setting 1 While X3 is on the loop is repeated 2 To exi...

Page 385: ...ror 1 When X20 turns ON the program execution jumps from CJ instruction corresponding to X20 to the label P9 2 When X20 turns OFF and X21 turns ON the program execution jumps from CJ instruction corresponding to X21 to the label P9 A User program A User program 1 Subroutine program dedicated to CALL instruction 2 Program a label P after FEND instruction A User program It is skipped and is not exec...

Page 386: ...ions When a GOEND instruction is executed by invalid jump during interrupt program execation it becomes the same operation as the IRET instruction Operation error Ladder diagram Structured text Not supported FBD LD Not supported Error code SD0 SD8067 Description 3340H After the FOR instruction is executed the GOEND instruction is executed before the NEXT instruction is executed 3381H After the CAL...

Page 387: ...thout an argument when using the interrupt disable instruction with a specified priority or lower DI instruction with an argument refer to Page 387 Disabling the interrupt program with specified priority or lower EI This instruction releases the execution disabled state of interrupt programs when the DI instruction is executed and enables the execution of the interrupt program with the interrupt p...

Page 388: ...control contains the EI or DI instruction such an instruction is executed regardless of the execution of the MC instruction Precautions Interrupts requests that are generated after the DI instruction execution are processed after the EI instruction is executed Operation error Error code SD0 SD8067 Description 3362H Nesting of the DI instruction exceeds 16 levels I10 50 56 60 X2 X5 Y10 Y30 IRET 1 ...

Page 389: ...d by s or lower Ladder diagram Structured text ENO DI_1 EN s FBD LD DI_1 enters Operand Description Range Data type Data type label s Priority for disabling interrupts 1 to 3 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E s 1 Inter...

Page 390: ...errupt disabled section for the priority 3 or lower Interrupt enabled section for the priority 2 or higher 3 Interrupt disabled section for the priority 2 or lower Interrupt enabled section for the priority 1 or higher 4 Interrupt disabled section for the priority 3 or lower Interrupt enabled section for the priority 2 or higher 5 Interrupt enabled section for all priority 6 EI which is the counte...

Page 391: ...once When the DI instructions with and without an argument are executed Execution order is DI instruction with an argument DI instruction without an argument A Scan execution type program 1 Interrupt enabled section for all priority 2 Interrupt disabled section for the priority 2 or lower interrupt enabled section for the priority 1 or higher 3 Interrupt disabled section for the priority 1 or lowe...

Page 392: ...ns ranges and data types Applicable devices Ladder diagram Structured text ENO IMASK EN s FBD LD Operand Description Range Data type Data type label s Head device number where the interrupt mask data is stored The device specified in s and following 15 devices are used 16 bit signed binary ANY16_ARRAY Number of elements 16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit W...

Page 393: ...rupt programs is disabled Error code SD0 SD8067 Description 2820H The 16 point range starting from the device specified by s exceeds the corresponding device range s 1 s s 2 s 3 s 4 s 5 s 6 s 7 s 8 s 9 s 10 s 11 s 12 s 13 s 14 s 15 b0 b7 b15 b8 b14 b13 b12 b11 b10 b9 b6 b5 b4 b3 b2 b1 I0 I7 I15 I8 I14 I13 I12 I11 I10 I9 I6 I5 I4 I3 I2 I1 I16 I23 I31 I30 I29 I28 I22 I21 I20 I19 I18 I17 I55 I63 I56 ...

Page 394: ...ecution status of the interrupt programs of I0 to I177 is applied The execution enabled disabled states of interrupt pointers are stored in SD1400 to 1415 IMASK instruction mask pattern Operation error Ladder diagram Structured text ENO SIMASK EN In s FBD LD Operand Description Range Data type Data type label I 1 Interrupt pointer number for which interrupts are enabled or disabled I0 to I177 Devi...

Page 395: ...rogram execution to the main routine The table below shows two types of jump to an interrupt routine Operation error Ladder diagram Structured text Not supported FBD LD Not supported Function Interrupt No Description Interrupt from inputs including counter I0 to I23 Interrupt pointer used for the CPU built in functions such as input interrupt high speed comparison match interrupt Internal timer in...

Page 396: ...eed the setting value of the watchdog timer The WDT P instruction can be used more than once in one scan However note that turning off the output takes some time if an error occurs Precautions The time of the watchdog timer can be changed in the RAS tab of CPU Parameter The default value is 200 ms By overwriting the contents of SD8000 watchdog timer time the watchdog timer detection time can be ch...

Page 397: ...executed In n any of 1 to 32767 can be specified If any of 32768 to 0 is specified the processing of n 1 is applied To skip the processing between the FOR and NEXT instructions jump the program execution with the CJ instruction Up to 16 FOR instructions can be nested Ladder diagram Structured text A Repetition program Not supported FBD LD Operand Description Range Data type Data type label n Numbe...

Page 398: ...NEXT instruction loop When the NEXT instruction is located before FOR No NEXT instruction When the number of FOR instructions is not equivalent to the number of NEXT instructions When the NEXT instruction is located after the FEND or END instruction Error code SD0 SD8067 Description 3340H After the FOR instruction is executed the END or GOEND instruction is executed before the NEXT instruction is ...

Page 399: ...nstructions are executed The BREAK P instructions can be used only between the FOR and NEXT instructions The BREAK P instructions can be used for only one nesting level To forcibly terminate multiple nesting levels execute as many BREAK P instructions as the number of nesting levels Ladder diagram Structured text Not supported FBD LD Operand Description Range Data type Data type label d Device num...

Page 400: ...and the program execution stops when the BREAK instruction is executed Operation error Error code SD0 SD8067 Description 3340H The branch pointer number outside two nesting levels or more is specified 3342H The BREAK P instructions are used other than between the FOR and NEXT instructions 3380H The destination pointer specified by P does not exist A pointer in other program file is specified in P ...

Page 401: ...nter P is executed The CALL P instructions can execute a subroutine program specified by a pointer in the same program file or by a common pointer Ladder diagram Structured text Not supported FBD LD Not supported Operand Description Range Data type Data type label P Start pointer number of the subroutine program Device name POINTER Operand Bit Word Double word Indirect specification Constant Other...

Page 402: ...tion is executed they do not count if they are used in subroutines in which the coil instruction is executed only under some conditions If a retentive type 1 ms timer is used in a subroutine interrupt routine note that the output contact is activated when the first coil instruction or subroutine is executed after the timer reaches its set value Devices which were set to ON in a subroutine or inter...

Page 403: ...eset instruction is valid the current value of C0 remains unchanged even if a pulses are input 2 Outputs are latched Example in which latched outputs are reset countermeasures Program example 1 Program to reset Y7 at an arbitrary timing 2 Program to reset the preceding C0 reset instruction inside the subroutine X0 P0 P0 CALLP Y7 RET X1 C0 K10 FEND X0 C0 RST RST C0 Y7 X1 1 2 3 Subroutine is execute...

Page 404: ...ter in the CALL P instructions do not exist 3381H After the CALL P instructions are executed the END FEND GOEND or STOP instruction is executed before the RET SRET instruction is executed 3382H The RET SRET instruction is executed before the CALL P instructions are executed X2 Y7 X1 1 2 3 1 2 3 4 RST C0 Subroutine is executed A Counter reset instruction is deactivated part in above program Resets ...

Page 405: ... Error code SD0 SD8067 Description 3381H The END FEND GOEND or STOP instruction is executed before the RET instruction is executed 3382H While the number of nesting levels is decreased by the return instruction the result becomes negative The number of RET SRET instructions is larger than that of the CALL instructions 33E3H The RET instruction is programmed and written between the FOR and NEXT ins...

Page 406: ... name POINTER Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E P In the execution of subroutine programs each coil instruction is operated according to the ON OFF status of the condition contact In the non execution processing of subroutine programs each coil instruction is operated with the OFF status of the condition con...

Page 407: ...n 3360H The 17th level of the nesting is executed 3380H The subroutine program specified by the pointer in the XCALL instruction does not exist 3381H After the XCALL instruction is executed the END FEND GOEND or STOP instruction is executed before the RET instruction is executed 3382H The RET SRET instruction is executed before the XCALL instruction is executed P0 X0 XCALL FEND RET RET RET END P0 ...

Page 408: ...ription Range Data type Data type label s Start number of the word device storing the data The start is a pointer The data is stored starting from s 1 16 bit signed binary ANY16 d Word device number storing data taken out first 16 bit signed binary ANY16 n Number of stored points plus 1 1 is required for the pointer 2 to 32768 16 bit unsigned binary ANY16_U EN Execution condition Bit BOOL ENO Exec...

Page 409: ...P instruction in programming Precautions The contents of s n do not change by reading When the continuous operation type SFRD instruction is used data is read in turn in each scan time operation cycle but the contents of s n do not change When 0 is set in the pointer s no processing is executed and the contents of d do not change Operation error Error code SD0 SD8067 Description 2820H The number o...

Page 410: ...scription Range Data type Data type label s Head device number storing the first in data including pointer data start number of the word device storing the data 16 bit signed binary ANY16 d Device number storing last out data 16 bit signed binary ANY16 n Length of data array Add 1 because pointer data is also included 2 to 32768 16 bit unsigned binary ANY16_U EN Execution condition Bit BOOL ENO Ex...

Page 411: ...tructions in the pulse operation type or let them be executed by a pulsed command contact When the current value of the pointer s is 0 the zero flag SM8020 turns ON and the POP P instructions are not executed When the current value of the pointer s is 1 0 is written to s and the zero flag SM8020 turns ON Operation error Data for FILO control Description s Pointer data amount of data stored s 1 Dat...

Page 412: ...Description Range Data type Data type label s Word device number storing data to be put in first 16 bit signed binary ANY16 d Start word device number storing and shifting data The start is a pointer The data is stored starting from d 1 16 bit signed binary ANY16 n Number of stored points plus 1 2 to 32768 16 bit unsigned binary ANY16_U EN Execution condition Bit BOOL ENO Execution result Bit BOOL...

Page 413: ...the pulse operation type SFWRP instruction in programming Data is stored from the right end in the same way and the number of stored data is specified by the contents of the pointer d Precautions In the case of the continuous operation type instruction SFWR note that data is stored overwritten in every scan time operation cycle Operation error Error code SD0 SD8067 Description 2820H The number of ...

Page 414: ... range used in a data table should be controlled by the user The data table has d number of stored data starting from d 1 Ladder diagram Structured text ENO FINS EN s n d ENO FINSP EN s n d FBD LD Operand Description Range Data type Data type label s Head device number where the insertion target data is stored 16 bit signed binary ANY16 d Start number of the table Word ANY16 n Data insertion posit...

Page 415: ...ed the data table range exceeds the corresponding device range 3405H When the FINS P instructions are executed the value n exceeds the corresponding device range of the table d When the FINS P instructions are executed the table position n where the data is inserted exceeds the number of stored data points 1 The value set in n is other than the following 2 n 32767 ...

Page 416: ... data point Precautions The device range used in a data table should be controlled by the user The data table has d number of stored data starting from d 1 Ladder diagram Structured text ENO FDEL EN s n d ENO FDELP EN s n d FBD LD Operand Description Range Data type Data type label s Head device number for storing the data to be deleted 16 bit signed binary ANY16 d Start number of the table Word A...

Page 417: ... corresponding device range 3405H When the FDEL P instructions are executed the value n exceeds the corresponding device range of the table d When 0 is set in d and the FDEL P instructions are executed When the FDEL P instructions are executed the table position n where the data to be deleted is stored exceeds the number of stored data points The value set in n is other than the following 2 n 3276...

Page 418: ... data memory Writing the fixed values used for operation and operation results to data memory can prevent data loss when the battery is low The data that has been written to data memory can be read at any time using the data memory read instruction Execution method Use the SP DEVST instruction to write device data to data memory Use the S P DEVLD instruction to read device data from data memory to...

Page 419: ... used Ladder diagram Structured text ENO S_DEVLD EN s d n ENO SP_DEVLD EN s d n FBD LD Operand Description Range Data type Data type label s Read offset of device data storage file specified in units of 16 bit words 0 to 63 32 bit unsigned binary ANY32 d Head device for storing the data that has been read Word ANY16 1 n Number of read points 1 to 64 16 bit unsigned binary ANY16 EN Execution condit...

Page 420: ...ed by word offsets incremented by 1 every 16 bits Use the SP DEVST instruction to write device data to the device data storage file Page 419 SP DEVST Operation error Error code SD0 SD8067 Description 2820H The value specified by s and s n are out of range of the device data storage file The device range specified by d exceeds the corresponding device range 2822H Device that cannot be specified is ...

Page 421: ...Ladder diagram Structured text ENO SP_DEVST EN s1 s2 n d FBD LD Operand Description Range Data type Data type label s1 Write offset of device data storage file specified in units of 16 bit words 0 to 63 32 bit unsigned binary ANY32 s2 Start device to which data is to be written Word ANY16 1 n Number of write points 1 to 64 16 bit unsigned binary ANY16 d d Completion device d 1 Error completion dev...

Page 422: ... one at execution of the SP DEVST instruction Execution of the SP DEVST instruction increases SD634 and SD635 The number of writes to the data memory of the CPU module is limited If the data memory write count index exceeds twenty thousands an error occurs with error code 1080H To prevent the data memory write count from being increased by careless instruction execution SD771 can be set to limit t...

Page 423: ...file Any of the device area ranges specified in s2 and d exceed the corresponding device range 2822H Device that cannot be specified is specified 3405H The value stored in a device specified by n is 0 3421H When the SP DEVST instruction is executed the write count of the day exceeds the value specified in SD771 When the SP DEVST instruction is executed a value out of the range 1 to 32767 is set in...

Page 424: ...iption Range Data type Data type label s The device number of file register R in the data storage destination Extended file register ER in the data transfer source and s is the same number Word ANY16_ARRAY n Number of read transfer points 0 to 32767 16 bit unsigned binary ANY16_U d Head device number which turns on when the instruction is completed When the reading is completed abnormally d 1 turn...

Page 425: ...e instruction completion device d After the contact of the ERREAD instruction turns on the extended file register ER access flag SM9366 turns on during access to the extended file register When s 0 R0 and n 0 the number of read points 0 are specified all the points 32768 points of the extended file register ER are read to the file register R in the CPU built in memory in a batch When s 1 or higher...

Page 426: ...rring the extended file register ER Do not turn off the power supply of the CPU module during access to the extended file register ER Operation error Error code SD0 SD8067 Description 2121H The SD memory card is not formatted 2820H The last device number of the device to be transferred s exceeds the device points assignment setting of the file register R 2821H The device other than the target devi...

Page 427: ...Data type label s The device number of file register R in the data storage destination Extended file register ER in the data transfer source and s is the same number Word ANY16_ARRAY n Number of write transfer points 0 to 32767 16 bit unsigned binary ANY16_U d Head device number which turns on when the instruction is completed When the reading is completed abnormally d 1 turns on Bit ANYBIT_ARRAY ...

Page 428: ...truction completion device d After the contact of the ERWRITE instruction turns on the extended file register ER access flag SM9366 turns on during access to the extended file register ER When s 0 R0 and n 0 the number of read points 0 are specified all the points 32768 points of the file register R in the CPU built in memory are written to the extended file register ER in a batch When s 1 or high...

Page 429: ...er supply of the CPU module during access to the extended file register ER Operation error Error code SD0 SD8067 Description 2121H The SD memory card is not formatted 2820H The last device number of the device to be transferred s exceeds the device points assignment setting of the file register R 2821H The device other than the target device is specified to each operand 3583H The extended file reg...

Page 430: ... C cannot be used Ladder diagram Structured text ENO ERINIT EN d FBD LD Operand Description Range Data type Data type label d Head device number which turns on when the instruction is completed When the reading is completed abnormally d 1 turns on Bit ANYBIT_ARRAY Number of elements 2 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification ...

Page 431: ...on execution abnormal end flag SM8329 turn on only for one scan at the same timing with the instruction completion device d After the contact of the ERINIT instruction turns on the extended file register ER access flag SM9366 turns on during access to the extended file register ER The initial value of the extended file register ER when initializing is 65535 FFFFH Related devices Device Name Descri...

Page 432: ...nstruction cannot be executed in the interrupt program Do not turn off the power supply of the CPU module during access to the extended file register ER Operation error Error code SD0 SD8067 Description 2821H The device other than the target device is specified to each operand 3583H The extended file register operation instruction is executed in the F W of the serial number 16X or earlier 3584H Wr...

Page 433: ...T ST C cannot be used Ladder diagram Structured text 1 enters ENO LDSTRING_ EN s1 s2 ENO ANDSTRING_ EN s1 s2 ENO ORSTRING_ EN s1 s2 EQ NE GT LE LT GE enters 2 FBD LD _EQ _NE _GT _LE _LT _GE enters 2 Operand Description Range Data type Data type label s1 Comparison data or head device number where the comparison data is stored Character string ANYSTRING_SINGLE s2 Comparison data or head device numb...

Page 434: ...e state Non conductive state Conductive state Conductive state When the character strings are different the magnitude relation between them is determined based on the size of the first different character code Instruction symbol in Result Instruction symbol in Result Non conductive state Conductive state Conductive state Conductive state Non conductive state Non conductive state When the length of...

Page 435: ... the target device range does not have 00H a comparison operation result is output when a mismatch between the acquired character strings is detected Ex For the data specified by s1 and s2 as shown above the second character is different between them Thus the operation result is non conductive Operation error There is no operation error LD D7998 s1 s2 D10 M0 D7998 D7999 42H B 41H A 44H D 43H C D10...

Page 436: ...at stores 00H are concatenated When character strings are concatenated 00H indicating an end of the character string specified by d is ignored and the character string specified by s is concatenated to the last character of d Ladder diagram Structured text Not supported Page 436 P For 3 operands FBD LD Not supported Page 436 P For 3 operands Operand Description Range Data type Data type label s He...

Page 437: ...ge after the device specified by d 00H does not exist 3406H The whole concatenated character string cannot be stored in the devices from the device specified by d to the last device in the corresponding device range The number of characters of the character string in the device specified by s d exceeds 16383 3405H The character string specified by s has more than 16383 characters The character str...

Page 438: ...er strings are connected 00H is automatically added at the end When the number of characters after the concatenation is odd 00H is stored in the upper byte of the device storing the last character When the number is even 0000H is stored in the device after the last character Ladder diagram Structured text ENO STRINGPLUS EN s1 s2 d ENO STRINGPLUSP EN s1 s2 d FBD LD STRINGPLUS STRINGPLUSP enters Ope...

Page 439: ...he corresponding device range after the device specified by s1 00H does not exist In the corresponding device range after the device specified by s2 00H does not exist 2821H The numbers of the character string storing devices specified by s1 s2 and d overlap 3405H The character string specified by s1 has more than 16383 characters The character string specified by s2 has more than 16383 characters...

Page 440: ...Structured text 1 ENO STRINGMOV EN s d ENO STRINGMOVP EN s d FBD LD STRINGMOV STRINGMOVP enters Operand Description Range Data type Data type label s Character string to be transferred up to 255 characters or head device number storing a character string Character string ANYSTRING_SINGLE d Head device number storing transferred character string Character string ANYSTRING_SINGLE EN Execution condit...

Page 441: ... is not transferred 2 It is the same as the character string before transfer 3 00H is automatically stored in the high order byte Error code SD0 SD8067 Description 2820H In the corresponding device range of the device specified by s and later 00H does not exist 3405H The character string specified by s has more than 16383 characters 3406H The whole specified character string cannot be stored in th...

Page 442: ...bit signed binary ANY16_S BINDA P _U 0 to 65535 16 bit unsigned binary ANY16_U d Head device number storing conversion result Character string ANYSTRING_SINGLE EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E s d 1 As sign data 20H is stored if the 16 bit binary...

Page 443: ...ing Operation Instruction 441 8 Precautions The number of occupied points of d is 3 when SM701 is on and 4 when SM701 is off Operation error Error code SD0 SD8067 Description 2820H The device specified by d exceeds the corresponding device range ...

Page 444: ...NDA P Binary data to be converted into ASCII codes 2147483648 to 2147483647 32 bit signed binary ANY32_S DBINDA P _U 0 to 4294967295 32 bit unsigned binary ANY32_U d Head device number storing conversion result Character string ANYSTRING_SINGLE EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST ...

Page 445: ...ve 20H is stored for 0 on the left side of the valid digits zero suppression For 0012034560 20H is stored for 00 and the number of digits is 8 based on 12034560 In the upper 8 bits of the device specified by d 5 0 is stored when SM701 output character number selector signal is off and 20H is stored when SM701 is on Error code SD0 SD8067 Description 2820H The device specified by d exceeds the corre...

Page 446: ...iption Range Data type Data type label s Head device number storing hexadecimal code to be converted 16 bit signed binary ANY16 d Head device number storing converted ASCII code Character string ANYSTRING_SINGLE n Number of characters digits of hexadecimal code to be converted 1 to 32767 16 bit unsigned binary ANY16_U EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word D...

Page 447: ...0ABCH D101 1234H D102 5678H n d K1 K2 K3 K4 K5 K6 K7 K8 K9 D200 D200 D201 D201 D202 D202 D203 D203 D204 C C C C C C C C C B B B B B B B B A A A A A A A 0 0 0 0 0 0 4 4 4 4 4 3 3 3 3 2 2 2 1 1 8 lowest order byte highest order byte lowest order byte highest order byte lowest order byte highest order byte lowest order byte highest order byte lowest order byte 1 D100 0ABCH D200 D201 0 0 0 0 1 0 1 0 1...

Page 448: ...ON or OFF just before each instruction so that SM8161 does not apply to another instruction Operation error Number of specified digits characters and conversion result 1 Do not change Bit configuration when n is K2 SM701 SM8161 Number of devices occupied by d ON ON Number of letters ON OFF Number of letters 2 OFF ON Number of letters 1 OFF OFF Number of letters 2 1 Error code SD0 SD8067 Descriptio...

Page 449: ...R_U EN s1 s2 d ENO STRP_U EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 STR P Head device number where the number of digits of the conversion target data is stored 16 bit signed binary ANY16_S_ARRAY Number of elements 2 STR P _U 16 bit unsigned binary ANY16_U_ARRAY Number of elements 2 s2 STR P Conversion target data 32768 to 32767 16 bit signed binary ANY16_S STR P _U 0...

Page 450: ...mal part 2 Added automatically If the specified number of digits in the decimal part is greater than the number of digits of the 16 bit binary data 0 s is automatically added and the data is regarded as 0 1 Added automatically If the total number of digits excluding the sign and the decimal point is greater than the number of digits of the 16 bit binary data 20H space is stored between the sign an...

Page 451: ...digits specified by s1 is out of the valid range 2 to 8 The number of digits in the decimal part specified by s1 1 is out of the valid range 0 to 5 The relationship between the total number of digits specified by s1 and the number of digits in the decimal part specified by s1 1 does not satisfy the following Total number of digits 3 Number of digits in the decimal part 3406H The device areas stori...

Page 452: ... s2 d ENO DSTRP_U EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 DSTR P Head device number where the number of digits of the conversion target data is stored 16 bit signed binary ANY16_S_ARRAY Number of elements 2 DSTR P _U 16 bit unsigned binary ANY16_U_ARRAY Number of elements 2 s2 DSTR P Conversion target data 2147483648 to 2147483647 16 bit signed binary ANY32_S DSTR ...

Page 453: ... 0 s is automatically added and the data is regarded as 0 1 Added automatically If the total number of digits excluding the sign and the decimal point is greater than the number of digits of the 32 bit binary data 20H space is stored between the sign and the numeric value If the number of digits of the 32 bit binary data is greater an error occurs 1 20H SP is stored s1 1 b15 b8 b7 b0 00H d 4 d 3 d...

Page 454: ...us 2 of the 16 bit binary data in the device specified by s2 The additional 2 digits indicate the sign and the decimal point The total number of digits specified by s1 is out of the valid range 2 to 13 The number of digits in the decimal part specified by s1 1 is out of the valid range 0 to 10 The relationship between the total number of digits specified by s1 and the number of digits in the decim...

Page 455: ...er can be directly specified as s1 The data after conversion varies depending on the display specification stored in s2 Ladder diagram Structured text ENO ESTR EN s1 s2 d ENO ESTRP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Single precision real number data to be converted or the start number of the device where data is stored 0 2 126 s1 2128 Single precision real num...

Page 456: ...at 2 Total number of digits 3 Number of digits of decimal part 4 Sign 5 Single precision real number 6 0000H is automatically stored at the end of the character string 1 Total number of digits 2 Number of digits of decimal part 3 Sign 4 Single precision real number 5 0000H is automatically stored at the end of the character string s2 1 s2 2 b15 b8 b7 b0 0000H d 4 d 3 d 2 d 1 d s2 s1 1 s1 6 ASCII c...

Page 457: ... between the sign and the integer part 1 Total number of digits 2 Number of digits of decimal part 3 20H SP is stored The value 00H is automatically stored at the end of the converted character string 1 Exponent format 2 Total number of digits 3 Number of digits of decimal part 4 Single precision real number 5 Sign integer part 6 Sign exponent part 7 Added automatically 8 0000H is automatically st...

Page 458: ...f digits of decimal part 3 Fixed to 2 digit 4 Sign integer part 5 Sign exponent part 6 Single precision real number 7 0000H is automatically stored at the end of the character string As sign data of the integral part 20H space is stored if the single precision real number is positive and 2DH is stored if the data is negative The integer part is fixed to 1 digit 20H space is stored between the inte...

Page 459: ... range in the decimal point format When the number of digits of the decimal part is 0 Total number of digits 2 When the number of digits of the decimal part is any value other than 0 Total number of digits Number of digits of decimal part 3 The total number of digits specified by s2 1 is not within the following range in the exponent format When the number of digits of the decimal part is 0 Total ...

Page 460: ...nd store the length in the device specified by d and later These instructions handle data stored in the device specified by s to the device storing 00H as a character string Ladder diagram Structured text 1 ENO LENP EN s d FBD LD 1 Operand Description Range Data type Data type label s Character string or head device number storing a character string Character string ANYSTRING_SINGLE d Device numbe...

Page 461: ...rdingly in the case of character codes in which 2 bytes express 1 character such as shift JIS codes the length of 1 character is detected as 2 Operation error Error code SD0 SD8067 Description 2820H In the corresponding device range of the device specified by s and later 00H does not exist 3405H The character string specified by s has more than 16383 characters b15 b0 b7 b8 b15 b0 d s s 1 s 2 s 3 ...

Page 462: ...g or head device number storing a character string Character string ANYSTRING_SINGLE d Head device number for storing n characters extracted from the right of the device specified by s Character string ANYSTRING_SINGLE n Number of characters to be extracted 1 to 16383 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect spec...

Page 463: ...cted as 2 When extracting characters from a character string including character codes in which 2 bytes express 1 character such as shift JIS codes consider the number of characters to be extracted in units of character codes for 1 character Note that the expected character code is not retrieved if only 1 byte is extracted out of a 2 byte character code Operation error 1 ASCII code for 5th charact...

Page 464: ...er diagram Structured text 1 ENO LEFTP EN s n d FBD LD 1 Operand Description Range Data type Data type label s Character string or head device number storing a character string Character string ANYSTRING_SINGLE d Head device number for storing n characters extracted from the left of the device specified by s Character string ANYSTRING_SINGLE n Number of characters to be extracted 1 to 16383 16 bit...

Page 465: ... When extracting characters from a character string including character codes in which 2 bytes express 1 character such as shift JIS codes consider the number of characters to be extracted in units of character codes for 1 character Note that the expected character code is not retrieved if only 1 byte is extracted out of a 2 byte character code Operation error 1 ASCII code for 7th character Error ...

Page 466: ... MIDRP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Character string or head device number storing a character string Character string ANYSTRING_SINGLE d Head device number for storing the character string data of the operation result Character string ANYSTRING_SINGLE s2 Head device number for storing the number of characters and position of the start character s2 0 Pos...

Page 467: ... string stored in s1 and later is stored to d and later Precautions When handling character codes other than ASCII codes note the following points The number of characters is handled in byte units 8 bits Accordingly in the case of character codes in which 2 bytes express 1 character such as shift JIS codes 1 character is detected as 2 When extracting characters from a character string including ch...

Page 468: ...The value stored in a device specified in s2 exceeds the number of characters of s1 A negative value is specified in s2 The value stored in a device specified in s2 1 exceeds the number of characters of s1 The character string specified by s1 has more than 16383 characters The total of the values stored in devices specified in s2 and s2 1 exceeds the number of characters of s1 3406H The number of ...

Page 469: ...NO MIDW EN s1 s2 d ENO MIDWP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Character string or head device number storing a character string Character string ANYSTRING_SINGLE d Head device number for storing the character string data of the operation result Character string ANYSTRING_SINGLE s2 Head device number for storing the number of characters and position of the st...

Page 470: ... the last character of d 30H 0 31H 1 32H 2 33H 3 34H 4 35H 5 36H 6 37H 7 38H 8 00H b15 b0 b7 b8 s1 s1 1 s1 2 s1 3 s1 4 s2 s2 1 012345678 ABCDEFGHI AB012345I 3 6 41H A 42H B 43H C 44H D 45H E 46H F 47H G 48H H 49H I 00H b15 b0 b7 b8 d d 1 d 2 d 3 d 4 41H A 42H B 30H 0 31H 1 32H 2 33H 3 34H 4 35H 5 49H I 00H b15 b0 b7 b8 d d 1 d 2 d 3 d 4 Before execution After execution Position from the left end i...

Page 471: ...8067 Description 2820H In the corresponding device range of the device specified by s1 and later 00H does not exist The device specified by d exceeds the corresponding device range 3405H The value stored in a device specified in s2 1 is 2 or lower The value stored in a device specified in s2 exceeds the number of characters of d The value stored in a device specified in s2 1 exceeds the number of ...

Page 472: ...s2 s3 d ENO INSTRP EN s1 s2 s3 d FBD LD Operand Description Range Data type Data type label s1 Character string to be searched for or head device number storing a character string to be searched for Character string ANYSTRING_SINGLE s2 Character string to be searched or head device number storing a character string to be searched Character string ANYSTRING_SINGLE d Head device number storing searc...

Page 473: ...art position s3 3rd character 2 Fifth character from the head character 1 Search start position s3 3rd character 2 Fifth character from the head character Error code SD0 SD8067 Description 2820H No NULL code 00H exists in the corresponding device range of the device specified by s1 and later No NULL code 00H exists in the corresponding device range of the device specified by s2 and later 3405H The...

Page 474: ...D LD Operand Description Range Data type Data type label s1 Character string to be inserted or head device number storing the character string to be inserted Character string ANYSTRING_SINGLE d Head device number storing a character string to which another character string is inserted Character string ANYSTRING_SINGLE s2 Insertion position in units of bytes 1 to 16383 16 bit signed binary ANY16 EN...

Page 475: ...s The device storing the character string after insertion s1 d overlaps with the character string storing device of s1 3405H The character string specified by s1 has more than 16383 characters The character string specified by d has more than 16383 characters s2 is not within the range 1 s2 16383 The value specified by s2 exceeds the number of characters of the character string d 1 3406H The chara...

Page 476: ...ured text ENO STRDEL EN s n d ENO STRDELP EN s n d FBD LD Operand Description Range Data type Data type label d Head device number storing a character string having characters to be deleted Character string ANYSTRING_SINGLE s Deletion start position 1 to 16383 16 bit signed binary ANY16 n Number of characters to be deleted 0 to 16384 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO E...

Page 477: ...aracter string specified by d has more than 16383 characters s is not within the range 1 s 16383 The value specified by s exceeds the number of characters of the character string d The value specified by n exceeds the number of characters from s to the last of the character string d 41H A 42H B 48H H 49H I 4AH J 4BH K 4CH L 00H 0000H 0000H 0000H 31H 1 30H 0 33H 3 32H 2 35H 5 34H 4 41H A 42H B 49H ...

Page 478: ...am Structured text 1 enters ENO LDE_ EN s1 s2 ENO ANDE_ EN s1 s2 ENO ORE_ EN s1 s2 EQ NE GT LE LT GE enters 2 FBD LD _EQ _NE _GT _LE _LT _GE enters 2 Operand Description Range Data type Data type label s1 Comparison data or the head device number where the comparison data is stored 0 2 126 s1 2128 Single precision real number ANYREAL_32 s2 Comparison data or the head device number where the compar...

Page 479: ...son operation results of each instruction When an input value is set from the engineering tool a rounding error may occur Operation error There is no operation error When the E instruction is used note that values in the devices may not be equal 1 Values in the devices may not be equal Instruction symbol Condition Result Instruction symbol Condition Result E s1 s2 Conductive state E s1 s2 Non cond...

Page 480: ... DECMPP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Comparison data or the number of the device where the comparison data is stored 0 2 126 s1 2128 Single precision real number ANYREAL_32 s2 Comparison data or the number of the device where the comparison data is stored 0 2 126 s2 2128 Single precision real number ANYREAL_32 d Start bit device number to which compariso...

Page 481: ...d d 2 specified by d are occupied Note that these devices are not used for any other purpose Operation error Error code SD0 SD8067 Description 2820H The device range specified by d exceeds the corresponding device range 3402H The specified device value is denormalized number NaN not a number or ...

Page 482: ... or the number of the device where the comparison data is stored 0 2 126 s1 2128 Single precision real number ANYREAL_32 s2 Comparison data or the number of the device where the comparison data is stored 0 2 126 s2 2128 Single precision real number ANYREAL_32 s3 Comparison data or the number of the device where the comparison data is stored 0 2 126 s3 2128 Single precision real number ANYREAL_32 d...

Page 483: ...upied Note that these devices are not used for any other purpose The size relationship of the comparison data should be s1 1 s1 s2 1 s2 If the relationship is s1 1 s1 s2 1 s2 the value of s2 1 s2 is regarded as the same as that of s1 1 s1 and is compared Operation error 1 Even if the command input X0 turns off before the DECMP instruction is fully executed d to d 2 hold the status Error code SD0 S...

Page 484: ...ata type label s Addend data or the head device number where the data that is added to another is stored 0 2 126 s 2128 Single precision real number ANYREAL_32 d Head device number where the data to which another is added is stored Single precision real number ANYREAL_32 Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E s d...

Page 485: ...truction 483 8 Operation error Error code SD0 SD8067 Description 3402H The specified device value is 0 denormalized number NaN not a number or The value stored in specified device is outside the following range 0 2 126 Specified device value 2128 ...

Page 486: ...mber ANYREAL_32 s2 Addend data or the head device number where the data that is added to another is stored 0 2 126 s2 2128 Single precision real number ANYREAL_32 d Head device number for storing the operation result Single precision real number ANYREAL_32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F ...

Page 487: ...truction 485 8 Operation error Error code SD0 SD8067 Description 3402H The specified device value is 0 denormalized number NaN not a number or The value stored in specified device is outside the following range 0 2 126 specified device value 2128 ...

Page 488: ...ata type label s Subtrahend data or the head device number where the data to be subtracted from another is stored 0 2 126 s 2128 Single precision real number ANYREAL_32 d Head device number where the data from which another is to be subtracted is stored Single precision real number ANYREAL_32 Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R...

Page 489: ...truction 487 8 Operation error Error code SD0 SD8067 Description 3402H The specified device value is 0 denormalized number NaN not a number or The value stored in specified device is outside the following range 0 2 126 specified device value 2128 ...

Page 490: ...ion real number ANYREAL_32 s2 Subtrahend data or head device number where the data to be subtracted from another is stored 0 2 126 s2 2128 Single precision real number ANYREAL_32 d Head device number for storing the operation result Single precision real number ANYREAL_32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Othe...

Page 491: ...truction 489 8 Operation error Error code SD0 SD8067 Description 3402H The specified device value is 0 denormalized number NaN not a number or The value stored in specified device is outside the following range 0 2 126 specified device value 2128 ...

Page 492: ... text ENO DEADD EN s1 s2 d ENO DEADDP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Augend data or head device number where the data to which another is added is stored 0 2 126 s1 2128 Single precision real number ANYREAL_32 s2 Addend data or head device number where the data that is added to another is stored 0 2 126 s2 2128 Single precision real number ANYREAL_32 d Hea...

Page 493: ... The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM700 turns on SM8020 Zero The operation result is true 0 The mantissa part is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers and the borrow flag SM8021 turns on SM8022 Carry The absolute value of the op...

Page 494: ...tured text ENO DSUB EN s1 s2 d ENO DSUBP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Minuend data or head device number where the data from which another is subtracted is stored 0 2 126 s1 2128 Single precision real number ANYREAL_32 s2 Minuend data or head device number where the data that is subtracted another is stored 0 2 126 s2 2128 Single precision real number AN...

Page 495: ...8 The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM700 turns on SM8020 Zero The operation result is true 0 The mantissa part is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers and the borrow flag SM8021 turns on SM8022 Carry The absolute value of the o...

Page 496: ... When an input value is set from the engineering tool a rounding error may occur Ladder diagram Structured text 1 ENO EMULTI EN s1 s2 d ENO EMULTIP EN s1 s2 d FBD LD EMULTI EMULTIP enters Operand Description Range Data type Data type label s1 Multiplicand data or head device number where the data to be multiplied by another is stored 0 2 126 s1 2128 Single precision real number ANYREAL_32 s2 Multi...

Page 497: ...art is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers and the borrow flag SM8021 turns on SM8022 Carry The absolute value of the operation result 2128 The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM8022 turns on Error code SD0 SD8067 Description 340...

Page 498: ...28 When an input value is set from the engineering tool a rounding error may occur Ladder diagram Structured text 1 ENO EDIVISION EN s1 s2 d ENO EDIVISIONP EN s1 s2 d FBD LD EDIVISION EDIVISIONP enters Operand Description Range Data type Data type label s1 Dividend data or head device number where the data which is divided by another is stored 0 2 126 s1 2128 Single precision real number ANYREAL_3...

Page 499: ...he zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers and the borrow flag SM8021 turns on SM8022 Carry The absolute value of the operation result 2128 The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM8022 turns on Error code SD0 SD8067 Description 3400H The div...

Page 500: ... ENO DEMUL EN s1 s2 d ENO DEMULP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Multiplicand data or head device number where the data to be multiplied by another is stored 0 2 126 s1 2128 Single precision real number ANYREAL_32 s2 Multiplier data or head device number where the data by which another is to be multiplied is stored 0 2 126 s2 2128 Single precision real numb...

Page 501: ...art is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers and the borrow flag SM8021 turns on SM8022 Carry The absolute value of the operation result 2128 The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM8022 turns on Error code SD0 SD8067 Description 340...

Page 502: ... diagram Structured text ENO DEDIV EN s1 s2 d ENO DEDIVP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Dividend data or head device number where the data which is divided by another is stored Single precision real number ANYREAL_32 s2 Divisor data or head device number where the data that divides another is stored Single precision real number ANYREAL_32 d Head device num...

Page 503: ...e zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers and the borrow flag SM8021 turns on SM8022 Carry The absolute value of the operation result 2128 The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM8022 turns on Error code SD0 SD8067 Description 3400H The divi...

Page 504: ...pecified by s to single precision real number and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO INT2FLT EN s d ENO INT2FLTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 32768 to 32767 16 bit signed binary ANY16_S d Data after conversion Single precision real number...

Page 505: ...ce specified by s to single precision real number and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO UINT2FLT EN s d ENO UINT2FLTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 0 to 65535 16 bit unsigned binary ANY32_U d Data after conversion Single precision real nu...

Page 506: ...ingle precision real number and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO DINT2FLT EN s d ENO DINT2FLTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 2147483648 to 2147483647 32 bit signed binary ANY32_S d Data after conversion Single precision real number ANYRE...

Page 507: ... s to single precision real number and store the converted data in the device specified by d Operation error There is no operation error Ladder diagram Structured text 1 ENO UDINT2FLT EN s d ENO UDINT2FLTP EN s d FBD LD Operand Description Range Data type Data type label s Data before conversion 0 to 4294967295 32 bit unsigned binary ANY32_U d Data after conversion Single precision real number ANY...

Page 508: ...consist of up to 24 characters 20H space and 30H 0 in a character string are counted as one character each Ladder diagram Structured text ENO EVAL EN s d ENO EVALP EN s d FBD LD Operand Description Range Data type Data type label s Character string data to be converted to single precision real number or head device number where the character string data is stored Character string ANYSTRING_SINGLE ...

Page 509: ...specified by s 20H or 30H is ignored during conversion Exponent format When the character string specified by s is in exponent format the operation is executed as follows 1 Single precision real number 1 These values are discarded 2 Single precision real number 1 Ignored 2 Single precision real number 1 Single precision real number s s 1 s 2 s 3 s 4 b15 b0 b7 b8 00H d d 1 31H 1 30H 0 38H 8 2DH 2EH...

Page 510: ...d during conversion Operation error 1 These values are discarded 2 Single precision real number 1 Ignored 2 Single precision real number Error code SD0 SD8067 Description 2820H 00H does not exist in the corresponding device range starting from s 3401H Characters other than 30 0 to 39 9 exist in a character string specified by s 2EH exists in two or more positions in a character string specified by...

Page 511: ...escription Range Data type Data type label s Head device number storing binary floating point data Single precision real number ANYREAL_32 d Device number storing converted decimal floating point Real number ANY32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E...

Page 512: ...ause binary floating point is difficult to understand requiring a dedicated monitoring method it is converted into scientific notation decimal floating point so that monitoring can be easily executed by peripheral equipment Operation error Error code SD0 SD8067 Description 3402H The specified device value is denormalized number NaN not a number or ...

Page 513: ... Description Range Data type Data type label s Head device number storing decimal floating point data Real number ANY32 d Device number storing converted binary floating point data Single precision real number ANYREAL_32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC L...

Page 514: ...e 2128 of 32 bit real numbers and the carry flag SM700 turns on SM8020 Zero The operation result is true 0 The mantissa part is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers and the borrow flag SM8021 turns on SM8022 Carry The absolute value of the operation result 2128 The value of d ...

Page 515: ...d store the data in the device specified by d Use these instructions for inverting the positive and negative sign Operation error There is no operation error Ladder diagram Structured text ENO ENEG EN d ENO ENEGP EN d FBD LD Operand Description Range Data type Data type label d Head device number storing single precision real number whose sign is to be inverted Single precision real number ANYREAL...

Page 516: ...ified by d Operation error There is no operation error Ladder diagram Structured text ENO EMOV EN s d ENO EMOVP EN s d FBD LD Operand Description Range Data type Data type label s Data to be transferred or head device number where the data to be transferred is stored 0 2 126 s 2128 Single precision real number ANYREAL_32 d Device number storing the data in transfer destination Single precision rea...

Page 517: ...ber where the angle data is stored Single precision real number ANYREAL_32 d Head device number for storing the operation result Single precision real number ANYREAL_32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E s d Device Name Description Condition Operat...

Page 518: ...conversion refer to the DRAD P and DDEG P instructions Page 527 Converting single precision real number angle to radian Page 529 Converting single precision real number radian to angle Error code SD0 SD8067 Description 3402H The specified device value is 0 denormalized number NaN not a number or ...

Page 519: ...rd function Page 982 COS _E Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text 1 ENO COSP EN s d FBD LD 1 Operand Description Range Data type Data type label s Angle data or head device number where the angle data is stored Single precision real number ANYREAL_32 d Head device number for storing the operation result Single precision real number ANYREA...

Page 520: ...0 Carry The absolute value of the operation result 2128 The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM700 turns on SM8020 Zero The operation result is true 0 The mantissa part is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers and the borrow flag SM...

Page 521: ...ard function Page 983 TAN _E Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text 1 ENO TANP EN s d FBD LD 1 Operand Description Range Data type Data type label s Angle data or head device number where the angle data is stored Single precision real number ANYREAL_32 d Head device number for storing the operation result Single precision real number ANYRE...

Page 522: ...ber radian to angle Device Name Description Condition Operation SM700 Carry The absolute value of the operation result 2128 The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM700 turns on SM8020 Zero The operation result is true 0 The mantissa part is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is t...

Page 523: ...n Page 984 ASIN _E Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text 1 ENO ASINP EN s d FBD LD 1 Operand Description Range Data type Data type label s A sine value used in SIN 1 arc sine operation or head device number storing the sine value 1 0 to 1 0 Single precision real number ANYREAL_32 d Head device number for storing the operation result 2 to ...

Page 524: ...ndition Operation SM700 Carry The absolute value of the operation result 2128 The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM700 turns on SM8020 Zero The operation result is true 0 The mantissa part is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers ...

Page 525: ...n Page 985 ACOS _E Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text 1 ENO ACOSP EN s d FBD LD 1 Operand Description Range Data type Data type label s A cosine value used in COS 1 arc cosine operation or head device number storing the cosine value 1 0 to 1 0 Single precision real number ANYREAL_32 d Head device number for storing the operation result...

Page 526: ...dition Operation SM700 Carry The absolute value of the operation result 2128 The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM700 turns on SM8020 Zero The operation result is true 0 The mantissa part is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers a...

Page 527: ...ion Page 986 ATAN _E Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text 1 ENO ATANP EN s d FBD LD 1 Operand Description Range Data type Data type label s A tangent value used in the TAN 1 arc tangent operation or head device number storing the tangent value Single precision real number ANYREAL_32 d Head device number for storing the operation result 2...

Page 528: ...Condition Operation SM700 Carry The absolute value of the operation result 2128 The value of d is the maximum value 2128 of 32 bit real numbers and the carry flag SM700 turns on SM8020 Zero The operation result is true 0 The mantissa part is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real number...

Page 529: ...ces Ladder diagram Structured text ENO RAD EN s d ENO RADP EN s d FBD LD Operand Description Range Data type Data type label s A value in degrees to be converted into a value in radians or the start number storing the value in degrees Single precision real number ANYREAL_32 d Head device number storing a value in radians acquired by conversion Single precision real number ANYREAL_32 EN Execution c...

Page 530: ...2128 of 32 bit real numbers and the carry flag SM700 turns on SM8020 Zero The operation result is true 0 The mantissa part is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers and the borrow flag SM8021 turns on SM8022 Carry The absolute value of the operation result 2128 The value of d is...

Page 531: ...lue in radians Single precision real number ANYREAL_32 d Head device number storing a value in degrees acquired by conversion Single precision real number ANYREAL_32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E s d Device Name Description Condition Operation...

Page 532: ...530 8 APPLICATION INSTRUCTION 8 9 Real Number Instruction Operation error Error code SD0 SD8067 Description 3402H The specified device value is 0 denormalized number NaN not a number or ...

Page 533: ...re root operation cannot be executed for a negative value The table below shows the related devices Ladder diagram Structured text ENO DESQR EN s d ENO DESQRP EN s d FBD LD Operand Description Range Data type Data type label s Data whose square root is calculated or head device number where the data is stored Single precision real number ANYREAL_32 d Head device number for storing the operation re...

Page 534: ...nstruction Operation error Error code SD0 SD8067 Description 2822H Device that cannot be specified is specified 3402H The specified device value is denormalized number NaN not a number or 3405H The value stored in a device specified in s is negative ...

Page 535: ... type Data type label s Data whose exponent is calculated or head device number where the data is stored Single precision real number ANYREAL_32 d Head device number for storing the operation result Single precision real number ANYREAL_32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W ...

Page 536: ... instructions execute operations in natural logarithm For obtaining a value in common logarithm specify a common logarithm value divided by 0 4342945 in s Error code SD0 SD8067 Description 3402H The specified device value is 0 denormalized number NaN not a number or 10X e 0 4342945 X ...

Page 537: ... the standard function Page 978 LOG _E Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text 1 ENO LOGP EN s d FBD LD 1 Operand Description Range Data type Data type label s Data whose natural logarithm is calculated or head device number where the data is stored Single precision real number ANYREAL_32 d Head device number for storing the operation resul...

Page 538: ...t real numbers and the carry flag SM700 turns on SM8020 Zero The operation result is true 0 The mantissa part is 0 The zero flag SM8020 turns on SM8021 Borrow The absolute value of the operation result 2 126 The value of d is the minimum value 2 126 of 32 bit real numbers and the borrow flag SM8021 turns on SM8022 Carry The absolute value of the operation result 2128 The value of d is the maximum ...

Page 539: ... s1 s2 d ENO POWP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Data to be raised or head device number which stores such data 0 2 126 s1 2128 Single precision real number ANYREAL_32 s2 Power data or head device number which stores such data 0 2 126 s2 2128 Single precision real number ANYREAL_32 d Head device number for storing the operation result Single precision real...

Page 540: ...ithin the following range the operation result is regarded as 2128 and the carry flag SM716 turns on When an input value is set from the engineering tool a rounding error may be occur Operation error 2128 operation result Error code SD0 SD8067 Description 3402H The value specified by s1 or s2 is outside the following range 0 2 126 specified value stored value 2128 The specified device value is 0 d...

Page 541: ...on logarithm is calculated or head device number where the data is stored Single precision real number ANYREAL_32 d Head device number for storing the operation result Single precision real number ANYREAL_32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E s d D...

Page 542: ...Instruction Operation error Error code SD0 SD8067 Description 3402H The specified device value is denormalized number NaN not a number or 3405H The value stored in a device specified in s is negative The value stored in a device specified in s is 0 ...

Page 543: ...EMAX instruction is not supported by the ST language and the FBD LD language Use MAX of the standard function Page 1014 MAX _E MIN _E Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text 1 ENO EMAXP EN s n d FBD LD 1 Operand Description Range Data type Data type label s Search target data Single precision real number ANYREAL_32 d Search result Single pr...

Page 544: ...ed as 1st point when the location is counted The following values are stored in d When n is 0 the processing is not performed Operation error d 1 d Maximum value d 2 Position d 3 Number of data Data type Description d Single precision real number Maximum value d 1 d 2 16 bit data Maximum value position d 3 16 bit data Number of maximum values Error code SD0 SD8067 Description 2820H The device area...

Page 545: ...EMIN instruction is not supported by the ST language and the FBD LD language Use MIN of the standard function Page 1014 MAX _E MIN _E Setting data Descriptions ranges and data types Applicable devices Ladder diagram Structured text 1 ENO EMINP EN s n d FBD LD 1 Operand Description Range Data type Data type label s Search target data Single precision real number ANYREAL_32 d Search result Single pr...

Page 546: ...ounted as 1st point when the location is counted The following values are stored in d When n is 0 the processing is not performed Operation error d 1 d Minimum value d 2 Position d 3 Number of data Data type Description d Single precision real number Minimum value d 1 d 2 16 bit data Minimum value position d 3 16 bit data Number of minimum values Error code SD0 SD8067 Description 2820H The device ...

Page 547: ...pseudo random number using the source value 1 To SD8311 SD8310 write a non negative value 0 to 2147483647 only once when the CPU module mode switches from STOP to RUN K1 is written to SD8311 SD8310 as the initial value when the power is restored Operation error There is no operation error Ladder diagram Structured text ENO RND EN d ENO RNDP EN d FBD LD Operand Description Range Data type Data type...

Page 548: ...ex registers are saved for 12 points The ZPOP P instructions are used to return the data The ZPUSH P and ZPOP P instructions are used in pairs and by using the same device in d a nesting structure can be adopted Page 548 Returning all data of the index register When a nesting structure is adopted the areas to be used are added to d and later every time the ZPUSH P instructions are used Check the n...

Page 549: ...gisters use the ZPOP P instructions corresponding to the ZPUSH P instructions that were used for saving the data Secure the areas so that the save destination specified by d do not exceed the device range Operation error 1 Number of times of batch storage 2 1st nesting 24 words for one nesting 3 2nd nesting ZPUSH P One setting data ZPOP P One setting data ZPUSH P Two setting data ZPOP P Two settin...

Page 550: ...re read 1 is subtracted from d The ZPUSH P instructions are used to temporarily save the data The ZPUSH P and ZPOP P instructions are used in pairs Operation error Ladder diagram Structured text ENO ZPOP EN d ENO ZPOPP EN d FBD LD Operand Description Range Data type Data type label d Head device number for returning the data of index registers 16 bit signed binary ANY16 EN Execution condition Bit ...

Page 551: ...PUSH P instructions and the selected data of index register long index register return instructions ZPOP P instructions can be used in pairs and to adopt a nesting structure Page 551 Returning the selected data of the index register and long index register When a nesting structure is adopted the areas to be used are added to d and later every time the selected data of index register long index reg...

Page 552: ... because they are used by the system Secure the areas so that the save destination specified by d does not exceed the device range Operation error ZPUSH P One setting data ZPOP P One setting data ZPUSH P Two setting data ZPOP P Two setting data Error code SD0 SD8067 Description 2820H The range of points used in d or later exceeds the range of the target device label area 3405H A value other than 0...

Page 553: ...gisters are read 1 is subtracted from d The data specified by s is regarded as dummy data and ignored Operation error Ladder diagram Structured text ENO ZPOP_2 EN s d ENO ZPOPP_2 EN s d FBD LD ZPOP_2 ZPOPP_2 enters Operand Description Range Data type Data type label s Dummy 16 bit unsigned binary ANY16 d Head device number for returning the data of index registers 16 bit signed binary ANY16 EN Exe...

Page 554: ...scription Range Data type Data type label s1 LIMIT P Lower limit value minimum output value 32768 to 32767 16 bit signed binary ANY16_S LIMIT P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 LIMIT P Upper limit value maximum output value 32768 to 32767 16 bit signed binary ANY16_S LIMIT P _U 0 to 65535 16 bit unsigned binary ANY16_U s3 LIMIT P Input value controlled by the upper and lower limit v...

Page 555: ...nput value only with the upper limit set the minimum value within the setting range in s1 To control the input value only with the lower limit set the maximum value within the setting range in s2 Operation error Condition Output value Lower limit value s1 Input value s3 Lower limit value s1 Upper limit value s2 Input value s3 Upper limit value s2 Lower limit value s1 Input value s3 Upper limit val...

Page 556: ...el s1 DLIMIT P Lower limit value minimum output value 2147483648 to 2147483647 32 bit signed binary ANY32_S DLIMIT P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DLIMIT P Upper limit value maximum output value 2147483648 to 2147483647 32 bit signed binary ANY32_S DLIMIT P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s3 DLIMIT P Input value controlled by the upper and lower limit value...

Page 557: ...t set the minimum value within the setting range in s1 To control the input value only with the lower limit set the maximum value within the setting range in s2 Operation error Condition Output value Lower limit value s1 s1 1 Input value s3 s3 1 Lower limit value s1 s1 1 Upper limit value s2 s2 1 Input value s3 s3 1 Upper limit value s2 s2 1 Lower limit value s1 s1 1 Input value s3 s3 1 Upper limi...

Page 558: ...limit value of the dead band no output band 32768 to 32767 16 bit signed binary ANY16_S BAND P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 BAND P Upper limit value of the dead band no output band 32768 to 32767 16 bit signed binary ANY16_S BAND P _U 0 to 65535 16 bit unsigned binary ANY16_U s3 BAND P Input value controlled by the dead band 32768 to 32767 16 bit signed binary ANY16_S BAND P _U ...

Page 559: ...ut value 32768 10 8000H 000AH 7FFFH 32758 When the output value to be stored in the device specified by d is a 16 bit unsigned binary value and the operation result exceeds the range of 0 to 65535 the output value is calculated as follows Ex When s1 is 100 and s3 is 50 Output value 50 100 0032H 0064H FFCEH 65486 Operation error Condition Output value Lower limit value of the dead band s1 Input val...

Page 560: ... band no output band 2147483648 to 2147483647 32 bit signed binary ANY32_S DBAND P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DBAND P Upper limit value of the dead band no output band 2147483648 to 2147483647 32 bit signed binary ANY32_S DBAND P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s3 DBAND P Input value controlled by the dead band 2147483648 to 2147483647 32 bit signed bina...

Page 561: ...47482648 When the output values to be stored in the devices specified by d and d 1 are 32 bit unsigned binary values and the operation result exceeds the range of 0 to 4294967295 the output value is calculated as follows Ex When s1 and s1 1 are 100 and s3 and s3 1 are 50 Output value 50 100 00000032H 00000064H FFFFFFCEH 4294967246 Operation error Condition Output value Lower limit value of the dea...

Page 562: ... 32768 to 32767 16 bit signed binary ANY16_S ZONE P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 ZONE P Positive bias value to be added to the input value 32768 to 32767 16 bit signed binary ANY16_S ZONE P _U 0 to 65535 16 bit unsigned binary ANY16_U s3 ZONE P Input value for performing the zone control 32768 to 32767 16 bit signed binary ANY16_S ZONE P _U 0 to 65535 16 bit unsigned binary ANY1...

Page 563: ...is calculated as follows Ex When s1 is 100 and s3 is 32768 Output value 32768 100 8000H FF9CH 7F9CH 32668 When the output value to be stored in the device specified by d is a 16 bit unsigned binary value and the operation result exceeds the range of 0 to 65535 the output value is calculated as follows Ex When s2 is 100 and s3 is 65535 Output value 65535 100 FFFFH 0064H 0063H 99 When the ZONE P _U ...

Page 564: ...47 32 bit signed binary ANY32_S DZONE P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DZONE P Positive bias value to be added to the input value 2147483648 to 2147483647 32 bit signed binary ANY32_S DZONE P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s3 DZONE P Input value for performing the zone control 2147483648 to 2147483647 32 bit signed binary ANY32_S DZONE P _U 0 to 4294967295 ...

Page 565: ...7483648 Output value 2147483648 1000 80000000H FFFFFC18H 7FFFFC18H 2147482648 When the output values to be stored in the devices specified by d and d 1 are 32 bit unsigned binary values and the operation result exceeds the range of 0 to 4294967295 the output value is calculated as follows Ex When s2 and s2 1 are 1000 and s3 and s3 1 are 4294967295 Output value 4294967295 1000 FFFFFFFFH 00003E8H 00...

Page 566: ...LP_U EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 SCL P Input value used in scaling or head device number storing the input value 32768 to 32767 16 bit signed binary ANY16_S SCL P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 SCL P Head device number where the scaling conversion data is stored 16 bit signed binary 1 ANY16_S SCL P _U 16 bit unsigned binary 1 ANY16_U d ...

Page 567: ...he scaling conversion data within the range of 1 to 65535 Setting example of the conversion table for scaling Setting item n indicates the number of coordinate points specified by s2 Device assignment Number of coordinate points s2 Point 1 X coordinate s2 1 Y coordinate s2 2 Point 2 X coordinate s2 3 Y coordinate s2 4 Point n X coordinate s2 2n 1 Y coordinate s2 2n In the case of the conversion ch...

Page 568: ...using two points in this way the output value is the Y coordinate at the next point In this example the output value is specified by the Y coordinate of the point 9 Y coordinate s2 16 R16 K90 Point 9 X coordinate s2 17 R17 K350 Y coordinate s2 18 R18 K30 Point 10 X coordinate s2 19 R19 K400 Y coordinate s2 20 R20 K7 Error code SD0 SD8067 Description 3405H The Xn data is not set in the ascending or...

Page 569: ..._U EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 DSCL P Input value used in scaling or head device number storing the input value 2147483648 to 2147483647 32 bit signed binary ANY32_S DSCL P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DSCL P Head device number where the scaling conversion data is stored 32 bit signed binary 1 ANY32_S DSCL P _U 32 bit unsigned bi...

Page 570: ...le of the conversion table for scaling Setting item n indicates the number of coordinate points specified by s2 Device assignment Number of coordinate points s2 1 s2 Point 1 X coordinate s2 3 s2 2 Y coordinate s2 5 s2 4 Point 2 X coordinate s2 7 s2 6 Y coordinate s2 9 s2 8 Point n X coordinate s2 4n 1 s2 4n 2 Y coordinate s2 4n 1 s2 4n In the case of the conversion characteristics for scaling show...

Page 571: ...two points in this way the output value is the Y coordinate at the next point In this example the output value is specified by the Y coordinate of the point 9 Y coordinate s2 33 s2 32 R33 R32 K90 Point 9 X coordinate s2 35 s2 34 R35 R34 K350 Y coordinate s2 37 s2 36 R37 R36 K30 Point 10 X coordinate s2 39 s2 38 R39 R38 K400 Y coordinate s2 41 s2 40 R41 R40 K7 Error code SD0 SD8067 Description 3405...

Page 572: ..._U EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 SCL2 P Input value used in scaling or head device number storing the input value 32768 to 32767 16 bit signed binary ANY16_S SCL2 P _U 0 to 65535 16 bit unsigned binary ANY16_U s2 SCL2 P Head device number where the scaling conversion data is stored 16 bit signed binary 1 ANY16_S SCL2 P _U 16 bit unsigned binary 1 ANY16_U ...

Page 573: ...ified by multiple points the Y coordinate value of the point whose number is the largest is output Set the number of coordinate points for the scaling conversion data within the range of 1 to 65535 Setting example of the conversion table for scaling Setting item n indicates the number of coordinate points specified by s2 Device assignment Number of coordinate points s2 X coordinate Point 1 s2 1 Po...

Page 574: ... s2 2 R2 K20 Point 3 s2 3 R3 K50 Point 4 s2 4 R4 K200 Refer to 1 Point 5 s2 5 R5 K200 Point 6 s2 6 R6 K200 Point 7 s2 7 R7 K250 Point 8 s2 8 R8 K350 Refer to 2 Point 9 s2 9 R9 K350 Point 10 s2 10 R10 K400 Y coordinate Point 1 s2 11 R11 K7 Point 2 s2 12 R12 K30 Point 3 s2 13 R13 K100 Point 4 s2 14 R14 K25 Refer to 1 Point 5 s2 15 R15 K70 Point 6 s2 16 R16 K250 Point 7 s2 17 R17 K90 Point 8 s2 18 R1...

Page 575: ... EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 DSCL2 P Input value used in scaling or head device number storing the input value 2147483648 to 2147483647 32 bit signed binary ANY32_S DSCL2 P _U 0 to 4294967295 32 bit unsigned binary ANY32_U s2 DSCL2 P Head device number where the scaling conversion data is stored 32 bit signed binary 1 ANY32_S DSCL2 P _U 32 bit unsigned ...

Page 576: ...oints the Y coordinate value of the point whose number is the largest is output Set the number of coordinate points for the scaling conversion data within the range of 1 to 4294967295 Setting example of the conversion table for scaling Setting item n indicates the number of coordinate points specified by s2 Device assignment Number of coordinate points s2 1 s2 X coordinate Point 1 s2 3 s2 2 Point ...

Page 577: ... Point 5 s2 11 s2 10 R11 R10 K200 Point 6 s2 13 s2 12 R13 R12 K200 Point 7 s2 15 s2 14 R15 R14 K250 Point 8 s2 17 s2 16 R17 R16 K350 Refer to 2 Point 9 s2 19 s2 18 R19 R18 K350 Point 10 s2 21 s2 20 R21 R20 K400 Y coordinate Point 1 s2 23 s2 22 R23 R22 K7 Point 2 s2 25 s2 24 R25 R24 K30 Point 3 s2 27 s2 26 R27 R26 K100 Point 4 s2 29 s2 28 R29 R28 K25 Refer to 1 Point 5 s2 31 s2 30 R31 R30 K70 Point...

Page 578: ...t ENO TTMR EN s d FBD LD Operand Description Range Data type Data type label d Device storing the teaching data 16 bit signed binary ANY16_ARRAY Number of elements 2 s Magnification applied to the teaching data 0 to 2 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST ...

Page 579: ... Precautions When the command contact turns from on to off the current value d 1 of the pressing and holding time is cleared and the teaching time d will not change any more Two devices are occupied from a device specified as the teaching time d Make sure that such devices are not used in other controls for the machine Operation error s Magnification d K0 0 d 1 K1 10 0 d 10 K2 100 0 d 100 Error co...

Page 580: ...t Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E s1 1 s2 d Operand d Device Description Setting range Set by 0 Off delay timer output Turns on at the rising edge of the command of the STMR instruction and turns off when the time specified by s2 elapses after the falling edge System 1 One shot timer output after turning off Turns on at the falling edge of the command of the STMR in...

Page 581: ...1 starts counting as a 100 ms timer on the rising edge of the command contact Four devices are occupied from a device specified in d Make sure that such devices are not used in other controls for the machine If the command contact is turned off d d 1 and d 3 turn off when the set time elapses d 2 and the timer s1 are immediately reset Operation error 1 Command of the STMR instruction 2 Setting val...

Page 582: ...the counter reaches the end of its count NO contact becomes turns ON and NC contact becomes turns OFF When the long counter specified by d is a high speed counter up counting and down counting are enabled During up counting the output contact turns ON when the current value changes from a value less than the set value to a value not less than the set value During down counting only when using a hi...

Page 583: ... 118 OUT LC The current value operates as a ring counter Precautions The last number of a word device cannot be input as the long counter set value Indirect specification cannot be input as the long counter set value Operation error There is no operation error 1 Up counting 2 Down counting only when using a high speed counter 2147483648 2147483647 2 1 0 1 2 2147483646 2147483647 1 2 2 1 ...

Page 584: ...3 s 1 Sets the station No to be called s 2 Sets the product No to be called n1 Number of divisions 2 to 32767 16 bit unsigned binary ANY16 n2 Number of low speed sections 0 to 32767 16 bit unsigned binary ANY16 d Registers bit devices specifying the calling condition Construct an internal contact circuit in advance which is driven by the input signal X d A phase signal Bit ANY16_ARRAY Number of el...

Page 585: ...1 of the table and number of low speed sections n2 Precautions When the command input is set to ON and this instruction is executed the result will be automatically output to d 3 to d 7 When the command input is set to OFF d 3 to d 7 are set to OFF accordingly For example when the rotation detection signal d to d 2 is activated 10 times in one division set a value multiplied by 10 to each division...

Page 586: ...range specified by s exceeds the corresponding device range The device range specified by d exceeds the corresponding device range 3405H The value specified by n1 is outside the following range 2 to 32767 The value specified by n2 is outside the following range 0 to 32767 The value specified by n1 or n2 is in the following condition n1 n2 Either s s 1 or s 2 is negative Either s s 1 or s 2 is equa...

Page 587: ... EN s1 s2 n d FBD LD Operand Description Range Data type Data type label s1 Initial value of ramp 16 bit signed binary ANY16 s2 Target value of ramp 16 bit signed binary ANY16 d d 0 Current value 16 bit signed binary ANY16_ARRAY Number of elements 2 d 1 Number of scans n Ramp transfer time scan 1 to 32767 16 bit unsigned binary ANY16_U EN Execution condition Bit BOOL ENO Execution result Bit BOOL ...

Page 588: ... to ON again d is cleared and the operation is started from s1 After transfer is completed the instruction execution complete flag SM8029 turns ON and the d value is returned to the s1 value When the operation result is acquired at a constant time interval constant scan mode write a prescribed scan time which is longer than the actual scan time to SD8039 and set SM8039 to ON For example when 20 ms...

Page 589: ...backed type device as d when setting the CPU module to the RUN mode while the command input is ON clear d in advance Operation error Error code SD0 SD8067 Description 2820H The device range specified by d exceeds the corresponding device range 3405H The value specified by n is outside the following range 1 to 32767 s2 s1 SM8029 d s2 s1 d SM8029 Command Command When SM8026 is on When SM8026 is off ...

Page 590: ...in the device specified by d The high speed pulse input output module is not supported Setting data Descriptions ranges and data types Instruction CPU module High speed pulse input output module SPD DSPD PLSY For the FX3 compatible operand specification PLSY For the FX5 operand specification DPLSY For the FX3 compatible operand specification DPLSY For the FX5 operand specification PWM DPWM Ladder ...

Page 591: ...counts the number of pulses by the high speed counter setting of the channel number corresponding to each word device When a bit device is specified by s1 the following input assignment devices shaded area are valid When the high speed counter FX3 compatibility function is enabled only the 1 phase 1 input pulse input mode S W general purpose input assignment of the 1 phase 1 input counter switchin...

Page 592: ...7 X11 X13 X15 X17 is specified as a device an error occurs A A phase pulse input B B phase pulse input P Preset input reset E Enable input start If one of X1 X3 X5 X7 X11 X13 X15 X17 is specified as a device an error occurs X0 X1 X2 X3 X4 X5 X6 X7 X10 X11 X12 X13 X14 X15 X16 X17 CH1 C A CH2 CH3 CH4 CH5 CH6 CH7 CH8 P E P E P E P E P E P E P E D B D B D B D B D B D B D B D B C A C A C A C A C A C A ...

Page 593: ... rounded into 1 with the sign Operation error Function CH1 CH2 CH3 CH4 CH5 CH6 CH7 CH8 Monitor in operation SM4500 SM4501 SM4502 SM4503 SM4504 SM4505 SM4506 SM4507 High speed counter pulse density SD4507 SD4506 SD4537 SD4536 SD4567 SD4566 SD4597 SD4596 SD4627 SD4626 SD4657 SD4656 SD4687 SD4686 SD4717 SD4716 Measurement unit time SD4517 SD4516 SD4547 SD4546 SD4577 SD4576 SD4607 SD4606 SD4637 SD4636...

Page 594: ...device is specified specify one of the channel numbers CH1 to CH8 When FX3 compatible function of a high speed counter is valid a channel number cannot be specified Only X can be used for a bit device If the channel numbers is specified in s1 an error occurs Ladder diagram Structured text ENO DSPD EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Pulse input Bit Word Double ...

Page 595: ...1 phase 1 input counter switching S W up or down is enabled General purpose input assignment of the 1 phase 1 input counter switching S W up or down General purpose input assignment of the 1 phase 1 input counter switching H W up or down 1 The elapsed time is judged using the 1ms interrupt and the counted result is stored in d 1 and d U D UP DOWN pulse input P Preset input reset E Enable input sta...

Page 596: ...High speed counter pulse density SD4507 SD4506 SD4537 SD4536 SD4567 SD4566 SD4597 SD4596 SD4627 SD4626 SD4657 SD4656 SD4687 SD4686 SD4717 SD4716 Measurement unit time SD4517 SD4516 SD4547 SD4546 SD4577 SD4576 SD4607 SD4606 SD4637 SD4636 SD4667 SD4666 SD4697 SD4696 SD4727 SD4726 Function R W Update timing Clear Monitor in operation R When the DSPD instruction is executed When the DHIOEN instruction...

Page 597: ...me which exceeds the ring length of the high speed counter cannot be input The measurement time specified by s2 overwrites the value stored in the SD device specified for the measurement unit time When the measurement time specified by s2 is outside the range from 1 to 2147483647 the specified measurement time is rounded into 1 with the sign Operation error FX5U 32M FX5UC 32M CPU module Used input...

Page 598: ...eed s so that the command speed is 200 kpps or less when the command speed is converted to frequency Set the value from 0 to 65535 in user unit to the positioning address n so that the positioning address is within the range from 0 to 2147483647 when the positioning address is converted to number of pulses Specify the Y device number Y0 to Y3 in d Ladder diagram Structured text ENO PLSY EN s n d F...

Page 599: ...eceleration stop command 1 ON Deceleration stop command is on OFF Deceleration stop command is off SM5660 SM5661 SM5662 SM5663 Forward limit ON Forward limit is on OFF Forward limit is off SM5676 SM5677 SM5678 SM5679 Reverse limit ON Reverse limit is on OFF Reverse limit is off Axis number Name 1 2 3 4 SD5500 SD5501 SD5540 SD5541 SD5580 SD5581 SD5620 SD5621 Current address in user unit SD5502 SD55...

Page 600: ... pulses by the pulses conversion of the command speed and positioning address exceed the 32 bit range an error occurs and the operation cannot be performed The PLSY instruction always increases the current address because the setting of rotation direction is disabled due to the absence of direction When the output mode is CW CCW mode output is always performed from the device set to CW If reverse ...

Page 601: ...o be not used by parameters such as interrupt input signal 1 and zero return relations is used 3631H 3632H 3633H 3634H The numbers of pulses by the pulses conversion of the positioning address specified by n exceed the 32 bit range 3641H 3642H 3643H 3644H The numbers of pulses by the pulses conversion of the command speed specified by s exceed the 32 bit range 3651H 3652H 3653H 3654H The operation...

Page 602: ...hen the command speed is converted to frequency Set the value from 0 to 65535 in user unit in the positioning address n so that the positioning address is within the range from 0 to 2147483647 when the positioning address is converted to number of pulses Specify the axis number K1 to K4 in which positioning parameters exist in d Ladder diagram Structured text ENO PLSY EN s n d FBD LD Operand Descr...

Page 603: ...eceleration stop command 1 ON Deceleration stop command is on OFF Deceleration stop command is off SM5660 SM5661 SM5662 SM5663 Forward limit ON Forward limit is on OFF Forward limit is off SM5676 SM5677 SM5678 SM5679 Reverse limit ON Reverse limit is on OFF Reverse limit is off Axis number Name 1 2 3 4 SD5500 SD5501 SD5540 SD5541 SD5580 SD5581 SD5620 SD5621 Current address in user unit SD5502 SD55...

Page 604: ...pulses by the pulses conversion of the command speed and positioning address exceed the 32 bit range an error occurs and the operation cannot be performed The PLSY instruction always increases the current address because the setting of rotation direction is disabled due to the absence of direction When the output mode is CW CCW mode output is always performed from the device set to CW If reverse l...

Page 605: ...o be not used by parameters such as interrupt input signal 1 and zero return relations is used 3631H 3632H 3633H 3634H The numbers of pulses by the pulses conversion of the positioning address specified by n exceed the 32 bit range 3641H 3642H 3643H 3644H The numbers of pulses by the pulses conversion of the command speed specified by s exceed the 32 bit range 3651H 3652H 3653H 3654H The operation...

Page 606: ...that the command speed is 200 kpps or less when the command speed is converted to frequency Set the value from 0 to 2147483647 in user unit to the positioning address n so that the positioning address is within the range from 0 to 2147483647 when the positioning address is converted to number of pulses Specify the Y device number Y0 to Y3 in d Ladder diagram Structured text ENO DPLSY EN s n d FBD ...

Page 607: ...eceleration stop command 1 ON Deceleration stop command is on OFF Deceleration stop command is off SM5660 SM5661 SM5662 SM5663 Forward limit ON Forward limit is on OFF Forward limit is off SM5676 SM5677 SM5678 SM5679 Reverse limit ON Reverse limit is on OFF Reverse limit is off Axis number Name 1 2 3 4 SD5500 SD5501 SD5540 SD5541 SD5580 SD5581 SD5620 SD5621 Current address in user unit SD5502 SD55...

Page 608: ...pulses by the pulses conversion of the command speed and positioning address exceed the 32 bit range an error occurs and the operation cannot be performed The DPLSY instruction always increases the current address because the setting of rotation direction is disabled due to the absence of direction When the output mode is CW CCW mode output is always performed from the device set to CW If reverse ...

Page 609: ...o be not used by parameters such as interrupt input signal 1 and zero return relations is used 3631H 3632H 3633H 3634H The numbers of pulses by the pulses conversion of the positioning address specified by n exceed the 32 bit range 3641H 3642H 3643H 3644H The numbers of pulses by the pulses conversion of the command speed specified by s exceed the 32 bit range 3651H 3652H 3653H 3654H The operation...

Page 610: ... command speed is converted to frequency Set the value from 0 to 2147483647 in user unit to the positioning address n so that the positioning address is within the range from 0 to 2147483647 when the positioning address is converted to number of pulses Specify the axis number K1 to K4 in which positioning parameters exist in d Ladder diagram Structured text ENO DPLSY EN s n d FBD LD Operand Descri...

Page 611: ...eceleration stop command 1 ON Deceleration stop command is on OFF Deceleration stop command is off SM5660 SM5661 SM5662 SM5663 Forward limit ON Forward limit is on OFF Forward limit is off SM5676 SM5677 SM5678 SM5679 Reverse limit ON Reverse limit is on OFF Reverse limit is off Axis number Name 1 2 3 4 SD5500 SD5501 SD5540 SD5541 SD5580 SD5581 SD5620 SD5621 Current address in user unit SD5502 SD55...

Page 612: ... pulses by the pulses conversion of the command speed and positioning address exceed the 32 bit range an error occurs and the operation cannot be performed The PLSY instruction always increases the current address because the setting of rotation direction is disabled due to the absence of direction When the output mode is CW CCW mode output is always performed from the device set to CW If reverse ...

Page 613: ...o be not used by parameters such as interrupt input signal 1 and zero return relations is used 3631H 3632H 3633H 3634H The numbers of pulses by the pulses conversion of the positioning address specified by n exceed the 32 bit range 3641H 3642H 3643H 3644H The numbers of pulses by the pulses conversion of the command speed specified by s exceed the 32 bit range 3651H 3652H 3653H 3654H The operation...

Page 614: ...fy K1 to K4 axis 1 to 4 for the CPU module and K5 to K12 axis 5 to 12 for the high speed pulse input output module Processing details This instruction outputs the pulse of the ON time specified by s1 and the period specified by s2 to the output destination specified by d Time with a unit selected on the parameter setting screen s or ms can be specified by s1 and s2 Ladder diagram Structured text E...

Page 615: ...uted END processing STOP PAUSE RUN CH2 SD5317 SD5316 CH3 SD5333 SD5332 CH4 SD5349 SD5348 CH5 SD5365 SD5364 CH6 SD5381 SD5380 CH7 SD5397 SD5396 CH8 SD5413 SD5412 CH9 SD5429 SD5428 CH10 SD5445 SD5444 CH11 SD5461 SD5460 CH12 SD5477 SD5476 Pulse output destination channel ON time R W Initial value Timing of reflection on operation Timing of clearing to initial value CH1 SD5303 SD5302 R W 0 2 When the ...

Page 616: ...ulses are monitored When the PWM output is executed several times the monitor of the number of output pulses is an integrated value The monitor of the current number of output pulses can be changed during the pulse output The monitor of the current number of output pulses is updated when the number of pulses is counted at the falling edge of pulses in the positive logic and at the rising edge of p...

Page 617: ...put output module 5 to 12 in a program with interrupt priority set to 1 Operations when the PWM output is stopped while the output pulse is on Period Output stop command If an output stop command is issued while the ON time setting is 5 s or less outputting pulses stops after the set ON time elapses When the ON time setting is 5 s or more and 5 s or less time has elapsed when an output stop comman...

Page 618: ... ON state continues even after Period x Number of output pulses is finished in this condition OFF time setting is 5 s or more OFF time setting is 5 s or more OFF time setting is 5 s or more OFF time setting is 5 s or more OFF time setting is 5 s or less OFF time setting is 5 s or less Output stop command is issued within 5 s of the OFF width time 5 s or less 5 s or more Output stop command is issu...

Page 619: ...ion specified by d The PWM output stops 3580H An instruction that cannot be used in an interrupt program is used 3600H A channel number that is not selected in the parameter setting are specified for the output destination specified by d The PWM output is not executed 3611H CH1 3612H CH2 3613H CH3 3614H CH4 3615H CH5 3616H CH6 3617H CH7 3618H CH8 3619H CH9 361AH CH10 361BH CH11 361CH CH12 The ON t...

Page 620: ... K4 axis 1 to 4 for the CPU module and K5 to K12 axis 5 to 12 for the high speed pulse input output module Processing details This instruction outputs the pulse of the ON time specified by s1 and the period specified by s2 to the output destination specified by d Time with a unit selected on the parameter setting screen s or ms can be specified by s1 and s2 Ladder diagram Structured text ENO DPWM ...

Page 621: ...uted END processing STOP PAUSE RUN CH2 SD5317 SD5316 CH3 SD5333 SD5332 CH4 SD5349 SD5348 CH5 SD5365 SD5364 CH6 SD5381 SD5380 CH7 SD5397 SD5396 CH8 SD5413 SD5412 CH9 SD5429 SD5428 CH10 SD5445 SD5444 CH11 SD5461 SD5460 CH12 SD5477 SD5476 Pulse output destination channel ON time R W Initial value Timing of reflection on operation Timing of clearing to initial value CH1 SD5303 SD5302 R W 0 2 When the ...

Page 622: ...lses are monitored When the DPWM output is executed several times the monitor of the number of output pulses is an integrated value The monitor of the current number of output pulses can be changed during the pulse output The monitor of the current number of output pulses is updated when the number of pulses is counted at the falling edge of pulses in the positive logic and at the rising edge of p...

Page 623: ...rror occurs Do not specify the channel numbers of the high speed pulse input output module 5 to 12 in a program with interrupt priority set to 1 Operations when the PWM output is stopped while the output pulse is on Period Output stop command If an output stop command is issued while the ON time setting is 5 s or less outputting pulses stops after the set ON time elapses When the ON time setting i...

Page 624: ...t ON state continues even after Period x Number of output pulses is finished in this condition OFF time setting is 5 s or more OFF time setting is 5 s or more OFF time setting is 5 s or more OFF time setting is 5 s or more OFF time setting is 5 s or less OFF time setting is 5 s or less Output stop command is issued within 5 s of the OFF width time 5 s or less 5 s or more Output stop command is iss...

Page 625: ...nterrupt program is used 3600H A channel number that is not selected in the parameter setting are specified for the output destination specified by d The PWM output is not executed 3611H CH1 3612H CH2 3613H CH3 3614H CH4 3615H CH5 3616H CH6 3617H CH7 3618H CH8 3619H CH9 361AH CH10 361BH CH11 361CH CH12 The ON time specified by s1 is larger than the period specified by s2 The PWM output stops In s1...

Page 626: ...Operand Description Range Data type Data type label s Input device X number of matrix signal input X0 X10 X20 final input device number Only 0 is allowed in the least significant digit of device numbers Bit ANYBIT_ARRAY Number of elements 8 d1 Head device Y number of matrix signal output Y0 Y10 Y20 final output device number Only 0 is allowed in the least significant digit of device numbers Bit AN...

Page 627: ...ix in the 1st to nth last columns is being input Command contact SM8029 execution complete 1 4 1st column input is received 2 2nd column input is received 20ms 3 6 5 COM S S Input X sink Output Y sink n points are occupied Diode 0 1A 50V 2nd column 1st column CPU module 0V 24V d1 1 S 1 S d2 17 d2 16 d2 15 d2 14 d2 13 d2 12 d2 11 d2 d2 7 d2 6 d2 5 d2 4 d2 3 d2 2 d2 1 d2 10 d1 S 2 S 3 S 4 S 5 S 7 S ...

Page 628: ...istors use the power supply shown in the table below The figure below shows an example of the FX5U 64MT ES sink input sink output Because 64 input points 8 rows 8 columns are received in a cycle of 80 or 160 ms the ON OFF duration of each input signal should be greater than or equal to the value shown below Operation error Power supply used for pull up resistors transistor output AC power type CPU...

Page 629: ...ad device Ladder diagram Structured text ENO IST EN s d1 d2 FBD LD Operand Description Range Data type Data type label s Head bit device number of the selector switch in the operation mode Bit ANYBIT_ARRAY Number of elements 8 d1 Smallest state relay number of practical state relays in the automatic mode d1 d2 Bit ANY_BOOL d2 Largest state relay number of practical state relays in the automatic mo...

Page 630: ... Stop Stops each operation Device number Descriptions ON OFF condition SM8040 STL transfer disable ON condition Always remains ON in the individual operation Always remains ON in the stepping operation except when the START button is pressed Turns ON when the STOP button is pressed during return to the zero point and in the cycle operation OFF condition Turns OFF when the START button is pressed i...

Page 631: ...e IST instruction can only be used once in a program Device number Descriptions ON OFF condition S0 Individual operation initial state ON condition when a individual operation mode is selected OFF condition Except a individual operation mode S1 Zero return initial state ON condition when a zero return operation mode is selected OFF condition Except a zero return operation mode S2 Automatic operati...

Page 632: ...ulse Stop X22 Stepping operation X23 Cycle operation X027Stop SM8002Initial pulse SM8040Self holding SM8000 SM8047 RUN monitor Enable STL monitoring X20 Individual operation S 0 SM8044 Zero point condition SM8043 Zero return complete X21 Zero return S 1 X25 Zero return start Zero return complete signal is reset SM8043 RST PLS X22 to X24 Automatic operation Zero return complete SM8043 SM8041 Transf...

Page 633: ... mode When the start button is pressed while the machine is located at the zero point the machine starts continuous operation When the stop button is pressed the machine finishes the current cycle until the zero point and then stops at the zero point Input device Assignment X20 Individual operation mode X21 Zero return operation mode X22 Stepping operation mode Unclamping Y1 Pushbutton switches fo...

Page 634: ...ration X32 M 5 M 6 Automatic mode start X33 M 7 Stop SM8000 SM8000 Individual operation mode When inputs do not have consecutive device numbers Example In this example M0 is used as the head input for mode specification X30 Individual operation mode X35 Zero return operation mode X33 Stepping operation mode X40 Cycle operation mode X32 Continuous operation mode X34 Zero return start X26 Automatic ...

Page 635: ...art This special relay allows transfer from the initial state S2 to the next state Individual operation mode and zero return operation mode SM8041 is not effective Stepping operation mode and cycle operation mode SM8041 is effective only while the start button is pressed and held Continuous operation mode The operation is latched when the start button is pressed and cleared when the stop button is...

Page 636: ...up command Moving down command Leftward travel command Rightward travel command Moving up Moving down Leftward travel Rightward travel Upper limit Initial state for individual operation SET X25 Zero return start S10 RST S10 Y1 Y2 RST Y0 STL S1 STL S10 SET X2 Upper limit S11 STL S11 SET X4 Left limit S12 STL S12 RST SM8043 S12 SM400 RETSTL SET SM8043 RST S11 Y3 Y4 Unclamping Zero return complete Mo...

Page 637: ...1 Down limit Upper limit S21 STL S22 SET T0 S22 RETSTL END SET Y1 T0 K10 STL S25 SET X1 Down limit S25 S25 RST Y1 T1 K10 Y0 Y2 STL S26 SET T1 S26 Y2 STL S23 SET X2 S23 Y3 Right limit STL S24 SET X3 S24 Y0 Upper limit STL S27 SET X2 S27 Left limit X4 Y4 S2 SM400 SM400 SM400 SM400 SM400 SM400 SM400 Moving down Clamping Moving up Rightward travel Moving down Moving up Leftward travel Unclamping Initi...

Page 638: ...r of times the IST instruction is simultaneously driven exceeds 1 2820H The device numbers specified in d1 and d2 show the following relationship d1 d2 Eight points are not secured from the device specified in s An unavailable device is set in s An unavailable device is set in d1 An unavailable device is set in d2 ...

Page 639: ...Structured text ENO ABSD EN s1 s2 n d FBD LD Operand Description Range Data type Data type label s1 Head device number storing the data table with rising and falling point data 16 bit signed binary ANY16 s2 Counter number for monitoring the current value compared with the data table 16 bit signed binary ANY16 d Head bit device number to be output Bit ANY_BOOL n Number of lines in the table and the...

Page 640: ... the data in s1 to s1 2 n 1 Precautions When specifying the nibble of a bit device to s1 specify a multiple of 16 0 16 32 64 as a device number and always specify K4 for the number of digits The value of n determines the number of target outputs 1 n 64 Even if the command input is set to OFF the ON OFF status of outputs does not change Operation error Rising point Falling point Target output Data ...

Page 641: ...re controlled to on or off during one rotation Ladder diagram Structured text ENO DABSD EN s1 s2 n d FBD LD Operand Description Range Data type Data type label s1 Head device number storing the data table with rising and falling point data 32 bit signed binary ANY32 s2 Counter number for monitoring the current value compared with the data table 32 bit signed binary ANY32 d Head bit device number t...

Page 642: ...an cycle with regard to the current value of a counter When specifying the nibble of a bit device to s1 specify a multiple of 16 0 16 32 64 as a device number and always specify K8 for the number of digits The value of n determines the number of target outputs 1 n 64 Even if the command input is set to OFF the ON OFF status of outputs does not change Operation error Rising point Falling point Targ...

Page 643: ...owing ladder example shows the operation s2 occupies two points In the following timing chart C0 and C1 correspond to the two points Ladder diagram Structured text ENO INCD EN s1 s2 n d FBD LD Operand Description Range Data type Data type label s1 Head word device number storing the set value 16 bit signed binary ANY16 s2 Head counter number for monitoring current value is monitored 16 bit signed ...

Page 644: ...final process specified by n is finished the execution complete flag SM8029 turns on and remains on for one operation cycle SM8029 is used for many instructions as the instruction execution complete flag Use SM8029 as a contact just after a corresponding instruction The program execution returns to the beginning and outputs are repeated Precautions When specifying the nibble of a bit device to s1 ...

Page 645: ...T ST C cannot be used Ladder diagram Structured text ENO CCD EN s n d ENO CCDP EN s n d FBD LD Operand Description Range Data type Data type label s Head device number of applicable device 16 bit signed binary ANY16 d Head device number storing the calculated data 16 bit signed binary ANY16_ARRAY Number of elements 2 n Number of data 1 to 32767 16 bit unsigned binary ANY16_U EN Execution condition...

Page 646: ...1 is cleared when the CPU module mode is changed from RUN to STOP In the following program conversion is executed as follows s D100 K100 0 1 1 0 0 1 0 0 D100 K111 0 1 1 0 1 1 1 D101 K100 0 1 1 0 0 1 0 0 D101 K 98 0 1 1 0 0 0 1 0 D102 K123 0 1 1 1 1 0 1 D102 K 66 0 1 0 0 0 0 1 0 D103 K100 0 1 1 0 0 1 0 0 D103 K 95 0 1 0 1 1 1 1 D104 K210 1 1 0 1 0 0 1 0 D104 K 88 0 1 0 1 1 0 0 0 K1091 1 0 0 0 0 1 0...

Page 647: ...by s or d exceeds the corresponding device range 3405H The value specified by n is outside the following range 1 to 32767 s D100 K100 0 1 1 0 0 1 0 0 K111 0 1 1 0 1 1 1 D105 D106 D107 D109 D108 D101 K100 0 1 1 0 0 1 0 0 K 98 0 1 1 0 0 0 1 0 D102 D103 D104 K123 0 1 1 1 1 0 1 K 66 0 1 0 0 0 0 1 0 K100 0 1 1 0 0 1 0 0 K 95 0 1 0 1 1 1 1 K210 1 1 0 1 0 0 1 0 K 88 0 1 0 1 1 0 0 0 K1091 1 0 0 0 0 1 0 CC...

Page 648: ...tion In this case however 0 is stored in three devices starting from d which store the number of same data first position and last position Ladder diagram Structured text ENO SERMM EN s1 s2 n d ENO SERMMP EN s1 s2 n d FBD LD Operand Description Range Data type Data type label s1 Head device number in which same data maximum value and minimum value are searched 16 bit signed binary ANY16 s2 Data to...

Page 649: ...d in other controls for the machine Operation error Searched device s1 Searched data s1 value example Comparison data s2 value example Data position Search result Maximum value d 4 Same d Minimum value d 3 s1 K100 K100 0 First time s1 1 K111 1 s1 2 K100 2 s1 3 K98 3 s1 4 K123 4 s1 5 K66 5 s1 6 K100 6 Last s1 7 K95 7 s1 8 K210 8 s1 9 K88 9 Device number Description Search result item d 3 Number of ...

Page 650: ...minimum value position In this case however 0 is stored in three 32 bit devices starting from d 1 and d which store the number of same data first position and last position Ladder diagram Structured text ENO DSERMM EN s1 s2 n d ENO DSERMMP EN s1 s2 n d FBD LD Operand Description Range Data type Data type label s1 Head device number in which same data maximum value and minimum value are searched 32...

Page 651: ... Searched device s1 Searched data s1 value example Comparison data s2 value example Data position Search result Maximum value d 9 d 8 Same d Minimum value d 7 d 6 s1 1 s K100000 K100000 0 First time s1 3 s1 2 K110100 1 s1 5 s1 4 K100000 2 s1 7 s1 6 K98000 3 s1 9 s1 8 K123000 4 s1 11 s1 10 K66000 5 s1 13 s1 12 K100000 6 Last s1 15 s1 14 K95000 7 s1 17 s1 16 K910000 8 s1 19 s1 18 K910000 9 Device nu...

Page 652: ... executed The output of the number of bits in the on status is latched in the previous status Operation error There is no operation error Ladder diagram Structured text ENO SUM EN s d ENO SUMP EN s d FBD LD Operand Description Range Data type Data type label s Head device number that counts the total bits of 1 16 bit signed binary ANY16 d Head device number storing the total bits 16 bit signed bin...

Page 653: ...t of the number of bits in the on status is latched in the previous status Operation error There is no operation error Ladder diagram Structured text ENO DSUM EN s d ENO DSUMP EN s d FBD LD Operand Description Range Data type Data type label s Head device number that counts the total bits of 1 32 bit signed binary ANY32 d Head device number storing the total bits 16 bit signed binary ANY16 EN Exec...

Page 654: ...se instructions turn d off When a constant K is specified in the device specified by s it is automatically converted into binary Ladder diagram Structured text ENO BON EN s n d ENO BONP EN s n d FBD LD Operand Description Range Data type Data type label s Word device number storing the data 16 bit signed binary ANY16 d Bit device number to be driven Bit ANY_BOOL n Bit position to be checked 0 to 1...

Page 655: ...8 APPLICATION INSTRUCTION 8 22 Data Operation Instruction 653 8 Operation error Error code SD0 SD8067 Description 3405H The value specified by n is outside the following range 0 to 15 ...

Page 656: ...hen a constant K is specified in the device specified by s it is automatically converted into binary Ladder diagram Structured text ENO DBON EN s n d ENO DBONP EN s n d FBD LD Operand Description Range Data type Data type label s Word device number storing the data 32 bit signed binary ANY32 d Bit device number to be driven Bit ANY_BOOL n Bit position to be checked 0 to 31 16 bit unsigned binary A...

Page 657: ...8 APPLICATION INSTRUCTION 8 22 Data Operation Instruction 655 8 Operation error Error code SD0 SD8067 Description 3405H The value specified by n is outside the following range 0 to 31 ...

Page 658: ...Ladder diagram Structured text 1 ENO MAXP EN s n d ENO MAXP_U EN s n d FBD LD 1 Operand Description Range Data type Data type label s MAX P Head device number where the maximum value is searched 16 bit signed binary ANY16_S MAX P _U 16 bit unsigned binary ANY16_U d MAX P Head device number for storing the maximum value 16 bit signed binary ANY16_S_ARRAY Number of elements 3 MAX P _U 16 bit unsigne...

Page 659: ...ng from the device specified by s and store the location from s of the first maximum value in d 1 and the number of maximum values in d 2 Operation error d Maximum value d 1 Position d 2 Number of data Error code SD0 SD8067 Description 2820H The n point s of data in the device starting from the one specified by s exceed the corresponding device range The device specified by d exceeds the correspon...

Page 660: ...dder diagram Structured text 1 ENO DMAXP EN s n d ENO DMAXP_U EN s n d FBD LD 1 Operand Description Range Data type Data type label s DMAX P Head device number where the maximum value is searched 32 bit signed binary ANY32_S DMAX P _U 32 bit unsigned binary ANY32_U d DMAX P Head device number for storing the maximum value 32 bit signed binary ANY32_S_ARRAY Number of elements 4 DMAX P _U 32 bit uns...

Page 661: ...specified by s and store the location from s of the first minimum value in d 2 and the number of maximum values in d 3 Operation error d 1 d Maximum value d 2 Position d 3 Number of data Error code SD0 SD8067 Description 2820H The n point s of data in the device starting from the one specified by s exceed the corresponding device range The device specified by d exceeds the corresponding device ran...

Page 662: ...Ladder diagram Structured text 1 ENO MINP EN s n d ENO MINP_U EN s n d FBD LD 1 Operand Description Range Data type Data type label s MIN P Head device number where the minimum value is searched 16 bit signed binary ANY16_S MIN P _U 16 bit unsigned binary ANY16_U d MIN P Head device number for storing the minimum value 16 bit signed binary ANY16_S_ARRAY Number of elements 3 MIN P _U 16 bit unsigne...

Page 663: ...ng from the device specified by s and store the location from s of the first minimum value in d 1 and the number of minimum values in d 2 Operation error d Minimum value d 1 Position d 2 Number of data Error code SD0 SD8067 Description 2820H The n point s of data in the device starting from the one specified by s exceed the corresponding device range The device specified by d exceeds the correspon...

Page 664: ... by s and store the location from s of the first minimum value in d 2 and the number of minimum values in d 3 Ladder diagram Structured text 1 ENO DMINP EN s n d ENO DMINP_U EN s n d FBD LD 1 Operand Description Range Data type Data type label s DMIN P Head device number where the minimum value is searched 32 bit signed binary ANY32_S DMIN P _U 32 bit unsigned binary ANY32_U d DMIN P Head device n...

Page 665: ...tion 663 8 Operation error Error code SD0 SD8067 Description 2820H The n point s of data in the device starting from the one specified by s exceed the corresponding device range The device specified by d exceeds the setting area in the device label memory ...

Page 666: ... points specified by d Ladder diagram Structured text ENO SORTTBL EN s n1 n2 n3 d ENO SORTTBL_U EN s n1 n2 n3 d FBD LD Operand Description Range Data type Data type label s SORTTBL Head device number storing the data table 16 bit signed binary ANY16 SORTTBL_U 16 bit unsigned binary ANY16_U n1 Number of data lines 1 to 32 16 bit unsigned binary ANY16_U n2 Number of group data columns 1 to 6 16 bit ...

Page 667: ... executed with n3 K2 column No 2 Number of groups n2 K4 Column No 1 Column No 2 Column No 3 Column No 4 Control number Height Weight Age Number of data n1 3 Line No 1 s s 3 s 6 s 9 Line No 2 s 1 s 4 s 7 s 10 Line No 3 s 2 s 5 s 8 s 11 Number of groups n2 K4 Column No 1 Column No 2 Column No 3 Column No 4 Control number Height Weight Age Number of data n1 5 Line No 1 s s 5 s 10 s 15 1 150 45 20 Lin...

Page 668: ...or code SD0 SD8067 Description 1811H These instructions are used more than once 2820H The device range specified by s exceeds the corresponding device range The device range specified by d exceeds the corresponding device range 3405H The value specified by n1 is outside the following range 1 to 32 The value specified by n2 is outside the following range 1 to 6 The value specified by n3 is outside ...

Page 669: ...he data table sorting result of 16 bit binary data having n1 n2 points specified by d Ladder diagram Structured text ENO SORTTBL2 EN s n1 n2 n3 d ENO SORTTBL2_U EN s n1 n2 n3 d FBD LD Operand Description Range Data type Data type label s SORTTBL2 Head device number storing the data table 16 bit signed binary ANY16 SORTTBL2_U 16 bit unsigned binary ANY16_U n1 Number of data lines 1 to 32 16 bit uns...

Page 670: ...No 2 in the case of ascending order SM703 OFF Number of groups n2 K4 Column No 1 Column No 2 Column No 3 Column No 4 Control number Height Weight Age Number of data n1 3 Line No 1 s s 1 s 2 s 3 Line No 2 s 4 s 5 s 6 s 7 Line No 3 s 8 s 9 s 10 s 11 Sorting order SM703 ON Descending order SM703 OFF Ascending order Number of groups n2 K4 Column No 1 Column No 2 Column No 3 Column No 4 Control number ...

Page 671: ...Description 2820H The device range specified by s exceeds the corresponding device range The device range specified by d exceeds the corresponding device range 3405H The value specified by n1 is outside the following range 1 to 32 The value specified by n2 is outside the following range 1 to 6 The value specified by n3 is outside the following range 1 to n2 Number of groups n2 K4 Column No 1 Colum...

Page 672: ...data table sorting result of 32 bit binary data having n1 n2 points specified by d Ladder diagram Structured text ENO DSORTTBL2 EN s n1 n2 n3 d ENO DSORTTBL2_U EN s n1 n2 n3 d FBD LD Operand Description Range Data type Data type label s DSORTTBL2 Head device number storing the data table 32 bit signed binary ANY32 DSORTTBL2_U 32 bit unsigned binary ANY32_U n1 Number of data lines 1 to 32 16 bit un...

Page 673: ...er Height Weight Age Number of data n1 3 Line No 1 s 1 s s 3 s 2 s 5 s 4 s 7 s 6 Line No 2 s 9 s 8 s 11 s 10 s 13 s 12 s 15 s 14 Line No 3 s 17 s 16 s 19 s 18 s 21 s 20 s 23 s 22 Sorting order SM703 ON Descending order SM703 OFF Ascending order Number of groups n2 K4 Column No 1 Column No 2 Column No 3 Column No 4 Control number Height Weight Age Number of data n1 5 Line No 1 s 1 s s 3 s 2 s 5 s 4...

Page 674: ...exceeds the corresponding device range The device range specified by d exceeds the corresponding device range 3405H The value specified by n1 is outside the following range 1 to 32 The value specified by n2 is outside the following range 1 to 6 The value specified by n3 is outside the following range 1 to n2 Number of groups n2 K4 Column No 1 Column No 2 Column No 3 Column No 4 Control number Heig...

Page 675: ...ta type label s WSUM P Head device number where the addition target data are stored 16 bit signed binary ANY16_S WSUM P _U 16 bit unsigned binary ANY16_U d WSUM P Head device number storing sum 32 bit signed binary ANY32_S WSUM P _U 32 bit unsigned binary ANY32_U n Number of data 16 bit unsigned binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word...

Page 676: ... CPU module can handle the low order 32 bits of 32 bit data as the sum while ignoring the high order 32 bits Ladder diagram Structured text ENO DWSUM EN s n d ENO DWSUMP EN s n d ENO DWSUM_U EN s n d ENO DWSUMP_U EN s n d FBD LD Operand Description Range Data type Data type label s DWSUM P Head device number where the addition target data are stored 32 bit signed binary ANY32_S DWSUM P _U 32 bit u...

Page 677: ...eration error Error code SD0 SD8067 Description 2820H The device range specified by d exceeds the corresponding device range The n point s of data in the device starting from s exceed the corresponding device range 3405H The data stored in a device specified by n is 0 ...

Page 678: ... is exceeded n is handled as a smaller value in the possible range Ladder diagram Structured text ENO MEAN EN s n d ENO MEANP EN s n d ENO MEAN_U EN s n d ENO MEANP_U EN s n d FBD LD Operand Description Range Data type Data type label s MEAN P Head device number where the mean value target data are stored 16 bit signed binary ANY16_S MEAN P _U 16 bit unsigned binary ANY16_U d MEAN P Head device nu...

Page 679: ...8 APPLICATION INSTRUCTION 8 22 Data Operation Instruction 677 8 Operation error Error code SD0 SD8067 Description 3405H The value stored in a device specified by n is 0 ...

Page 680: ... n is handled as a smaller value in the possible range Ladder diagram Structured text ENO DMEAN EN s n d ENO DMEANP EN s n d ENO DMEAN_U EN s n d ENO DMEANP_U EN s n d FBD LD Operand Description Range Data type Data type label s DMEAN P Head device number where the mean value target data are stored 32 bit signed binary ANY32_S DMEAN P _U 32 bit unsigned binary ANY32_U d DMEAN P Head device number ...

Page 681: ...8 APPLICATION INSTRUCTION 8 22 Data Operation Instruction 679 8 Operation error Error code SD0 SD8067 Description 3405H The value stored in a device specified by n is 0 ...

Page 682: ...obtained square root is an integer because the decimal point is ignored When the calculated decimal value is ignored SM8021 borrow flag turns on When the operation result is true 0 SM8020 zero flag turns on Operation error Ladder diagram Structured text 1 ENO SQRTP EN s d FBD LD 1 Operand Description Range Data type Data type label s Device where the data whose square root is operated is calculate...

Page 683: ...the calculated decimal value is ignored SM8021 borrow flag turns on When the operation result is true 0 SM8020 zero flag turns on Operation error Ladder diagram Structured text ENO DSQRT EN s d ENO DSQRTP EN s d FBD LD Operand Description Range Data type Data type label s Device where the data whose square root is operated is calculated 32 bit signed binary ANY32 d Device for storing the calculate...

Page 684: ...dder diagram Structured text ENO CRC EN s n d ENO CRCP EN s n d FBD LD Operand Description Range Data type Data type label s Head device number storing data for which the CRC value is generated 16 bit signed binary ANY16 d Device number storing the generated CRC value 16 bit signed binary ANY16 n Number of 8 bit 1 byte data for which the CRC value is generated or the device number storing the numb...

Page 685: ...4H 41E4H High order byte High order bits of D0 41H 8 bit conversion mode while SM8161 is ON In this mode the operation is executed only for low order 8 bits low order 1 byte of a device specified by s With regard to the operation result low order 8 bits 1 byte are stored to a device specified by d and high order 8 bits 1 byte are stored to a device specified by d 1 In the following program convers...

Page 686: ... Descriptions ranges and data types Applicable devices 1 T ST C cannot be used Ladder diagram Structured text ENO ADRSET EN s d ENO ADRSETP EN s d FBD LD Operand Description Range Data type Data type label s Device number for reading the indirect address Device name ANY_ELEMENTARY d Device number for storing the indirect address of the device specified by s 32 bit signed binary ANY32 EN Execution ...

Page 687: ...insufficient In the indirect specification the device which specify the address of the specified device is specified by word device number For example when D100 is specified and the content of D101 and D100 becomes the device address Operation error There is no operation error 1 Stores the address of W100 to D100 and D101 2 Specifies the content of D100 and D101 address of W100 3 Writes 1234 to W1...

Page 688: ...nd Description Range Data type Data type label d Head device number where the read clock data is stored 16 bit signed binary ANY16_ARRAY Number of elements 7 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW R U G Z LC LZ K H E d Device Item Clock data Device Item Special registers ...

Page 689: ... SD215 Binary clock data second The second data in the clock data is stored as a binary code SD216 Binary clock data day of the week The day of a week data in the clock data 0 Sunday 1 Monday 6 Saturday is stored as a binary code Binary code FX3 compatible area SD8013 Binary clock data second The second data in the clock data is stored as a binary code SD8014 Binary clock data minute The minute da...

Page 690: ...of range are set to the write source area the clock data will not be updated In this case correct the clock data in the write source area and execute the instruction Day of the week SD216 and SD8019 is automatically corrected Ladder diagram Structured text ENO TWR EN s ENO TWRP EN s FBD LD Operand Description Range Data type Data type label s Head device number where the clock write source data is...

Page 691: ...ata is stored as a binary code SD215 Binary clock data second The second data in the clock data is stored as a binary code SD216 Binary clock data day of the week The day of a week data in the clock data 0 Sunday 1 Monday 6 Saturday is stored as a binary code Binary code FX3 compatible area SD8013 Binary clock data second The second data in the clock data is stored as a binary code SD8014 Binary c...

Page 692: ...2 d ENO TADDP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Head device number where the clock data to be added is stored 16 bit signed binary ANY16_ARRAY Number of elements 3 s2 Head device number where the adding time value or clock data value is stored 16 bit signed binary ANY16_ARRAY Number of elements 3 d Head device number where the resultant clock data or time val...

Page 693: ... the time value hour minute second of the built in real time clock in the CPU module for the operation use the TRD P operation to read the special register values first Then specify the word devices where the read values are stored to each operand Operation error Device Name Description SM700 Carry If the result exceeds the maximum value of the time data 23 59 59 this special relay turns on SM8020...

Page 694: ...SUBP EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Head device number where the clock data that is subtracted is stored 16 bit signed binary ANY16_ARRAY Number of elements 3 s2 Head device number where the subtracting time value or clock data value is stored 16 bit signed binary ANY16_ARRAY Number of elements 3 d Head device number where the resultant clock data or time ...

Page 695: ... When using the time value hour minute second of the built in real time clock in the CPU module for the operation use the TRD P operation to read the special register values first Then specify the word devices where the read values are stored to each operand Operation error Device Name Description SM8020 Zero If the result is 0 00 00 this special relay turns on SM8021 Borrow If the execution resul...

Page 696: ...converted data in the device numbers starting from d Ex When specifying 4 hours 29 minutes 31 seconds in s Ladder diagram Structured text ENO HTOS EN s d ENO HTOSP EN s d FBD LD Operand Description Range Data type Data type label s Head device number where the clock data before conversion is stored 16 bit signed binary ANY16_ARRAY Number of elements 3 d Head device number where the clock data afte...

Page 697: ...ion 2820H Any of the device area ranges specified in s and d exceed the corresponding device range 3403H The result is outside the following range 0 to 32767 3405H A value specified by s is outside the following range 0 to 9 Any of values specified by s 1 and s 2 is outside the following range 0 to 59 ...

Page 698: ...d data in the device numbers starting from d Ex When specifying 35 hours 10 minutes 58 seconds in s Ladder diagram Structured text ENO DHTOS EN s d ENO DHTOSP EN s d FBD LD Operand Description Range Data type Data type label s Head device number where the clock data before conversion is stored 16 bit signed binary ANY16_ARRAY Number of elements 3 d Head device number where the clock data after con...

Page 699: ...ror code SD0 SD8067 Description 2820H Any of the device area ranges specified in s and d exceed the corresponding device range 3405H A value specified by s is outside the following range 0 to 32767 Any of values specified by s 1 and s 2 is outside the following range 0 to 59 ...

Page 700: ...mat and store the converted data in the device numbers starting from d Ex When specifying 29011 seconds in s Ladder diagram Structured text ENO STOH EN s d ENO STOHP EN s d FBD LD Operand Description Range Data type Data type label s Head device number where the clock data before conversion is stored 16 bit signed binary ANY16 d Head device number where the clock data after conversion is stored 16...

Page 701: ... INSTRUCTION 8 24 Clock Instruction 699 8 Operation error Error code SD0 SD8067 Description 2820H The specified device area exceeds the corresponding device range 3405H The value specified by s is outside the range ...

Page 702: ...tore the converted data in the device numbers starting from d Ex When specifying 45325 seconds in s Ladder diagram Structured text ENO DSTOH EN s d ENO DSTOHP EN s d FBD LD Operand Description Range Data type Data type label s Head device number where the clock data before conversion is stored 32 bit signed binary ANY32 d Head device number where the clock data after conversion is stored 16 bit si...

Page 703: ... INSTRUCTION 8 24 Clock Instruction 701 8 Operation error Error code SD0 SD8067 Description 2820H The specified device area exceeds the corresponding device range 3405H The value specified by s is outside the range ...

Page 704: ... ENO ORDT_ EN s1 s2 s3 EQ NE GT LE LT GE enters 2 FBD LD _EQ _NE _GT _LE _LT _GE enters 2 Operand Description Range Data type Data type label s1 Head device number where the comparison data is stored 16 bit signed binary ANY_DT s2 Head device number where the comparison data is stored 16 bit signed binary ANY_DT s3 Comparison target setting value or the number of comparison target data 0001H to 00...

Page 705: ...ditions set by s3 Devices are used as a normally open contact The date data in the device specified by s2 is regarded as dummy data and ignored 1 Set day as comparison target 2 Set month as comparison target 3 Set year as comparison target 4 Set 0 If a value other than 0 is set the operation result will be non continuity 5 When 1 is set to the 15 bit the data in the device specified by s1 is compa...

Page 706: ...ta are compared under the same conditions the results differ depending on the comparison target data Even though the specified date does not exist the comparison operation is performed in accordance with the conditions in the following table as long as the date data are within the valid range Operation error There is no operation error Instruction symbol Condition Result Instruction symbol Conditi...

Page 707: ...3 ENO ORTM_ EN s1 s2 s3 EQ NE GT LE LT GE enters 2 FBD LD _EQ _NE _GT _LE _LT _GE enters 2 Operand Description Range Data type Data type label s1 Head device number where the comparison data is stored 16 bit signed binary ANY_TM s2 Head device number where the comparison data is stored 16 bit signed binary ANY_TM s3 Comparison target setting value or the number of comparison target data 0001H to 0...

Page 708: ...Devices are used as a normally open contact The time data in the device specified by s2 is regarded as dummy data and ignored 1 Set second as comparison target 2 Set minute as comparison target 3 Set hour as comparison target 4 Set 0 If a value other than 0 is set the operation result will be non continuity 5 When 1 is set to the 15 bit the data in the device specified by s1 is compared with the c...

Page 709: ...on results of each instruction Ex The time data A B and C are compared The following table lists the comparison operation results between A B and C Even when the data are compared under the same conditions the results differ depending on the comparison target data Operation error There is no operation error Instruction symbol Condition Result Instruction symbol Condition Result TM s1 s2 Conductive...

Page 710: ... hour of the time comparison 0 to 23 16 bit signed binary ANY16 s2 Specify the minute of the time comparison 0 to 59 16 bit signed binary ANY16 s3 Specify the second of the time comparison 0 to 59 16 bit signed binary ANY16 s4 Specify the time data hour minute and second 16 bit signed binary ANY16_ARRAY Number of elements 3 d Specify the Bit device that turns on off depending on the comparison res...

Page 711: ...f the special register used in the TRD P instruction when the time hour minute second of the clock data of the built in real time clock in the CPU module is used Operation error Error code SD0 SD8067 Description 2820H The device range specified exceeds the corresponding device range 3405H The value specified by s1 and s4 is outside the following range 0 to 23 The value specified by s2 s3 s4 1 and ...

Page 712: ...label s1 Specify the lower limit of time comparison hour minute and second 16 bit signed binary ANY16_ARRAY Number of elements 3 s2 Specify the upper limit of time comparison hour minute and second 16 bit signed binary ANY16_ARRAY Number of elements 3 s3 Specify the time data hour minute and second 16 bit signed binary ANY16_ARRAY Number of elements 3 d Specify the Bit device that turns on off dep...

Page 713: ...CPU module is used read the values of special registers by the TRD instruction and then specify those word devices as the operands Make s1 s2 Operation error Error code SD0 SD8067 Description 2820H The device range specified exceeds the corresponding device range 3405H The value specified by s1 s2 and s3 is outside the following range 0 to 23 The value specified by s1 1 s2 1 s3 1 s1 2 s2 2 and s3 ...

Page 714: ...M424 SM8330 to SM8334 in the special relay of the timing clock output destination specified by d In SM420 to SM424 SM8330 to SM8334 when one device is turned on another device is also turned on at the same time Ladder diagram Structured text ENO DUTY EN n1 n2 d FBD LD Operand Description Range Data type Data type label n1 Number of scans to be turned on 0 to 32767 16 bit unsigned binary ANY16 n2 N...

Page 715: ...D8330 SM421 SM8331 SD8331 SM422 SM8332 SD8332 SM423 SM8333 SD8333 SM424 SM8334 SD8334 Status of n1 and n2 ON OFF status of d n1 0 n2 0 d Fixed to OFF n1 0 n2 0 d Fixed to ON Special relay Name Description SM420 SM8330 Timing clock output 1 Timing clock output in the DUTY instruction SM421 SM8331 Timing clock output 2 SM422 SM8332 Timing clock output 3 SM423 SM8333 Timing clock output 4 SM424 SM833...

Page 716: ...ata type register is used the current value data is cleared when the power to the CPU module is turned OFF or when the controller mode switches from STOP to RUN Even after the alarm output specified by d2 turns ON the measurement is continued When the current value reaches the maximum value of 16 bit data the measurement is stopped For continuing the measurement clear the current value stored in d...

Page 717: ...ION INSTRUCTION 8 25 Timing Check Instruction 715 8 Operation error Error code SD0 SD8067 Description 2820H The device areas specified by d1 exceed the corresponding device range 3405H The value of s is negative ...

Page 718: ...turns off If a general data type register is used the current value data is cleared when the power to the CPU module is turned OFF or when the controller mode switches from STOP to RUN Even after the alarm output specified by d2 turns ON the measurement is continued When the current value reaches the maximum value of 32 bit data the measurement is stopped For continuing the measurement clear the c...

Page 719: ...ION INSTRUCTION 8 25 Timing Check Instruction 717 8 Operation error Error code SD0 SD8067 Description 2820H The device areas specified by d1 exceed the corresponding device range 3405H The value of s is negative ...

Page 720: ...ime only after the END instruction is executed in the program a pulse signal cannot be output externally in the middle of a scan The execution of the I O refresh instruction forcibly refreshes the corresponding input X or output Y in the middle of program execution and then a pulse signal can be output externally in the middle of a scan Ladder diagram Structured text ENO REF EN s n ENO REFP EN s n...

Page 721: ...access output DY Ex When a program using the RFS instruction is changed to a program using direct access input output Operation error 1 Refreshes X0 2 Refreshes Y20 Error code SD0 SD8067 Description 2820H The n points of device range starting from the device specified by s exceed the range of proximal I O X0 DX0 REF X0 K1 REF Y20 K1 Y20 DY20 Command Command 1 2 ...

Page 722: ... UnHn Applicable devices 1 Only the DFROM P instruction can be used Ladder diagram Structured text ENO FROM EN UnHn s n d ENO FROMP EN UnHn s n d ENO DFROM EN UnHn s n d ENO DFROMP EN UnHn s n d FBD LD Operand Description Range Data type Data type label U H 1 Unit number H1 to H10 16 bit unsigned binary ANY16 s Start address of the buffer memory where the read target data is stored 0 to 65535 16 b...

Page 723: ...intelligent function module No 1 to D0 Operation error Error code SD0 SD8067 Description 2441H Updating procedure with the unit was not properly completed during the execution of the instruction 2801H The unit number specified by U H does not exist 2823H The buffer memory number specified by s exceeds the buffer memory area The buffer memory number specified by s the number of transfer points spec...

Page 724: ... the purpose of control of each Intelligent function module and the setting range is from K0 to K65535 The number of read data is specified by n and the setting range is from K1 to K65535 If this instruction is executed in an interrupt program with the priority 1 operation error 3580H occurs This instruction operates in an interrupt program with the priority 2 or 3 If this instruction is executed ...

Page 725: ... UnHn Applicable devices 1 Only the DTO P instruction can be used Ladder diagram Structured text ENO TO EN UnHn s1 s2 n ENO TOP EN UnHn s1 s2 n ENO DTO EN UnHn s1 s2 n ENO DTOP EN UnHn s1 s2 n FBD LD Operand Description Range Data type Data type label U H 1 Unit number H1 to H10 16 bit unsigned binary ANY16 s1 Start address of the buffer memory for writing the data 0 to 65535 16 bit unsigned binar...

Page 726: ...dress DTO P These instructions write the n 2 points of data in the device starting from the one specified by s2 to the buffer memory address specified by s1 in intelligent function module specified by U H When a constant is specified in s2 n x 2 words of the same data the value specified by s2 is written starting from the specified buffer memory address s2 s1 CPU module Buffer memory n points n wo...

Page 727: ...tion of the instruction 2801H The unit number specified by U H does not exist 2823H The buffer memory number specified by s1 exceeds the buffer memory area The buffer memory number specified by s1 the number of transfer points specified by n exceeds the buffer memory area 2820H The device number specified by s2 the number of write data specified by n exceeds the corresponding device range 3056H Ti...

Page 728: ...n Applicable devices 1 Only the DFROMD P instruction can be used Ladder diagram Structured text ENO FROMD EN UnHn s n d ENO FROMDP EN UnHn s n d ENO DFROMD EN UnHn s n d ENO DFROMDP EN UnHn s n d FBD LD Operand Description Range Data type Data type label U H 1 Unit number H1 to H10 16 bit unsigned binary ANY16 s Start address of the buffer memory where the read target data is stored 0 to 429496729...

Page 729: ...iption 2441H Updating procedure with the unit was not properly completed during the execution of the instruction 2801H The unit number specified by U H does not exist 2823H The buffer memory number specified by s exceeds the buffer memory area The buffer memory number specified by s the number of transfer points specified by n exceeds the buffer memory area 2820H The device number specified by d t...

Page 730: ...the purpose of control of each intelligent function module and the setting range is from K0 to K4294967295 The number of read data is specified by n and the setting range is from K1 to K65535 If this instruction is executed in an interrupt program with the priority 1 operation error 3580H occurs This instruction operates in an interrupt program with the priority 2 or 3 If this instruction is execu...

Page 731: ...ays as UnHn Applicable devices 1 Only the DTOD P instruction can be used Ladder diagram Structured text ENO TOD EN UnHn s1 s2 n ENO TODP EN UnHn s1 s2 n ENO DTOD EN UnHn s1 s2 n ENO DTODP EN UnHn s1 s2 n FBD LD Operand Description Range Data type Data type label U H 1 Unit number H1 to H10 16 bit unsigned binary ANY16 s1 Start address of the buffer memory for writing the data 0 to 4294967295 32 bi...

Page 732: ...ddress DTOD P These instructions write the n 2 points of data in the device starting from the one specified by s2 to the buffer memory address specified by s1 in intelligent function module specified by U H When a constant is specified in s2 n 2 words of the same data the value specified by s2 is written starting from the specified buffer memory address s2 s1 CPU module Buffer memory n points n wo...

Page 733: ... exist 2823H The buffer memory number specified by s1 exceeds the buffer memory area The buffer memory number specified by s1 the number of transfer points specified by n exceeds the buffer memory area 2820H The device number specified by s2 the number of write data specified by n exceeds the corresponding device range 3056H Timeout occurred while communicating with the connected units during the ...

Page 734: ...G instruction is executed no processing is performed in the following cases Operation error Ladder diagram Structured text ENO LOGTRG EN s FBD LD Operand Description Range Data type Data type label s Logging setting number 1 to 4 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F ...

Page 735: ...logging trigger and after logging trigger with the logging setting number in the device specified by s Precautions When the LOGTRGR instruction is executed after the LOGTRG instruction is executed in the same scan the LOGTRG instruction becomes invalid Operation error Ladder diagram Structured text ENO LOGTRGR EN s FBD LD Operand Description Range Data type Data type label s Logging setting number...

Page 736: ...n The data missing occurs In the following case even if the RTM instruction is executed the procession is not performed Operation error There is no operation error Ladder diagram Structured text ENO RTM EN FBD LD Device Name Description SD1484 Real time monitor internal buffer free space The amount of free space of the internal buffer is stored in K bytes When the collection timing of the real tim...

Page 737: ...ing process is stopped when the program execution proceeds to the next process a machine can be controlled using simple sequences for each process The step relay number specified by STL instruction is assigned to the State The start and completion of the State use SET instruction RST instruction and ZRST instruction Program a step ladder program starting from the initial state relay in the order o...

Page 738: ...etween state relays is satisfied the next state relay turns ON and the state relay which was been ON before hand turns OFF transfer operation In the state relay ON status transfer process both state relays are ON for one operation cycle In the next operation cycle after the ON status is transferred to the next state relay the former state relay is reset to OFF A drive instruction connected to the ...

Page 739: ... latched step relay clears at power supply ON OFF or RUN STOP If the State is valid and power supply ON OFF or PLC RUN STOP operation can not be restarted from the last point before power supply ON OFF or RUN STOP Operation error There is no operation error Device Name Remarks SM8040 STL transfer disable When SM8040 is set to ON transfer of the ON status is disabled among all state relays SM8046 S...

Page 740: ... type Data type label U 1 Dummy Input the character string U0 Character string ANYSTRING_SINGLE s1 Connection number 1 to 8 16 bit unsigned binary ANY16 s2 Head device number for storing the control data Refer to Control data Page 739 Word ANY16_ARRAY Number of elements 10 d Head device number which turns ON when the execution of the instruction is completed and remains ON for 1 scan If the instru...

Page 741: ...e open processing is performed with the set values of the control data s2 2 to s2 9 0000H 8000H User s2 1 Completion status The status at the completion of the instruction is stored 0000H Completed successfully Other than 0000H Completed with an error error code For error codes refer to MELSEC iQ F FX5 User s Manual Ethernet Communication System s2 2 Application setting area 1 Communication method...

Page 742: ...ontents of the open processing in s2 2 to s2 9 For details refer to MELSEC iQ F FX5 User s Manual Ethernet Communication Operation error Status Description When completed normally The device does not change remains OFF When completed with an error The device turns ON during the END processing for the scan in which the SP SOCOPEN instruction is completed and turns OFF during the next END processing...

Page 743: ...6 s2 Head device number for storing the control data Refer to Control data Page 741 Word ANY16_ARRAY Number of elements 2 d Head device number which turns on when the execution of the instruction is completed and remains on for 1 scan If the instruction is completed with an error d 1 is also turned on Bit ANYBIT_ARRAY Number of elements 2 EN Execution condition Bit BOOL ENO Execution result Bit BO...

Page 744: ...mpletion signal and open request signal of the corresponding connection turn OFF and close processing is executed the communication is disabled Status Description When completed normally The device does not change remains OFF When completed with an error The device turns ON during the END processing for the scan in which the SP SOCCLOSE instruction is completed and turns OFF during the next END pr...

Page 745: ...el U 1 Dummy Input the character string U0 Character string ANYSTRING_SINGLE s1 Connection number 1 to 8 16 bit unsigned binary ANY16 s2 Head device number for specifying the control data Refer to Control data Page 744 Word ANY16_ARRAY Number of elements 2 d1 Head device number for storing the receive data Word ANY16 d2 Head device number which turns ON when the execution of the instruction is com...

Page 746: ...sing Completion device d2 1 Turns ON or OFF depending on the status when the SP SOCRCV instruction is completed Device Item Description Setting range Set by 1 s2 0 System area s2 1 Completion status The status at the completion of the instruction is stored 0000H Completed successfully Other than 0000H Completed with an error error code For error codes refer to MELSEC iQ F FX5 User s Manual Etherne...

Page 747: ...e data storage device The device number specified by s2 d1 or d2 is outside the range of the number of device points 2822H Device that cannot be specified is specified 3582H When an instruction which cannot be used in interruption routine program is used Sequence program END processing END processing END processing When failed SP SOCRCV instruction ON OFF ON OFF ON OFF 1 scan END processing Execut...

Page 748: ...NYSTRING_SINGLE s1 Connection number 1 to 8 16 bit unsigned binary ANY16 s2 Head device number for specifying the control data Refer to Control data Page 747 Word ANY16_ARRAY Number of elements 2 s3 Head device number for storing the send data Word ANY16 d Head device number which turns ON when the execution of the instruction is completed and remains on for 1 scan If the instruction is completed ...

Page 749: ...completed and turns OFF during the next END processing Completion device d 1 Turns ON or OFF depending on the status when the SP SOCSND instruction is completed Device Item Description Setting range Set by 1 s2 0 System area s2 1 Completion status The status at the completion of the instruction is stored 0000H Completed successfully Other than 0000H Completed with an error error code For error cod...

Page 750: ...ified by s2 s3 or d is outside the range of the number of device points 2822H Device that cannot be specified is specified 3582H When an instruction which cannot be used in interruption routine program is used Sequence program END processing END processing When failed SP SOCSND instruction Completion device d 0 Completion device d 1 Execute SP SOCSND instruction ON OFF ON OFF ON OFF 1 scan Sending...

Page 751: ...nd Description Range Data type Data type label U 1 Dummy Input the character string U0 Character string ANYSTRING_SINGLE s1 Connection number 1 to 8 16 bit unsigned binary ANY16 s2 Head device number for storing the control data Refer to Control data Page 750 Word ANY16_ARRAY Number of elements 2 d Head device number for storing the connection information Word ANY16_ARRAY Number of elements 5 EN E...

Page 752: ...s at the completion of the instruction is stored 0000H Completed successfully Other than 0000H Completed with an error error code For error codes refer to MELSEC iQ F FX5 User s Manual Ethernet Communication System d 0 d 1 Target device IP address The IP address of the target device is stored 1 to 3758096382 00000001H to DFFFFFFEH 2 System d 2 Target device port number The port number of the targe...

Page 753: ...racter string ANYSTRING_SINGLE s1 Connection number 1 to 8 16 bit unsigned binary ANY16 s2 Head device number for storing the control data Refer to Control data Page 751 Word ANY16_ARRAY Number of elements 2 d Head device number for storing the read data Word ANY16 n Number of the read data 1 to 1024 words 1 to 1024 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bi...

Page 754: ...struction is executed For details refer to MELSEC iQ F FX5 User s Manual Ethernet Communication Precautions Even when the S P SOCRDATA instructions are executed the socket communication receive data area is not cleared and the receiving status signal does not change Therefore the next receive data is not stored in the socket communication receive data area To update receive data use the SP SOCRCV ...

Page 755: ...be executed continuously 1 to 8 16 bit unsigned binary ANY16 s3 Head device number for storing the control data Refer to Control data Page 753 Word ANY16_ARRAY Number of elements 18 d Head device number which turns ON when the execution of the instruction is completed and remains on for 1 scan If the instruction is completed with an error d 1 is also turned on Bit ANYBIT_ARRAY Number of elements 2...

Page 756: ...ceive packet number successful in collation match is stored If the communication type is receive only 0 is stored If an error occurs during execution of the third protocol 0 is stored If the number of protocols executed is less than 3 0 is stored 0 1 to 16 s3 13 Collation match Receive packet number 4 If receiving is included in the communication type of the protocol that has been executed fourth ...

Page 757: ...cuted are only those for which Communication protocol is specified for the communication means If a cancel request is received during execution of the mth protocol while multiple protocols are executed continuously the following is stored in s3 If same instructions are executed for the same connection the subsequent instruction is ignored and is not executed until the preceding instruction is comp...

Page 758: ...l Support Function Instruction Operation error Error code SD0 SD8067 Description 2820H The device used exceeded the specified range 2821H The device used to store data are overlapping 2822H Device that cannot be specified is specified 3405H The input data was out of range ...

Page 759: ...MPSND enters Operand Description Range Data type Data type label U 1 Dummy String ANYSTRING_SINGLE s1 Head device where control data is stored Page 758 Control data Word ANY16_ARRAY Number of elements 19 s2 Head device where request frame is stored Page 759 Request frame Word ANY16_ARRAY 2 d1 Head device for storing response frame Page 759 Response frame Word ANY16_ARRAY 2 d2 Head device that turn...

Page 760: ...e octets of the IP address User s1 5 Destination port number Specify the destination port number 1 to 65534 1 to FFFEH User s1 6 Request destination network number 0000H fixed 0000H User s1 7 Request destination station number 00FFH fixed 00FFH User s1 8 Request destination module I O number Specify request destination module I O number 03D0H Addressed to control system CPU 03D1H Addressed to stan...

Page 761: ... the IP address System s1 18 IP address of error detected device first and second octets The IP address first and second octets of the station where an error was detected is stored 1 2 Indicates the octets of the IP address System Error completion type The 7th bit of s1 0 Completion status s1 1 Clock setting flag s1 12 Clock data s1 13 to 16 IP address of error detected device s1 17 18 0 Do not se...

Page 762: ... off depending on the completion status of the SP SLMPSND instruction Status Description When completed successfully The device remains off When completed with an error The device turns on during the END processing of the scan where the SP SLMPSND instruction completes and turns off during the next END processing Request destination module I O No Header Footer Subheader Request destination station...

Page 763: ...e corrective action Operation error Upon completion with an error the completion status indication device d2 1 is turned on and an error code is stored in the completion status s1 1 For the error code stored in the completion status s1 1 refer to the following MELSEC iQ F FX5 User s Manual Ethernet Communication 1 Request message 2 Processing request from target device to request destination 3 Pro...

Page 764: ...ng time s3 For details refer to the MELSEC iQ F FX5 User s Manual Application Ladder diagram Structured text ENO PID EN s1 s2 s3 d FBD LD Operand Description Range Data type Data type label s1 Device number storing the target value SV 32768 to 32767 16 bit signed binary ANY16 1 s2 Device number storing the measured value PV 32768 to 32767 16 bit signed binary ANY16 1 s3 Device number storing a par...

Page 765: ...structions can be executed at the same time There is no limitation in the number of loops However make sure that s3 d and other operands specified in each instruction are different to each other For the output value MV in the PID instruction specify an unlatched data register If specifying a latched data register make sure to clear the backup contents when the PLC mode is set to RUN using the foll...

Page 766: ...32767 3512H PID output upper limit set value PID output lower limit set value 3513H Abnormal PID input variation alarm set value or output variation alarm set value Set value 0 3514H Step response method Improper auto tuning result 3515H Step response method Auto tuning operation direction mismatch 3516H Step response method Improper auto tuning operation 3517H Limit cycle method Abnormal output s...

Page 767: ...onsists of the following chapters 12 NETWORK COMMON INSTRUCTION 13 CC LINK IE FIELD NETWORK INSTRUCTION 14 HIGH SPEED COUNTER INSTRUCTION 15 EXTERNAL DEVICE COMMUNICATION INSTRUCTION 16 POSITIONING INSTRUCTION 17 DIVIDED DATA READ WRITE FROM TO BFM INSTRUCTION ...

Page 768: ...work interface board MELSECNET H interface board and MELSECNET 10 interface board Instruction symbol Target station another station Target network Target station type GP READ GP SREAD Ethernet CC Link IE Controller Network CC Link IE Field Network MELSECNET H MELSECNET 10 QCPU LCPU QSCPU QnACPU FX5CPU Intelligent device station GP WRITE GP SWRITE Ethernet CC Link IE Controller Network CC Link IE F...

Page 769: ...ction specifying bit devices by nibble can be executed only when the target station is FX5CPU RCPU basic model QCPU universal model QCPU or LCPU If an instruction uses nibble specification for other types of CPU modules an abnormal response is returned from the target station and the instruction is completed with an error The network module does not detect an error during execution of the instruct...

Page 770: ...ram Structured text ENO GP_READ EN Un s1 s2 d1 d2 FBD LD GP_READ enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s1 Own station head device where control data is stored Refer to Page 769 Control data Device name ANY16 s2 Target station head device where the data to be read is stored Character string 2 ANY...

Page 771: ...ion Specify the number of resends to be performed if the instruction is not completed within the monitoring time specified by s1 8 At completion of instruction The number of resends performed result is stored 0 to 15 User system s1 8 Arrival monitoring time Specify the monitoring time until completion of processing If processing is not completed within the monitoring time the request is resent by ...

Page 772: ... link dedicated instructions specifying the same channel cannot be used concurrently The execution of the GP READ instruction and whether it has been completed normally or completed with an error can be checked with the completion device d2 or completion status indication device d2 1 Device Operation Completion device d2 The device turns on during the END processing for the scan in which the GP RE...

Page 773: ...ND 0 OFF OFF OFF OFF ON ON OFF READ FX5 CCLIEF Sequence scan Start contact CPU module on the own station Network module Completion device d2 Completion status indication device d2 1 Read data storage device d1 Sequence scan Read data storage device s2 Channel 1 1 scan CPU module on the target station END 0 END 0 END 0 END 0 END 0 OFF OFF OFF OFF OFF ON ON ON OFF READ FX5 CCLIEF 1 scan Error code S...

Page 774: ...is required Ladder diagram Structured text ENO GP_SREAD EN Un s1 s2 d1 d2 d3 FBD LD GP_SREAD enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s1 Own station head device where control data is stored Refer to Page 773 Control data Device name ANY16 s2 Target station head device where the data to be read is s...

Page 775: ...iple CPU No 4 03FFH Addressed to target station CPU control CPU 0000H 03D0H to 03D3H 03E0H to 03E3H 03FFH User s1 4 Target network number Specify the network number 1 to 239 of the target station 1 to 239 User s1 5 Target station number Specify the station number of the target station 125 Master station 126 Master operating station 1 to 120 Local station intelligent device station submaster statio...

Page 776: ...s indication device d2 1 s1 12 Clock data Set only in an abnormal state Upper 8 bits Month 01H to 12H Lower 8 bits Lower 2 digits of year 00H to 99H System s1 13 Upper 8 bits Hour 00H to 23H Lower 8 bits Day 01H to 31H System s1 14 Upper 8 bits Second 00H to 59H Lower 8 bits Minute 00H to 59H System s1 15 Upper 8 bits Upper 2 digits of the year 00H to 99H Lower 8 bits Day of the week 00H Sun to 06...

Page 777: ...ON OFF OFF ON OFF SREAD FX5 CCLIEF Sequence scan Start contact CPU module on the own station CPU module on the target station Network module Completion device d2 Completion status indication device d2 1 Read data storage device d1 Sequence scan Read data storage device s2 Channel 1 1 scan Read notification device d3 1 scan END 0 END 0 END 0 END 0 END 0 OFF OFF OFF OFF OFF ON ON ON OFF SREAD FX5 CC...

Page 778: ...ENO GP_WRITE EN Un s1 s2 d1 d2 FBD LD GP_WRITE enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s1 Own station head device where control data is stored Refer to Page 777 Control data Device name ANY16 s2 Own station head device where the data to be written is stored Device name ANY16 d1 Target station head...

Page 779: ...status The instruction completion status is stored 0 Normal Other than 0 Error error code System s1 2 Own station channel Specify the channel to be used by own station 1 2 User s1 3 Target station CPU type Specify the CPU type of the target station 0000H Addressed to target station CPU control CPU 03D0H Addressed to control system CPU 03D1H Addressed to standby system CPU 03D2H Addressed to system...

Page 780: ...fective when the execution type specified by s1 0 is 1 Arrival acknowledgment used Specify the monitoring time until completion of processing If processing is not completed within the monitoring time the request is resent by the number of resends specified in s1 7 0 10 seconds 1 to 32767 1 to 32767 seconds 0 to 32767 User s1 9 Write data length Specify the number of words to be written 1 to 960 wo...

Page 781: ...Specify the target stations in control data s1 4 and s1 5 Upon completion of writing device data to target station the completion device specified by d2 turns on For the target stations that can be specified refer to the following Page 766 Target networks and target station types When executing multiple link dedicated instructions concurrently be careful not to overlap the channels of the link ded...

Page 782: ...FF OFF ON ON OFF 3000 WRITE 3000 END 0 END 0 END 0 END 0 END 0 FX5 CCLIEF Channel 1 1 scan Sequence scan Start contact CPU module on the own station CPU module on the target station Network module Completion device d2 Completion status indication device d2 1 Write data storage device s2 Sequence scan Write data storage device d1 3000 END 0 END 0 END 0 END 0 END 0 OFF OFF OFF OFF OFF ON ON ON OFF W...

Page 783: ...s1 s2 d1 d2 d3 FBD LD GP_SWRITE enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s1 Own station head device where control data is stored Refer to Page 782 Control data Device name ANY16 s2 Own station head device where the data to be written is stored Device name ANY16 d1 Target station head device where d...

Page 784: ...tatus is stored 0 Normal Other than 0 Error error code System s1 2 Own station channel Specify the channel to be used by own station 1 2 User s1 3 Target station CPU type Specify the CPU type of the target station 0000H Addressed to target station CPU control CPU 03D0H Addressed to control system CPU 03D1H Addressed to standby system CPU 03D2H Addressed to system A CPU 03D3H Addressed to system B ...

Page 785: ...ffective when the execution type specified by s1 0 is 1 Arrival acknowledgment used Specify the monitoring time until completion of processing If processing is not completed within the monitoring time the request is resent by the number of resends specified in s1 7 0 10 seconds 1 to 32767 1 to 32767 seconds 0 to 32767 User s1 9 Write data length Specify the number of words to be written 1 to 960 w...

Page 786: ...n completion of writing device data to target station the completion device specified by d2 turns on In the other station upon completion of writing the device data specified by s2 the device specified by d3 turns on For the target stations that can be specified refer to the following Page 766 Target networks and target station types When executing multiple link dedicated instructions concurrently...

Page 787: ...5 CCLIEF Channel 1 1 scan Sequence scan Start contact CPU module on the own station CPU module on the target station Network module Completion device d2 Completion status indication device d2 1 Write data storage device s2 Sequence scan Write data storage device d1 Write notification device d3 1 scan 3000 END 0 END 0 END 0 END 0 END 0 OFF OFF OFF OFF OFF ON ON ON OFF SWRITE FX5 CCLIEF 1 scan Error...

Page 788: ...786 12 NETWORK COMMON INSTRUCTION 12 1 Link Dedicated Instructions Operation error Error code s1 1 Description D000H to DFFFH Refer to MELSEC iQ F FX5 User s Manual CC Link IE ...

Page 789: ...enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s1 Own station head device where control data is stored Refer to Page 788 Control data Device name ANY16 s2 Own station head device where sending data is stored 2 Device name ANY16 d Own station device to be turned on for one scan when the instruction comple...

Page 790: ...used by own station 1 2 User s1 3 Target station storage channel Specify the channel of the target station for storing data 1 to 8 User s1 4 Target network number Specify the network number of the target station 1 to 239 Network number 1 to 239 User s1 5 Target station number Specify the station number of the target station 1 Station number specification 125 Master station 126 Master operating sta...

Page 791: ...the number of sending data from s2 to s2 n 1 to 960 words When sending data to QnACPU 1 to 480 words 1 to 960 User s1 10 Not used s1 11 Clock set flag The validity status valid or invalid of the data in s1 12 and later is stored Note that the data in s1 12 and later is not cleared even when the instruction is completed successfully 0 Invalid 1 Valid System s1 12 Clock data Set only in an abnormal ...

Page 792: ... timeout results in the sending station if the instructions are executed for the same station from multiple stations With the execution type set to Arrival acknowledgment used if the sending station sends data to the same channel in the receiving station before the receiving station reads data using the GP RECV instruction a buffer full error results in the sending station When multiple network mo...

Page 793: ...ructions concurrently be careful not to overlap the channels of the link dedicated instructions Multiple link dedicated instructions specifying the same channel cannot be used concurrently The execution of the GP SEND instruction and whether it has been completed normally or completed with an error can be checked with the completion device d or completion status indication device d 1 Device Operat...

Page 794: ... 3000 OFF OFF OFF ON ON OFF FX5 CCLIEF 1 scan With arrival acknowledgment Channel 1 Data transmission Storage notification 1 scan Channel 2 Sequence scan Start contact CPU module on the own station Completion device d Completion status indication device d 1 Send data storage device s2 Network module CPU module on the target station Sequence scan RECV execution request area Completion device d2 Com...

Page 795: ...FFFH Refer to MELSEC iQ F FX5 User s Manual CC Link IE 3000 END 0 END 0 END 0 END 0 END 0 OFF OFF OFF OFF OFF ON ON ON OFF SEND FX5 CCLIEF 1 scan Error code Sequence scan Start contact CPU module on the own station Completion device d Completion status indication device d 1 Send data storage device s2 Channel 1 Completion status s1 1 Data transmission Data transmission Resending data Number of res...

Page 796: ..._RECV EN Un s d1 d2 FBD LD GP_RECV enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s Own station head device where control data is stored Refer to Page 795 Control data Device name ANY16 d1 Own station head device for storing the receive data 2 Device name ANY16 d2 Own station device to be turned on for o...

Page 797: ... Arrival monitoring time Specify the monitoring time until completion of processing The instruction is completed with an error if it fails to complete within the monitoring time 0 10 seconds 1 to 32767 1 to 32767 seconds 0 to 32767 User s 9 Receive data length The number of data received and stored in d1 to d1 n is stored 0 No receive data 1 to 960 Number of words of received data System s 10 Not ...

Page 798: ... careful not to overlap the channels of the link dedicated instructions Multiple link dedicated instructions specifying the same channel cannot be used concurrently The execution of the GP RECV instruction and whether it has been completed normally or completed with an error can be checked with the completion device d2 or completion status indication device d2 1 Name of GP RECV instruction executi...

Page 799: ...execution timing refer to the following the instruction Page 787 GP SEND When completed with an error Error code s 1 Description D000H to DFFFH Refer to MELSEC iQ F FX5 User s Manual CC Link IE OFF OFF OFF OFF OFF ON ON ON RECV END 0 END 0 END 0 END 0 END 0 1 scan Error code Arrival timeout Channel 2 Intelligent device station CPU module on the own station Sequence scan RECV execution request area...

Page 800: ...rs Operand Description Range Data type Data type label U 9 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s1 Own station head device where control data is stored Refer to Page 799 Control data Device name ANY16 s2 Dummy device 2 Device name ANY16 s3 Dummy device 2 Device name ANY16 s4 Dummy device 2 Device name ANY16 d Own station device to be turned on for one scan...

Page 801: ... for CPU STOP bit 9 0 Held 1 Cleared 3 Output setting for CPU error bit 12 0 Cleared 1 Held Shown on left side User Device Operation Completion device d The device turns on during the END processing for the scan in which the G P CCPASET instruction is completed and turns off during the next END processing Completion status indication device d 1 The device turns on or off depending on the completio...

Page 802: ... Manual CC Link IE END 0 END 0 END 0 END 0 END 0 OFF OFF OFF OFF ON ON OFF CCPASET FX5 CCLIEF Sequence scan Start contact CPU module on the own station Completion device d Completion status indication device d 1 Parameter setting 1 scan END 0 END 0 END 0 END 0 END 0 OFF OFF OFF OFF OFF ON ON ON OFF CCPASET FX5 CCLIEF 1 scan Error code Sequence scan Start contact Completion device d Completion stat...

Page 803: ...0H 16 bit unsigned binary ANY16 s Own station head device where control data is stored Refer to Page 801 Control data Device name ANY16 d Own station device to be turned on for one scan when the instruction completes If the instruction is completed with an error d 1 is also turned on Bit ANYBIT_ARRAY Number of elements 2 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Wor...

Page 804: ...completion status of the G P UINI instruction When completed normally The device does not change remains off When completed with an error The device turns on during the END processing for the scan in which the G P UINI instruction is completed and turns off during the next END processing When completed normally When completed with an error UINI FX5 CPU module Setting a station number Intelligent d...

Page 805: ...be executed on the intelligent device station with no station number setting If the station number set by the G P UINI instruction is already used for another station the instruction is completed with an error Set a unique station number Note that such error cannot be detected before data link start e g absence of the master station Operation error Error code s 1 Description D000H to DFFFH Refer t...

Page 806: ...C35 and 55 that is designated as an FX3 compatible high speed counter For FX3 compatible function refer to MELSEC iQ F FX5 User s Manual Application 2 I16 to I23 can be used Ladder diagram Structured text 1 ENO DHSCS EN s1 s2 d ENO DHSCS_I EN s1 s2 Pn FBD LD 1 Operand Description Range Data type Data type label s1 Data to be compared with the current value of a high speed counter or word device nu...

Page 807: ...wn below Precautions The value specified in s2 should only be the channel of high speed counter number 1 to 8 set by the parameter An operation error occurs in the following cases For other precautions refer to MELSEC iQ F FX5 User s Manual Application Operation error A Main routine program B I16 Interrupt Program 1 Start the high speed counter CH1 2 When the current value of the high speed counte...

Page 808: ...rrent value changes from 199 to 200 or from 201 to 200 if the comparison value is K200 the bit device d is reset to OFF regardless of the scan time For details refer to MELSEC iQ F FX5 User s Manual Application Ladder diagram Structured text ENO DHSCR EN s1 s2 d FBD LD Operand Description Range Data type Data type label s1 Data to be compared with the current value of a high speed counter or word ...

Page 809: ...e following cases For other precautions refer to MELSEC iQ F FX5 User s Manual Application Operation error When a channel which is not set by the parameter or a value other than K1 to 8 is specified When an LC device number which is not set by the parameter is specified Error code SD0 SD8067 Description 3405H A channel number outside the range or the LC device is specified 3582H The DHSCR instruct...

Page 810: ...t to ON regardless of the scan time For details refer to MELSEC iQ F FX5 User s Manual Application Ladder diagram Structured text ENO DHSZ EN s1 s2 s3 d FBD LD Operand Description Range Data type Data type label s1 Data to be compared with the current value of a high speed counter or word device number storing data to be compared comparison value 1 2147483648 to 2147483647 32 bit signed binary ANY...

Page 811: ... For other precautions refer to MELSEC iQ F FX5 User s Manual Application Operation error Comparison pattern Current value of CH1 s3 Change of output contact Y Y0 Y1 Y2 s1 s3 1000 s3 ON OFF OFF 999 1000 ON OFF OFF ON OFF 1000 999 OFF ON ON OFF OFF s1 s3 s2 999 1000 ON OFF OFF ON OFF 1000 999 OFF ON ON OFF OFF 1000 s3 2000 OFF ON OFF 2000 2001 OFF ON OFF OFF ON 2001 2000 OFF OFF ON ON OFF s3 s2 200...

Page 812: ...ed binary ANY16 s2 Set the bit of the channel number where the function is started 32768 to 32767 16 bit signed binary ANY16 s3 Set the bit of the channel number where the function is stopped 32768 to 32767 16 bit signed binary ANY16 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specification Constant Others X Y M L SM F B SB S T ST C D W SD SW...

Page 813: ...Set the value to turn on the bit of the high speed comparison table number which is to be started or stopped In the case of the CPU module K20 b0 to b15 can be used In the case of the high speed pulse input output module K21 to K24 b0 to b14 can be used Function number K30 For the multi output high speed comparison table specification of a channel is not required To start the multi output high spe...

Page 814: ...nction specified by the HIOEN instruction Parameter setting K0 High speed counter Channel setting of the high speed counter K10 Pulse density rotation speed measurement Channel setting of the pulse density rotation speed measurement High speed counter K20 High speed comparison table CPU module Output setting of the high speed counter K21 High speed comparison table first high speed pulse input out...

Page 815: ...unction number Page 813 16 bit signed binary ANY16 s2 Set the bit of the channel number where the function is started 2147483648 to 2147483647 32 bit signed binary ANY32 s3 Set the bit of the channel number where the function is stopped 2147483648 to 2147483647 32 bit signed binary ANY32 EN Execution condition Bit BOOL ENO Execution result Bit BOOL Operand Bit Word Double word Indirect specificati...

Page 816: ... the case of the CPU module K20 b0 to b31 can be used In the case of the high speed pulse input output module K21 to K24 b0 to b14 can be used Function number K30 For the multi output high speed comparison table specification of a channel is not required To start the multi output high speed comparison table set 01H in s2 To stop it set 01H in s3 Function numbers K40 and K50 The measuring start and...

Page 817: ... Function specified by the DHIOEN instruction Parameter setting K0 High speed counter Channel setting of the high speed counter K10 Pulse density rotation speed measurement Channel setting of the pulse density rotation speed measurement High speed counter K20 High speed comparison table CPU module Output setting of the high speed counter K21 High speed comparison table first high speed pulse input...

Page 818: ... device supporting high speed transfer When the HCMOV instruction is executed the latest value is acquired such as the current value of a high speed counter and transferred to d When d is a device supporting high speed transfer When the HCMOV instruction is executed value such as the current value of a high speed counter is changed Ladder diagram Structured text ENO HCMOV EN s n d ENO HCMOVP EN s ...

Page 819: ...d counter using the HCMOV instruction while executing the pulse density rotation speed measurement or the SPD instruction If s is SD8099 and the n value is K1 SD8099 is cleared at the timing the instruction is executed after the SD8099 current value is transferred Do not clear the SD8099 current value with an application instruction such as a MOV instruction which is affected by the scan The HCMOV...

Page 820: ...d counter When s is a device supporting high speed transfer When the DHCMOV instruction is executed the latest value is acquired such as the current value of a high speed counter and transferred to d When d is a device supporting high speed transfer When the DHCMOV instruction is executed value such as the current value of a high speed counter is changed Ladder diagram Structured text ENO DHCMOV E...

Page 821: ...ed as follows When a high speed counter SD device current value maximum value minimum value is read out individually only the read SD device will be updated Thus there may be cases when the high speed counter s SD device does not satisfy the relation of minimum value current value maximum value temporarily Refer to the MELSEC iQ F FX5 User s Manual Application for details on the timing that the hi...

Page 822: ...storing the received data and the maximum number of bytes that can be received For details refer to MELSEC iQ F FX5 User s Manual Serial Communication Ladder diagram Structured text ENO RS2 EN s n1 n2 n3 d FBD LD Operand Description Range Data type Data type label s Head device storing send data 16 bit signed binary character string ANY16 n1 Number of bytes of data to be sent 0 to 4096 16 bit unsi...

Page 823: ...riving this instruction Do not change the values of the header and terminator while this instruction is being driven For other precautions refer to MELSEC iQ F FX5 User s Manual Serial Communication Operation error For communication errors refer to MELSEC iQ F FX5 User s Manual Serial Communication Error code SD0 SD8067 Description 3405H Data outside the allowable range was input 2820H The device ...

Page 824: ...cation For the instruction codes refer to the each inverter manual Precautions Three devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls Ladder diagram Structured text ENO IVCK EN s1 s2 n d1 d2 FBD LD Operand Description Range Data type Data type label s1 Inverter station number K0 to 31 16 bit signed binary ANY16 s2 Inverter instruction...

Page 825: ... Serial Communication Error code SD0 SD8067 Description 1810H Channel number specified by d is used by another instruction 2820H The specified device exceeds the range of the corresponding device 3405H The value specified by s1 is other than any of K0 to 31 The value specified by n is other than any of K1 to 4 3600H Channel number specified by d is not set by parameters ...

Page 826: ...on codes refer to the each inverter manual Precautions Three devices are occupied from the device specified in d Make sure that these devices are not used in other controls Ladder diagram Structured text ENO IVDR EN s1 s2 s3 n d FBD LD Operand Description Range Data type Data type label s1 Inverter station number K0 to 31 16 bit signed binary ANY16 s2 Inverter instruction codes 1 16 bit signed bin...

Page 827: ... Serial Communication Error code SD0 SD8067 Description 1810H Channel number specified by d is used by another instruction 2820H The specified device exceeds the range of the corresponding device 3405H The value specified by s1 is other than any of K0 to 31 The value specified by n is other than any of K1 to 4 3600H Channel number specified by d is not set by parameters ...

Page 828: ...al Precautions Three devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls Ladder diagram Structured text ENO IVRD EN s1 s2 n d1 d2 FBD LD Operand Description Range Data type Data type label s1 Inverter station number K0 to 31 16 bit signed binary ANY16 s2 Inverter parameter number 1 16 bit signed binary ANY16 d1 Device number storing the ...

Page 829: ...tion 1810H Channel number specified by d is used by another instruction 2820H The specified device exceeds the range of the corresponding device 3405H The value specified by s1 is other than any of K0 to 31 The value specified by s2 is outside the allowable range Less than K0 K3000 to 9999 or K13000 to 32767 The value specified by n is other than any of K1 to 4 3600H Channel number specified by d ...

Page 830: ...ces are occupied from the device specified in d Make sure that these devices are not used in other controls Ladder diagram Structured text ENO IVWR EN s1 s2 s3 n d FBD LD Operand Description Range Data type Data type label s1 Inverter station number K0 to 31 16 bit signed binary ANY16 s2 Inverter parameter number 1 16 bit signed binary ANY16 s3 Set value to be written to the inverter parameter or ...

Page 831: ...tion 1810H Channel number specified by d is used by another instruction 2820H The specified device exceeds the range of the corresponding device 3405H The value specified by s1 is other than any of K0 to 31 The value specified by s2 is outside the allowable range Less than K0 K3000 to 9999 or K13000 to 32767 The value specified by n is other than any of K1 to 4 3600H Channel number specified by d ...

Page 832: ...ee devices are occupied from the device specified in d Make sure that these devices are not used in other controls Ladder diagram Structured text ENO IVBWR EN s1 s2 s3 n d FBD LD Operand Description Range Data type Data type label s1 Inverter station number K0 to 31 16 bit signed binary ANY16 s2 Number of parameters in an inverter to be written at one time 1 16 bit signed binary ANY16 s3 Head devi...

Page 833: ...umber specified by d is used by another instruction 2820H The specified device exceeds the range of the corresponding device 3405H The value specified by s1 is other than any of K0 to 31 The value specified by s2 is K0 or less The value specified by s3 is outside the allowable range Less than K0 K3000 to 9999 or K13000 to 32767 The value specified by n is other than any of K1 to 4 3600H Channel nu...

Page 834: ...d1 For details refer to MELSEC iQ F FX5 User s Manual Serial Communication Ladder diagram Structured text ENO IVMC EN s1 s2 s3 n d1 d2 FBD LD Operand Description Range Data type Data type label s1 Inverter station number K0 to 31 16 bit signed binary ANY16 s2 Multiple instructions for inverter Send receive data type specification 1 16 bit signed binary ANY16 s3 Head device which stores data to be ...

Page 835: ...en by the IVMC instruction can be read when the next reading instruction IVCK IVMC etc is executed Two devices are occupied from the device specified in s3 and d1 Make sure that these devices are not used in other controls Three devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls Operation error For communication errors refer to MELSEC i...

Page 836: ...on No 0 to F7H 1 16 bit signed binary ANY16 s2 Function code 01H to 06H 0FH 10H 16 bit signed binary ANY16 s3 Function parameters depending on the function code 0 to FFFFH 16 bit signed binary ANY16 s4 Function parameters depending on the function code 1 to 2000 16 bit signed binary ANY16 s5 d1 Function parameters depending on the function code Bit 16 bit signed binary ANY_ELEMENTARY d2 Head bit d...

Page 837: ...tion such as communicating completed normally completed with an error Precautions Three devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls Operation error For communication errors refer to MELSEC iQ F FX5 User s Manual MODBUS Communication Error code SD0 SD8067 Description 1810H Channel used by the instruction is used by other instructi...

Page 838: ...l U 1 Dummy Input the character string U0 Character string ANYSTRING_SINGLE n1 Communication channel 1 to 4 16 bit unsigned binary ANY16_U n2 Number of protocols to be executed continuously 1 to 8 16 bit unsigned binary ANY16_U s Head device number for storing the control data Refer to Control data Page 837 Word ANY16_ARRAY Number of elements 18 d Head device number which turns ON when the executi...

Page 839: ...0 1 to 16 s 12 Collation match Receive packet number 3 If receiving is included in the communication type of the protocol that has been executed third the receive packet number successful in collation match is stored If the communication type is receive only 0 is stored If an error occurs during execution of the third protocol 0 is stored If the number of protocols executed is less than 3 0 is sto...

Page 840: ...he m 1 th protocol and after and is completed with an error The communication CH for which the S P CPRTCL instruction can be executed are only those for which Predefined protocol support function is specified for the communication protocol If a cancel request is received during execution of the mth protocol while multiple protocols are executed continuously the following is stored in s If same ins...

Page 841: ...port Function Instruction 839 15 Operation error Error code SD0 SD8067 Description 2820H The device used exceeded the specified range 2821H The device used to store data are overlapping 2822H Device that cannot be specified is specified 3405H The input data was out of range ...

Page 842: ...erand specification DVIT For the FX5 operand specification DDVIT For the FX3 compatible operand specification DDVIT For the FX5 operand specification TBL For the FX3 compatible operand specification TBL For the FX5 operand specification DRVTBL DRVMUL DABS PLSV For the FX3 compatible operand specification PLSV For the FX5 operand specification DPLSV For the FX3 compatible operand specification DPLS...

Page 843: ...PULSE SIGN and using Y only the SIGN output or general purpose output of the self axis can be specified Ladder diagram Structured text ENO DSZR EN s1 s2 d1 d2 FBD LD Operand Description Range Data type Data type label s1 Bit device number to which the near point dog signal is input Bit ANY_ELEMENTARY BOOL s2 Bit device number to which the zero phase signal is input Bit ANY_ELEMENTARY BOOL d1 Bit d...

Page 844: ...t device number When an X device is specified the zero phase signal functions follow the logic set by parameter When other than X device is specified the device functions follow the positive logic For d1 specify the device from which pulses are output Only the output devices Y having positioning parameters can be specified For d2 specify the bit device from which the rotation direction signal is o...

Page 845: ... speed set in s1 The speed must be 200 Kpps or lower in frequency For d1 specify the axis number for which zero return is performed For d2 specify the bit device of the zero return complete flag or abnormal end flag For details on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Ladder diagram Structured...

Page 846: ...nction Precautions Two devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls For other precautions refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module ...

Page 847: ...han the zero return speed set in s1 The speed must be 200 Kpps or lower in frequency For d1 specify the axis number for which zero return is performed For d2 specify the bit device of the zero return complete flag or abnormal end flag For details on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Ladder...

Page 848: ...nction Precautions Two devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls For other precautions refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module ...

Page 849: ...output of the self axis can be specified 3 T ST C cannot be used Ladder diagram Structured text ENO DVIT EN s1 s2 d1 d2 FBD LD Operand Description Range Data type Data type label s1 Positioning address after an interrupt input 32768 to 32767 16 bit signed binary ANY16 s2 Command speed 1 to 65535 16 bit unsigned binary ANY16 d1 Bit device number Y from which pulses are output 0 to 3 Bit ANY_ELEMENT...

Page 850: ...ncy For d1 specify the device from which pulses are output Only the output devices Y having positioning parameters can be specified For d2 specify the device from which the rotation direction signal is output Only the device specified with a parameter or general purpose outputs can be specified When the output devices Y is executed by another function PWM positioning PULSE axis or CW CCW axis etc ...

Page 851: ...ails on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Precautions Two devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls For other precautions refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse i...

Page 852: ...f the self axis can be specified 3 T ST C cannot be used Ladder diagram Structured text ENO DDVIT EN s1 s2 d1 d2 FBD LD Operand Description Range Data type Data type label s1 Positioning address after an interrupt input 2147483648 to 2147483647 32 bit signed binary ANY32 s2 Command speed 1 to 2147483647 32 bit signed binary ANY32 d1 Bit device number Y from which pulses are output 0 to 3 Bit ANY_E...

Page 853: ...requency For d1 specify the device from which pulses are output Only the output devices Y having positioning parameters can be specified For d2 specify the device from which the rotation direction signal is output Only the device specified with a parameter or general purpose outputs can be specified When the output devices Y is executed by another function PWM positioning PULSE axis or CW CCW axis...

Page 854: ... the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Precautions Two devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls For other precautions refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input ou...

Page 855: ...ol For d specify the device from which pulses are output Only the output devices Y having positioning parameters can be specified For n specify the table number to be executed according to the output specified in d For details on the function precautions and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Ladder diagram...

Page 856: ...specify the axis number from which pulses are output For n specify the table number to be executed according to the output specified in d For details on the function precautions and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Ladder diagram Structured text ENO TBL EN n d FBD LD Operand Description Range Data type Da...

Page 857: ...licable devices 1 T ST C cannot be used Ladder diagram Structured text ENO DRVTBL EN n1 n2 n3 d1 d2 FBD LD Operand Description Range Data type Data type label d1 Axis number from which pulses are to be output K1 to 12 1 16 bit unsigned binary ANY16 n1 Start table number to be executed 1 to 100 2 16 bit unsigned binary ANY16_U n2 Last table number to be executed 1 to 100 2 16 bit unsigned binary AN...

Page 858: ...nly one table is executed The table operation keeps executing until the last table or a table that is not set with parameters is executed For n3 specify the table execution method K0 Stepping operation K1 Continuous operation For d2 specify the bit device of the normal complete flag or abnormal end flag For details on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning C...

Page 859: ...3 n4 n5 d FBD LD Operand Description Range Data type Data type label n1 Start axis number K1 K5 K7 K9 K11 1 16 bit unsigned binary ANY16_U n2 Table number of the axis 1 K0 to 100 2 16 bit unsigned binary ANY16_U n3 Table number of the axis 2 K0 to 100 2 16 bit unsigned binary ANY16_U n4 Table number of the axis 3 K0 to 100 2 16 bit unsigned binary ANY16_U n5 Table number of the axis 4 K0 to 100 2 ...

Page 860: ...l CPU module built in High speed pulse input output module Precautions Eight devices are occupied from the device specified in d Make sure that these devices are not used in other controls For other precautions refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Designation number Axis numbers to be used K1 Execute axis 1 to axis 4 CP...

Page 861: ...al to the servo amplifier Be sure to use transistor outputs for the CPU module outputs For d2 specify the device that stores the absolute position ABS data read from the servo amplifier For details on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Ladder diagram Structured text ENO DABS EN s d1 d2 FBD ...

Page 862: ...on Precautions Three devices are occupied from the device specified in s and d1 Make sure that these devices are not used in other controls For other precautions refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module ...

Page 863: ...Y having positioning parameters can be specified For d2 specify the device from which the rotation direction signal is output Only the device specified with the parameter or general purpose outputs can be specified When the output devices Y is executed by another function PWM positioning PULSE axis or CW CCW axis etc the device does not function and causes an error For details on the function prec...

Page 864: ...he abnormal end status d2 1 For details on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Precautions Two devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls For other precautions refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU...

Page 865: ...ing positioning parameters can be specified For d2 specify the device from which the rotation direction signal is output Only the device specified with the parameter or general purpose outputs can be specified When the output devices Y is executed by another function PWM positioning PULSE axis or CW CCW axis etc the device does not function and causes an error For details on the function precautio...

Page 866: ...normal end status d2 1 For details on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Precautions Two devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls For other precautions refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU modu...

Page 867: ... purpose output of the self axis can be specified 3 T ST C cannot be used Ladder diagram Structured text ENO DRVI EN s1 s2 d1 d2 FBD LD Operand Description Range Data type Data type label s1 Positioning address 32768 to 32767 16 bit signed binary ANY16 s2 Command speed 1 to 65535 16 bit unsigned binary ANY16 d1 Output bit device number Y from which pulses are output 0 to 3 Bit ANY_ELEMENTARY BOOL ...

Page 868: ... specify the command speed in user units The speed must be 200 Kpps or lower in frequency For d1 specify the device from which pulses are output Only the Y devices having positioning parameters can be specified For d2 specify the bit device from which the rotation direction signal is output Only the device specified with the parameter or general purpose outputs can be specified When the output dev...

Page 869: ...ext ENO DRVI EN s1 s2 d1 d2 FBD LD Operand Description Range Data type Data type label s1 Positioning address 32768 to 32767 16 bit signed binary ANY16 s2 Command speed 1 to 65535 16 bit unsigned binary ANY16 d1 Axis number from which pulses are to be output K1 to 12 1 16 bit unsigned binary ANY_ELEMENTARY WORD d2 Bit device number of the positioning complete flag or abnormal end flag Bit ANY_BOOL...

Page 870: ...ulses For s2 specify the command speed in user units The speed must be 200 Kpps or lower in frequency For d1 specify the axis number from which pulses are output For d2 specify the bit device of the normal complete flag or abnormal end flag for the DRVI instruction For details on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed p...

Page 871: ...se output of the self axis can be specified 3 T ST C cannot be used Ladder diagram Structured text ENO DDRVI EN s1 s2 d1 d2 FBD LD Operand Description Range Data type Data type label s1 Positioning address 2147483648 to 2147483647 32 bit signed binary ANY32 s2 Command speed 1 to 2147483647 32 bit signed binary ANY32 d1 Output bit device number Y from which pulses are output 0 to 3 Bit ANY_ELEMENTA...

Page 872: ...s2 specify the command speed in user units The speed must be 200 Kpps or lower in frequency For d1 specify the device from which pulses are output Only the Y devices having positioning parameters can be specified For d2 specify the device from which the rotation direction signal is output Only the device specified with the parameter or general purpose outputs can be specified When the output devic...

Page 873: ... user units The speed must be 200 Kpps or lower in frequency For d1 specify the axis number from which pulses are output For d2 specify the bit device of the normal complete flag or abnormal end flag for the DDRVI instruction For details on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Ladder diagram ...

Page 874: ...nction Precautions Two devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls For other precautions refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module ...

Page 875: ...purpose output of the self axis can be specified 3 T ST C cannot be used Ladder diagram Structured text ENO DRVA EN s1 s2 d1 d2 FBD LD Operand Description Range Data type Data type label s1 Positioning address 32768 to 32767 16 bit signed binary ANY16 s2 Command speed 1 to 65535 16 bit unsigned binary ANY16 d1 Output bit device number Y from which pulses are output 0 to 3 Bit ANY_ELEMENTARY BOOL d...

Page 876: ... speed in user units The speed must be 200 Kpps or lower in frequency For d1 specify the device from which pulses are output Only the Y devices having positioning parameters can be specified For d2 specify the bit device from which the rotation direction signal is output Only the device specified with the parameter or general purpose outputs can be specified When the output devices Y is executed b...

Page 877: ...ce of the normal complete flag or abnormal end flag for the DRVA instruction For details on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Precautions Two devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls For other precautions refer to MELS...

Page 878: ...output of the self axis can be specified 3 T ST C cannot be used Ladder diagram Structured text ENO DDRVA EN s1 s2 d1 d2 FBD LD Operand Description Range Data type Data type label s1 Positioning address 2147483648 to 2147483647 32 bit signed binary ANY32 s2 Command speed 1 to 2147483647 32 bit signed binary ANY32 d1 Output bit device number Y from which pulses are output 0 to 3 Bit ANY_ELEMENTARY ...

Page 879: ...d speed in user units The speed must be 200 Kpps or lower in frequency For d1 specify the device from which pulses are output Only the Y devices having positioning parameters can be specified For d2 specify the bit device from which the rotation direction signal is output Only the device specified with the parameter or general purpose outputs can be specified When the output devices Y is executed ...

Page 880: ...ust be 200 Kpps or lower in frequency For d1 specify the axis number from which pulses are output For d2 specify the bit device of the normal complete flag or abnormal end flag for the DDRVA instruction For details on the function and error code refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module Ladder diagram Structured text ENO DDR...

Page 881: ...n 879 16 Precautions Two devices are occupied from the device specified in d2 Make sure that these devices are not used in other controls For other precautions refer to MELSEC iQ F FX5 User s Manual Positioning Control CPU module built in High speed pulse input output module ...

Page 882: ... enters ENO G_ABRST1 EN Un s d ENO G_ABRST2 EN Un s d FBD LD G_ABRST1 G_ABRST2 enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s Device where the control data is stored Refer to Page 881 Control data Device name ANY16_ARRAY 2 Number of elements 8 d Device which turns on when the execution of the instructi...

Page 883: ...status below input from the servo amplifier to the CPU module or I O module b0 ABS data bit 0 b1 ABS data bit 1 b2 Send data ready flag 0 1 User s 3 Signal to be sent to the servo amplifier Performs the operation with this instruction by using the Signal received from the servo amplifier in s 2 The ON OFF state of the following data output to the servo amplifier is stored b0 Servo ON b1 ABS transf...

Page 884: ...solute position can be restored the G ABRST instruction can be executed while a servo amplifier is operable Note that when the absolute position is restored the Servo on signal may turn off servo off for the period of the scan time plus approximately 60 ms and the motor may move To restore the absolute position during the servo off state install an electromagnetic brake separately so that signals ...

Page 885: ... EN Un s d ENO GP_PSTRT2 EN Un s d FBD LD GP_PSTRT1 GP_PSTRT2 enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s Own station head device where control data is stored Refer to Page 884 Control data Device name ANY16_ARRAY 2 Number of elements 3 d Own station device to be turned on for one scan when the inst...

Page 886: ...f the following data that is started with the GP PSTRT instruction Positioning data number 1 to 600 Block start 7000 to 7004 Machine OPR 9001 Fast OPR 9002 Present value change 9003 Multiple axes concurrent start 9004 1 to 600 7000 to 7004 9001 to 9004 User Instruction symbol Target axis GP PSTRT1 Axis 1 GP PSTRT2 Axis 2 Device Description Completion device d This device turns on during the END pr...

Page 887: ...atus b0 is ON While the READY signal Md 140 module status b0 is OFF if the GP PSTRT instruction is executed PLC READY OFF start Error code 19A1H error occurs and positioning cannot be started Turn the Cd 190 PLC READY signal ON and turn the READY signal Md 140 module status b0 ON before executing the GP PSTRT instruction If multiple axes concurrent start is executed using the GP PSTRT instruction ...

Page 888: ..._TEACH2 EN Un s d FBD LD GP_TEACH1 GP_TEACH2 enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s Own station head device where control data is stored Refer to Page 887 Control data Device name ANY16_ARRAY 2 Number of elements 4 d Own station device to be turned on for one scan when the instruction completes...

Page 889: ... 0 Error error code System s 2 Teaching data selection Selects the address to which to write the current feed value positioning or arc address 0 Writes the current feed value to the positioning address 1 Writes the current feed value to the arc address 0 1 User s 3 Positioning data number Sets the positioning data number at which to perform the teaching 1 to 600 User Instruction symbol Target axis...

Page 890: ...hing cannot be executed Before executing the instruction check that the Md 141 BUSY signal of the corresponding axis is off If this instruction is executed in an interrupt program with the priority 1 operation error 3580H occurs This instruction operates in an interrupt program with the priority 2 or 3 Operation error Positioning start instruction GP PSTRT Absolute position restoration instruction...

Page 891: ...D LD GP_PFWRT enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s Own station head device where control data is stored Refer to Page 889 Control data Device name ANY16_ARRAY 2 Number of elements 2 d Own station device to be turned on for one scan when the instruction completes If the instruction is complete...

Page 892: ...ng the CPU module The GP PFWRT instruction can be executed when the READY signal Md 140 module status b0 is OFF While the READY signal Md 140 module status b0 is ON if the GP PFWRT instruction is executed Writing during PLC READY ON Warning code 0905H warning occurs in the positioning module and the module backup cannot be executed Turn the Cd 190 PLC READY signal OFF and turn the READY signal Md ...

Page 893: ...16 POSITIONING INSTRUCTION 16 2 Positioning Module 891 16 Operation error Error code s 1 Description 1080H Flash ROM write count error 1931H Flash ROM write error ...

Page 894: ... ENO GP_PINIT EN Un s d FBD LD GP_PINIT enters Operand Description Range Data type Data type label U 1 Position number of the module connected 1H to 10H 16 bit unsigned binary ANY16 s Own station head device where control data is stored Refer to Page 892 Control data Device name ANY16_ARRAY 2 Number of elements 2 d Own station device to be turned on for one scan when the instruction completes If t...

Page 895: ...ond this count results in failure and the flash ROM write error error code 1931H occurs After the power is turned on or the CPU module is reset once module backup including the number of times initialization is executed can be repeated a maximum of 25 times if the program is used Any attempt to write data to the flash ROM memory beyond 25 times results in a flash ROM write count error at error cod...

Page 896: ... n2 d FBD LD Operand Description Range Data type Data type label U H 1 Module number K1 to 16 16 bit unsigned binary ANY16_U s Head buffer memory number 0 to 32767 16 bit unsigned binary ANY16_U d Head device number storing data to be read from buffer memory 16 bit signed binary ANY16 n1 Number of all buffer memory areas to be read 1 to 32768 16 bit unsigned binary ANY16_U n2 Not used 16 bit unsig...

Page 897: ...ters at the beginning of execution are used Even if the contents of index registers are changed after the instruction such changes do not affect the process of the instruction The contents of n1 points starting from d update change every scan while this instruction is executed Use the data after the instruction is completed Do not update change the contents of n1 buffer memory areas starting from ...

Page 898: ...mory number The intelligent function module incorporates a RAM memory The RAM memory is called buffer memory Buffer memory numbers range from 0 to 32767 and their contents vary depending on the function of the extension equipment Setting range K0 to K32767 For the contents of buffer memory areas refer to manuals of intelligent function modules Error code SD0 SD8067 Description 2441H Communication ...

Page 899: ...tion Range Data type Data type label U H 1 Module number K1 to 16 16 bit unsigned binary ANY16_U s1 Head buffer memory number 0 to 32767 16 bit unsigned binary ANY16_U s2 Head device number storing data to be written to buffer memory 16 bit signed binary ANY16 n1 Number of all buffer memory areas to be written 1 to 32768 16 bit unsigned binary ANY16_U n2 Not used 16 bit unsigned binary ANY16_U EN ...

Page 900: ...points starting from s2 while this instruction is executed If the contents are updated the intended data may not be written to the buffer memory areas This instruction cannot be used in FX5 intelligent function modules This instruction cannot be used while a interrupt routine program is being executed Operation error Device Name Description SM8029 Instruction execution complete Turns ON when an in...

Page 901: ...ng chapters 18 TYPE CONVERSION FUNCTIONS 19 SINGLE NUMBER VARIABLE FUNCTIONS 20 ARITHMETIC OPERATION FUNCTIONS 21 BIT SHIFT FUNCTIONS 22 STANDARD BITWISE BOOLEAN FUNCTIONS 23 SELECTION FUNCTIONS 24 COMPARISON FUNCTIONS 25 CHARACTER STRING FUNCTIONS 26 TIME DATA FUNCTIONS ...

Page 902: ...output value is output from d 2 Function with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d BOOL_TO_WOR...

Page 903: ... is output from d 2 Function with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d BOOL_TO_DWORD s With EN...

Page 904: ...output from d 2 Function with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d BOOL_TO_INT s With EN ENO d...

Page 905: ...is output from d 2 Function with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d BOOL_TO_DINT s With EN E...

Page 906: ...utput from d 2 Function with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d BOOL_TO_TIME s With EN ENO d...

Page 907: ...e is output from d 2 Function with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d BOOL_TO_STRING s With ...

Page 908: ...nction with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d WORD_TO_BOOL s With EN ENO d WORD_TO_BOOL_E E...

Page 909: ...table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d WORD_TO_DWORD s With EN ENO d WORD_TO_DWORD_E EN ENO s Argument Description Ty...

Page 910: ...ditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d WORD_TO_INT s With EN ENO d WORD_TO_INT_E EN ENO s Argument Description Type Data type EN Execution conditi...

Page 911: ...esults 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d WORD_TO_DINT s With EN ENO d WORD_TO_DINT_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FAL...

Page 912: ...ns and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d WORD_TO_TIME s With EN ENO d WORD_TO_TIME_E EN ENO s Argument Description Type Data type EN Execution condition ...

Page 913: ...unction with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DWORD_TO_BOOL s With EN ENO d DWORD_TO_BOOL_...

Page 914: ... ENO data output from d is undefined In that case modify a program so that the data output from d is not used When DWORD_TO_WORD _E is executed the information stored in high order 16 bits of the DWORD type data value input from s is discarded Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DWORD_TO_WORD s With EN ENO d DWORD_TO_WORD_E EN ENO s Argument Descriptio...

Page 915: ...18 TYPE CONVERSION FUNCTIONS 18 13 Converting DWORD to WORD 913 18 Operation error There is no operation error ...

Page 916: ...output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used When DWORD_TO_INT _E is executed the information stored in high order 16 bits of the DWORD type data value input from s is discarded Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DWORD_TO_INT s With EN ENO d DWORD_TO_INT_E EN ENO s Argument De...

Page 917: ...18 TYPE CONVERSION FUNCTIONS 18 14 Converting DWORD to INT 915 18 Operation error There is no operation error ...

Page 918: ...itions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DWORD_TO_DINT s With EN ENO d DWORD_TO_DINT_E EN ENO s Argument Description Type Data type EN Execution cond...

Page 919: ... and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DWORD_TO_TIME s With EN ENO d DWORD_TO_TIME_E EN ENO s Argument Description Type Data type EN Execution condition ...

Page 920: ...unction with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d INT_TO_BOOL s With EN ENO d INT_TO_BOOL_E EN...

Page 921: ...onditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d INT_TO_WORD s With EN ENO d INT_TO_WORD_E EN ENO s Argument Description Type Data type EN Execution condi...

Page 922: ...ts 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d INT_TO_DWORD s With EN ENO d INT_TO_DWORD_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE S...

Page 923: ...conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d INT_TO_DINT s With EN ENO d INT_TO_DINT_E EN ENO s Argument Description Type Data type EN Execution cond...

Page 924: ...tured text Without EN ENO With EN ENO Without EN ENO d INT_TO_BCD s With EN ENO d INT_TO_BCD_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable INT ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d INT_TO_BCD _E Output Output variable WORD 1 Make sure to set them to 0 Operation result d No ...

Page 925: ...18 TYPE CONVERSION FUNCTIONS 18 21 Converting INT to BCD 923 18 Operation error Error code SD0 SD8067 Description 3401H Data in the device specified by s is out of the valid range 0 to 9999 ...

Page 926: ...nditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d INT_TO_REAL s With EN ENO d INT_TO_REAL_E EN ENO s Argument Description Type Data type EN Execution condit...

Page 927: ...nditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d INT_TO_TIME s With EN ENO d INT_TO_TIME_E EN ENO s Argument Description Type Data type EN Execution condit...

Page 928: ... of the character string when SM701 output character number selector signal is off Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d INT_TO_STRING s With EN ENO d INT_TO_STRING_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable INT ENO Output status TRUE Normal FALSE Abnormal ...

Page 929: ...peration output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 2820H In the corresponding device range of the device specified by s and l...

Page 930: ...ction with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DINT_TO_BOOL s With EN ENO d DINT_TO_BOOL_E EN...

Page 931: ...output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used When DINT_TO_WORD _E is executed the information stored in high order 16 bits of the DINT type data value input from s is discarded Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DINT_TO_WORD s With EN ENO d DINT_TO_WORD_E EN ENO s Argument Des...

Page 932: ...930 18 TYPE CONVERSION FUNCTIONS 18 26 Converting DINT to WORD Operation error There is no operation error ...

Page 933: ...ditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DINT_TO_DWORD s With EN ENO d DINT_TO_DWORD_E EN ENO s Argument Description Type Data type EN Execution con...

Page 934: ...peration error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DINT_TO_INT s With EN ENO d DINT_TO_INT_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable DINT ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d DINT_TO_INT _E Output Output variable INT Operat...

Page 935: ...ithout EN ENO With EN ENO Without EN ENO d DINT_TO_BCD s With EN ENO d DINT_TO_BCD_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable DINT ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d DINT_TO_BCD _E Output Output variable ANY_BIT 1 Make sure to set them to 0 s d EN ENO d s DINT 9999999...

Page 936: ...lt d No operation error occurred Operation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 3401H The 32 bit signed binary data in t...

Page 937: ...is executed The operation output value is output from d 2 Function with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Wi...

Page 938: ...ditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DINT_TO_TIME s With EN ENO d DINT_TO_TIME_E EN ENO s Argument Description Type Data type EN Execution condi...

Page 939: ...gram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DINT_TO_STRING s With EN ENO d DINT_TO_STRING_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable DINT ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d DINT_TO_STRING _E Output Output variable STRING 11 1 00H is stored ...

Page 940: ...ata output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Operation result d No operation error occurred Operation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Ope...

Page 941: ... diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d BCD_TO_INT s With EN ENO d BCD_TO_INT_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable WORD ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d BCD_TO_INT _E Output Output variable INT 1 Always becomes 0 Operation r...

Page 942: ...940 18 TYPE CONVERSION FUNCTIONS 18 33 Converting BCD to INT Operation error Error code SD0 SD8067 Description 3401H A value other than 0 to 9 exists in each digit of s ...

Page 943: ...ut variable DINT When WORD is specified to s 1 Always becomes 0 When DWORD is specified to s 1 Always becomes 0 s d EN ENO d s WORD 9999H DINT 9999 9999 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 1 1 1 0 0 0 0 1 1 1 1 DINT 1 2 31 2 30 2 29 2 28 2 27 2 26 2 25 2 24 2 23 2 22 2 21 2 20 2 19 2 18 2 17 2 16 2 15 2 14 2 13 2 12 2 11 2 10 2 9 2 8 2 7 2 6 2 5 2 4 2 3 2 2 2 1 2 0 1 0 0 1 1 0 0 1 1 0 0 1 1 ...

Page 944: ... When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error When s is WORD When s is DWORD Operation result d No operation error occurred Operation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occ...

Page 945: ...on results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d REAL_TO_INT s With EN ENO d REAL_TO_INT_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Inp...

Page 946: ... 3401H The single precision real number in the device specified by s is out of the valid range 32768 to 32767 3402H A special number is set to s The set single precision real number is not located within the following range 0 2 126 s 2128 The set device or label value is 0 denormalized number NaN not a number or ...

Page 947: ...ion results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d REAL_TO_DINT s With EN ENO d REAL_TO_DINT_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input ...

Page 948: ...H The single precision real number in the device specified by s is out of the valid range 2147483648 to 2147483647 3402H A special number is set to s The set single precision real number is not located within the following range 0 2 126 s 2128 The set device or label value is 0 denormalized number NaN not a number or ...

Page 949: ...put variable BOOL d REAL_TO_STRING _E Output Output variable STRING 13 The number of digits is fixed respectively for the integer part decimal part and exponent part as follows Integer part 1 decimal part 5 exponent part 2 20H space is stored in the 2nd byte 2EH is stored in the 4th byte and 45H E is stored in the 10th byte automatically 1 Total number of digits 13 digits 2 Integer part 1 digit 3 ...

Page 950: ... off 30H 0 is stored in the decimal part when the number of significant figures is small 1 Total number of digits 13 digits 2 Number of digits of decimal part 5 3 30H 0 is stored In Sign data exponent part 2BH is stored when the input value is positive and 2DH is stored when the input value is negative 30H 0 is stored in the tens place of the exponent part when the exponent part consists of 1 digi...

Page 951: ... operation error occurred Operation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 3402H s is not located within the following ran...

Page 952: ...When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d TIME_TO_BOOL s With EN ENO d TIME_TO_BOOL_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop I...

Page 953: ...nditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d TIME_TO_WORD s With EN ENO d TIME_TO_WORD_E EN ENO s Argument Description Type Data type EN Execution cond...

Page 954: ...ons and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d TIME_TO_DWORD s With EN ENO d TIME_TO_DWORD_E EN ENO s Argument Description Type Data type EN Execution conditi...

Page 955: ...h EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d TIME_TO_INT s With EN ENO d TIME_TO_INT_E EN ENO s Argu...

Page 956: ...ons and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d TIME_TO_DINT s With EN ENO d TIME_TO_DINT_E EN ENO s Argument Description Type Data type EN Execution condition...

Page 957: ...esults 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d TIME_TO_STRING s With EN ENO d TIME_TO_STRING_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution...

Page 958: ...ns and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d STRING_TO_ BOOL s With EN ENO d STRING_TO_ BOOL_E EN ENO s Argument Description Type Data type EN Execution cond...

Page 959: ...STRING_TO_INT s With EN ENO d STRING_TO_INT_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable STRING 6 ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d STRING_TO_INT _E Output Output variable INT Within the range of 30H to 39H 20H 2DH and 00H in ASCII code Within the range of 32768 to 327...

Page 960: ...ation error Error code SD0 SD8067 Description 3401H Invalid data which cannot be converted to s are input Values for each place of the ASCII code are other than 30H to 39H 20H and 00H Values for the ASCII data are other than 32768 to 32767 when STRING_TO_INT _E is used ...

Page 961: ...EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable STRING 11 ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d STRING_TO_DINT _E Output Output variable DINT Within the range of 30H to 39H 20H 2DH and 00H in ASCII code Within the range of 2147483648 to 2147483647 as the STRING type data value Operation result d No operation error occurre...

Page 962: ... error Error code SD0 SD8067 Description 3401H Invalid data which cannot be converted to s are input Values for each place of the ASCII code are other than 30H to 39H 20H and 00H Values for the ASCII data are other than 2147483648 to 2147483647 when STRING_TO_DINT _E is used ...

Page 963: ...t Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable STRING 24 ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d STRING_TO_REAL _E Output Output variable REAL Decimal point format s d EN ENO d s REAL ASCII code for 3rd character ASCII code for 2nd character ASCII code for 5th character ASCII code for 4th chara...

Page 964: ...rst 0 in STRING type data 20H or 30H is ignored during conversion When 30H 0 exists between a number and E in STRING type data exponent format 30H is ignored during conversion When 20H space is contained in character string 20H is ignored during conversion Up to 24 characters can be input as STRING type data 20H space and 30H 0 in a character string are counted as one character respectively A valu...

Page 965: ...SD8067 Description 2820H 00H does not exist in the corresponding device range starting from s 3401H Invalid data which cannot be converted to s are set Any character other than 30 0 to 39 9 exists in the integer part or decimal part 2EH exists in two or more positions in the specified character string Any character other than 45H E 65 e 2B or 2D exists in the specified exponent part Two or more ex...

Page 966: ...odify a program so that the data output from d is not used Operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d STRING_TO_TIME s With EN ENO d STRING_TO_TIME_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable STRING 11 ENO Output status TRUE Normal FALSE Abnormal ...

Page 967: ... and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d BITARR_TO_INT s n With EN ENO d BITARR_TO_INT_E EN ENO s n Argument Description Type Data type EN Execution condit...

Page 968: ...eration results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d BITARR_TO_DINT s n With EN ENO d BITARR_TO_DINT_E EN ENO s n Argument Description Type Data type EN Execution condition T...

Page 969: ...E is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d INT_TO_BITARR s n With EN ENO d INT_TO_BITARR_E EN ENO s n Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Inpu...

Page 970: ...output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DINT_TO_BITARR s n With EN ENO d DINT_TO_BITARR_E EN ENO s n Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input v...

Page 971: ...defined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d CPY_BITARR s n With EN ENO d CPY_BITARR_E EN ENO s n Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s BitArrIn Input Input variable BOO...

Page 972: ...data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram Structured text FBD LD Without EN ENO With EN ENO Without EN ENO d GET_BIT_OF_INT s n With EN ENO d GET_BIT_OF_INT_E EN ENO s n Not supported Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input var...

Page 973: ... is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram Structured text FBD LD Without EN ENO With EN ENO Without EN ENO d SET_BIT_OF_INT s n With EN ENO d SET_BIT_OF_INT_E EN ENO s n Not supported Argument Description Type Data type EN Execution condition TRUE Execution ...

Page 974: ...In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram Structured text FBD LD Without EN ENO With EN ENO Without EN ENO d CPY_BIT_OF_INT s n1 n2 With EN ENO d CPY_BIT_OF_INT_E EN ENO s n1 n2 Not supported Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s Input Input...

Page 975: ...Operation result The operation processing is executed The operation output value is output from d Operation error There is no operation error Ladder diagram FBD LD Structured text d GET_BOOL_ADDR s d GET_INT_ADDR s d GET_WORD_ADDR s Argument Description Type Data type s Input Input variable ANY d GET_BOOL_ADDR GET_INT_ADDR GET_WORD_ADDR Output Output variable BOOL INT WORD General function Input d...

Page 976: ...on without EN ENO The following table lists the operation results 2 Function with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d ABS s With EN ENO d...

Page 977: ...S 19 1 Absolute Value 975 19 Operation error When s is REAL Error code SD0 SD8067 Description 3402H The data specified by s is 0 denormalized number NaN not a number or 3403H d exceeds the following range An overflow has occurred d 2128 ...

Page 978: ...hen FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d SQRT s With EN ENO d SQRT_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable ...

Page 979: ...utput from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d LN s With EN ENO d LN_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable REAL ENO Output st...

Page 980: ...t EN ENO The following table lists the operation results 2 Function with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d LOG s With EN ENO d LOG_E EN...

Page 981: ...en s is REAL Error code SD0 SD8067 Description 3402H The value specified in s is 0 denormalized number NaN not a number or 3403H The value of d exceeds the following range An overflow has occurred d 2128 3405H Data outside the allowable range was set to s A negative value is specified 0 is specified ...

Page 982: ...ts 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d EXP s With EN ENO d EXP_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input varia...

Page 983: ...eration results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d SIN s With EN ENO d SIN_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Inpu...

Page 984: ... operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d COS s With EN ENO d COS_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN I...

Page 985: ...on with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d TAN s With EN ENO d TAN_E EN ENO s Argument Description Type Data type EN Exe...

Page 986: ...SE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d ASIN s With EN ENO d ASIN_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable REAL EN...

Page 987: ...hen FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d ACOS s With EN ENO d ACOS_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable ...

Page 988: ...conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d ATAN s With EN ENO d ATAN_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input vari...

Page 989: ...cution FALSE Stop Input variable BOOL s1 IN1 to s28 IN28 Input Input variable ANY_NUM ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d ADD _E Output Output variable ANY_NUM Data type is INT Data type is DINT Data type is REAL Even if underflow or overflow occurs in the operation result it is not regarded as an operation error ADD_E outputs TRUE from ENO Example 1 32767 2 1 7FFFH...

Page 990: ...not used Operation error s1 to s28 are REAL Operation result d No operation error occurred Operation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 S...

Page 991: ...LSE Abnormal Output variable BOOL d MUL _E Output Output variable ANY_NUM Data type is INT Data type is DINT Data type is REAL Even if underflow or overflow occurs in the operation result it is not regarded as an operation error MUL_E outputs TRUE from ENO Even when the operation result exceeds the INT type data range the INT type data is output The operation result is the DINT type however the ou...

Page 992: ...range convert the data type of an input value then perform the operation Operation error s1 to s28 are REAL Operation result d No operation error occurred Operation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value...

Page 993: ...L s1 IN1 s2 IN2 Input Input variable ANY_NUM ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d SUB _E Output Output variable ANY_NUM Data type is INT Data type is DINT Data type is REAL Even if underflow or overflow occurs in the operation result it is not regarded as an operation error SUB_E outputs TRUE from ENO Example 1 32767 2 1 7FFFH 0002H 0001H The most significant bit bec...

Page 994: ...d s2 are REAL Operation result d No operation error occurred Operation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 3402H The da...

Page 995: ... to s2 When the operation result is 0 the zero flag SM8020 turns on When the operation result exceeds 32767 16 bit operation or 2147483647 32 bit operation the carry flag SM8022 turns on Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DIV s1 s2 With EN ENO d DIV_E EN ENO s1 s2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Inp...

Page 996: ...An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 3400H The value divisor specified by s2 is 0 Error code SD0 SD8067 Description 3400H The value d...

Page 997: ...undefined In that case modify a program so that the data output from d is not used Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d MOD s1 s2 With EN ENO d MOD_E EN ENO s1 s2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 IN1 Dividend Input variable ANY_INT s2 IN2 Divisor Input variable ANY_INT ENO Output...

Page 998: ...CTIONS 20 5 Remainder Operation error s1 and s2 are INT s1 and s2 are DINT Error code SD0 SD8067 Description 3400H The value divisor specified by s2 is 0 Error code SD0 SD8067 Description 3400H The value divisor specified by s2 is 0 ...

Page 999: ...at the data output from d is not used Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d EXPT s1 s2 With EN ENO d EXPT_E EN ENO s1 s2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 IN1 Cardinal number Input variable REAL s2 IN2 Exponent Input variable ANY_NUM ENO Output status TRUE Normal FALSE Abnormal Out...

Page 1000: ...rror code SD0 SD8067 Description 3402H The value of s1 is outside the following range 0 2 126 s1 2128 The data specified by s1 is 0 denormalized number NaN not a number or 3403H The operation result is within the following range 2128 operation result Error code SD0 SD8067 Description 3402H The value of s1 is outside the following range 0 2 126 s1 2128 The data specified by s1 is 0 denormalized num...

Page 1001: ... be specified for s and d Specify the same data type for s and d Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d MOVE s With EN ENO d MOVE_E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable ANY ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d MOVE _E Outpu...

Page 1002: ...ation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 2820H In the corresponding device range of the device specified by s and late...

Page 1003: ...e and within the following range Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d SHL s n With EN ENO d SHL_E EN ENO s n Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable ANY_BIT n N Number of shift bits Input variable ANY_BIT ENO Output status TRUE Normal FALSE Abnormal Output variabl...

Page 1004: ...The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE 1 Indefinite value ...

Page 1005: ...hin the following range Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d SHR s n With EN ENO d SHR_E EN ENO s n Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable ANY_BIT n N Number of shift bits Input variable ANY_BIT ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d ...

Page 1006: ... The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE 1 Indefinite value ...

Page 1007: ...r diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d ROL s n With EN ENO d ROL_E EN ENO s n Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable ANY_BIT n N Number of shift bits Input variable ANY_BIT ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d ROL _E Output Output variable...

Page 1008: ...O The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE 1 Indefinite value...

Page 1009: ...dder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d ROR s n With EN ENO d ROR_E EN ENO s n Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable ANY_BIT n N Number of shift bits Input variable ANY_BIT ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d ROR _E Output Output varia...

Page 1010: ...O The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE 1 Indefinite value...

Page 1011: ...he BOOL WORD or DWORD type data input in s1 to s28 bit by bit and output the operation result from d in the same data type as s Ex When the data type is WORD Ladder diagram FBD LD 1 Structured text 1 Without EN ENO With EN ENO Without EN ENO d AND s1 s2 d OR s1 s2 d XOR s1 s2 With EN ENO d AND_E EN ENO s1 s2 d OR_E EN ENO s1 s2 d XOR_E EN ENO s1 s2 Argument Description Type Data type EN Execution ...

Page 1012: ... s6 and so on Ex When the data type is BOOL Operation result 1 Function without EN ENO The operation processing is executed The operation output value is output from d 2 Function with EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used...

Page 1013: ... ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d NOT s With EN ENO d NOT_E EN ENO s Argument Description Typ...

Page 1014: ...an argument correspond to the bit value of s1 0 or 1 A value input to s1 is the BOOL type data value A data value of the BOOL INT DINT WORD DWORD REAL STRING TIME structure or array type can be input to s2 and s3 Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d SEL s1 s2 s3 With EN ENO d SEL_E EN ENO s1 s2 s3 Argument Description Type Data type EN Execution conditi...

Page 1015: ...ror occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 2820H 00H is not set to a label specified by s2 or devices from the device number to end device number of corre...

Page 1016: ...s1 s2 With EN ENO d MAX_E EN ENO s1 s2 d MIN_E EN ENO s1 s2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 IN1 to s28 IN28 Input Input variable ANY_ELEMENTARY ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d MAX _E MIN _E Output Output variable ANY_ELEMENTARY These functions output the maximum value of the BOOL INT DIN...

Page 1017: ...ed Operation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 2820H In the corresponding device range of the device specified by s1 ...

Page 1018: ...Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 MIN Lower limit value minimum output threshold value Input variable ANY_ELEMENTARY s2 IN Input value to be controlled with the upper and lower limits Input variable ANY_ELEMENTARY s3 MX Upper limit value maximum output threshold value Input variable ANY_ELEMENTARY ENO Output status TRUE Norm...

Page 1019: ... specified by s1 is greater than the upper limit value specified by s2 Error code SD0 SD8067 Description 3405H The lower limit value specified by s1 is greater than the upper limit value specified by s3 Error code SD0 SD8067 Description 3402H The value of s1 is outside the following range 0 2 126 s1 2128 The data specified by s1 is 0 denormalized number NaN not a number or The value of s2 is outsi...

Page 1020: ...n indefinite value from d An operation error does not occur MUX_E outputs FALSE from ENO A value input to n is the INT type data value and within the range from 0 to 27 The value must be in the pin number range for s A data value of the BOOL INT DINT WORD DWORD REAL STRING TIME structure or array type can be input to s Ladder diagram FBD LD 1 Structured text 1 Without EN ENO With EN ENO Without EN...

Page 1021: ...on output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 2820H In the corresponding device range of the device specified by s1 to s28 and...

Page 1022: ... s1 IN1 to s28 IN28 Input Input variable ANY_ELEMENTARY ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d GT _E GE _E EQ _E LE _E LT _E Output TRUE True value FALSE False value Output variable BOOL GT _E These functions compare s1 s2 s2 s3 s n 1 s n When all the operation results are s n 1 s n these functions output TRUE When any of the operation results is s n 1 s n these functi...

Page 1023: ...ation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 2820H In the corresponding device range of the device specified by s1 to s28 ...

Page 1024: ...ta output from d is undefined In that case modify a program so that the data output from d is not used Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO 1 d NE s1 s2 With EN ENO d NE_E EN ENO s1 s2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 IN1 s2 IN2 Input Input variable ANY_ELEMENTARY ENO Output status...

Page 1025: ...820H In the corresponding device range of the device specified by s and later 00H does not exist 3405H The character string specified by s has more than 16383 characters 3406H The whole specified character string cannot be stored in the devices from the device specified by d to the last device in the corresponding device range ...

Page 1026: ...from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d LEN s With EN ENO d LEN _E EN ENO s Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable STRING 255 ENO...

Page 1027: ...ENO s n d RIGHT_E EN ENO s n Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s IN Input Input variable STRING 255 n L Specification of number of characters to be extracted Input variable INT ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d LEFT _E RIGHT _E Output Output variable STRING 255 These functions output the data f...

Page 1028: ...itions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error These functions output the data for the specified number of characters from the right of a character string input to s from d The value input to n specifies the number of characters to be ex...

Page 1029: ...input to s A value input to n2 is the INT type data value and within the range from 1 to 255 However the value must be within the number of characters of the character string to be input to s Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d MID s n1 n2 With EN ENO d MID_E EN ENO s n1 n2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE...

Page 1030: ...operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 2820H In the corresponding device range of the device specified by s and later 00H does not exist 3405H The character string specified by s has more than 16383 characters Data outside the allowable ran...

Page 1031: ...n the range from 0 to 255 byte s Ladder diagram FBD LD 1 Structured text 1 Without EN ENO With EN ENO Without EN ENO d CONCAT s1 s2 With EN ENO d CONCAT_E EN ENO s1 s2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 IN1 to s28 IN28 Input Input variable STRING 255 ENO Output status TRUE Normal FALSE Abnormal Output variable BOOL d CONCAT _...

Page 1032: ... No operation error occurred Operation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 2820H In the corresponding device range of t...

Page 1033: ...ue input to n is the INT type data value and within the range from 1 to 255 However the value must be within the number of characters of the character string to be input to s1 Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d INSERT s1 s2 n With EN ENO d INSERT_E EN ENO s1 s2 n Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Inpu...

Page 1034: ... d No operation error occurred Operation output value An operation error occurred Indefinite value Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 2820H In the corresponding device range of...

Page 1035: ...string to be input to s A value input to n2 is the INT type data value and within the range from 1 to 255 However the value must be within the number of characters of the character string to be input to s Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DELETE s n1 n2 With EN ENO d DELETE_E EN ENO s n1 n2 Argument Description Type Data type EN Execution condition T...

Page 1036: ...eration error did not occur Operation output value FALSE Operation error occurred 1 Indefinite value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 2820H 00H is not set to devices from the device number specified by s to the end device number of corresponding device 3405H The character strings specified by s have more than 255 characters The device value specified...

Page 1037: ... input to n1 specifies the number of characters to be replaced Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d REPLACE s1 s2 n1 n2 With EN ENO d REPLACE_E EN ENO s1 s2 n1 n2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 IN1 s2 IN2 Input Input variable STRING 255 n1 L Specification of number of character...

Page 1038: ...ng table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used 1 Head character position of a character string to be replaced n2 5th character 2 Number of characters to be replaced n1 5 Operation result d No operation error occurred Operation output value An opera...

Page 1039: ...he character strings specified by s1 have more than 255 characters The character strings specified by s2 have more than 255 characters The device value specified by n1 is out of the valid range 0 to 255 The device value specified by n2 is out of the valid range 1 to 255 n1 exceeds the number of characters of a character string specified by s2 n2 exceeds the number of characters of a character stri...

Page 1040: ... one specified by s1 these functions output 0 A value input to s1 and s2 is the STRING type data value and within the range from 0 to 255 byte s Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d FIND s1 s2 With EN ENO d FIND_E EN ENO s1 s2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 IN1 s2 IN2 Input Inp...

Page 1041: ...th EN ENO The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE 1 Indefini...

Page 1042: ...is output from d as follows ADD_TIME_E outputs TRUE from the output variable ENO Ex Overflow The most significant bit becomes 1 and a negative time is output Ex Underflow The most significant bit becomes 0 and a positive time is output Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d ADD_TIME s1 s2 With EN ENO d ADD_TIME_E EN ENO s1 s2 Argument Description Type Dat...

Page 1043: ...e following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE 1 Indefinite value ...

Page 1044: ... output from d as follows SUB_TIME_E outputs TRUE from the output variable ENO Ex Overflow The most significant bit becomes 1 and a negative time is output Ex Underflow The most significant bit becomes 0 and a positive time is output Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d SUB_TIME s1 s2 With EN ENO d SUB_TIME_E EN ENO s1 s2 Argument Description Type Data ...

Page 1045: ...he following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE 1 Indefinite value ...

Page 1046: ...tputs TRUE from the output variable ENO The operation result is the 64 bit data however the output data is the time type data with high order 32 bits deleted Ex Overflow The most significant bit becomes 1 and a negative time is output Ex Underflow The most significant bit becomes 0 and a positive time is output Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d MUL_T...

Page 1047: ... The following table lists the execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE 1 Indefinite value ...

Page 1048: ...seconds and 2 A value input to s1 is the TIME type data value A value input to s2 is the INT DINT or REAL type However input other than 0 to s2 Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO d DIV_TIME s1 s2 With EN ENO d DIV_TIME_E EN ENO s1 s2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 IN1 Input Inp...

Page 1049: ...e execution conditions and operation results 1 When FALSE is output from ENO data output from d is undefined In that case modify a program so that the data output from d is not used Operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE 1 Indefinite value Error code SD0 SD8067 Description 3400H A value input to ...

Page 1050: ...1048 26 TIME DATA FUNCTIONS 26 4 Division MEMO ...

Page 1051: ...1049 PART 6 PART 6 FUNCTION BLOCKS This part consists of the following chapters 27 BISTABLE FUNCTION BLOCKS 28 EDGE DETECTION FUNCTION BLOCKS 29 COUNTER FUNCTION BLOCKS 30 TIMER FUNCTION BLOCKS ...

Page 1052: ...is executed The operation output value is output from d Timing chart Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO SR_1 S1 s1 R s2 Q1 d With EN ENO SR_E_1 EN EN ENO ENO S1 s1 R s2 Q1 d Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 S1 Set instruction Input variable BOOL s2 R Reset instruction Input varia...

Page 1053: ...s Timing chart Operation error There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE Previous output value 1 When EN and s1 are on d is on 2 When EN s1 and s2 are on d is off ON ON ON ON ON EN OFF OFF ON OFF OFF OFF ON ON ON ON ON s1 OFF OFF ON ON s2 ENO OFF ON OFF OFF ON ON d 1 2 ...

Page 1054: ...on output value is output from d Timing chart Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO RS_1 S s1 R1 s2 Q1 d With EN ENO RS_E_1 EN EN ENO ENO S s1 R1 s2 Q1 d Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 S Set instruction Input variable BOOL s2 R1 Reset instruction Input variable BOOL ENO Output sta...

Page 1055: ...results Timing chart Operation error There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE Previous output value 1 When EN and s1 are on and s2 is off d turns on 2 When EN and s2 are on d turns off ON ON ON ON ON EN OFF ON ON s1 OFF OFF ON OFF ON s2 ENO OFF OFF ON OFF ON d 1 2 ...

Page 1056: ...executed The operation output value is output from d Timing chart Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO R_TRIG_1 CLK s Q d With EN ENO R_TRIG_E_1 EN EN ENO ENO CLK s Q d Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s CLK Rising edge detector input Input variable BOOL ENO Output status TRUE Normal ...

Page 1057: ...rror There is no operation error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE Previous output value 1 When EN is on and on the rising edge of s d turns on 2 At the next scan d turns off 3 When EN is off d holds the output of the previous scan ON ON ON ON EN OFF ON ON ON ON s OFF ENO OFF ON OFF ON OFF ON ON d 1 2 3 ...

Page 1058: ...eration output value is output from d Timing chart Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO F_TRIG_1 CLK s Q d With EN ENO F_TRIG_E_1 EN EN ENO ENO CLK s Q d Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s CLK Falling edge detector input Input variable BOOL ENO Output status TRUE Normal FALSE Abnormal...

Page 1059: ...ion error Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE Previous output value 1 When EN is on and on the falling edge of s d turns on 2 At the next scan d turns off 3 When EN is off d holds the output of the previous scan OFF ON ON ON ON ON EN OFF OFF ON OFF ON OFF ON OFF ON ON ON s OFF ON ON ON ON ON ENO OFF OFF ON OF...

Page 1060: ...en s2 is turned ON d1 turns OFF and d2 is set to 0 2 Count maximum value The effective setting range of n is from 0 to 32767 Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO CTU_1 CU s1 R s2 PV n Q d1 CV d2 With EN ENO CTU_E_1 EN EN ENO ENO CU s1 R s2 PV n Q d1 CV d2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable B...

Page 1061: ... error When 3 is specified in n 1 When s1 is on d2 counts up 2 When s2 is on d2 is cleared to 0 Execution condition Operation result EN ENO d1 d2 TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE Previous output value When 3 is specified in n 1 When EN and s1 are on d2 turns on 2 When s2 is on d2 is cleared to 0 OFF OFF ON OFF ON ON ON OFF ON OFF ON ON ON s1 OFF OFF O...

Page 1062: ...ns OFF and n is set for d2 2 Count start value The effective setting range of n is from 0 to 32767 Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO CTD_1 CD s1 LD s2 PV n Q d1 CV d2 With EN ENO CTD_E_1 EN EN ENO ENO CD s1 LD s2 PV n Q d1 CV d2 Argument Description Type Data type EN Execution condition TRUE Execution FALSE Stop Input variable BOOL s1 CD Count signal i...

Page 1063: ...itialized 2 On the rising edge of s1 d2 counts down Execution condition Operation result EN ENO d1 d2 TRUE Executes operation TRUE Operation output value FALSE Stops operation FALSE Previous output value When 3 is specified in n 1 When EN and s2 are on d2 is initialized 2 When EN is on at the rising edge of s1 d2 counts down OFF OFF ON OFF ON s1 OFF ON OFF ON OFF ON OFF ON OFF ON OFF ON OFF 3 0 3 ...

Page 1064: ...e of n is from 0 to 32767 4 Others When s1 and s2 are simultaneously turned ON from OFF s1 is prioritized and the function blocks count up add 1 to the value of d3 When s3 and s4 are simultaneously turned ON s3 is prioritized and the value of d3 is set to 0 Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO CTUD_1 CU s1 CD s2 R s3 LD s4 PV n QU d1 QD d2 CV d3 With EN E...

Page 1065: ...2 and d3 Timing chart When 3 is specified in n 1 When s1 turns on from off d3 counts up 2 When s3 turns on from off d3 is initialized 3 When s2 turns on from off d3 counts down 4 When s4 turns on from off d3 is initialized OFF OFF ON OFF ON OFF ON OFF ON OFF ON ON s1 OFF s2 OFF OFF ON s3 OFF OFF ON s4 OFF d1 OFF ON OFF ON OFF ON OFF ON OFF ON ON OFF 2 0 0 1 1 2 3 2 3 2 1 0 d2 d3 1 2 3 4 ...

Page 1066: ...tops operation FALSE Previous output value When 3 is specified in n 1 When EN is on and s1 turns on from off d3 is counts up 2 When EN is on and s3 turns on from off d3 is cleared to 0 3 When EN is on and s2 turns on from off d3 is counts down 4 When EN is on and s4 turns on from off d3 is initialized OFF ON ON ON ON ON EN OFF OFF ON s1 OFF OFF ON OFF ON s2 OFF OFF ON s3 OFF OFF ON OFF ON s4 OFF O...

Page 1067: ... can be specified for s3 However when a negative value is specified the initial value is set to 0 To reset the current value of the counter d1 reset s1 of FB directly Ex When the label name is TIMER_CONT_FB_M_1 Ladder diagram FBD LD Structured text COUNTER_FB_M_1 Coil s1 Preset s2 ValueIn s3 ValueOut d1 Status d2 Argument Description Type Data type s1 Coil Execution condition TRUE Execution FALSE ...

Page 1068: ...1066 29 COUNTER FUNCTION BLOCKS 29 4 Counter Function Block Operation error There is no error ...

Page 1069: ...ms For TP _E the output time value of n is set in units of 100 ms or more For TP_10 _E it is set in units of 10 ms or more The value of when d1 is turned on from off rising edge is used for the setting value of n If the value of n is changed while d1 is on the changed value becomes valid at the next output start Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO TP_1 I...

Page 1070: ...d Execution condition Operation result EN ENO d1 d2 TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred Indefinite value FALSE Stops operation FALSE Previous output value When T 5s 5 seconds is specified in n 1 When EN and s are on d1 turns on When EN and s are on the time measurement of d2 starts 2 After the time measurement starts the ...

Page 1071: ...r more For TON_10 _E it is set in units of 10 ms or more The value of when s is turned on from off rising edge is used for the setting value of n If the value of n is changed while s is on the changed value becomes valid on the next rising edge of s Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO TON_1 IN s PT n Q d1 ET d2 TON_10_1 IN s PT n Q d1 ET d2 With EN ENO T...

Page 1072: ...1 turns on 3 On the falling edge of s d2 is reset Execution condition Operation result EN ENO d1 d2 TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred Previous output value FALSE Stops operation FALSE Previous output value When T 5s 5 seconds is specified in n 1 When EN and s are on the time measurement of d2 starts 2 When d2 reaches th...

Page 1073: ... it is set in units of 10 ms or more The value of when s is turned on from off falling edge is used for the setting value of n If the value of n is changed while s is off the changed value becomes valid at the next falling edge of s Ladder diagram FBD LD Structured text Without EN ENO With EN ENO Without EN ENO TOF_1 IN s PT n Q d1 ET d2 TOF_10_1 IN s PT n Q d1 ET d2 With EN ENO TOF_E_1 EN EN ENO ...

Page 1074: ...d by n d1 turns off 3 When s is on d2 is reset Execution condition Operation result EN ENO d TRUE Executes operation TRUE Operation error did not occur Operation output value FALSE Operation error occurred Previous output value FALSE Stops operation FALSE Previous output value When T 5s 5 seconds is specified in n 1 When EN is on and s is off the time measurement of d2 starts 2 When EN and s are o...

Page 1075: ...cified the initial value is set to 0 Ex Ladder example Timing chart Ladder diagram FBD LD Structured text indicates TIMER_1_FB_M TIMER_10_FB_M TIMER_100_FB_M TIMER_CONT_FB_M TIMER_CONTHS_FB_M TIMER_1_FB_M_1 Coil s1 Preset s2 ValueIn s3 ValueOut d1 Status d2 TIMER_10_FB_M_1 Coil s1 Preset s2 ValueIn s3 ValueOut d1 Status d2 TIMER_100_FB_M_1 Coil s1 Preset s2 ValueIn s3 ValueOut d1 Status d2 TIMER_C...

Page 1076: ... Ladder example Timing chart TIMER_100_FB_M When the execution condition of s1 turns on counting the current value starts The timer starts counting from s3 100 ms When it counts up to s2 100 ms d2 turns on The current measurement value is output into d1 When the execution condition of s1 turns off the current value is reset to s3 and d2 turns off A value in the range of 0 to 32767 can be specified...

Page 1077: ... on off status of d1 and d2 is maintained even if the execution condition of s1 turns off When the execution condition of s1 turns on the timer resume counting from the measurement it holds A value in the range of 0 to 32767 can be specified for s2 A value in the range of 32768 to 32767 can be specified for s3 However when a negative value is specified the initial value is set to 0 To reset d1 of ...

Page 1078: ...OFF status s Remarks LD 0 034 AND 0 042 OUT 0 024 OUT T 0 509 0 317 OUT C 0 341 0 275 LD 0 042 LDD 0 042 0 059 0 017 In case of 2 operands 0 059 0 017 In case of 2 operands D 0 059 0 017 In case of 2 operands D 0 059 0 017 0 059 0 017 3 827 0 017 D 4 333 0 017 D 4 413 0 017 WAND 0 059 0 017 In case of 2 operands DAND 0 059 0 017 In case of 2 operands BCD 2 556 0 017 DBCD 2 931 0 017 BIN 2 381 0 01...

Page 1079: ...character string bit specification of word device nibble specification of bit devices indexing etc Instruction name Number of minimum steps LD 2 LDI 2 AND 2 ANI 2 OR 2 ORI 2 LDP 4 LDF 4 ANDP 4 ANDF 4 ORP 4 ORF 4 LDPI 4 LDFI 4 ANDPI 4 ANDFI 4 ORPI 4 ORFI 4 ANB 1 ORB 1 MPS 1 MRD 1 MPP 1 INV 1 MEP 3 MEF 3 OUT 2 OUT T ST 5 OUTH T ST 5 OUTHS T ST 5 OUT C 5 OUT LC 5 OUT F 3 SET 2 RST 2 SET F 3 RST F 3 A...

Page 1080: ...FL 4 DSFLP 4 SFTR 6 SFTRP 6 SFTL 6 SFTLP 6 WSFR 6 WSFRP 6 WSFL 6 WSFLP 6 MC 5 MCR 3 FEND 1 END 1 STOP 1 LD 4 LD 4 LD 4 LD 4 LD 4 LD 4 AND 4 AND 4 AND 4 AND 4 AND 4 AND 4 OR 4 OR 4 OR 4 OR 4 OR 4 OR 4 LD _U 4 LD _U 4 LD _U 4 LD _U 4 LD _U 4 LD _U 4 AND _U 4 AND _U 4 AND _U 4 AND _U 4 Instruction name Number of minimum steps ...

Page 1081: ...NDD 4 ANDD 4 ANDD 4 ANDD 4 ANDD 4 ANDD 4 ORD 4 ORD 4 ORD 4 ORD 4 ORD 4 ORD 4 LDD _U 4 LDD _U 4 LDD _U 4 LDD _U 4 LDD _U 4 LDD _U 4 ANDD _U 4 ANDD _U 4 ANDD _U 4 ANDD _U 4 ANDD _U 4 ANDD _U 4 ORD _U 4 ORD _U 4 ORD _U 4 ORD _U 4 ORD _U 4 ORD _U 4 CMP 5 CMPP 5 CMP_U 5 CMPP_U 5 DCMP 5 DCMPP 5 DCMP_U 5 DCMPP_U 5 ZCP 6 Instruction name Number of minimum steps ...

Page 1082: ...MP _U 6 BKCMP _U 6 BKCMP _U 6 BKCMP _U 6 BKCMP _U 6 BKCMP _U 6 BKCMP P_U 6 BKCMP P_U 6 BKCMP P_U 6 BKCMP P_U 6 BKCMP P_U 6 BKCMP P_U 6 DBKCMP 6 DBKCMP 6 DBKCMP 6 DBKCMP 6 DBKCMP 6 DBKCMP 6 DBKCMP P 6 DBKCMP P 6 DBKCMP P 6 DBKCMP P 6 DBKCMP P 6 DBKCMP P 6 DBKCMP _U 6 DBKCMP _U 6 DBKCMP _U 6 DBKCMP _U 6 DBKCMP _U 6 DBKCMP _U 6 DBKCMP P_U 6 DBKCMP P_U 6 DBKCMP P_U 6 DBKCMP P_U 6 Instruction name Numb...

Page 1083: ...2 d 5 P s1 s2 d 5 _U s d 5 P_U s d 5 _U s1 s2 d 5 P_U s1 s2 d 5 SUB 5 SUBP 5 SUB_U 5 SUBP_U 5 D s d 5 D P s d 5 D s1 s2 d 5 D P s1 s2 d 5 D _U s d 5 D P_U s d 5 D _U s1 s2 d 5 D P_U s1 s2 d 5 DADD 5 DADDP 5 DADD_U 5 DADDP_U 5 D s d 5 D P s d 5 D s1 s2 d 5 D P s1 s2 d 5 D _U s d 5 D P_U s d 5 D _U s1 s2 d 5 D P_U s1 s2 d 5 DSUB 5 DSUBP 5 DSUB_U 5 DSUBP_U 5 7 P 7 _U 7 Instruction name Number of mini...

Page 1084: ...MUL 7 DMULP 7 DMUL_U 7 DMULP_U 7 D 7 D P 7 D _U 7 D P_U 7 DDIV 7 DDIVP 7 DDIV_U 7 DDIVP_U 7 B s d 4 B P s d 4 B s1 s2 d 5 B P s1 s2 d 5 B s d 4 B P s d 4 B s1 s2 d 5 B P s1 s2 d 5 DB s d 4 DB P s d 4 DB s1 s2 d 5 DB P s1 s2 d 5 DB s d 4 DB P s d 4 DB s1 s2 d 5 DB P s1 s2 d 5 B 7 B P 7 B 7 B P 7 DB 7 DB P 7 DB 7 DB P 7 Instruction name Number of minimum steps ...

Page 1085: ...INCP_U 3 DEC 3 DECP 3 DEC_U 3 DECP_U 3 DINC 3 DINCP 3 DINC_U 3 DINCP_U 3 DDEC 3 DDECP 3 DDEC_U 3 DDECP_U 3 WAND s d 5 WANDP s d 5 WAND s1 s2 d 5 WANDP s1 s2 d 5 DAND s d 5 DANDP s d 5 DAND s1 s2 d 5 DANDP s1 s2 d 5 BKAND 6 BKANDP 6 WOR s d 5 WORP s d 5 WOR s1 s2 d 5 WORP s1 s2 d 5 DOR s d 5 DORP s d 5 DOR s1 s2 d 5 DORP s1 s2 d 5 BKOR 6 BKORP 6 WXOR s d 5 Instruction name Number of minimum steps ...

Page 1086: ...R s d 5 DXNRP s d 5 DXNR s1 s2 d 5 DXNRP s1 s2 d 5 BKXNR 6 BKXNRP 6 BSET 4 BSETP 4 BRST 4 BRSTP 4 TEST 5 TESTP 5 DTEST 5 DTESTP 5 BKRST 4 BKRSTP 4 ZRST 4 ZRSTP 4 BCD 4 BCDP 4 DBCD 4 DBCDP 4 BIN 4 BINP 4 DBIN 4 DBINP 4 FLT2INT 4 FLT2INTP 4 FLT2UINT 4 FLT2UINTP 4 FLT2DINT 4 FLT2DINTP 4 FLT2UDINT 4 FLT2UDINTP 4 INT2UINT 4 INT2UINTP 4 INT2DINT 4 INT2DINTP 4 INT2UDINT 4 INT2UDINTP 4 Instruction name Nu...

Page 1087: ... 4 UDINT2INTP 4 UDINT2UINT 4 UDINT2UINTP 4 UDINT2DINT 4 UDINT2DINTP 4 GRY 4 GRYP 4 GRY_U 4 GRYP_U 4 DGRY 4 DGRYP 4 DGRY_U 4 DGRYP_U 4 GBIN 4 GBINP 4 GBIN_U 4 GBINP_U 4 DGBIN 4 DGBINP 4 DGBIN_U 4 DGBINP_U 4 DABIN 4 DABINP 4 DABIN_U 4 DABINP_U 4 DDABIN 4 DDABINP 4 DDABIN_U 4 DDABINP_U 4 HEXA 5 HEXAP 5 VAL 5 VALP 5 VAL_U 5 VALP_U 5 DVAL 5 DVALP 5 DVAL_U 5 DVALP_U 5 NEG 3 Instruction name Number of mi...

Page 1088: ...I 5 UNIP 5 NDIS 5 NDISP 5 NUNI 5 NUNIP 5 WTOB 5 WTOBP 5 BTOW 5 BTOWP 5 DSW 6 MOV 4 MOVP 4 DMOV 4 DMOVP 4 CML 4 CMLP 4 DCML 4 DCMLP 4 SMOV 7 SMOVP 7 CMLB 4 CMLBP 4 BMOV 5 BMOVP 5 FMOV 5 FMOVP 5 DFMOV 5 DFMOVP 5 XCH 4 XCHP 4 DXCH 4 DXCHP 4 SWAP 3 SWAPP 3 DSWAP 3 DSWAPP 3 MOVB 4 MOVBP 4 PRUN 5 PRUNP 5 Instruction name Number of minimum steps ...

Page 1089: ... 4 ROL 4 ROLP 4 RCL 4 RCLP 4 DROL 4 DROLP 4 DRCL 4 DRCLP 4 CJ 3 CJP 3 GOEND 1 DI 1 DI s 3 EI 1 IMASK 3 SIMASK 5 IRET 1 WDT 1 WDTP 1 FOR 3 NEXT 1 BREAK 5 BREAKP 5 CALL 3 CALLP 3 RET 1 SRET 1 XCALL 3 SFRD 5 SFRDP 5 POP 5 POPP 5 SFWR 5 SFWRP 5 FINS 5 FINSP 5 FDEL 5 FDELP 5 S DEVLD 8 SP DEVLD 8 SP DEVST 10 Instruction name Number of minimum steps ...

Page 1090: ...4 OR 4 OR 4 OR 4 OR 4 OR 4 OR 4 s d 4 P s d 4 s1 s2 d 5 P s1 s2 d 5 MOV 4 MOVP 4 BINDA 4 BINDAP 4 BINDA_U 4 BINDAP_U 4 DBINDA 4 DBINDAP 4 DBINDA_U 4 DBINDAP_U 4 ASCI 5 ASCIP 5 STR 5 STRP 5 STR_U 5 STRP_U 5 DSTR 5 DSTRP 5 DSTR_U 5 DSTRP_U 5 ESTR 5 ESTRP 5 DESTR 5 DESTRP 5 LEN 4 LENP 4 RIGHT 5 RIGHTP 5 Instruction name Number of minimum steps ...

Page 1091: ...DE 4 LDE 4 LDE 4 LDE 4 LDE 4 LDE 4 ANDE 4 ANDE 4 ANDE 4 ANDE 4 ANDE 4 ANDE 4 ORE 4 ORE 4 ORE 4 ORE 4 ORE 4 ORE 4 DECMP 5 DECMPP 5 DEZCP 6 DEZCPP 6 E s d 4 E P s d 4 E s1 s2 d 5 E P s1 s2 d 5 DEADD 5 DEADDP 5 E s d 4 E P s d 4 E s1 s2 d 5 E P s1 s2 d 5 DESUB 5 DESUBP 5 E 5 E P 5 DEMUL 5 DEMULP 5 E 5 E P 5 DEDIV 5 Instruction name Number of minimum steps ...

Page 1092: ...4 DEVAL 4 DEVALP 4 DEBCD 4 DEBCDP 4 DEBIN 4 DEBINP 4 ENEG 3 ENEGP 3 DENEG 3 DENEGP 3 EMOV 4 EMOVP 4 DEMOV 4 DEMOVP 4 SIN 4 SINP 4 DSIN 4 DSINP 4 COS 4 COSP 4 DCOS 4 DCOSP 4 TAN 4 TANP 4 DTAN 4 DTANP 4 ASIN 4 ASINP 4 DASIN 4 DASINP 4 ACOS 4 ACOSP 4 DACOS 4 DACOSP 4 ATAN 4 ATANP 4 DATAN 4 DATANP 4 RAD 4 RADP 4 DRAD 4 DRADP 4 Instruction name Number of minimum steps ...

Page 1093: ... 5 POWP 5 LOG10 4 LOG10P 4 DLOG10 4 DLOG10P 4 EMAX 5 EMAXP 5 EMIN 5 EMINP 5 RND 3 RNDP 3 ZPUSH d 3 ZPUSHP d 3 ZPUSH s d 4 ZPUSHP s d 4 ZPOP d 3 ZPOPP d 3 ZPOP s d 4 ZPOPP s d 4 LIMIT 6 LIMITP 6 LIMIT_U 6 LIMITP_U 6 DLIMIT 6 DLIMITP 6 DLIMIT_U 6 DLIMITP_U 6 BAND 6 BANDP 6 BAND_U 6 BANDP_U 6 DBAND 6 DBANDP 6 DBAND_U 6 DBANDP_U 6 ZONE 6 Instruction name Number of minimum steps ...

Page 1094: ...CLP 5 DSCL_U 5 DSCLP_U 5 SCL2 5 SCL2P 5 SCL2_U 5 SCL2P_U 5 DSCL2 5 DSCL2P 5 DSCL2_U 5 DSCL2P_U 5 TTMR 4 STMR 7 UDCNTF 5 ROTC 6 RAMPF 6 SPD 5 DSPD 5 PLSY 5 DPLSY 5 PWM 5 DPWM 5 MTR 6 IST 7 ABSD 9 DABSD 9 INCD 9 CCD 5 CCDP 5 SERMM 6 SERMMP 6 DSERMM 6 DSERMMP 6 SUM 4 SUMP 4 DSUM 4 DSUMP 4 BON 5 BONP 5 DBON 5 DBONP 5 Instruction name Number of minimum steps ...

Page 1095: ...P_U 5 SORTTBL 7 SORTTBL_U 7 SORTTBL2 7 SORTTBL2_U 7 DSORTTBL2 7 DSORTTBL2_U 7 WSUM 7 WSUMP 7 WSUM_U 7 WSUMP_U 7 DWSUM 7 DWSUMP 7 DWSUM_U 7 DWSUMP_U 7 MEAN 5 MEANP 5 MEAN_U 5 MEANP_U 5 DMEAN 5 DMEANP 5 DMEAN_U 5 DMEANP_U 5 SQRT 4 SQRTP 4 DSQRT 4 DSQRTP 4 CRC 5 CRCP 5 ADRSET 4 ADRSETP 4 TRD 3 TRDP 3 TWR 3 TWRP 3 TADD 5 TADDP 5 TSUB 5 Instruction name Number of minimum steps ...

Page 1096: ...LDDT 5 LDDT 5 LDDT 5 ANDDT 5 ANDDT 5 ANDDT 5 ANDDT 5 ANDDT 5 ANDDT 5 ORDT 5 ORDT 5 ORDT 5 ORDT 5 ORDT 5 ORDT 5 LDTM 5 LDTM 5 LDTM 5 LDTM 5 LDTM 5 LDTM 5 ANDTM 5 ANDTM 5 ANDTM 5 ANDTM 5 ANDTM 5 ANDTM 5 ORTM 5 ORTM 5 ORTM 5 ORTM 5 ORTM 5 ORTM 5 TCMP 7 TCMPP 7 TZCP 6 TZCPP 6 DUTY 5 HOURM 5 DHOURM 5 REF 4 Instruction name Number of minimum steps ...

Page 1097: ... 3 LOGTRGR 3 RTM 2 STL 3 RETSTL 1 SP SOCOPEN 10 SP SOCCLOSE 10 SP SOCRCV 12 SP SOCSND 12 SP SOCCINF 10 S SOCRDATA 12 SP SOCRDATA 12 SP ECPRTCL 7 SP SLMPSND 13 PID 6 GP READ 19 GP SREAD 23 GP WRITE 20 GP SWRITE 23 GP SEND 16 GP RECV 16 G CCPASET 22 GP CCPASET 22 G UINI 14 GP UINI 14 DHSCS 5 DHSCR 5 DHSZ 6 HIOEN 5 HIOENP 5 DHIOEN 5 DHIOENP 5 HCMOV 5 HCMOVP 5 Instruction name Number of minimum steps ...

Page 1098: ...R 7 IVRD 7 IVWR 7 IVBWR 7 IVMC 13 ADPRW 13 S CPRTCL 7 SP CPRTCL 7 DSZR 6 DDSZR 6 DVIT 6 DDVIT 6 TBL 4 DRVTBL 7 DRVMUL 13 DABS 5 PLSV 5 DPLSV 5 DRVI 6 DDRVI 6 DRVA 6 DDRVA 6 G ABRST 15 GP PSTRT 15 GP TEACH 15 GP PFWRT 15 GP PINIT 15 RBFM 7 WBFM 7 Instruction name Number of minimum steps ...

Page 1099: ...e 1 007H and above Page 762 PID The ESQRT P instruction is supported 1 015 and above 1 015R and above Page 531 DESQR P ESQRT P The number of settable high speed comparison tables was changed from maximum 4 to 32 1 015 and above 1 1 015R and above Page 810 HIOEN P Page 813 DHIOEN P The number of high speed comparisons was changed from 4 to 32 1 015 and above 1 1 015R and above Page 810 HIOEN P Page...

Page 1100: ...DDT_GT 702 ANDDT_LE 702 ANDDT_LT 702 ANDDT_NE 702 ANDE 476 ANDE 476 ANDE 476 ANDE 476 ANDE 476 ANDE 476 ANDE_EQ 476 ANDE_GE 476 ANDE_GT 476 ANDE_LE 476 ANDE_LT 476 ANDE_NE 476 AND_EQ _U 165 ANDF 106 ANDFI 108 AND_GE _U 165 AND_GT _U 165 AND_LE _U 165 AND_LT _U 165 AND_NE _U 165 ANDP 106 ANDPI 108 ANDSTRING_EQ 431 ANDSTRING_GE 431 ANDSTRING_GT 431 ANDSTRING_LE 431 ANDSTRING_LT 431 ANDSTRING_NE 431 ...

Page 1101: ...TUD _E 1062 D D P _U 199 201 D P _U 213 D P _U 217 D P _U 194 195 DABIN P _U 310 DABS 859 DABSD 639 DACOS P 523 DADD P _U 197 DAND P 251 252 DASIN P 521 DATAN P 525 DB P 227 228 DB P 232 DB P 234 DB P 225 226 DBAND P _U 558 DBCD P 284 DBDIVISION P 234 DBIN P 288 DBINDA P _U 442 DBK P _U 243 DBK P _U 240 DBKCMP P _U 179 DBKCMP P _U 179 DBKCMP P _U 179 DBKCMP P _U 179 DBKCMP P _U 179 DBKCMP P _U 179...

Page 1102: ...WM 618 DRAD P 527 DRCL P 379 DRCR P 377 DROL P 379 DROR P 377 DRVA 873 875 DRVI 865 867 DRVMUL 857 DRVTBL 855 DSCL P _U 567 DSCL2 P _U 573 DSERMM P 648 DSFL P 148 DSFR P 147 DSIN P 515 DSORTTBL2 _U 670 DSPD 592 DSQRT P 681 DSTOH P 700 DSTR P _U 450 DSUB P _U 203 DSUM P 651 DSW 345 DSWAP P 363 DSZR 841 843 DTAN P 519 DTEST P 277 DTO P 722 723 DTOD P 728 729 DUTY 712 DVAL P _U 321 DVIT 847 849 DWORD...

Page 1103: ... GT _E 1020 H HCMOV P 816 HEXA P 314 HIOEN P 810 HOURM 714 HTOS P 694 I IMASK 390 INC P _U 245 INCD 641 INSERT _E 1031 INSTR P 470 INT2DINT P 295 INT2FLT P 502 INT2UDINT P 296 INT2UINT P 294 INT_TO_BCD _E 922 INT_TO_BITARR _E 967 INT_TO_BOOL _E 918 INT_TO_DINT _E 921 INT_TO_DWORD _E 920 INT_TO_REAL _E 924 INT_TO_STRING _E 926 INT_TO_TIME _E 925 INT_TO_WORD _E 919 INV 112 IRET 393 IST 627 IVBWR 830...

Page 1104: ...GR 733 LT _E 1020 M MAX _E 1014 MAX P _U 656 MC 157 MCR 157 MEAN P _U 676 MEF 113 MEP 113 MID _E 1027 MIDR P 464 MIDW P 467 MIN _E 1014 MIN P _U 660 MINUS P _U 188 190 MOD _E 995 MOV P 347 MOVB P 364 MOVE _E 999 MPP 111 MPS 111 MRD 111 MTR 624 MUL _E 989 MUL P _U 207 MULTI P _U 205 MUL_TIME _E 1044 MUX _E 1018 N NDIS P 337 NE _E 1022 NEG P 324 NEXT 395 NOT _E 1011 NUNI P 339 O OR 104 OR _E 1009 OR...

Page 1105: ...ID 762 PLF 134 PLS 132 PLSV 861 862 PLSY 596 600 PLUS P _U 182 184 POP P 408 POW P 537 PRUN P 365 PWM 612 R RAD P 527 RAMPF 585 RBFM 894 RCL P 374 RCR P 371 REAL_TO_DINT _E 945 REAL_TO_INT _E 943 REAL_TO_STRING _E 947 REF P 718 REPLACE _E 1035 RET 403 RETSTL 735 RFS P 718 RIGHT _E 1025 RIGHT P 460 RND P 545 ROL _E 1005 ROL P 374 ROR _E 1007 ROR P 371 ROTC 582 RS _E 1052 RS2 820 RST 123 127 RST F 1...

Page 1106: ... TIMER_1_FB_M 1073 TIMER_CONT_FB_M 1073 TIMER_CONTHS_FB_M 1073 TIME_TO_BOOL _E 950 TIME_TO_DINT _E 954 TIME_TO_DWORD _E 952 TIME_TO_INT _E 953 TIME_TO_STRING _E 955 TIME_TO_WORD _E 951 TO P 722 723 TOD P 728 729 TOF _E 1071 TOF_10 _E 1071 TON _E 1069 TON_10 _E 1069 TP _E 1067 TP_10 _E 1067 TRD P 686 TSUB P 692 TTMR 576 TWR P 688 TZCP P 710 U UDCNTF 580 UDINT2DINT P 305 UDINT2FLT P 505 UDINT2INT P ...

Page 1107: ...I 1105 MEMO ...

Page 1108: ...LEVANT MANUALS TERMS Section 4 1 4 2 8 2 8 15 8 24 Chapter 12 13 14 16 October 2016 G Added or modified parts TEAMS 3 3 3 5 6 3 8 25 10 3 10 4 14 1 Appendix 2 3 April 2017 H Added or modified parts RELEVANT MANUALS TERM Section 4 6 Chapter 6 7 8 10 11 12 13 14 15 16 17 24 30 Appendix 2 3 October 2017 J Added or modified parts RELEVANT MANUALS TERM Section 3 3 7 7 8 6 8 7 8 28 10 2 14 1 23 2 23 3 C...

Page 1109: ...ations in which the public could be affected such as in nuclear power plants and other power plants operated by respective power companies and applications in which a special quality assurance system is required such as for railway companies or public service purposes shall be excluded from the programmable controller applications In addition applications in which human life or property that could...

Page 1110: ...and or other countries Ethernet is a trademark of Xerox Corporation Anywire and ANYWIREASLINK is a registered trademark of the Anywire Corporation MODBUS is a registered trademark of Schneider Electric SA The company name and the product name to be described in this manual are the registered trademarks or trademarks of each company ...

Page 1111: ......

Page 1112: ...10 JAPAN Specifications are subject to change without notice When exported from Japan this manual does not require application to the Ministry of Economy Trade and Industry for service transaction permission Manual number JY997D55801J Model FX5 P MF E Model code 09R539 ...

Reviews: