Ldi/Tdi: Loading To Or Transferring From A 32-Bit Memory Area Indirectly - Siemens CPU 948 Programming Manual

Simatic s5 s5-155u
Table of Contents

Advertisement

9.2.3
LDI/TDI: Loading to or
Transferring from a 32-Bit
Memory Area Indirectly
Byte addresses
Data storage with LDI/TDI
CPU 948 Programming Guide
C79000-G8576-C848-04
The following table shows which register names you can use on the
CPU 948 for the LDI and TDI operations and how these are assigned.
Table 9-3
32-bit register for LDI/TDI
Register name Register assignment (each 32 bits wide)
A1
ACCU 1 (ACCU1, bits 0 to 31)
A2
ACCU 2 (ACCU1, bits 0 to 31)
SA
STEP address counter (bits 0 to 19)
BA
BA register (block start address, bits 0 to 19)
BR
BR register (base address register, bits 0 to 19)
1)
Loading the contents of an addressed memory register into the A1 register overwrites
the address stored in ACCU 1.
If you reference byte addresses with the LDI or TDI operations, note
the following:
• • the LDI operation overwrites the high byte of the register with non-
defined values (except for flags, PIQ, PII; with these areas, FFH is
written in the high byte)
and
• • the TDI operation transfers only the low bytes of the register (the
high bytes are lost – refer to the example on the following page
Address
15
0
aaaa
DW n
bbbb
DW n+1
Memory Access via Address in ACCU 1
1)
High register
31
16 15
aaaa
Low register
0
bbbb
9 - 17

Advertisement

Table of Contents
loading

Table of Contents