COPY (d, s, n)

Chapter 5 Instruction Specifications

Item number

 

Application instructions-13

 

 

Name

 

Copy

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Ladder format

 

 

 

 

 

 

Condition code

 

 

 

 

Processing time (s)

Remark

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

R7F4

 

R7F3

 

R7F2

R7F1

 

R7F0

Average

Maximum

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

COPY (d, s, n)

 

 

DER

 

ERR

 

SD

 

V

 

 

 

C

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

z

 

 

z

 

z

 

 

 

z

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Instruction format

 

 

 

 

 

 

Number of steps

 

 

 

 

As per the table

 

 

 

 

 

 

 

 

Condition

 

 

 

Steps

 

 

below.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

COPY (d, s, n)

 

 

 

 

 

 

 

 

 

 

 

 

 

4

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Bit

 

 

 

 

 

 

 

Word

 

Double word

Constant

 

 

 

Usable I/O

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Other

 

X

 

Y

M

 

 

CU, CT

 

WX

WY

WM

 

TC

DX

DY

DM

 

 

 

 

 

 

 

 

R,

 

 

TD, SS,

 

 

 

 

WR,

 

 

 

 

DR,

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

d

Copy destination head I/O

 

 

 

{

 

 

 

 

 

 

 

 

 

{

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

s

Copy source head I/O

{

{

{

 

 

 

 

 

{

{

 

{

 

{

 

 

 

{

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

n

Number of bits (words)

 

 

 

 

 

 

 

 

 

{

{

 

{

 

{

 

 

 

{

 

The constant is set in

to be copied

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

decimal.

Function

The value of s (bit, word) is copied from d to d + n - 1.

The value of s is retained.

A bit is copied to bits and a word is copied to words.

s

 

 

s

s

s

s

 

 

 

s

s

s

s

s

s

 

 

 

 

 

d+n-1

 

 

 

 

 

 

 

 

 

d

 

 

 

 

 

 

 

 

n bits (words)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

If n is a word:

The contents (0 to 255) of the lower 8 bits (b7 to b0) of n (WX, WY, WR, WM, TC) are set to the

 

 

 

 

 

 

number of bits (words) to be copied.

If n is a constant:

0 to 255 (decimal) can be designated for the number of bits (words) to be copied.

Notes

Use this instruction so that d + n - 1 does not exceed the I/O range (R7BF, M3FFF, WRFFF, and WM3FF). If it exceeds the I/O range, DER is equal to '1' and transfers to the maximum range.

If n is equal to “0,” the block copy is not be performed and DER (R7F4) will be set to “0.”

n

Processing time (s) (Average)

Bit

Word

 

1

80

73

16

83

114

32

83

148

64

88

224

128

95

381

255

109

785

5-84

Page 134
Image 134
Hitachi NJI-350B Application instructions-13, Below Copy d, s, n, Number of bits words to be copied, 114, 148, 224