Chapter 5 Instruction Specifications

Item number

Arithmetic instructions-1

 

 

Name

 

Substitution statement (ASSIGNMENT STATEMENT)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Ladder format

 

 

 

 

 

 

Condition code

 

 

 

 

Processing time (s)

 

Remark

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

R7F4

 

R7F3

 

R7F2

R7F1

 

R7F0

Average

Maximum

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

d = s

 

 

DER

 

ERR

 

SD

 

V

 

 

 

C

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

z

 

 

z

 

z

 

 

 

z

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Instruction format

 

 

 

 

 

 

Number of steps

 

 

 

 

(See following table)

 

 

 

 

 

 

 

 

 

Condition

 

 

 

Steps

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

d = s

 

 

 

(See Notes)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

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

Substitution destination

 

 

{

{

 

 

 

 

 

 

{

 

{

 

{

 

{

{

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

s

Substitution source

{

 

{

{

 

 

 

 

 

{

{

 

{

 

{

{

{

{

{

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

( )

Index value

 

 

 

 

 

 

 

 

 

{

{

 

{

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Function

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

• Substitutes the content of s into d.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

• It is possible to use array variables for d and s.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

• When d is a word, the constant is

 

 

 

 

0 to 65535 or – 32768 to + 32767 (decimal)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

H0000 to HFFFF or H8000 to H7FFF (hexadecimal)

 

 

When d is a double word, the constant is

 

 

0 to 4294967295 or -2147483648 to +2147483647 (decimal)

 

 

 

 

 

 

 

 

 

 

 

H00000000 to HFFFFFFFF or H80000000 to H7FFFFFFF

 

Notes

When using an array variable, DER is set to 1 if the usable I/O number exceeds the maximum value, and DER is reset to “0” if it is normal.

The combinations of d and s are as follows:

d

s

 

 

Bit

Bit

 

 

Word

Word

 

 

Double word

Double word

 

 

Step numbers and processing time are as follows:

d

s

Number of steps ( ) indicates DW

 

Processing time (s)

Bit

 

Word

Double word

 

 

 

 

 

 

 

 

 

 

 

I/O

I/O

3 (4)

32

 

27

35

 

 

 

 

 

 

 

I/O

Array

4

74

 

66

86

 

 

 

 

 

 

 

Array

I/O

4 (5)

52

 

53

71

 

 

 

 

 

 

 

Array

Array

5

92

 

99

120

 

 

 

 

 

 

 

d = s

5-45

Page 95
Image 95
Hitachi NJI-350B Arithmetic instructions-1, Substitution statement Assignment Statement, = s, See following table, 120