Browse
(440) 299-7778
Menu
(440) 299-7778
One-year parts and labor warranty30-day money-back guaranteeContact

The text of a manual · part 20 of 37

Sharp Programmable Controller New Satellite JW10 User's Manual: Chapter 9 Description of Instructions, pages 156 to 165

Pages 156 to 165 of 307, from Sharp Programmable Controller New Satellite JW10 User's Manual

The original document is the PDF (5.0 MB). This is its text as extracted, unedited; tables and drawings read best in the PDF, and each page heading opens it at that page.

Filed in the catalog under the Sharp jW-10CM

Page 156

F-62 U/DC

2 digits BCD up/down counter (Up/Down Counter)

Symbol

① ② ③

F-62 U/DC

D

① Up/down direction input ② Counter input ③ Reset input

〔Example for use〕 04010 Up/down direction 00000

Function

The contents of the register D (BCD 2 digits) are added (① ON) or subtracted (① OFF), according to the up/down counter direction input.

Operation

When the up/down direction input ① is ON: 〈D〉 +1→D When the up/down direction input ① is OFF: −1→D 〈D〉

Counter input 04011

F-62 09000

U/DC

Instruction 04010 STR 00000 STR 04011 STR F-62 09000

Reset input

コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777

When the reset input 04011 is OFF, the counter is enabled, if set to ON reset mode. When the up/down counter direction input 04010 is ON, it acts as an incremental counter. When it is OFF, it acts as a decremental counter. If the contents At a rising of the counter input ② (OFF of 09000 were other than the BCD code, the error Condition to ON) when the reset input ③ is OFF flag (07355) is turned ON and no counter operation takes place. (7F in the example) • Result (BCD code) is contained when the reset input ③ is OFF. Contents of D Up/down • All bits are OFF when the reset direction Down input ③ is ON. Up (04010)

Range of D

Up/down direction Result input ①

After operation

Zero Carry Error Non-carry 07357 07356 07355 07354

Counter input (00000) Reset input (04011)

99+1 →00

1

1

0

0

Register (09000)

00 to 98+1 →01 to 99

0

0

0

1

Non-carry flag (07354)

Not BCD code

0

0

1

0

Error flag (07355)

00−1 →99

0

1

0

0

01−1 →00

1

0

0

1

02 to 99−1 →01 to 98 Not BCD code

0

0

0

1

0

0

1

0

Reset input ③ ON

0

0

0

0

ON

Flag

OFF

97 98 98 99 99 00 00 01 01 00 00 99 7F7F7F 00 00

Carry flag (07356) Zero flag (07357)

Note 1: By setting the reset input③ in the system memory (#202), it permits to "reset with OFF." Similarity instructions: F-62w

9・ 81

1 scan time, max. Valid until a flag affecting instruction is met in the program.

9

Page 157

F-62w U/DC Symbol

Function

4 digits BCD up/down counter (Up/Down Counter) ① ② ③

F-62w U/DC

D

① Up/down direction input ② Counter input ③ Reset input

Operation

Range of D

コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777

Contents Upper 2 digits of result of D+1 Up/down direction input ① Result

F-62w

00002

19000

U/DC

00003

All bits are OFF when the reset input ③ is OFF.

Zero 07357

Carry Error Non-carry 07356 07355 07354

Up/down direction (00001)

Reset input (00003) Register (19000) (19001)

1

1

0

0

Non-carry flag (07354)

0000 to 9998+1

0

0

0

1

Error flag (07355)

Not BCD code

0

0

1

0

0000−1

0

1

0

0

0001−1

1

0

0

1

0002 to 9999−1

0

0

0

1

Not BCD code

0

0

1

0

Reset input ③ ON

0

0

0

0

Flag

DOWN

UP

Counter input (00002)

9999+1 ON

After operation

Instruction 00001 STR 00002 STR 00003 STR F-62w 19000

When the reset input 00003 is OFF, the counter is enabled, if set to ON reset mode. When the up/down counter direction input 00001 is ON, it acts as an incremental counter. When it is OFF, it acts as a decremental counter. If the contents of the register 19000 or 19001 were At a rising of the counter input ② (OFF other than the BCD code, the error flag (07355) is to ON) when the reset input ③ is OFF. turned ON and no counter operation takes place.

Contents Lower 2 digits of result of D

9

00001

The 4 digits BCD contents of the register D, D+1 are added (① ON) or subtracted (① OFF), according to the up/down counter direction input ①. When the up/down direction input ① is ON : 〈D, D+1〉 +1→D, D+1 When the up/down direction input ① is OFF : 〈D, D+1〉 −1→D, D+1

Condition

〔Example for use〕

97 99

98 99

99 99

00 00

Carry flag (07356) Zero flag (07357)

OFF

Note 1: Be sure to use even address for register D. Note 2: By setting the reset input③ in the system memory (#202), it permits to "reset with OFF." Similarity instructions: F-62

9・ 82

1 scan time, max.

01 00

00 00

99 99 00 00 00 A0 A0 00 00

Page 158

F-63 INC

Increment counter (1 byte) (INCrement) F-63 INC

Symbol

〔Example for use〕

D

00000

Function Operation

Range of D

Condition

F-63 INC

The contents of the register D (binary data) are incremented.

コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777

Input (00000) Register (09030)

Rising edge of input signal (OFF to ON)

376

377

000

001

Non-carry flag (07354) Error flag (07355)

Result (oct)

Zero 07357

Carry 07356

377→000

1

1

0

0

Other than above

0

0

0

1

Error Non-carry 07355 07354

002

003

004

(OCT)

1 scan time, max. Valid until a flag affecting instruction is met in the program.

OFF

Contents Result (binary code) of D

Flag

09030

When the input condition 00000 changes from OFF to ON, the data are incremented.

〈D〉 +1→D

After operation

Instruction STR 00000 F-63 09030

Carry flag (07356) Zero flag (07357)

Note 1: The contents of D are represented by a binary number, which can assume a number of 000 to 255 in the decimal notation or 000 to 377(8) in the octal notation.

9

Similarity instructions: F-63w

F-63w INC

Increment counter (1 word) (INCrement) F-63w INC

Symbol

〔Example for use〕

D

00002

Function

The binary contents of the registers D and D+1 are incremented.

Operation

〈D, D+1〉 +1→D, D+1

Range of D

コ0000 to コ1576 b0000 to b0776 09000 to 09776 19000 to 19776 29000 to 29776 39000 to 39776

Condition

After operation

Flag

F-63w I N C 19000

When the input condition 00002 changes from OFF to ON, the data are incremented. Input (00002) Register (19000) (19001)

Rising edge of input signal (OFF to ON)

Contents of D Contents of D+1

Instruction STR 00002 F-63w 19000

375 377

376 377

377 377

000 000

Non-carry flag (07354) OFF

Lower digits of result

Error flag (07355)

Upper digits of result Result (oct)

Zero 07357

Carry 07356

177777 →000000

1

1

0

0

Other than above

0

0

0

1

Error Non-carry 07355 07354

Note 1: Be sure to use even address for register D. Similarity instructions: F-63

9・ 83

Carry flag (07356) Zero flag (07357) 1 scan time, max.

001 000

002 000

003 000

(OCT) (OCT)

Page 159

F-64 DEC

Decrement counter (1 byte) (DECrement) F-64 DEC

Symbol

〔Example for use〕

D

00000

Function

Condition

When the input condition 00000 changes from OFF to ON, the data are decremented.

コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777

Input (00000) Register (09000)

Rising edge of input signal (OFF to ON)

001

000

377

Non-carry flag (07354)

Result (binary code)

After operation

Flag

Error flag (07355)

Result (oct)

Zero 07357

Carry 07356

Error Non-carry 07354 07355

001 → 000

1

0

0

1

000 → 377

0

1

0

0

Other than above

0

0

0

1

376

375

374

373

(OCT)

1 scan time, max. Valid until a flag affecting instruction is met in the program.

OFF

Contents of D

9

F-64 D E C 09000

The contents of the register D (binary data) are incremented.

Operation 〈D〉−1→D

Range of D

Instruction STR 00000 F-64 09000

Carry flag (07356) Zero flag (07357)

Note 1: The contents of D are represented by a binary number, which can assume a number of 000 to 255 in the decimal notation or 000 to 377 (8) in the octal notation. Similarity instructions: F-64w

Decrement counter (1 word) (DECrement)

F-64w DEC

F-64w DEC

Symbol

〔Example for use〕

D

Function

The binary contents of the registers D, D+1 are decremented.

Operation

〈D, D+1〉 −1→D, D+1

Range of D

コ0000 to コ1576 b0000 to b0776 09000 to 09776 19000 to 19776 29000 to 29776 39000 to 39776

Condition

Contents of D+1 After operation

Flag

F-64w D E C 19000

When the input condition 00002 changes from OFF to ON, the data are decremented. Input (00002) Register (19000) (19001)

Rising edge of input signal (OFF to ON)

Contents of D

00002

Instruction 00002 STR F-64w 19000

002 000

001 000

000 000

377 377

Non-carry flag (07354)

Lower digits of result

OFF Error flag (07355)

Upper digits of result Result (octal)

Zero 07357

Carry 07356

000001 →000000 000000 →177777

1

0

0

1

0

1

0

0

Other than above

0

0

0

1

Error Non-carry 07355 07354

Note 1: Be sure to use even address for register D. Similarity instructions: F-64w

Carry flag (07356) Zero flag (07357) 1 scan time, max.

9・ 84

376 377

375 377

374 (OCT) 377 (OCT)

Page 160

F-70 FILE

Transfer "n" bytes block (FILE) F-70 FILE

Symbol n

S

〔Example for use〕

D

Function

"n" bytes data through the register S to the register S+n−1 are transferred in batch to the "n" bytes area beginning from the register D to D+n−1.

Operation

S, …S+n−1→D, …D+n−1

Range of "n"

000〜377(8) (256 bytes for 000)

Range of S

Range of D

Condition

@コ0000 to @コ1574 @b0000 to @b0774 @09000 to @09774 @19000 to @19774 @29000 to @29774 @39000 to @39774 @コ0000 to @コ1574 @b0000 to @b0774 @09000 to @09774 @19000 to @19774 @29000 to @29774 @39000 to @39774

F-70 FILE

09000 コ0040

040

When the input condition 04001 changes from OFF to ON, 040 (8) bytes data (32 bytes in decimal) in register 09000 to 09037 are transferred in batch to the 32 bytes area of コ0040 to コ0077. The contents of registers, 09000 to 09037, remain unaffected. Before operation

After operation

09000

1

2

1

2

コ0040

09001

4

5

4

5

コ0041

09037

9

9

9

9

コ0077

Rising edge of input signal (OFF to ON) Contents of S, S+n−1

Unchanged

Contents of D Contents of D+1

Contents of the register S

9

Contents of the register S+1

…

…

After operation

コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777 コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777

04001

Instruction 04001 STR F-70 040 09000 コ0040

Contents of D+n-1

Flag

Contents of the register S+n-1 Unchanged

Note 1: F-70 can use indirect address for assigning S and D such as @コ0000 or @コ09000. For indirect address, see page 9・21 "Indirect address assignment." Note 2: It would be possible to program "n", S, and D that the source may overwrite the destination. 04002

F-70 FILE

005

09000

09002

Transfer data

Receive data

09000

Data (1)

09001

(2)

09002

(3)

Data (1)

09002

09003

(4)

(2)

09003

09004

(5)

(3)

09004

09005

(4)

09005

09006

(5)

09006

09000 09001

09007

09007

Similarity instructions: F-00, F-00w, F-70w, F-74, F-74w

9・ 85

Overwritten area

Page 161

F-70w FILE Symbol

Transfer "n" words block (FILE) F-70w FILE n

S

〔Example for use〕

D

Function

"n" words data through the register S to the register S+2n−1 are transferred in batch to the "n" words area in the registers D to D+2n−1.

Operation

S, S+1, …S+2n−1→ D, D+1, …D+2n−1

Range of "n"

000 to 377 (8) (256 words for 000)

Condition

9 After operation

@コ0000 to @コ1574 @b0000 to @b0774 @09000 to @09774 @19000 to @19774 @29000 to @29774 @39000 to @39774 @コ0000 to @コ1574 @b0000 to @b0774 @09000 to @09774 @19000 to @19774 @29000 to @29774 @39000 to @39774

Rising edge of input signal (OFF to ON) Contents of S, …S+2n−1

Unchanged

Contents of D, D+1

Contents of the register S Contents of the register S+1

D+2n-1

Flag

…

Range of D

…

Range of S

コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777 コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777

Contents of the register S+2n-1

04000

F-70w FILE

040

09000 19000

Instruction 04000 STR F-70w 040 09000 19000

When the input condition 04000 changes from OFF to ON, 040 (8) words data (32 words in decimal) in registers 09000 to 09077 are transferred in batch to the 32 words area of 19000 to 19007. The contents of registers, 09000 to 09077, remain unaffected. Before operation

After operation

09000

5

6

5

6

19000

09001

7

8

7

8

19001

09002

1

3

1

3

19002

09003

2

8

2

8

19003

09076

9

7

9

7

19076

09077

5

4

5

4

19077

Unchanged

Note 1: F-70w can use indirect address for assigning S and D such as @コ0000 or @コ09000. For indirect address, see page 9・21 "Indirect address assignment." Note 2: Be sure to use even addresses for registers S and D. Similarity instructions: F-00, F-00w, F-70, F-74, F-74w

9・ 86

Page 162

Transfer octal constant block (1 byte) (CONStant)

F-71 CONS

F-71 CONS

Symbol n

D1

〔Example for use〕

D2

An octal constant "n" is transferred in batch through the register D1 to the register D2.

Function Operation n→D1, ……, D2

Range of "n"

000 to 377 (8)

Range of D2

F-71 000 CONS

09000

09037

When the input condition 04001 changes from OFF to ON, the octal constant 000 is transferred in batch from registers 09000 to 09037.

コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777 コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777

Range of D1

04001

Instruction 04001 STR F-71 000 09000 09037

Before operation

After operation

09000 × × × × × × × ×

0 0 0 0 0 0 0 0

09000

09001 × × × × × × × ×

0 0 0 0 0 0 0 0

09001

09037 × × × × × × × ×

0 0 0 0 0 0 0 0

09037

Rising edge of input signal (OFF to ON)

Condition

Contents of D1 Contents of D1+1

Constant "n"

…

After operation

9

Contents of D2−1 Contents of D2

Flag

Unchanged

Note 1: No operation takes place if D1 or D2 is programmed that may override ① to ③, as shown below. Block ① ②

③

Range コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777

×

F-71 010 CONS

コ0070 09000

The end address of the block that contains コ0070 is コ1577.

○

F-71 100 CONS

19100 29500

Both D1 and D2 are stored in block ③.

Note 2: No operation takes place if the address D1 is greater than D2. F-71 050 CONS

09200 09000

D1(09200)>D2(09000)

Similarity instructions: F-08, F-08w, F-71w

9・ 87

Page 163

Transfer octal constant block (1 word) (CONStant)

F-71w CONS

F-71w CONS

Symbol n

D1

〔Example for use〕

D2

Function

An octal constant "n" is transferred in batch in registers D1, D1+1, through D2, D2+1.

Operation n→ (D1, D1+1), …… (D2, D2+1)

Range of "n"

000000 to 177777 (8)

04000

When the input condition 04000 changes from OFF to ON, the octal constant 012345 is transferred in batch from registers 09000, 09001 to 09036, 09037.

コ0000 to コ1576 b0000 to b0776 09000 to 09776 19000 to 19776 29000 to 29776 39000 to 39776 コ0000 to コ1576 b0000 to b0776 09000 to 09776 19000 to 19776 29000 to 29776 39000 to 39776 Rising edge of input signal (OFF to ON)

Range of D1

Range of D2

Condition

F-71w 012345 09000 09036 CONS

Instruction 04000 STR F-71w 012345 09000 09036

After operation 09001 0 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 09000

0

1

2

3

4

5

09003 0 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 09002

9

After operation

…

D1, D1+1 D1+2, D1+3

Constant "n"

D2-2, D2+1 D2, D2+1

Flag

09037 0 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 09036

Unchanged

Note 1: Be sure to use even addresses for registers D1 and D2. Note 2: No operation takes place if D1 or D2 is programmed that may override ① to ③, as shown below. Block ① ②

③

Range コ0000 to コ1576 b0000 to b0776 09000 to 09776 19000 to 19776 29000 to 29776 39000 to 39776

×

F-71w 010 CONS

コ0070 09000

The end address of the block that contains コ0070 is コ1576.

○

F-71w 100 CONS

19100 29500

Both D1 and D2 are stored in block ③.

Note 3: No operation takes place if the address D1 is greater than D2. F-71w 050 CONS

09200 09000

D1(09200)>D2(09000)

Similarity instructions: F-08, F-08w, F-71

9・ 88

Page 164

F-74 nXFR Symbol

Transfer "n" bytes F-74 nXFR n

S

〔Example for use〕

D

Function

The contents of the register S are transferred to "n" bytes registers headed by the register D.

Operation

S→D, …D+n−1

Range of "n"

000 to 377 (8) (256 bytes for 000)

Range of S

Range of D

Condition

09013

19416

1 0 0 1 0 0 1 0 19416 1 0 0 1 0 0 1 0 19417

010 (8) bytes

1 0 0 1 0 0 1 0 19424

Rising edge of input signal (OFF to ON)

Unchanged

1 0 0 1 0 0 1 0 19425

9

Contents of D Contents of D+1 Contents of the register S Contents of D+n -1

Flag

010

09013 1 0 0 1 0 0 1 0

…

After operation

F-74 nXFR

When the input condition 04000 changes from OFF to ON, the contents of the register 09013 are transferred to a 010 (8) bytes registers headed by the register 19416.

コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777 コ0000 to コ1577 b0000 to b0777 09000 to 09777 19000 to 19777 29000 to 29777 39000 to 39777

Contents of S

04000

Instruction 04000 STR F-74 010 09013 19416

Unchanged

Similarity instructions: F-00, F-00w, F-70, F-70w, F-74w

9・ 89

Page 165

F-74w nXFR Symbol

Transfer "n" words

F-74w nXFR n

S

Function

The contents of the registers S, S+1 are transferred to "n" words registers headed by the registers D, D+1.

Operation

S, S+1→D, D+1…D+2n-2, D+2n-1

Range of "n"

000 to 377 (8) (256 words for 000)

Range of D

Condition

09014

19416

09014

19417

19416

6

8

6

7

8

9

6

7

8

9

6

7

8

9

6

7

8

9

6

7

8

9

6

7

8

9

6

7

8

9

6

7

8

9

7

9

010 (8) bytes

Unchanged

Contents Contents of the register S of D Contents Contents of the register S+1 of D+1 D+2n−2 Contents of the register S D+2n−1 Contents of the register S+1

Flag

010

09015

Rising edge of input signal (OFF to ON)

…

After operation

F-74w nXFR

Instruction 04000 STR F-74w 010 09014 19416

When the input condition 04000 changes from OFF to ON, the contents of the registers 09014 and 09015 are transferred to a 010 (8) words registers headed by the registers 19416 and 19417.

コ0000 to コ1576 b0000 to b0776 09000 to 09776 19000 to 19776 29000 to 29776 39000 to 39776 コ0000 to コ1576 b0000 to b0776 09000 to 09776 19000 to 19776 29000 to 29776 39000 to 39776

Contents of S, S+1

9

04000

…

Range of S

〔Example for use〕

D

Unchanged

Note 1: Be sure to use even addresses for registers S and D. Similarity instructions: F-00, F-00w, F-70, F-70w, F-74

9・ 90

19435

19434