EasyManua.ls Logo

Eaton ELC-PB - Page 193

Eaton ELC-PB
728 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
ELC Programming Manual
For more information visit: www.eaton.com MN05003003E
3-24
the most significant bit of (D1, D0) is the sign bit.
The range of decimal numbers is from ±1175×10
-41
to ±3402×10
+35
.
3. Decimal floating point can be used in the following instructions.
The conversion instruction for Binary floating point Æ Decimal floating point (DEBCD)
The conversion instruction for Decimal floating point Æ Binary floating point (DEBIN)
4. Zero flag (M1020), Borrow flag (M1021) and carry flag (M1022). The flags that correspond to
the floating point instructions are:
a) Zero flag: when the result is 0, M1020=ON.
b) Borrow flag: when a borrow is generated, M1021=ON
c) Carry flag: when the absolute value of result exceeds usage range, M1022=ON
Index register E, F
The index registers are 16-bit registers. There are 2 index registers for ELC-PB, ELCB-PB models
(E and F), 8 for ELC-PC/PA/PH models (E0~E3, F0~F3), and 16 for ELCM-PH/PA, ELC-PV models
(E0 ~ E7 and F0 ~ F7).
E and F are also 16-bit registers just the same as D-registers.
They are read /write registers.
When using a 32-bit index register, the combination of E, F
are as follows. (E0, F0), (E1, F1), (E2, F2), (E3, F3), (E4, F4),
(E5, F5), (E6, F6), (E7, F7).
F0
E0
E0
F0
16-bit
16-bit
32-bit
Lower wordUpper word
If using a 32-bit register, you must specify an E index register. In this case, the specified E register is
used and its corresponding F register is also used (When the ELC starts-up, it is recommended to
use the MOVP instruction to clear the contents of F and reset it to 0)
As the right figure shows, the addresses will change
based the contents of E, F. This is called “Index”
addressing.
For example, if E0=8 then D20E0 represents
address D (20+8). When F0=14, the destination
address becomes D24.
E0=8 F0=14
20+8=28 10+14=24
D28 D24
M1000
D20E0 D10F0MOV
Data types supported in ELC-PB, ELCB-PB series: P, X, Y, M, S, KnX, KnY, KnM, KnS, T, C, D.
Data types supported in ELC-PC/PA/PH, ELCM-PH/PA series: P, X, Y, M, S, KnX, KnY, KnM, KnS, T,
C, D.
Data types supported in ELC-PV series: P, I, X, Y, M, S, K, H, KnX, KnY, KnM, KnS, T, C, D.
If E and F are used with a constant value, use @ between the K or H value and the E or F index
register. For example: "MOV K10@E0 D0F0”

Related product manuals