A-49
Appendices
CJ2 CPU Unit Software User’s Manual
A-1 Instruction Functions
App
A-1-16 Tracking Instructions
FRAME
CHECKSUM
FCS
@FCS
180 Calculates the FCS value for the specified range and outputs the
value in ASCII.
Output Required
A-1-16 Tracking Instructions
Instruction Mnemonic Code Symbol/Operand Function Location
Execution
condition
Unsigned
One-word
Record
Search
Instructions
RSRCH
+
<, <=, =, >,
>=
@RSRCH
+
<, <=, =, >,
>=
360
(<),
361
(<=),
362
(=),
363
(>),
364
(>=)
An Unsigned One-word Record Search Instruction searches the
data (1 word) specified by S2, beginning from the table specified
by S1. When a record matching the specified condition is found, its
record number and data are output to D1 onwards. When an index
register is specified for D2, the address of the matching record is
output to that index register. To not use an index register output,
set #00000000 for D2.
Output Required
Unsigned
Two - word
Record
Search
Instructions
RSRCH2
+
<, <=, =, >,
>=
@RSRCH2
+
<, <=, =, >,
>=
370
(<),
371
(<=),
372
(=),
373
(>),
374
(>=)
An Unsigned Two-word Record Search Instruction searches the
data (2 words) specified by S2, beginning from the table specified
by S1. When a record matching the specified condition is found, its
record number and data are output to D1 onwards. When an index
register is specified for D2, the address of the matching record is
output to that index register. To not use an index register output,
set #00000000 for D2.
Output Required
Unsigned
Four-word
Record
Search
Instructions
RSRCH4
+
<, <=, =, >,
>=
@RSRCH4
+
<, <=, =, >,
>=
380
(<),
381
(<=),
382
(=),
383
(>),
384
(>=)
An Unsigned Four-word Record Search Instruction searches the
data (4 words) specified by S2, beginning from the table specified
by S1. When a record matching the specified condition is found, its
record number and data are output to D1 onwards. When an index
register is specified for D2, the address of the matching record is
output to that index register. To not use an index register output,
set #00000000 for D2.
Output Required
Instruction Mnemonic Code Symbol/Operand Function Location
Execution
condition
FCS(180)
C
R1
D
C: 1st control word
R1: 1st word in
range
D: 1st destination
word
RSRCH
S1
S2
D1
D2
C
C: 1st control word
S1: 1st word of first
record to search
S2: Search data
D1: 1st destination
word
D2: Destination index
register
RSRCH2
S1
S2
D1
D2
C
C: 1st control word
S1: 1st word of first
record to search
S2: 1st word of
search data
D1: 1st destination
word
D2: Destination
index register
RSRCH4
S1
S2
D1
D2
C
C: 1st control word
S1: 1st word of first
record to search
S2: Search data
D1: 1st destination
word
D2: Destination
index register