LSDDR
LSIDR
Block Copy
Rabbit 3000A/4000 Instruction
|
|
ED D8
|
LSDDR
|
|
(DE) = (HL)
BC = BC - 1
DE = DE - 1
repeat while BC != 0
|
|
ED D0
|
LSIDR
|
|
(DE) = (HL)
BC = BC - 1
DE = DE + 1
repeat while BC != 0
|
Description
-
LSDDR: BC holds the count, which is the number of bytes that will be copied from the source address in HL to the destination address in DE. If the count starts at zero, the number of bytes that will be moved is 65536. After each byte is copied, BC and DE are decremented and HL remains unchanged. The instruction repeats until BC reaches zero.
-
LSIDR: BC holds the count, which is the number of bytes that will be copied from the source address in HL to the destination address in DE. If the count starts at zero, the number of bytes that will be moved is 65536. After each byte is copied, BC is decremented and DE is incremented. HL remains unchanged. The instruction repeats until BC reaches zero.
If either of these instructions is prefixed by IOI or IOE, the source will be in the specified I/O space. If the
prefix is IOI (internal I/O), add 1 clock for each iteration. If the prefix is IOE, add 2 clocks plus the number
of I/O wait states enabled.
The V flag is cleared when BC transitions from 1 to 0, which ends the block copy.
Interrupts can occur between different repeats (after the registers have been updated), but not within an
iteration. Return from the interrupt is to the first byte of the instruction, which is the I/O prefix byte if there
is one.