Wiki source code of 06 Instructions

Version 10.1 by Theodore Xu on 2024/06/06 09:50

Hide last authors
Mora Zhou 8.1 1 = **Basic program instructions** =
Stone Wu 5.1 2
3 |**Instruction type**|**Instruction**|**Description**|(((
4 **LX3V(1S)**
5 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
6 |(% rowspan="25" %)[[Basic instructions>>path:/wiki/plc/view/2-User%20manual/6.Instruction/01.Basic%20instruction/]]|LD|Operation contact type NO (normally open)|¡|¡|¡|¡
7 |LDI|Operation contact type NC (normally closed)|¡|¡|¡|¡
8 |OUT|Final logical operation type coil drive|¡|¡|¡|¡
9 |AND|Serial connection of NO(normally open)|¡|¡|¡|¡
10 |ANI|Serial logical, operation contact type NC(normally closed) contacts|¡|¡|¡|¡
11 |OR|Parallel, connection of NO (normally open) contacts|¡|¡|¡|¡
12 |ORI|Parallel, connection of NC (normally closed) contacts|¡|¡|¡|¡
13 |LDP|Initial logical, operation -Rising edge pulse|¡|¡|¡|¡
14 |LDF|Initial logical, operation falling/trailing edge pulse|¡|¡|¡|¡
15 |ANDP|Serial connection of Rising edge pulse|¡|¡|¡|¡
16 |ANDF|Serial connection of falling/ trailing edge pulse|¡|¡|¡|¡
17 |ORP|Parallel, connection of NO Rising edge pulse|¡|¡|¡|¡
18 |ORF|Parallel connection of Falling/trailing edge pulse|¡|¡|¡|¡
19 |ORB|Serial connection of multiple parallel circuits|¡|¡|¡|¡
20 |ANB|Serial connection of multiple parallel circuits|¡|¡|¡|¡
21 |MPS|Stores the current result of the internal PLC operations|¡|¡|¡|¡
22 |MRD|Reads the current result of the internal PLC operations|¡|¡|¡|¡
23 |MPP|Pops (recalls and removes) the currently stored result|¡|¡|¡|¡
24 |MC|Denotes the start of a master control block|¡|¡|¡|¡
25 |MCR|Denotes the end of a master control block|¡|¡|¡|¡
26 |INV|Invert the current result of the internal PLC operations|¡|¡|¡|¡
27 |PLS|Rising edge pulse|¡|¡|¡|¡
28 |PLF|Falling / trailing edge pulse|¡|¡|¡|¡
29 |SET|Sets a bit device permanently ON|¡|¡|¡|¡
30 |RST|Resets a bit device permanently OFF|¡|¡|¡|¡
31
Mora Zhou 8.1 32 = **Step ladder instructions** =
Stone Wu 5.1 33
34 |**Instruction type**|**Instruction**|**Description**|(((
35 **LX3V**
36
37 **(1S)**
38 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
39 |(% rowspan="2" %)[[Step ladder instructions>>path:/wiki/plc/view/2-User%20manual/6.Instruction/17.Step%20control%20instructions/]]|STL|STL programming start instruction|¡|¡|¡|¡
40 |RET|STL programming end instruction|¡|¡|¡|¡
41
Mora Zhou 8.1 42 = **Program Flow instructions** =
Stone Wu 5.1 43
44 |**Instruction type**|**Instruction**|**Description**|(((
45 **LX3V**
46
47 **(1S)**
48 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
49 |(% rowspan="7" %)[[Program flow instructions>>path:/wiki/plc/view/2-User%20manual/6.Instruction/02.Program%20flow/]]|CJ|Conditional jump|¡|¡|¡|¡
50 |CALL|Call Subroutine|¡|¡|¡|¡
51 |EI|Enable Interrupt|¡|¡|¡|¡
52 |DI|Disable Interrupt|¡|¡|¡|¡
53 |WDT|Watchdog Timer|¡|¡|¡|¡
54 |FOR|Start of a For/Next Loop|¡|¡|¡|¡
55 |NEXT|End a For/Next Loop|¡|¡|¡|¡
56
Mora Zhou 8.1 57 = **Move and Compare instructions** =
Stone Wu 5.1 58
59 |**Instruction type**|**Instruction**|**Description**|(((
60 **LX3V**
61
62 **(1S)**
63 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
64 |(% rowspan="10" %)[[Move and Compare instructions>>path:/wiki/plc/view/2-User%20manual/6.Instruction/03.Move%20and%20campare/]]|CMP|Compare |¡|¡|¡|¡
65 |ZCP|Zone compare|¡|¡|¡|¡
66 |MOV|Move |¡|¡|¡|¡
67 |SMOV|Shift move|-|¡|¡|¡
68 |CML|Compliment |-|¡|¡|¡
69 |BMOV|Block move|¡|¡|¡|¡
70 |FMOV|Fill move|-|¡|¡|¡
71 |XCH|Exchange |-|¡|¡|¡
72 |BCD|Binary coded decimal|¡|¡|¡|¡
73 |BIN|Binary |¡|¡|¡|¡
74
Mora Zhou 8.1 75 = **Arithmetic and Logical Operations instructions** =
Stone Wu 5.1 76
77 |**Instruction type**|**Instruction**|**Description**|(((
78 **LX3V**
79
80 **(1S)**
81 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
82 |(% rowspan="10" %)[[Arithmetic and Logical Operations instructions>>path:/wiki/plc/view/2-User%20manual/6.Instruction/06.Arithmetic%20and%20logical%20operations/]]|ADD|Addition |¡|¡|¡|¡
83 |SUB|Subtraction |¡|¡|¡|¡
84 |MUL|Multiplication |¡|¡|¡|¡
85 |DIV|Division |¡|¡|¡|¡
86 |INC|Increment|¡|¡|¡|¡
87 |DEC|Decrement|¡|¡|¡|¡
88 |WAND|Word AND|¡|¡|¡|¡
89 |WOR|Word OR|¡|¡|¡|¡
90 |WXOR|Word exclusive OR|¡|¡|¡|¡
91 |NEG|Negation |-|¡|¡|¡
92
Mora Zhou 8.1 93 = **Rotation and Shift instructions** =
Stone Wu 5.1 94
95 |**Instruction type**|**Instruction**|**Description**|(((
96 **LX3V**
97
98 **(1S)**
99 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
100 |(% rowspan="10" %)[[Rotation and Shift instructions>>path:/wiki/plc/view/2-User%20manual/6.Instruction/08.Rotation%20and%20shift/]]|ROR|Rotation right|¡|¡|¡|¡
101 |ROL|Rotation left|¡|¡|¡|¡
102 |RCR|16-bit rotation right with carry|-|¡|¡|¡
103 |RCL|16-bit rotation left with carry|-|¡|¡|¡
104 |SFTR|(bit) shift right|¡|¡|¡|¡
105 |SFTL|(bit) shift left|¡|¡|¡|¡
106 |WSFR|word shift right|-|¡|¡|¡
107 |WSFL|word shift left|-|¡|¡|¡
108 |SFWR|shift register write|¡|¡|¡|¡
109 |SFRD|shift register read|¡|¡|¡|¡
110
Mora Zhou 8.1 111 = **Data operation instructions** =
Stone Wu 5.1 112
113 |**Instruction type**|**Instruction**|**Description**|(((
114 **LX3V**
115
116 **(1S)**
117 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
118 |(% rowspan="11" %)[[Data operation instructions>>path:/wiki/plc/view/2-User%20manual/6.Instruction/04.Data%20operation/]]|ZRST|Zone reset|¡|¡|¡|¡
119 |DECO|Decode |¡|¡|¡|¡
120 |ENCO|Encode |¡|¡|¡|¡
121 |SUM|The sum of active bits|-|¡|¡|¡
122 |BON|Check specified bit status|-|¡|¡|¡
123 |MEAN|Mean |-|¡|¡|¡
124 |ANS|(timed) annunciator set|-|¡|¡|¡
125 |ANR|Annunciator reset|-|¡|¡|¡
126 |SQR|Square root|-|¡|¡|¡
127 |FLT|Float |-|¡|¡|¡
128 |SWAP|High and low bit conversion|-|¡|¡|¡
129
Mora Zhou 8.1 130 = **High-speed Processing Instructions** =
Stone Wu 5.1 131
132 |**Instruction type**|**Instruction**|**Description**|(((
133 **LX3V**
134
135 **(1S)**
136 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
137 |(% rowspan="10" %)[[High-speed Processing Instruction>>path:/wiki/plc/view/2-User%20manual/6.Instruction/07.High%20speed%20process/]]|REF|Refresh|¡|¡|¡|¡
138 |REFF|Refresh and filter adjust|-|¡|¡|¡
139 |MTR|Input matrix|¡|¡|¡|¡
140 |DHSCR|High speed counter set|¡|¡|¡|¡
141 |DHSCS|High speed counter reset|¡|¡|¡|¡
142 |DHSZ|High speed counter zone compare|-|¡|¡|¡
143 |SPD|Speed detect|¡|¡|¡|¡
144 |PLSY|16-bit pulse Y output|¡|¡|¡|¡
145 |PWM|Pulse width modulation|¡|¡|¡|¡
146 |PLSR|Ramp pulse output|¡|¡|¡|¡
147
Mora Zhou 8.1 148 = **ECAM instructions** =
Stone Wu 5.1 149
150 |**Instruction type**|**Instruction**|**Description**|(((
151 **LX3V**
152
153 **(1S)**
154 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
155 |(% rowspan="3" %)[[ECAM instruction>>path:/wiki/plc/view/2-User%20manual/6.Instruction/10.ECAM/]]|DECAM|ECAM configuration|-|-|-|¡
156 |DEGEAR|Electronic gear configuration|-|-|-|¡
157 |ECAMTBX|Create E-CAM datasheet|-|-|-|¡
158
Mora Zhou 8.1 159 = **External I/O Devices instructions** =
Stone Wu 5.1 160
161 |**Instruction type**|**Instruction**|**Description**|(((
162 **LX3V**
163
164 **(1S)**
165 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
Theodore Xu 10.1 166 |(% rowspan="12" %)[[External I/O device instruction>>path:https://docs.we-con.com.cn/bin/view/PLC%20Editor/6.Instruction/09.External%20IO%20Devices/]]|TKY|Ten key input|-|¡|¡|¡
Stone Wu 5.1 167 |HKY|Hexadecimal input|-|¡|¡|¡
168 |DSW|Digital switch (thumbwheel input)|¡|¡|¡|¡
169 |SEGD|Seven segment decoder|-|¡|¡|¡
170 |SEGL|Seven segment with latch|¡|¡|¡|¡
171 |ARWS|Arrow switch|-|¡|¡|¡
172 |ASC|ASCII code|-|¡|¡|¡
173 |PR|“print” to a display|-|¡|¡|¡
174 |FROM|Read from a special function block|¡|¡|¡|¡
175 |TO|Write to a special function block|¡|¡|¡|¡
176 |GRY|Converts binary integer to GRAY code|-|¡|¡|¡
177 |GBIN|Converts GRAY CODE to binary|-|¡|¡|¡
178
Mora Zhou 8.1 179 = **External Devices instructions** =
Stone Wu 5.1 180
181 |**Instruction type**|**Instruction**|**Description**|(((
182 **LX3V**
183
184 **(1S)**
185 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
Theodore Xu 9.1 186 |(% rowspan="9" %)[[External devices instruction>>path:https://docs.we-con.com.cn/bin/view/PLC%20Editor/6.Instruction/13.External%20Device%20SER%20instruction/]]|RS|RS communications|¡|¡|¡|¡
Stone Wu 5.1 187 |RS2|RS2 communications|¡|¡|¡|¡
188 |CPAVL|Serial port settings|¡|¡|¡|¡
189 |CPAVL|Ethernet port settings|¡|¡|¡|¡
190 |PRUN|Octal bit transmission|¡|¡|¡|¡
191 |ASCI|hexadecimal to ASCII|¡|¡|¡|¡
192 |HEX|ASCII to hexadecimal|¡|¡|¡|¡
193 |CCD|check code|¡|¡|¡|¡
194 |PID|PID control loop|¡|¡|¡|¡
195
Mora Zhou 8.1 196 = **Floating Point instructions** =
Stone Wu 5.1 197
198 |**Instruction type**|**Instruction**|**Description**|(((
199 **LX3V**
200
201 **(1S)**
202 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
203 |(% rowspan="22" %)[[Floating point instruction>>path:/wiki/plc/view/2-User%20manual/6.Instruction/14.Floating%20calculation/]]|DECMP|Binary floating point data compare|-|¡|¡|¡
204 |DEZCP|Binary floating point zone compare|-|¡|¡|¡
205 |DEBCD|Binary to BCD floating point data conversion|-|¡|¡|¡
206 |DEBIN|BCD to Binary floating point data conversion|-|¡|¡|¡
207 |DEADD|Binary floating point addition|-|¡|¡|¡
208 |DESUB|Binary floating point subtraction|-|¡|¡|¡
209 |DEMUL|Binary floating point multiplication|-|¡|¡|¡
210 |DEDIV|Binary floating point division|-|¡|¡|¡
211 |DESQR|Binary floating point square root|-|¡|¡|¡
212 |INT|16-bit binary floating point to integer|-|¡|¡|¡
213 |DSIN|Sin operation|-|¡|¡|¡
214 |DCOS|Cosine operation|-|¡|¡|¡
215 |DTAN|Tangent operation|-|¡|¡|¡
216 |DASIN|Calculate radian value, according to the corresponding value of SIN|-|-|¡|¡
217 |DSINH|Binary floating point operation of Hyperbolic Sine function SINH|-|-|¡|¡
218 |DACOS|Calculate radian value, according to the corresponding value of COS|-|-|¡|¡
219 |DCOSH|Binary floating point operation of Hyperbolic Cosine function COSH|-|-|¡|¡
220 |DATAN|Calculate radian value, according to the corresponding value of TAN|-|-|¡|¡
221 |DTANH|Binary floating point operation of Hyperbolic Tangent function TANH|-|-|¡|¡
222 |DEXP|Perform exponent operation of binary floating-point number to base e (2.71828)|-|-|¡|¡
223 |DLOG10|Perform common logarithm operation of binary floating-point number to base 10|-|-|¡|¡
224 |DLOGE|Perform natural logarithm operation of binary floating-point number to base e (2.71828)|-|-|¡|¡
225
Mora Zhou 8.1 226 = **Positioning Instructions** =
Stone Wu 5.1 227
228 |**Instruction type**|**Instruction**|**Description**|(((
229 **LX3V**
230
231 **(1S)**
232 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
233 |(% rowspan="5" %)[[Positioning instruction>>path:/wiki/plc/view/2-User%20manual/6.Instruction/12.Positioning%20control/]]|DABS|Absolute current value read|¡|¡|¡|¡
234 |ZRN|Setting of zero return speed|¡|¡|¡|¡
235 |PLSV|Variable speed pulse output|¡|¡|¡|¡
236 |DRVI|Relative position control|¡|¡|¡|¡
237 |DRVA|Absolute position control|¡|¡|¡|¡
238
239 **4.14 Real Time Clock Control**
240
241 |**Instruction type**|**Instruction**|**Description**|(((
242 **LX3V**
243
244 **(1S)**
245 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
246 |(% rowspan="7" %)[[Real time clock control>>path:/wiki/plc/view/2-User%20manual/6.Instruction/05.Real%20time%20clock/]]|TCMP|time compare|¡|¡|¡|¡
247 |TZCP|time zone compare|¡|¡|¡|¡
248 |TADD|time addition|¡|¡|¡|¡
249 |TSUB|time subtraction|¡|¡|¡|¡
250 |TRD|read RTC data|¡|¡|¡|¡
251 |TWR|set RTC data|¡|¡|¡|¡
252 |HOUR|16-bit chronograph|¡|¡|¡|¡
253
Mora Zhou 8.1 254 = **Handy Instructions** =
Stone Wu 5.1 255
256 |**Instruction type**|**Instruction**|**Description**|(((
257 **LX3V(1S)**
258 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
259 |(% rowspan="10" %)[[Handy instruction>>path:/wiki/plc/view/2-User%20manual/6.Instruction/11.Handy%20instructions/]]|IST|initial state|¡|¡|¡|¡
260 |SER|Search |-|¡|¡|¡
261 |ABSD|Absolute drum|¡|¡|¡|¡
262 |INCD|Incremental drum|¡|¡|¡|¡
263 |TTMR|Teaching timer|-|¡|¡|¡
264 |STMR|Special timer - definable|-|¡|¡|¡
265 |ALT|Alternate state|¡|¡|¡|¡
266 |RAMP|Ramp - variable value|¡|¡|¡|¡
267 |ROTC|Rotary table control|-|¡|¡|¡
268 |SORT|Sort data|-|¡|¡|¡
269
Mora Zhou 8.1 270 = **Circular interpolation instructions** =
Stone Wu 5.1 271
272 |**Instruction type**|**Instruction**|**Decryption**|**LX3V**|**LX3VP**|**LX3VE**|**LX3VM**
273 |(% rowspan="6" %)[[Circular interpolation instruction>>path:/wiki/plc/view/2-User%20manual/6.Instruction/15.Circular%20interpolation%20instruction/]]|G90G01|Absolute position line interpolation|-|-|-|¡
274 |G91G01|Relative position line interpolation|-|-|-|¡
275 |G90G02|Absolute position of the clockwise circular interpolation|-|-|-|¡
276 |G91G02|Relative position clockwise circular interpolation|-|-|-|¡
277 |G90G03|Absolute position anticlockwise circular interpolation|-|-|-|¡
278 |G91G03|Relative position anticlockwise circular interpolation|-|-|-|¡
279
Mora Zhou 8.1 280 = **Inline Comparisons Instructions** =
Stone Wu 5.1 281
282 |**Instruction type**|**Instruction**|**Description**|(((
283 **LX3V**
284
285 **(1S)**
286 )))|**LX3V (2N)**|**LX3VP**|**LX3VE**
287 |(% rowspan="19" %)Inline comparisons instruction|LD=|Comparison of 16-bit data (==)|¡|¡|¡|¡
288 |LD>|Comparison of 16-bit data (>|¡|¡|¡|¡
289 |LD<|Comparison of 16-bit data (<|¡|¡|¡|¡
290 |LD<>|Comparison of 16-bit data (<>|¡|¡|¡|¡
291 |LD<=|Comparison of 16-bit data (<=)|¡|¡|¡|¡
292 |LD>=|Comparison of 16-bit data (>=)|¡|¡|¡|¡
293 |AND=|Comparison of 16-bit data (==)|¡|¡|¡|¡
294 |AND>|Comparison of 16-bit data (>|¡|¡|¡|¡
295 |AND<|Comparison of 16-bit data (<|¡|¡|¡|¡
296 |AND<>|Comparison of 16-bit data (<>|¡|¡|¡|¡
297 |AND<=|Comparison of 16-bit data (<=)|¡|¡|¡|¡
298 |AND>=|Comparison of 16-bit data (>=)|¡|¡|¡|¡
299 |OR=|Comparison of 16-bit data (==)|¡|¡|¡|¡
300 |ORD=|Comparison of 32-bit data (==)|¡|¡|¡|¡
301 |OR>|Comparison of 16-bit data (>|¡|¡|¡|¡
302 |OR<|Comparison of 16-bit data (<|¡|¡|¡|¡
303 |OR<>|Comparison of 16-bit data (<>|¡|¡|¡|¡
304 |OR<=|Comparison of 16-bit data (<=)|¡|¡|¡|¡
305 |OR>=|Comparison of 16-bit data (>=)|¡|¡|¡|¡