0% found this document useful (0 votes)
255 views

PMC-MODEL SD7 Programming Manual

This manual covers programming for FANUC PMC-MODEL SD7 programmable logic controllers used with FANUC CNCs. It describes the system configuration, PMC specifications including data types and references, and programming with ladder logic.

Uploaded by

Denchiro Tsuka
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
255 views

PMC-MODEL SD7 Programming Manual

This manual covers programming for FANUC PMC-MODEL SD7 programmable logic controllers used with FANUC CNCs. It describes the system configuration, PMC specifications including data types and references, and programming with ladder logic.

Uploaded by

Denchiro Tsuka
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 618

/

om
FANUC PMC-MODEL SD7

s.c
re
pa
PROGRAMMING MANUAL
cs
.cn
w
w
w
://
tp
ht

B-63823EN/02
/
om
s.c
re
pa
cs
.cn
w

• No part of this manual may be reproduced in any form.


• All specifications and designs are subject to change without notice.
w

The export of this product is subject to the authorization of the government of the country
w

from where the product is exported.


://

In this manual we have tried as much as possible to describe all the various matters.
However, we cannot describe all the matters which must not be done, or which cannot be
tp

done, because there are so many possibilities.


Therefore, matters which are not especially described as possible in this manual should be
ht

regarded as ”impossible”.

This manual contains the program names or device names of other companies, some of
which are registered trademarks of respective owners. However, these names are not
followed by  or  in the main body.
B-63823EN/02 DEFINITION OF WARNING, CAUTION, AND NOTE

DEFINITION OF WARNING, CAUTION, AND NOTE


This manual includes safety precautions for protecting the user and
preventing damage to the machine. Precautions are classified into

/
Warning and Caution according to their bearing on safety. Also,

om
supplementary information is described as a Note. Read the Warning,
Caution, and Note thoroughly before attempting to use the machine.

WARNING
Applied when there is a danger of the user being

s.c
injured or when there is a damage of both the user
being injured and the equipment being damaged if
the approved procedure is not observed.

re
CAUTION
Applied when there is a danger of the equipment

NOTE
observed. pa
being damaged, if the approved procedure is not
cs
The Note is used to indicate supplementary
information other than Warning and Caution.
.cn

* Read this manual carefully, and store it in a safe place.


w
w
w
://
tp
ht

s-1
ht
tp
://
w
w
w
.cn
cs
pa
re
s.c
om
/
B-63823EN/02 PREFACE

PREFACE
This manual covers the specifications and the instructions and
operations used for programming with the following devices.

/
Product name Applicable CNC

om
FANUC Series 16i-MODEL B (Series 16i-B)
FANUC Series 160i-MODEL B (Series 160i-B)
FANUC PMC-MODEL SD7 FANUC Series 18i-MODEL B (Series 18i-B)
(PMC-SD7) FANUC Series 180i-MODEL B (Series 180i-B)
FANUC Series 21i-MODEL B (Series 21i-B)

s.c
FANUC Series 210i-MODEL B (Series 210i-B)
The FANUC PMC (Programmable Machine Controller) is a sequence
control unit that is built into the FANUC CNC. It is used to execute
IEC61131-3-compatible sequence programs.

re
IEC61131, as established by the International Electrotechnical
Commission (IEC), is a set of rules consisting of the following five
parts:
pa
Part 1: General information
Part 2: Equipment requirements and tests
Part 3: Programming languages
cs
Part 4: User guidelines
Part 5: Communications
Part 6: Reserved
.cn

Part 7: Fuzzy-control programming


Part 8: Guidelines for the application and implementation of
programming languages for programmable controllers
IEC61131-3 relates to Part 3 of these rules. It is intended to specify
a world-wide standard programming language and related techniques
w

for industrial sequence control units.

Related Manuals
w

The following manuals provide an explanation of the use of the above


hardware and software, as well as the connection interface. Refer to
w

the corresponding manual as necessary.


Specification
Manual Name
Number
://

FANUC Series 16i/18i/21i/160i/180i/210i-MODEL B


B-63523EN-1
Connection Manual (Function)
tp

This product can be programmed using the following software. This


software provides with a lot of help documents which contain the
information of PMC-SD7. Please also refer to these help documents.
ht

Software
FANUC LADDER-IIIC

p-1
ht
tp
://
w
w
w
.cn
cs
pa
re
s.c
om
/
B-63823EN/02 TABLE OF CONTENTS

TABLE OF CONTENTS

DEFINITION OF WARNING, CAUTION, AND NOTE .................................s-1

/
PREFACE ....................................................................................................p-1

om
1 OVERVIEW ............................................................................................. 1
1.1 SYSTEM CONFIGURATION ......................................................................... 2
1.2 PMC BASIC CONFIGURATION .................................................................... 3

s.c
1.3 CONTENTS OF THIS MANUAL .................................................................... 4
2 SPECIFICATIONS................................................................................... 5

re
2.1 SPECIFICATIONS OF PMC .......................................................................... 6
2.2 DATA TYPES ................................................................................................ 9
2.3
2.3.1
2.3.2
pa
REFERENCES ............................................................................................ 10
Reference Address..................................................................................................10
User References......................................................................................................11
cs
2.3.3 System References .................................................................................................13
2.3.4 Message Display Reference ...................................................................................16
.cn

3 I/O LINK................................................................................................. 22
3.1 WHAT IS THE I/O LINK?............................................................................. 23
3.1.1 Configuration of an I/O Link..................................................................................24
w

3.1.2 Numbers of Input Points and of Output Points of the I/O Link .............................25
3.2 ASSIGNMENT METHOD ............................................................................ 26
w

3.2.1 Assignment Method for I/O Unit-MODEL A ........................................................34


3.2.2 Assignment Method for I/O Unit-MODEL B ........................................................37
w

3.2.3 Assignment Method for Distribution I/O Connection Panel I/O Unit and
Distribution I/O Operator's Panel I/O Units ...........................................................40
://

3.2.4 Assignment Method for the Power Mate................................................................47


3.2.5 Assignment Method for I/O Link Connection Units ..............................................48
tp

3.2.6 Assignment Method for a Handy Machine Operator's Panel .................................50


3.2.7 Assignment Method for an AS-i Converter Unit ...................................................52
ht

3.3 I/O LINK CONNECTION CHECK FUNCTION ............................................. 54


4 LD INSTRUCTION GROUP .................................................................. 55
4.1 CONTACTS & COILS.................................................................................. 56
4.1.1 Normally Open Contacts (A Contacts)...................................................................56
4.1.2 Normally Close Contacts (B Contacts) ..................................................................56
4.1.3 Coils ......................................................................................................................57
c-1
TABLE OF CONTENTS B-63823EN/02

4.1.4 Reverse-wound Coils .............................................................................................57


4.1.5 Setting Coil (SET) ..................................................................................................57
4.1.6 Reset Coil (RESET) ...............................................................................................58
4.1.7 Continuous Contacts & Continuous Coils..............................................................59

/
4.2 TIMERS & COUNTERS............................................................................... 60

om
4.2.1 ONDTR ..................................................................................................................61
4.2.2 TMR ......................................................................................................................63
4.2.3 OFDT .....................................................................................................................65

s.c
4.2.4 UPCTR ...................................................................................................................67
4.2.5 DNCTR ..................................................................................................................69
4.3 MATH OPERATIONS .................................................................................. 71

re
4.3.1 ADD_(type)/SUB_(type)/MUL_(type)/DIV_(type) ..............................................72
4.3.2 MOD_(type) ...........................................................................................................74

4.4
4.3.3
4.3.4
pa
ABS_(type).............................................................................................................76
SQRT_(type) ..........................................................................................................77
RELATIONAL OPERATIONS ...................................................................... 78
cs
4.4.1 EQ_(type)/NE_(type) .............................................................................................79
4.4.2 GT_(type)/GE_(type)/LT_(type)/LE_(type) ..........................................................81
.cn

4.4.3 RANGE_(type).......................................................................................................83
4.5 BIT OPERATIONS....................................................................................... 85
4.5.1 AND_(type)/OR_(type)..........................................................................................86
w

4.5.2 XOR_(type) ............................................................................................................88


4.5.3 NOT_(type) ............................................................................................................90
w

4.5.4 SHIFTL_(type)/SHIFTR_(type) ............................................................................91


4.5.5 ROL_(type)/ROR_(type)........................................................................................93
w

4.5.6 BIT_TEST_(type) ..................................................................................................95


4.5.7 BIT_SET_(type)/BIT_CLR_(type) ........................................................................97
://

4.5.8 BIT_POS_(type).....................................................................................................99
4.5.9 BIT_SEQ ..............................................................................................................101
tp

4.5.10 MASK_COMP_(type)..........................................................................................103
4.6 DATA MOVE.............................................................................................. 106
ht

4.6.1 MOVE_(type).......................................................................................................107
4.6.2 SWAP_(type) .......................................................................................................109
4.6.3 BLK_CLR_(type).................................................................................................110
4.6.4 SHFR_(type) ........................................................................................................112
4.7 DATA TABLE FUNCTIONS ....................................................................... 114
4.7.1 ARRAY_MOVE_(type).......................................................................................115

c-2
B-63823EN/02 TABLE OF CONTENTS

4.7.2 SEARCH_EQ_(type)/SEARCH_NE_(type)/SEARCH_GT_(type)/
SEARCH_GE_(type)/SEARCH_LT_(type)/SEARCH_LE_(type).....................117
4.8 DATA TYPE CONVERSION...................................................................... 120
4.8.1 (type)_TO_BCDx (x = 2, 4, 8) .............................................................................121

/
4.8.2 BCDx_TO_(type) (x = 2, 4, 8) .............................................................................123

om
4.8.3 (type)_TO_SINT ..................................................................................................125
4.8.4 (type)_TO_USINT ...............................................................................................127
4.8.5 (type)_TO_INT ....................................................................................................129

s.c
4.8.6 (type)_TO_UINT..................................................................................................131
4.8.7 (type)_TO_DINT..................................................................................................133
4.8.8 (type)_TO_UDINT...............................................................................................135

re
4.9 PROGRAM FLOW..................................................................................... 137
4.9.1 CALL ...................................................................................................................138
4.9.2
4.9.3
4.9.4
pa
END ....................................................................................................................138
MCR/ENDMCR/MCRN/ENDMCRN .................................................................139
JUMPN.................................................................................................................140
cs
4.9.5 LABELN ..............................................................................................................141
4.9.6 COMMENT..........................................................................................................141
.cn

4.10 PMC OPERATIONS .................................................................................. 142


4.10.1 PMC_ADD_BCDx/PMC_SUB_BCDx/PMC_MUL_BCDx/ PMC_DIV_BCDx
(x = 2, 4, 8) ...........................................................................................................143
w

4.10.2 PMC_MOD_BCDx (x = 2, 4, 8) ..........................................................................145


4.10.3 R_TRIG/F_TRIG .................................................................................................147
w

4.10.4 PMC_DECODE_(type)........................................................................................148
4.10.5 PMC_EVPAR_(type)/PMC_ODPAR_(type) ......................................................150
w

4.10.6 PMC_WINDOW ..................................................................................................151


4.10.7 PMC_EXIN ..........................................................................................................153
://

4.10.8 PMC_AXCTL ......................................................................................................155


4.11 NOTE ON LD PROGRAMMING ................................................................ 157
tp

5 IL INSTRUCTIONS.............................................................................. 158
5.1 BASIC INSTRUCTIONS ............................................................................ 159
ht

5.2 IL TIMERS & COUNTERS......................................................................... 161


5.2.1 Off Delay Timer ...................................................................................................162
5.2.1.1 OFDT_THOUS(address, pv) ............................................................................................................. 162
5.2.1.2 OFDT_HUNDS(address, pv)............................................................................................................. 162
5.2.1.3 OFDT_TENTHS(address, pv) ........................................................................................................... 162
5.2.1.4 OFDT_SECS(address, pv) ................................................................................................................. 162

c-3
TABLE OF CONTENTS B-63823EN/02

5.2.1.5 OFDT_TENSEC(address, pv)............................................................................................................ 163


5.2.1.6 OFDT_MIN(address, pv)................................................................................................................... 163

5.2.2 On Delay Stopwatch Timer ..................................................................................164


5.2.2.1 ONDTR_THOUS(address, r, pv)....................................................................................................... 164

/
5.2.2.2 ONDTR_HUNDS(address, r, pv) ...................................................................................................... 164

om
5.2.2.3 ONDTR_TENTHS(address, r, pv)..................................................................................................... 164
5.2.2.4 ONDTR_SECS(address, r, pv) .......................................................................................................... 164
5.2.2.5 ONDTR_TENSEC(address, r, pv)..................................................................................................... 165
5.2.2.6 ONDTR_MIN(address, r, pv) ............................................................................................................ 165

s.c
5.2.3 On Delay Timer....................................................................................................166
5.2.3.1 TMR_THOUS(address, pv) ............................................................................................................... 166
5.2.3.2 TMR_HUNDS(address, pv)............................................................................................................... 166
5.2.3.3 TMR_TENTHS(address, pv) ............................................................................................................. 166

re
5.2.3.4 TMR_SECS(address, pv)................................................................................................................... 166
5.2.3.5 TMR_TENSEC(address, pv) ............................................................................................................. 167

5.2.4
5.2.3.6

pa
TMR_MIN(address, pv)..................................................................................................................... 167

Up Counter ...........................................................................................................168
5.2.4.1 UPCTR(address, r, pv) ....................................................................................................................... 168
cs
5.2.5 Down Counter ......................................................................................................168
5.2.5.1 DNCTR(address, r, pv) ...................................................................................................................... 168

5.3 IL MATH FUNCTIONS............................................................................... 169


.cn

5.3.1 Add ....................................................................................................................170


5.3.1.1 ADD_SINT(in1, in2) ......................................................................................................................... 170
5.3.1.2 ADD_USINT(in1, in2) ...................................................................................................................... 170
w

5.3.1.3 ADD_INT(in1, in2)............................................................................................................................ 170


5.3.1.4 ADD_UINT(in1, in2)......................................................................................................................... 170
w

5.3.1.5 ADD_DINT(in1, in2)......................................................................................................................... 170


5.3.1.6 ADD_UDINT(in1, in2)...................................................................................................................... 171

5.3.2 Subtract.................................................................................................................172
w

5.3.2.1 SUB_SINT(in1, in2) .......................................................................................................................... 172


5.3.2.2 SUB_USINT(in1, in2) ....................................................................................................................... 172
://

5.3.2.3 SUB_INT(in1, in2)............................................................................................................................. 172


5.3.2.4 SUB_UINT(in1, in2).......................................................................................................................... 172
5.3.2.5 SUB_DINT(in1, in2).......................................................................................................................... 173
tp

5.3.2.6 SUB_UDINT(in1, in2)....................................................................................................................... 173

5.3.3 Multiply................................................................................................................174
ht

5.3.3.1 MUL_SINT(in1, in2) ......................................................................................................................... 174


5.3.3.2 MUL_USINT(in1, in2) ...................................................................................................................... 174
5.3.3.3 MUL_INT(in1, in2) ........................................................................................................................... 174
5.3.3.4 MUL_UINT(in1, in2)......................................................................................................................... 174
5.3.3.5 MUL_DINT(in1, in2)......................................................................................................................... 175
5.3.3.6 MUL_UDINT(in1, in2)...................................................................................................................... 175

5.3.4 Divide ...................................................................................................................176


c-4
B-63823EN/02 TABLE OF CONTENTS

5.3.4.1 DIV_SINT(in1, in2) ........................................................................................................................... 176


5.3.4.2 DIV_USINT(in1, in2) ........................................................................................................................ 176
5.3.4.3 DIV_INT(in1, in2) ............................................................................................................................. 176
5.3.4.4 DIV_UINT(in1, in2) .......................................................................................................................... 176

/
5.3.4.5 DIV_DINT(in1, in2) .......................................................................................................................... 177

om
5.3.4.6 DIV_UDINT(in1, in2) ....................................................................................................................... 177

5.3.5 Modulus................................................................................................................178
5.3.5.1 MOD_SINT(in1, in2)......................................................................................................................... 178
5.3.5.2 MOD_USINT(in1, in2)...................................................................................................................... 178

s.c
5.3.5.3 MOD_INT(in1, in2) ........................................................................................................................... 178
5.3.5.4 MOD_UINT(in1, in2) ........................................................................................................................ 178
5.3.5.5 MOD_DINT(in1, in2) ........................................................................................................................ 179
5.3.5.6 MOD_UDINT(in1, in2) ..................................................................................................................... 179

re
5.3.6 Absolute ...............................................................................................................180
5.3.6.1 ABS_SINT(in) ................................................................................................................................... 180

5.3.7
5.3.6.2
5.3.6.3 pa
ABS_INT(in)...................................................................................................................................... 180
ABS_DINT(in)................................................................................................................................... 180

Square Root ..........................................................................................................181


cs
5.3.7.1 SQRT_SINT(in) ................................................................................................................................. 181
5.3.7.2 SQRT_USINT(in) .............................................................................................................................. 181
5.3.7.3 SQRT_INT(in) ................................................................................................................................... 181
.cn

5.3.7.4 SQRT_UINT(in) ................................................................................................................................ 181


5.3.7.5 SQRT_DINT(in) ................................................................................................................................ 181
5.3.7.6 SQRT_UDINT(in) ............................................................................................................................. 182

5.4 IL RELATIONAL FUNCTIONS................................................................... 183


w

5.4.1 Equal ....................................................................................................................184


5.4.1.1 EQ_SINT(in1, in2)............................................................................................................................. 184
w

5.4.1.2 EQ_USINT(in1, in2).......................................................................................................................... 184


5.4.1.3 EQ_INT(in1, in2) ............................................................................................................................... 184
w

5.4.1.4 EQ_UINT(in1, in2) ............................................................................................................................ 184


5.4.1.5 EQ_DINT(in1, in2) ............................................................................................................................ 185
://

5.4.1.6 EQ_UDINT(in1, in2) ......................................................................................................................... 185


5.4.1.7 EQ_BYTE(in1, in2) ........................................................................................................................... 185
5.4.1.8 EQ_WORD(in1, in2) ......................................................................................................................... 185
tp

5.4.1.9 EQ_DWORD(in1, in2) ...................................................................................................................... 186

5.4.2 Not Equal..............................................................................................................187


ht

5.4.2.1 NE_SINT(in1, in2)............................................................................................................................. 187


5.4.2.2 NE_USINT(in1, in2).......................................................................................................................... 187
5.4.2.3 NE_INT(in1, in2) ............................................................................................................................... 187
5.4.2.4 NE_UINT(in1, in2) ............................................................................................................................ 187
5.4.2.5 NE_DINT(in1, in2) ............................................................................................................................ 188
5.4.2.6 NE_UDINT(in1, in2) ......................................................................................................................... 188
5.4.2.7 NE_BYTE(in1, in2) ........................................................................................................................... 188

c-5
TABLE OF CONTENTS B-63823EN/02

5.4.2.8 NE_WORD(in1, in2) ......................................................................................................................... 188


5.4.2.9 NE_DWORD(in1, in2) ...................................................................................................................... 189

5.4.3 Greater Than.........................................................................................................190


5.4.3.1 GT_SINT(in1, in2)............................................................................................................................. 190

/
5.4.3.2 GT_USINT(in1, in2).......................................................................................................................... 190

om
5.4.3.3 GT_INT(in1, in2) ............................................................................................................................... 190
5.4.3.4 GT_UINT(in1, in2) ............................................................................................................................ 191
5.4.3.5 GT_DINT(in1, in2) ............................................................................................................................ 191
5.4.3.6 GT_UDINT(in1, in2) ......................................................................................................................... 191

s.c
5.4.4 Greater or Equal ...................................................................................................192
5.4.4.1 GE_SINT(in1, in2)............................................................................................................................. 192
5.4.4.2 GE_USINT(in1, in2).......................................................................................................................... 192
5.4.4.3 GE_INT(in1, in2) ............................................................................................................................... 192

re
5.4.4.4 GE_UINT(in1, in2) ............................................................................................................................ 192
5.4.4.5 GE_DINT(in1, in2) ............................................................................................................................ 193

5.4.5
5.4.4.6

pa
GE_UDINT(in1, in2) ......................................................................................................................... 193

Less Than .............................................................................................................194


5.4.5.1 LT_SINT(in1, in2) ............................................................................................................................. 194
cs
5.4.5.2 LT_USINT(in1, in2) .......................................................................................................................... 194
5.4.5.3 LT_INT(in1, in2) ............................................................................................................................... 194
5.4.5.4 LT_UINT(in1, in2)............................................................................................................................. 195
.cn

5.4.5.5 LT_DINT(in1, in2)............................................................................................................................. 195


5.4.5.6 LT_UDINT(in1, in2).......................................................................................................................... 195

5.4.6 Less or Equal ........................................................................................................196


w

5.4.6.1 LE_SINT(in1, in2) ............................................................................................................................. 196


5.4.6.2 LE_USINT(in1, in2) .......................................................................................................................... 196
5.4.6.3 LE_INT(in1, in2) ............................................................................................................................... 196
w

5.4.6.4 LE_UINT(in1, in2)............................................................................................................................. 197


5.4.6.5 LE_DINT(in1, in2)............................................................................................................................. 197
w

5.4.6.6 LE_UDINT(in1, in2).......................................................................................................................... 197

5.4.7 Range ....................................................................................................................198


://

5.4.7.1 RANGE_SINT(l1, l2, in) ................................................................................................................... 198


5.4.7.2 RANGE_USINT(l1, l2, in) ................................................................................................................ 198
5.4.7.3 RANGE_INT(l1, l2, in) ..................................................................................................................... 198
tp

5.4.7.4 RANGE_UINT(l1, l2, in) .................................................................................................................. 198


5.4.7.5 RANGE_DINT(l1, l2, in) .................................................................................................................. 199
ht

5.4.7.6 RANGE_UDINT(l1, l2, in)................................................................................................................ 199

5.5 IL BIT OPERATIONS................................................................................. 200


5.5.1 Logical AND ........................................................................................................201
5.5.1.1 AND_BYTE(in1, in2)........................................................................................................................ 201
5.5.1.2 AND_WORD(in1, in2) ...................................................................................................................... 201
5.5.1.3 AND_DWORD(in1, in2) ................................................................................................................... 201

5.5.2 Logical OR ...........................................................................................................202

c-6
B-63823EN/02 TABLE OF CONTENTS

5.5.2.1 OR_BYTE(in1, in2) ........................................................................................................................... 202


5.5.2.2 OR_WORD(in1, in2) ......................................................................................................................... 202
5.5.2.3 OR_DWORD(in1, in2) ...................................................................................................................... 202

5.5.3 Logical XOR ........................................................................................................203

/
5.5.3.1 XOR_BYTE(in1, in2) ........................................................................................................................ 203

om
5.5.3.2 XOR_WORD(in1, in2) ...................................................................................................................... 203
5.5.3.3 XOR_DWORD(in1, in2) ................................................................................................................... 203

5.5.4 Logical NOT.........................................................................................................204


5.5.4.1 NOT_BYTE(operand)........................................................................................................................ 204

s.c
5.5.4.2 NOT_WORD(operand)...................................................................................................................... 204
5.5.4.3 NOT_DWORD(operand)................................................................................................................... 204

5.5.5 Shift Bits...............................................................................................................205

re
5.5.5.1 SHIFTL_BYTE(in, n, length, b1, q).................................................................................................. 205
5.5.5.2 SHIFTL_WORD(in, n, length, b1, q) ................................................................................................ 205
5.5.5.3 SHIFTL_DWORD(in, n, length, b1, q) ............................................................................................. 205
5.5.5.4
5.5.5.5
5.5.5.6
pa
SHIFTR_BYTE(in, n, length, b1, q).................................................................................................. 205
SHIFTR_WORD(in, n, length, b1, q)................................................................................................ 206
SHIFTR_DWORD(in, n, length, b1, q) ............................................................................................. 206
cs
5.5.6 Rotate Bits ............................................................................................................207
5.5.6.1 ROL_BYTE(in, n, length, q).............................................................................................................. 207
.cn

5.5.6.2 ROL_WORD(in, n, length, q)............................................................................................................ 207


5.5.6.3 ROL_DWORD(in, n, length, q)......................................................................................................... 207
5.5.6.4 ROR_BYTE(in, n, length, q) ............................................................................................................. 207
5.5.6.5 ROR_WORD(in, n, length, q) ........................................................................................................... 208
w

5.5.6.6 ROR_DWORD(in, n, length, q)......................................................................................................... 208

5.5.7 Bit Test .................................................................................................................209


5.5.7.1 BIT_TEST_BYTE(in, bit, length) ..................................................................................................... 209
w

5.5.7.2 BIT_TEST_WORD(in, bit, length) ................................................................................................... 209


5.5.7.3 BIT_TEST_DWORD(in, bit, length)................................................................................................. 209
w

5.5.8 Bit Set, Clear ........................................................................................................210


5.5.8.1 BIT_SET_BYTE(in, bit, length)........................................................................................................ 210
://

5.5.8.2 BIT_SET_WORD(in, bit, length)...................................................................................................... 210


5.5.8.3 BIT_SET_DWORD(in, bit, length) ................................................................................................... 210
5.5.8.4 BIT_CLR_BYTE(in, bit, length) ....................................................................................................... 210
tp

5.5.8.5 BIT_CLR_WORD(in, bit, length) ..................................................................................................... 210


5.5.8.6 BIT_CLR_DWORD(in, bit, length) .................................................................................................. 211
ht

5.5.9 Bit Position ...........................................................................................................212


5.5.9.1 BIT_POS_BYTE(in, length).............................................................................................................. 212
5.5.9.2 BIT_POS_WORD(in, length) ............................................................................................................ 212
5.5.9.3 BIT_POS_DWORD(in, length) ......................................................................................................... 212

5.5.10 Bit Sequencer .......................................................................................................213


5.5.10.1 BIT_SEQ(address, r, dir, n, st, length)............................................................................................... 213

5.5.11 Masked Compare..................................................................................................214


c-7
TABLE OF CONTENTS B-63823EN/02

5.5.11.1 MASK_COMP_BYTE(in1, in2, m, bit, length, q, bn)...................................................................... 214


5.5.11.2 MASK_COMP_WORD(in1, in2, m, bit, length, q, bn) .................................................................... 214
5.5.11.3 MASK_COMP_DWORD(in1, in2, m, bit, length, q, bn) ................................................................. 215

5.6 IL DATA MOVE FUNCTIONS.................................................................... 216

/
5.6.1 Move Data ............................................................................................................217

om
5.6.1.1 MOVE_SINT(in, length, q) ............................................................................................................... 217
5.6.1.2 MOVE_USINT(in, length, q) ............................................................................................................ 217
5.6.1.3 MOVE_INT(in, length, q).................................................................................................................. 217
5.6.1.4 MOVE_UINT(in, length, q)............................................................................................................... 217

s.c
5.6.1.5 MOVE_DINT(in, length, q)............................................................................................................... 217
5.6.1.6 MOVE_UDINT(in, length, q)............................................................................................................ 218
5.6.1.7 MOVE_BOOL(in, length, q) ............................................................................................................. 218
5.6.1.8 MOVE_BYTE(in, length, q).............................................................................................................. 218

re
5.6.1.9 MOVE_WORD(in, length, q) ............................................................................................................ 218
5.6.1.10 MOVE_DWORD(in, length, q) ......................................................................................................... 218

5.6.2
5.6.2.1
5.6.2.2
pa
Swap Data.............................................................................................................219
SWAP_WORD(in, length, q)............................................................................................................. 219
SWAP_DWORD(in, length, q).......................................................................................................... 219
cs
5.6.3 Block Clear...........................................................................................................220
5.6.3.1 BLK_CLR_SINT(in, length) ............................................................................................................. 220
.cn

5.6.3.2 BLK_CLR_USINT(in, length) .......................................................................................................... 220


5.6.3.3 BLK_CLR_INT(in, length)................................................................................................................ 220
5.6.3.4 BLK_CLR_UINT(in, length)............................................................................................................. 220
5.6.3.5 BLK_CLR_DINT(in, length)............................................................................................................. 221
w

5.6.3.6 BLK_CLR_UDINT(in, length).......................................................................................................... 221


5.6.3.7 BLK_CLR_BYTE(in, length)............................................................................................................ 221
5.6.3.8 BLK_CLR_WORD(in, length).......................................................................................................... 221
w

5.6.3.9 BLK_CLR_DWORD(in, length) ....................................................................................................... 222

5.6.4 Shift Register........................................................................................................223


w

5.6.4.1 SHFR_BIT(r, in, st, length, q)............................................................................................................ 223


5.6.4.2 SHFR_BYTE(r, in, st, length, q) ....................................................................................................... 223
://

5.6.4.3 SHFR_WORD(r, in, st, length, q)...................................................................................................... 223


5.6.4.4 SHFR_DWORD(r, in, st, length, q)................................................................................................... 224

5.7 IL DATA TABLE FUNCTIONS ................................................................... 225


tp

5.7.1 Array Move ..........................................................................................................226


5.7.1.1 ARRAY_MOVE_SINT(sr, snx, dnx, n, length, ds) .......................................................................... 226
ht

5.7.1.2 ARRAY_MOVE_USINT(sr, snx, dnx, n, length, ds) ....................................................................... 226


5.7.1.3 ARRAY_MOVE_INT(sr, snx, dnx, n, length, ds) ............................................................................ 227
5.7.1.4 ARRAY_MOVE_UINT(sr, snx, dnx, n, length, ds) ......................................................................... 227
5.7.1.5 ARRAY_MOVE_DINT(sr, snx, dnx, n, length, ds) ......................................................................... 227
5.7.1.6 ARRAY_MOVE_UDINT(sr, snx, dnx, n, length, ds)....................................................................... 228
5.7.1.7 ARRAY_MOVE_BOOL(sr, snx, dnx, n, length, ds) ........................................................................ 228
5.7.1.8 ARRAY_MOVE_BYTE(sr, snx, dnx, n, length, ds)......................................................................... 229

c-8
B-63823EN/02 TABLE OF CONTENTS

5.7.1.9 ARRAY_MOVE_WORD(sr, snx, dnx, n, length, ds)....................................................................... 229


5.7.1.10 ARRAY_MOVE_DWORD(sr, snx, dnx, n, length, ds).................................................................... 230

5.7.2 Search for Values in a Memory Block .................................................................231


5.7.2.1 Mnemonics ......................................................................................................................................... 231

/
5.7.2.2 Operation ............................................................................................................................................ 232

om
5.7.2.3 Operands............................................................................................................................................. 233

5.8 IL CONVERSIONS .................................................................................... 234


5.8.1 (type)_TO_BCDx(x=2,4,8) ..................................................................................235
5.8.1.1 SINT_TO_BCD2(operand)................................................................................................................ 235

s.c
5.8.1.2 USINT_TO_BCD2(operand)............................................................................................................. 235
5.8.1.3 INT_TO_BCD4(operand) .................................................................................................................. 235
5.8.1.4 UINT_TO_BCD4(operand) ............................................................................................................... 235

re
5.8.1.5 DINT_TO_BCD8(operand) ............................................................................................................... 235
5.8.1.6 UDINT_TO_BCD8(operand) ............................................................................................................ 235

5.8.2 BCDx_TO_(type)(x=2,4,8) ..................................................................................236


5.8.2.1
5.8.2.2
5.8.2.3
pa
BCD2_TO_SINT(operand)................................................................................................................ 236
BCD2_TO_USINT(operand)............................................................................................................. 236
BCD4_TO_INT(operand) .................................................................................................................. 236
cs
5.8.2.4 BCD4_TO_UINT(operand) ............................................................................................................... 236
5.8.2.5 BCD8_TO_DINT(operand) ............................................................................................................... 236
.cn

5.8.2.6 BCD8_TO_UDINT(operand) ............................................................................................................ 237

5.8.3 (type)_TO_SINT ..................................................................................................238


5.8.3.1 USINT_TO_SINT(operand) .............................................................................................................. 238
5.8.3.2 INT_TO_SINT(operand) ................................................................................................................... 238
w

5.8.3.3 UINT_TO_SINT(operand) ................................................................................................................ 238


5.8.3.4 DINT_TO_SINT(operand) ................................................................................................................ 238
5.8.3.5 UDINT_TO_SINT(operand).............................................................................................................. 238
w

5.8.4 (type)_TO_USINT ...............................................................................................239


5.8.4.1 SINT_TO_USINT(operand) .............................................................................................................. 239
w

5.8.4.2 INT_TO_USINT(operand) ................................................................................................................ 239


5.8.4.3 UINT_TO_USINT(operand).............................................................................................................. 239
://

5.8.4.4 DINT_TO_USINT(operand).............................................................................................................. 239


5.8.4.5 UDINT_TO_USINT(operand)........................................................................................................... 239

5.8.5 (type)_TO_INT ....................................................................................................240


tp

5.8.5.1 SINT_TO_INT(operand) ................................................................................................................... 240


5.8.5.2 USINT_TO_INT(operand) ................................................................................................................ 240
ht

5.8.5.3 UINT_TO_INT(operand)................................................................................................................... 240


5.8.5.4 DINT_TO_INT(operand)................................................................................................................... 240
5.8.5.5 UDINT_TO_INT(operand)................................................................................................................ 240

5.8.6 (type)_TO_UINT..................................................................................................241
5.8.6.1 SINT_TO_UINT(operand) ................................................................................................................ 241
5.8.6.2 USINT_TO_UINT(operand).............................................................................................................. 241
5.8.6.3 INT_TO_UINT(operand)................................................................................................................... 241

c-9
TABLE OF CONTENTS B-63823EN/02

5.8.6.4 DINT_TO_UINT(operand)................................................................................................................ 241


5.8.6.5 UDINT_TO_UINT(operand)............................................................................................................. 241

5.8.7 (type)_TO_DINT..................................................................................................242
5.8.7.1 SINT_TO_DINT(operand) ................................................................................................................ 242

/
5.8.7.2 USINT_TO_DINT(operand).............................................................................................................. 242

om
5.8.7.3 INT_TO_DINT(operand)................................................................................................................... 242
5.8.7.4 UINT_TO_DINT(operand)................................................................................................................ 242
5.8.7.5 UDINT_TO_DINT(operand)............................................................................................................. 242

5.8.8 (type)_TO_UDINT...............................................................................................243

s.c
5.8.8.1 SINT_TO_UDINT(operand).............................................................................................................. 243
5.8.8.2 USINT_TO_UDINT(operand)........................................................................................................... 243
5.8.8.3 INT_TO_UDINT(operand)................................................................................................................ 243
5.8.8.4 UINT_TO_UDINT(operand)............................................................................................................. 243

re
5.8.8.5 DINT_TO_UDINT(operand)............................................................................................................. 243

5.9 IL PMC OPERATIONS .............................................................................. 244


5.9.1
5.9.1.1
5.9.1.2
pa
Add BCD..............................................................................................................245
PMC_ADD_BCD2(in1, in2) ............................................................................................................. 245
PMC_ADD_BCD4(in1, in2) ............................................................................................................. 245
cs
5.9.1.3 PMC_ADD_BCD8(in1, in2) ............................................................................................................. 245

5.9.2 Subtract BCD .......................................................................................................246


.cn

5.9.2.1 PMC_SUB_BCD2(in1, in2) .............................................................................................................. 246


5.9.2.2 PMC_SUB_BCD4(in1, in2) .............................................................................................................. 246
5.9.2.3 PMC_SUB_BCD8(in1, in2) .............................................................................................................. 246

5.9.3 Multiply BCD.......................................................................................................247


w

5.9.3.1 PMC_MUL_BCD2(in1, in2) ............................................................................................................. 247


5.9.3.2 PMC_MUL_BCD4(in1, in2) ............................................................................................................. 247
w

5.9.3.3 PMC_MUL_BCD8(in1, in2) ............................................................................................................. 247

5.9.4 Divide BCD..........................................................................................................248


w

5.9.4.1 PMC_DIV_BCD2(in1, in2) ............................................................................................................... 248


5.9.4.2 PMC_DIV_BCD4(in1, in2) ............................................................................................................... 248
5.9.4.3 PMC_DIV_BCD8(in1, in2) ............................................................................................................... 248
://

5.9.5 Modulus BCD ......................................................................................................249


5.9.5.1 PMC_MOD_BCD2(in1, in2)............................................................................................................. 249
tp

5.9.5.2 PMC_MOD_BCD4(in1, in2)............................................................................................................. 249


5.9.5.3 PMC_MOD_BCD8(in1, in2)............................................................................................................. 249

5.9.6 Trigger..................................................................................................................250
ht

5.9.6.1 R_TRIG(in) ........................................................................................................................................ 250


5.9.6.2 F_TRIG(in)......................................................................................................................................... 250

5.9.7 Decode..................................................................................................................251
5.9.7.1 PMC_DECODE_SINT(in, base, n, q) ............................................................................................... 251
5.9.7.2 PMC_DECODE_USINT(in, base, n, q) ............................................................................................ 251
5.9.7.3 PMC_DECODE_INT(in, base, n, q) ................................................................................................. 251

c-10
B-63823EN/02 TABLE OF CONTENTS

5.9.7.4 PMC_DECODE_UINT(in, base, n, q)............................................................................................... 252


5.9.7.5 PMC_DECODE_DINT(in, base, n, q)............................................................................................... 252
5.9.7.6 PMC_DECODE_UDINT(in, base, n, q)............................................................................................ 252

5.9.8 Check Even Parity ................................................................................................253

/
5.9.8.1 PMC_EVPAR_BYTE(in1) ................................................................................................................ 253

om
5.9.8.2 PMC_EVPAR_WORD(in1) .............................................................................................................. 253
5.9.8.3 PMC_EVPAR_DWORD(in1) ........................................................................................................... 253

5.9.9 Check Odd Parity .................................................................................................254


5.9.9.1 PMC_ODPAR_BYTE(in1)................................................................................................................ 254

s.c
5.9.9.2 PMC_ODPAR_WORD(in1).............................................................................................................. 254
5.9.9.3 PMC_ODPAR_DWORD(in1)........................................................................................................... 254

5.9.10 Window ................................................................................................................254

re
5.9.10.1 PMC_WINDOW(ar, n, err)................................................................................................................ 254

5.9.11 EXIN ....................................................................................................................255


5.9.11.1 PMC_EXIN(head, cmd, dt, err) ......................................................................................................... 255

5.10
5.9.12
5.9.12.1
pa
AXCTL.................................................................................................................255
PMC_AXCTL(r, grp, cmd, dt1, dt2, err) ........................................................................................... 255

NOTE ON IL PROGRAMMING ................................................................. 256


cs
6 OPERATION ....................................................................................... 257
6.1 OVERVIEW ............................................................................................... 258
.cn

6.2 SOFT KEY-BASED PMC MENU SELECTION PROCEDURE .................. 259


6.2.1 PMC Basic Menu .................................................................................................259
6.2.2 PMC Screen Transition and Related Soft Keys ...................................................261
w

6.3 DISPLAYING PMC INPUT/ OUTPUT SIGNALS AND INTERNAL RELAY


(PMCDGN) ................................................................................................ 262
w

6.3.1 Title Data Display (TITLE)..................................................................................262


6.3.2 Signal Status Display (STATUS).........................................................................263
w

6.3.3 Alarm Screen (ALARM)......................................................................................272


6.3.4 Trace Screen (TRACE) ........................................................................................273
://

6.3.5 Displaying and Setting the Configuration Status of I/O Devices (I/OCHK) .......285
6.4 DISPLAYING AND SETTING THE PMC PARAMETERS (PMCPRM) ...... 289
tp

6.4.1 Overview ..............................................................................................................289


6.4.2 Input PMC Parameters from MDI Panel ..............................................................289
ht

6.4.3 Setting and Display Screen...................................................................................291


6.4.4 Setting Screen (SETING) .....................................................................................296
6.5 SEQUENCE PROGRAM EXECUTION ..................................................... 311
6.5.1 Starting and Stopping a Sequence Program .........................................................311
6.5.2 Forced Termination of Sequence Program...........................................................311

c-11
TABLE OF CONTENTS B-63823EN/02

6.6 WRITING, READING, AND VERIFYING THE SEQUENCE PROGRAM


AND PMC PARAMETER DATA (I/O) ........................................................ 312
6.6.1 I/O Screen.............................................................................................................312
6.6.2 Outputting to and Inputting from Memory Cards ................................................315

/
6.6.3 Memory Card List Screen ....................................................................................318

om
6.6.4 Outputting to and Inputting from Flash ROM......................................................320
6.6.5 Outputting to and Inputting from Floppy .............................................................321
6.6.6 Floppy List Screen ...............................................................................................324

s.c
6.6.7 Outputting to and Inputting from Other Input/Output Devices............................325
6.6.8 Port Setting Screen ...............................................................................................327
6.6.9 I/O Screen Error Messages...................................................................................329

re
APPENDIX
A
A.1 pa
WINDOW FUNCTIONS ....................................................................... 335
FORMATS OF CONTROL DATA .............................................................. 336
A.1.1 The Note about the Address Used for Control Data.............................................337
cs
A.2 LOW-SPEED RESPONSE AND HIGH-SPEED RESPONSE.................... 339
A.2.1 Note on the Programming of a Low-speed Response Window Instruction .........340
.cn

A.3 LIST OF WINDOW FUNCTIONS............................................................... 341


A.4 CNC INFORMATION................................................................................. 347
A.4.1 Reading CNC System Information (High-speed Response) ................................347
w

A.4.2 Reading a Tool Offset (High-speed Response) ....................................................349


A.4.3 Writing a Tool Offset (Low-speed Response)......................................................351
w

A.4.4 Reading a Workpiece Origin Offset Value (High-speed Response) ....................353


A.4.5 Writing a Workpiece Origin Offset Value (Low-speed Response)......................355
w

A.4.6 Reading a Parameter (High-speed Response) ......................................................357


A.4.7 Writing a Parameter (Low-speed Response) ........................................................359
://

A.4.8 Reading Setting Data (High-speed Response) .....................................................361


A.4.9 Writing Setting Data (Low-speed Response) .......................................................363
tp

A.4.10 Reading a Custom Macro Variable (High-speed Response) ................................365


A.4.11 Writing a Custom Macro Variable (Low-speed Response)..................................367
ht

A.4.12 Reading the CNC Alarm Status (High-speed Response) .....................................369


A.4.13 Reading the Current Program Number (High-speed Response)...........................372
A.4.14 Reading the Current Sequence Number (High-speed Response) .........................374
A.4.15 Reading Modal Data (High-speed Response) ......................................................376
A.4.16 Reading Diagnosis Data (High-speed Response).................................................383
A.4.17 Reading Value of the P-code Macro Variable (High-speed Response) ...............385

c-12
B-63823EN/02 TABLE OF CONTENTS

A.4.18 Writing Value of the P-code Macro Variable (Low-speed Response) .................387
A.4.19 Reading CNC Status Information (High-speed Response) ..................................389
A.4.20 Reading the Current Program Number (8-digit Program Numbers)
(High-speed Response).........................................................................................392

/
A.4.21 Entering Data on the Program Check Screen (Low-speed Response) .................394

om
A.4.22 Reading Clock Data (Date and Time) (High-speed Response) ............................396
A.4.23 Specifying the Number of the Program for I/O Link(Low-speed Response).......398
A.5 AXIS INFORMATION ................................................................................ 400

s.c
A.5.1 Reading the Actual Velocity of Controlled Axes (High-speed Response)...........400
A.5.2 Reading the Absolute Position (Absolute Coordinates) of Controlled Axes
(High-speed Response).........................................................................................402

re
A.5.3 Reading the Machine Position (Machine Coordinates) of Controlled Axes
(High-speed Response).........................................................................................404
A.5.4

A.5.5
pa
Reading a Skip Position (Stop Coordinates of Skip Operation (G31)) of
Controlled Axes (High-speed Response) .............................................................407
Reading the Servo Delay for Controlled Axes (High-speed Response)...............409
cs
A.5.6 Reading the Acceleration/Deceleration Delay on Controlled Axes
(High-speed Response).........................................................................................411
.cn

A.5.7 Reading the Feed Motor Load Current Value (A/D Conversion Data)
(High-speed Response).........................................................................................413
A.5.8 Reading the Actual Spindle Speed (High-speed Response).................................415
w

A.5.9 Reading the Relative Position on a Controlled Axis (High-speed Response)......417


A.5.10 Reading the Remaining Travel (High-speed Response).......................................419
w

A.5.11 Reading Actual Spindle Speeds (High-speed Response) .....................................421


A.5.12 Entering Torque Limit Data for the Digital Servo Motor
w

(Low-speed Response) .........................................................................................425


A.5.13 Reading Load Information of the Spindle Motor (Serial Interface)
://

(High-speed Response).........................................................................................427
A.5.14 Reading the servo data of the control axes (High-speed Response).....................430
tp

A.5.15 Reading the Estimate Disturbance Torque Data (High-speed Response) ............437
A.5.16 Reading Fine Torque Sensing Data (Statistical Calculation Results)
ht

(High-speed Response).........................................................................................441
A.5.17 Reading Fine Torque Sensing Data (Store Data) (High-speed Response) ...........443
A.5.18 Presetting the Relative Coordinate (Low-speed Response) .................................450
A.6 TOOL LIFE MANAGEMENT FUNCTION .................................................. 453
A.6.1 Reading The Tool Life Management Data (Tool Group Number)
(High-speed Response).........................................................................................453

c-13
TABLE OF CONTENTS B-63823EN/02

A.6.2 Reading Tool Life Management Data (Number of Tool Groups)


(High-speed Response).........................................................................................455
A.6.3 Reading Tool Life Management Data (Number of Tools)
(High-speed Response).........................................................................................457

/
A.6.4 Reading Tool Life Management Data (Tool Life) (High-speed Response) .........459

om
A.6.5 Reading Tool Life Management Data (Tool Life Counter)
(High-speed Response).........................................................................................461
A.6.6 Reading Tool Life Management Data (Tool Length Compensation Number (1):

s.c
Tool Number) (High-speed Response).................................................................463
A.6.7 Reading Tool Life Management Data (Tool Length Compensation Number (2):
Tool Order Number) (High-speed Response) ......................................................465

re
A.6.8 Reading Tool Life Management Data (Cutter Radius Compensation Number (1):
Tool Number) (High-speed Response).................................................................467
A.6.9

A.6.10
pa
Reading Tool Life Management Data (Cutter Radius Compensation Number (2):
Tool Order Number) (High-speed Response) ......................................................469
Reading Tool Life Management Data (Tool Information (1): Tool Number)
cs
(High-speed Response).........................................................................................471
A.6.11 Reading Tool Life Management Data (Tool Information (2):
.cn

Tool Order Number) (High-speed Response) ......................................................473


A.6.12 Reading Tool Life Management Data (Tool Number) (High-speed Response)...475
A.6.13 Reading the Tool Life Management Data (Tool Life Counter Type)
w

(High-speed Response).........................................................................................477
A.6.14 Registering Tool Life Management Data (Tool Group) (Low-speed Response) .479
w

A.6.15 Writing Tool Life Management Data (Tool Life) (Low-speed Response)...........481
A.6.16 Writing Tool Life Management Data (Tool Life Counter)
w

(Low-speed Response) .........................................................................................483


A.6.17 Writing Tool Life Management Data (Tool Life Counter Type)
://

(Low-speed Response) .........................................................................................485


A.6.18 Writing Tool Life Management Data (Tool Length Compensation Number (1):
tp

Tool Number) (Low-speed Response) .................................................................487


A.6.19 Writing Tool Life Management Data (Tool Length Compensation Number (2):
ht

Tool Order Number) (Low-speed Response) .......................................................489


A.6.20 Writing Tool Life Management Data (Cutter Compensation Number (1):
Tool Number) (Low-speed Response) .................................................................491
A.6.21 Writing Tool Life Management Data (Cutter Compensation Number (2):
Tool Order Number) (Low-speed Response) .......................................................493

c-14
B-63823EN/02 TABLE OF CONTENTS

A.6.22 Writing the Tool Life Management Data (Tool Information (1): Tool Number)
(Low-speed Response) .........................................................................................495
A.6.23 Writing the Tool Management Data (Tool Information (2): Tool Order Number)
(Low-speed Response) .........................................................................................497

/
A.6.24 Writing Tool Life Management Data (Tool Number) (Low-speed Response) ....499

om
A.6.25 Reading The Tool Life Management Data (Tool Group Number)
(8-digit tool number) (High-speed Response)......................................................501
A.6.26 Reading Tool Life Management Data (Tool Information (1): Tool Number)

s.c
(8-digit tool number) (High-speed Response)......................................................503
A.6.27 Registering Tool Life Management Data (Tool Group Number)
(8-digit tool number) (Low-speed Response).......................................................505

re
A.6.28 Reading Tool Life Management Data (Tool Length Compensation Number (1):
Tool Number) (8-digit tool number) (High-speed Response) .............................507
A.6.29

A.6.30
pa
Reading Tool Life Management Data (Cutter Compensation Number (1):
Tool Number) (8-digit tool number) (High-speed Response) .............................509
Writing Tool Life Management Data (Tool Length Compensation Number (1):
cs
Tool Number) (8-digit tool number) (Low-speed Response)...............................511
A.6.31 Writing Tool Life Management Data (Cutter Compensation Number (1):
.cn

Tool Number) (8-digit tool number) (Low-speed Response)...............................513


A.6.32 Writing the Tool Life Management Data (Tool Information (1): Tool Number)
(8-digit tool number) (Low-speed Response).......................................................515
w

A.6.33 Deleting Tool life Management Data (Tool Group) (Low-speed Response) .......517
A.6.34 Deleting Tool life Management Data (Tool Data) (Low-speed Response)..........519
w

A.6.35 Clearing Tool Life Management Data


(Tool Life Counter and Tool Information) (Low-speed Response) .....................521
w

A.6.36 Writing Tool Life Management Data (Arbitrary Group Number)


(Low-speed Response) .........................................................................................523
://

A.6.37 Writing Tool Life Management Data (Remaining Tool Life)


(Low-speed Response) .........................................................................................525
tp

A.7 TOOL MANAGEMENT FUNCTIONS ........................................................ 527


A.7.1 Exchange of Tool Management Data Numbers in a Magazine Management
ht

Table (Low-speed Response) ...............................................................................528


A.7.2 Search of empty pot (Low-speed Response) ........................................................531
A.7.3 New-register of a Tool Management Data (Low-speed Response)......................533
A.7.4 Writing a Tool Management Data (Low-speed Response) ..................................539
A.7.5 Deletion of a Tool Management Data (Low-speed Response).............................545
A.7.6 Reading a Tool Management Data (Low-speed Response) .................................547

c-15
TABLE OF CONTENTS B-63823EN/02

A.7.7 Writing each Tool Data (Low-speed Response)...................................................551


A.7.8 Search of Tool Management Data (Low-speed Response) ..................................555
A.7.9 Shifting Tool Management Data (Low-speed Response).....................................557
A.7.10 Reading a Decimal Point of the Customizing Data (Low-speed Response) ........559

/
A.7.11 Search of Empty Pot for Oversize Tool Use (Low-speed Response)...................561

om
A.7.12 Reading a Total Life Data (Low-speed Response)...............................................563

B DIFFERENCES BETWEEN PMC-SB7 ............................................... 565


B.1 SUPPORT OF OPTION BOARDS............................................................. 568

s.c
B.2 PROGRAMMING SOFTWARE ON PC ..................................................... 568
B.3 MACHINE REMOTE DIAGNOSIS PACKAGE........................................... 568
B.4 MONITORING AND EDITING ON CNC .................................................... 569

re
B.5 LEVEL3 ..................................................................................................... 569
B.6 MISCELLANEOUS PMC PARAMETERS.................................................. 570
B.7
B.8
pa
MISCELLANEOUS FEATURES OF MESSAGE........................................ 570
FEATURES OF TIMER/COUNTER........................................................... 571
cs
B.9 USE OF MDI KEY FOR INPUT ON CNC .................................................. 571
B.10 FA NETWORK BOARD ............................................................................. 571
B.11 EDIT ON-THE-FLY .................................................................................... 572
.cn

B.12 PASSWORD FUNCTION .......................................................................... 572


C ALARM MESSAGE LIST .................................................................... 573
w

C.1 PMC ALARMS/SYSTEM ALARMS............................................................ 574


C.2 PMC SYSTEM ALARM MESSAGES......................................................... 577
w

D CHINESE CHARACTER CODE, HIRAGANA CODE, AND SPECIAL


CODE LIST.......................................................................................... 579
w
://
tp
ht

c-16
B-63823EN/02 1.OVERVIEW

1 OVERVIEW

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

-1-
1.OVERVIEW B-63823EN/02

1.1 SYSTEM CONFIGURATION

The PMC-SD7 is used to create and execute sequence programs


conforming to the IEC61131-3 standard. The system requires the

/
following hardware and software (development software, etc.).

om
CNC

s.c
PC

Hardware
Built-in PMC

Ethernet

re
RS-232-C
Program HSSB
Machine tool

DI/DO

pa
• Sequence program start/stop • Sequence program editing, compiling,
cs
• Communication service down-/up-loading, start/stop

(up- and down-loading, online monitor) • Online monitor

Function
• Reference table display/setting • Reference table display/setting
.cn

• Writing of sequence program into flash • Writing of sequence program into flash
memory memory

• Printing

Software
w

FANUC PMC control software FANUC LADDER-IIIC.


w
w
://
tp
ht

-2-
B-63823EN/02 1.OVERVIEW

1.2 PMC BASIC CONFIGURATION

The basic configuration of the PMC is as shown below.

/
CNC

om
CNC control
Built-in PMC
unit
Internal Sequence External Machine tool
I/O I/O

s.c
re
pa
There are two types of PMC:

Internal relay

Those using programming that conforms with IEC61131-3, as


cs
described in this manual
• Those using existing FANUC proprietary instructions and related
items
.cn

For example, in the case of the Series 16i-B, the former is represented
by the PMC-SD7, while the latter is represented by the PMC-SB7
For these two types of PMC, the mapping and functions of the
interface signals between the CNC or machine tool and the PMC are
identical, and correspond on a one-to-one basis. Upon reference
w

from a PMC sequence program, only the address or instruction


declaration changes.
w

Therefore, upon reference from a CNC, open CNC PC function, or


external PMC application, the PMC signal address and so on are
converted to those corresponding to the corresponding PMC type.
w

Example: Emergency stop signal (*ESP)


PMC-SD7 PMC-SB7
://

%I00069 X008.4
%QG00069 G008.4
tp
ht

-3-
1.OVERVIEW B-63823EN/02

1.3 CONTENTS OF THIS MANUAL

1. Overview
2. Specifications

/
explains the PMC specifications, program structuring, data type,

om
and references.
3. I/O Link
4. The LD Instruction Group
explains the LD programming instructions that can be used with
the PMC.

s.c
5. The IL Instruction Group
explains the IL programming instructions that can be used with the
PMC.
6. PMC Operation

re
explains the PMC operations that can be performed using the CNC
display.
7. WINDOW Functions (Appendix)

pa
8. Differences between PMC-SB7 (Appendix)
9. Alarm message list (Appendix)
10.CHINESE character code, HIRAGANA code, and special code list
(Appendix)
cs
.cn
w
w
w
://
tp
ht

-4-
B-63823EN/02 2.SPECIFICATIONS

2 SPECIFICATIONS

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

-5-
2.SPECIFICATIONS B-63823EN/02

2.1 SPECIFICATIONS OF PMC


The following table lists the specifications of the PMC-SD7.
PMC-SD7
Type of PMC

/
Series 16i/160i/18i/180i/21i/210i-B

om
LD (Ladder Diagram)
Programming language
IL(Instruction List)
Number of ladder levels 2
Ladder execution cycle 8 ms
0.033 us/step
Instruction processing time

s.c
(relay instruction)
256 KB
Program size 512 KB
768 KB

re
I/O points
• I/O Link (Master)
Input Max. 2,048(Note)
Output
Programmer

NOTE
pa Max. 2,048(Note)
FANUC LADDER-IIIC
cs
Maximum of basic input/output points are
1024/1024 points. I/O Link expansion option
extends the maximum to 2048/2048 points.
.cn

Programming Language
LD and IL are supported as the programming language.
w

About LD Logic
Ladder Diagram (LD) logic is one of five programming languages
specified by the IEC 61131-3 standard. This graphical language is
w

likely the most popular control language in use today. LD logic is


represented as a sequence of rungs with a series of instructions placed
w

on each rung. Generally, each rung is executed from left to right as


power flows through the rung and subsequent rungs are generally
executed from top to bottom. A basic LD instruction set, including
://

arithmetic, logical and program control operations, is supported by


PMC-SD7.
tp
ht

-6-
B-63823EN/02 2.SPECIFICATIONS

About Instruction List Logic


Instruction List (IL) logic is one of five programming languages
specified by the IEC 61131-3 standard. This text language is
accumulator-based and much like the assembly languages used for
programming microprocessors. In its simplest form an IL program

/
proceeds like the following:

om
1) Load an accumulator with a data value.
2) Perform an operation on the accumulator, saving the result in the
accumulator.
3) Store the accumulator's value to memory (a variable).

s.c
4) Do another accumulator load or operation, etc.

(Accumulators)
IL logic is accumulator-based, much like the assembler languages

re
used for programming microprocessors. Most IL instructions operate
on the content of an accumulator and then store the result of the
operation back to the accumulator. Most functions use an accumulator

Number of Ladder Levels


pa
to store the result of an operation. The content of both accumulators is
retained until modified by an instruction or function.
cs
A sequence program for PMC consists of two parts: 1st level sequence
and 2nd level sequence.
.cn

Priority of execution

8m s 8m s 8m s 8m s

7m s 7m s 7m s
w

1 s t le v e l

Division 1 Division 1
2 n d le v e l
w

Division 2

Division n
w

S y s te m e tc

Fig. 2.1 About priority of execution.


://

The 1st level sequence part operates every 8 ms (high-speed


sequential operation).
tp

If the 1st level sequence part is long, the total operating time,
including the 2nd level sequence part, is extended. Therefore the 1st
level sequence part must be programmed to be processed in as short
ht

time as possible.
The 2nd level sequence part operates every 8×n ms. Here n is a
dividing number for the 2nd level sequence part.
The 2nd level sequence part is divided automatically when the
sequence program is executed. The time for one cycle of the sequence
program is displayed on the TITLE screen.

-7-
2.SPECIFICATIONS B-63823EN/02

(1) Division of the 2nd level sequence part


The 2nd level sequence part must be divided in order to execute
the 1st level sequence part. For example a sequence program is
executed in the following sequence when the dividing number is
n. (See Fig. 2.1)
After the last division of 2nd level sequence part (division n) is

/
executed, the sequence program is executed again from the

om
beginning. Thus, when the dividing number is n, the cycle of
execution is 8msec×n.
The 1st level sequence operates every 8msec, and the 2nd level
sequence every 8×n msec. If the steps of the 1st level sequence is
increased, the steps of the 2nd level sequence operating within

s.c
8msec becomes less, thereby increasing the dividing number and
making the processing time longer. Therefore, it is desirable to
program so as to reduce the 1st level sequence to a minimum.
In the PMC-SD7, 7msec of 8msec is assigned to execution of the

re
1st and 2nd level sequences.
(2) 1st level sequence part
Only short-width pulse signals are processed. These signals

pa
include emergency stop, over-travel of each axis, reference point
return deceleration, external deceleration, skip, measuring
position arrival and feed hold signals.
cs
Instruction Processing Time
Relay instructions are processed at high speed, such that it requires
.cn

0.033 us to execute one step.

Program Size
A FANUC PMC program is contained in the flash memory of the
CNC.
w

The size of the flash memory varies depending on which option is


installed
w

(ex., 256KB, 512KB, 768KB).

I/O Points
w

I/O units are connected via the FANUC I/O Link. The maximum
number of I/O points is as follows.
Series 16i/160i/18i/180i/21i/210i-B
://

I/O Link master function: Input 1,024/ Output 1,024


Series 16i/160i/18i/180i/21i/210i-B (With I/O Link expansion option)
I/O Link master function: Input 2,048/ Output 2,048
tp

Programmer
A sequence program is created and edited using a dedicated
ht

programmer (FANUC LADDER-IIIC).


A created program is transferred to the PMC and executed.
The programmer supports online operations.

-8-
B-63823EN/02 2.SPECIFICATIONS

2.2 DATA TYPES

This section explains the data types which can be used with PMC
programs.

/
The PMC can use the basic IEC61131-3 data types shown below.

om
Keyword Data type Bit count Range
The value obtained with this
BOOL Boolean 1 data type is either 0 (false) or 1
(true).
SINT 8-bit integer 8 Range of values obtained with

s.c
INT 16-bit integer 16 this data type:
DINT 32-bit integer 32 -2bit count -1 to 2bit count -1-1
Unsigned 8-bit
USINT 8
integer
Range of values obtained with

re
Unsigned 16-bit
UINT 16 this data type:
integer
0 to 2bit count -1
Unsigned 32-bit
UDINT 32

BYTE
WORD
DWORD
integer
Byte
Word
pa
Double-word
8
16
32
--
cs
This manual uses the IEC61131-3 general data type that uses prefix
ANY as shown below.
.cn

ANY
ANY_NUM
ANY_INT
SINT, INT, DINT, USINT, UINT, UDINT
w

ANY_BIT
BOOL, BYTE, WORD, DWORD
In a location indicated by the general data type, basic data of that data
w

type can be specified.


w
://
tp
ht

-9-
2.SPECIFICATIONS B-63823EN/02

2.3 REFERENCES

2.3.1 Reference Address

/
PMC-SD7

om
The PMC-SD7 address comprises a "%" letter, one or more alphabets,
and digits as defined in IEC61131.

%I 1024

s.c
%I : The type of the signal ("%" + one or more alphabets)
1024 : Bit or word number

Bit address and word address are distinguished by the first alphabet

re
letter related with memory type. %R represents word address and
others like %I, %Q, %M and %S represents bit address. Bit address at
the beginning of each byte/word/dword can be used in functional

PMC-SB7
pa
instructions operating on byte/word/dword data.
cs
The PMC-SB7 address comprises the address number and the bit
number in the format as shown below.

X 127. 7
.cn

X 127 : Address number (digits after alphabet)


7 : Bit number (0 to 7)
w

An alphabet must be specified at the beginning of the address number


to indicate the type of the signal. When specifying the address in the
byte unit in the functional instruction, specify X127. In this case, “.”
w

and the bit number are not necessary.


w
://
tp
ht

- 10 -
B-63823EN/02 2.SPECIFICATIONS

2.3.2 User References


This section explains the references which can be used in a PMC
program. The following lists the valid range of PMC addresses.
Name Range Size Attribute Remarks Corresponding

/
PMC-SB7

om
references
%I 1- 1024 1-bit (BOOL type) Read-only Input from I/O Link 1st channel X0.0 - X127.7
10001 - 11024 Input from I/O Link 2nd channel *1 X200.0 - X327.7
80001 - 81024 Input from built-in I/O *2 X1000.0 - X1127.7
%IF 1- 6144 1-bit (BOOL type) Read-only Input from CNC *3 F0.0 - F767.7

s.c
10001 - 16144 *4 F1000.0 - F1767.7
20001 - 26144 *4 F2000.0 - F2767.7
30001 - 36144 *5 F3000.0 - F3767.7
%Q 1- 1024 1-bit (BOOL type) Output to I/O Link 1st channel Y0.0 - Y127.7

re
10001 - 11024 Output to I/O Link 2nd channel *1 Y200.0 - Y327.7
80001 - 81024 Output to built-in I/O *2 Y1000.0 - Y1127.7
%QG 1- 6144 1-bit (BOOL type) Output to CNC *3 G0.0 - G767.7
10001 - 16144 *4 G1000.0 - G1767.7

%R
20001 - 26144
30001 - 36144
1- 5000 16-bit (WORD type) Retentive
pa
Data Register
*4
*5
G2000.0 - G2767.7
G3000.0 - G3767.7
D0.0 - D9999.7
cs
%M 1- 64000 1-bit (BOOL type) Internal relay R0.0 - R7999.7
%ME 1- 64000 1-bit (BOOL type) *7 E0.0 - E7999.7
%MA 1- 2000 1-bit (BOOL type) Message display request A0.0 - A249.7
.cn

%MK 1- 800 1-bit (BOOL type) Retentive Internal relay K0.0 - K99.7
%S 1- 3872 1-bit (BOOL type) Read-only System area *6 R9016.0 - R9499.7
%ST 1- 64 1-bit (BOOL type) Read-only *6 R9008.0 - R9015.7
%SA 1- 2000 1-bit (BOOL type) Read-only *8 A9000.0 - A9249.7
%SK 1- 160 1-bit (BOOL type) Retentive *9 K900.0 - K919.7
w
w
w
://
tp
ht

- 11 -
2.SPECIFICATIONS B-63823EN/02

NOTE
1 These references are used for 2nd channel of I/O
Link. I/O link expansion option is necessary.
2 This area is reserved for PMC. I/O can not be
assigned in it.

/
Don’t use it in sequence program.

om
3 This area contains PMC reserve. Actual available
references depend on the configuration of CNC
system.
4 This area is used for multi path system. It contains
PMC reserve. Actual available references depend

s.c
on the configuration of CNC system.
5 This area is for PMC reserve. Don’t use it in
sequence program.

re
6 This area is used for PMC system software as
special relay. Please use these according to the
explanation of each address.

(%M). pa
7 This area can be used equally as internal relay

These relays (%ME) are volatile type. However,


cs
these can be input/output from/to memory card,
etc, as PMC parameter.
8 These references are message display state
.cn

signals that have one-to-one correspondence to


message display request signal (%MA). It is
impossible to write into these references.
9 This area is used for PMC control software. Please
use these signals according to each explanation.
w
w
w
://
tp
ht

- 12 -
B-63823EN/02 2.SPECIFICATIONS

2.3.3 System References


The following explains the system references used by the PMC control software.
Address Name Explanation
%S601 #ALW_OFF Always OFF signal.

/
%S602 #ALW_ON Always ON signal.

om
%S606 #T_200MS 200 ms cycle signal. (104 ms ON, 96 ms OFF)
%S607 #T_SEC 1 sec cycle signal. (504 ms ON, 496 ms OFF)
STOP to RUN transition signal. Turned ON when
%ST57 #STP_RUN
the current scan is the first scan.
RUN to STOP transition signal. Reset from 1 (ON)
%ST58 #RUN_STP

s.c
to 0 (OFF) when the current scan is the last scan.
%S603 #RUNNING RUN status signal. Turned ON when during RUN.
Prevents the edit (output) operation of the sequence
%SK1 # NEN_OUT
program.

re
%SK2 # EN_PRG Validates the program debugging function.
%SK3 # RUN_NAT Manually (soft key) executes a sequence program.
Enables display of data input on the memory content
%SK5 # EN_RAM

%SK8

%SK15
# NEN_DTC

# EN_IN
pa
display screen.
The PMC parameter data table control screen is not
displayed.
Validates the sequence program edit function.
cs
The ladder program is automatically written to
%SK17 # FROM_AT
F-ROM after editing.
%SK19 # DSP_RUN “RUN” or “STOP” soft key is displayed.
.cn

%SK23 #HIDEPRM The PMC parameter screen is not displayed.


The PMC parameter is not changed by reading of
%SK24 #PROTPRM
the I/O screen.
%SK49 #EN_OVR The override mode becomes enabled.
Automatically starts the trace function (TRACE)
w

%SK54 #TRC_AT
when the power is turned on.
w
w
://
tp
ht

- 13 -
2.SPECIFICATIONS B-63823EN/02

RUN to STOP Transition Signal, STOP to RUN Transition Signal and RUN
Status Signal

/
om
s.c
re
(i) “STOP to RUN transition signal” (%ST57)
When a STOP to RUN event is detected on system software, this

pa
signal will be turned on during the 1st scan of LADDER program
after LADDER started. This signal has individual status
corresponding the scan of each LADDER execution level. This
signal is completely turned on during whole of the 1st scan in
cs
any execution level of LADDER program.
• When does a STOP to RUN event happen?
• LADDER starting at every power on cycle
.cn

• Pressing a ”RUN” soft-key on a PMC screen


• “RUN” commanded by FANUC LADDER-IIIC
Referring this signal in a LADDER program, you can recognize
and handle a ”STOP to RUN” transition event. You can program
w

a pre-processing for LADDER execution.

NOTE
w

This signal is available only in LADDER program.


Don’t refer this signal on other systems or
w

programs, such a network board, C executor


program, FOCAS1/Ethernet or FOCAS1/HSSB
library etc. because this signal has individual status
://

in each LADDER execution.


tp
ht

- 14 -
B-63823EN/02 2.SPECIFICATIONS

(ii) “RUN to STOP transition signal” (%ST58)


When a RUN to STOP event is detected on system software, this
signal will be turned off during the last scan of LADDER
program before LADDER stopped. This signal has individual
status corresponding the scan of each LADDER execution level.
This signal is completely turned off during the last scan before

/
any execution level of LADDER program stops.

om
• When does a RUN to STOP event happen?
• Pressing a ”STOP” soft-key on a PMC screen
• ”STOP” commanded by FANUC LADDER-IIIC
• Storing a LADDER program to PMC on PMC ”I/O” screen

s.c
• Storing a LADDER program to PMC using FANUC
LADDER-IIIC
Referring this signal in a LADDER program, you can recognize
and handle a ”RUN to STOP” transition event. You can program

re
a post-processing for LADDER execution (i.e. pre-processing for
stopping of LADDER execution). For example, set or reset any
appropriate signals into certain condition for the safety.

NOTE pa
1 This signal is available only in LADDER program.
Don’t refer this signal on other systems or
cs
programs, such a network board, C executor
program, FOCAS1/Ethernet or FOCAS1/HSSB
library etc. because this signal has individual status
.cn

in each LADDER execution level.


2 You can not handle this event using this signal at a
power off sequence and system alarm of CNC in
which the execution of LADDER and I/O scanning
w

are completely shut down.


w

(iii) “RUN status signal” (%S603)


Referring this signal on other systems or programs, such a
network board, C executor program, FOCAS1/Ethernet or
w

FOCAS1/HSSB library etc. you can know the status of


LADDER program execution.
://
tp
ht

- 15 -
2.SPECIFICATIONS B-63823EN/02

2.3.4 Message Display Reference

Function
PMC can display messages on the CNC screen using the CNC
external operator and alarm message functions. An external alarm

/
message can also be specified with its message number to place the

om
CNC in the alarm state.
To use this function, create message data using a programmer
(FANUC LADDER-IIIC) and store it in the message data table.
When a message display request memory bit (reference%MAxx) is
turned on using the sequence program, the corresponding message in

s.c
the message data table is displayed.

Message display request memory (RAM) Message data table


(written into ROM)

re
Message data corresponding to
%MA1 %MA1 reference%MA1
%MA2
Message data corresponding to
: %MA2
reference%MA2
: :
:
:
:
:
:
:

pa

:
:
:
:
:
:

Message data corresponding to



cs
%MA2000 %MA2000
reference%MA2000

Message display request memory and message data table


.cn

Message Display Request Memory


Message display request memory consists of 2000 bits corresponding
to reference%MA1 to reference%MA2000. Each bit corresponds to
one message data item. The entire memory indicates up to 2000
w

message display requests. To display a message on the CNC screen,


set the corresponding display request memory bit to "1". To erase
the message from the screen, set the corresponding display request
w

memory bit to "0".


w

Message Data Table


This table is used to store message data corresponding to message
display request memory bits. It is written into program memory
://

together with the sequence program.

Number of Characters Consisting of a Message


tp

Messages are displayed on the NC alarm and operator message


screens. The number of characters that can be displayed on the
screen is 32 (32 bytes) for an alarm message or 255 (255 bytes) for an
ht

operator message.
An alphanumeric character requires 1 byte. For other special
characters including half-size kana characters and kanji characters
(full-size characters), note the following: a half-size kana character
requires 2 bytes, a kanji character requires 4 bytes, and character "@"
used to code a special character requires 1 byte.

- 16 -
B-63823EN/02 2.SPECIFICATIONS

Message Number
Always specify a message number for each message data item.
The relationships between message numbers and their display are
shown below:
Path Message Destination
Display

/
number numbers CNC screen

om
Alarm screen Alarm messages
1000 to 1999
(on path 1) - Path 1 is placed in the alarm state.
2000 to 2099 Operator messages
1 Operator messages (with no
Operator
message numbers)
message

s.c
2100 to 2999 - Only message data is displayed,
screen
and no message number is
displayed.
Alarm screen Alarm message
2 1000 to 1999
(on path 2) - Path 2 is placed in the alarm state.

re
Alarm screen Alarm message
3 1000 to 1999
(on path 3) - Path 3 is placed in the alarm state.

NOTE
pa
If a message number other than the above is
specified, no message is displayed.
cs
Path Number
Always specify a path number for each message data item.
.cn

Each message is displayed on the screen for the path indicated by the
number.

NOTE
w

If a nonexistent path number such as 0 is specified,


no message is displayed.
w

Setting Message Data


Input message data characters using a programmer. Kana and kanji
w

characters can be input as numeric data with a special symbol "@".


See the later section "Inputting kana and kanji characters" for details.
://

Number of Displayed Messages


Up to four alarm messages or one operator message can be displayed
at a time.
tp

NOTE
The number of messages that can be displayed at
ht

a time may differ depending on the NC model or


setting.

- 17 -
2.SPECIFICATIONS B-63823EN/02

Message Display Order


When multiple message display request memory bits are turned on,
which message is displayed first is unpredictable.
When the number of message display request memory bits that are
turned on exceeds the maximum number of messages that can be

/
displayed at a time, the excess message display requests are not

om
executed, but held as long as they are on. When the displayed
messages are cleared, the message display requests being held are
recognized, then the corresponding messages are displayed. At this
time, which message display requests are recognized is unpredictable.

s.c
Using the Message Display Function Together with the External Data Input
Function
Use the PMC_EXIN functional instruction to perform external tool
compensation, external workpiece number search, and other

re
operations using the message display function, together with the
external data input function which uses the same interface.

Numeric Data Display


pa
Once programmed, message data is treated as fixed data that cannot be
modified. For numeric values to be made variable during execution,
define a memory address in message data and set numeric data in the
cs
memory using the sequence program to display any numeric data.
Using this function, data such as a tool number that frequently
changes during automatic operation can be displayed. See the later
.cn

section "Setting numeric data display" for details.

Option
To use the message display function, the CNC external data input or
w

message display option is required.


w
w
://
tp
ht

- 18 -
B-63823EN/02 2.SPECIFICATIONS

Setting Numeric Data Display


To display numeric data, define, in message data, the number of digits
of the numeric value and the address in memory containing the
numeric data. The data for defining numeric data must be enclosed
in brackets ([]) to distinguish it from other message data. Therefore,

/
brackets ([]) cannot be used as message display symbols because they

om
are used for numeric data. Set data in brackets as follows:

[nbid, ]
Address at which numeric data is stored

s.c
Binary-format data is set for the specified numeric data.
Set the following information for nbid:
n: Specifies whether the variable is signed or unsigned.

re
Set "I" to reference the numeric data as a signed variable.
Set "U" to reference it as an unsigned variable.

pa
b: Specifies a byte count. (Specify 1, 2, or 4.)
i: Specifies the number of digits of the integer part. (Specify 0 to 8.)
d: Specifies the number of digits of the fraction part. (Specify 0 to
cs
An address for PMC-SD7 (such as %R or %I) can be used for the
address at which numeric data is stored.
.cn

Example: Displaying UINT-type numeric data with a 5-digit integer


part and 3-digit fraction part from %R1 using a PMC-SD7
address
[U253,R1]
w

NOTE
1 The total number of digits of the integer and
w

fraction parts must not exceed 8.


2 For erroneous numeric data such as data
consisting of more than eight digits, a blank is
w

displayed.
3 The numeric data of address of the BYTE
://

boundary such as %I1, %I9 or %I17 is displayed.


When the address is not the BYTE boundary such
as %I2, %I3 or %I4, the value that rounded in the
tp

BYTE boundary such as "%I1" is displayed.


4 The % of address (such as %R) within the
message data is unnecessary.
ht

Inputting Kana and Kanji Characters


When the personal computer environment in which the programmer
runs supports Japanese-language input, kana and kanji characters can
directly be input. When the environment does not support
Japanese-language input, input kana and kanji characters as follows:

- 19 -
2.SPECIFICATIONS B-63823EN/02

Half-size Kana Characters


1 Data format
Input the numeric codes corresponding to desired kana characters
between @ and @.
2 Input method

/
Input kana characters using their numeric codes by referencing

om
the character code table given later. One kana character
requires 2 bytes. Alphanumeric characters can also be input using
their numeric codes.
3 Example
Inputting ATC ? OK:

s.c
Kanji Characters (Full-size Characters)

re
1 Data format
Input the numeric codes corresponding to desired kanji

2 Input method pa
characters between @02 and 01@.

Input kanji characters using their numeric codes by referencing


cs
the kanji, hiragana, and special character code table. One kanji
character requires 4 bytes.
3 Example
Inputting ATC ? OK:
.cn
w

NOTE
1 To define character @, input @40...@.

w

@
2 To define a line feed of a screen display message,
input @0A@ at the end of data.
w

3 For numeric code input, code @ requires 1 byte.


When a character, for example, a space is input
://

using its numeric code (20), 1 byte for "2" and 1


byte for "0", a total of 2 bytes, are required.
4 Control codes are assigned for characters as
tp

follows:
02: 2-byte code (kanji and hiragana characters)
01: 1-byte code (alphanumeric and half-size
ht

kana characters)
Do not specify 02 or 01 between @02 and @01, as
shown below. If so, the data may not be
displayed normally.
@02...02...01@, @02...01...01@
5 No variable display specification is allowed
between @ and @ or between @02 and 01@.

- 20 -
B-63823EN/02 2.SPECIFICATIONS

Character code table

/
om
s.c
re
NOTE
pa
cs
(*1) Minus
(*2) Under bar
(*3) Long bar
.cn

About 4 digits of code for available kanji characters, please refer to


the Appendix D.
w
w
w
://
tp
ht

- 21 -
3.I/O LINK B-63823EN/02

3 I/O LINK

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 22 -
B-63823EN/02 3.I/O LINK

3.1 WHAT IS THE I/O LINK?

The FANUC I/O Link is a serial interface which passes input/output


signals between the PMC and each I/O device at a high speed.

/
For each channel, up to 1024 DI points and up to 1024 DO points can

om
be connected and controlled from the PMC.

NOTE
1 To use 2nd channel of the I/O Link, the I/O Link point
expansion option is required.

s.c
2 The transfer cycle of signals from I/O devices is 2
ms.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 23 -
3.I/O LINK B-63823EN/02

3.1.1 Configuration of an I/O Link


The following figure shows a basic configuration of the I/O Link.

Slaves

/
I/O Unit I/O Unit

om
Group 0
I/O Link
master

s.c
Group 1
Operator's panel
connection unit

re
Group 2
Power Mate

:
:
pa :
:
:
:
:
:
:
:
cs
Group 15
.cn

(1) The I/O Link consists of one master and multiple slaves.
Master: CNC (such as Series 16i-B)
Slaves: I/O Unit-MODEL A, Power Mate, operator's panel
w

connection unit, and other devices


(2) Up to 16 groups of slaves can be connected to one I/O Link.
Group numbers 0 to 15 are sequentially assigned. Number 0 is
w

assigned to the group nearest to the master.


The number of connected slaves in a group differs depending on
the types of slaves.
w

(3) Any slave can be connected in any group. One group must
consist of slaves of the same type, however.
://
tp
ht

- 24 -
B-63823EN/02 3.I/O LINK

NOTE
1 Turn the power to the slaves and master on
simultaneously or turn the power to the slaves on
before turning the power to the master.
2 When turning the power to the master off, also turn

/
the power to all slaves off. Turn the power to all

om
slaves on again before turning the power to the
master on or turn the power to all slaves and the
master on simultaneously. Turn the power to the
master on after turning the power to all slaves on or
turn the power to the master and all slaves on

s.c
simultaneously.
3 For the maximum number of slaves per group that
can be connected, refer to the hardware connection

re
manual for each I/O device used as a slave.

3.1.2
pa
Numbers of Input Points and of Output Points of the I/O Link
The I/O Link has up to 1024 input points and up to 1024 output points
cs
for each channel when viewed from the master. These I/O points can
be assigned to each slave to periodically pass I/O data between the
master and each slave.
Each slave occupies the predetermined number of I/O points.
.cn

The total number of I/O points occupied by all slaves connected to one
channel is up to 1024 points (128 bytes) for each of input and output.
The number of I/O points occupied by one group is up to 256 points
(32 bytes) for each of input and output.
w

NOTE
The number of occupied I/O points may differ from
w

the actual number of I/O points. For example, if


the number of input points is smaller than or equal
w

to that of output points for a group, the number of


input points is assumed equal to that of output
points. For this reason, when the number of input
://

points for the actually connected hardware


components is 128 and that of output points is 256,
the number of occupied input points is assumed to
tp

be 256 because there is the following relationship


between the numbers of input points and of output
points:
ht

128 (number of input points) ≤ 256 (number


of output points)
For more specific rules, see Section 3.2.

- 25 -
3.I/O LINK B-63823EN/02

3.2 ASSIGNMENT METHOD

To use an I/O device as a slave, assign connection information to %I


addresses (input) and %Q addresses (output) of the PMC. The

/
machine tool builder should determine addresses to be used for

om
input/output of each I/O device in a sequence program. Connection
information can be assigned to these determined addresses using the
FANUC LADDER-IIIC. The information is written in the flash
ROM together with the sequence program. For this reason, the set
information is not changed unless the sequence program is changed.

s.c
Information to be set to addresses includes the connection location and
module name of each I/O device.
The connection location of an I/O device is represented by its group,
base, and slot numbers.

re
Setting the connection location

pa
I/O devices can roughly be divided into the following three types
according to the method for specifying the connection location.
cs
(1) Type of I/O device whose connection location is specified with
its group, base, and slot numbers
I/O Unit-MODEL A is of this type. Specify the connection
.cn

location with its group, base, and slot numbers.


The range of valid settings of each item is as follows:
Group = 0 to 15
Base = 0 and 1
Slot = 1 to 10 (number of a slot on a I/O Unit-MODEL
w

A base board)
(2) Type of I/O device whose connection location is specified with
w

its group and unit numbers


I/O Unit-MODEL B and handy machine operator's panels are of
this type.
w

The range of valid settings of each item is as follows:


Group = 0 to 15
Unit = 0 to 30 (NOTE)
://

NOTE
For detailed information on settings, see Subsections
tp

3.2.2 and 3.2.6.


ht

- 26 -
B-63823EN/02 3.I/O LINK

(3) Type of I/O device whose connection location is specified with


its group number
Machine operator's panel interface unit, I/O Link connection unit,
Power Mate, and other devices are of this type. One unit of this
type occupies one group.
The range of valid settings of group is as follows:

/
Group = 0 to 15

om
Setting the module name
Assign the %I or %Q addresses to the module as input/output of each

s.c
I/O device. Because %I and %Q address are BIT memory, a starting
address for BYTE must be assigned at “modulo 8 plus 1”, in other
words, at 1, 9, 17, 25, 33, 41, etc.
For the module name, see Tables 3.2 (a) to (f).

re
The number of bytes of the address occupied is determined for each
module name. The number of occupied I/O points per byte is 8.

pa
For details of the assignment method, see the assignment method for
each I/O device described later.
cs
.cn
w
w
w
://
tp
ht

- 27 -
3.I/O LINK B-63823EN/02

Table 3.2 (a) Module names (1)


Name Module name Occupied address Description
Input modules for A03B-0807-J101(C101) 4 bytes for input Input32 (AID32A1)
I/O Unit-MODEL A A03B-0807-J102(C102) 4 bytes for input Input32 (AID32B1)
A03B-0807-J111(C111) 4 bytes for input Input32 (AID32H1)
A03B-0807-J103(C103) 2 bytes for input Input16 (AID16C)

/
A03B-0807-J104(C104) 2 bytes for input Input16 (AID16D)

om
A03B-0807-J113(C113) 2 bytes for input Input16 (AID16K)
A03B-0807-J114(C114) 2 bytes for input Input16 (AID16L)
A03B-0807-J105(C105) 4 bytes for input Input32 (AID32E1)
A03B-0807-J110(C110) 4 bytes for input Input32 (AID32E2)
A03B-0807-J106(C106) 4 bytes for input Input32 (AID32F1)
A03B-0807-J109(C109) 4 bytes for input Input32 (AID32F2)

s.c
A03B-0807-J107(C107) 2 bytes for input Input16 (AIA16G)
A03B-0807-J051(C051) 8 bytes for input Input64 (AAD04A)
A03B-0807-J053(C053) 4 bytes for input Input32
A03B-0819-J053(C053) 4 bytes for input Input32

re
A03B-0807-C108(C108) 1 byte for input Input8
A03B-0807-C112(C112) 1 byte for input Input8
A03B-0819-J101(C101) 4 bytes for input Input32 (AID32A1)
A03B-0819-J102(C102) 4 bytes for input Input32 (AID32B1)
A03B-0819-J111(C111)
A03B-0819-J103(C103)
A03B-0819-J104(C104)
A03B-0819-J113(C113)
pa
4 bytes for input
2 bytes for input
2 bytes for input
2 bytes for input
Input32 (AID32H1)
Input16 (AID16C)
Input16 (AID16D)
Input16 (AID16K)
cs
A03B-0819-J114(C114) 2 bytes for input Input16 (AID16L)
A03B-0819-J105(C105) 4 bytes for input Input32 (AID32E1)
A03B-0819-J110(C110) 4 bytes for input Input32 (AID32E2)
.cn

A03B-0819-J106(C106) 4 bytes for input Input32 (AID32F1)


A03B-0819-J109(C109) 4 bytes for input Input32 (AID32F2)
A03B-0819-J107(C107) 2 bytes for input Input16 (AIA16G)
A03B-0819-J051(C051) 8 bytes for input Input64 (AAD04A)
Generic In (1byte) 1 byte for input Input8
Generic In (2byte) 2 bytes for input Input16
w

Generic In (3byte) 3 bytes for input Input24


Generic In (4byte) 4 bytes for input Input32
Generic In (5byte) 5 bytes for input Input40
w

Generic In (6byte) 6 bytes for input Input48


Generic In (7byte) 7 bytes for input Input56
Generic In (8byte) 8 bytes for input Input64
w
://
tp
ht

- 28 -
B-63823EN/02 3.I/O LINK

Table 3.2 (b) Module names (2)


Name Module name Occupied address Description
Output modules for A03B-0807-J162(C162) 4 bytes for output Output32 (AOD32A1)
I/O Unit-MODEL A A03B-0807-J151(C151) 1 byte for output Output8 (AOD08C)
A03B-0807-J152(C152) 1 byte for output Output8 (AOD08D)
A03B-0807-J153(C153) 2 bytes for output Output16 (AOD16C)

/
A03B-0807-J154(C154) 2 bytes for output Output16 (AOD16D)

om
A03B-0807-J155(C155) 4 bytes for output Output32 (AOD32C1)
A03B-0807-J172(C172) 4 bytes for output Output32 (AOD32C2)
A03B-0807-J156(C156) 4 bytes for output Output32 (AOD32D1)
A03B-0807-J167(C167) 4 bytes for output Output32 (AOD32D2)
A03B-0807-J157(C157) 1 byte for output Output8 (AOA05E)
A03B-0807-J158(C158) 1 byte for output Output8 (AOA08E)

s.c
A03B-0807-J159(C159) 2 bytes for output Output16 (AOA12F)
A03B-0807-J160(C160) 1 byte for output Output8 (AOR08G)
A03B-0807-J161(C161) 2 bytes for output Output16 (AOR16G)
A03B-0807-J165(C165) 2 bytes for output Output16 (AOR16H2)

re
A03B-0807-J052(C052) 4 bytes for output Output32 (ADA02A)
A03B-0807-C164(C164) 1 byte for output Output8
A03B-0807-C169(C109) 1 byte for output Output8
A03B-0807-C170(C170) 1 byte for output Output8
A03B-0807-C171(C171)
A03B-0807-C166(C166)
A03B-0807-C168(C168)
A03B-0807-J182(C182)
pa
2 bytes for output
1 byte for output
1 byte for output
2 bytes for output
Output16
Output8
Output8
Output16
cs
A03B-0819-J162(C162) 4 bytes for output Output32 (AOD32A1)
A03B-0819-J151(C151) 1 byte for output Output8 (AOD08C)
A03B-0819-J152(C152) 1 byte for output Output8 (AOD08D)
.cn

A03B-0819-J153(C153) 2 bytes for output Output16 (AOD16C)


A03B-0819-J154(C154) 2 bytes for output Output16 (AOD16D)
A03B-0819-J155(C155) 4 bytes for output Output32 (AOD32C1)
A03B-0819-J172(C172) 4 bytes for output Output32 (AOD32C2)
A03B-0819-J156(C156) 4 bytes for output Output32 (AOD32D1)
A03B-0819-J167(C167) 4 bytes for output Output32 (AOD32D2)
w

A03B-0819-J157(C157) 1 byte for output Output8 (AOA05E)


A03B-0819-J158(C158) 1 byte for output Output8 (AOA08E)
A03B-0819-J159(C159) 2 bytes for output Output16 (AOA12F)
w

A03B-0819-J160(C160) 1 byte for output Output8 (AOR08G)


A03B-0819-J161(C161) 2 bytes for output Output16 (AOR16G)
A03B-0819-J165(C165) 2 bytes for output Output16 (AOR16H2)
w

A03B-0819-J052(C052) 4 bytes for output Output32 (ADA02A)


A03B-0819-J182(C182) 2 bytes for output Output16
Generic Out (1byte) 1 byte for output Output8
://

Generic Out (2byte) 2 bytes for output Output16


Generic Out (3byte) 3 bytes for output Output24
Generic Out (4byte) 4 bytes for output Output32
Generic Out (5byte) 5 bytes for output Output40
tp

Generic Out (6byte) 6 bytes for output Output48


Generic Out (7byte) 7 bytes for output Output56
Generic Out (8byte) 8 bytes for output Output64
ht

Input/output module for 3 bytes for input


A03B-0807-C200(C200) Input24 / Output16 (AIO40A)
I/O Unit-MODEL A 2 bytes for output
1 byte for input
A03B-0807-J183(C183) Input8 / Output8 (AOD08DP)
1 byte for output
1 byte for input
A03B-0819-J183(C183) Input8 / Output8 (AOD08DP)
1 byte for output

- 29 -
3.I/O LINK B-63823EN/02

Table 3.2 (c) Module names (3)


Name Module name Occupied address Description
Modules for ## 4 bytes for input Input32 (Power on/off)
I/O Unit-MODEL B #1(In) 1 byte for input Input8
#2(In) 2 byte for input Input16
Handy Machine #3(In) 3 byte for input Input24

/
Operator’s Panel #4(In) 4 byte for input Input32

om
#6(In) 6 byte for input Input48
#8(In) 8 byte for input Input64
#10(In) 10 byte for input Input80
#1(Out) 1 byte for output Out put8
#2(Out) 2 byte for output Out put16
#3(Out) 3 byte for output Out put24

s.c
#4(Out) 4 byte for output Out put32
#6(Out) 6 byte for output Out put48
#8(Out) 8 byte for output Out put64
#10(Out) 10 byte for output Out put80

re
I/O Connection Panel 24 bytes for input
B BASIC Unit only
16 bytes for output
48 bytes for input
BE BASIC Unit + expansion unit
32 bytes for output
BEM

BEE
pa
104 bytes for input
32 bytes for output
72 bytes for input
48 bytes for output
BASIC Unit + expansion unit +
MPG
BASIC Unit + 2 expansion unit
cs
104 bytes for input BASIC Unit + 2 expansion unit +
BEEM
48 bytes for output MPG
112 bytes for input BASIC Unit + 2 expansion unit +
BEEMM
48 bytes for output 2 MPG
.cn

96 bytes for input


BEEE BASIC Unit + 3 expansion unit
64 bytes for output
104 bytes for input BASIC Unit + 3 expansion unit +
BEEEM
64 bytes for output MPG
112 bytes for input BASIC Unit + 3 expansion unit +
BEEEMM
w

64 bytes for output 2 MPG


120 bytes for input BASIC Unit + 3 expansion unit +
BEEEMMM
64 bytes for output 3 MPG
w

128 bytes for input


BA BASIC Unit only (Use Alarm DO)
16 bytes for output
128 bytes for input BASIC Unit + expansion unit
BEA
32 bytes for output (Use Alarm DO)
w

128 bytes for input BASIC Unit + expansion unit +


BEMA
32 bytes for output MPG (Use Alarm DO)
128 bytes for input BASIC Unit + 2 expansion unit
BEEA
://

48 bytes for output (Use Alarm DO)


128 bytes for input BASIC Unit + 2 expansion unit +
BEEMA
48 bytes for output MPG (Use Alarm DO)
128 bytes for input BASIC Unit + 2 expansion unit +
tp

BEEMMA
48 bytes for output 2 MPG (Use Alarm DO)
128 bytes for input BASIC Unit + 3 expansion unit
BEEEA
64 bytes for output (Use Alarm DO)
ht

128 bytes for input BASIC Unit + 3 expansion unit +


BEEEMA
64 bytes for output MPG (Use Alarm DO)
128 bytes for input BASIC Unit + 3 expansion unit +
BEEEMMA
64 bytes for output 2 MPG (Use Alarm DO)
128 bytes for input BASIC Unit + 3 expansion unit +
BEEEMMMA
64 bytes for output 3 MPG (Use Alarm DO)

- 30 -
B-63823EN/02 3.I/O LINK

Table 3.2 (d) Module names (4)


Name Module name Occupied address Description
I/O Link Connect Unit 4 bytes for input
A20B-2000-0410 (1) Input32 / Output32
4 bytes for output
8 bytes for input
A20B-2000-0410 (2) Input64 / Output64
8 bytes for output

/
16 bytes for input
A20B-2000-0410 (3) Input128 / Output128

om
16 bytes for output
32 bytes for input
A20B-2000-0410 (4) Input256 / Output256
32 bytes for output
32 bytes for input
A20B-2000-0410 Input256 / Output256
32 bytes for output
4 bytes for input
A20B-2000-0411 (1) Input32 / Output32

s.c
4 bytes for output
8 bytes for input
A20B-2000-0411 (2) Input64 / Output64
8 bytes for output
16 bytes for input
A20B-2000-0411 (3) Input128 / Output128
16 bytes for output

re
32 bytes for input
A20B-2000-0411 (4) Input256 / Output256
32 bytes for output
32 bytes for input
A20B-2000-0411 Input256 / Output256

A20B-2000-0412 (1)

A20B-2000-0412 (2)
pa
32 bytes for output
4 bytes for input
4 bytes for output
8 bytes for input
8 bytes for output
Input32 / Output32

Input64 / Output64
cs
16 bytes for input
A20B-2000-0412 (3) Input128 / Output128
16 bytes for output
32 bytes for input
A20B-2000-0412 (4) Input256 / Output256
.cn

32 bytes for output


32 bytes for input
A20B-2000-0412 Input256 / Output256
32 bytes for output
Connection Unit Input64 / Output32
8 bytes for input
A16B-2200-0661 Operator’s panel connection unit
4 bytes for output
sink DO
w

Input96 / Output64
12 bytes for input
A16B-2200-0660 Operator’s panel connection unit
8 bytes for output
sink DO
w

Input64 / Output32
8 bytes for input
A16B-2202-0731 Operator’s panel connection unit
4 bytes for output
source DO
w

Input96 / Output64
12 bytes for input
A16B-2202-0730 Operator’s panel connection unit
8 bytes for output
source DO
16 bytes for input
://

A16B-2201-0110(1) Input128 / Output128


16 bytes for output
32 bytes for input
A16B-2201-0110(2) Input256 / Output256
32 bytes for output
6 bytes for input
tp

A16B-2201-0071 Input48 / Output32


4 bytes for output
12 bytes for input
A16B-2201-0070 Input96 / Output64
8 bytes for output
ht

3 bytes for input


A16B-2600-0150 Input24 / Output16
2 bytes for output
6 bytes for input
A16B-2202-0733 Input48 / Output32
4 bytes for output
12 bytes for input
A16B-2202-0732 Input96 / Output64
8 bytes for output
3 bytes for input
A16B-2600-0170 Input24 / Output16
2 bytes for output

- 31 -
3.I/O LINK B-63823EN/02

Table 3.2 (e)Module names (5)


Name Module name Occupied address Description
Operator’s Panel 12 bytes for input
A20B-2002-0470 (1) Input72 / Output56
8 bytes for output
13 bytes for input
A20B-2002-0470 (2) Input72 / Output56 1MPG
8 bytes for output

/
14 bytes for input
A20B-2002-0470 (3) Input72 / Output56 2MPG

om
8 bytes for output
15 bytes for input
A20B-2002-0470 (4) Input72 / Output56 3MPG
8 bytes for output
16 bytes for input Input72 / Output56
A20B-2002-0470 (5)
8 bytes for output (use Alarm DO)
16 bytes for input Input72 / Output56 1MPG
A20B-2002-0470 (6)

s.c
8 bytes for output (use Alarm DO)
16 bytes for input Input72 / Output56 2MPG
A20B-2002-0470 (7)
8 bytes for output (use Alarm DO)
16 bytes for input Input72 / Output56 3MPG
A20B-2002-0470 (8)
8 bytes for output (use Alarm DO)

re
6 bytes for input
A20B-2002-0520 (1) Input48 / Output32
4 bytes for output
13 bytes for input
A20B-2002-0520 (2) Input48 / Output32 1MPG

A20B-2002-0520 (3)

A20B-2002-0520 (4)
pa
4 bytes for output
14 bytes for input
4 bytes for output
15 bytes for input
4 bytes for output
Input48 / Output32 2MPG

Input48 / Output32 3MPG


cs
16 bytes for input Input48 / Output32
A20B-2002-0520 (5)
4 bytes for output (use Alarm DO)
16 bytes for input Input48 / Output32 1MPG
A20B-2002-0520 (6)
.cn

4 bytes for output (use Alarm DO)


16 bytes for input Input48 / Output32 2MPG
A20B-2002-0520 (7)
4 bytes for output (use Alarm DO)
16 bytes for input Input48 / Output32 3MPG
A20B-2002-0520 (8)
4 bytes for output (use Alarm DO)
6 bytes for input
w

A20B-2002-0521 (1) Input48 / Output32


4 bytes for output
Beta Servo 16 bytes for input
A06B-6093-H151 Input128 / Output128
16 bytes for output
w

FANUC CNC SYSTEM 4 bytes for input


FS04A(In) / (Out) Input32 / Output32
4 bytes for output
FANUC Power Mate 8 bytes for input
FS08A(In) / (Out) Input64 / Output64
w

8 bytes for output


16 bytes for input
FANUC CNC(OC02I) / (OC02O) Input128 / Output128
16 bytes for output
32 bytes for input
://

FANUC CNC(OC03I) / (OC03O) Input256 / Output256


32 bytes for output
tp
ht

- 32 -
B-63823EN/02 3.I/O LINK

Table 3.2 (f) Module names (6)


Name Module name Occupied address Description
Others 1 byte Unit (In) 1 byte for input Input8
2 byte Unit (In) 2 bytes for input Input16
3 byte Unit (In) 3 bytes for input Input24
4 byte Unit (In) 4 bytes for input Input32

/
5 byte Unit (In) 5 bytes for input Input40

om
6 byte Unit (In) 6 bytes for input Input48
7 byte Unit (In) 7 bytes for input Input56
8 byte Unit (In) 8 bytes for input Input64
16 byte Unit (In) 16 bytes for input Input128
32 byte Unit (In) 32 bytes for input Input256
1 byte Unit (Out) 1 byte for output Output8

s.c
2 byte Unit (Out) 2 bytes for output Output16
3 byte Unit (Out) 3 bytes for output Output24
4 byte Unit (Out) 4 bytes for output Output32
5 byte Unit (Out) 5 bytes for output Output40

re
6 byte Unit (Out) 6 bytes for output Output48
7 byte Unit (Out) 7 bytes for output Output56
8 byte Unit (Out) 8 bytes for output Output64
16 byte Unit (Out) 16 bytes for output Output128
32 byte Unit (Out)

NOTE
pa
32 bytes for output Output256
cs
1 For the specifications and connection of each I/O
device, refer to the relevant hardware connection
manual.
.cn

2 For the assignment method for each I/O device, see


Subsections 3.2.1 to 3.2.7.
3 As assignment data for a handy machine operator's
panel, assign multiple module names successively.
w

For details, see Subsection 3.2.6.


w
w
://
tp
ht

- 33 -
3.I/O LINK B-63823EN/02

3.2.1 Assignment Method for I/O Unit-MODEL A


Figs. 3.2.1 (a) and 3.2.1 (b) show sample configurations of I/O
Unit-MODEL A.

/
om
I/O Unit I/O Unit
I/O Link
A A Group 0
master
I I

Slot 2
Slot 3
Slot 4
Slot 5

Slot 2
Slot 3
Slot 4
Slot 5
Slot 1

Slot 1
F F
0 0
1 1
A B

s.c
Base 0 Base 1

Fig. 3.2.1 (a)

re
I/O Unit I/O Unit
I/O Link
master A A Group 0
I I

pa Slot 1
Slot 2
Slot 3
Slot 4
Slot 5

Slot 1
Slot 2
Slot 3
Slot 4
Slot 5
F F
0 0
1 1
A B
cs
Base 0 Base 1

I/O Unit I/O Unit


A A Group 1
I I
.cn
Slot 1
Slot 2
Slot 3
Slot 4
Slot 5

Slot 1
Slot 2
Slot 3
Slot 4
Slot 5
F F
0 0
1 1
A B
Base 0 Base 1
w

Operator's panel Group 2


connection unit
w

Base 0

Group 3
Power Mate
w

Base 0
://

Fig. 3.2.1 (b)


tp
ht

- 34 -
B-63823EN/02 3.I/O LINK

Assignment method
(1) Group number
For I/O Unit-MODEL A, up to two I/O units can be connected
when interface module AIF01A is used as the basic unit and

/
expansion interface module AIF01B is also used. This is called

om
the base expansion function. This set of up to two I/O units
comprises one group (see Fig. 3.2.1 (a)). When required I/O
modules cannot be contained only in one group or when multiple
I/O units are to be distributed at distant locations on the machine
side, the second AIF01A can be connected to the first AIF01A

s.c
using a cable to add a group. (See Fig. 3.2.1 (b).)

(2) Base number


One group consists of up to two I/O base units. The base

re
number of the I/O unit on which interface module AIF01A is
mounted is 0; the base number of the other I/O unit is 1.
In other words, when the base expansion function is used, the

pa
base number of the basic unit is always 0 and that of the
expansion unit is always 1. When the base expansion function
is not used, the base number is always 0.
cs
(3) Slot number
On one I/O base unit, up to five (ABU05A) or ten (ABU10A)
I/O modules can be mounted depending on the type of I/O base
.cn

unit. The location of each module on the I/O base unit is


represented by a slot number. For each base unit, the location
of the I/O interface module is 0 and slot numbers 1 to 10 are
assigned from left to right. Each module can be mounted into
any desired slot. I/O modules may not be mounted closely from
w

left to right. An intermediate slot may not be used.

(4) Module name


w

For module names, see Tables 3.2 (a) to (b) in Section 3.2 above.
w
://
tp
ht

- 35 -
3.I/O LINK B-63823EN/02

Number of occupied I/O points


Obtain the number of occupied I/O points as follows.

[Number of output points]

/
Total number of points required for output Number of occupied

om
modules used in one group I/O points
0 to 32 32
40 to 64 64
72 to 128 128
136 to 256 256

s.c
[Number of input points]
Total number of points required for input modules Number of occupied
used in one group I/O points

re
0 to 32 32
40 to 64 64
72 to 128 128

pa
136 to 256 256

If the obtained total number of input points is smaller than or equal to


cs
that of output points in the same group, however, the number of input
points is assumed equal to that of output points. For this reason,
when the number of input points for the actually connected hardware
.cn

components is 128 and that of output points is 256, the number of


occupied input points is assumed to be 256.

Related hardware manual


w

"FANUC I/O Unit-MODEL A Connection and Maintenance Manual"


(B-61813E)
w

NOTE
w

For the specifications and connection of I/O


Unit-MODEL A and related I/O modules, refer to the
hardware connection manual for each I/O device.
://
tp
ht

- 36 -
B-63823EN/02 3.I/O LINK

3.2.2 Assignment Method for I/O Unit-MODEL B


I/O Unit-MODEL B can be used together with I/O Link devices such
as the Power Mate, operator's panel interface unit, connection unit,
and I/O Unit-MODEL A. In this case, I/O Unit-MODEL B

/
comprises one group and other units cannot be contained in the group.

om
An example of connection is shown below.

I/O LINK
MASTER

s.c
[GROUP] = 0
Power Mate

re
[BASE] = 0, [SLOT] = 1
[GROUP] = 1

[GROUP] = 2
Operator's panel
interface unit

[BASE] = 0, [SLOT] = 1
pa
cs
→SLOT No. →SLOT No.

I/O Unit-A I/O Unit-A


.cn

[GROUP] = 3

[BASE] = 0 [BASE] = 1
w

I/O Unit-B
interface unit
w

I/O Unit-B I/O Unit-B


DI/DO unit DI/DO unit
(Unit No. = 1) (Unit No. = 20)
w

[UNIT] = 1 [UNIT] = 20
://

I/O Unit-B I/O Unit-B


DI/DO unit DI/DO unit
(Unit No. = 5) (Unit No. = 10)
tp

[UNIT] = 5 [UNIT] = 10
ht

I/O Unit-B I/O Unit-B


DI/DO unit DI/DO unit
(Unit No. = 30) (Unit No. = 9)

[UNIT] = 30 [UNIT] = 9

- 37 -
3.I/O LINK B-63823EN/02

Assignment method
As the group number, set the group number used in the configuration.
As the slot number, set the unit number of a DI/DO unit of I/O
Unit-MODEL B. To assign power on-off information, set 0 for the
unit number.

/
Set the following values for the slot number and assignment name:

om
Unit number: 0: Power on-off information
1 to 30: Unit number
Assignment name: Module name representing the address
occupied by the I/O Unit-MODEL B
DI/DO unit (see Table 3.2 (c).)

s.c
Number of input or
output points required
Assignment name Occupied address
for [basic unit] +

re
[expansion unit]
1 byte #1 1 byte for input/output
2 bytes #2 2 bytes for input/output
3 bytes
4 bytes
6 bytes
8 bytes
pa #3
#4
#6
#8
3 bytes for input/output
4 bytes for input/output
6 bytes for input/output
8 bytes for input/output
cs
10 bytes #10 10 bytes for input/output
Power on-off information ## 4 bytes for input
.cn

NOTE
When channels 2 is also used to connect I/O
devices, the maximum total number of groups used
for connecting I/O Unit-MODEL B with channels 1 to
w

2 is 8.
w
w
://
tp
ht

- 38 -
B-63823EN/02 3.I/O LINK

Interface module incorporating I/O Unit-MODEL A


Interface module AIF02C can control communication both with I/O
Unit-MODEL A and with I/O Unit-MODEL B.

/
om
I/O Unit I/O Unit
I/O Link
A A
master Group 0
I I

Slot 1
Slot 2
Slot 3
Slot 4
Slot 5

Slot 1
Slot 2
Slot 3
Slot 4
Slot 5
F F
0 0
2 1

s.c
C B
Group 1

I/O Unit-MODEL B I/O Unit-MODEL B I/O Unit-MODEL B


DI/DO unit DI/DO unit DI/DO unit

re
Group 2
Operator's panel
connection unit

pa
cs
For the AIF02C, the base expansion function of the AIF02A is
removed and the functions of the I/O Unit-MODEL B interface unit
.cn

are added.
When I/O Unit-MODEL A is not used, only I/O Unit-MODEL B
cannot be used. The base expansion function cannot also be used.
The AIF02C occupies two groups. Assignment is required for each
w

of I/O Unit-MODEL A and I/O Unit-MODEL B.

NOTE
w

For details of the AIF02C, refer to "FANUC I/O


Unit-MODEL A Connection and Maintenance
w

Manual" (B-61813E).
://

Related hardware manual


"FANUC I/O Unit-MODEL B Connection Manual" (B-62163E)
tp

NOTE
For the setting of each I/O Unit-MODEL B unit and
ht

the specifications and connection of related I/O


modules, refer to the hardware connection manual
for each I/O device in addition to the above
connection manual.

- 39 -
3.I/O LINK B-63823EN/02

3.2.3 Assignment Method for Distribution I/O Connection Panel I/O


Unit and Distribution I/O Operator's Panel I/O Units
For the I/O Link, when assigning connection information of a
connection panel or operator's panel I/O module, set an I/O Link serial

/
number (0 for the module nearest to the I/O Link master CNC) for the

om
group number, always set 0 for the base number, and always set 1 for
the slot number. When basic and expansion connection panel I/O
modules are used, assign one connection information item for all
modules in one I/O Link group. For a distribution I/O module unlike
I/O Unit-MODEL A, the slot number need not be specified. For the

s.c
module name used to set assignment data, see "Distribution I/O
connection panel I/O modules" in Table 3.2 (c) to (d).
An example of assignment is shown below.

re
Example of assignment
Example)

CNC

JD1A
pa
cs
72 input points (16 general-purpose points + 56 matrix points), 56 output points
(%I33…, %Q1…)

Operator's panel
.cn

I/O unit
A20B-2002-0470
JD1B
JD1A
w

96 input points, 64 output points (%I161…, %Q81…)


Connection Expansion Expansion Expansion
panel I/O unit 1 unit 2 unit 3
w

basic unit
JD1B
JD1A
w

24 input points, 16 output points (%I801…, %Q801…)


Connection
://

panel I/O
basic unit
JD1B
JD1A
tp
ht

Input Address Output Address Group number Module name


%I33 %Q1 0 A20B-2002-0470(3)
%I161 %Q81 1 BEEE
%I801 %Q801 2 B

- 40 -
B-63823EN/02 3.I/O LINK

Connection panel I/O units


For signal mapping of connection panel I/O modules, refer to the
connection manual (hardware) for the CNC used as the I/O Link
master.

/
Assignment data is described below for each configuration of basic

om
and expansion units.

CAUTION
Always connect expansion units 1, 2, and 3 in this
order closely when required. Any intermediate

s.c
expansion unit cannot be skipped.

re
Basic unit Expansion Expansion
JD1B unit 1 unit 2
JD1A

pa
You may want to make the above setting so that
expansion unit 1 is not mounted to connect it later
cs
and connection information of only expansion unit 2
is assigned, but the setting is disabled.
.cn

(1) Only basic unit

24 input points, 16 output points


w

Basic unit
JD1B
JD1A
w
w

(a) When DO alarm detection is not used


• When no manual pulse generator is used
Module Name = B
://

(b) When DO alarm detection is used


• Regardless of the number of manual pulse generators
Module Name = BA
tp

NOTE
"B" means a BASIC unit.
ht

"A" means that alarm DO is used.

- 41 -
3.I/O LINK B-63823EN/02

(2) Basic unit + expansion unit 1

48 input points, 32 output points

Basic unit Expansion


JD1B unit 1

/
JD1A

om
(a) When DO alarm detection is not used
• When no manual pulse generator is used

s.c
Module Name = BE
• When one manual pulse generator is used
Module Name = BEM
(b) When DO alarm detection is used

re
• When no manual pulse generator is used
Module Name = BEA
• When one manual pulse generator is used

NOTE
pa
Module Name = BEMA
cs
"B" means a BASIC unit.
"E" means an expansion unit.
"M" means that manual pulse generator is used.
.cn

"A" means that alarm DO is used.


w
w
w
://
tp
ht

- 42 -
B-63823EN/02 3.I/O LINK

(3) Basic unit + expansion unit 1 + expansion unit 2

72 input points, 48 output points

Basic unit Expansion Expansion


JD1B unit 1 unit 2

/
JD1A

om
(a) When DO alarm detection is not used
• When no manual pulse generator is used

s.c
Module Name = BEE
• When one manual pulse generator is used
Module Name = BEEM
• When two manual pulse generators are used

re
Module Name = BEEMM
(b) When DO alarm detection is used
• When no manual pulse generator is used

pa
Module Name = BEEA
• When one manual pulse generator is used
Module Name = BEEMA
cs
• When two manual pulse generators are used
Module Name = BEEMMA
.cn

NOTE
"B" means a BASIC unit.
"E" means an expansion unit.
"M" means that manual pulse generator is used.
w

"A" means that alarm DO is used.


w
w
://
tp
ht

- 43 -
3.I/O LINK B-63823EN/02

(4) Basic unit + expansion unit 1 + expansion unit 2 + expansion


unit 3

96 input points, 64 output points

/
Basic unit Expansion Expansion Expansion
JD1B unit 1 unit 2 unit 3

om
JD1A

(a) When DO alarm detection is not used

s.c
• When no manual pulse generator is used
Module Name = BEEE
• When one manual pulse generator is used
Module Name = BEEEM

re
• When two manual pulse generators are used
Module Name = BEEEMM
• When three manual pulse generators are used

pa
Module Name = BEEEMMM
(b) When DO alarm detection is used
• When no manual pulse generator is used
cs
Module Name = BEEEA
• When one manual pulse generator is used
Module Name = BEEEMA
.cn

• When two manual pulse generators are used


Module Name = BEEEMMA
• When three manual pulse generators are used
Module Name = BEEEMMMA
w

NOTE
"B" means a BASIC unit.
w

"E" means an expansion unit.


"M" means that manual pulse generator is used.
"A" means that alarm DO is used.
w
://
tp
ht

- 44 -
B-63823EN/02 3.I/O LINK

Operator's panel I/O units


For signal mapping of operator's panel I/O units, refer to the
connection manual (hardware) for the CNC used as the I/O Link
master.

/
(1) Operator's panel I/O unit (compatible with matrix input,

om
A20B-2002-0470)

Input: 16 general-purpose points + 56 matrix points


Output: 56 matrix points

s.c
Operator's panel
I/O unit
JD1B
JD1A

re
(a) When DO alarm detection is not used

pa
• When no manual pulse generator is used
Module Name = A20B-2002-0470 (1)
• When one manual pulse generator is used
cs
Module Name = A20B-2002-0470 (2)
• When two manual pulse generators are used
Module Name = A20B-2002-0470 (3)
• When three manual pulse generators are used
.cn

Module Name = A20B-2002-0470 (4)


(b) When DO alarm detection is used
• When no manual pulse generator is used
Module Name = A20B-2002-0470 (5)
w

• When one manual pulse generator is used


Module Name = A20B-2002-0470 (6)
• When two manual pulse generators are used
w

Module Name = A20B-2002-0470 (7)


• When three manual pulse generators are used
w

Module Name = A20B-2002-0470 (8)


://
tp
ht

- 45 -
3.I/O LINK B-63823EN/02

(2) Operator's panel I/O unit (A20B-2002-0520, A20B-2002-0521)

48 input points
32 output points

Operator's panel

/
I/O unit

om
JD1B
JD1A

(a) When DO alarm detection is not used

s.c
• When no manual pulse generator is used
A20B-2002-0520 (1)
A20B-2002-0521 (1)
• When one manual pulse generator is used

re
A20B-2002-0520 (2)
• When two manual pulse generators are used
A20B-2002-0520 (3)

pa
• When three manual pulse generators are used
A20B-2002-0520 (4)
(b) When DO alarm detection is used
• When no manual pulse generator is used
cs
A20B-2002-0520 (5)
• When one manual pulse generator is used
A20B-2002-0520 (6)
.cn

• When two manual pulse generators are used


A20B-2002-0520 (7)
• When three manual pulse generators are used
A20B-2002-0520 (8)
w
w
w
://
tp
ht

- 46 -
B-63823EN/02 3.I/O LINK

3.2.4 Assignment Method for the Power Mate


To use Power Mate-MODEL D/H, Power Mate i MODEL-D/H, or I/O
Link β amplifier as an I/O Link slave, assign its connection
information on the I/O Link master.

/
On the I/O Link slave, assignment is not required because the

om
addresses are fixed.
An example of connection is shown below.

I/O LINK

s.c
MASTER

[GROUP] = 0
Operator's panel
interface unit

re
[BASE] = 0, [SLOT] = 1
[GROUP] = 1

Power Mate pa
cs
[BASE] = 0, [SLOT] = 1
.cn

Assignment method

Number of input/output Input device assignment Output device assignment


points (input/output) name (module name) name (module name)
w

32/32 FS04A (In) FS04A (Out)


64/64 FS08A (In) FS08A (Out)
128/128 FANUC CNC (OC02I) FANUC CNC (OC02O)
w

256/256 FANUC CNC (OC03I) FANUC CNC (OC03O)

NOTE
w

1 Assign input and output module names with the


same number of points.
://

2 For the I/O Link β amplifier, assign


“A06B-6093-H151”.
tp
ht

- 47 -
3.I/O LINK B-63823EN/02

3.2.5 Assignment Method for I/O Link Connection Units


Conventionally, to exchange data between CNCs A and B, the devices
indicated by (a) in the figure below must be connected. (Any I/O
units can be used to exchange data.)

/
om
CNC A I/O Unit I/O Unit CNC B
Model A Model A

(a)

s.c
I/O Unit I/O Unit
Model A Model A

I/O Unit I/O Unit

re
Model A Model A

pa
An I/O Link connection unit replaces the connected devices to
eliminate cable connection and enable the power to each master or
slave to be turned on and off independently.
cs
CNC A I/O Unit I/O Unit CNC B
Model A Model A
.cn

← These devices are replaced with an


I/O Link connection unit.
I/O Unit (a) I/O Unit
Model A ↔ Model A
w
w

I/O Unit I/O Unit


Model A Model A
w
://
tp
ht

- 48 -
B-63823EN/02 3.I/O LINK

Therefore, when an I/O Link connection unit is used, the connection is


as follows.

CNC A I/O Unit I/O Unit CNC B


Model A Model A

/
om
I/O Link
connection unit

s.c
I/O Unit I/O Unit
Model A Model A

Assignment method

re
Assignment data is determined according to the types of I/O devices
replaced with an I/O Link connection unit.

Occupied address
(input/output)
pa Input / Output device assignment name
(module name)
cs
A20B-2000-0410(1)
4/4 A20B-2000-0411(1)
A20B-2000-0412(1)
A20B-2000-0410(2)
.cn

8/8 A20B-2000-0411(2)
A20B-2000-0412(2)
A20B-2000-0410(3)
16/16 A20B-2000-0411(3)
w

A20B-2000-0412(3)
A20B-2000-0410(4)
A20B-2000-0410
w

A20B-2000-0411(4)
32/32
A20B-2000-0411
A20B-2000-0412(4)
w

A20B-2000-0412
://

Example of setting

NOTE
tp

For details of the hardware connection method,


particularly connection of a power supply, refer to
the hardware connection manual for each related
ht

master/slave device.

- 49 -
3.I/O LINK B-63823EN/02

3.2.6 Assignment Method for a Handy Machine Operator's Panel


An example of connecting a handy machine operator's panel to the I/O
Link is shown below.

/
om
I/O Link Handy machine
Group 0
master operator's panel

s.c
Operator's panel
Group 1
connection unit

re
Assignment method pa
Assign 128 bit (16 bytes) to %I addresses and 256 bit (32 bytes)
cs
to %Q addresses contiguously starting from any address for each
group. Set the group number used in the configuration for the group
number and always set 0 for the base number. Set the slot number
.cn

and assignment name as shown in the table below. The number of


occupied input points for each group is 256 bit (32 bytes), which is the
same as that of output points, because of limitations of the I/O Link.
w

[Examples of assigning %I addresses]


%I address Unit number Assignment Occupied
name address
w

%I(8×n+1) 0 ## 4 bytes
%I(8×n+33) 1 #2 2 bytes
%I(8×n+49) 2 #2 2 bytes
w

%I(8×n+65) 3 #2 2 bytes
%I(8×n+81) 4 #2 2 bytes
://

%I(8×n+97) 5 #2 2 bytes
%I(8×n+113) 6 #2 2 bytes
tp
ht

- 50 -
B-63823EN/02 3.I/O LINK

[Examples of assigning %Q addresses]


%Q address Unit number Assignment Occupied
name address
%Q(8×n+1) 7 #2 2 bytes

/
%Q(8×n+17) 8 #2 2 bytes

om
%Q(8×n+33) 9 #2 2 bytes
%Q(8×n+49) 10 #2 2 bytes
%Q(8×n+65) 11 #2 2 bytes
%Q(8×n+81) 12 #2 2 bytes
%Q(8×n+97) 13 #2 2 bytes

s.c
%Q(8×n+113) 14 #2 2 bytes
%Q(8×n+129) 15 #2 2 bytes
%Q(8×n+145) 16 #2 2 bytes
%Q(8×n+161) 17 #2 2 bytes

re
%Q(8×n+177) 18 #2 2 bytes
%Q(8×n+193) 19 #2 2 bytes
%Q(8×n+209) 20 #2 2 bytes
%Q(8×n+225)
%Q(8×n+241)
pa 21
22
#2
#2
2 bytes
2 bytes
cs
.cn
w
w
w
://
tp
ht

- 51 -
3.I/O LINK B-63823EN/02

3.2.7 Assignment Method for an AS-i Converter Unit


An I/O Link-AS-i converter unit converts I/O from the I/O Link to the
AS-Interface (called AS-i below) to enable the use of AS-i slave
module DI/DO signals as a standalone unit.

/
The AS-i comes in two main versions: Ver 2.0 and Ver 2.1. Two

om
types of I/O Link-AS-i converter units are available for each of these
versions.
An I/O Link-AS-i converter unit for Ver 2.0 differs from that for Ver
2.1 in the following points.

s.c
For Ver 2.0 For Ver 2.1
Number of 256 input points/256 output 512 input points/512 output
input/output points points points
Occupied groups 1 group Contiguous 2 groups

re
For each version, an example of connection is shown and the
assignment method is described below.

Example of connection for Ver 2.0


pa
cs
AS-i power
supply Group 0
.cn

I/O Link I/O Link-AS-i


master converter unit for
AS-i slave AS-i slave
Ver 2.0
w

Group 1
Operator's panel
w

connection unit
w

Assignment method for Ver 2.0


://

An assignment device name is selected from “Others”.


An I/O Link-AS-i converter unit occupies 256 points (32 bytes) for
tp

both input and output. Therefore, the assignment names are as


follows.
ht

Input device assignment name Output device assignment name


32 byte Unit (In) 32 byte Unit (Out)

- 52 -
B-63823EN/02 3.I/O LINK

Example of connection for Ver 2.1

AS-i power
supply Groups 0 and 1
I/O Link I/O Link-AS-i

/
om
master converter unit for AS-i slave AS-i slave
Ver 2.1

Group 2
Operator's panel

s.c
connection unit

re
Assignment method for Ver 2.1

pa
An assignment device name is selected from “Others”.
An I/O Link-AS-i converter unit occupies 512 points for both input
and output, 256 points (32 bytes) per group. Therefore, the
cs
assignment names per group are the same as for an I/O Link-AS-i
converter unit for Ver 2.0. Set the same assignment names for each
occupied group number.
.cn

Group number Input device assignment Output device assignment


name name
n 32 byte Unit (In) 32 byte Unit (Out)
n+1 32 byte Unit (In) 32 byte Unit (Out)
w

NOTE
w

An I/O Link-AS-i converter unit for Ver 2.1 cannot


be used as a converter unit for Ver 2.0 with
assignment data for Ver 2.0.
w
://
tp
ht

- 53 -
3.I/O LINK B-63823EN/02

3.3 I/O LINK CONNECTION CHECK FUNCTION

The I/O Link connection check function always checks whether the
number of I/O Link groups defined in a sequence program is the same

/
as that of actually connected groups. When the selectable I/O Link

om
assignment function is used, the I/O Link connection check function
compares the number of selected groups with that of connected
groups.
If these numbers of groups do not match, the PMC alarm "ER97 IO
LINK FAILURE (CHx yyGROUP)" is issued. For action to be taken,

s.c
see Section B.1.

NOTE
1 All I/O devices connected to the channel in which

re
this alarm occurs are not linked.
2 The ladder program is executed regardless of
whether this alarm occurs.

pa
The execution of this function can be controlled using keep
relay %SK51.
cs
%SK51
0: Enables the I/O Link connection check function. (Initial
value)
.cn

1: Disables the I/O Link connection check function.

CAUTION
If I/O devices are linked in the status in which an I/O
w

device error or I/O device connection error occurs or


the setting of an I/O device is changed due to an
w

unintentional operation, the machine may not


operate normally. This function can always be
operated to detect an I/O device error at power-on.
w

To troubleshoot problems with I/O devices easily, it


is recommended that keep relay %SK51 be set to
the initial value (0).
://
tp
ht

- 54 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4 LD INSTRUCTION GROUP

/
om
The following explains the Ladder Diagram(LD) instructions used by
a PMC sequence program.

PMC Instruction Set

s.c
Number Class Instruction
--| |--, --|/|--, |+|---
1. Contact, Coil
--( ), --(/), --(S), --(R),--(+)
2. Timer, counter ONDTR_, TMR_, OFDT_, UPCTR_, DNCTR_

re
3. Math operation ADD_, SUB_, MUL_, DIV_, MOD_, ABS_, SQRT_
4. Relational EQ_, NE_, GT_, GE_, LT_, LE_, RANGE_
AND_, OR_, XOR_, NOT_, SHIFTL_, SHIFTR_,
5.

6.
Bit operation

Data move
pa
ROL_, ROR_, BIT_TEST_, BIT_SET_, BIT_CLR_,
BIT_POS_, BIT_SEQ, MASK_COMP_
MOVE_, SWAP_, BLK_CLR_,SHFR_
ARRAY_MOV_, SEARCH_EQ_, SEARCH_NE_,
cs
7. Data table function SEARCH_GT_, SEARCH_GE_, SEARCH_LT_,
SEARCH_LE_
_TO_BCD2, _TO_BCD4, _TO_BCD8, BCD2_TO_,
.cn

8. Conversion BCD4_TO_, BCD8_TO_, _TO_SINT, _TO_USINT,


_TO_INT, _TO_UINT, _TO_DINT, _TO_UDINT
CALL, END, MCR, ENDMCR, MCRN, ENDMCRN,
9. Program flow
JUMPN, LABELN, COMMENT
PMC_ADD_BCD2, PMC_ADD_BCD4,PMC_ADD_BCD8,
w

PMC_SUB_BCD2, PMC_SUB_BCD4, PMC_SUB_BCD8,


PMC_MUL_BCD2,PMC_MUL_BCD4,PMC_MUL_BCD8,
PMC_DIV_BCD2, PMC_DIV_BCD4, PMC_DIV_BCD8,
w

10. PMC operation


PMC_MOD_BCD2,PMC_MOD_BCD4,PMC_MOD_BCD8,
R_TRIG, F_TRIG, PMC_DECODE_,
PMC_EVPAR, PMC_ODPAR, PMC_WINDOW,
w

PMC_EXIN, PMC_AXCTL
://
tp
ht

- 55 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.1 CONTACTS & COILS


Contacts
Instruction Function Data type

/
--| |-- Normally open contact (A contact) BOOL

om
--|/|-- Normally close contact (B contact) BOOL
|+|--- Continuous contact BOOL

Coils
Instruction Function Data type

s.c
--( )-- Coil BOOL
--(/)-- Reverse-wound coil BOOL
--(S)-- Set coil BOOL
--(R)-- Reset coil BOOL

re
---(+) Continuous coil BOOL

4.1.1 Normally Open Contacts (A Contacts)

Function pa
While the corresponding reference is set to ON, a normally open
cs
contact allows power to flow.

Format
.cn

???????

4.1.2 Normally Close Contacts (B Contacts)


w

Function
w

While the corresponding reference is set to OFF, a normally close


contact allows power to flow.
w

Format
???????
://

Example
While %I00001 is set to ON, but %I00002 is OFF, %Q00001 is set to
tp

ON.

% I00001 % I00002 % Q00001


ht

- 56 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.1.3 Coils

Function
While the coil is receiving a power flow, it sets the corresponding
reference to ON.

/
om
Format
???????

s.c
4.1.4 Reverse-wound Coils

re
Function
While the coil is not receiving a power flow, it sets the corresponding
reference to ON.

Format
???????
pa
cs
Example
While %I00001 is set to OFF (because %Q00001 is OFF), %Q00002
.cn

is set to ON.

% I00001 % Q00001
w

% Q00001 % Q00002
w
w

4.1.5 Setting Coil (SET)


://

Function
While the coil is receiving a power flow, it sets the corresponding
reference to ON.
tp

This ON state is maintained until reset by the reset coil (RESET),


described below.
Format
ht

???????

- 57 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.1.6 Reset Coil (RESET)

Function
While the coil is receiving a power flow, it sets the corresponding
reference to OFF.

/
This OFF state is maintained until the ON state is set by the set coil

om
(SET), described above.

Format
???????

s.c
Example
When %I00001 is ON, %Q00001 is set to ON. (This ON state is

re
maintained until reset by the reset coil (RESET).)
Similarly, when %I00002 is ON, %Q00002 is set to OFF. (This OFF
state is maintained until the ON state is set by the set coil (SET).)

% I00001
pa % Q00001
cs
% I00002 % Q00002
.cn
w
w
w
://
tp
ht

- 58 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.1.7 Continuous Contacts & Continuous Coils

Function
Indicates the continuation of a ladder when the ladder for one net can
not be described within 20 elements.

/
om
Format

Example
% I00001 REL
ABS INT

s.c
% R00010 IN Q %R00110

re
% I00011 %I00012 % I00013 %I00014 %I00029

%I00032 %I00033 % Q00010

Element 1 Element 2
pa
Element 3 Element 4 Element 19 Element 20
cs
NOTE
Multiple continuous contacts cannot be used in
parallel, as shown below.
.cn
w
w
w
://
tp
ht

- 59 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.2 TIMERS & COUNTERS


Timers
Controlled
Instruction Function Parameter Data type

/
I/O

om
ONDTR_(unit) Integrated on ADRS, PV ADRS = EN, ENO, R
delay timer one-dimensional
WORD array of 3
words
PV = INT

s.c
TMR_(unit) On delay timer ADRS, PV ADRS = EN, ENO
one-dimensional
WORD array of 3
words
PV = INT

re
OFDT_(unit) Off delay timer ADRS, PV ADRS = EN, ENO
one-dimensional
WORD array of 3

pa Counters
words
PV = INT
cs
Controlled
Instruction Function Parameter Data type
I/O
UPCTR Up counter ADRS, PV ADRS = EN, ENO, R
.cn

one-dimensional
WORD array of 3
words
PV = INT
w

DNCTR Down counter ADRS, PV ADRS = EN, ENO, R


one-dimensional
WORD array of 3
w

words
PV = INT
w
://
tp
ht

- 60 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.2.1 ONDTR

Function
The retentive On-Delay Stopwatch Timer (ONDTR) increments while
it receives power flow and holds its value when power flow stops.

/
When this function first receives power flow, it starts accumulating

om
time (Current Value (CV)). When this timer is encountered in the
ladder logic, its CV is updated. When the CV equals or exceeds Preset
Value (PV), output Q is energized, regardless of the state of the power
flow input.
The instruction differs depending on the units in which the timer is

s.c
set.

Integrated on timer
Name Setting units

re
ONDTR_THOUS 0.001 s
ONDTR_HUNDS 0.01 s
ONDTR_TENTHS 0.1 s
ONDTR_SECS
ONDTR_TENSEC
ONDTR_MIN
pa 1s
10 s
1 min
cs
Format
.cn

ONDTR
(EN) HUNDS (ENO)

ADRS

(R) R
w

??????? PV
w
w
://
tp
ht

- 61 -
4.LD INSTRUCTION GROUP B-63823EN/02

Parameters
Parameter Data type Meaning
ADRS one-dimensio ADRS is the beginning address of a three-word
nal WORD WORD array:
array of 3 Word 1: Current value (CV)

/
words Word 2: Preset value (PV)

om
Word 3: Control word
EN BOOL Timer start
R BOOL Timer reset
PV INT Set time (Preset Value)
The time required to actually reach time up will be

s.c
this value to which the set units are applied.
ENO BOOL Time up

Memory Type

re
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
ADRS o o
EN
R
PV
o
o pa
o
o
o
o
o
o
o
o
o
o
o
o o o
cs
ENO o o o Note o

NOTE
.cn

Only %SK can be specified.

Example
%Q00011 is turned ON 0.8 s after %Q00010 is set to ON.
(%Q00011 is turned OFF when %Q00020 is turned ON.)
w

%Q00010 %Q00011
w

ONDTR
HUNDS

% Q00020 % R00004
w

CONST PV
://

+00080
tp
ht

- 62 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.2.2 TMR

Function
The On-Delay Timer (TMR) increments while it receives power flow
and resets to zero when power flow stops. The timer passes power

/
after the specified interval PV (Preset Value) has elapsed, as long as

om
power is received. When the On Delay Timer function receives power
flow, the timer starts accumulating time (Current Value (CV)). CV is
updated when it is encountered in the logic to reflect the total elapsed
time the timer has been enabled since it was last reset. This update
occurs as long as the power flow input remains ON. When CV equals

s.c
or exceeds the Preset Value (PV), the function begins passing power
flow to the right. When the power flow input transitions from ON to
OFF, the timer stops accumulating time, CV is reset to zero, and Q is
turned off.

re
Output Q is energized when TMR is enabled and PV ≤ CV.

On delay timer

TMR_THOUS
TMR_HUNDS
Name
pa Setting units
0.001 s
0.01 s
cs
TMR_TENTHS 0.1 s
TMR_SECS 1s
TMR_TENSEC 10 s
.cn

TMR_MIN 1 min

Format
w

TMR
(EN) HUNDS (ENO)

ADRS
w

??????? PV
w

Parameters
Parameter Data type Meaning
ADRS one-dimensional ADRS is the beginning address of a
://

WORD array of 3 three-word WORD array:


words Word 1: Current value (CV)
Word 2: Preset value (PV)
tp

Word 3: Control word


EN BOOL Timer start
PV INT Set time (Preset Value)
ht

The time required to actually reach time up


will be this value to which the set units are
applied.
ENO BOOL Time up

- 63 -
4.LD INSTRUCTION GROUP B-63823EN/02

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
ADRS o o
EN o o o o o

/
PV o o o o o o

om
ENO o o o Note o

NOTE
Only %SK can be specified.

s.c
Example
While REL is OFF, if DO_DWL is turned ON, DWELL is also turned
ON. (The latch circuit causes the ON state to be maintained even if
DO_DWL is subsequently set to OFF.)

re
Then, 0.05 s later, TMR005 causes REL to turn ON, disconnects the
latch circuit, and sets DWELL to OFF. As a result, REL is turned OFF,
and the initial status is restored.

DO_DW L REL pa DW ELL


cs
DW ELL

DW ELL REL
.cn

TMR

HUNDS
TMR005
CONST
PV
+00005
w
w
w
://
tp
ht

- 64 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.2.3 OFDT

Function
The Off-Delay Timer (OFDT) increments while power flow is off, and
the timer's Current Value (CV) resets to zero when power flow is on.

/
OFDT passes power until the specified interval PV (Preset Value) has

om
elapsed.
When OFDT first receives power flow, CV is set to zero and the timer
passes power to the right, even if PV=0. The output remains on as
long as OFDT receives power flow. If OFDT stops receiving power
flow from the left, it continues to pass power to the right and OFDT

s.c
starts accumulating time in CV. Each time OFDT is invoked with the
power flow logic set to OFF, CV is updated to reflect the elapsed time
since the timer was turned off. OFDT continues passing power flow to
the right until CV=PV. When CV=PV, OFDT stops passing power

re
flow to the right and OFDT stops accumulating time. CV remains
equal to PV and never exceeds PV. If PV=0, the timer stops passing
power flow to the right as soon as it stops receiving power flow.

Name
pa
Off delay timer
Setting units
cs
OFDT_THOUS 0.001 s
OFDT_HUNDS 0.01 s
OFDT_TENTHS 0.1 s
.cn

OFDT_SECS 1s
OFDT_TENSEC 10 s
OFDT_MIN 1 min
w

Format
OFDT
(EN) (ENO)
w

HUNDS

ADRS

??????? PV
w

Parameters
://

Parameter Data type Meaning


ADRS one-dimensional ADRS is the beginning address of a
WORD array of 3 three-word WORD array:
tp

words Word 1: Current value (CV)


Word 2: Preset value (PV)
Word 3: Control word
ht

EN BOOL Timer start


PV INT Set time (Preset Value)
The time required to actually reach time up
will be this value to which the set units are
applied.
ENO BOOL Time up

- 65 -
4.LD INSTRUCTION GROUP B-63823EN/02

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
ADRS o o
EN o o o o o

/
PV o o o o o o

om
ENO o o o Note o

NOTE
Only %SK can be specified.

s.c
Example
When %I00010 is turned ON, %Q00011 is turned ON, and that state
is maintained.
Then, 0.8 s after %I00010 has been set to OFF, %Q00011 is turned

re
off.

%I00010

pa OFDT
HUNDS

%R00004
%Q00011
cs
CONST
PV
+00080
.cn
w
w
w
://
tp
ht

- 66 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.2.4 UPCTR

Function
The Up Counter (UPCTR) function counts up to the Preset Value
(PV). The range is 0 to +32,767 counts. When the Current Value (CV)

/
of the counter reaches 32,767, it remains there until reset. When the

om
UPCTR reset is ON, CV resets to 0. Each time the power flow input
transitions from OFF to ON, CV increments by 1. CV can be
incremented past the Preset Value (PV). The output is ON whenever
CV ≥ PV. The output stays ON until the R input receives power flow
to reset CV to zero.

s.c
Format
UPCTR
(EN) (ENO)

re
ADRS

(R) R

Parameters
??????? PV

pa
cs
Parameter Data type Meaning
ADRS one-dimensional ADRS is the beginning address of a
.cn

WORD array of 3 three-word WORD array:


words Word 1: Current Value (CV)
Word 2: Preset Value (PV)
Word 3: Control word
EN BOOL Counter start
w

R BOOL Reset
PV INT Set value (Preset Value)
ENO BOOL Reach to the Preset Value
w

Memory Type
w

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
ADRS o o
://

EN o o o o o
R o o o o o
PV o o o o o o
tp

ENO o o o Note o

NOTE
ht

Only %SK can be specified.

- 67 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
Every time %I00001 goes from OFF to ON, the count is incremented
by one.
Once CV exceeds 100, %Q00001 is set to ON. (Also, at this time,
CV is reset to 0.)

/
om
% I00001 % Q00001
UPCTR

% R00004
% Q00001

s.c
CONST
PV
+00100

re
pa
cs
.cn
w
w
w
://
tp
ht

- 68 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.2.5 DNCTR

Function
The Down Counter (DNCTR) function counts down from a preset
value. The minimum Preset Value (PV) is zero; the maximum present

/
value is +32,767 counts. When the Current Value (CV) reaches the

om
minimum value, -32,768, it stays there until reset. When DNCTR is
reset, CV is set to PV. When the power flow input transitions from
OFF to ON, CV is decremented by one. The output is ON whenever
CV ≤ 0.

s.c
Format

re
DNCTR
(EN) (ENO)

ADRS

(R)

???????
R

PV
pa
cs
Parameters
Parameter Data type Meaning
.cn

ADRS one-dimensional ADRS is the beginning address of a


WORD array of 3 three-word WORD array:
words Word 1: Current Value (CV)
Word 2: Preset Value (PV)
Word 3: Control word
w

EN BOOL Counter start


R BOOL Reset
w

PV INT Set value (Preset Value)


ENO BOOL Current Value falls below 0
w

Memory Type
Memory
://

Flow %I* %Q* %M* %S* %R Constant Omissible


ADRS o o
EN o o o o o
tp

R o o o o o
PV o o o o o o o
ENO o o o Note o
ht

NOTE
Only %SK can be specified.

- 69 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
Every time %I00001 goes from OFF to ON, the count is decremented
by one.
Once the value of CV falls below 0, %Q00001 is set to ON. (Also,
at this time, CV is reset to 100.)

/
om
%I00001 %Q00001
DNCTR

% R00004
% Q00001
R

s.c
CONST
PV
+00100

re
pa
cs
.cn
w
w
w
://
tp
ht

- 70 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.3 MATH OPERATIONS


Math operation functions
Instruction Function Parameters Data type Controlled I/O

/
ADD_(type) Addition IN1, IN2, Q ANY_INT EN, ENO

om
SUB_(type) Subtraction IN1, IN2, Q ANY_INT EN, ENO
MUL_(type) Multiplication IN1, IN2, Q ANY_INT EN, ENO
DIV_(type) Division IN1, IN2, Q ANY_INT EN, ENO
MOD_(type) Mode IN1, IN2, Q ANY_INT EN, ENO
ABS_(type) Absolute value IN, Q SINT, INT, EN, ENO

s.c
DINT
SQRT_(type) Square root IN, Q ANY_INT EN, ENO

re
pa
cs
.cn
w
w
w
://
tp
ht

- 71 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.3.1 ADD_(type)/SUB_(type)/MUL_(type)/DIV_(type)

Function
When EN is set to ON and is receiving the power flow, ADD, SUB,
MUL, and DIV perform, on input parameters IN1 and IN2, addition

/
(IN1 + IN2), subtraction (IN1 - IN2), multiplication (IN1 X IN2), and

om
division (IN1 ÷ IN2), respectively. The result is output to output
parameter Q.
IN1, IN2, and Q must all be of the same data type.
If the arithmetic operation results in an overflow, the maximum value
for that data type is set in the output reference. For a signed data

s.c
type, the direction of the overflow is indicated, based on the sign.
When the operation can be completed without any overflow, ENO is
set to ON.

re
Addition/subtraction/multiplication/division
Name Explanation
ADD_SINT
ADD_USINT
ADD_INT
ADD_UINT
pa
Addition of SINT data
Addition of USINT data
Addition of INT data
Addition of UINT data
cs
ADD_DINT Addition of DINT data
ADD_UDINT Addition of UDINT data
SUB_SINT Subtraction of SINT data
.cn

SUB_USINT Subtraction of USINT data


SUB_INT Subtraction of INT data
SUB_UINT Subtraction of UINT data
SUB_DINT Subtraction of DINT data
SUB_UDINT Subtraction of UDINT data
w

MUL_SINT Multiplication of SINT data


MUL_USINT Multiplication of USINT data
w

MUL_INT Multiplication of INT data


MUL_UINT Multiplication of UINT data
MUL_DINT Multiplication of DINT data
w

MUL_UDINT Multiplication of UDINT data


DIV_SINT Division of SINT data
DIV_USINT Division of USINT data
://

DIV_INT Division of INT data


DIV_UINT Division of UINT data
DIV_DINT Division of DINT data
tp

DIV_UDINT Division of UDINT data


ht

- 72 -
B-63823EN/02 4.LD INSTRUCTION GROUP

Format
ADD
(EN) (type) (ENO)

??????? IN1 Q ???????

/
om
??????? IN2

SUB
MUL
DIV

s.c
Parameters
Parameter Data type Meaning
EN BOOL Execution of operation

re
IN1 ANY_INT Input data 1
IN2 ANY_INT Input data 2
ENO BOOL Normal end flag (set to OFF upon an overflow)

Memory Type
Q ANY_INT
pa Result
cs
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
.cn

IN1 o o o o o o
IN2 o o o o o o
ENO o o o Note o
Q o o Note o
w

NOTE
Only %SK can be specified.
w

Example
When %I00001 is set to ON, 1 is added to the value of %R00001, 95,
w

to give an output of 96 to %R00010. %Q00001 is set to ON, and


notification of the operation ending without an overflow is posted.
://

% I00001 % Q00001
ADD
INT
tp

% R00001 IN1 Q % R00010


+00095
ht

CONST IN2
+00001

- 73 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.3.2 MOD_(type)

Function
When EN is set to ON and is receiving the power flow, MOD
performs, on input parameters IN1 and IN2, division (IN1 ÷ IN2) and

/
outputs the remainder to output parameter Q.

om
IN1, IN2, and Q must all be of the same data type. Q will have the
same sign as IN1.
When the operation terminates without an overflow (division by 0),
ENO is set to ON.

s.c
The Modulo Division (MOD) function
Name Explanation
MOD_SINT MOD of SINT data

re
MOD_USINT MOD of USINT data
MOD_INT MOD of INT data
MOD_UINT MOD of UINT data

Format
MOD_DINT
MOD_UDINT
pa MOD of DINT data
MOD of UDINT data
cs
MOD
(EN) (type) (ENO)
.cn

??????? IN1 Q ???????

??????? IN2
w

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of operation


IN1 ANY_INT Input data 1
w

IN2 ANY_INT Input data 2


ENO BOOL Normal end flag (set to OFF upon an overflow)
Q ANY_INT Result
://

Memory Type
Memory
tp

Flow %I* %Q* %M* %S* %R Constant Omissible


EN o o o o o
ht

IN1 o o o o o o
IN2 o o o o o o
ENO o o o Note o
Q o o Note o

NOTE
Only %SK can be specified.

- 74 -
B-63823EN/02 4.LD INSTRUCTION GROUP

Example
When %I00001 is set to ON, division (-17 ÷ 6) is performed and the
remainder - 5 is output to %R00010.

% I00001 % Q00001
MOD

/
INT

om
% R00001 IN1 Q % R00010
-00017
-00005

CONST IN2
+00006

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 75 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.3.3 ABS_(type)

Function
When EN is set to ON and is receiving the power flow, ABS takes the
absolute value of input parameter IN and outputs it to output

/
parameter Q.

om
ABS_(type) instructions
Name Explanation
ABS_SINT The absolute value of SINT data

s.c
ABS_INT The absolute value of INT data
ABS_DINT The absolute value of DINT data

Format

re
ABS
(EN) (type) (ENO)

Parameters
???????

Parameter
IN

pa
Q

Data type
???????

Meaning
cs
EN BOOL Execution
IN SINT,INT, DINT Input data
ENO BOOL Normal end flag
.cn

(set to OFF upon an overflow)


Q SINT,INT, DINT Absolute value

Memory Type
w

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
w

EN o o o o o
IN o o o o o o
ENO o o o Note o
w

Q o o Note o

NOTE
://

Only %SK can be specified.

Example
tp

When %I00010 is set to ON, the absolute value of -1234, namely


1234, is output to %R00020.
ht

%I00010 %Q00011
ABS
INT

CONST IN Q % R00020
-1234 1234

- 76 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.3.4 SQRT_(type)

Function
When EN is set to ON and is receiving the power flow, SQROOT
takes the square root of input parameter IN and outputs it to output

/
parameter Q.

om
IN and Q must both be of the same data type.

SQRT_(type) instructions
Name Explanation

s.c
SQRT_SINT The square root of SINT data
SQRT_USINT The square root of USINT data
SQRT_INT The square root of INT data
SQRT_UINT The square root of UINT data

re
SQRT_DINT The square root of DINT data
SQRT_UDINT The square root of UDINT data

Format
(EN)
SQRT
(type) pa (ENO)
cs
??????? IN Q ???????

Parameters
.cn

Parameter Data type Meaning


EN BOOL Execution
IN ANY_INT Input data
ENO BOOL Normal end flag (set to OFF upon an overflow)
w

Q ANY_INT Square root

Memory Type
w

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
w

EN o o o o o
IN o o o o o o
ENO o o o Note o
://

Q o o Note o

NOTE
tp

Only %SK can be specified.

Example
ht

When %I00010 is set to ON, the square root of the value of %R00100
is output to %R00200.

%I00010 %Q00011
SQRT
INT

%R00100 IN Q % R00200

- 77 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.4 RELATIONAL OPERATIONS


Comparison instructions
Controlled
Instruction Function Parameter Data type

/
I/O

om
EQ_(type) Equal to IN1, IN2 BYTE, WORD, EN, Q
DWORD, ANY_INT
NE_(type) Not equal to IN1, IN2 BYTE, WORD, EN, Q
DWORD, ANY_INT
GT_(type) Greater than IN1, IN2 ANY_INT EN, Q

s.c
(IN1 > IN2)
GE_(type) Greater than or IN1, IN2 ANY_INT EN, Q
equal to
(IN1 ≥ IN2)
LT_(type) Less than IN1, IN2 ANY_INT EN, Q

re
(IN1 < IN2)
LE_(type) Less than or IN1, IN2 ANY_INT EN, Q
equal to
(IN1 ≤ IN2)
RANGE_(type) Range compare pa L1, L2, IN ANY_INT EN, Q
cs
.cn
w
w
w
://
tp
ht

- 78 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.4.1 EQ_(type)/NE_(type)

Function
When EN is set to ON and is receiving the power flow, the signs of
input parameters IN1 and IN2 are checked for equivalence (IN1 =

/
IN2?) or non-equivalence (IN1≠IN2?). When the result of the

om
comparison is true, power is allowed to flow and Q is set to ON.
IN1 and IN2 must both be of the same data type.

EQ_(type)/NE_(type) instructions

s.c
Name Explanation
EQ_BYTE Equal to BYTE data
EQ_WORD Equal to WORD data
EQ_DWORD Equal to DWORD data

re
EQ_SINT Equal to SINT data
EQ_USINT Equal to USINT data
EQ_INT Equal to INT data
EQ_UINT
EQ_DINT
EQ_UDINT
NE_BYTE
pa
Equal to UINT data
Equal to DINT data
Equal to UDINT data
Not equal to BYTE data
cs
NE_WORD Not equal to WORD data
NE_DWORD Not equal to DWORD data
NE_SINT Not equal to SINT data
.cn

NE_USINT Not equal to USINT data


NE_INT Not equal to INT data
NE_UINT Not equal to UINT data
NE_DINT Not equal DINT data
NE_UDINT Not equal UDINT data
w

Format
w

EQ
(EN) (type)
w

??????? IN1 Q ???????


://

??????? IN2

NE
tp

Parameters
Parameter Data type Meaning
EN BOOL Execution of comparison
ht

IN1 BYTE, WORD, Input data 1


DWORD,
ANY_INT
IN2 BYTE, WORD, Input data 2
DWORD,
ANY_INT
Q BOOL Result of comparison
(set to ON when condition is satisfied)

- 79 -
4.LD INSTRUCTION GROUP B-63823EN/02

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o

/
IN1 o o o o o o

om
IN2 o o o o o o
Q o o o Note o

NOTE

s.c
Only %SK can be specified.

Example
When %I00001 is set to ON, the values of %R00001 and %R00002

re
are compared and, if they are equivalent, %Q00002 is set to ON.

%I00001
EQ

%R00001
pa (type)

IN1 Q
%Q00002
cs
%R00002 IN2
.cn
w
w
w
://
tp
ht

- 80 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.4.2 GT_(type)/GE_(type)/LT_(type)/LE_(type)

Function
When EN is set to ON and is receiving the power flow, the values of
input parameters IN1 and IN2 are compared (IN1 > IN2?/IN1 ≥

/
IN2?/IN1 < IN2?/IN1 ≤ IN2?). If the result of the comparison is true,

om
power is allowed to flow and Q is set to ON.
IN1 and IN2 must both be of the same data type.

GT_(type)/GE_(type)/LT_(type)/LE_(type) instructions

s.c
Name Explanation
GT_SINT Greater than (SINT data)
GT_USINT Greater than (USINT data)
GT_INT Greater than (INT data)

re
GT_UINT Greater than (UINT data)
GT_DINT Greater than (DINT data)
GT_UDINT Greater than (UDINT data)
GE_SINT
GE_USINT
GE_INT
GE_UINT
pa
Greater than or equal(SINT data)
Greater than or equal(USINT data)
Greater than or equal(INT data)
Greater than or equal(UINT data)
cs
GE_DINT Greater than or equal(DINT data)
GE_UDINT Greater than or equal(UDINT data)
LT_SINT Less than (SINT data)
.cn

LT_USINT Less than (USINT data)


LT_INT Less than (INT data)
LT_UINT Less than (UINT data)
LT_DINT Less than (DINT data)
LT_UDINT Less than (UDINT data)
w

LE_SINT Less than or equal (SINT data)


LE_USINT Less than or equal (USINT data)
w

LE_INT Less than or equal (INT data)


LE_UINT Less than or equal (UINT data)
LE_DINT Less than or equal (DINT data)
w

LE_UDINT Less than or equal (UDINT data)

Format
://

GT
(EN) (type)
tp

??????? IN1 Q ???????


ht

??????? IN2

GE
LT
LE

- 81 -
4.LD INSTRUCTION GROUP B-63823EN/02

Parameters
Parameter Data type Meaning
EN BOOL Execution of comparison
IN1 ANY_INT Input data 1
IN2 ANY_INT Input data 2

/
Q BOOL Result of comparison

om
(set to ON when condition is satisfied)

Memory Type
Memory

s.c
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
IN1 o o o o o o
IN2 o o o o o o

re
Q o o o Note o

NOTE

Example
pa
Only %SK can be specified.
cs
When %I00001 is set to ON, the values of %R00001 and %R00002
are compared. When the former is larger than the latter, %Q00002 is
set to ON.
.cn

%I00001
GT
INT

%Q00002
%R00001 IN1 Q
w

%R00002 IN2
w
w
://
tp
ht

- 82 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.4.3 RANGE_(type)

Function
When EN is set to ON and is receiving the power flow, RANGE
compares input parameter IN with the range of L1 and L2. When L1

/
≤ IN ≤ L2, or L2 ≤ IN ≤ L1, power is allowed to flow and Q is set to

om
ON.
L1, L2 and IN must all be of the same data type.

RANGE_(type) instructions

s.c
Name Explanation
RANGE_SINT Range compare of SINT data
RANGE_USINT Range compare of USINT data
RANGE_INT Range compare of INT data

re
RANGE_UINT Range compare of UINT data
RANGE_DINT Range compare of DINT data
RANGE_UDINT Range compare of UDINT data

Format
(EN)
RANGE
pa
(type)
cs
??????? L1 Q ???????
.cn

??????? L2

??????? IN
w

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of comparison


L1 ANY_INT Threshold 1
L2 ANY_INT Threshold 2
w

IN ANY_INT Comparison data


Q BOOL Set to ON when L1 ≤ IN ≤ L2, or L2 ≤ IN ≤ L1
://

Memory Type
Memory
tp

Flow %I* %Q* %M* %S* %R Constant Omissible


EN o o o o o
L1 o o o o o o
ht

L2 o o o o o o
IN o o o o o o
Q o o o Note o

NOTE
Only %SK can be specified.

- 83 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00001 is set to ON, and the value of %R00100 is between 0
and 100, %Q00100 is set to ON.

%I00001
RANGE

/
INT

om
%Q00100
CONST L1 Q
+100

CONST L2
0

s.c
% R00100 IN

re
pa
cs
.cn
w
w
w
://
tp
ht

- 84 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.5 BIT OPERATIONS

Bit operation functions


Instruction Function Parameter Data type Controlled

/
I/O

om
AND_(type) Logical AND IN1, IN2, Q BYTE, WORD, DWORD EN, ENO
OR_(type) Logical OR IN1, IN2, Q BYTE,WORD, DWORD EN, ENO
XOR_(type) Exclusive IN1, IN2, Q BYTE,WORD, DWORD EN, ENO
logical OR
NOT_(type) Logical NOT IN, Q BYTE,WORD, DWORD EN, ENO

s.c
SHIFTL_(type) Left shift LEN, IN, N, Q LEN = The number of data EN, B1, B2
IN/Q = BYTE, WORD,
DWORD
N = INT

re
SHIFTR_(type) Right shift LEN, IN, N, Q LEN = The number of data EN, B1, B2
IN/Q = BYTE, WORD,
DWORD

ROL_(type) Rotate left


pa N = INT
LEN, IN, N, Q LEN = The number of data
IN/Q = BYTE, WORD,
DWORD
EN, ENO
cs
N = INT
ROR_(type) Rotate right LEN, IN, N, Q LEN = The number of data EN, ENO
IN/Q = BYTE, WORD,
.cn

DWORD
N = INT
BIT_TEST_(type) Bit test IN, BIT IN/Q = BYTE, WORD, EN, Q
DWORD
BIT = INT
w

BIT_SET_(type) Bit set LEN, IN, BIT LEN = The number of data EN, ENO
IN/Q = BYTE, WORD,
DWORD
w

BIT = INT
BIT_CLR_(type) Bit clear LEN, IN, BIT LEN = The number of data EN, ENO
IN/Q = BYTE, WORD,
w

DWORD
BIT = INT
BIT_POS_(type) Bit position LEN, IN, POS LEN = The number of data EN, ENO
://

IN = BYTE, WORD,
DWORD
POS = INT
tp

BIT_SEQ Sequence a ADRS, LEN, ADRS = one-dimensional EN, ENO, R,


string of bit N, ST WORD array of 3 words DIR
values. LEN = The number of data
ht

N = INT
ST = BYTE
MASK_COMP_(ty Compare the LEN, IN1, LEN = The number of data EN, MC
pe) bits in two IN2, M, BIT, IN1/IN2/M/Q = BYTE,
strings Q, BN WORD, DWORD
BIT/BN = UINT

- 85 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.5.1 AND_(type)/OR_(type)

Function
When EN is set to ON and is receiving the power flow, AND/OR
performs a logical AND/logical OR operation on each bit of the

/
corresponding bit strings in input parameters IN1 and IN2. The

om
result is output to the corresponding bit of output parameter Q.
IN1, IN2 and Q must all be of the same data type.

AND_(type)/OR_(type) instructions

s.c
Name Explanation
AND_BYTE Logical AND of BYTE data
AND_WORD Logical AND of WORD data
AND_DWORD Logical AND of DWORD data

re
OR_BYTE Logical OR of BYTE data
OR_WORD Logical OR of WORD data
OR_DWORD Logical OR of DWORD data

Format
(EN)
AND
(type)
pa (ENO)
cs
??????? IN1 Q ???????
.cn

??????? IN2

OR

Parameters
w

Parameter Data type Meaning


EN BOOL Execution of logical operation
w

IN1 BYTE, WORD, DWORD Input data 1


IN2 BYTE, WORD, DWORD Input data 2
ENO BOOL Returns the value of EN
w

Q BYTE, WORD, DWORD Result of operation


://

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
tp

EN o o o o o
IN1 o o o o o o
IN2 o o o o o o
ht

ENO o o o Note o
Q o o Note o

NOTE
Only %SK can be specified.

- 86 -
B-63823EN/02 4.LD INSTRUCTION GROUP

Example
When %I00001 is set to ON, a logical operation is performed on each
corresponding bit of the bit strings of input parameters %R00001
and %R00002. The result is output to the corresponding bit of the
bit string of %R00010.

/
om
%I00001 %Q00001
AND
W ORD

%R00001 IN1 Q % R00010

s.c
%R00002 IN2

re
pa
cs
.cn
w
w
w
://
tp
ht

- 87 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.5.2 XOR_(type)

Function
When EN is set to ON and is receiving the power flow, XOR performs
an exclusive logical OR operation on each corresponding bit of the bit

/
strings in input parameters IN1 and IN2. The result is output to the

om
corresponding bit of output parameter Q.
IN1, IN2 and Q must all be of the same data type.

XOR_(type) instructions

s.c
Name Explanation
XOR_BYTE Exclusive logical OR of BYTE data
XOR_WORD Exclusive logical OR of WORD data
XOR_DWORD Exclusive logical OR of DWORD data

re
Format
(EN)

???????
XOR
(type)

IN1
pa
Q
(ENO)

???????
cs
??????? IN2
.cn

Parameters
Parameter Data type Meaning
EN BOOL Execution of logical operation
w

IN1 BYTE, WORD, DWORD Input data 1


IN2 BYTE, WORD, DWORD Input data 2
ENO BOOL Returns the value of EN
w

Q BYTE, WORD, DWORD Result of operation


w

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
://

EN o o o o o
IN1 o o o o o o
tp

IN2 o o o o o o
ENO o o o Note o
ht

Q o o Note o

NOTE
Only %SK can be specified.

- 88 -
B-63823EN/02 4.LD INSTRUCTION GROUP

Example
When %I00001 is set to ON, a logical operation is performed on each
corresponding bit of the bit strings of %R00001 and %R00001. The
result is output to the corresponding bit of the bit string of %R00001.
(In this case, all the bits of %R00001 are cleared to 0.)

/
om
%I00001 %Q00001
XOR
W ORD

%R00001 IN1 Q % R00001

s.c
%R00001 IN2

re
pa
cs
.cn
w
w
w
://
tp
ht

- 89 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.5.3 NOT_(type)

Function
When EN is set to ON and is receiving the power flow, NOT logically
inverts each bit of a bit string in input parameter IN. The result is

/
output to the corresponding bit of output parameter Q.

om
IN and Q must both be of the same data type.

NOT_(type) instructions
Name Explanation

s.c
NOT_BYTE Logical NOT of BYTE data
NOT_WORD Logical NOT of WORD data
NOT_DWORD Logical NOT of DWORD data

Format

re
NOT
(EN) (type) (ENO)

Parameter
??????? IN

pa
Q ???????
cs
Parameter Data type Meaning
EN BOOL Execution of logical operation
IN BYTE, WORD, DWORD Input data
.cn

ENO BOOL Returns the value of EN


Q BYTE, WORD, DWORD Result of operation

Memory Type
w

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
w

EN o o o o o
IN o o o o o o
ENO o o o Note o
w

Q o o Note o

NOTE
://

Only %SK can be specified.


tp

Example
When %I00010 is set to ON, each bit of the bit string of %R00100 is
logically inverted. The result is output to the corresponding bit of
ht

the bit string of %R00200.

%I00010 %Q00011
NOT
W ORD

%R00100 IN Q % R00200

- 90 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.5.4 SHIFTL_(type)/SHIFTR_(type)

Function
When EN is set to ON and is receiving the power flow,
SHIFTL/SHIFTR left-shifts/right-shifts the bit string of input

/
parameter IN by an amount given by input parameter N.

om
The last bit to overflow is output to output parameter B2, and the
value of input parameter B1 (0 or 1) is replaced with an empty bit.
The shifted bit string is output to output parameter Q.
IN and Q must both be of the same data type. When the value of N
is less than 0, or greater than the number of bits in the bit string of IN,

s.c
SHIFTL/SHIFTR stops the power flow.

SHIFTL_(type)/SHIFTR_(type) instructions
Name Explanation

re
SHIFTL_BYTE Left shift of BYTE data
SHIFTL_WORD Left shift of WORD data
SHIFTL_DWORD
SHIFTR_BYTE
SHIFTR_WORD
SHIFTR_DWORD
pa Left shift of DWORD data
Right shift of BYTE data
Right shift of WORD data
Right shift of DWORD data
cs
Format
SHIFTL
(EN)
.cn

(type)

LEN

??????? IN B2 ???????

??????? N Q ???????
w

??????? B1
w

SHIFTR
w

Parameters
Parameter Data type Meaning
EN BOOL Execution of shift
://

LEN Constant The number of data in the string.


1 ≤ LEN ≤ 256
IN BYTE, WORD, DWORD Shifted data
tp

N INT Among of shift (bits)


B1 BOOL Value placed in bit emptied by shift
B2 BOOL Last bit to overflow
ht

Q BYTE, WORD, DWORD Result of operation

- 91 -
4.LD INSTRUCTION GROUP B-63823EN/02

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
IN o o o o o o

/
N o o o o o o

om
B1 o o o o o
B2 o o o Note o
Q o o Note o

NOTE

s.c
Only %SK can be specified.

Example
When %I00001 is set to ON, the bit string of %R00001 is shifted five

re
bits to the left, and the left-shifted bit string is output to %R00002.
The last bit to overflow is output to %Q00001, and the value of input
parameter %I00002 is replaced with an empty bit.

pa
When the bit string of %R00001 is 0011100011011011, and %I00002
is set to ON, 0001101101111111 is output to %R00002 and 1 is
output to %Q00001.
cs
% I00001
SHIFTL
W ORD
1
.cn

% Q00001

%R00001 IN B2

CONST N Q %R00002
+00005
w

% I00002
B1
w
w
://
tp
ht

- 92 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.5.5 ROL_(type)/ROR_(type)

Function
When EN is set to ON and is receiving the power flow, ROL/ROR left
rotates/right rotates the bit string of input parameter IN by an amount

/
equal to the value of input parameter N.

om
The rotated bit string is output to output parameter Q.
IN and Q must be both of the same data type. When the value of N
is 0 or less, or larger than the number of bits in the bit string of IN, bit
string rotation is not performed, and ROL/ROR is not performed.

s.c
ROL_(type)/ROR_(type) instructions
Name Explanation
ROL_BYTE Rotate left of BYTE data
ROL_WORD Rotate left of WORD data

re
ROL_DWORD Rotate left of DWORD data
ROR_BYTE Rotate right of BYTE data
ROR_WORD Rotate right of WORD data

Format
ROR_DWORD

ROL
pa Rotate right of DWORD data
cs
(EN) (type) (ENO)

LEN

??????? IN Q ???????
.cn

??????? N

ROR
w

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of operation


LEN Constant The number of data in the
string. 1 ≤ LEN ≤ 256
w

IN BYTE, WORD, DWORD Shifted data


N INT Amount of shift (bits)
ENO BOOL Normal end flag
://

Q BYTE, WORD, DWORD Result of operation

Memory Type
tp

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
ht

EN o o o o o
IN o o o o o o
N o o o o o o
ENO o o o Note o
Q o o Note o

NOTE
Only %SK can be specified.

- 93 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00001 is set to ON, the bit string of %R00001 is rotated left
by 3 bits, then the rotated bit string is output to %R00002.
When the bit string of %R00001 is 0011100011011011,

/
1100011011011001 is output to %R00002.

om
% I00001 % Q00001
ROL
W ORD
1

% R00001 IN Q % R00002

s.c
CONST N
+00003

re
pa
cs
.cn
w
w
w
://
tp
ht

- 94 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.5.6 BIT_TEST_(type)

Function
When EN is set to ON and is receiving the power flow and BIT_TEST
outputs to output parameter Q, the bit state (0 or 1) specified with

/
input parameter BIT in the bit string of input parameter IN.

om
When the value of BIT is 1 or more and not less than the number of
bits in the bit string of IN, Q is set to OFF.

BIT_TEST_(type) instructions

s.c
Name Explanation
BIT_TEST_BYTE Bit test of BYTE data
BIT_TEST_WORD Bit test of WORD data
BIT_TEST_DWORD Bit test of DWORD data

re
Format
BIT
(EN ) TEST

??????? IN
(type)
LEN

pa
Q ???????
cs
??????? BIT
.cn

Parameters
Parameter Data type Meaning
EN BOOL Execution of operation
LEN Constant The number of data in the
string. 1 ≤ LEN ≤ 256
w

IN BYTE, WORD, DWORD Input data


BIT INT Test bit
w

Q BOOL Result of operation

Memory Type
w

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
://

EN o o o o o
IN o o o o o o
BIT o o o o o o
tp

Q o o o Note o

NOTE
ht

Only %SK can be specified.

- 95 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00001 is set to ON, the bit state of the 3rd bit of %R00001 is
output to %Q00002.
When the bit string of %R00001 is 0011100011011011, 0 is output
to %Q00002.

/
om
% I00001
BIT
TEST
WOR D
1 % Q00002

% R 00001 IN Q

s.c
C ON ST BIT
+00003

re
pa
cs
.cn
w
w
w
://
tp
ht

- 96 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.5.7 BIT_SET_(type)/BIT_CLR_(type)

Function
When EN is set to ON and is receiving the power flow,
BIT_SET/BIT_CLR sets to 1 or clears to 0 that bit, specified with

/
input parameter BIT, within the bit string of input parameter IN.

om
When the value of BIT is less than one or more than the number of
bits in the IN bit string, ENO is set to OFF.

BIT_SET_(type)/BIT_CLR_(type) instructions

s.c
Name Explanation
BIT_SET_BYTE Bit set of BYTE data
BIT_SET_WORD Bit set of WORD data
BIT_SET_DWORD Bit set of DWORD data

re
BIT_CLR_BYTE Bit clear of BYTE data
BIT_CLR_WORD Bit clear of WORD data
BIT_CLR_DWORD Bit clear of DWORD data

Format
(EN)
BIT
SET
(type)
pa (ENO)
cs
LEN
??????? IN
.cn

??????? BIT

BIT_CLR

Parameters
w

Parameter Data type Meaning


EN BOOL Execution of operation
w

LEN Constant The number of data in the


string. 1 ≤ LEN ≤ 256
IN BYTE, WORD, DWORD Input data
w

BIT INT Set (clear) bit


ENO BOOL Normal end flag
://

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
tp

EN o o o o o
IN o o Note o
ht

BIT o o o o o o
ENO o o o Note o

NOTE
Only %SK can be specified.

- 97 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00001 is set to ON the twelfth bit of the bit string
of %R00001 is cleared to 0. When the bit string of %R00001 is
0011100011011011, the twelfth bit is cleared to 0 and
0011000011011011 is output.

/
om
% I00001 % Q00001
BIT
CLR
W ORD
1

% R00001 IN

s.c
CONST BIT
+000012

re
pa
cs
.cn
w
w
w
://
tp
ht

- 98 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.5.8 BIT_POS_(type)

Function
When EN is set to ON and is receiving the power flow, BIT_POS
searches the bit string of input parameter IN for bits that are set to 1,

/
then outputs the positions of those bits to output parameter POS.

om
When no bit can be found, 0 is output.
When BIT_POS finds a bit that has been set to 1, it sets Q to ON.

BIT_POS_(type) instructions

s.c
Name Explanation
BIT_POS_BYTE Bit position of BYTE data
BIT_POS_WORD Bit position of WORD data
BIT_POS_DWORD Bit position of DWORD data

re
Format
BIT
(EN) POS (ENO)

??????? IN
(type)
LEN
POS pa ???????
cs
.cn

Parameters
Parameter Data type Meaning
EN BOOL Execution
LEN Constant The number of data in the string.
1≤ LEN ≤256
w

IN BYTE, WORD, DWORD Input data


ENO BOOL Returns the value of EN
w

POS INT Position of first non-zero bit to be


detected
w

Memory Type
Memory
://

Flow %I* %Q* %M* %S* %R Constant Omissible


EN o o o o o
IN o o o o o o
tp

ENO o o Note o
POS o o o Note o
ht

NOTE
Only %SK can be specified.

- 99 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00001 is set to ON, the bit string of %R00001 is searched for
bits that are set to 1.
When the bit string of %R00001 is 0011100011011011, 1 is output
to %R00010 and %Q00002 is set to ON.

/
om
% I00001 % Q00001
BIT
POS
W ORD
1

% R00001 IN POS % R00010

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 100 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.5.9 BIT_SEQ

Function
The Bit Sequencer (BITSEQ) function performs a bit sequence shift
through a series of contiguous bits. The operation of BITSEQ depends

/
on the value of the reset input (R) and both the current value and

om
previous value of the enabling power flow input (EN):
The reset input (R) overrides the enabling power flow (EN) and
always resets the sequencer. When R is active, the current step number
is set to the value of the optional N operand. If the user did not specify
N, the step number is set to 1. All of the bits in the bit sequencer, ST,

s.c
are set to 0, except for the bit pointed to by the current step, which is
set to 1.
When EN is active and Reset is not active and the previous EN was
OFF, the bit pointed to by the current step number is cleared. The

re
current step number is incremented or decremented, based on the
direction (DIR) operand. Then the bit pointed to by the new step
number is set to 1.

pa
When the step number is being incremented and it goes outside the
range of (1 ≤ step number ≤ LEN operand), it is set back to 1.
When the step number is being decremented and it goes outside the
cs
range of (1≤ step number ≤ LEN operand), it is set to LEN.

Format
.cn

BIT
(EN) SEQ (ENO)
ADRS
LEN
??????? R
w

??????? DIR
w

??????? N
w

??????? ST
://

Parameters
Parameter Data type Meaning
EN BOOL Execution of operation
tp

ADRS one-dimensional WORD ADRS is the beginning address of a


array of 3 words three-word WORD array:
Word 1: current step number
ht

Word 2: length of sequence in bits


Word 3: control word, which tracks
the status of the last enabling power
flow and the status of the power flow
to the right.
LEN Constant The length. The number of bits in the
bit sequencer, ST, that BITSEQ will
Step Through.
1 ≤ LEN ≤ 256

- 101 -
4.LD INSTRUCTION GROUP B-63823EN/02

Parameter Data type Meaning


R BOOL Reset
DIR BOOL Direction of the bit sequencer
N INT Step number
ST BYTE The first byte of the bit sequencer

/
ENO BOOL Returns the value of EN

om
Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible

s.c
EN o o o o o
R o o o o o
DIR o o o o o
N o o o o o o

re
ST o o o o o o
ENO o o o Note o o

Example
NOTE
pa
Only %SK can be specified.
cs
The Bit Sequencer operates on register memory %R00001. Its static
data is stored in registers %R00010, %R00011, and %R00012.
When %I00002 is active, the sequencer is reset and the current step is
.cn

set to step number 3, as specified in N. The third bit of %R00001 is


set to one and the other seven bits are set to zero.
When %I00001 is active and %I00002 is not active, the bit for step
number 3 is cleared and the bit for step number 2 or 4 (depending on
w

whether DIR is energized) is set.

% I00001 % Q00001
w

BIT
SEQ
%R00010
% I00002 192
w

% I00003
DIR
://

3 N
tp

%R00001 ST
ht

- 102 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.5.10 MASK_COMP_(type)

Function
The Masked Compare (function compares the contents of two separate
bit strings. It provides the ability to mask selected bits.

/
Tip: Input string 1 might contain the states of outputs such as

om
solenoids or motor starters. Input string 2 might contain their input
state feedback, such as limit switches or contacts.
When the function receives power flow, it begins comparing the bits
in the first string with the corresponding bits in the second string.
Comparison continues until a miscompare is found or until the end of

s.c
the string is reached.
The BIT input stores the bit number where the next comparison
should start (a 0 indicates the first bit in the string). The BN output
stores the bit number where the last comparison occurred (where a 1

re
indicates the first bit in the string). Using the same reference for BIT
and BN causes the compare to start at the next bit position after a
miscompare; or, if all bits compared successfully upon the next

pa
invocation of the function block, the compare starts at the beginning.
Tip: If you want to start the next comparison at some other location in
the string, you can enter different references for BIT and BN. If the
cs
value of BIT is a location that is beyond the end of the string, BIT is
reset to 0 before starting the next comparison.
The function passes power flow whenever it receives power. The other
outputs of the function depend on the state of the corresponding mask
.cn

bit.
If all corresponding bits in strings IN1 and IN2 match, the function
sets the miscompare output MC to 0 and BN to the highest bit number
in the input strings. The comparison then stops. On the next
w

invocation of a Masked Compare Word, it is reset to 0.


If a Miscompare is found, i.e., when the two bits currently being
compared are not the same, the function checks the correspondingly
w

numbered bit in string M (the mask). If the mask bit is a 1, the


comparison continues until it reaches another miscompare or the end
of the input strings.
w

If a miscompare is detected and the corresponding mask bit is a 0, the


function does the following:
://

1) Sets the corresponding mask bit in M to 1.


2) Sets the miscompare (MC) output to 1.
3) Updates the output bit string Q to match the new content of mask
string M
tp

4) Sets the bit number output (BN) to the number of the


miscompared bit.
5) Stops the comparison.
ht

MASK_COMP_(type) instructions
Name Explanation
MASK_COMP_BYTE Compare the bits in two BYTE data
MASK_COMP_WORD Compare the bits in two WORD data
MASK_COMP_DWORD Compare the bits in two DWORD data

- 103 -
4.LD INSTRUCTION GROUP B-63823EN/02

Format
MASK
(EN) CMP
(type)
LEN
??????? IN1 MC ???????

/
om
??????? IN2 Q ???????

??????? M BN ???????

??????? BIT

s.c
Parameters
Parameter Data type Meaning

re
EN BOOL Execution of operation.
LEN Constant The number of data in either
compared string.

IN1
pa
BYTE, WORD, DWORD
1 ≤ LEN ≤ 8192(BYTE)
1 ≤ LEN ≤ 4096(WORD)
1 ≤ LEN ≤ 2048(DWORD)
Input data 1.
cs
IN2 BYTE, WORD, DWORD Input data 2.
M BYTE, WORD, DWORD The bit string mask.
BIT UINT The bit number where the next
.cn

comparison should start.


Q BYTE, WORD, DWORD The output copy of the compare
mask bit string.
BN UINT The number of the bit where
w

the latest miscompare


occurred.
MC BOOL Miscompare output.
w

Memory Type
w

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
://

IN1 o o o o o
IN2 o o o o o
M o o o o o
tp

BIT o o o o o
Q o o o
BN o o o
ht

MC o o o Note o

NOTE
Only %SK can be specified.

- 104 -
B-63823EN/02 4.LD INSTRUCTION GROUP

Example
After first scan, the Masked Compare Word function
executes. %M00001 through %M00016 is compared with %M00017
through %M00032. %M00033 through %M00048 contains the mask
value. The value in %R00001 determines the bit position in the two

/
input strings where the comparison starts.

om
% I00001
MASK
COMP
W ORD
16 % Q00001
% M00001 IN1 MC

s.c
% M00017 IN2 Q % M00033

% M00033 M BN % R00001

re
%R00001 BIT

references are:
(IN1) - %M00001 =
pa
Before the function block is executed, the contents of the above
cs
0 1 1 0 1 1 0 0 0 1 1 0 1 1 0 0
(IN2) - %M00017 =
0 1 1 0 1 1 0 1 0 1 1 0 1 1 1 1
(M/Q) - %M00033 =
.cn

0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1
(BIT/BN) - %R00001 = 0
(MC) - %Q00001 = OFF
w

The contents of these references after the function block is executed


are as follows:
(IN1) - %M00001 =
w

0 1 1 0 1 1 0 0 0 1 1 0 1 1 0 0
(IN2) - %M00017 =
0 1 1 0 1 1 0 1 0 1 1 0 1 1 1 1
w

(M/Q) - %M00033 =
0 0 0 0 0 0 0 1 0 0 0 0 1 1 1 1
(BIT/BN) - %R00001 = 9
://

(MC) - %Q00001 = ON
tp
ht

- 105 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.6 DATA MOVE


Data transmission functions
Controlled
Instruction Function Parameter Data type

/
I/O

om
MOVE_(type) Data IN, Q ANY EN, ENO
movement
SWAP_(type) Swap IN, Q WORD, DWORD EN, ENO
BLK_CLR_(type) Block Clear IN BYTE, WORD, DWORD EN, ENO
ANY_INT

s.c
SHFR_(type) Shift Register LEN, IN, ST, LEN = The number of data EN, ENO, R
Q IN/ST/Q = ANY_BIT

re
pa
cs
.cn
w
w
w
://
tp
ht

- 106 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.6.1 MOVE_(type)

Function
When EN is set to ON and is receiving the power flow, MOVE copies
the data in input parameter IN to output parameter Q.

/
MOVE_(type) instructions

om
Name Explanation
MOVE_BOOL Data movement of BOOL data.
MOVE_BYTE Data movement of BYTE data
MOVE_WORD Data movement of WORD data

s.c
MOVE_DWORD Data movement of DWORD data
MOVE_SINT Data movement of SINT data
MOVE_USINT Data movement of USINT data
MOVE_INT Data movement of INT data

re
MOVE_UINT Data movement of UINT data
MOVE_DINT Data movement of DINT data
MOVE_UDINT Data movement of UDINT data

Format
(EN)
MOVE
(type)
pa (ENO)
cs
LEN

??????? IN Q ???????
.cn

Parameters
Parameter Data type Meaning
EN BOOL Execution
LEN Constant The length of IN; the number of data to
w

move. If IN is a constant and Q is BOOL,


then 1 ≤ LEN ≤ 16; otherwise, 1 ≤ LEN ≤ 256
IN ANY Input data
w

ENO BOOL Returns the value of EN


Q ANY Destination address
w

Memory Type
://

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
IN o o o o o o
tp

ENO o o o Note o
Q o o Note o
ht

NOTE
Only %SK can be specified.

- 107 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00010 is set to ON, the value of %R00100 is copied
to %R00200.

% I00010 % Q00011
MOVE

/
W ORD
3

om
% R00100 IN Q % R00200

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 108 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.6.2 SWAP_(type)

Function
When EN is set to ON and is receiving the power flow, SWAP swaps
either WORD data in input parameter IN in BYTE units, or DWORD

/
data in WORD units, and outputs the result to output parameter Q.

om
SWAP_(type) instructions
Name Explanation
SWAP_WORD Swap of WORD data

s.c
SWAP_DWORD Swap of DWORD data

Format
SW AP
(EN) (type) (ENO)

re
LEN

??????? IN Q ???????

Parameters
Parameter
pa Data type Meaning
cs
EN BOOL Execution of logical operation
LEN Constant The number of data in the string.
1 ≤ LEN ≤ 256
.cn

IN WORD, DWORD Input data


ENO BOOL Returns the value of EN
Q WORD, DWORD Result of operation
w

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
w

EN o o o o o
IN o o o o o o
ENO o o o Note o
w

Q o o Note o
://

NOTE
Only %SK can be specified.
tp

Example
When %I00010 is set to ON, the data of %R00100 is swapped, and
the result is output to %R00200. When %R00100 is
ht

0011100011011011, WORD data 1101101100111000 that has been


swapped in BYTE units is output to %R00200.

%I00010 %Q00011
SW AP
W ORD
1

%R 00100 IN Q % R00200

- 109 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.6.3 BLK_CLR_(type)

Function
When the Block Clear (BLK_CLR) function receives power flow, it
fills the specified block of data with zeros, beginning at the reference

/
specified by IN. The function passes power to the right whenever

om
power is received.

BLK_CLR_(type) instructions
Name Explanation

s.c
BLK_CLR_BYTE Block clear of BYTE data
BLK_CLR_WORD Block clear of WORD data
BLK_CLR_DWORD Block clear of DWORD data
BLK_CLR_SINT Block clear of SINT data

re
BLK_CLR_USINT Block clear of USINT data
BLK_CLR_INT Block clear of INT data
BLK_CLR_UINT Block clear of UINT data

Format
BLK_CLR_DINT
BLK_CLR_UDINT
pa Block clear of DINT data
Block clear of UDINT data
cs
BLK_CLR
(EN) (type) (ENO)

LEN
.cn

??????? IN

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of logical operation


LEN Constant The number of data to be
cleared, starting at the IN
w

location. 1 ≤ LEN ≤ 256


IN BYTE,WORD, DWORD, Input data
w

ANY_INT
ENO BOOL Returns the value of EN
://

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
tp

EN o o o o o
IN o o o
ENO o o o Note o
ht

NOTE
Only %SK can be specified.

- 110 -
B-63823EN/02 4.LD INSTRUCTION GROUP

Example
At power-up, 32 words of %Q memory (512 points) beginning
at %Q00001 are filled with zeros.

% I00010 % Q00011
BLK

/
CLR
W ORD

om
32

% Q00001 IN

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 111 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.6.4 SHFR_(type)

Function
When the Shift Register function (SHFR_BIT, SHFR_BYTE,
SHFR_WORD or SHFR_DWORD) receives power and R does not,

/
the function shifts one or more data bits or data words from a

om
reference location into a specified area of memory. A contiguous
section of memory serves as a shift register. For example, one word
might be shifted into an area of memory with a specified length of five
words. As a result of this shift, another word of data would be shifted
out of the end of the memory area.

s.c
The reset input (R) takes precedence over the function enable input.
When the reset is active, all references beginning at the shift register
(ST) up to the length specified for the LEN operand, are filled with
zeros.

re
If the function receives power flow and R is not active, each bit or
word of the shift register is moved to the next highest reference. The
last element in the shift register is shifted into Q. The highest

element starting at ST. pa


reference of the shift register element of IN is shifted into the vacated

The function passes power to the right whenever the function receives
cs
power flow and the R operand does not. ON.

SHFR_(type) instructions
.cn

Name Explanation
CHFR_BIT Shift Register (BIT data)
CHFR_BYTE Shift Register (BYTE data)
CHFR_WORD Shift Register (WORD data)
CHFR_DWORD Shift Register (DWORD data)
w

Format
w

SHFR
(EN) (type) (ENO)

LEN
w

??????? R Q ???????

??????? IN
://

??????? ST
tp
ht

- 112 -
B-63823EN/02 4.LD INSTRUCTION GROUP

Parameters
Parameter Data type Meaning
EN BOOL Execution of operation
LEN Constant Length; the number of data in the shift register.
1 ≤ LEN ≤ 256

/
R BOOL Reset

om
IN ANY_BIT The value to be shifted into the first data of the
shift register
ST ANY_BIT Shift Register
Q ANY_BIT The data shifted out of the shift register
ENO BOOL Returns the value of EN

s.c
Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible

re
EN o o o o o
R o o o o o
IN o o o o o
ST
Q
ENO o
pao o
o
o
o
o
o
o
o
Note
o
o
o o
cs
NOTE
Only %SK can be specified.
.cn

Example
SHFR_BIT operates on Bool memory locations %M00001
through %M00100. When the reset reference CLEAR is active, the
Shift Register function fills %M00001 through %M00100 with zeros.
w

When NXT_CYC is active and CLEAR is not, SHFR_BIT shifts the


data in %M00001 to %M00100 down by one bit. The bit in %Q00033
w

is shifted into %M00001 while the bit shifted out of %M0100 is


written to %M00200.
w

NXT_CYC %Q00001
SHFR
BIT

100
://

CLEAR
R Q % M00200

% Q00033 IN
tp

% M00001 ST
ht

- 113 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.7 DATA TABLE FUNCTIONS

Data table functions


Controlled

/
Instruction Function Parameter Data type
I/O

om
ARRAY_MOVE_(type) Movement of data array SR, SNX, SR/DS = ANY_BIT, EN, ENO
DNX, N, DS ANY_INT
SNX/DNX = INT
N = INT
SEARCH_EQ_(type) Search for equal to AR, INX, AR/IN = ANY_BIT, EN, FD

s.c
(= IN) IN, ONX ANY_INT
INX/ONX = WORD
SEARCH_NE_(type) Search for not equal to AR, INX, AR/IN = ANY_BIT, EN, FD
(≠ IN) IN, ONX ANY_INT

re
INX/ONX = WORD
SEARCH_GT_(type) Search for greater than AR, INX, AR/IN = ANY_BIT, EN, FD
(> IN) IN, ONX ANY_INT

or equal to
(≥ IN)
pa
SEARCH_GE_(type) Search for greater than AR, INX,
IN, ONX
INX/ONX = WORD
AR/IN = ANY_BIT,
ANY_INT
INX/ONX = WORD
EN, FD
cs
SEARCH_LT_(type) Search for less than AR, INX, AR/IN = ANY_BIT, EN, FD
(< IN) IN, ONX ANY_INT
INX/ONX = WORD
.cn

SEARCH_LE_(type) Search for less than or AR, INX, AR/IN = ANY_BIT, EN, FD
equal to IN, ONX ANY_INT
(≤ IN) INX/ONX = WORD
w
w
w
://
tp
ht

- 114 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.7.1 ARRAY_MOVE_(type)

Function
When EN is set to ON and is receiving the power flow,
ARRAY_MOVE moves, from the location specified with parameters

/
SR and SNX (SR + SNX - 1) to the location specified with parameters

om
DS and DNX (DS + DNX - 1), the number of array elements specified
with input parameter N.

ARRAY_MOVE_(type) instructions

s.c
Name Explanation
ARRAY_MOVE_BOOL Movement of BOOL data array
ARRAY_MOVE_BYTE Movement of BYTE data array
ARRAY_MOVE_WORD Movement of WORD data array

re
ARRAY_MOVE_DWORD Movement of DWORD data array
ARRAY_MOVE_SINT Movement of SINT data array
ARRAY_MOVE_USINT Movement of USINT data array
ARRAY_MOVE_INT
ARRAY_MOVE_UINT
ARRAY_MOVE_DINT
ARRAY_MOVE_UDINT
pa Movement of INT data array
Movement of UINT data array
Movement of DINT data array
Movement of UDINT data array
cs
Format
ARRAY
(EN) (ENO)
.cn

MOVE
(type)
LEN
??????? SR DS ???????

??????? SNX
w

??????? DNX
w

??????? N
w

Parameters
Parameter Data type Meaning
EN BOOL Execution of transmission
://

LEN constant The length of each memory block


(source and destination); the number
of registers in each memory block. 1 ≤
tp

LEN ≤ 32767.
SR ANY_BIT Head address of array at origin
ANY_INT
ht

SNX INT Index of array at origin


DNX INT Index of array at destination
N INT Number of items of data
ENO BOOL Normal end flag
DS ANY_BIT Head address of destination array
ANY_INT

- 115 -
4.LD INSTRUCTION GROUP B-63823EN/02

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
SR o o o o o

/
SNX o o o o o o

om
DNX o o o o o o
N o o o o o o
ENO o o o Note o
DS o o Note o

s.c
NOTE
Only %SK can be specified.

Example

re
When %I00001 is set to ON, the array elements between %R00003
and %R00009 are moved to between %R00104 and %R00110.
% I00001

%R00001
pa SR
ARRAY
MOVE
W ORD
7

DS %R00100
% Q00001
cs
CONST SNX

00003
.cn

CONST DNX

00005

CONST N

00007
w
w
w
://
tp
ht

- 116 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.7.2 SEARCH_EQ_(type)/SEARCH_NE_(type)/SEARCH_GT_(type)/
SEARCH_GE_(type)/SEARCH_LT_(type)/SEARCH_LE_(type)

Function

/
When EN is set to ON and is receiving the power flow,

om
SRCH_EQ/SRCH_NE/SRCH_GT/SRCH_GE/SRCH_LT/SRCH_LE
search for, from the start position specified with input parameters AR
and INX (AR + INX), those array elements conforming to the data and
conditions of input parameter IN (= IN/ ≠ IN/ > IN/ ≥ IN/ < IN/ ≤ IN).
Those array elements that satisfy the conditions are output, output

s.c
parameter FD is set to ON, and the indexes of those array elements are
output to output parameter ONX. When there are no array elements
that satisfy the conditions, FD is set to OFF, and 0 is output to ONX.

re
SEARCH_xx_(type) instructions
Name Explanation
SEARCH_EQ_BOOL Search for equal to BOOL data array
SEARCH_EQ_BYTE
SEARCH_EQ_WORD
SEARCH_EQ_DWORD
SEARCH_EQ_SINT
pa Search for equal to BYTE data array
Search for equal to WORD data array
Search for equal to DWORD data array
Search for equal to SINT data array
cs
SEARCH_EQ_USINT Search for equal to USINT data array
SEARCH_EQ_INT Search for equal to INT data array
SEARCH_EQ_UINT Search for equal to UINT data array
.cn

SEARCH_EQ_DINT Search for equal to DINT data array


SEARCH_EQ_UDINT Search for equal to UDINT data array
SEARCH_NE_BOOL Search for not equal to BOOL data array
SEARCH_NE_BYTE Search for not equal to BYTE data array
SEARCH_NE_WORD Search for not equal to WORD data array
w

SEARCH_NE_DWORD Search for not equal to DWORD data array


SEARCH_NE_SINT Search for not equal to SINT data array
w

SEARCH_NE_USINT Search for not equal to USINT data array


SEARCH_NE_INT Search for not equal to INT data array
SEARCH_NE_UINT Search for not equal to UINT data array
w

SEARCH_NE_DINT Search for not equal to DINT data array


SEARCH_NE_UDINT Search for not equal to UDINT data array
SEARCH_GT_BYTE Search for greater than BYTE data array
://

SEARCH_GT_WORD Search for greater than WORD data array


SEARCH_GT_DWORD Search for greater than DWORD data array
SEARCH_GT_SINT Search for greater than SINT data array
tp

SEARCH_GT_USINT Search for greater than USINT data array


SEARCH_GT_INT Search for greater than INT data array
SEARCH_GT_UINT Search for greater than UINT data array
ht

SEARCH_GT_DINT Search for greater than DINT data array


SEARCH_GT_UDINT Search for greater than UDINT data array
SEARCH_GE_BYTE Search for greater than or equal to BYTE data array
SEARCH_GE_WORD Search for greater than or equal to WORD data array
SEARCH_GE_DWORD Search for greater than or equal to DWORD data array
SEARCH_GE_SINT Search for greater than or equal to SINT data array
SEARCH_GE_USINT Search for greater than or equal to USINT data array
SEARCH_GE_INT Search for greater than or equal to INT data array

- 117 -
4.LD INSTRUCTION GROUP B-63823EN/02

Name Explanation
SEARCH_GE_UINT Search for greater than or equal to UINT data array
SEARCH_GE_DINT Search for greater than or equal to DINT data array
SEARCH_GE_UDINT Search for greater than or equal to UDINT data array
SEARCH_LT_BYTE Search for less than BYTE data array

/
SEARCH_LT_WORD Search for less than WORD data array

om
SEARCH_LT_DWORD Search for less than DWORD data array
SEARCH_LT_SINT Search for less than SINT data array
SEARCH_LT_USINT Search for less than USINT data array
SEARCH_LT_INT Search for less than INT data array
SEARCH_LT_UINT Search for less than UINT data array

s.c
SEARCH_LT_DINT Search for less than DINT data array
SEARCH_LT_UDINT Search for less than UDINT data array
SEARCH_LE_BYTE Search for less than or equal to BYTE data array
SEARCH_LE_WORD Search for less than or equal to WORD data array

re
SEARCH_LE_DWORD Search for less than or equal to DWORD data array
SEARCH_LE_SINT Search for less than or equal to SINT data array
SEARCH_LE_USINT Search for less than or equal to USINT data array
SEARCH_LE_INT
SEARCH_LE_UINT
SEARCH_LE_DINT
SEARCH_LE_UDINT
pa Search for less than or equal to INT data array
Search for less than or equal to UINT data array
Search for less than or equal to DINT data array
Search for less than or equal to UDINT data array
cs
Format
SRCH
.cn

(EN) EQ
(type)
LEN
??????? AR FD ???????

??????? INX ONX ???????


w

??????? IN
w

SRCH_NE
SRCH_GT
SRCH_GE
SRCH_LT
w

SRCH_LE

Parameters
://

Parameter Data type Meaning


EN BOOL Execution of search
tp

LEN Constant The number of registers starting at AR that


makes up the memory block to search.
1 ≤ LEN ≤ 32767.
ht

AR ANY_BIT Head address of array


ANY_INT
INX WORD Search start index
IN ANY_BIT Search value
ANY_INT
FD BOOL Whether any value satisfies the condition
ONX WORD Index of value that satisfies the condition

- 118 -
B-63823EN/02 4.LD INSTRUCTION GROUP

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
AR o o o o o

/
INX o o o o o o

om
IN o o o o o o
FD o o o Note o o
ONX o o Note o

NOTE

s.c
Only %SK can be specified.

Example
When %I00001 is set to ON, and the elements of the array

re
between %R00001 and %R00016 are 100, 20, 0, 5, 90, 200, 0, 79, 102,
80, 24, 34, 987, 8, 0, and 500, setting the initial value of %R00100 to
5 starts a search, starting from %R00006, for those array elements
whose value is 0.
pa
In the following example, the first scan reveals %R00007, %Q00100
is set to ON, and %R00100 is set to 7. In the second scan, the search
cs
starts from %R00008, %R00015 is revealed, %Q00100 is set to ON,
and %R00100 is set to 15. In the next scan, the search starts
from %R00016 but, because the value of %R00016 is other than
.cn

0, %Q00100 is left set to OFF, and %R00100 is set to 0. In the next


scan, the search starts from the head of the array, namely %R00001.

% I00001
SRCH
EQ
w

W ORD
16 % Q00100
% R00001 AR FD
w

% R00100 INX ONX % R00100

00005
w

CONST IN
00000
://
tp
ht

- 119 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.8 DATA TYPE CONVERSION

Data type conversion functions


Controlled

/
Instruction Function Parameter Data type
I/O

om
(type)_TO_BCDx Conversion from IN, Q IN = ANY_INT EN, ENO
binary to BCD data Q = WORD,
DWORD
BCDx_TO_(type) Conversion from IN, Q IN = WORD, EN, ENO
BCD to binary data DWORD

s.c
Q = ANY_INT
(type)_TO_SINT Conversion to IN, Q IN = USINT, INT, EN, ENO
SINT data UINT, DINT, UDINT
Q = SINT

re
(type)_TO_USINT Conversion to IN, Q IN = SINT, INT, EN, ENO
USINT data UINT, DINT, UDINT
Q = USINT
(type)_TO_INT

(type)_TO_UINT
data
pa
Conversion to INT IN, Q

Conversion to IN, Q
IN = SINT, USINT,
UINT, DINT, UDINT
Q = INT
IN = SINT, USINT,
EN, ENO

EN, ENO
cs
UINT data INT, DINT , UDINT
Q = UINT
(type)_TO_DINT Conversion to IN, Q IN = SINT, USINT, EN, ENO
.cn

DINT data INT, UINT, UDINT


Q = DINT
(type)_TO_UDINT Conversion to IN, Q IN = SINT, USINT, EN, ENO
UDINT data INT, UINT, DINT
Q = DINT
w
w
w
://
tp
ht

- 120 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.8.1 (type)_TO_BCDx (x = 2, 4, 8)

Function
When EN is set to ON and is receiving the power flow,
(type)_TO_BCDx converts the integer data of input parameter IN to

/
2-, 4- or 8- digit BCD, then outputs the result to output parameter Q.

om
When a large value that can not be expressed in BCD (a value greater
than 99 for a 2-digit BCD, greater than 9999 for a 4-digit BCD, and
greater than 99999999 for an 8-digit BCD) is input to IN, the
maximum value that can be expressed in BCD (99 for a 2-digit BCD,
9999 for a 4-digit BCD, and 99999999 for an 8-digit BCD) is output

s.c
to Q. In such a case, ENO is not output. Also, if a negative value is
input to IN, 0 is output to Q. Again, in such a case ENO is not
output.

re
(type)_TO_BCDx instructions
Name Explanation
SINT_TO_BCD2
USINT_TO_BCD2
INT_TO_BCD4
UINT_TO_BCD4
pa Converts from SINT to 2-digit BCD
Converts from USINT to 2-digit BCD
Converts from INT to 4-digit BCD
Converts from UINT to 4-digit BCD
cs
DINT_TO_BCD8 Converts from DINT to 8-digit BCD
UDINT_TO_BCD8 Converts from UDINT to 8-digit BCD
.cn

Format
(type)
(EN) TO (ENO)
BCDx

??????? IN Q ???????
w

Parameters
w

Parameter Data type Meaning


EN BOOL Execution of conversion
w

IN ANY_INT Input data


ENO BOOL Normal end flag
Q WORD, DWORD Result of conversion
://

Memory Type
tp

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
ht

IN o o o o o o
ENO o o o Note o
Q o o Note o

NOTE
Only %SK can be specified.

- 121 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00010 is set to ON, the INT type data of %R00100 is
converted to 4-digit BCD data and output to %R00200.

% I00010 % Q00011
INT

/
TO
BCD4

om
% R00100 IN Q % R00200

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 122 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.8.2 BCDx_TO_(type) (x = 2, 4, 8)

Function
When EN is set to ON and is receiving the power flow,
BCDx_TO_(type) converts the 2-, 4-, or 8-digit data input to input

/
parameter IN to integer data and outputs the result to output parameter

om
Q.
If an invalid BCD value is input to IN, the minimum valid value for
that data type (-128 for SINT, 0 for USINT) is output to Q. In this
case, ENO is not output.

s.c
BCDx_TO_(type) instructions
Name Explanation
BCD2_TO_SINT Converts from 2-digit BCD to SINT

re
BCD2_TO_USINT Converts from 2-digit BCD to USINT
BCD4_TO_INT Converts from 4-digit BCD to INT
BCD4_TO_UINT Converts from 4-digit BCD to UINT

Format
BCD8_TO_DINT
BCD8_TO_UDINT
pa Converts from 8-digit BCD to DINT
Converts from 8-digit BCD to UDINT
cs
BCDx
(EN) TO (ENO)
(type)
.cn

??????? IN Q ???????

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of conversion


IN WORD, DWORD Input data
ENO BOOL Normal end flag
w

Q ANY_INT Result of conversion

Memory Type
w

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
://

EN o o o o o
IN o o o o o o
ENO o o o Note o
tp

Q o o Note o

NOTE
ht

Only %SK can be specified.

- 123 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00010 is set to ON, the 4-digit BCD data of %R00100 is
converted to INT type data and output to %R00200.

%I00010 %Q00011
BCD 4

/
TO

om
INT

%R 00100 IN Q % R00200

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 124 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.8.3 (type)_TO_SINT

Function
When EN is set to ON and is receiving the power flow,
(type)_TO_SINT converts the data of input parameter IN to SINT data

/
and outputs the result to output parameter Q.

om
If the conversion results in an overflow, the maximum value for that
data type is output to Q. In such a case, ENO is not output.
Furthermore, if the conversion results in an underflow, the minimum
value for that type is output to Q. Again, in such a case, ENO is not
output.

s.c
(type)_TO_SINT instructions
Name Explanation

re
USINT_TO_SINT Converts from USINT to SINT
INT_TO_SINT Converts from INT to SINT
UINT_TO_SINT Converts from UINT to SINT

Format
DINT_TO_SINT
UDINT_TO_SINT
pa Converts from DINT to SINT
Converts from UDINT to SINT
cs
(type)
(EN) (ENO)
TO
SIN T
.cn

??????? IN Q ???????

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of conversion


IN USINT, INT, UINT, DINT, UDINT Input data
ENO BOOL Normal end flag
w

Q SINT Result of conversion

Memory Type
w

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
://

EN o o o o o
IN o o o o o o
ENO o o o Note o
tp

Q o o Note o

NOTE
ht

Only %SK can be specified.

- 125 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00010 is set to ON, the USINT data of %M00001 is
converted to SINT data and the result is output to %M00009.

%I00010 %Q00011
USINT

/
TO
SINT

om
%M00001 IN Q %M00009

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 126 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.8.4 (type)_TO_USINT

Function
When EN is set to ON and is receiving the power flow,
(type)_TO_USINT converts the data of input parameter IN to USINT

/
data and outputs the result to output parameter Q.

om
If the conversion results in an overflow, the maximum value for that
data type is output to Q. In such a case, ENO is not output.
Furthermore, if the conversion results in an underflow, the minimum
value for that type is output to Q. Again, in such a case, ENO is not
output.

s.c
(type)_TO_USINT instructions
Name Explanation

re
SINT_TO_USINT Converts from SINT to USINT
INT_TO_USINT Converts from INT to USINT
UINT_TO_USINT Converts from UINT to USINT

Format
DINT_TO_USINT
UDINT_TO_USINT
pa Converts from DINT to USINT
Converts from UDINT to USINT
cs
(type)
(EN) (ENO)
TO
USINT
.cn

??????? IN Q ???????

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of conversion


IN SINT, INT, UINT, DINT, Input data
UDINT
w

ENO BOOL Normal end flag


Q USINT Result of conversion
w

Memory Type
Memory
://

Flow %I* %Q* %M* %S* %R Constant Omissible


EN o o o o o
IN o o o o o o
tp

ENO o o o Note o
Q o o Note o
ht

NOTE
Only %SK can be specified.

- 127 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00010 is set to ON, the SINT data of %M00001 is converted
to USINT data and the result is output to %M00009.

%I00010 %Q00011
USINT

/
TO
USINT

om
%M00001 IN Q %M00009

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 128 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.8.5 (type)_TO_INT

Function
When EN is set to ON and is receiving the power flow,
(type)_TO_INT converts the data of input parameter IN to INT data

/
and outputs the result to output parameter Q.

om
If the conversion results in an overflow, the maximum value for that
data type is output to Q. In such a case, ENO is not output.
Furthermore, if the conversion results in an underflow, the minimum
value for that type is output to Q. Again, in such a case, ENO is not
output.

s.c
(type)_TO_INT instructions
Name Explanation

re
SINT_TO_INT Converts from SINT to INT
USINT_TO_INT Converts from USINT to INT
UINT_TO_INT Converts from UINT to INT

Format
DINT_TO_INT
UDINT_TO_INT
pa Converts from DINT to INT
Converts from UDINT to INT
cs
(type)
(EN) TO (ENO)
INT
.cn

??????? IN Q ???????

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of conversion


IN SINT, USINT, UINT, DINT, UDINT Input data
ENO BOOL Normal end flag
w

Q INT Result of conversion

Memory Type
w

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
://

EN o o o o o
IN o o o o o o
ENO o o o Note o
tp

Q o o Note o

NOTE
ht

Only %SK can be specified.

- 129 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00010 is set to ON, the UINT data of %R00100 is converted
to INT data and the result is output to %R00200.

%I00010 %Q00011
UINT

/
TO
INT

om
%R 00100 IN Q % R00200

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 130 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.8.6 (type)_TO_UINT

Function
When EN is set to ON and is receiving the power flow,
(type)_TO_UINT converts the data of input parameter IN to UINT

/
data and outputs the result to output parameter Q.

om
If the conversion results in an overflow, the maximum value for that
data type is output to Q. In such a case, ENO is not output.
Furthermore, if the conversion results in an underflow, the minimum
value for that type is output to Q. Again, in such a case, ENO is not
output.

s.c
(type)_TO_UINT instructions
Name Explanation

re
SINT_TO_UINT Converts from SINT to UINT
USINT_TO_UINT Converts from USINT to UINT
INT_TO_UINT Converts from INT to UINT

Format
DINT_TO_UINT
UDINT_TO_UINT
pa Converts from DINT to UINT
Converts from UDINT to UINT
cs
(type)
(EN) TO (ENO)
UINT
.cn

??????? IN Q ???????

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of conversion


IN SINT, USINT, INT, DINT, UDINT Input data
w

ENO BOOL Normal end flag


Q UINT Result of conversion
w

Memory Type
Memory
://

Flow %I* %Q* %M* %S* %R Constant Omissible


EN o o o o o
IN o o o o o o
tp

ENO o o o Note o
Q o o Note o
ht

NOTE
Only %SK can be specified.

- 131 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00010 is set to ON, the DINT data of %R00100 is converted
to UINT data and the result is output to %R00200.

% I00010 % Q00011
DINT

/
TO
UINT

om
% R00100 IN Q % R00200

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 132 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.8.7 (type)_TO_DINT

Function
When EN is set to ON and is receiving the power flow,
(type)_TO_DINT converts the data of input parameter IN to DINT

/
data and outputs the result to output parameter Q.

om
If the conversion results in an overflow, the maximum value for that
data type is output to Q. In such a case, ENO is not output.
Furthermore, if the conversion results in an underflow, the minimum
value for that type is output to Q. Again, in such a case, ENO is not
output.

s.c
(type)_TO_DINT instructions
Name Explanation

re
SINT_TO_DINT Converts from SINT to DINT
USINT_TO_DINT Converts from USINT to DINT
INT_TO_DINT Converts from INT to DINT

Format
UINT_TO_DINT
UDINT_TO_DINT
pa Converts from UINT to DINT
Converts from UDINT to DINT
cs
(type)
(EN) TO (ENO)
DINT
.cn

??????? IN Q ???????

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of conversion


IN SINT, USINT, INT, UINT, Input data
UDINT
w

ENO BOOL Normal end flag


Q DINT Result of conversion
w

Memory Type
Memory
://

Flow %I* %Q* %M* %S* %R Constant Omissible


EN o o o o o
IN o o o o o o
tp

ENO o o o Note o
Q o o Note o
ht

NOTE
Only %SK can be specified.

- 133 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00010 is set to ON, the INT data of %R00100 is converted to
DINT data and the result is output to %R00200.

% I00010 % Q00011
INT

/
TO
DINT

om
% R00100 IN Q % R00200

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 134 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.8.8 (type)_TO_UDINT

Function
When EN is set to ON and is receiving the power flow,
(type)_TO_UDINT converts the data of input parameter IN to UDINT

/
data and outputs the result to output parameter Q.

om
If the conversion results in an overflow, the maximum value for that
data type is output to Q. In such a case, ENO is not output.
Furthermore, if the conversion results in an underflow, the minimum
value for that type is output to Q. Again, in such a case, ENO is not
output.

s.c
(type)_TO_UDINT instructions
Name Explanation

re
SINT_TO_UDINT Converts from SINT to UDINT
USINT_TO_UDINT Converts from USINT to UDINT
INT_TO_UDINT Converts from INT to UDINT

Format
UINT_TO_UDINT
DINT_TO_UDINT
pa Converts from UINT to UDINT
Converts from DINT to UDINT
cs
(type)
(EN) (ENO)
TO
U DINT
.cn

??????? IN Q ???????

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of conversion


IN SINT, USINT, INT, UINT, Input data
DINT
w

ENO BOOL Normal end flag


Q UDINT Result of conversion
w

Memory Type
Memory
://

Flow %I* %Q* %M* %S* %R Constant Omissible


EN o o o o o
IN o o o o o o
tp

ENO o o o Note o
Q o o Note o
ht

NOTE
Only %SK can be specified.

- 135 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00010 is set to ON, the INT data of %R00100 is converted to
UDINT data and the result is output to %R00200.

%I00010 %Q00011
INT

/
TO

om
UDINT

%R 00100 IN Q % R00200

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 136 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.9 PROGRAM FLOW


Program Flow
Instruction Function

/
CALL Call IL or LD block

om
END Ends execution unconditionally
MCR Master control(Non-nested)
ENDMCR Ends master control(Non-nested)
MCRN Master control(Nested)
ENDMCRN Ends master control(Nested)

s.c
JUMPN Jump
LABELN Label of jump destination
COMMENT Comment

re
pa
cs
.cn
w
w
w
://
tp
ht

- 137 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.9.1 CALL

Function

When the CALL function receives power flow, it causes the scan to go

/
immediately to the designated subroutine IL block or LD block and

om
execute it. After the subroutine block execution is complete, control
returns to the point in the logic immediately following the CALL
instruction.
Format

s.c
name
CALL
(EN) (ENO)

re
Parameters
Parameter Data type Meaning
name - Name of IL block or LD block

Memory Type
EN
ENO pa BOOL
BOOL
Execution of CALL
Normal end flag
cs
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
.cn

EN o o o o o o
ENO o o o Note o

NOTE
Only %SK can be specified.
w

4.9.2
w

END
w

Function
Unconditionally ends the execution of the sequence program for each
level. For each level, the program logic subsequent to the END
://

instruction is not executed. After the execution of an END


instruction, execution switches to the head address of the program for
each label.
tp

Format
END
ht

Parameters
None

- 138 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.9.3 MCR/ENDMCR/MCRN/ENDMCRN

Function
When EN is set to ON and is receiving the power flow, MCR(N)
executes all the rungs up to the corresponding ENDMCR(N) without

/
applying power to the coil. ENDMCR(N) must be described after the

om
corresponding MCR(N). Furthermore, within the same rung, nothing
can be described either before or after ENDMCR(N).
MCR is Non-nested form.
MCRN is Nested form.

s.c
Format
name name
(EN) (EN)

re
MCR MCRN

pa name

ENDMCR
name

ENDMCRN
cs
Parameters
Parameter Data type Meaning
.cn

EN BOOL Execution of master control


name - Name

Memory Type
w

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
w

Example
w

When %I00010 is set to ON, regardless of the ON/OFF state


of %I00001 and %I00002, a negative power flow is established (that
is, no power flows), and %Q00001 and %Q00002 are both set to OFF.
://

% I00010 LBL1

MC R
tp

% I00001 %Q00001
ht

%I00002 %Q00002

LBL1

ENDMCR

- 139 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.9.4 JUMPN

Function
When EN is set to ON and is receiving the power flow, JUMPN
causes processing to jump to the corresponding LABELN. All

/
intervening processing is skipped.

om
All of the coils between the JUMPN and the corresponding LABELN
maintain their original state.
LABELN is not necessarily be described after the corresponding
JUMPN. Furthermore, within the same rung, nothing can be described
either before or after LABELN.

s.c
Format
(EN) label
JUMPN

re
Parameters
Parameter
EN
label
pa
Data type
BOOL
-
Meaning
Execution of jump
Label
cs
Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
.cn

EN o o o o o
w
w
w
://
tp
ht

- 140 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.9.5 LABELN

Function
Indicates the destination of a JUMPN instruction.

/
Format

om
Parameters

s.c
Parameter Data type Meaning
label - Label

Example

re
When %I00001 is set to ON, the processing up to LBL2 is skipped.
(The power flow goes directly from %I00001 to LBL2.)

% I00001
pa LBL2

JUMPN
cs
%I00002 %Q00002
.cn

LBL2

4.9.6 COMMENT
w

Function
Enables a comment to be inserted into a program.
w

Each comment occupies one rung.

Format
w
://

Parameters
tp

Parameter Data type Meaning


comment - comment
ht

- 141 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.10 PMC OPERATIONS

PMC operation instructions


Instruction Function Parameter Data type Controlled I/O

/
PMC_ADD_BCDx Addition of BCD data IN1, IN2, Q BYTE, WORD, DWORD EN, ENO

om
PMC_SUB_BCDx Subtraction of BCD data IN1, IN2, Q BYTE, WORD, DWORD EN, ENO
PMC_MUL_BCDx Multiplication of BCD data IN1, IN2, Q BYTE, WORD, DWORD EN, ENO
PMC_DIV_BCDx Division of BCD data IN1, IN2, Q BYTE, WORD, DWORD EN, ENO
PMC_MOD_BCDx Remainder of BCD data IN1, IN2, Q BYTE, WORD, DWORD EN, ENO
R_TRIG Detection of rising edge -- -- EN, ENO, address

s.c
F_TRIG Detection of falling edge -- -- EN, ENO, address
PMC_DECODE_(type) Decode LEN, IN, BASE, Q IN/BASE = ANY_INT EN, ENO
LEN/Q = WORD
PMC_EVPAR_(type) Even parity check IN BYTE, WORD, DWORD EN, ENO, Q

re
PMC_ODPAR_(type) Odd parity check IN BYTE, WORD, DWORD EN, ENO, Q
PMC_WINDOW Read and write of CNC LEN, AR INT EN, Q, ERR
window data
PMC_EXIN

PMC_AXCTL
External data input

PMC axis control


pa
HEAD, CMD, DT

GRP, CMD, DT1,


HEAD = INT
CMD = WORD
DT = DWORD
GRP = INT
EN, Q, ERR

EN, R, Q, ERR
cs
DT2 CMD = WORD
DT1 = DINT
DT2 = DINT
.cn
w
w
w
://
tp
ht

- 142 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.10.1 PMC_ADD_BCDx/PMC_SUB_BCDx/PMC_MUL_BCDx/
PMC_DIV_BCDx (x = 2, 4, 8)

Function

/
When EN is set to ON and is receiving the power flow,

om
PMC_ADD_BCDx/PMC_SUB_BCDx/PMC_MUL_BCDx/PMC_DI
V_BCDx perform addition, subtraction, multiplication, and division
on the BCD data of input parameters IN1 and IN2, and output the
result to output parameter Q.
IN1, IN2, and Q must all be of the same data type.

s.c
If the operation produces an overflow, the maximum possible value
for that data type is set in the output reference. If invalid BCD data
is input to IN, 0 is output to Q. When the operation ends without an
overflow, ENO is set to ON.

re
Addition/subtraction/multiplication/division of BCD data
Name Explanation
PMC_ADD_BCD2
PMC_ADD_BCD4
PMC_ADD_BCD8
PMC_SUB_BCD2
pa Addition of 2-digit BCD data
Addition of 4-digit BCD data
Addition of 8-digit BCD data
Subtraction of 2-digit BCD data
cs
PMC_SUB_BCD4 Subtraction of 4-digit BCD data
PMC_SUB_BCD8 Subtraction of 8-digit BCD data
PMC_MUL_BCD2 Multiplication of 2-digit BCD data
.cn

PMC_MUL_BCD4 Multiplication of 4-digit BCD data


PMC_MUL_BCD8 Multiplication of 8-digit BCD data
PMC_DIV_BCD2 Division of 2-digit BCD data
PMC_DIV_BCD4 Division of 4-digit BCD data
PMC_DIV_BCD8 Division of 8-digit BCD data
w

Format
w

PMC
(EN) ADD (ENO)
BCDx
w

??????? IN1 Q ???????


://

??????? IN2

PMC_SUB_BCDx
PMC_MUL_BCDx
tp

PMC_DIV_BCDx
ht

- 143 -
4.LD INSTRUCTION GROUP B-63823EN/02

Parameters
Parameter Data type Meaning
EN BOOL Execution of operation
IN1 BYTE, WORD, Input data 1
DWORD

/
IN2 BYTE, WORD, Input data 2

om
DWORD
ENO BOOL Normal end flag (set to OFF upon an overflow)
Q BYTE, WORD, Result of operation
DWORD

s.c
Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o

re
IN1 o o o o o o
IN2 o o o o o o
ENO
Q

NOTE
o

pa o
o
o
o
Note
Note o
o
cs
Only %SK can be specified.

Example
.cn

When %I00001 is set to ON, the 2-digit BCD data in %R00001 is


added to that in %R00002, and the result is output to %R00010.
When %Q00001 is set to ON, it indicates that the operation ended
with no overflow.
w

% I00001 % Q00001
PMC
ADD
w

BCD2

% R00001 IN1 Q % R00010


w

% R00002 IN2
://
tp
ht

- 144 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.10.2 PMC_MOD_BCDx (x = 2, 4, 8)

Function
When EN is set to ON and is receiving the power flow,
PMC_MOD_BCDx divides the BCD data of input parameter IN1 by

/
that of IN2 (IN1 ÷ IN2) and outputs the remainder to output parameter

om
Q.
IN1, IN2, and Q must all be of the same data type.
If invalid BCD data is input to IN, 0 is output to Q. When the
operation ends with no overflow (such as that caused by division by
zero), ENO is set to ON.

s.c
Remainder of BCD data
Name Explanation

re
PMC_MOD_BCD2 Remainder of 2-digit BCD data
PMC_MOD_BCD4 Remainder of 4-digit BCD data
PMC_MOD_BCD8 Remainder of 8-digit BCD data

Format pa (EN)
PMC
MOD (ENO)
cs
BCDx

??????? IN1 Q ???????


.cn

??????? IN2

Parameters
w

Parameter Data type Meaning


EN BOOL Execution of operation
w

IN1 BYTE, WORD, Input data 1


DWORD
IN2 BYTE, WORD, Input data 2
w

DWORD
ENO BOOL Normal end flag (set to OFF upon an overflow)
Q BYTE, WORD, Result of operation
://

DWORD

Memory Type
tp

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
ht

EN o o o o o
IN1 o o o o o o
IN2 o o o o o o
ENO o o o Note o
Q o o Note o

NOTE
Only %SK can be specified.
- 145 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00001 is set to ON, the 4-digit BCD data in %R00001, IN1,
is divided by that in %R00002 (IN2) (IN1 ÷ IN2), and the remainder
is output to %R00010.

/
When %Q00001 is set to ON, it indicates that the operation ended

om
without an overflow.

% I00001 % Q00001
PMC
MOD
BCD4

s.c
% R00001 IN1 Q % R00010

% R00002 IN2

re
pa
cs
.cn
w
w
w
://
tp
ht

- 146 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.10.3 R_TRIG/F_TRIG

Function
When EN is rising (going from OFF to ON) or falling (going from ON
to OFF), R_TRIG/F_TRIG sets ENO to ON for one sweep only.

/
om
Format
R TRIG
(EN) (ENO)

ADRS

s.c
F TRIG

Parameters
Parameter Data type Meaning

re
ADRS BOOL Detection memory
EN BOOL Detection signal input
ENO BOOL Detection result output

Memory Type
pa
cs
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
ADRS o
EN o o o o o
.cn

ENO o o o Note o

NOTE
Only %SK can be specified.
w

Example
w

When %I00010 goes from OFF to ON, %Q00011 is set to ON for one
sweep only.
w

% I00010 % Q00011
R TRIG

% M00010
://
tp
ht

- 147 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.10.4 PMC_DECODE_(type)

Function
When EN is set to ON and is receiving the power flow,
PMC_DECODE extracts continuous 8 x n (depending on the array

/
size of output parameter Q) integer data from the integer data of input

om
parameter IN and that of BASE, decodes it, then sets the
corresponding bit of output parameter Q.

PMC_DECODE_(type) instructions

s.c
Name Explanation
PMC_DECODE_SINT Decode of SINT data
PMC_DECODE_USINT Decode of USINT data
PMC_DECODE_INT Decode of INT data

re
PMC_DECODE_UINT Decode of UINT data
PMC_DECODE_DINT Decode of DINT data
PMC_DECODE_UDINT Decode of UDINT data

Format
pa
cs
PMC
(EN) DECODE (ENO)
(type)
LEN
??????? IN Q ???????
.cn

??????? BASE
w

Parameters
Parameter Data type Meaning
w

EN BOOL Execution of operation


LEN Constant Length of Q array(WORD)
IN ANY_INT Input data
w

BASE ANY_INT Decode indication number


ENO BOOL Returns the value of EN
Q WORD Result of decoding
://

Memory Type
tp

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
ht

IN o o o o o o
BASE o o o o o o
ENO o o o Note o
Q o o Note o

NOTE
Only %SK can be specified.

- 148 -
B-63823EN/02 4.LD INSTRUCTION GROUP

Example
When %I00001 is set to ON, the value of %R00001 is decoded into
sixteen (when the array size of output address %00010 is 1)
continuous integer values, starting from 6.
The result of decoding, 00000000 00100000, is output to %R00010.

/
om
% I00001 % Q00001
PMC
DECODE
INT
1
%R00001 IN Q %R00010
+000011

s.c
CONST BASE
+000006

re
pa
cs
.cn
w
w
w
://
tp
ht

- 149 -
4.LD INSTRUCTION GROUP B-63823EN/02

4.10.5 PMC_EVPAR_(type)/PMC_ODPAR_(type)

Function
When EN is set to ON and is receiving the power flow,
PMC_EVPAR/PMC_ODPAR check the even/odd parity of input

/
parameter IN and, when the result is true, set output parameter Q to

om
ON.

PMC_EVPAR_(type)/PMC_ODPAR_(type) instructions
Name Explanation
PMC_EVPAR_BYTE Check the even parity of BYTE data

s.c
PMC_EVPAR_WORD Check the even parity of WORD data
PMC_EVPAR_DWORD Check the even parity of DWORD data
PMC_ODPAR_BYTE Check the odd parity of BYTE data
PMC_ODPAR_WORD Check the odd parity of WORD data

re
PMC_ODPAR_DWORD Check the odd parity of DWORD data

Format

pa (EN)
PMC
EVPAR
(type)
cs
??????? IN Q ???????

PMC ODPAR
.cn

Parameters
Parameter Data type Meaning
EN BOOL Execution of parity check
IN BYTE, WORD, Input data
w

DWORD
Q BOOL Result of check
w

Memory Type
Memory
w

Flow %I* %Q* %M* %S* %R Constant Omissible


EN o o o o o
IN o o o o o o
://

Q o o o Note o

NOTE
tp

Only %SK can be specified.


ht

Example
When %I00010 is set to ON, the data of %R00100 is subjected to a
parity check. When the parity is even, %Q00100 is set to ON.

%I00010
PMC
EVPAR
W ORD
%Q00100
%R 00100 IN Q

- 150 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.10.6 PMC_WINDOW

Function
The CNC ←→ PMC window function is used to read and write the
CNC data.

/
om
Format
PMC
(EN) WINDOW

LEN

s.c
??????? AR Q ???????

ERR ???????

re
Parameters
Parameter
EN
LEN
AR
pa
Data type
BOOL
Constant
INT
WINDOW execution
Length of AR(INT) array
AR array
Meaning
cs
Top address

+0 Function code ...INT


.cn

+2 Completion code ...INT


+4 Data length ...INT
+6 Data number ...INT
+8 Data attribute ...INT
w

+10 Data ...ANY_NUM


(max. 32 bytes) (Values with each
function)
w

Q BOOL Completion flag


ERR BOOL Error output
w

For details of the data contents set in the AR array, refer to the
specified sections of the Appendix A ”WINDOW FUNCTIONS.”
://

Memory Type
tp

Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
ht

AR o o o
Q o o o Note o
ERR o o Note

NOTE
Only %SK can be specified.

- 151 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
When %I00001 is set to ON, NC parameter No. 1815 (N = +001815)
is read (FNC = +000017) for all axes (ATR = -000001).
The completion flag is output to %Q00002, while the error flag is
output to %Q00003.

/
om
%I00001
PMC
W INDOW

6 % Q00002
% R01000 AR Q

s.c
ERR % Q00003

%R01000 17
%R01001 -

re
%R01002 -
%R01003 1815
%R01004 -1

NOTE
%R01005
pa -
cs
%R address is 16-bit size (word type).
.cn
w
w
w
://
tp
ht

- 152 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.10.7 PMC_EXIN

Function
Issues commands for the CNC external data input function

/
om
Format
PMC
(EN) EXIN

??????? HEAD Q ???????

s.c
??????? CMD ERR ???????

re
??????? DT

Parameters
Parameter
EN
pa
Data type
BOOL Execution of EXIN
Meaning
cs
HEAD INT HEAD NO.
CMD WORD Command code
DT DWORD Command data
.cn

Q BOOL Completion flag


ERR BOOL Error output
For details of the data contents set in the parameters, refer to the
specified sections of the following manuals.
• FANUC PMC-MODEL PA1/PA3/SA1/SA2/SA3/SA5/SB/SB2/
w

SB3/SB4/SB5/SB6/SB7/SC/SC3/SC4/NB/NB2/NB6
Ladder Language Programming Manual (B-61863E)
5.45 EXIN (External Data Input)
w

• FANUC Series 16i/18i/21i/160i/180i/210i-MODEL B


Connection Manual (Functions) (B-63523EN-1)
15.2 External Data Input
w

Memory Type
Memory
://

Flow %I* %Q* %M* %S* %R Constant Omissible


EN o o o o o
HEAD o o o o o o
tp

CMD o o o o o
DT o o o o o
Q o o o Note o
ht

ERR o o Note

NOTE
Only %SK can be specified.

- 153 -
4.LD INSTRUCTION GROUP B-63823EN/02

Example
For a 16i-TB two-path control system, in the example shown below,
when %I00001 is set to ON, the shift amount for %R00020 is input
for the first axis of the second path, and the machine coordinates are
shifted.

/
The completion flag is output to %Q00100 and the error flag is output

om
to %Q00200.

% I00001
PMC
EXIN

% Q00100

s.c
CONST HEAD Q
00002

%R00010 CMD ERR % Q00200


+00176

re
%R00020 DT

pa
cs
.cn
w
w
w
://
tp
ht

- 154 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.10.8 PMC_AXCTL

Function
Specifies the PMC axis control function of the CNC.

/
om
Format
PMC
(EN) AXCTL

(R) R Q ???????

s.c
??????? GRP ERR ???????

re
??????? CMD

??????? DT1

pa ??????? DT2
cs
Parameters
Parameter Data type Meaning
.cn

EN BOOL Execution of AXCTL


R BOOL Reset
GRP INT DI/DO signal group
CMD WORD Axis control command
w

DT1 DINT Instruction data 1


DT2 DINT Instruction data 2
Q BOOL Completion flag
w

ERR BOOL Error output


For details of the data contents set in the parameters, refer to the
specified section of the following manual.
w

• FANUC PMC-MODEL PA1/PA3/SA1/SA2/SA3/SA5/SB/SB2/


SB3/SB4/SB5/SB6/SB7/SC/SC3/SC4/NB/NB2/NB6
Ladder Language Programming Manual (B-61863E)
://

5.72 AXCTL (PMC Axis Control Instruction)


tp
ht

- 155 -
4.LD INSTRUCTION GROUP B-63823EN/02

Memory Type
Memory
Flow %I* %Q* %M* %S* %R Constant Omissible
EN o o o o o
R o o o o o

/
GRP o o o o o o

om
CMD o o o o o o
DT1 o o o o o o
DT2 o o o o o o
Q o o Note
ERR o o Note

s.c
NOTE
Only %SK can be specified.

re
Example
When %I00001 is set to ON, the axis specified in the C group (GRP =
+000003) is subjected to high-speed positioning (CMD = 000000) at

with %R00013. pa
the speed specified with %R00011, over the distance specified

The completion flag is output to %Q00002 and the error code is


cs
output to %Q00003.
In addition, the system can be reset by setting %I00002 to ON.
.cn

%I00001
PMC
AXCTL

%I00002
R Q %Q00002
w

CONST GRP ERR %Q00003


+000003
w

% R00010 CMD
000000
w

% R00011 DT1

% R00013 DT2
://
tp
ht

- 156 -
B-63823EN/02 4.LD INSTRUCTION GROUP

4.11 NOTE ON LD PROGRAMMING

Some functional instructions may cause the ladder program to take a


long time to stop or make it unable to stop, if their EN or R condition

/
remains on for no apparent reason. If the ladder program does not stop,

om
all operations aimed at changing the ladder program will take longer
to end or will never end.
To avoid such problems, when you code a ladder program using
functional instructions, you need to design the ladder structure based
on a thorough understanding of the control conditions of the

s.c
individual instructions you use.
Listed below are typical cases in which the ladder program will not
stop.

• A low‐speed window function is used for a PMC_WINDOW

re
functional instruction, and its EN condition remains on.
• In a PMC_EXIN or PMC_AXCTL instruction, not only the EN

pa
condition but also the R condition remain on.

If the ladder program takes long to stop or does not stop for any of
these reasons, the following operations will be affected.
cs
1. Stopping the ladder program using a soft key on the screen.
2. Reading a new ladder program from a memory card or other
.cn

medium, by using the data input and output screen.


3. Updating the ladder program with changes made using the FANUC
LADDER-IIIC.

If any of the above phenomena occurs, the functional instruction


w

causing the problem needs to be fixed. Check the functional


instructions mentioned above to see whether there is any EN or R
w

condition remaining on, and correct the ladder program according to


the following procedure.
w

1. Put the machine in safe condition and turn off the power of the NC.
2. Turn on the power of the NC while holding down the "CAN" and
"Z" keys simultaneously, to restart the NC with the ladder program
://

halted.
3. In the FANUC LADDER-IIIC, redesign the logic associated with
the problematic functional instruction. When done, set the EN or R
tp

condition to off.
4. Write the resulting logic to flash ROM using the I/O screen.
5. Run the ladder program.
ht

If the ladder program does not stop or cannot be changed even after
you make the correction, there may be other functional instructions
that have the same condition settings.
Check for other functional instructions having the same condition
settings, besides the one you have corrected, and repeat the above
procedure to correct them all.

- 157 -
5.IL INSTRUCTIONS B-63823EN/02

5 IL INSTRUCTIONS

/
om
IL logic instructions and functions are grouped according to the type
of operation performed. The instruction groups are:

Number Class

s.c
1 Basic IL Instructions
2 Timers & Counters
3 Math Functions
4 Relational Functions

re
5 Bit Functions
6 Data Move Functions
7 Data Table Functions
8
9
pa Conversion Functions
PMC Operations
cs
.cn
w
w
w
://
tp
ht

- 158 -
B-63823EN/02 5.IL INSTRUCTIONS

5.1 BASIC INSTRUCTIONS

The basic IL instruction set supports operations on BOOL, 8-bit


(BYTE), 16-bit (INT, WORD, UINT) and 32-bit (DINT, DWORD)

/
variables. These instructions generally operate on an accumulator's

om
content to generate a new value for the same accumulator. The
following instructions (sorted by functional group) are supported:

(a) Accumulator Instructions (Basic IL)


Mnemonic Description

s.c
LD_BOOL Load a value into the boolean accumulator.
LDN_BOOL Load the inverse of a value into the boolean accumulator.
LD_INT Load a single-precision integer value into the integer accumulator.
LD_ENO Load the enable output state, from the previously executed function, into the boolean

re
accumulator.
ST_BOOL Store the content of the boolean accumulator to a BOOL variable.
STN_BOOL Store the inverse of the boolean accumulator to a BOOL variable.
ST_SINT
ST_USINT

ST_INT
pa
Store the content of the integer accumulator to an 8-bit integer (SINT) variable.
Store the content of the integer accumulator to an unsigned 8-bit integer (USINT)
variable.
Store the content of the integer accumulator to a 16-bit integer (INT) variable.
cs
ST_UINT Store the content of the integer accumulator to an unsigned 16-bit integer (UINT)
variable.
ST_DINT Store the content of the integer accumulator to a 32-bit integer (DINT) variable.
.cn

ST_UDINT Store the content of the integer accumulator to an unsigned 32-bit integer (UDINT)
variable.
ST_BYTE Store the content of the integer accumulator to a BYTE variable.
ST_WORD Store the content of the integer accumulator to a WORD variable.
ST_DWORD Store the content of the integer accumulator to a DWORD variable.
w

(b) Coil Instructions (Basic IL)


w

Mnemonic Description
S Store the content of the boolean accumulator to the Set Coil variable.
R Store the content of the boolean accumulator to the Reset Coil variable.
w

(c) Boolean Instructions (Basic IL)


://

Mnemonic Description
NOT Invert the state of the boolean accumulator.
AND Perform a logical AND between an operand and the boolean accumulator.
ANDN Perform a logical AND between the boolean accumulator and the inverse of an operand.
tp

AND() Perform a logical AND between a boolean expression and the boolean accumulator.
OR Perform a logical OR between an operand and the boolean accumulator.
ORN Perform a logical OR between the boolean accumulator and the inverse of an operand.
ht

OR() Perform a logical OR between a boolean expression and the boolean accumulator.
XOR Perform a logical XOR between an operand and the boolean accumulator.
XOR() Perform a logical XOR between a boolean expression and the boolean accumulator.
XORN Perform a logical XOR between the boolean accumulator and the inverse of an operand.
XORN() Perform a logical XORN between a boolean expression and the boolean accumulator.

- 159 -
5.IL INSTRUCTIONS B-63823EN/02

(d) Math Instructions (Basic IL)


Mnemonic Description
ADD Add the content of the integer accumulator to the single-precision integer operand.
SUB Subtract the single-precision integer operand from the content of the integer
accumulator.

/
MUL Multiply the content of the integer accumulator with the single-precision integer operand.

om
DIV Divide the content of the integer accumulator by the single-precision integer operand.
MOD Divide the content of the integer accumulator by the single-precision integer operand and
store the remainder in the accumulator.

(e) Relational Instructions (Basic IL)

s.c
Mnemonic Description
GT Set the boolean accumulator to True if the content of the integer accumulator is greater
than the single-precision integer operand.
GE Set the boolean accumulator to True if the content of the integer accumulator is greater

re
than or equal to the single-precision integer operand.
EQ Set the boolean accumulator to True if the content of the integer accumulator is equal to
the single-precision integer operand.
NE

LE
pa
Set the boolean accumulator to True if the content of the integer accumulator is not
equal to the single-precision integer operand.
Set the boolean accumulator to True if the content of the integer accumulator is less
than or equal to the single-precision integer operand.
cs
LT Set the boolean accumulator to True if the content of the integer accumulator is less
than the single-precision integer operand.
.cn

(f) Program Flow Instructions (Basic IL)


Mnemonic Description
CAL Call subroutine block.
CALC Call subroutine block if boolean accumulator is set to True.
CALCN Call subroutine block if boolean accumulator is set to False.
w

END Marks the absolute end of section of IL logic.


ENDMCRN Marks the end of a section of IL logic that will not be solved. The section begins with a
w

MCRN instruction with the same name assigned.


JMP Transfer execution to label.
JMPC Transfer execution to label if boolean accumulator is set to True.
w

JMPCN Transfer execution to label if boolean accumulator is set to False.


MCRN Marks the beginning of a section of IL logic that will be bypassed. The end of the section
is marked with an END_MCRN instruction assigned the same name.
://

RET Return from subroutine.


RETC Return from subroutine if boolean accumulator is set to True.
RETCN Return from subroutine if boolean accumulator is set to False.
tp
ht

- 160 -
B-63823EN/02 5.IL INSTRUCTIONS

5.2 IL TIMERS & COUNTERS

Timers
Use these IL functions to time intervals from instruction list logic.

/
Off Delay Timer

om
On Delay Stopwatch Timer
On Delay Timer

Counters
Use these IL functions to count events occurring in a process under

s.c
control.
Up Counter
Down Counter

re
pa
cs
.cn
w
w
w
://
tp
ht

- 161 -
5.IL INSTRUCTIONS B-63823EN/02

5.2.1 Off Delay Timer

5.2.1.1 OFDT_THOUS(address, pv)

/
The off-delay timer increments every thousandths of a second while power flow is off, and resets to

om
0 when there is power flow. The timer passes power until the specified interval 'pv' has elapsed.
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.

s.c
pv: INT variable or constant (0 - 32,767); preset value in thousandths of second.

5.2.1.2 OFDT_HUNDS(address, pv)

re
The off-delay timer increments every hundredth of a second while power flow is off, and resets to 0
when there is power flow. The timer passes power until the specified interval 'pv' has elapsed.
pa
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.
cs
pv: INT variable or constant (0 - 32,767); preset value in hundredths of second.

5.2.1.3 OFDT_TENTHS(address, pv)


.cn

The off-delay timer increments every tenth of a second while power flow is off, and resets to 0
when there is power flow. The timer passes power until the specified interval 'pv' has elapsed.
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
w

Value 'pv', Word 3 - Control Word.


pv: INT variable or constant (0 - 32,767); preset value in tenths of second.
w

5.2.1.4 OFDT_SECS(address, pv)


w

The off-delay timer increments every one second while power flow is off, and resets to 0 when there
://

is power flow. The timer passes power until the specified interval 'pv' has elapsed.
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
tp

Value 'pv', Word 3 - Control Word.


pv: INT variable or constant (0 - 32,767); preset value in one second.
ht

- 162 -
B-63823EN/02 5.IL INSTRUCTIONS

5.2.1.5 OFDT_TENSEC(address, pv)

The off-delay timer increments every ten seconds while power flow is off, and resets to 0 when
there is power flow. The timer passes power until the specified interval 'pv' has elapsed.

/
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset

om
Value 'pv', Word 3 - Control Word.
pv: INT variable or constant (0 - 32,767); preset value in ten seconds.

5.2.1.6

s.c
OFDT_MIN(address, pv)

The off-delay timer increments every one minute while power flow is off, and resets to 0 when

re
there is power flow. The timer passes power until the specified interval 'pv' has elapsed.
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.
pa
pv: INT variable or constant (0 - 32,767); preset value in one minute.
cs
For more details, see LD Functions.
Note: IL and LD functions are generally the same, with some differences in data types for operands.
.cn
w
w
w
://
tp
ht

- 163 -
5.IL INSTRUCTIONS B-63823EN/02

5.2.2 On Delay Stopwatch Timer

5.2.2.1 ONDTR_THOUS(address, r, pv)

/
The on-delay stop watch timer increments every thousandth of a second while an accumulator is

om
present, and holds its value when the accumulator is removed.
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.

s.c
pv: INT variable or constant (0 - 32,767); preset value in thousandths of second.
r: BOOL variable; resets 'cv' to zero when True.

5.2.2.2 ONDTR_HUNDS(address, r, pv)

re
pa
The on-delay stop watch timer increments every hundredth of a second while an accumulator is
present, and holds its value when the accumulator is removed.
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
cs
Value 'pv', Word 3 - Control Word.
pv: INT variable or constant (0 - 32,767); preset value in hundredths of second.
.cn

r: BOOL variable; resets 'cv' to zero when True.

5.2.2.3 ONDTR_TENTHS(address, r, pv)


w

The on-delay stop watch timer increments every tenth of a second while an accumulator is present,
w

and holds its value when the accumulator is removed.


address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
w

Value 'pv', Word 3 - Control Word.


pv: INT variable or constant (0 - 32,767); preset value in tenth of second.
://

r: BOOL variable; resets 'cv' to zero when True.

5.2.2.4 ONDTR_SECS(address, r, pv)


tp

The on-delay stop watch timer increments every one second while an accumulator is present, and
ht

holds its value when the accumulator is removed.


address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.
pv: INT variable or constant (0 - 32,767); preset value in one second.
r: BOOL variable; resets 'cv' to zero when True.

- 164 -
B-63823EN/02 5.IL INSTRUCTIONS

5.2.2.5 ONDTR_TENSEC(address, r, pv)

The on-delay stop watch timer increments every ten seconds while an accumulator is present, and

/
holds its value when the accumulator is removed.

om
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.
pv: INT variable or constant (0 - 32,767); preset value in ten seconds.

s.c
r: BOOL variable; resets 'cv' to zero when True.

5.2.2.6 ONDTR_MIN(address, r, pv)

re
The on-delay stop watch timer increments every one minute while an accumulator is present, and
holds its value when the accumulator is removed.
pa
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.
cs
pv: INT variable or constant (0 - 32,767); preset value in one minute.
r: BOOL variable; resets 'cv' to zero when True.
.cn

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
w
://
tp
ht

- 165 -
5.IL INSTRUCTIONS B-63823EN/02

5.2.3 On Delay Timer

5.2.3.1 TMR_THOUS(address, pv)

/
The standard timer increments while there is an accumulator present and resets to 0 when the

om
accumulator is removed.
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.
pv: INT variable or constant (0 - 32,767); preset value in thousandths of second.

s.c
5.2.3.2 TMR_HUNDS(address, pv)

re
The standard timer increments while there is an accumulator present and resets to 0 when the
accumulator is removed.

pa
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.
cs
pv: INT variable or constant (0 - 32,767); preset value in hundredths of second.

5.2.3.3 TMR_TENTHS(address, pv)


.cn

The standard timer increments while there is an accumulator present and resets to 0 when the
accumulator is removed.
w

address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.
w

pv: INT variable or constant (0 - 32,767); preset value in tenths of second.

5.2.3.4 TMR_SECS(address, pv)


w

The standard timer increments while there is an accumulator present and resets to 0 when the
://

accumulator is removed.
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
tp

Value 'pv', Word 3 - Control Word.


pv: INT variable or constant (0 - 32,767); preset value in one second.
ht

- 166 -
B-63823EN/02 5.IL INSTRUCTIONS

5.2.3.5 TMR_TENSEC(address, pv)

The standard timer increments while there is an accumulator present and resets to 0 when the
accumulator is removed.

/
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset

om
Value 'pv', Word 3 - Control Word.
pv: INT variable or constant (0 - 32,767); preset value in ten seconds.

5.2.3.6 TMR_MIN(address, pv)

s.c
The standard timer increments while there is an accumulator present and resets to 0 when the
accumulator is removed.

re
address: The first of three consecutive word registers. Word 1 - Current Value 'cv', Word 2 - Preset
Value 'pv', Word 3 - Control Word.

pa
pv: INT variable or constant (0 - 32,767); preset value in one minute.
cs
For more details, see LD Functions.
Note: IL and LD functions are generally the same, with some differences in data types for operands.
.cn
w
w
w
://
tp
ht

- 167 -
5.IL INSTRUCTIONS B-63823EN/02

5.2.4 Up Counter

5.2.4.1 UPCTR(address, r, pv)

/
Each time UPCTR executes, it checks the current value of the Boolean accumulator. If that value

om
has transitioned to ON, then UPCTR increments the current value 'CV'; otherwise, CV remains
the same. When the 'PV' value is reached, the enable output turns ON and stays on until 'r' input
becomes True to reset 'CV' to zero.
address: WORD variable; the beginning address of a three-word WORD array. Word 1 - Current

s.c
Value 'CV', Word 2 - Preset Value 'PV', Word 3 - Control Word.
r: BOOL variable; resets the counter when True.
pv: INT variable or constant (0 - 32,767); preset value.

re
For more details, see LD Functions.

pa
Note: IL and LD functions are generally the same, with some differences in data types for operands.
cs
5.2.5 Down Counter
.cn

5.2.5.1 DNCTR(address, r, pv)

Each time DNCTR executes, it checks the current value of the Boolean accumulator. If that value
w

has transitioned to ON, then DNCTR decrements the current value 'CV'; otherwise, CV remains
the same. When the 'CV' value decrements to zero or less, the enable output turns ON and stays
w

on until the 'r' input becomes True to reset 'CV' to the 'PV'.
address: WORD variable; the beginning address of a three-word WORD array. Word 1 - Current
w

Value 'CV', Word 2 - Preset Value 'PV', Word 3 - Control Word.


r: BOOL variable; resets the counter when True.
://

pv: INT variable or constant (0 - 32,767); preset value.


tp

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.
ht

- 168 -
B-63823EN/02 5.IL INSTRUCTIONS

5.3 IL MATH FUNCTIONS

Math Functions
Use these IL instructions to perform basic mathematical operations on

/
data in instruction list logic.

om
Add
Subtract
Multiply
Divide
Modulus

s.c
Absolute
Square root

re
pa
cs
.cn
w
w
w
://
tp
ht

- 169 -
5.IL INSTRUCTIONS B-63823EN/02

5.3.1 Add

5.3.1.1 ADD_SINT(in1, in2)

accumulator ← in1 + in2

/
om
Add two short integers and store the sum in the integer accumulator.
in1: SINT variable or constant
in2: SINT variable or constant

s.c
5.3.1.2 ADD_USINT(in1, in2)

accumulator ← in1 + in2

re
Add two unsigned short integers and store the sum in the integer accumulator.
in1: USINT variable or constant
in2: USINT variable or constant

5.3.1.3 ADD_INT(in1, in2)


pa
cs
accumulator ← in1 + in2
.cn

Add two single-precision integers and store the sum in the integer accumulator.
in1: INT variable or constant
in2: INT variable or constant
w

5.3.1.4 ADD_UINT(in1, in2)


w

accumulator ← in1 + in2


w

Add two single-precision unsigned integers and store the sum in the integer accumulator.
in1: UINT variable or constant
://

in2: UINT variable or constant

5.3.1.5 ADD_DINT(in1, in2)


tp

accumulator ← in1 + in2


ht

Add two double-precision integers and store the sum in the integer accumulator.
in1: DINT variable or constant
in2: DINT variable or constant

- 170 -
B-63823EN/02 5.IL INSTRUCTIONS

5.3.1.6 ADD_UDINT(in1, in2)

accumulator ← in1 + in2


Add two double-precision unsigned integers and store the sum in the integer accumulator.

/
in1: UDINT variable or constant

om
in2: UDINT variable or constant

For more details, see LD Functions.

s.c
Note: IL and LD functions are generally the same, with some differences in data types for operands.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 171 -
5.IL INSTRUCTIONS B-63823EN/02

5.3.2 Subtract

5.3.2.1 SUB_SINT(in1, in2)

/
accumulator ← in1 - in2

om
Subtract one short integer from another and store the result in the accumulator. The value and
type of the accumulator are unchanged.
in1: SINT variable or constant

s.c
in2: SINT variable or constant

5.3.2.2 SUB_USINT(in1, in2)

re
accumulator ← in1 - in2
Subtract one unsigned short integer from another and store the result in the accumulator. The
value and type of the accumulator are unchanged.
in1: USINT variable or constant
pa
cs
in2: USINT variable or constant

5.3.2.3 SUB_INT(in1, in2)


.cn

accumulator ← in1 - in2


Subtract one single-precision integer from another and store the result in the accumulator. The
w

value and type of the accumulator are unchanged.


in1: INT variable or constant
w

in2: INT variable or constant


w

5.3.2.4 SUB_UINT(in1, in2)


://

accumulator ← in1 - in2


Subtract one single-precision unsigned integer from another and store the result in the
tp

accumulator. The value and type of the accumulator are unchanged.


in1: UINT variable or constant
ht

in2: UINT variable or constant

- 172 -
B-63823EN/02 5.IL INSTRUCTIONS

5.3.2.5 SUB_DINT(in1, in2)

accumulator ← in1 - in2


Subtract one double-precision integer from another and store the result in the accumulator. The

/
value and type of the accumulator are unchanged.

om
in1: DINT variable or constant
in2: DINT variable or constant

5.3.2.6 SUB_UDINT(in1, in2)

s.c
accumulator ← in1 - in2

re
Subtract one double-precision unsigned integer from another and store the result in the
accumulator. The value and type of the accumulator are unchanged.
in1: UDINT variable or constant
in2: UDINT variable or constant
For more details, see LD Functions.
pa
cs
Note: IL and LD functions are generally the same, with some differences in data types for operands.
.cn
w
w
w
://
tp
ht

- 173 -
5.IL INSTRUCTIONS B-63823EN/02

5.3.3 Multiply

5.3.3.1 MUL_SINT(in1, in2)

/
accumulator ← in1 * in2

om
Multiply one short integer by another and store the product in the accumulator. The accumulator
type is unchanged.
in1: SINT variable or constant

s.c
in2: SINT variable or constant

5.3.3.2 MUL_USINT(in1, in2)

re
accumulator ← in1 * in2
Multiply one unsigned short integer by another and store the product in the accumulator. The
accumulator type is unchanged.
in1: USINT variable or constant
pa
cs
in2: USINT variable or constant

5.3.3.3 MUL_INT(in1, in2)


.cn

accumulator ← in1 * in2


Multiply one single-precision integer by another and store the product in the accumulator. The
w

accumulator type is unchanged.


in1: INT variable or constant
w

in2: INT variable or constant


w

5.3.3.4 MUL_UINT(in1, in2)


://

accumulator ← in1 * in2


Multiply one single-precision unsigned integer by another and store the product in the
tp

accumulator. The accumulator type is unchanged.


in1: UINT variable or constant
ht

in2: UINT variable or constant

- 174 -
B-63823EN/02 5.IL INSTRUCTIONS

5.3.3.5 MUL_DINT(in1, in2)

accumulator ← in1 * in2


Multiply one double-precision integer by another and store the product in the accumulator. The

/
accumulator type is unchanged.

om
in1: DINT variable or constant
in2: DINT variable or constant

5.3.3.6 MUL_UDINT(in1, in2)

s.c
accumulator ← in1 * in2

re
Multiply one double-precision unsigned integer by another and store the product in the
accumulator. The accumulator type is unchanged.
in1: UDINT variable or constant
in2: UDINT variable or constant pa
cs
For more details, see LD Functions.
Note: IL and LD functions are generally the same, with some differences in data types for operands.
.cn
w
w
w
://
tp
ht

- 175 -
5.IL INSTRUCTIONS B-63823EN/02

5.3.4 Divide

5.3.4.1 DIV_SINT(in1, in2)

/
accumulator ← in1/in2

om
Divide one short integer (in1) by another (in2) and store the quotient in the integer accumulator.
in1: SINT variable or constant; the dividend
in2: SINT variable or constant; the divisor

s.c
5.3.4.2 DIV_USINT(in1, in2)

accumulator ← in1/in2

re
Divide one unsigned short integer (in1) by another (in2) and store the quotient in the integer
accumulator.
in1: USINT variable or constant; the dividend
in2: USINT variable or constant; the divisor
pa
cs
5.3.4.3 DIV_INT(in1, in2)
.cn

accumulator ← in1/in2
Divide one single-precision integer (in1) by another (in2) and store the quotient in the integer
accumulator.
w

in1: INT variable or constant; the dividend


in2: INT variable or constant; the divisor
w

5.3.4.4 DIV_UINT(in1, in2)


w

accumulator ← in1/in2
://

Divide one single-precision unsigned integer (in1) by another (in2) and store the quotient in the
integer accumulator.
tp

in1: UINT variable or constant; the dividend


in2: UINT variable or constant; the divisor
ht

- 176 -
B-63823EN/02 5.IL INSTRUCTIONS

5.3.4.5 DIV_DINT(in1, in2)

accumulator ← in1/in2
Divide one double-precision integer (in1) by another (in2) and store the quotient in the integer

/
accumulator.

om
in1: DINT variable or constant; the dividend
in2: DINT variable or constant; the divisor

5.3.4.6 DIV_UDINT(in1, in2)

s.c
accumulator ← in1/in2

re
Divide one double-precision unsigned integer (in1) by another (in2) and store the quotient in the
integer accumulator.
in1: UDINT variable or constant; the dividend
in2: UDINT variable or constant; the divisor pa
cs
For more details, see LD Functions.
Note: IL and LD functions are generally the same, with some differences in data types for operands.
.cn
w
w
w
://
tp
ht

- 177 -
5.IL INSTRUCTIONS B-63823EN/02

5.3.5 Modulus

5.3.5.1 MOD_SINT(in1, in2)

/
accumulator ← REMAINDER [in1/in2]

om
Divide one short integer by another and place the remainder in the accumulator. The accumulator
type is unchanged.
in1: SINT variable or constant

s.c
in2: SINT variable or constant

5.3.5.2 MOD_USINT(in1, in2)

re
accumulator ← REMAINDER [in1/in2]

accumulator type is unchanged.


in1: USINT variable or constant
pa
Divide one unsigned short integer by another and place the remainder in the accumulator. The
cs
in2: USINT variable or constant

5.3.5.3 MOD_INT(in1, in2)


.cn

accumulator ← REMAINDER [in1/in2]


w

Divide one single-precision integer by another and place the remainder in the accumulator. The
accumulator type is unchanged.
w

in1: INT variable or constant


in2: INT variable or constant
w

5.3.5.4 MOD_UINT(in1, in2)


://

accumulator ← REMAINDER [in1/in2]


Divide one single-precision unsigned integer by another and place the remainder in the
tp

accumulator. The accumulator type is unchanged.


in1:UINT variable or constant
ht

in2: UINT variable or constant

- 178 -
B-63823EN/02 5.IL INSTRUCTIONS

5.3.5.5 MOD_DINT(in1, in2)

accumulator ← REMAINDER [in1/in2]


Divide one double-precision integer by another and place the remainder in the accumulator. The

/
accumulator type is unchanged.

om
in1: DINT variable or constant
in2: DINT variable or constant

5.3.5.6

s.c
MOD_UDINT(in1, in2)

accumulator ← REMAINDER [in1/in2]

re
Divide one double-precision unsigned integer by another and place the remainder in the
accumulator. The accumulator type is unchanged.
in1: UDINT variable or constant
in2: UDINT variable or constant pa
cs
For more details, see LD Functions.
Note: IL and LD functions are generally the same, with some differences in data types for operands.
.cn
w
w
w
://
tp
ht

- 179 -
5.IL INSTRUCTIONS B-63823EN/02

5.3.6 Absolute

5.3.6.1 ABS_SINT(in)

/
accumulator ← ABS(in)

om
Absolute short integers and store the result in the integer accumulator.
in: SINT variable or constant

5.3.6.2 ABS_INT(in)

s.c
accumulator ← ABS(in)

re
Absolute single-precision integers and store the result in the integer accumulator.
in: INT variable or constant

5.3.6.3 ABS_DINT(in) pa
cs
accumulator ← ABS(in)
Absolute double-precision integers and store the result in the integer accumulator.
.cn

in: DINT variable or constant


Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
w
://
tp
ht

- 180 -
B-63823EN/02 5.IL INSTRUCTIONS

5.3.7 Square Root

5.3.7.1 SQRT_SINT(in)

/
accumulator ← operand

om
Take the square root of a short integer and store the result in the integer accumulator.
in: SINT variable or constant

5.3.7.2 SQRT_USINT(in)

s.c
accumulator ← operand

re
Take the square root of a unsigned short integer and store the result in the integer accumulator.
in: USINT variable or constant

5.3.7.3 SQRT_INT(in) pa
cs
accumulator ← operand
Take the square root of a single-precision integer and store the result in the integer accumulator.
.cn

in: INT, WORD variable or constant

5.3.7.4 SQRT_UINT(in)
w

accumulator ← operand
Take the square root of a single-precision unsigned integer and store the result in the integer
w

accumulator.
w

in: UINT, WORD variable or constant

5.3.7.5 SQRT_DINT(in)
://

accumulator ← operand
tp

Take the square root of a double-precision integer and store the result in the integer accumulator.
in: DINT variable or constant
ht

- 181 -
5.IL INSTRUCTIONS B-63823EN/02

5.3.7.6 SQRT_UDINT(in)

accumulator ← operand
Take the square root of a double-precision unsigned integer and store the result in the integer

/
accumulator.

om
in: UDINT variable or constant

For more details, see "4.3.4 SQRT_(type)"

s.c
Note: IL and LD functions are generally the same, with some differences in data types for operands.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 182 -
B-63823EN/02 5.IL INSTRUCTIONS

5.4 IL RELATIONAL FUNCTIONS

Relational Functions
Use these IL functions to compare the values of two operands without

/
altering them or generating a sum or difference.

om
Equal
Not Equal
Greater Than
Greater or Equal
Less Than

s.c
Less or Equal
Range

re
pa
cs
.cn
w
w
w
://
tp
ht

- 183 -
5.IL INSTRUCTIONS B-63823EN/02

5.4.1 Equal

5.4.1.1 EQ_SINT(in1, in2)

/
If in1 = in2, boolean accumulator ← 1

om
If in1 in2, boolean accumulator ← 0
Compare the two short integers and set the boolean accumulator if they are equal. Otherwise,
clear the boolean accumulator.

s.c
in1: SINT variable or constant
in2: SINT variable or constant

5.4.1.2 EQ_USINT(in1, in2)

re
If in1 = in2, boolean accumulator ← 1
If in1 in2, boolean accumulator ← 0
pa
Compare the two unsigned short integers and set the boolean accumulator if they are equal.
cs
Otherwise, clear the boolean accumulator.
in1: USINT variable or constant
in2: USINT variable or constant
.cn

5.4.1.3 EQ_INT(in1, in2)


w

If in1 = in2, boolean accumulator ← 1


If in1 in2, boolean accumulator ← 0
w

Compare the two single-precision integers and set the boolean accumulator if they are equal.
Otherwise, clear the boolean accumulator.
w

in1: INT variable or constant


in2: INT variable or constant
://

5.4.1.4 EQ_UINT(in1, in2)


tp

If in1 = in2, boolean accumulator ← 1


ht

If in1 in2, boolean accumulator ← 0


Compare the two single-precision unsigned integers and set the boolean accumulator if they are
equal. Otherwise, clear the boolean accumulator.
in1: UINT variable or constant
in2: UINT variable or constant

- 184 -
B-63823EN/02 5.IL INSTRUCTIONS

5.4.1.5 EQ_DINT(in1, in2)

If in1 = in2, boolean accumulator ← 1


If in1 in2, boolean accumulator ← 0

/
Compare two double-precision integers and set the boolean accumulator if they are equal.

om
Otherwise, clear the boolean accumulator.
in1: DINT variable or constant
in2: DINT variable or constant

s.c
5.4.1.6 EQ_UDINT(in1, in2)

re
If in1 = in2, boolean accumulator ← 1
If in1 in2, boolean accumulator ← 0

Otherwise, clear the boolean accumulator.


in1: UDINT variable or constant
pa
Compare two double-precision unsigned integers and set the boolean accumulator if they are equal.
cs
in2: UDINT variable or constant

5.4.1.7
.cn

EQ_BYTE(in1, in2)

If in1 = in2, boolean accumulator ← 1


If in1 in2, boolean accumulator ← 0
w

Compare two BYTE data and set the boolean accumulator if they are equal. Otherwise, clear the
boolean accumulator.
w

in1: BYTE variable or constant


in2: BYTE variable or constant
w

5.4.1.8 EQ_WORD(in1, in2)


://

If in1 = in2, boolean accumulator ← 1


tp

If in1 in2, boolean accumulator ← 0


Compare two WORD data and set the boolean accumulator if they are equal. Otherwise, clear the
ht

boolean accumulator.
in1: WORD variable or constant
in2: WORD variable or constant

- 185 -
5.IL INSTRUCTIONS B-63823EN/02

5.4.1.9 EQ_DWORD(in1, in2)

If in1 = in2, boolean accumulator ← 1


If in1 in2, boolean accumulator ← 0

/
Compare two DWORD data and set the boolean accumulator if they are equal. Otherwise, clear the

om
boolean accumulator.
in1: DWORD variable or constant
in2: DWORD variable or constant

s.c
For more details, see LD Functions.
Note: IL and LD functions are generally the same, with some differences in data types for operands.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 186 -
B-63823EN/02 5.IL INSTRUCTIONS

5.4.2 Not Equal

5.4.2.1 NE_SINT(in1, in2)

/
If in1 in2, boolean accumulator ← 1

om
If in1 = in2, boolean accumulator ← 0
Compare the values of two short integers and set the boolean accumulator to 1 if they are not
equal. Otherwise, clear the boolean accumulator to 0. The accumulator type is set to boolean.
in1: SINT variable or constant

s.c
in2: SINT variable or constant

5.4.2.2 NE_USINT(in1, in2)

re
If in1 in2, boolean accumulator ← 1
If in1 = in2, boolean accumulator ← 0
pa
Compare the values of two unsigned short integers and set the boolean accumulator to 1 if they are
not equal. Otherwise, clear the boolean accumulator to 0. The accumulator type is set to boolean.
cs
in1: USINT variable or constant
in2: USINT variable or constant
.cn

5.4.2.3 NE_INT(in1, in2)

If in1 in2, boolean accumulator ← 1


w

If in1 = in2, boolean accumulator ← 0


Compare the values of two single-precision integers and set the boolean accumulator to 1 if they
w

are not equal. Otherwise, clear the boolean accumulator to 0. The accumulator type is set to
boolean.
w

in1: INT variable or constant


in2: INT variable or constant
://

5.4.2.4 NE_UINT(in1, in2)


tp

If in1 in2, boolean accumulator ← 1


If in1 = in2, boolean accumulator ← 0
ht

Compare the values of two single-precision unsigned integers and set the boolean accumulator to 1
if they are not equal. Otherwise, clear the boolean accumulator to 0. The accumulator type is set to
boolean.
in1: UINT variable or constant
in2: UINT variable or constant

- 187 -
5.IL INSTRUCTIONS B-63823EN/02

5.4.2.5 NE_DINT(in1, in2)

If in1 in2, boolean accumulator ← 1


If in1 = in2, boolean accumulator ← 0

/
Compare the values of two double-precision integers and set the boolean accumulator to 1 if they

om
are not equal. Otherwise, clear the boolean accumulator to 0. The accumulator type is set to
boolean.
in1: DINT variable or constant

s.c
in2: DINT variable or constant

5.4.2.6 NE_UDINT(in1, in2)

re
If in1 in2, boolean accumulator ← 1
If in1 = in2, boolean accumulator ← 0

pa
Compare the values of two double-precision unsigned integers and set the boolean accumulator to
1 if they are not equal. Otherwise, clear the boolean accumulator to 0. The accumulator type is set
to boolean.
cs
in1: UDINT variable or constant
in2: UDINT variable or constant
.cn

5.4.2.7 NE_BYTE(in1, in2)

If in1 in2, boolean accumulator ← 1


w

If in1 = in2, boolean accumulator ← 0


Compare the values of two BYTE data and set the boolean accumulator to 1 if they are not equal.
w

Otherwise, clear the boolean accumulator to 0. The accumulator type is set to boolean.
in1: BYTE variable or constant
w

in2: BYTE variable or constant


://

5.4.2.8 NE_WORD(in1, in2)

If in1 in2, boolean accumulator ← 1


tp

If in1 = in2, boolean accumulator ← 0


Compare the values of two WORD data and set the boolean accumulator to 1 if they are not equal.
ht

Otherwise, clear the boolean accumulator to 0. The accumulator type is set to boolean.
in1: WORD variable or constant
in2: WORD variable or constant

- 188 -
B-63823EN/02 5.IL INSTRUCTIONS

5.4.2.9 NE_DWORD(in1, in2)

If in1 in2, boolean accumulator ← 1


If in1 = in2, boolean accumulator ← 0

/
Compare the values of two DWORD data and set the boolean accumulator to 1 if they are not equal.

om
Otherwise, clear the boolean accumulator to 0. The accumulator type is set to boolean.
in1: DWORD variable or constant
in2: DWORD variable or constant

s.c
For more details, see LD Functions.
Note: IL and LD functions are generally the same, with some differences in data types for operands.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 189 -
5.IL INSTRUCTIONS B-63823EN/02

5.4.3 Greater Than

5.4.3.1 GT_SINT(in1, in2)

If in1 > in2, boolean accumulator ← 1

/
om
If in1 ≤ in2, boolean accumulator ← 0
Compare the value of two short integers and set the boolean accumulator to 1 if in1 is numerically
greater than in2. Otherwise, set the boolean accumulator to 0. The accumulator type is set to
boolean.

s.c
in1: SINT variable or constant
in2: SINT variable or constant

re
5.4.3.2 GT_USINT(in1, in2)

If in1 > in2, boolean accumulator ← 1


If in1 ≤ in2, boolean accumulator ← 0 pa
Compare the value of two unsigned short integers and set the boolean accumulator to 1 if in1 is
cs
numerically greater than in2. Otherwise, set the boolean accumulator to 0. The accumulator type
is set to boolean.
.cn

in1: USINT variable or constant


in2: USINT variable or constant

5.4.3.3 GT_INT(in1, in2)


w

If in1 > in2, boolean accumulator ← 1


w

If in1 ≤ in2, boolean accumulator ← 0


Compare the value of two single-precision integers and set the boolean accumulator to 1 if in1 is
w

numerically greater than in2. Otherwise, set the boolean accumulator to 0. The accumulator type
is set to boolean.
://

in1: INT variable or constant


in2: INT variable or constant
tp
ht

- 190 -
B-63823EN/02 5.IL INSTRUCTIONS

5.4.3.4 GT_UINT(in1, in2)

If in1 > in2, boolean accumulator ← 1


If in1 ≤ in2, boolean accumulator ← 0

/
Compare the value of two single-precision unsigned integers and set the boolean accumulator to 1

om
if in1 is numerically greater than in2. Otherwise, set the boolean accumulator to 0. The
accumulator type is set to boolean.
in1: UINT variable or constant

s.c
in2: UINT variable or constant

5.4.3.5 GT_DINT(in1, in2)

re
If in1 > in2, boolean accumulator ← 1
If in1 ≤ in2, boolean accumulator ← 0

pa
Compare the value of two double-precision integers and set the boolean accumulator to 1 if in1 is
numerically greater than in2. Otherwise, set the boolean accumulator to 0. The accumulator type
is set to boolean.
cs
in1: DINT variable or constant
in2: DINT variable or constant
.cn

5.4.3.6 GT_UDINT(in1, in2)

If in1 > in2, boolean accumulator ← 1


w

If in1 ≤ in2, boolean accumulator ← 0


Compare the value of two double-precision unsigned integers and set the boolean accumulator to 1
w

if in1 is numerically greater than in2. Otherwise, set the boolean accumulator to 0. The
accumulator type is set to boolean.
w

in1: UDINT variable or constant


in2: UDINT variable or constant
://

For more details, see LD Functions.


tp

Note: IL and LD functions are generally the same, with some differences in data types for operands.
ht

- 191 -
5.IL INSTRUCTIONS B-63823EN/02

5.4.4 Greater or Equal

5.4.4.1 GE_SINT(in1, in2)

If in1 ≥ in2, boolean accumulator ← 1

/
om
If in1 < in2, boolean accumulator ← 0
Compare two short integers. If in1 is greater than or equal to in2, set the boolean accumulator. If
in1 is less than in2, clear the boolean accumulator.
in1: SINT variable or constant

s.c
in2: SINT variable or constant

5.4.4.2 GE_USINT(in1, in2)

re
If in1 ≥ in2, boolean accumulator ← 1
If in1 < in2, boolean accumulator ← 0
pa
Compare two unsigned short integers. If in1 is greater than or equal to in2, set the boolean
accumulator. If in1 is less than in2, clear the boolean accumulator.
cs
in1: USINT variable or constant
in2: USINT variable or constant
.cn

5.4.4.3 GE_INT(in1, in2)

If in1 ≥ in2, boolean accumulator ← 1


w

If in1 < in2, boolean accumulator ← 0


Compare two single-precision integers. If in1 is greater than or equal to in2, set the boolean
w

accumulator. If in1 is less than in2, clear the boolean accumulator.


in1: INT variable or constant
w

in2: INT variable or constant

5.4.4.4 GE_UINT(in1, in2)


://

If in1 ≥ in2, boolean accumulator ← 1


tp

If in1 < in2, boolean accumulator ← 0


Compare two single-precision unsigned integers. If in1 is greater than or equal to in2, set the
ht

boolean accumulator. If in1 is less than in2, clear the boolean accumulator.
in1:UINT variable or constant
in2: UINT variable or constant

- 192 -
B-63823EN/02 5.IL INSTRUCTIONS

5.4.4.5 GE_DINT(in1, in2)

If in1 ≥ in2, boolean accumulator ← 1


If in1 < in2, boolean accumulator ← 0

/
Compare two double-precision integers. If in1 is greater than or equal to in2, set the boolean

om
accumulator. If in1 is less than in2, clear the boolean accumulator.
in1: DINT variable or constant
in2: DINT variable or constant

s.c
5.4.4.6 GE_UDINT(in1, in2)

If in1 ≥ in2, boolean accumulator ← 1

re
If in1 < in2, boolean accumulator ← 0
Compare two double-precision unsigned integers. If in1 is greater than or equal to in2, set the

in1: UDINT variable or constant


in2: UDINT variable or constant
pa
boolean accumulator. If in1 is less than in2, clear the boolean accumulator.
cs
For more details, see LD Functions.
.cn

Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
w
://
tp
ht

- 193 -
5.IL INSTRUCTIONS B-63823EN/02

5.4.5 Less Than

5.4.5.1 LT_SINT(in1, in2)

If in1 < in2, boolean accumulator ← 1

/
om
If in1 ≥ in2, boolean accumulator ← 0
Compare two short integers and set the boolean accumulator to 1 if in1 is numerically less than
in2. Otherwise, clear the boolean accumulator to 0. The accumulator type is set to boolean.
in1: SINT variable or constant

s.c
in2: SINT variable or constant

5.4.5.2 LT_USINT(in1, in2)

re
If in1 < in2, boolean accumulator ← 1
If in1 ≥ in2, boolean accumulator ← 0
pa
Compare two unsigned short integers and set the boolean accumulator to 1 if in1 is numerically
less than in2. Otherwise, clear the boolean accumulator to 0. The accumulator type is set to
cs
boolean.
in1: USINT variable or constant
.cn

in2: USINT variable or constant

5.4.5.3 LT_INT(in1, in2)


w

If in1 < in2, boolean accumulator ← 1


If in1 ≥ in2, boolean accumulator ← 0
w

Compare two single-precision integers and set the boolean accumulator to 1 if in1 is numerically
less than in2. Otherwise, clear the boolean accumulator to 0. The accumulator type is set to
w

boolean.
in1: INT variable or constant
://

in2: INT variable or constant


tp
ht

- 194 -
B-63823EN/02 5.IL INSTRUCTIONS

5.4.5.4 LT_UINT(in1, in2)

If in1 < in2, boolean accumulator ← 1


If in1 ≥ in2, boolean accumulator ← 0

/
Compare two single-precision unsigned integers and set the boolean accumulator to 1 if in1 is

om
numerically less than in2. Otherwise, clear the boolean accumulator to 0. The accumulator type is
set to boolean.
in1: UINT variable or constant

s.c
in2: UINT variable or constant

5.4.5.5 LT_DINT(in1, in2)

re
If in1 < in2, boolean accumulator ← 1
If in1 ≥ in2, boolean accumulator ← 0

pa
Compare two double-precision integers and set the boolean accumulator to 1 if in1 is numerically
less than in2. Otherwise, clear the boolean accumulator to 0. The accumulator type is set to
boolean.
cs
in1: DINT variable or constant
in2: DINT variable or constant
.cn

5.4.5.6 LT_UDINT(in1, in2)

If in1 < in2, boolean accumulator ← 1


w

If in1 ≥ in2, boolean accumulator ← 0


Compare two double-precision unsigned integers and set the boolean accumulator to 1 if in1 is
w

numerically less than in2. Otherwise, clear the boolean accumulator to 0. The accumulator type is
set to boolean.
w

in1: UDINT variable or constant


in2: UDINT variable or constant
://

For more details, see LD Functions.


tp

Note: IL and LD functions are generally the same, with some differences in data types for operands.
ht

- 195 -
5.IL INSTRUCTIONS B-63823EN/02

5.4.6 Less or Equal

5.4.6.1 LE_SINT(in1, in2)

If in1 ≤ in2, boolean accumulator ← 1

/
om
If in1 > in2, boolean accumulator ← 0
Compare the content of two short integers and set the boolean accumulator to 1 if in1 is
numerically less than or equal to in2. Otherwise, clear the boolean accumulator to 0. The
accumulator type is set to boolean.

s.c
in1: SINT variable or constant
in2: SINT variable or constant

re
5.4.6.2 LE_USINT(in1, in2)

If in1 ≤ in2, boolean accumulator ← 1


If in1 > in2, boolean accumulator ← 0 pa
Compare the content of two unsigned short integers and set the boolean accumulator to 1 if in1 is
cs
numerically less than or equal to in2. Otherwise, clear the boolean accumulator to 0. The
accumulator type is set to boolean.
.cn

in1: USINT variable or constant


in2: USINT variable or constant

5.4.6.3 LE_INT(in1, in2)


w

If in1 ≤ in2, boolean accumulator ← 1


w

If in1 > in2, boolean accumulator ← 0


Compare the content of two single-precision integers and set the boolean accumulator to 1 if in1 is
w

numerically less than or equal to in2. Otherwise, clear the boolean accumulator to 0. The
accumulator type is set to boolean.
://

in1: INT variable or constant


in2: INT variable or constant
tp
ht

- 196 -
B-63823EN/02 5.IL INSTRUCTIONS

5.4.6.4 LE_UINT(in1, in2)

If in1 ≤ in2, boolean accumulator ← 1


If in1 > in2, boolean accumulator ← 0

/
Compare the content of two single-precision unsigned integers and set the boolean accumulator to

om
1 if in1 is numerically less than or equal to in2. Otherwise, clear the boolean accumulator to 0. The
accumulator type is set to boolean.
in1: UINT variable or constant

s.c
in2: UINT variable or constant

5.4.6.5 LE_DINT(in1, in2)

re
If in1 ≤ in2, boolean accumulator ← 1
If in1 > in2, boolean accumulator ← 0

pa
Compare the content of two double-precision integers and set the boolean accumulator to 1 if in1 is
numerically less than or equal to in2. Otherwise, clear the boolean accumulator to 0. The
accumulator type is set to boolean.
cs
in1: DINT variable or constant
in2: DINT variable or constant
.cn

5.4.6.6 LE_UDINT(in1, in2)

If in1 ≤ in2, boolean accumulator ← 1


w

If in1 > in2, boolean accumulator ← 0


Compare the content of two double-precision unsigned integers and set the boolean accumulator to
w

1 if in1 is numerically less than or equal to in2. Otherwise, clear the boolean accumulator to 0. The
accumulator type is set to boolean.
w

in1: UDINT variable or constant


in2: UDINT variable or constant
://

For more details, see LD Functions.


tp

Note: IL and LD functions are generally the same, with some differences in data types for operands.
ht

- 197 -
5.IL INSTRUCTIONS B-63823EN/02

5.4.7 Range

5.4.7.1 RANGE_SINT(l1, l2, in)

If l1 < in < l2, boolean accumulator ← 1

/
om
Otherwise, boolean accumulator ← 0
Test if a value is within a range limited by two other values.
l1: SINT variable or constant; the lower limit of the range.
l2: SINT variable or constant; the upper limit of the range.

s.c
in: SINT variable or constant; the value under test

5.4.7.2 RANGE_USINT(l1, l2, in)

re
If l1 < in < l2, boolean accumulator ← 1
Otherwise, boolean accumulator ← 0
pa
Test if a value is within a range limited by two other values.
l1: USINT variable or constant; the lower limit of the range.
cs
l2: USINT variable or constant; the upper limit of the range.
in: USINT variable or constant; the value under test
.cn

5.4.7.3 RANGE_INT(l1, l2, in)

If l1 < in < l2, boolean accumulator ← 1


w

Otherwise, boolean accumulator ← 0


Test if a value is within a range limited by two other values.
w

l1: INT variable or constant; the lower limit of the range.


l2: INT variable or constant; the upper limit of the range.
w

in: INT variable or constant; the value under test

5.4.7.4 RANGE_UINT(l1, l2, in)


://

If l1 < in < l2, boolean accumulator ← 1


tp

Otherwise, boolean accumulator ← 0


Test if a value is within a range limited by two other values.
ht

l1: UINT variable or constant; the lower limit of the range.


l2: UINT variable or constant; the upper limit of the range.
in: UINT variable or constant; the value under test.

- 198 -
B-63823EN/02 5.IL INSTRUCTIONS

5.4.7.5 RANGE_DINT(l1, l2, in)

If l1 < in < l2, boolean accumulator ← 1


Otherwise, boolean accumulator ← 0

/
Test if a value is within a range limited by two other values.

om
l1: DINT variable or constant; the lower limit of the range.
l2: DINT variable or constant; the upper limit of the range.
in: DINT variable or constant; the value under test.

s.c
5.4.7.6 RANGE_UDINT(l1, l2, in)

If l1 < in < l2, boolean accumulator ← 1

re
Otherwise, boolean accumulator ← 0
Test if a value is within a range limited by two other values.
l1: UDINT variable or constant; the lower limit of the range.
l2: UDINT variable or constant; the upper limit of the range.
in: UDINT variable or constant; the value under test.
pa
cs
For more details, see LD Functions.
.cn

Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
w
://
tp
ht

- 199 -
5.IL INSTRUCTIONS B-63823EN/02

5.5 IL BIT OPERATIONS

Bit Functions
Use these IL functions to perform bit-wise logical operations on

/
binary strings (WORD/DWORD data).

om
Logical AND
Logical OR
Logical XOR
Logical NOT
Shift Bits Right, Shift Bits Left

s.c
Rotate Bits Right, Rotate Bits Left
Bit Test
Bit Set, Bit Clear
Bit Position

re
Bit Sequencer
Masked Compare

pa
cs
.cn
w
w
w
://
tp
ht

- 200 -
B-63823EN/02 5.IL INSTRUCTIONS

5.5.1 Logical AND

5.5.1.1 AND_BYTE(in1, in2)

accumulator ← in1 AND in2

/
om
Perform a logical AND between each bit of in1 and the same bit of in2. The corresponding bit of the
integer accumulator is set or cleared depending on the result.
Operands: Both in1 and in2 can be either a BYTE variable or constant.

s.c
5.5.1.2 AND_WORD(in1, in2)

accumulator ← in1 AND in2

re
Perform a logical AND between each bit of in1 and the same bit of in2. The corresponding bit of the
integer accumulator is set or cleared depending on the result.

5.5.1.3 AND_DWORD(in1, in2)


pa
Operands: Both in1 and in2 can be either a WORD variable or constant.
cs
accumulator ← in1 AND in2
Perform a logical AND between each bit of in1 and the same bit of in2. The corresponding bit of the
.cn

integer accumulator is set or cleared depending on the result.


Operands: Both in1 and in2 can be either a DWORD variable or constant.
w

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
://
tp
ht

- 201 -
5.IL INSTRUCTIONS B-63823EN/02

5.5.2 Logical OR

5.5.2.1 OR_BYTE(in1, in2)

accumulator ← in1 OR in2

/
om
Perform a logical OR between the bits of in1 and in2 and store the result in the integer
accumulator.
Operands: Both in1 and in2 can be either BYTE variables or constants.

s.c
5.5.2.2 OR_WORD(in1, in2)

accumulator ← in1 OR in2

re
Perform a logical OR between the bits of in1 and in2 and store the result in the integer
accumulator.

5.5.2.3 OR_DWORD(in1, in2)


pa
Operands: Both in1 and in2 can be either WORD variables or constants.
cs
accumulator ← in1 OR in2
Perform a logical OR between the bits of in1 and in2 and store the result in the integer
.cn

accumulator.
Operands: Both in1 and in2 can be either DWORD variables or constants.
w

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for
w

operands.
w
://
tp
ht

- 202 -
B-63823EN/02 5.IL INSTRUCTIONS

5.5.3 Logical XOR

5.5.3.1 XOR_BYTE(in1, in2)

accumulator ← in1 XOR in2

/
om
Perform a logical exclusive OR between the bits of in1 and in2 and store the result in the integer
accumulator.
Operands: Both in1 and in2 can be either BYTE variables or constants.

s.c
5.5.3.2 XOR_WORD(in1, in2)

accumulator ← in1 XOR in2

re
Perform a logical exclusive OR between the bits of in1 and in2 and store the result in the integer
accumulator.

5.5.3.3 XOR_DWORD(in1, in2)


pa
Operands: Both in1 and in2 can be either WORD variables or constants.
cs
accumulator ← in1 XOR in2
Perform a logical exclusive OR between the bits of in1 and in2 and store the result in the integer
.cn

accumulator.
Operands: Both in1 and in2 can be either DWORD variables or constants.
w

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for
w

operands.
w
://
tp
ht

- 203 -
5.IL INSTRUCTIONS B-63823EN/02

5.5.4 Logical NOT

5.5.4.1 NOT_BYTE(operand)

accumulator ← inverted operand

/
om
Invert every bit of the operand and store the result in the integer accumulator.
Operand: BYTE variable

5.5.4.2 NOT_WORD(operand)

s.c
accumulator ← inverted operand
Invert every bit of the operand and store the result in the integer accumulator.

re
Operand: WORD variable

5.5.4.3 NOT_DWORD(operand)

accumulator ← inverted operand


pa
Invert every bit of the operand and store the result in the integer accumulator.
cs
Operand: DWORD variable
.cn

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
w
://
tp
ht

- 204 -
B-63823EN/02 5.IL INSTRUCTIONS

5.5.5 Shift Bits

5.5.5.1 SHIFTL_BYTE(in, n, length, b1, q)

/
Shift the bits in a BYTE, or string of BYTEs, left by a specified number of positions.

om
in: BYTE variable; the first BYTE in a string of BYTEs.
n: INT variable or constant; the number of positions to rotate.
length: Constant; the number (1 to 256) of BYTEs in the string.
b1: BOOL variable; the bits to shift into the string.

s.c
q: BYTE variable; the first BYTE of the shifted string.

5.5.5.2 SHIFTL_WORD(in, n, length, b1, q)

re
Shift the bits in a word, or string of words, left by a specified number of positions.
in: WORD variable; the first word in a string of words.
pa
n: INT variable or constant; the number of positions to rotate.
length: Constant; the number (1 to 256) of words in the string.
cs
b1: BOOL variable; the bits to shift into the string.
q: WORD variable; the first word of the shifted string.
.cn

5.5.5.3 SHIFTL_DWORD(in, n, length, b1, q)

Shift the bits in a DWORD, or string of DWORDs, left by a specified number of positions.
w

in: DWORD variable; the first DWORD in a string of DWORDs.


n: INT variable or constant; the number of positions to rotate.
w

length: Constant; the number (1 to 256) of DWORDs in the string.


b1: BOOL variable; the bits to shift into the string.
w

q: DWORD variable; the first DWORD of the shifted string.

5.5.5.4 SHIFTR_BYTE(in, n, length, b1, q)


://

Shift the bits in a BYTE, or string of BYTEs, right by a specified number of positions.
tp

in: BYTE variable; the first BYTE in a string of BYTEs.


n: INT variable or constant; the number of positions to rotate.
ht

length: Constant; the number of BYTEs in the string (1 to 256).


b1: BOOL variable; the bits to shift into the string.
q: BYTE variable; the first BYTE of the shifted string.

- 205 -
5.IL INSTRUCTIONS B-63823EN/02

5.5.5.5 SHIFTR_WORD(in, n, length, b1, q)

Shift the bits in a word, or string of words, right by a specified number of positions.
in: WORD variable; the first word in a string of words.

/
n: INT variable or constant; the number of positions to rotate.

om
length: Constant; the number of words in the string (1 to 256).
b1: BOOL variable; the bits to shift into the string.
q: WORD variable; the first word of the shifted string.

s.c
5.5.5.6 SHIFTR_DWORD(in, n, length, b1, q)

Shift the bits in a DWORD, or string of DWORDs, right by a specified number of positions.

re
in: DWORD variable; the first DWORD in a string of DWORDs.
n: INT variable or constant; the number of positions to rotate.

b1: BOOL variable; the bits to shift into the string.


q: DWORD variable; the first DWORD of the shifted string.
pa
length: Constant; the number of DWORDs in the string (1 to 256).
cs
For more details, see LD Functions.
.cn

Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
w
://
tp
ht

- 206 -
B-63823EN/02 5.IL INSTRUCTIONS

5.5.6 Rotate Bits

5.5.6.1 ROL_BYTE(in, n, length, q)

Rotates the bits in a string of BYTEs n positions to the left. The most significant bit moves to the

/
om
least significant bit.
in: BYTE variable; the first BYTE in a string of BYTEs.
n: INT variable or constant; the number of positions to rotate
length: Constant; the number of BYTEs in the string (1 to 256).

s.c
q: BYTE variable; the first BYTE of the rotated string.

5.5.6.2 ROL_WORD(in, n, length, q)

re
Rotates the bits in a string of words n positions to the left. The most significant bit moves to the
least significant bit.
pa
in: WORD variable; the first word in a string of words.
n: INT variable or constant; the number of positions to rotate
cs
length: Constant; the number of words in the string (1 to 256).
q: WORD variable; the first word of the rotated string.
.cn

5.5.6.3 ROL_DWORD(in, n, length, q)

Rotates the bits in a string of DWORDs n positions to the left. The most significant bit moves to
w

the least significant bit.


in: DWORD variable; the first DWORD in a string of DWORDs.
w

n: INT variable or constant; the number of positions to rotate


length: Constant; the number of DWORDs in the string (1 to 256).
w

q: DWORD variable; the first DWORD of the rotated string.

5.5.6.4 ROR_BYTE(in, n, length, q)


://

Rotates the bits in a string of BYTEs n positions to the right. The least significant bit moves to the
tp

most significant bit.


in: BYTE variable; the first BYTE in a string of BYTEs.
ht

n: INT variable or constant; the number of positions to rotate.


length: Constant; the number of BYTEs in the string (1 to 256).
q: BYTE variable; the first BYTE of the rotated string.

- 207 -
5.IL INSTRUCTIONS B-63823EN/02

5.5.6.5 ROR_WORD(in, n, length, q)

Rotates the bits in a string of words n positions to the right. The least significant bit moves to the
most significant bit.

/
in: WORD variable; the first word in a string of words.

om
n: INT variable or constant; the number of positions to rotate.
length: Constant; the number of words in the string (1 to 256).
q: WORD variable; the first word of the rotated string.

s.c
5.5.6.6 ROR_DWORD(in, n, length, q)

Rotates the bits in a string of DWORDs n positions to the right. The least significant bit moves to

re
the most significant bit.
in: DWORD variable; the first DWORD in a string of DWORDs.
n: INT variable or constant; the number of positions to rotate.
pa
length: Constant; the number of DWORDs in the string (1 to 256).
q: DWORD variable; the first DWORD of the rotated string.
cs
For more details, see LD Functions.
.cn

Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
w
://
tp
ht

- 208 -
B-63823EN/02 5.IL INSTRUCTIONS

5.5.7 Bit Test

5.5.7.1 BIT_TEST_BYTE(in, bit, length)

/
accumulator ← bit state

om
Returns the state of a specific bit within a string of BYTEs (consecutive registers) to the boolean
accumulator.
in: BYTE variable; the first item in the data to be operated on.
bit: INT variable or constant; the bit number of in that will be set. 1 ≤ bit ≤ (8*length).

s.c
length: Constant; the number of BYTEs comprising the data string to operate on (1 to 255).

5.5.7.2 BIT_TEST_WORD(in, bit, length)

re
accumulator ← bit state

accumulator. pa
Returns the state of a specific bit within a string of words (consecutive registers) to the boolean

in: WORD variable; the first item in the data to be operated on.
cs
bit: INT variable or constant; the bit number of in that will be set. 1 ≤ bit ≤ (16*length).
length: Constant; the number of words comprising the data string to operate on (1 to 255).
.cn

5.5.7.3 BIT_TEST_DWORD(in, bit, length)

accumulator ← bit state


w

Returns the state of a specific bit within a string of DWORDs (consecutive registers) to the boolean
accumulator.
w

in: DWORD variable; the first item in the data to be operated on.
bit: INT variable or constant; the bit number of in that will be set. 1 ≤ bit ≤ (32*length).
w

length: Constant; the number of DWORDs comprising the data string to operate on (1 to 255).
://

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.
tp
ht

- 209 -
5.IL INSTRUCTIONS B-63823EN/02

5.5.8 Bit Set, Clear

5.5.8.1 BIT_SET_BYTE(in, bit, length)

/
Set a specific bit within a string (consecutive registers) of BYTEs by setting that bit to 1.

om
in: BYTE variable; the first item in the data to be operated on.
bit: INT variable or constant; the bit number of in that will be set. 1 ≤ bit ≤ (8*length).
length: Constant; the number of BYTEs comprising the data string to operate on (1 to 255).

s.c
5.5.8.2 BIT_SET_WORD(in, bit, length)

Set a specific bit within a string (consecutive registers) of words by setting that bit to 1.

re
in: WORD variable; the first item in the data to be operated on.
bit: INT variable or constant; the bit number of in that will be set. 1 ≤ bit ≤ (16*length).

5.5.8.3 BIT_SET_DWORD(in, bit, length)


pa
length: Constant; the number of words comprising the data string to operate on (1 to 255).
cs
Set a specific bit within a string (consecutive registers) of DWORDs by setting that bit to 1.
in: DWORD variable; the first item in the data to be operated on.
.cn

bit: INT variable or constant; the bit number of in that will be set. 1 ≤ bit ≤ (32*length).
length: Constant; the number of DWORDs comprising the data string to operate on (1 to 255).

5.5.8.4 BIT_CLR_BYTE(in, bit, length)


w

Clear a specific bit within a string (consecutive registers) of BYTEs by setting that bit to 0.
w

in: BYTE variable; the first item in the data to be operated on.
bit: INT variable or constant; the bit number of in that will be cleared. 1 ≤ bit ≤ (8*length).
w

length: Constant; the number (1 to 255) of BYTEs comprising the data string to operate on.
://

5.5.8.5 BIT_CLR_WORD(in, bit, length)

Clear a specific bit within a string (consecutive registers) of words by setting that bit to 0.
tp

in: WORD variable; the first item in the data to be operated on.
bit: INT variable or constant; the bit number of in that will be cleared. 1 ≤ bit ≤ (16*length).
ht

length: Constant; the number (1 to 255) of words comprising the data string to operate on.

- 210 -
B-63823EN/02 5.IL INSTRUCTIONS

5.5.8.6 BIT_CLR_DWORD(in, bit, length)

Clear a specific bit within a string (consecutive registers) of DWORDs by setting that bit to 0.
in: DWORD variable; the first item in the data to be operated on.

/
bit: INT variable or constant; the bit number of in that will be cleared. 1 ≤ bit ≤ (32*length).

om
length: Constant; the number (1 to 255) of DWORDs comprising the data string to operate on.

For more details, see LD Functions.

s.c
Note: IL and LD functions are generally the same, with some differences in data types for operands.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 211 -
5.IL INSTRUCTIONS B-63823EN/02

5.5.9 Bit Position

5.5.9.1 BIT_POS_BYTE(in, length)

/
accumulator ← bit number

om
Returns to the integer accumulator the bit number of the first bit found within a string of BYTEs
(consecutive registers) set to 1.
in: BYTE variable; the first data item in the string to be operated on.
length: Constant; the number (1 of 255) of BYTEs comprising the data string to operate on.

s.c
5.5.9.2 BIT_POS_WORD(in, length)

re
accumulator ← bit number
Returns to the integer accumulator the bit number of the first bit found within a string of words
(consecutive registers) set to 1.
pa
in: WORD variable; the first data item in the string to be operated on.
length: Constant; the number (1 of 255) of words comprising the data string to operate on.
cs
5.5.9.3 BIT_POS_DWORD(in, length)
.cn

accumulator ← bit number


Returns to the integer accumulator the bit number of the first bit found within a string of
DWORDs (consecutive registers) set to 1.
w

in: DWORD variable; the first data item in the string to be operated on.
length: Constant; the number (1 of 255) of DWORDs comprising the data string to operate on
w

For more details, see LD Functions.


w

Note: IL and LD functions are generally the same, with some differences in data types for operands.
://
tp
ht

- 212 -
B-63823EN/02 5.IL INSTRUCTIONS

5.5.10 Bit Sequencer

5.5.10.1 BIT_SEQ(address, r, dir, n, st, length)

/
acummulator ← latest sequence value

om
Sequences a string of bit values, starting at st.
address: WORD variable; the first of three control words for the BIT_SEQ function (word 1:current
step number, word 2: length of sequence in bits, word 3: control word).
r: BOOL variable; when r is true, the bit sequencer’s step number is set to the value in st (default

s.c
= 1), and the bit sequencer is filled with zeros, except for the current step number bit.
dir: BOOL variable; when dir is true, the bit sequencer’s step number is incremented prior to the
shift. Otherwise, it is decremented.

re
n: UINT, WORD variable or constant; when r is energized, the step number is set to this value
(Optional).
st: BYTE; the first word of the bit sequencer (Optional).
pa
length: Constant; the number of bits (starting at st) that this instruction will step through.
cs
Acceptable values range from 1-256.

For more details, see LD Functions.


.cn

Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
w
://
tp
ht

- 213 -
5.IL INSTRUCTIONS B-63823EN/02

5.5.11 Masked Compare

5.5.11.1 MASK_COMP_BYTE(in1, in2, m, bit, length, q, bn)

/
Compare the bits in two strings of BYTEs (consecutive registers). The compare starts at the bit

om
number bit and continues until a mismatch is found. When a mismatch is found the corresponding
bit of m is set and then q is updated with the value of m.
in1: BYTE variable; the first data item in a string of BYTES.
in2: BYTE variable; the first data item in another string of BYTES.

s.c
m: BYTE variable; the mask containing the ongoing status of the compare.
bit: UINT variable or constant; the bit number where the compare begins.
length: Constant; the number (1 to 8192) of BYTEs in either compared string.

re
q: BYTE variable; the output copy of the compare mask.
bn: UINT variable; the number of the bit where the latest miscompare occurred.

pa
5.5.11.2 MASK_COMP_WORD(in1, in2, m, bit, length, q, bn)
cs
Compare the bits in two strings of words (consecutive registers). The compare starts at the bit
number bit and continues until a mismatch is found. When a mismatch is found the corresponding
.cn

bit of m is set and then q is updated with the value of m.


in1: WORD variable; the first data item in a string of WORDS.
in2: WORD variable; the first data item in another string of WORDS.
w

m: WORD variable; the mask containing the ongoing status of the compare.
bit: UINT variable or constant; the bit number where the compare begins.
w

length: Constant; the number (1 to 4096) of WORDs in either compared string.


q: WORD variable; the output copy of the compare mask.
w

bn: UINT variable; the number of the bit where the latest miscompare occurred.
://
tp
ht

- 214 -
B-63823EN/02 5.IL INSTRUCTIONS

5.5.11.3 MASK_COMP_DWORD(in1, in2, m, bit, length, q, bn)

Compare the bits in two strings of DWORDS (consecutive registers). The compare starts at the bit
number bit and continues until a mismatch is found. When a mismatch is found the corresponding

/
bit of m is set and then q is updated with the value of m.

om
in1: DWORD variable; the first data item in a string of DWORDS.
in2: DWORD variable; the first data item in another string of DWORDS.
m: DWORD variable; the mask containing the ongoing status of the compare.

s.c
bit: UINT variable or constant; the bit number where the compare begins.
length: Constant; the number (1 to 2048) of DWORDs in either compared string.
q: DWORD variable; the output copy of the compare mask.

re
bn: UINT variable; the number of the bit where the latest miscompare occurred.

For more details, see LD Functions.


pa
Note: IL and LD functions are generally the same, with some differences in data types for operands.
cs
.cn
w
w
w
://
tp
ht

- 215 -
5.IL INSTRUCTIONS B-63823EN/02

5.6 IL DATA MOVE FUNCTIONS

Data Move Functions


Use these IL functions to transfer data between various memory

/
locations from instruction list logic.

om
Move Data
Swap Data
Block Clear
Shift Register

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 216 -
B-63823EN/02 5.IL INSTRUCTIONS

5.6.1 Move Data

5.6.1.1 MOVE_SINT(in, length, q)

/
Move a block of SINT data from one location in PMC memory to another.

om
in: SINT variable; the location of the first source data item.
length: Constant; the number of data items to move (1 - 256).
q: SINT variable; the location of the first destination data item.

s.c
5.6.1.2 MOVE_USINT(in, length, q)

Move a block of USINT data from one location in PMC memory to another.

re
in: USINT variable; the location of the first source data item.
length: Constant; the number of data items to move (1 - 256).

5.6.1.3 MOVE_INT(in, length, q)


pa
q: USINT variable; the location of the first destination data item.
cs
Move a block of INT data from one location in PMC memory to another.
in: INT variable; the location of the first source data item.
.cn

length: Constant; the number of data items to move (1 - 256).


q: INT variable; the location of the first destination data item.

5.6.1.4 MOVE_UINT(in, length, q)


w

Move a block of UINT data from one location in PMC memory to another.
w

in: UINT variable; the location of the first source data item.
length: Constant; the number of data items to move (1 - 256).
w

q: UINT variable; the location of the first destination data item.


://

5.6.1.5 MOVE_DINT(in, length, q)

Move a block of DINT data from one location in PMC memory to another.
tp

in: DINT variable; the location of the first source data item.
length: Constant; the number of data items to move (1 - 256).
ht

q: DINT variable; the location of the first destination data item.

- 217 -
5.IL INSTRUCTIONS B-63823EN/02

5.6.1.6 MOVE_UDINT(in, length, q)

Move a block of UDINT data from one location in PMC memory to another.
in: UDINT variable; the location of the first source data item.

/
length: Constant; the number of data items to move (1 - 256).

om
q: UDINT variable; the location of the first destination data item.

5.6.1.7 MOVE_BOOL(in, length, q)

s.c
Move a block of boolean data from one location in PMC memory to another.
in: BOOL variable; the location of the first source data item.
length: Constant; the number of data items to move.

re
q: BOOL variable; the location of the first destination data item.

5.6.1.8 MOVE_BYTE(in, length, q)


pa
Move a block of BYTE data from one location in PMC memory to another.
cs
in: BYTE variable; the location of the first source data item.
length: Constant; the number of data items to move (1 - 256).
q: BYTE variable; the location of the first destination data item.
.cn

5.6.1.9 MOVE_WORD(in, length, q)


w

Move a block of WORD data from one location in PMC memory to another.
in: WORD variable; the location of the first source data item.
w

length: Constant; the number of data items to move (1 - 256).


q: WORD variable; the location of the first destination data item.
w

5.6.1.10 MOVE_DWORD(in, length, q)


://

Move a block of DWORD data from one location in PMC memory to another.
in: DWORD variable; the location of the first source data item.
tp

length: Constant; the number of data items to move (1 - 256).


q: DWORD variable; the location of the first destination data item.
ht

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for
operands.

- 218 -
B-63823EN/02 5.IL INSTRUCTIONS

5.6.2 Swap Data

5.6.2.1 SWAP_WORD(in, length, q)

/
Swap a block of WORD data from one location in PMC memory to another.

om
in: WORD variable; the location of the first source data item.
length: Constant; the number of data items to move (1 - 256).
q: WORD variable; the location of the first destination data item.

s.c
5.6.2.2 SWAP_DWORD(in, length, q)

Swap a block of DWORD data from one location in PMC memory to another.

re
in: DWORD variable; the location of the first source data item.
length: Constant; the number of data items to move (1 - 256).

pa
q: DWORD variable; the location of the first destination data item.
cs
.cn
w
w
w
://
tp
ht

- 219 -
5.IL INSTRUCTIONS B-63823EN/02

5.6.3 Block Clear

5.6.3.1 BLK_CLR_SINT(in, length)

/
Clear a block of memory to 0.

om
in: SINT variable; starting location of memory block to be cleared. The length field for this variable
must be between 1 and 256 words.
length: Constant; the number of words (starting at in) that will be cleared. Acceptable values
range from 1-256.

s.c
5.6.3.2 BLK_CLR_USINT(in, length)

re
Clear a block of memory to 0.
in: USINT variable; starting location of memory block to be cleared. The length field for this
variable must be between 1 and 256 words.
pa
length: Constant; the number of words (starting at in) that will be cleared. Acceptable values
range from 1-256.
cs
5.6.3.3 BLK_CLR_INT(in, length)
.cn

Clear a block of memory to 0.


in: INT variable; starting location of memory block to be cleared. The length field for this variable
must be between 1 and 256 words.
w

length: Constant; the number of words (starting at in) that will be cleared. Acceptable values
range from 1-256.
w

5.6.3.4 BLK_CLR_UINT(in, length)


w

Clear a block of memory to 0.


in: UINT variable; starting location of memory block to be cleared. The length field for this
://

variable must be between 1 and 256 words.


length: Constant; the number of words (starting at in) that will be cleared. Acceptable values
tp

range from 1-256.


ht

- 220 -
B-63823EN/02 5.IL INSTRUCTIONS

5.6.3.5 BLK_CLR_DINT(in, length)

Clear a block of memory to 0.


in: DINT variable; starting location of memory block to be cleared. The length field for this

/
variable must be between 1 and 256 words.

om
length: Constant; the number of words (starting at in) that will be cleared. Acceptable values
range from 1-256.

5.6.3.6 BLK_CLR_UDINT(in, length)

s.c
Clear a block of memory to 0.
in: UDINT variable; starting location of memory block to be cleared. The length field for this

re
variable must be between 1 and 256 words.
length: Constant; the number of words (starting at in) that will be cleared. Acceptable values
range from 1-256.

5.6.3.7 BLK_CLR_BYTE(in, length)


pa
cs
Clear a block of memory to 0.
in: BYTE variable; starting location of memory block to be cleared. The length field for this
.cn

variable must be between 1 and 256 words.


length: Constant; the number of words (starting at in) that will be cleared. Acceptable values
range from 1-256.
w

5.6.3.8 BLK_CLR_WORD(in, length)


w

Clear a block of memory to 0.


w

in: WORD variable; starting location of memory block to be cleared. The length field for this
variable must be between 1 and 256 words.
://

length: Constant; the number of words (starting at in) that will be cleared. Acceptable values
range from 1-256.
tp
ht

- 221 -
5.IL INSTRUCTIONS B-63823EN/02

5.6.3.9 BLK_CLR_DWORD(in, length)

Clear a block of memory to 0.


in: DWORD variable; starting location of memory block to be cleared. The length field for this

/
variable must be between 1 and 256 words.

om
length: Constant; the number of words (starting at in) that will be cleared. Acceptable values
range from 1-256.

s.c
For more details, see LD Functions.
Note: IL and LD functions are generally the same, with some differences in data types for operands.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 222 -
B-63823EN/02 5.IL INSTRUCTIONS

5.6.4 Shift Register

5.6.4.1 SHFR_BIT(r, in, st, length, q)

/
If the Boolean Accumulator is set to ON (the transition state does not matter), SHFR_BIT shifts

om
the content in a block of BOOL memory from one register to the next. The contiguous "length"
number of bits starting at section of memory "st" serves as a shift register.
r: BOOL variable; when true (ON), the shift register is filled with zeroes (is set to false, OFF).
in: BOOL, WORD variable or constant; the bit value to be shifted into the shift register. Only the

s.c
first bit of a WORD is used.
st: BOOL, WORD variable; the address of the first bit of the shift register.
length: Constant; the number (1 - 256) of bits in the shift register.

re
q: BOOL, INT, WORD variable; the value of the bit shifted out of the shift register. If q is a WORD
variable, only the first bit is used.

5.6.4.2 SHFR_BYTE(r, in, st, length, q) pa


cs
Shift the content in a block of BYTE memory, from one register to the next. The contiguous section
of memory serves as a shift register.
.cn

r: BOOL variable; when True the shift register is filled with zeroes.
in: BYTE variable or constant; the value to be shifted into the shift register.
st: BYTE variable; the first element of the shift register.
w

length: Constant; the number (1 - 256) of elements in the shift register.


q: BYTE variable; the value shifted out of the shift register.
w

5.6.4.3 SHFR_WORD(r, in, st, length, q)


w

Shift the content in a block of WORD memory, from one register to the next. The contiguous
section of memory serves as a shift register.
://

r: BOOL variable; when True the shift register is filled with zeroes.
in: WORD variable or constant; the value to be shifted into the shift register.
tp

st: WORD variable; the first element of the shift register.


length: Constant; the number (1 - 256) of elements in the shift register.
ht

q: WORD variable; the value shifted out of the shift register.

- 223 -
5.IL INSTRUCTIONS B-63823EN/02

5.6.4.4 SHFR_DWORD(r, in, st, length, q)

Shift the content in a block of double WORD memory, from one register to the next. The
contiguous section of memory serves as a shift register.

/
r: BOOL variable; when True the shift register is filled with zeroes.

om
in: DWORD variable or constant; the value to be shifted into the shift register.
st: DWORD variable; the first element of the shift register.
length: Constant; the number (1 - 256) of elements in the shift register.

s.c
q: DWORD variable; the value shifted out of the shift register.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 224 -
B-63823EN/02 5.IL INSTRUCTIONS

5.7 IL DATA TABLE FUNCTIONS

Data Table Functions


Use these IL functions to copy a specified number of data elements

/
from a source array to a destination array.

om
Array Move
Search for values in a Memory Block

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 225 -
5.IL INSTRUCTIONS B-63823EN/02

5.7.1 Array Move

5.7.1.1 ARRAY_MOVE_SINT(sr, snx, dnx, n, length, ds)

When the function receives power flow, the number of data elements in the count indicator 'n' is

/
om
extracted from the input array starting with the indexed location ('sr' + 'snx' – 1). The data
elements are written to the output array starting with the indexed location ('ds' + 'dnx' – 1).
sr: SINT variable; the first element of the source array.
snx: UINT, variable or constant; the index into the source array.

s.c
dnx: UINT, variable or constant; the index into the destination array.
n: UINT, variable or constant; count indicator.
ds: SINT variable; the first element of the destination array.

re
length: Constant; the number (1 - 32767) of elements (starting at 'sr' and 'ds') that make up each
array.

5.7.1.2 pa
ARRAY_MOVE_USINT(sr, snx, dnx, n, length, ds)
cs
When the function receives power flow, the number of data elements in the count indicator 'n' is
extracted from the input array starting with the indexed location ('sr' + 'snx' – 1). The data
.cn

elements are written to the output array starting with the indexed location ('ds' + 'dnx' – 1).
sr: USINT variable; the first element of the source array.
snx: UINT, variable or constant; the index into the source array.
w

dnx: UINT, variable or constant; the index into the destination array.
n: UINT, variable or constant; count indicator.
w

ds: USINT variable; the first element of the destination array.


length: Constant; the number (1 - 32767) of elements (starting at 'sr' and 'ds') that make up each
w

array.
://
tp
ht

- 226 -
B-63823EN/02 5.IL INSTRUCTIONS

5.7.1.3 ARRAY_MOVE_INT(sr, snx, dnx, n, length, ds)

When the function receives power flow, the number of data elements in the count indicator 'n' is
extracted from the input array starting with the indexed location ('sr' + 'snx' – 1). The data

/
elements are written to the output array starting with the indexed location ('ds' + 'dnx' – 1).

om
sr: INT variable; the first element of the source array.
snx: UINT, variable or constant; the index into the source array.
dnx: UINT, variable or constant; the index into the destination array.

s.c
n: UINT, variable or constant; count indicator.
ds: INT variable; the first element of the destination array.
length: Constant; the number (1 - 32767) of elements (starting at 'sr' and 'ds') that make up each

re
array.

5.7.1.4 ARRAY_MOVE_UINT(sr, snx, dnx, n, length, ds)


pa
When the function receives power flow, the number of data elements in the count indicator 'n' is
extracted from the input array starting with the indexed location ('sr' + 'snx' – 1). The data
cs
elements are written to the output array starting with the indexed location ('ds' + 'dnx' – 1).
sr: UINT variable; the first element of the source array.
.cn

snx: UINT, variable or constant; the index into the source array.
dnx: UINT, variable or constant; the index into the destination array.
n: UINT, variable or constant; count indicator.
w

ds: UINT variable; the first element of the destination array.


length: Constant; the number (1 - 32767) of elements (starting at 'sr' and 'ds') that make up each
w

array.

5.7.1.5 ARRAY_MOVE_DINT(sr, snx, dnx, n, length, ds)


w

When the function receives power flow, the number of data elements in the count indicator 'n' is
://

extracted from the input array starting with the indexed location ('sr' + 'snx' – 1). The data
elements are written to the output array starting with the indexed location ('ds' + 'dnx' – 1).
tp

sr: DINT variable; the first element of the source array.


snx: UINT, variable or constant; the index into the source array.
ht

dnx: UINT, variable or constant; the index into the destination array.
n: UINT, variable or constant; count indicator.
ds: DINT variable; the first element of the destination array.
length: Constant; the number (1 - 32767) of elements (starting at 'sr' and 'ds') that make up each
array.

- 227 -
5.IL INSTRUCTIONS B-63823EN/02

5.7.1.6 ARRAY_MOVE_UDINT(sr, snx, dnx, n, length, ds)

When the function receives power flow, the number of data elements in the count indicator 'n' is
extracted from the input array starting with the indexed location ('sr' + 'snx' – 1). The data

/
elements are written to the output array starting with the indexed location ('ds' + 'dnx' – 1).

om
sr: UDINT variable; the first element of the source array.
snx: UINT, variable or constant; the index into the source array.
dnx: UINT, variable or constant; the index into the destination array.

s.c
n: UINT, variable or constant; count indicator.
ds: UDINT variable; the first element of the destination array.
length: Constant; the number (1 - 32767) of elements (starting at 'sr' and 'ds') that make up each

re
array.

5.7.1.7 ARRAY_MOVE_BOOL(sr, snx, dnx, n, length, ds)


pa
When the function receives power flow, the number of data elements in the count indicator 'n' is
extracted from the input array starting with the indexed location ('sr' + 'snx' – 1). The data
cs
elements are written to the output array starting with the indexed location ('ds' + 'dnx' – 1).
sr: BOOL, variable; the first element of the source array. For an Array Move with the data type
.cn

BOOL, any reference may be used; it does not need to be byte aligned.
snx: UINT, variable or constant; the index into the source array.
dnx: UINT, variable or constant; the index into the destination array.
w

n: UINT, variable or constant; count indicator.


ds: BOOL, variable; the first element of the destination array. For an Array Move with the data
w

type BOOL, any reference may be used. It does not need to be byte aligned.
length: Constant; the number (1 - 32767) of elements (starting at 'sr' and 'ds') that make up each
w

array.
://
tp
ht

- 228 -
B-63823EN/02 5.IL INSTRUCTIONS

5.7.1.8 ARRAY_MOVE_BYTE(sr, snx, dnx, n, length, ds)

When the function receives power flow, the number of data elements in the count indicator 'n' is
extracted from the input array starting with the indexed location ('sr' + 'snx' – 1). The data

/
elements are written to the output array starting with the indexed location ('ds' + 'dnx' – 1).

om
sr: BYTE variable; the first element of the source array.
snx: UINT, variable or constant; the index into the source array.
dnx: UINT, variable or constant; the index into the destination array.

s.c
n: UINT, variable or constant; count indicator.
ds: BYTE variable; the first element of the destination array.
length: Constant; the number (1 - 32767) of elements (starting at 'sr' and 'ds') that make up each

re
array.

5.7.1.9 ARRAY_MOVE_WORD(sr, snx, dnx, n, length, ds)


pa
When the function receives power flow, the number of data elements in the count indicator 'n' is
extracted from the input array starting with the indexed location ('sr' + 'snx' – 1). The data
cs
elements are written to the output array starting with the indexed location ('ds' + 'dnx' – 1).
sr: WORD variable; the first element of the source array.
.cn

snx: UINT, variable or constant; the index into the source array.
dnx: UINT, variable or constant; the index into the destination array.
n: UINT, variable or constant; count indicator.
w

ds: WORD variable; the first element of the destination array.


length: Constant; the number (1 - 32767) of elements (starting at 'sr' and 'ds') that make up each
w

array.
w
://
tp
ht

- 229 -
5.IL INSTRUCTIONS B-63823EN/02

5.7.1.10 ARRAY_MOVE_DWORD(sr, snx, dnx, n, length, ds)

When the function receives power flow, the number of data elements in the count indicator 'n' is
extracted from the input array starting with the indexed location ('sr' + 'snx' – 1). The data

/
elements are written to the output array starting with the indexed location ('ds' + 'dnx' – 1).

om
sr: DWORD variable; the first element of the source array.
snx: UINT, variable or constant; the index into the source array.
dnx: UINT, variable or constant; the index into the destination array.

s.c
n: UINT, variable or constant; count indicator.
ds: DWORD variable; the first element of the destination array.
length: Constant; the number (1 - 32767) of elements (starting at 'sr' and 'ds') that make up each

re
array.

For more details, see LD Functions.


pa
Note: IL and LD functions are generally the same, with some differences in data types for operands.
cs
.cn
w
w
w
://
tp
ht

- 230 -
B-63823EN/02 5.IL INSTRUCTIONS

5.7.2 Search for Values in a Memory Block

5.7.2.1 Mnemonics
The Search function supports 56 mnemonics:

/
Mnemonic Description

om
SEARCH_EQ_BOOL Searches memory block for all values equal to a specified value.
SEARCH_EQ_BYTE
SEARCH_EQ_WORD
SEARCH_EQ_DWORD
SEARCH_EQ_SINT

s.c
SEARCH_EQ_USINT
SEARCH_EQ_INT
SEARCH_EQ_UINT
SEARCH_EQ_DINT

re
SEARCH_EQ_UDINT
SEARCH_NE_BOOL Searches memory block for all values not equal to a specified value.
SEARCH_NE_BYTE
SEARCH_NE_WORD
SEARCH_NE_DWORD
SEARCH_NE_SINT
SEARCH_NE_USINT
pa
cs
SEARCH_NE_INT
SEARCH_NE_UINT
SEARCH_NE_DINT
SEARCH_NE_UDINT
.cn

SEARCH_GT_BYTE Searches memory block for all values greater than a specified value.
SEARCH_GT_WORD
SEARCH_GT_DWORD
SEARCH_GT_SINT
w

SEARCH_GT_USINT
SEARCH_GT_INT
SEARCH_GT_UINT
w

SEARCH_GT_DINT
SEARCH_GT_UDINT
SEARCH_GE_BYTE Searches memory block for all values greater than or equal to a specified value
w

SEARCH_GE_WORD
SEARCH_GE_DWORD
SEARCH_GE_SINT
://

SEARCH_GE_USINT
SEARCH_GE_INT
SEARCH_GE_UINT
SEARCH_GE_DINT
tp

SEARCH_GE_UDINT
SEARCH_LT_BYTE Searches memory block for all values less than a specified value.
SEARCH_LT_WORD
ht

SEARCH_LT_DWORD
SEARCH_LT_SINT
SEARCH_LT_USINT
SEARCH_LT_INT
SEARCH_LT_UINT
SEARCH_LT_DINT
SEARCH_LT_UDINT

- 231 -
5.IL INSTRUCTIONS B-63823EN/02

Mnemonic Description
SEARCH_LE_BYTE Searches memory block for all values less than or equal to a specified value.
SEARCH_LE_WORD
SEARCH_LE_DWORD
SEARCH_LE_SINT
SEARCH_LE_USINT

/
SEARCH_LE_INT

om
SEARCH_LE_UINT
SEARCH_LE_DINT
SEARCH_LE_UDINT

5.7.2.2 Operation

s.c
The Search function searches the specified memory block for a value. Searching begins at ar+inx,
where ar is the starting address and inx is the index value into the memory block. The search

re
continues either until a register equal to the search object (in) is found or until the end of the
memory block is reached.

pa
If a register is found, the boolean accumulator is set ON and the Output Index (onx) is set to the
relative position of this register within the block.
cs
If no register is found before the end of the block is reached, the boolean accumulator is set OFF
and onx is set to zero.
inx is zero-based, that is, 0 the means first reference, whereas onx is one-based, that is, 1 means
.cn

the first reference.


The valid values for inx are 0 to (length - 1). The valid values for onx are 1 to length.
inx should be set to zero to begin searching at the memory block's first register. This value
w

increments by one at the time of execution. If the value of inx is out-of-range, (< 0 or > length-1),
inx is set to the default value of zero.
w
w
://
tp
ht

- 232 -
B-63823EN/02 5.IL INSTRUCTIONS

5.7.2.3 Operands

Operand Data Type Memory Area Description


Length Constant The number of registers starting at ar that make
up the memory block to search. 1 ≤ ?? ≤ 32767.

/
ar (must be the same BOOL %I*, %Q*,%M*,%S* The starting address of the memory block to

om
data type as in) search; the address of the first register in the
BYTE %I*, %Q*,%M*,%S*,%R memory block.
WORD %I*, %Q*,%M*,%S*,%R

DWORD %I*, %Q*,%M*,%S*,%R

s.c
SINT %I*, %Q*,%M*,%S*,%R
USINT %I*, %Q*,%M*,%S*,%R
INT %I*, %Q*,%M*,%S*,%R

re
UINT %I*, %Q*,%M*,%S*,%R
DINT %I*, %Q*,%M*,%S*,%R

Inx
UDINT
UINT variable or
constant
pa
%I*, %Q*,%M*,%S*,%R
%I*, %Q*,%M*,%S*,%R The zero-based index into the memory block at
which to begin the search. Zero points to the
first reference. Valid range: 0 ≤ inx ≤
cs
(length-1). If inx is out of range, it is set to the
default value of 0.
in (must be the same BOOL variable or %I*, %Q*,%M*,%S* The object of the search; the value to search
.cn

data type as ar) constant for.

BYTE variable or %I*, %Q*,%M*,%S*,%R


constant
w

WORD variable %I*, %Q*,%M*,%S*,%R


or constant
w

DWORD variable %I*, %Q*,%M*,%S*,%R


or constant
w

SINT variable or %I*, %Q*,%M*,%S*,%R


constant

USINT variable or %I*, %Q*,%M*,%S*,%R


://

constant
INT variable or %I*, %Q*,%M*,%S*,%R
constant
tp

UINT variable or %I*, %Q*,%M*,%S*,%R


constant
ht

DINT variable or %I*, %Q*,%M*,%S*,%R


constant
UDINT variable %I*, %Q*,%M*,%S*,%R
or constant
onx UINT variable %I*, %Q*,%M*,%S*,%R The one-based position within the memory
block of the search target. A value of 1 points
to the first reference. Valid range: 1 ≤ onx ≤
length.

- 233 -
5.IL INSTRUCTIONS B-63823EN/02

5.8 IL CONVERSIONS

Conversion Functions
Use these IL functions to convert data types, number formats and units

/
in instruction list logic.

om
(type)_TO_BCDx(x=2,4,8)
BCDx_TO_(type)(x=2,4,8)
(type)_TO_SINT
(type)_TO_USINT
(type)_TO_INT

s.c
(type)_TO_UINT
(type)_TO_DINT
(type)_TO_UDINT

re
pa
cs
.cn
w
w
w
://
tp
ht

- 234 -
B-63823EN/02 5.IL INSTRUCTIONS

5.8.1 (type)_TO_BCDx(x=2,4,8)

5.8.1.1 SINT_TO_BCD2(operand)

/
accumulator ← converted value

om
Convert a short integer to binary coded decimal format.
Operand: SINT variable; the value to be converted.

5.8.1.2 USINT_TO_BCD2(operand)

s.c
accumulator ← converted value
Convert an unsigned short integer to binary coded decimal format.

re
Operand: USINT variable; the value to be converted.

5.8.1.3 INT_TO_BCD4(operand)

accumulator ← converted value


pa
Convert a single-precision integer to binary coded decimal format.
cs
Operand: INT variable; the value to be converted.

5.8.1.4
.cn

UINT_TO_BCD4(operand)

accumulator ← converted value


Convert a single-precision unsigned integer to binary coded decimal format.
w

Operand: UINT variable; the value to be converted.


w

5.8.1.5 DINT_TO_BCD8(operand)
w

accumulator ← converted value


Convert a double-precision integer to binary coded decimal format.
://

Operand: DINT variable; the value to be converted.

5.8.1.6 UDINT_TO_BCD8(operand)
tp

accumulator ← converted value


ht

Convert a double-precision unsigned integer to binary coded decimal format.


Operand: UDINT variable; the value to be converted.

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.

- 235 -
5.IL INSTRUCTIONS B-63823EN/02

5.8.2 BCDx_TO_(type)(x=2,4,8)

5.8.2.1 BCD2_TO_SINT(operand)

/
accumulator ← converted value

om
Convert a binary coded decimal value to a short integer value and store the result in the integer
accumulator.
Operand: BYTE variable; the BCD value for conversion.

s.c
5.8.2.2 BCD2_TO_USINT(operand)

accumulator ← converted value

re
Convert a binary coded decimal value to an unsigned short integer value and store the result in
the integer accumulator.
Operand: BYTE variable; the BCD value for conversion.

5.8.2.3 BCD4_TO_INT(operand)
pa
cs
accumulator ← converted value
Convert a binary coded decimal value to a single-precision integer value and store the result in the
.cn

integer accumulator.
Operand: WORD variable; the BCD value for conversion.

5.8.2.4 BCD4_TO_UINT(operand)
w

accumulator ← converted value


w

Convert a binary coded decimal value to a single-precision unsigned integer value and store the
result in the integer accumulator.
w

Operand: WORD variable; the BCD value for conversion.


://

5.8.2.5 BCD8_TO_DINT(operand)

accumulator ← converted value


tp

Convert a binary coded decimal value to a double-precision integer value and store the result in
the integer accumulator.
ht

Operand: DWORD variable; the BCD value for conversion.

- 236 -
B-63823EN/02 5.IL INSTRUCTIONS

5.8.2.6 BCD8_TO_UDINT(operand)

accumulator ← converted value


Convert a binary coded decimal value to a double-precision unsigned integer value and store the

/
result in the integer accumulator.

om
Operand: DWORD variable; the BCD value for conversion.

For more details, see LD Functions.

s.c
Note: IL and LD functions are generally the same, with some differences in data types for operands.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 237 -
5.IL INSTRUCTIONS B-63823EN/02

5.8.3 (type)_TO_SINT

5.8.3.1 USINT_TO_SINT(operand)

/
accumulator ← converted value

om
Convert an unsigned short integer value to a short integer value and store the result in the integer
accumulator.
Operand: USINT variable;

s.c
5.8.3.2 INT_TO_SINT(operand)

accumulator ← converted value

re
Convert a single-precisio integer value to a short integer value and store the result in the integer
accumulator.
Operand: INT variable;

5.8.3.3 UINT_TO_SINT(operand)
pa
cs
accumulator ← converted value
Convert a single-precision unsigned integer value to a short integer value and store the result in
.cn

the integer accumulator.


Operand: UINT variable;

5.8.3.4 DINT_TO_SINT(operand)
w

accumulator ← converted value


w

Convert a double-precision integer value to a short integer value and store the result in the integer
accumulator.
w

Operand: DINT variable;


://

5.8.3.5 UDINT_TO_SINT(operand)

accumulator ← converted value


tp

Convert a double-precision unsigned integer value to a short integer value and store the result in
the integer accumulator.
ht

Operand: UDINT variable;

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.

- 238 -
B-63823EN/02 5.IL INSTRUCTIONS

5.8.4 (type)_TO_USINT

5.8.4.1 SINT_TO_USINT(operand)

/
accumulator ← converted value

om
Convert a short integer value to an unsigned short integer value and store the result in the integer
accumulator.
Operand: SINT variable;

s.c
5.8.4.2 INT_TO_USINT(operand)

accumulator ← converted value

re
Convert a single-precision integer value to an unsigned short integer value and store the result in
the integer accumulator.
Operand: INT variable;

5.8.4.3 UINT_TO_USINT(operand)
pa
cs
accumulator ← converted value
Convert a single-precision unsigned integer value to an unsigned short integer value and store the
.cn

result in the integer accumulator.


Operand: UINT variable;

5.8.4.4 DINT_TO_USINT(operand)
w

accumulator ← converted value


w

Convert a double-precision integer value to an unsigned short integer value and store the result in
the integer accumulator.
w

Operand: DINT variable;


://

5.8.4.5 UDINT_TO_USINT(operand)

accumulator ← converted value


tp

Convert a double-precision unsigned integer value to an unsigned short integer value and store the
result in the integer accumulator.
ht

Operand: UDINT variable;

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.

- 239 -
5.IL INSTRUCTIONS B-63823EN/02

5.8.5 (type)_TO_INT

5.8.5.1 SINT_TO_INT(operand)

/
accumulator ← converted value

om
Convert a short integer value to a single-precision integer value and store the result in the integer
accumulator.
Operand: SINT variable;

s.c
5.8.5.2 USINT_TO_INT(operand)

accumulator ← converted value

re
Convert an unsigned short integer value to a single-precision integer value and store the result in
the integer accumulator.
Operand: USINT variable;

5.8.5.3 UINT_TO_INT(operand)
pa
cs
accumulator ← converted value
Convert a single-precision unsigned integer value to a single-precision integer value and store the
.cn

result in the integer accumulator.


Operand: UINT variable;

5.8.5.4 DINT_TO_INT(operand)
w

accumulator ← converted value


w

Convert a double-precision integer value to a single-precision integer value and store the result in
the integer accumulator.
w

Operand: DINT variable;


://

5.8.5.5 UDINT_TO_INT(operand)

accumulator ← converted value


tp

Convert a double-precision unsigned integer value to a single-precision integer value and store the
result in the integer accumulator.
ht

Operand: UDINT variable;

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.

- 240 -
B-63823EN/02 5.IL INSTRUCTIONS

5.8.6 (type)_TO_UINT

5.8.6.1 SINT_TO_UINT(operand)

/
accumulator ← converted value

om
Convert a short integer value to a single-precision unsigned integer value and store the result in
the integer accumulator.
Operand: SINT variable;

s.c
5.8.6.2 USINT_TO_UINT(operand)

accumulator ← converted value

re
Convert an unsigned short integer value to a single-precision unsigned integer value and store the
result in the integer accumulator.
Operand: USINT variable;

5.8.6.3 INT_TO_UINT(operand)
pa
cs
accumulator ← converted value
Convert a single-precision integer value to a single-precision unsigned integer value and store the
.cn

result in the integer accumulator.


Operand: INT variable;

5.8.6.4 DINT_TO_UINT(operand)
w

accumulator ← converted value


w

Convert a double-precision integer value to a single-precision unsigned integer value and store the
result in the integer accumulator.
w

Operand: DINT variable;


://

5.8.6.5 UDINT_TO_UINT(operand)

accumulator ← converted value


tp

Convert a double-precision unsigned integer value to a single-precision unsigned integer value and
store the result in the integer accumulator.
ht

Operand: UDINT variable;

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.

- 241 -
5.IL INSTRUCTIONS B-63823EN/02

5.8.7 (type)_TO_DINT

5.8.7.1 SINT_TO_DINT(operand)

/
accumulator ← converted value

om
Convert a short integer value to a double-precision integer value and store the result in the integer
accumulator.
Operand: SINT variable;

s.c
5.8.7.2 USINT_TO_DINT(operand)

accumulator ← converted value

re
Convert an unsigned short integer value to a double-precision integer value and store the result in
the integer accumulator.
Operand: USINT variable;

5.8.7.3 INT_TO_DINT(operand)
pa
cs
accumulator ← converted value
Convert a single-precision integer value to a double-precision integer value and store the result in
.cn

the integer accumulator.


Operand: INT variable;

5.8.7.4 UINT_TO_DINT(operand)
w

accumulator ← converted value


w

Convert a single-precision unsigned integer value to a double-precision integer value and store the
result in the integer accumulator.
w

Operand: UINT variable;


://

5.8.7.5 UDINT_TO_DINT(operand)

accumulator ← converted value


tp

Convert a double-precision unsigned integer value to a double-precision integer value and store the
result in the integer accumulator.
ht

Operand: UDINT variable;

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.

- 242 -
B-63823EN/02 5.IL INSTRUCTIONS

5.8.8 (type)_TO_UDINT

5.8.8.1 SINT_TO_UDINT(operand)

/
accumulator ← converted value

om
Convert a short integer value to a double-precision unsigned integer value and store the result in
the integer accumulator.
Operand: SINT variable;

s.c
5.8.8.2 USINT_TO_UDINT(operand)

accumulator ← converted value

re
Convert an unsigned short integer value to a double-precision unsigned integer value and store the
result in the integer accumulator.
Operand: USINT variable;

5.8.8.3 INT_TO_UDINT(operand)
pa
cs
accumulator ← converted value
Convert a single-precision integer value to a double-precision unsigned integer value and store the
.cn

result in the integer accumulator.


Operand: INT variable;

5.8.8.4 UINT_TO_UDINT(operand)
w

accumulator ← converted value


w

Convert a single-precision unsigned integer value to a double-precision unsigned integer value and
store the result in the integer accumulator.
w

Operand: UINT variable;


://

5.8.8.5 DINT_TO_UDINT(operand)

accumulator ← converted value


tp

Convert a double-precision integer value to a double-precision unsigned integer value and store the
result in the integer accumulator.
ht

Operand: DINT variable;

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.

- 243 -
5.IL INSTRUCTIONS B-63823EN/02

5.9 IL PMC OPERATIONS

PMC Operations
Use these IL functions to operate PMC.

/
Add BCD

om
Subtract BCD
Multiply BCD
Divide BCD
Modulus BCD
Trigger

s.c
Decode
Even Parity
Odd Parity
Window

re
EXIN
AXCTL

pa
cs
.cn
w
w
w
://
tp
ht

- 244 -
B-63823EN/02 5.IL INSTRUCTIONS

5.9.1 Add BCD

5.9.1.1 PMC_ADD_BCD2(in1, in2)

accumulator ← in1 + in2

/
om
Add two BCD2 and store the sum in the integer accumulator.
in1: BYTE variable or constant
in2: BYTE variable or constant

s.c
5.9.1.2 PMC_ADD_BCD4(in1, in2)

accumulator ← in1 + in2

re
Add two BCD4 and store the sum in the integer accumulator.
in1: WORD variable or constant
in2: WORD variable or constant

5.9.1.3 PMC_ADD_BCD8(in1, in2)


pa
cs
accumulator ← in1 + in2
Add two BCD8 and store the sum in the integer accumulator.
.cn

in1: DWORD variable or constant


in2: DWORD variable or constant
w

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
://
tp
ht

- 245 -
5.IL INSTRUCTIONS B-63823EN/02

5.9.2 Subtract BCD

5.9.2.1 PMC_SUB_BCD2(in1, in2)

accumulator ← in1 - in2

/
om
Subtract one BCD2 from another and store the result in the accumulator. The value and type of
the accumulator are unchanged.
in1: BYTE variable or constant
in2: BYTE variable or constant

s.c
5.9.2.2 PMC_SUB_BCD4(in1, in2)

re
accumulator ← in1 - in2
Subtract one BCD4 from another and store the result in the accumulator. The value and type of
the accumulator are unchanged.
in1: WORD variable or constant
in2: WORD variable or constant
pa
cs
5.9.2.3 PMC_SUB_BCD8(in1, in2)
.cn

accumulator ← in1 - in2


Subtract one BCD8 from another and store the result in the accumulator. The value and type of
the accumulator are unchanged.
w

in1: DWORD variable or constant


in1: DWORD variable or constant
w

For more details, see LD Functions.


w

Note: IL and LD functions are generally the same, with some differences in data types for operands.
://
tp
ht

- 246 -
B-63823EN/02 5.IL INSTRUCTIONS

5.9.3 Multiply BCD

5.9.3.1 PMC_MUL_BCD2(in1, in2)

accumulator ← in1 * in2

/
om
Multiply one BCD2 by another and store the product in the accumulator. The accumulator type is
unchanged.
in1: BYTE variable or constant
in2: BYTE variable or constant

s.c
5.9.3.2 PMC_MUL_BCD4(in1, in2)

re
accumulator ← in1 * in2
Multiply one BCD4 by another and store the product in the accumulator. The accumulator type is
unchanged.
in1: WORD variable or constant
in2: WORD variable or constant
pa
cs
5.9.3.3 PMC_MUL_BCD8(in1, in2)
.cn

accumulator ← in1 * in2


Multiply one BCD8 by another and store the product in the accumulator. The accumulator type is
unchanged.
w

in1: DWORD variable or constant


in2: DWORD variable or constant
w

For more details, see LD Functions.


w

Note: IL and LD functions are generally the same, with some differences in data types for operands.
://
tp
ht

- 247 -
5.IL INSTRUCTIONS B-63823EN/02

5.9.4 Divide BCD

5.9.4.1 PMC_DIV_BCD2(in1, in2)

accumulator ← in1/in2

/
om
Divide one BCD2 (in1) by another (in2) and store the quotient in the integer accumulator.
in1: BYTE variable or constant; the dividend
in2: BYTE variable or constant; the divisor

s.c
5.9.4.2 PMC_DIV_BCD4(in1, in2)

accumulator ← in1/in2

re
Divide one BCD4 (in1) by another (in2) and store the quotient in the integer accumulator.
in1: WORD variable or constant; the dividend
in2: WORD variable or constant; the divisor

5.9.4.3 PMC_DIV_BCD8(in1, in2)


pa
cs
accumulator ← in1/in2
Divide one BCD8 (in1) by another (in2) and store the quotient in the integer accumulator.
.cn

in1: DWORD variable or constant; the dividend


in2: DWORD variable or constant; the divisor
w

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
://
tp
ht

- 248 -
B-63823EN/02 5.IL INSTRUCTIONS

5.9.5 Modulus BCD

5.9.5.1 PMC_MOD_BCD2(in1, in2)

accumulator ← REMAINDER [in1/in2]

/
om
Divide one BCD2 by another and place the remainder in the accumulator. The accumulator type is
unchanged
in1: BYTE variable or constant
in2: BYTE variable or constant

s.c
5.9.5.2 PMC_MOD_BCD4(in1, in2)

re
accumulator ← REMAINDER [in1/in2]
Divide one BCD4 by another and place the remainder in the accumulator. The accumulator type is
unchanged
in1: WORD variable or constant
in2: WORD variable or constant
pa
cs
5.9.5.3 PMC_MOD_BCD8(in1, in2)
.cn

accumulator ← REMAINDER [in1/in2]


Divide one BCD8 by another and place the remainder in the accumulator. The accumulator type is
unchanged
w

in1: DWORD variable or constant


in2: DWORD variable or constant
w

For more details, see LD Functions.


w

Note: IL and LD functions are generally the same, with some differences in data types for operands.
://
tp
ht

- 249 -
5.IL INSTRUCTIONS B-63823EN/02

5.9.6 Trigger

5.9.6.1 R_TRIG(in)

/
When accumulator is rising (going from OFF to ON), R_TRIG sets ENO to ON for one sweep only.

om
in: BOOL variable for detection.

5.9.6.2 F_TRIG(in)

s.c
When accumulator is falling (going from ON to OFF), F_TRIG sets ENO to ON for one sweep only.
in: BOOL variable for detection.

re
For more details, see LD Functions.
Note: IL and LD functions are generally the same, with some differences in data types for operands.

pa
cs
.cn
w
w
w
://
tp
ht

- 250 -
B-63823EN/02 5.IL INSTRUCTIONS

5.9.7 Decode

5.9.7.1 PMC_DECODE_SINT(in, base, n, q)

/
PMC_DECODE_SINT extracts continuous 8 x n (depending on the array size of output parameter

om
q) integer data from the integer data of input parameter in and that of base, decodes it, then sets
the corresponding bit of output parameter q.
in: SINT variable or constant
base: SINT variable or constant; Decode indication number

s.c
n: constant
q: WORD [n] variable; Result of decoding

re
5.9.7.2 PMC_DECODE_USINT(in, base, n, q)

pa
PMC_DECODE_USINT extracts continuous 8 x n (depending on the array size of output
parameter q) integer data from the integer data of input parameter in and that of base, decodes it,
then sets the corresponding bit of output parameter q.
cs
in: USINT variable or constant
base: USINT variable or constant; Decode indication number
.cn

n: constant
q: WORD [n] variable; Result of decoding

5.9.7.3 PMC_DECODE_INT(in, base, n, q)


w

PMC_DECODE_INT extracts continuous 16 x n (depending on the array size of output parameter


w

q) integer data from the integer data of input parameter in and that of base, decodes it, then sets
the corresponding bit of output parameter q.
w

in: INT variable or constant


base: INT variable or constant; Decode indication number
://

n: constant
q: WORD [n] variable; Result of decoding
tp
ht

- 251 -
5.IL INSTRUCTIONS B-63823EN/02

5.9.7.4 PMC_DECODE_UINT(in, base, n, q)

PMC_DECODE_UINT extracts continuous 16 x n (depending on the array size of output


parameter q) integer data from the integer data of input parameter in and that of base, decodes it,

/
then sets the corresponding bit of output parameter q.

om
in: UINT variable or constant
base: UINT variable or constant; Decode indication number
n: constant

s.c
q: WORD [n] variable; Result of decoding

5.9.7.5 PMC_DECODE_DINT(in, base, n, q)

re
PMC_DECODE_DINT extracts continuous 32 x n (depending on the array size of output
parameter q) integer data from the integer data of input parameter in and that of base, decodes it,
then sets the corresponding bit of output parameter q.
in: DINT variable or constant
base: DINT variable or constant; Decode indication number
pa
cs
n: constant
q: WORD [n] variable; Result of decoding
.cn

5.9.7.6 PMC_DECODE_UDINT(in, base, n, q)

PMC_DECODE_UDINT extracts continuous 32 x n (depending on the array size of output


w

parameter q) integer data from the integer data of input parameter in and that of base, decodes it,
then sets the corresponding bit of output parameter q.
w

in: UDINT variable or constant


base: UDINT variable or constant; Decode indication number
w

n: constant
q: WORD [n] variable; Result of decoding
://

For more details, see LD Functions.


tp

Note: IL and LD functions are generally the same, with some differences in data types for operands.
ht

- 252 -
B-63823EN/02 5.IL INSTRUCTIONS

5.9.8 Check Even Parity

5.9.8.1 PMC_EVPAR_BYTE(in1)

/
accumulator ← Result of check

om
Check the even parity of BYTE data.
in1: BYTE variable or constant

5.9.8.2 PMC_EVPAR_WORD(in1)

s.c
accumulator ← Result of check
Check the even parity of WORD data.

re
in1: WORD variable or constant

5.9.8.3 PMC_EVPAR_DWORD(in1)

accumulator ← Result of check


Check the even parity of DWORD data.
pa
cs
in1: DWORD variable or constant
.cn

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.
w
w
w
://
tp
ht

- 253 -
5.IL INSTRUCTIONS B-63823EN/02

5.9.9 Check Odd Parity

5.9.9.1 PMC_ODPAR_BYTE(in1)

/
accumulator ← Result of check

om
Check the odd parity of BYTE data.
in1: BYTE variable or constant

5.9.9.2 PMC_ODPAR_WORD(in1)

s.c
accumulator ← Result of check
Check the odd parity of WORD data.

re
in1: WORD variable or constant

5.9.9.3 PMC_ODPAR_DWORD(in1)

accumulator ← Result of check


Check the odd parity of DWORD data.
pa
cs
in1: DWORD variable or constant
.cn

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.
w

5.9.10 Window
w

5.9.10.1 PMC_WINDOW(ar, n, err)


w

accumulator ← Completion flag


://

The CNC ←→ PMC window function is used to read and write the CNC data if boolean
accumulator is set to True.
tp

ar: INT variable; AR array


n: constant. Length of ar(INT) array.
ht

err: BOOL variable; Error output

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.

- 254 -
B-63823EN/02 5.IL INSTRUCTIONS

5.9.11 EXIN

5.9.11.1 PMC_EXIN(head, cmd, dt, err)

/
accumulator ← Completion flag

om
Issues commands for the CNC external data input function if boolean accumulator is set to True.
head: INT variable or constant; HEAD NO.
cmd: WORD variable; Command code
dt: DWORD variable; Command data

s.c
err: BOOL variable; Error output

For more details, see LD Functions.

re
Note: IL and LD functions are generally the same, with some differences in data types for operands.

5.9.12 AXCTL
pa
cs
5.9.12.1 PMC_AXCTL(r, grp, cmd, dt1, dt2, err)
.cn

accumulator ← Completion flag


Specifies the PMC axis control function of the CNC if boolean accumulator is set to True.
r: BOOL variable; Reset
w

grp: INT variable or constant; DI/DO signal group


cmd: WORD variable or constant; Axis control command
w

dt1: DINT variable or constant; Instruction data 1


dt2: DINT variable or constant; Instruction data 2
w

err: BOOL variable or constant; Error output


://

For more details, see LD Functions.


Note: IL and LD functions are generally the same, with some differences in data types for operands.
tp
ht

- 255 -
5.IL INSTRUCTIONS B-63823EN/02

5.10 NOTE ON IL PROGRAMMING

Some functional instructions may cause the ladder program to take a


long time to stop or make it unable to stop, if their boolean

/
accumulator or r (Reset) condition remains on for no apparent reason.

om
If the ladder program does not stop, all operations aimed at changing
the ladder program will take longer to end or will never end.
To avoid such problems, when you code a ladder program using
functional instructions, you need to design the ladder structure based
on a thorough understanding of the control conditions of the

s.c
individual instructions you use.
Listed below are typical cases in which the ladder program will not
stop.
• A low‐speed window function is used for a PMC_WINDOW

re
functional instruction, and its boolean accumulator condition
remains on.
• In a PMC_EXIN or PMC_AXCTL instruction, not only the

pa
boolean accumulator condition but also the r (Reset) condition
remain on.
cs
If the ladder program takes long to stop or does not stop for any of
these reasons, the following operations will be affected.
1. Stopping the ladder program using a soft key on the screen.
.cn

2. Reading a new ladder program from a memory card or other


medium, by using the data input and output screen.
3. Updating the ladder program with changes made using the FANUC
LADDER-IIIC.
w

If any of the above phenomena occurs, the functional instruction


causing the problem needs to be fixed. Check the functional
w

instructions mentioned above to see whether there is any boolean


accumulator or r (Reset) condition remaining on, and correct the
ladder program according to the following procedure.
w

1. Put the machine in safe condition and turn off the power of the NC.
2. Turn on the power of the NC while holding down the "CAN" and
://

"Z" keys simultaneously, to restart the NC with the ladder program


halted.
3. In the FANUC LADDER-IIIC, redesign the logic associated with
tp

the problematic functional instruction. When done, set the boolean


accumulator or r (Reset) condition to off.
4. Write the resulting logic to flash ROM using the I/O screen.
ht

5. Run the ladder program.

If the ladder program does not stop or cannot be changed even after
you make the correction, there may be other functional instructions
that have the same condition settings.
Check for other functional instructions having the same condition
settings, besides the one you have corrected, and repeat the above
procedure to correct them all.

- 256 -
B-63823EN/02 6.OPERATION

6 OPERATION

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 257 -
6.OPERATION B-63823EN/02

6.1 OVERVIEW

In the NC system, pressing the [PMC] soft key on the [SYSTEM]


menu enables the setting and display of data related to the PMC. The

/
following screens are used to specify and display the PMC-related

om
data.
(1) Displaying PMC input/output signals and internal relay
(PMCDGN)
(a) Title data screen
(b) Status screen

s.c
(c) Alarm screen
(d) Trace screen
(e) I/O Link Monitor screen
(2) PMC data setting and display (PMCPRM)

re
(f) Keep relay (%MK, %SK)
(g) Data Register Table (%R)
(3) Specifying PMC setting data (SETING)

pa
(h) General setting data
(i) Setting data related to editing and debugging
(j) Online monitor parameter
(4) Writing, reading, and collating sequence programs and PMC
cs
parameters (I/O)
.cn
w
w
w
://
tp
ht

- 258 -
B-63823EN/02 6.OPERATION

6.2 SOFT KEY-BASED PMC MENU SELECTION PROCEDURE

After the <SYSTEM> function key on the LCD/MDI is held down,


pressing the [PMC] soft key displays the following PMC basic menu.

/
6.2.1 PMC Basic Menu

om
Title Line
PMC Basic Menu

s.c
re
pa
cs
.cn
w

Key-in buffer Alarm line


Soft key
(1) Title line
w

This line displays the title of each PMC system screen.


It also displays the status of the PMC system at the right-hand end.
. . . Whether the sequence program is running is
w

indicated. [RUN] means that the sequence


program is running. [STOP] means that the
://

sequence program is not running.


(2) Key-in buffer
This area displays the data that was typed in.
(3) Soft key
tp

The soft key field consists of a soft key at both ends and 10 soft
keys or 5 soft keys in between. The left-end key has the following
meaning:
ht

< Return key .Pressing this key returns you to the previous screen.

(4) Alarm line


......... This character string appears if a PMC alarm has
occurred.

- 259 -
6.OPERATION B-63823EN/02

If the built-in debug function is disabled (%SK2 = 0, %SK19 = 0


and %SK23 = 0), the basic menu appears as follows:

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 260 -
B-63823EN/02 6.OPERATION

6.2.2 PMC Screen Transition and Related Soft Keys

NC system screen

PMC

/
om
TITLE Title screen
<

STATUS Status screen


PMC basic

s.c
menu screen
ALARM Alarm screen

PMCDGN TRACE Trace screen

re
< I/OCHK I/O Link Monitor screen

PMCPRM
KEEPRL

DATA
pa
Keep relay screen

Data table screen


cs
<
.cn

Setting menu screen


SETING
GEN General setting data
<

Data related to editing and


w

EDTDBG
debugging
w

ONLINE Online parameter setting


w

I/O
I/O screen
://

<
RUN Programmer function
or
tp

STOP
ht

- 261 -
6.OPERATION B-63823EN/02

6.3 DISPLAYING PMC INPUT/ OUTPUT SIGNALS AND


INTERNAL RELAY (PMCDGN)

6.3.1 Title Data Display (TITLE)

/
om
The title data corresponds to the title of a sequence program. It
consists of the following items:

s.c
re
pa
cs
.cn

• Machine tool builder name (32 characters)


• Machine name (32 characters)
w

• CNC/PMC type (32 characters)


• Sequence program number (4 characters)
• Edition (2 characters)
w

• Sequence program drawing (32 characters)


• Sequence program creation date (16 characters)

w

Sequence program creator name (32 characters)


• ROM writer operator name (32 characters)
• Comment (32 characters)
://

In addition, the following data is displayed:


• PMC basic software series and edition
• Amount of memory occupied by each set of sequence data
tp

• PMC basic software type and sequence program PMC type


• Current, maximum, and minimum execution time of the ladder
program
ht

On the programming FANUC LADDER-IIIC, these title items can be


edited in property inspector by selecting PMC target node.

- 262 -
B-63823EN/02 6.OPERATION

6.3.2 Signal Status Display (STATUS)


This screen displays the contents at all the addresses
(%QG, %IF, %Q, %I, %MA, %SA, %M, %ST, %S, %ME, %MK, %S
K, %R, %UF and %UI) specified in programs. Each content display is

/
a string of 0 and 1 with a hexadecimal indication at the right end.

om
Symbol

s.c
Address %QG8 %QG2 %QG1

re
pa
Display area of Symbol and Comment name
cs
.cn

Operating procedure
(1) Press the [STATUS] soft key. The screen shown above appears.
(2) Specify without % of the desired address, then press the
[SEARCH] soft key. Example %QG1 -> QG1
w

(3) A sequence of data starting at the specified address is displayed


as a bit pattern.
(4) To specify another address for display, press a cursor key, page
w

key, or the [SEARCH] soft key.


(5) When you want to change the status of the signals, press
[FORCE] soft key. So, the forced I/O screen appears.
w

NOTE
The [FORCE] soft key is displayed only when the
://

following conditions are satisfied.


In the GENERAL screen of PMC setting:
tp

Set “RAM WRITE ENABLE” to “YES”.


Or
Set “PROGRAMMER ENABLE” to “YES”.
ht

- 263 -
6.OPERATION B-63823EN/02

(6) The signals of %I and %Q addresses which are set into


overridden mode are marked with “>” on the left in the forced
I/O screen. That shows the setting of override signals

NOTE

/
Names given to variables on the programming

om
FANUC LADDER-IIIC can be displayed in symbol
field on this screen.
Strings entered on the programmer are translated
into symbols when compiling according to the
following rules.

s.c
1. In the string of the bit symbol that can be
displayed, there is a limitation of maximum 6
characters.
2. If the symbol (uint type etc.) except for the bit

re
symbol is displayed, there is limitation of
maximum 9 characters.

following.pa
3. The limitation to input SYMBOL name is as the

- The small letter cannot be inputted. Input the


capital.
cs
- The ‘_’ can not be input by key input. Input
the ‘-‘.
- The ‘$’ can not be input by key input. Input
.cn

the ‘&’.
4. When the symbol name is searched, the small
letter isn't distinguished from the capital letter.
w

Forced Input/ Output Function


w

- Overview
This is the function to change the status of the signals at arbitrary
PMC address forcibly. If the input “%I” is forced with this function,
w

the sequence program can be debugged without the machine. If the


output “%Q” is forced, the wiring for the machine can be checked
without the sequence program.
://
tp
ht

- 264 -
B-63823EN/02 6.OPERATION

- Input mode
This function has two kinds of input modes. These modes can be used
properly according to the purpose.

(1) Forcing mode

/
This mode is applied to all of PMC addresses. However, the

om
signals changed by this function are overwritten when the
sequence program or operator input in the same address. As a
result, the forced I/O function becomes ineffective.

Machine

s.c
I/O address
Overwrite %I
Overwrite %Q
Ladder %QG, %M,
Overwrite

re
%MK, %R
%IF
Overwrite
CNC

pa
cs
Ex1: I/O Unit-MODEL A is connected with %I1. And %I1 is
forced to be changed.
.cn

The input value from a I/O Unit-MODEL A is periodically


transferred to %I1. Therefore, even if you change the value
of %I1 forcedly, the I/O Unit-MODEL A would overwrite the
input value at next cycle.
w

I/O Unit-MODEL A NC
w

%I1 = 1 %I1 = 1
w

%I1 is forced to 0 %I1 = 0


://

%I1 is overwritten by the I/O Unit-MODEL A.


tp

I/O Unit-MODEL A NC
ht

%I1 = 1 %I1 = 1

The cyclic transfer might be performed to the addresses at which


any I/O device is not assigned. So, you should use the forced I/O
function in the forcing mode without I/O devices when
debugging any %I address. As for the debug of the ladder
program with I/O devices, use the forced I/O function in
Override mode explained in next paragraph.

- 265 -
6.OPERATION B-63823EN/02

(2) Override Mode


In this mode, the ladder program and the I/O devices does not
overwrite the signals which are forced to be changed. You can
specify the override mode into arbitrary %I/%Q addresses.
The %I/%Q addresses which is not set the override mode is in
the forcing mode.

/
om
Ex) I/O Unit-MODEL A is connected with %I1. And %I1 is
forced to be changed.

I/O Unit-MODEL A NC

s.c
%I1 = 1 %I1 = 1

re
• X0 is set in Override mode.

The input value from the I/O Unit-MODEL A is disabled.

I/O Unit-MODEL A pa x NC
cs
%I1 = 1 %I1 = 1

• The %I1 is forced to 0


.cn

I/O Unit-MODEL A x NC

%I1 = 1 %I1 = 0
w

Therefore, the forced I/O function for %I addresses in the


Override mode can be used to debug the ladder program with
w

some I/O devices. If you set the override mode into %Q


addresses, The value forced to be changed is output to the I/O
devices.
w
://
tp
ht

- 266 -
B-63823EN/02 6.OPERATION

NOTE
1 In the Override mode, the refresh cycle of the I/O signal is 8msec, which is
synchronized with the 1st level of the ladder program. Usually, the refresh cycle of
the I/O link is 2msec. So, the timing of the signals for I/O devices is delayed. Pay
attention the change of work of the ladder program which depends on the timing of

/
the I/O devices.

om
2 The processing time of the 2nd level of the ladder program might get longer in the
override mode.
3 The relay coils which are set in the override mode are displayed as the processing
result of the ladder program in the ladder monitor screen. The output value for the
I/O devices is forced to be changed. Pay attention that the values on the ladder

s.c
monitor screen does not correspond with the output values for the I/O devices.

Ex.) : I/O Unit-MODEL A is connected with %Q1. And %Q1 is forced to be

re
changed.

Usually, the display values on the ladder screen correspond with the output values
for the I/O Unit-MODEL A as follows.
pa %I1 %Q1
cs
I/O Unit-MODEL A NC
OFF OFF
.cn

%Q1=OFF
Ladder Monitor

If you set “1” into the %Q1 in the override mode, the value is output to the I/O
w

UNIT-MODEL A as follows.
w

%I1 %Q1

I/O Unit-MODEL A NC
OFF OFF
w

%Q1=ON
Ladder Monitor
://

WARNING
tp

When you change the signals by the forcing I/O function, you have to pay special
attention. Inappropriate use of this function may cause unexpected reaction of
machine. You have to make it sure that nobody is near the machine when you use
ht

this function.

- 267 -
6.OPERATION B-63823EN/02

Operations to Enable the Forced I/O Function


The following setting is necessary to enable each mode.
• Setting of forcing mode
In the GENERAL screen of PMC setting:
Set “RAM WRITE ENABLE” to “YES”.

/
Or

om
Set “PROGRAMMER ENABLE” to “YES”.

• Setting of override mode


In the GENERAL screen of PMC setting:
Set “RAM WRITE ENABLE” to “YES”.

s.c
Or
Set “PROGRAMMER ENABLE” to “YES”.
And, In the EDIT/DEUG screen of PMC setting:
Set “OVERRIDE ENABLE” to “YES”.

re
Then, turn on the power supply again.

NOTE

pa
1 Please disable the forced I/O function when the
machine is shipped.
2 The setting “OVERRIDE ENABLE” is set to “NO”
automatically and the override function becomes
cs
disabled when the setting "PROGRAM ENABLE =
NO", “RAM WRITE ENABLE = NO” and turning off
.cn

the power supply.


3 The settings of the override mode are not kept
after turning off the power supply. All bits of %I
and %Q are not in the override mode just after
turning on the power supply.
w

Forced Input/ Output Screen


w

In this screen, you can change the value of arbitrary address forcibly.
You can use the two input modes, i.e. the forcing mode and the
override mode. To display this screen, press the soft key [FORCE] in
w

the signal status screen. The following operations are available in this
screen.
[SEARCH] Search of address
://

[ON] Signal on
[OFF] Signal off
[STATUS] Display of signal status screen
tp

[OVR SET] Setting of override signal (Effective only when override


mode)
[OVRRST] Release from override signal (Effective only when
ht

override mode)
[INIT] Release form all override signal (Effective only when
override mode)

- 268 -
B-63823EN/02 6.OPERATION

Symbol

/
Input Mode

om
Address %QG8 %QG1

s.c
Display area of signal status

re
Key Input Line
pa
Display area of Symbol and Comment name
cs
.cn

Message Line

(1) When the override mode, The string ”OVERRIDE" is displayed


w

above the screen.


(2) The status of each signal is displayed in the area of the signal
status.
w

(3) Each bit of %I/%Q which is set into the override is displayed on
the screen as follows.
%I address:
w

(Input signal from the I/O devices)->(Input signal to the


ladder)
The hexadecimal numbers on the right of the screen is the
://

overridden input signals to ladder.


tp

%Q address:
(Output signal from the ladder)->(Output signal to the I/O
ht

devices)
The hexadecimal numbers on the right of the screen is the
overridden output signals from the ladder.

(4) In the message line, some system messages like error messages
are displayed.

- 269 -
6.OPERATION B-63823EN/02

Operations
(1) Operations by the soft keys

The soft-keys in this screen

/
om
Forcing Mode

Search of address Go to Signal Status Screen

s.c
Signal On Signal Off

re
Override Mode

Search of address
pa
Go to Signal Status Screen
cs
Signal On Signal Off
Release of All Override
.cn

Set of Override signal Release of Override signal

[SEARCH] Search of address


w

This searches the bit address or the word address to display


on the screen.
[ON] Signal On
w

The signal on the cursor is sets into on.


[OFF] Signal Off
The signal on the cursor is sets into off.
w

[STATUS] Return to the signal status screen


This returns the signal status screen.
[OVRSET] Setting or Override signal
://

This sets the %I/%Q address on the cursor into the override
signal.
As for the override signal, the status of the override signal is
tp

set the status of the signal just before pressing the soft key
[OVRSET].
The bit set the override is added the “>” display on the
ht

screen. The actual signals before overridden are also


displayed.
%I address:
(Actual input signal from the I/O devices)->
(Overridden Input signal to the ladder)

- 270 -
B-63823EN/02 6.OPERATION

%Q address:
(Actual output signal from the ladder)->(Overridden
output signal to the I/O devices)

/
[OVRRST] Release of override signal

om
This releases the setting of override signal about the %I/%Q
address on the cursor.
The status of signal returns to the status before overridden
by the operation.
[INIT] Release of all the overridden signals

s.c
These releases the setting of all override signals in %I/%Q
addresses.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 271 -
6.OPERATION B-63823EN/02

6.3.3 Alarm Screen (ALARM)


If an alarm condition occurs in the PMC, pressing the [PMC] soft key
from the NC system displays the following alarm message instead of
the PMC basic menu. The soft keys displayed on this screen remain

/
the same as on the PMC basic module screen. In addition, character

om
string “ALM” appears.
If the alarm condition is fatal, no sequence program will be executed.

s.c
re
pa
cs
.cn

For an explanation of the alarm messages displayed on this screen, see


APPENDIX C, “ALARM MESSAGE LIST”.
w
w
w
://
tp
ht

- 272 -
B-63823EN/02 6.OPERATION

6.3.4 Trace Screen (TRACE)

Overview
On the trace screen, you can trace specified signals. The result of the
trace is displayed as the time chart of signals.

/
There are two tracing modes. One is the “Time Cycle” mode that

om
samples the state of the signals at every specified cycle time. The
other is the “Signal Transition” mode that samples the status of the
signals when the signals that are watched at every specified time are
changed.
Pushing [TRACE] soft key displays the following screen.

s.c
re
pa
cs
.cn
w

To execute tracing, setting of the trace parameter is necessary.


Pushing the [SETING] soft key displays “Parameter Setting” screen.
The trace function is able to run automatically by the setting on “PMC
w

Setting” screen when the power is switched on. In this case, setting of
the trace parameter is necessary in advance.
w

NOTE
As for the setting of automatic running for the trace
://

function, please refer to “Screen for Displaying


General Settings (GENERAL)” in Subsection 6.4.4.
tp
ht

- 273 -
6.OPERATION B-63823EN/02

Setting of Trace Parameter


Pushing the [SETING] soft key displays the “Parameter Setting”
screen.
The following is the screen example of the trace execution by “TIME
CYCLE” mode.

/
om
s.c
re
pa
cs
“Parameter Setting” has two screens. The page number is displayed
.cn

on up right of the screen. The page key changes these screens.


Pushing [<] soft key displays “PMC Signal Trace” screen.

The following is the screen example of the trace execution by


“SIGNAL TRANSITION” mode.
w
w
w
://
tp
ht

- 274 -
B-63823EN/02 6.OPERATION

• SAMPLING MODE
Determines the sampling mode. Select one by cursor key or soft key.
Soft keys display when the cursor is put on “SAMPLING MODE”.

/
Explanation:

om
TIME CYCLE Samples at every specified cycle time.
SIGNAL TRANSITION Samples when the signal changes.
INIT Initializes all the settings. (This soft key
is always displayed in page 1.)

s.c
• SAMPLING RESOLUTION
The resolution of sampling is inputted. The default value is the
minimum resolution (8msec). The range of the value is from 8msec to
1000msec. Inputted value is rounded down to the multiple of 8msec.

re
• SAMPLING TIME
This parameter is displayed when “TIME CYCLE” is set on

pa
“SAMPLING MODE”. The execution time of trace is inputted. The
value of “SAMPLING SESOLUTION” or the number of specified
signal address changes the range of the value that is able to input. The
range is displayed on the right of the edit box.
cs
• SAMPLING FRAME
This parameter is displayed when “SIGNAL TRANSITION” is set on
.cn

“SAMPLING MODE”. The number of sampling is inputted. The


value of “SAMPLING SESOLUTION” or the number of specified
signal addresses changes the range of the value that is able to input.
The range is displayed on the right of the edit box.
w

• STOP CONDITION
Determines the condition to stop the trace. Select one by cursor key or
w

soft key.
Soft keys display when the cursor is put on “STOP CONDITION”.
w

Explanation:
NONE Does not stop the tracing automatically.
://

BUFFER FULL Stops the tracing when the buffer becomes full.
TRIGGER Stops the tracing by trigger
tp
ht

- 275 -
6.OPERATION B-63823EN/02

• STOP CONDITION TRIGGER ADDRESS


When “TRIGGER” is set on “STOP CONDITION”, this parameter is
enabled. Input signal address or symbol name as stop trigger.
Only bit address or corresponding symbols can be inputted. Byte
address cannot be inputted.

/
Soft keys display when the cursor is put on “STOP CONDITION
TRIGGER ADDRESS”.

om
Explanation:
DELETE Clears the value in the edit box.

s.c
SYMBOL Changes the address display to the symbol name display
and changes the soft key to [ADDRESS]. After that,
following soft keys are displayed.

re
NOTE
In the string of the symbol that can be displayed,
there is a limitation of maximum 16 characters.

pa
The SYMBOL name is displayed only in case of
the bit symbol.
cs
ADRESS Changes the symbol name display to the address
.cn

display and changes the soft key to [SYMBOL].

• STOP CONDITION TRIGGER MODE


When “TRIGGER” is set on “STOP CONDITION”, this parameter is
enabled. Input trigger mode when the trace is stopped. Select one by
w

cursor key or soft key.


Soft keys display when the cursor is put on “STOP CONDITION
w

TRIGGER MODE”.
w

Explanation:
RISE Stops the tracing automatically by rising up of the trigger
signal.
://

FALL Stops the tracing automatically by falling down of the


trigger signal.
BOTH Stops the tracing automatically by rising up or falling
tp

down of the trigger signal.


ht

- 276 -
B-63823EN/02 6.OPERATION

• STOP CONDITION TRIGGER POSITION


When “TRIGGER” is set on “STOP CONDITION”, this parameter is
enabled. Input the ratio of the sampling time or number which
specifies the position where specified trigger condition is on.
If you would like to examine the transitions of the signal before the

/
trigger condition, you should set a big value in this parameter. If you
would like to examine the transitions of the signal after the trigger

om
condition, you should set a small value in this parameter.
Example: The case that sampling time is 10 second and trigger
position is set as “10%”.

s.c
re
The graph is displayed on the right of the edit box. The edge of the
left hand is as 0% and the edge of the right hand is as 100%. The
position indicated by the input value is displayed as a gauge.

• SAMPLING CONDITION pa
When “SIGNAL TRANSITION” is set on “TRACE MODE”, this
cs
parameter is enabled. Select one by cursor key or soft key.
Soft keys display when the cursor is put on “SAMPLING
CONDITION”.
.cn

Explanation:
TRIGER Samples the status of specified signals when the
specified sampling condition is on.
w

CHANGE Samples the status of specified signals when the signals


change
w

The address of the signals that should be sampled is set on Parameter


Setting screen page2.
w

• SAMPLING CONDITION TRIGGER ADDRESS


When “SIGNAL TRANSITION” is set on “TRACE MODE”, and
://

“TRIGGER” is set on “SAMPLING CONDITION”, this parameter is


enabled. Input signal address or symbol name as sampling trigger.
Only bit address or corresponding symbol can be inputted. Byte
tp

address cannot be inputted.


Soft keys display when the cursor is put on “SAMPLING
CONDITION TRIGGER ADDRESS”.
ht

The contents of the soft keys are same as “STOP CONDITION


TRIGGER ADDRESS”.

- 277 -
6.OPERATION B-63823EN/02

• SAMPLING CONDITION TRIGGER MODE


When “SIGNAL TRANSITION” is set on “TRACE MODE”, and
“TRIGGER” is set on “SAMPLING CONDITION”, this parameter is
enabled. Input trigger mode that determines the condition of specified
trigger.

/
Soft keys display when the cursor is put on “SAMPLING
CONDITION TRIGGER MODE”.

om
Explanation:
RISE Samples the status of specified signals by rising up of the

s.c
trigger signal.
FALL Samples the status of specified signals by falling down of
the trigger signal.
BOTH Samples the status of specified signals by rising up or

re
falling down of the trigger signal.
ON Samples the status of specified signals during the trigger
signal is on.
OFF
pa
Samples the status of specified signals during the trigger
signal is off.

• SAMPLING ADDRESS
cs
In page 2 of Parameter Setting screen, you can set the addresses or
symbols that should be sampled.
.cn
w
w
w
://
tp

Move the cursor into edit box and input PMC signal address or
ht

symbol.
In case of inputting discrete bit addresses, any bit address can be
inputted. Moreover, when you input byte address, all bits of the
address (bit0-bit7) are set automatically.
Maximum 32 points of signal address can be inputted. Increasing the
number of the signal address changes the capacity of “SAMPLING
TIME” or “SAMPLING FRAME” in page1. If the capacity is changed,
the warning message is displayed

- 278 -
B-63823EN/02 6.OPERATION

Example of warning message:


In case of “TIME CYCLE” mode
“SAMPLING TIME IS REDUCED TO n SEC.”
In case of “SIGNAL TRANSITION” mode
“SAMPLING FRAME IS REDUCED TO n COUNT.”

/
om
The “n” means the maximum value that is able to input.

Explanation of the soft keys:


DELETE Clears the value of the edit box on the cursor.
SYMBOL Changes the address display to the symbol display.

s.c
However, display of the address that is not defined the
symbol does not change. This soft key also changes to
“ADDRESS”. The following soft keys are displayed.
MV.UP Exchanges the signal indicated the cursor for the signal

re
above one line.
MV.DWN Exchanges the signal indicated the cursor for the signal
below one line.

pa
DELALL Clears all of the value of the edit box.
cs
ADDRESS Changes the symbol display into the address display and
changes the soft key to “SYMBOL”.
.cn

NOTE
In the string of the symbol that can be displayed,
there is a limitation of maximum 10 characters.
w

The SYMBOL name is displayed only in case of


the bit symbol.
w
w
://
tp
ht

- 279 -
6.OPERATION B-63823EN/02

• TRIGGER SETTING OF THE SAMPLING SIGNALS


When “SIGNAL TRANSITION” is set on “TRACE MODE” and
“ANY CHANGE” is set on “SAMPLING CONDITION”, the check
boxes on the right of the sampling address or symbols are displayed as
follows. Check the signals that should trigger the sampling in the

/
setting signals.

om
s.c
re
pa
cs
Pushing [TRIGGER ON] soft key sets the trigger on. Pushing
.cn

[TRIGGER OFF] soft key sets the trigger off. The default setting is
trigger on for all signals. The contents of other soft keys are same as
“SAMPLING ADDRESS”.
w
w
w
://
tp
ht

- 280 -
B-63823EN/02 6.OPERATION

Execution of Trace
On trace screen, pushing [START] soft key starts the execution of
trace after you set the trace parameter correctly. The following is the
screen example of the trace execution by “TIME CYCLE” mode.

/
om
s.c
re
pa
cs
The result of trace is immediately displayed during execution of the
.cn

trace. When the stop condition that is set in parameter setting screen is
satisfied the execution is finished. Pushing [STOP] soft key aborts the
execution.

The following is the screen example of the trace execution by


w

“SIGNAL TRANSITION” mode.


w
w
://
tp
ht

In “SIGNAL TRANSITION” mode, graphic display is not refreshed


until any signal for sampling trigger changes.

- 281 -
6.OPERATION B-63823EN/02

Operation after Execution of Trace


When the execution is finished, the result of trace is displayed. The
following is the screen example of trace by “TIME CYCLE” mode.

/
om
s.c
re
pa
The cursor indicating current position is initially displayed on the
cs
original point (0 point).
The position of the cursor is displayed in “CURSOR POSITION” in
the upper of the screen. The cursor can move horizontally.
.cn

The following is the screen example of trace by “SIGNAL


TRANSITION” mode.
w
w
w
://
tp
ht

- 282 -
B-63823EN/02 6.OPERATION

After the execution, following operation is enabled.

(1) SCROLL OF SCREEN


Using cursor up/down key and page up/down key enables the
vertical scroll for the specified signal. Using cursor right/left key,
[NEXT>>] soft key and [<<PREV] soft key enables the

/
horizontal scroll of the graph.

om
(2) AUTOMATIC CALCULATION OF THE SELECTED RANGE
Pushing [MARK] soft key marks the current position and
displays the mark cursor. If the mark cursor duplicates with the
current position cursor, the current position cursor has priority of

s.c
display. The “MARK POSITION” that shows the position of the
mark cursor and “SELECT RANGE” that shows the range
between the mark cursor and the current position cursor are
displayed in the upper of screen. Moving the current position

re
cursor changes these values. Pushing [MARK] again releases the
select range mode.

pa
cs
.cn
w
w
w
://
tp
ht

- 283 -
6.OPERATION B-63823EN/02

(3) ZOOM IN/ZOOM OUT OF WAVEFORM


Pushing [Z.IN] soft key magnifies the display of chart. Pushing
[Z.OUT] soft key reduces the display of chart. Pushing these soft
keys also change the scale value of the graduation on the graph.
When trace is just finished, the default zooming level was the
most magnified level. In [Z.OUT] mode, gray box is displayed as

/
following screen example when the transitions of signal cannot

om
be expressed accurately enough. The limitation of [Z.OUT]
displays all of result of the trace in one page.

s.c
re
pa
cs
.cn

(4) EXCHANGE OF SAMPLING SIGNAL


Pushing [MV.UP] soft key exchanges the signal indicated by the
w

signal cursor for the signal one line above. Pushing


[MV.DOWN] soft key exchanges the signal indicated by the
signal cursor for the signal one line below. The result of the
w

operation is cancelled by the execution of trace or putting the


power off. When you would like to preserve the order of
displayed signals against the executing or powering off, please
w

change the order on “SAMPLING ADDRESS” screen.


://
tp
ht

- 284 -
B-63823EN/02 6.OPERATION

6.3.5 Displaying and Setting the Configuration Status of I/O


Devices (I/OCHK)
Call this screen by pressing of soft key [I/OCHK] in PMCDGN.

/
om
s.c
re
pa
cs
There are following sub screens under the I/O Check screen. Soft keys
.cn

are displayed when each function can be used.


Please refer to the manual about requirement of the functions and
detail of the sub screens.
Soft key : Name of sub screen
[IOLNK] : I/O Link Connecting Check screen
w

[IOLNK2] : I/O Link-II Parameter Setting screen


For details, please refer to “FANUC I/O Link-II
CONNECTING MANUAL (B-62714EN).”
w

[PROFI] : PROFIBUS-DP Parameter Setting screen


For details, please refer to “FANUC
PROFIBUS-DP Board OPERATOR’S MANUAL
w

(B-62924EN).”
[D_NET] : DeviceNet Parameter Setting screen
://

For details, please refer to “FANUC DeviceNet


Board OPERATOR’S MANUAL (B-63404EN).”
[FL-NET] : FL-net Parameter Setting screen
For details, please refer to “FANUC FL-net Board
tp

OPERATOR’S MANUAL (B-63434EN).”


ht

- 285 -
6.OPERATION B-63823EN/02

I/O Link Connecting Check Screen (IOLNK)


The I/O Link connecting check screen displays the types and ID codes
of the connected I/O devices for each group. If there is a problem of
input or output signals for I/O devices, check connection of I/O Link
by referring to this screen. Call this screen by pressing of soft key

/
[IOLNK] in I/OCHK. Then check if browsed group Ids are consistent

om
with the setting of I/O link configured under the hardware
configuration node on the programmer FANUC LADDER-IIIC.
I/O Unit Type

s.c
re
pa
cs
.cn

Group number I/O Unit ID code


w

If the channel 2 is available, the [PREV.] and [NEXT] soft keys are
w

displayed. This example screen shows that the channel 2 is available.

NOTE
w

I/O Link expansion option is necessary to use the


channel 2 of I/O Link.
://
tp
ht

- 286 -
B-63823EN/02 6.OPERATION

Table 6.3.5 Displayed type and true type of I/O Units


Displayed I/O Unit ID True I/O Unit
CONNECTION UNIT 80 Connection Unit
OPERATOR PANEL 82 Connection Unit for Operators Panel
I/O-B3 83 I/O B3
IO UNIT-MODEL B 84 I/O Unit-MODEL A

/
86

om
87
PLC SERIES 90-30 45 PLC SERIES 90-30
POWER MATE / IO LINK BETA 4A Power Mate or I/O Link Beta
SERIES 0 50 Series 0
OPERATOR IF BOARD (MPG1) 53 Machine Operators Panel Interface

s.c
LINK CONNECTION UNIT 96 I/O Link Connecting Unit
I/O UNIT-MODEL B 9E I/O Unit-MODEL B
R-J MATE 61 R-J Mate
CONNECTOR PANEL MODULE A9 I/O module for connector panel

re
OPERATOR PANEL A1 AA I/O module for operator's panel
OPERATOR I/F BOARD (MPG3) 6B Operator Interface(with MPG)
LOADER I/O AF I/O Board for Loader
ROBOCUT DIF
ROBOCUT MIF
I/O CARD
ROBOSHOT I/O CARD A
B0
B1
B2
B3
pa
DIF Board for ROBOCUT
MIF Board for ROBOCUT
I/O board
I/O for ROBOSHOT
cs
LOADER I/O (MATRIX) B4 I/O Board for Loader(Matrix)
PROCESS I/O FA B5 Process I/O for R-J3
PROCESS IO 89 Process I/O for R-X
.cn

I/O LINK ADAPTER 8B I/O Link adapter


ROBOT CONTROLLER 52 Controller for R-X
PLC SERIES 90 54 PLC SERIES 90
OPERATOR PANEL 95 I/O for Series 0
LASER OSCILLATOR 97 Laser Oscillator
w

FIXED I/O TYPE A 98 I/O for Robot Type A


FIXED I/O TYPE B 99 I/O for Robot Type B
w

AS-I CONVERTER 77 AS-i Converter


OPERATOER PANEL B A8 I/O Module(for Operator Panel 48/32)
MACHINE OPERATOER PANEL A A8 I/O Module(for Machine Operator Panel of 0 Type)
w

CONNECTION UNIT C1 (MPG) A8 Connection Unit C1(with MPG)


MACHINE OPERATOER PANEL B A8 I/O Module (for Machine Operator Panel )
I/O MODULE WITH LCD A8 LCD display embedded I/O
://

UNKNOWN UNIT - Unsupported I/O Unit


tp
ht

- 287 -
6.OPERATION B-63823EN/02

I/O Link–II Parameter Setting Screen


In case of using the I/O Link–II function, set the following I/O
Link–II parameter on this screen. Depending on the kind of I/O
Link–II interface board, master/slave screen is displayed
automatically.

/
Please refer to FANUC I/O Link–II Operator’s Manual (B–62714EN)

om
about details of I/O Link–II and each parameter.

(1) Set parameters.


Move the cursor to the parameter by using the cursor key.
Type the data and press the soft key[INPUT] or MDI

s.c
key<INPUT>.
The set parameter is saved to the I/O Link–II board when the
data is input.
(2) Change channel.

re
Change the channel by the soft key [PRV.CH],[NXT.CH]. These
keys are not displayed when the single channel is used.
(3) Delete parameter.

pa
Move the cursor to the parameter by using the cursor key.
Press the soft key[DELETE].
(4) Delete all parameters.
Press the soft key[DELALL].
cs
Press the soft key[EXEC] to delete all parameters.
Press the soft key[CANCEL] to cancel the deletion.
(5) Change page.
.cn

This screen is composed of two pages when the 9 inch CRT is


used.
Change the page by using (PAGE) key of MDI.
(6) Re–start I/O Link–II
Press the soft key [START] to re–start I/O Link–II after editing
w

the parameter.
When the re–start is completed normally, ”LINK STARTED” is
displayed.
w

If the re–start fails, ”START ERROR” is displayed. In this case,


check the parameter that is set.
w

NOTE
The PMC address of this screen is displayed in
://

PMC-SB7 address.
It is not displayed in PMC-SD7 address.
tp
ht

- 288 -
B-63823EN/02 6.OPERATION

6.4 DISPLAYING AND SETTING THE PMC PARAMETERS


(PMCPRM)

6.4.1 Overview

/
om
Pressing the [PMCPRM] soft key causes the PMCPRM screen to
appear.
The PMC parameters in the permanent memory areas (%MK, %SK
and % R) can be displayed and set using the CNC display.

s.c
6.4.2 Input PMC Parameters from MDI Panel
Usually, no data can be entered for PMC parameters because they are

re
protected. The following two methods can be used to make it possible
to enter data for them.
• If the sequence program is running (RUN state) (usually, this

pa
method should be used when the machine is operating.)
i) Place the NC in MDI mode or bring it to an emergency
stop.
ii) Set “PWE” on the NC setting screen to 1 (see the following
cs
table).
iii) Alternatively, set the program protect signal (KEY4) to 1
(only if data register tables are involved).
.cn

iv) The parameters are released from protection; so data can be


entered for them (see the following table).
PWE KEY4

KEEP RELAY
w

O
(%MK, %SK)
DATA REGISTER TABLE
O O : Alternative
(%R)
w

v) After entering data for the parameters, return “PWE” or the


KEY4 signal to the previous state.

w

If the sequence program can be stopped (STOP state), for


example, while it is being debugged
i) Stop the sequence program.
://

ii) The parameter protection is released; so data can be entered


for them.
tp

WARNING
If a sequence program is stopped while the
machine is operating, the machine may behave
ht

unexpectedly. Before stopping the sequence


program, make sure that nobody is near the
machine and that the tool cannot interfere with the
workpiece or machine. Incorrect operation of the
machine presents an extreme risk of death or
serious injury to the user. Damage the tool,
workpiece, and/or the machine is also likely.

- 289 -
6.OPERATION B-63823EN/02

An attempt to enter data for protected parameters causes the error


message “WRITE PROTECT” to be displayed. Please refer to "Screen
for displaying General settings (GENERAL)" in Subsection 6.4.4.

Multiple Data Input

/
om
1 This function is effective on the screen of KEEP RELAY and
DATA REGISTER TABLE.
2 The cursor is moved to the final data position of inputted data.
(1) Input method
• “ ; (EOB)” is used for separating data.

s.c
Press the INPUT key after typing “100; 200; 300”.
• “ ; =” is used for inputting the same value as preceding
data.
Press the INPUT key after typing “100; =; =; 200; =”,

re
and it becomes “100, 100, 100, 200, 200”.
• “ ; ;” is used for skipping an input address.
Press the INPUT key after typing “100; ; 100”.

pa
The second data is not inputted.
cs
.cn
w
w
w
://
tp
ht

- 290 -
B-63823EN/02 6.OPERATION

6.4.3 Setting and Display Screen

Keep Relay (KEEPRL [%MK, %SK])

- KEEPRL [%MK]

/
The %MK Relays and the Data for controlling nonvolatile memory

om
are set and displayed on this screen.

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 291 -
6.OPERATION B-63823EN/02

- KEEPRL [%SK]
For %SK, the system area used by the management software is
divided.

/
om
s.c
re
pa
cs
NOTE
Be careful of using the %SK Relays, because they
are used by PMC Management Software.
.cn

%SK is displayed by the setup of the GENERAL


screen of PMC setting. Refer to “Screen for
displaying General settings (GENERAL)” in
Subsection 6.4.4.
w

%SK00002 0: The programmer function is disabled.


#EN_PRG 1: The programmer function is enabled.
w

WARNING
w

Set this bit to 0 before shipment from the factory. If


the bit setting is left as 0, the operator may stop
execution of the ladder diagram by mistake, and
://

cause an accident.

%SK00003 0: The sequence program is executed automatically when the power is


tp

turned on.
#RUN_NAT 1: The sequence program is executed when the [RUN] soft key is
pressed.
ht

%SK00005 0: Data cannot be entered at the FORCING screen.


#EN_RAM 1: Data can be entered at the FORCING screen.

WARNING
Set this bit to 0 before shipment from the factory.

- 292 -
B-63823EN/02 6.OPERATION

%SK00008 0: The PMC parameter data register table control screen is displayed.
#NEN_DTC 1: The PMC parameter data register table control screen is not displayed.

%SK00014 0: The parity of the sequence program is checked.


1: The parity of the sequence program is not checked.

/
%SK00015 0: Prevents the edit (input) operation of the sequence program.

om
#EN_IN 1: Allows the edit (input) operation of the sequence program.

%SK00017 0: The program is not automatically written to F-ROM.


#FROM_AT 1: After a sequence program has been updated, the program is
automatically written to F-ROM.

s.c
%SK00019 0: Prevents run/stop and edit (input) operation of the sequence program.
#DSP_RUN 1: Allows run/stop and edit (input) operation of the sequence program.

re
%SK00023 0: The PMC parameter screen is displayed.
#HIDEPRM 1: The PMC parameter screen is not displayed.

%SK00024
#PRTCPRM
0:
1: pa
The PMC parameter can be changed.
The PMC parameter cannot be changed.
cs
%SK00054 0: In the trace function, tracing starts when the [EXEC] soft key is
pressed.
#TRC_AT 1: In the trace function, tracing starts automatically when the power is
.cn

turned on.

CAUTION
Set to 0 the bit that is not used by PMC control
software.
w
w
w
://
tp
ht

- 293 -
6.OPERATION B-63823EN/02

Data Register Table (DATA [%R])


DATA REGISTER TABLE consists of 2 screens, that is, Data
Register Table Controlling Data screen and Data Register Table
screen.
(1) Data Register Table Controlling Data Screen

/
Data Register Table Controlling Data Screen for controlling Data

om
Register Table is displayed by pressing the soft key [DATA].

Group No.
The top address of Data Table
Table Parameters (Note)

s.c
Data type (0:1byte, 1:2bytes, 2:4bytes) (Note)
Page No. (Change pages with the page keys)

re
The number of group of Data Table
The data numbers of each Data Table

pa
cs
.cn

You can initialize the Data Table setting data.


w

Press this key after typing the group No, and the cursor is moved to the group.
w

Press this key after typing the number of group, and the Group Table Count is set.
You can change the screen to Data Table.
w

NOTE 0: Binary
1: BCD
Table Parameter
://

#7 #6 #5 #4 #3 #2 #1 #0
0: Available to input
1: Unavailable to input (Protection mode)
tp

0: Binary or BCD (The bit 0 is valid.)


1: Hexadecimal (The bit 0 is invalid.)
ht

Data type
TYPE DATA FORM LENGTH
0 SINT, USINT, BYTE 1 byte
1 INT, UINT, WORD 2 bytes
2 DINT, UDINT, DWORD 4 bytes

- 294 -
B-63823EN/02 6.OPERATION

(2) Data Register Table Screen


If the Data Register Table Controlling Data is set, Data Register
Table Screen is displayed by pressing the soft key [G.DATA].
Group No.

/
Page No.

om
(Change pages with the page keys)

The address used by sequence program

s.c
re
pa
cs
Press this key after typing the address (ex. “%R8” %R can be omitted), and the cursor is
.cn

moved to the address in the current group.

If you search the Data Table in the other group, press this key after typing the group No.,
and the cursor is moved to the top of the address in the specified group.
w

You can change the screen to Data Table Controlling Data.


w
w
://
tp
ht

- 295 -
6.OPERATION B-63823EN/02

6.4.4 Setting Screen (SETING)


Pushing the [SETING] soft key on the PMC basic module screen
displays the following setting menu screen.

/
om
s.c
re
pa
cs
Contents of the menu.
.cn

1.GENERAL Screen for displaying general setting data.


2.EDIT/DEBUG Screen for displaying setting data related to editing
and debugging.
3.ONLINE Screen for displaying the communication settings
for the online-function. (It is displayed by setting
w

“PROGRAMMER ENABLE” to “YES” on the


GENERAL screen.)
w

Pushing the soft key, each SETTING screen is displayed. A part of the
setup value of this screen is stored in keep relay. It is possible to
prevent changes to the settings of this setting screen, using a sequence
w

program for writing to the keep relay.


://
tp
ht

- 296 -
B-63823EN/02 6.OPERATION

Screen for displaying General settings (GENERAL)


Pushing the [GEN] soft key displays the following screen.

(%SK54)
(%SK15)

/
(%SK5)

om
(%SK8)
(%SK23)
(%SK24)
(%SK1)
(%SK3)
(%SK19)
(%SK2)

s.c
re
pa
cs
• SIGNAL TRACE START (%SK54)
MANUAL (0): It executes by pushing the [START] soft key on
the SIGNAL TRACE screen.
.cn

AUTO (1): Starts the tracing automatically after the power


turns on.

• EDIT ENABLE (%SK15)


w

NO (0): Prevents editing of the sequence program.


YES (1): Allows editing of the sequence program.
w

NOTE
This setting effects some PMC functions.
Please refer to "Programmer protection function" in
w

Subsection 6.4.4.
://

• RAM WRITE ENABLE (%SK5)


NO (0): Prevents forcing function.
YES (1): Allows forcing function.
tp

NOTE
This setting effects some PMC functions.
ht

Please refer to "Programmer protection function" in


Subsection 6.4.4.

- 297 -
6.OPERATION B-63823EN/02

• DATA REGISTER TABLE CONTROL SCREEN (%SK8)


YES (0): Displays PMC parameter data register table control screen.
NO (1): Does not displays PMC parameter data register table
control screen.

/
• HIDE PMC PARAMETER (%SK23)

om
NO (0): Allows PMC parameter display.
YES (1): Prevents PMC parameter display.

NOTE

s.c
This setting effects some PMC functions.
Please refer to "Programmer protection function" in
Subsection 6.4.4.

re
• PROTECT PMC PARAMETER (%SK24)
NO (0): The PMC parameter can be changed.
YES (1): The PMC parameter cannot be changed.

NOTE
pa
This setting effects some PMC functions.
cs
Please refer to "Programmer protection function" in
Subsection 6.4.4.
.cn

• HIDE PMC PROGARAM (%SK1)


NO (0): Allows the edit (output) operation of the sequence
program.
YES (1): Prevents the edit (output) operation of the sequence
w

program.
w

NOTE
This setting effects some PMC functions.
w

Please refer to "Programmer protection function" in


Subsection 6.4.4.
://

• LADDER START (%SK3)


AUTO (0): Executes the sequence program automatically after
the power turns on.
tp

MANUAL (1): Executes the sequence program by [RUN] soft key.


ht

- 298 -
B-63823EN/02 6.OPERATION

• ALLOW PMC STOP (%SK19)


NO (0): Prevents run/stop operation of the sequence program.
YES (1): Allows run/stop operation of the sequence program.

NOTE

/
This setting effects some PMC functions.

om
Please refer to "Programmer protection function" in
Subsection 6.4.4.

• PROGRAMMER ENABLE (%SK2)

s.c
NO (0): Disables embedded programmer function.
YES (1): Enables embedded programmer function.

NOTE

re
This setting effects some PMC functions.
Please refer to "Programmer protection function" in
Subsection 6.4.4.

pa
cs
.cn
w
w
w
://
tp
ht

- 299 -
6.OPERATION B-63823EN/02

Screen for Displaying the Setting Data Related to Editing and Debugging
(EDTDBG)

(%SK17)

/
(%SK49)

om
s.c
re
pa
cs
• WRITE TO FROM (EDIT) (SK17)
NO (0): The sequence program is not automatically written to
F-ROM after reading in I/O screen.
.cn

YES (1): The sequence program is automatically written to F-ROM


after reading in I/O screen.

• OVERRIDE ENABLE (SK49)


w

NO (0): The override mode becomes disabled.


YES (1): The override mode becomes enabled.
This screen is displayed in the case of
w

“PROGRAMMERENABLE=YES” or “RAM WRITE


ENABLE=YES”.
w

CAUTION
This parameter is effective when turning on the
://

power supply after setting. Turn on the power


supply if setting this parameter.
Set this parameter “NO” when the machine is
tp

shipped.
ht

- 300 -
B-63823EN/02 6.OPERATION

Programmer Protection Function

CAUTION
This section contains important information for
developers of application system controlled by

/
PMC. Improperly implemented application system

om
may increase possibility of defects in its safety.
Careful examinations and considerations on using
and implementing with the functions explained
especially in this section are strongly required.

s.c
PMC system provides various embedded programmer functions such
as edit, diagnosis and debugging which help the programming and
debugging of sequence program. To use these functions which may
even disable safety mechanism realized by sequence program, it is

re
required that the operator of these functions should be an expert who
fully understands the sequence program and the operation of PMC. It
is also strongly recommended to the developer of machine that these
pa
functions should be protected from careless use by ordinary operators
after the machine is shipped into the field. Furthermore, if these
functions partly need to be used in the field for any purpose such as
cs
the maintenance or adjustment, the developer of the machine should
implement any means to enable these functions after forcing the
machine in safe mode or should
.cn

let the operator know and strictly follow proper procedure to ensure
the safety.
The setting parameters described in this section are provided for the
developer of machine to be able to properly program the sequence or
control the parameters for necessary conditions on which the operator
w

is allowed to use PMC programmer functions safely by eliminating


careless operation which may cause ”stopping the ladder”, ”changing
sequence program” or ”changing important setting data”.
w

These parameters can be set on the setting screen or in some system


keep relays (%SK1=1).
w
://
tp
ht

- 301 -
6.OPERATION B-63823EN/02

PROGRAMMER ENABLE (%SK2)


If you set ”PROGRAMMER ENABLE ” to ”YES”, it enables the
following functions as a supervisor mode.
• Start/stop of ladder
• Forcing function

/
• Override function *1

om
• I/O screen
• Online setting screen
• Setting screen for keep relay %SK

NOTE

s.c
The override function also requires the setting
of ”OVERRIDE ENABLE” in the setting
parameters.

re
CAUTION
Set this setting to ”NO”(0) before shipment of the
machine. If this setting is left as ”YES”(1), the
pa
operator may stop execution of the ladder program
by mistake. If you want to protect this setting,
please make a sequence that always writes 0 in
cs
this bit by your ladder.

HIDE PMC PROGRAM (%SK1)


.cn

If you set ”HIDE PMC PROGRAM” to ”YES”, it disables the


following functions which have the sequence program display.
• Writing of sequence program on the I/O screen
w

NOTE
Even if this parameter is set to "YES", these
settings are invalid if "PROGRAMMER ENABLE" is
w

set to "YES".
w

EDIT ENABLE (%SK15)


If you set ”EDIT ENABLE” to ”YES”, it enables the following
functions which can edit the program.
://

• Reading of sequence program on the I/O screen *1


• Setting screen for keep relay %SK
tp

NOTE
These screens with stop of ladder program require
ht

below setting ”ALLOW PMC STOP”.

CAUTION
Set this setting to ”NO”(0) before shipment of the
machine if you want to prohibit operator form
editing the program. If you want to protect this
setting, please make a sequence that always
writes 0 in this bit by your ladder.
- 302 -
B-63823EN/02 6.OPERATION

ALLOW PMC STOP (%SK19)


If you set ”ALLOW PMC STOP” to ”YES”, it enables the following
functions which require stop/start of ladder program.
• Reading of sequence program on the I/O screen *1
• Start/stop of ladder

/
om
CAUTION
Set this setting to ”NO”(0) before shipment of the
machine if you want to prohibit operator form
editing the program. If you want to protect this
setting, please make a sequence that always

s.c
writes 0 in this bit by your ladder.

RAM WRITE ENABLE (%SK5)

re
If you set ”RAM WRITE ENABLE” to ”YES”, it enables both the
forcing function and the override function.

NOTE
pa
The override function also requires the setting
of ”OVERRIDE ENABLE” in the setting parameters
(EDIT/DEBUG).
cs
DATA REGISTER TABLE CONTROL SCREEN (%SK8)
.cn

If you set ”DATA REGISTER TABLE CONTROL SCREEN”


to ”NO”, the data register table control screen does not be displayed.

HIDE PMC PARAMETER (%SK23)


If you set ”HIDE PMC PARAMETER” to ”YES”, the PMC parameter
w

screen does not be displayed.


w

NOTE
Even if this parameter is set to "YES", these
settings are invalid if "PROGRAMMER ENABLE" is
w

set to "YES".

PROTECT PMC PARAMETER (%SK24)


://

If you set "PROTECT PMC PARAMETER" to "YES", the PMC


parameter does not change by reading of the I/O screen.
tp

NOTE
Even if this parameter is set to "YES", these
ht

settings are invalid if "PROGRAMMER ENABLE" is


set to "YES".

- 303 -
6.OPERATION B-63823EN/02

EXAMPLE FOR SETTING PARAMETERS


(1) If you want to prohibit completely operator from accessing the
sequence program;
PROGRAMMER ENABLE (%SK2) ”NO”
HIDE PMC PROGRAM (%SK1) ”YES”

/
EDIT ENABLE (%SK15) ”NO”

om
ALLOW PMC STOP (%SK19) ”NO”

(2) If you want to allow operator only monitoring the sequence


program;
PROGRAMMER ENABLE (%SK2) ”NO”

s.c
HIDE PMC PROGRAM (%SK1) ”NO”
EDIT ENABLE (%SK15) ”NO”
ALLOW PMC STOP (%SK19) ”NO”

re
(3) If you want to allow operator monitoring and editing the
sequence program;
PROGRAMMER ENABLE (%SK2) ”NO”

EDIT ENABLE
pa
HIDE PMC PROGRAM

ALLOW PMC STOP


(%SK1)
(%SK15)
(%SK19)
”NO”
”YES”
”NO”
cs
(4) If you want to allow operator monitoring and editing the
sequence program which requires stop of ladder;
PROGRAMMER ENABLE (%SK2) ”NO”
.cn

HIDE PMC PROGRAM (%SK1) ”NO”


EDIT ENABLE (%SK15) ”YES”
ALLOW PMC STOP (%SK19) ”YES”

WARNING
w

If a sequence program is stopped while the


machine is operating, the machine may behave
w

unexpectedly. Before stopping the sequence


program, make sure that nobody is near the
machine and that the tool cannot interfere with the
w

work–piece or machine. Incorrect operation of the


machine presents an extreme risk of death or
://

serious injury to the user. Damage the tool,


work–piece, and/or the machine is also likely.
tp
ht

- 304 -
B-63823EN/02 6.OPERATION

(5) The case that operator who familiar with the machine and the
ladder sequence operate all the PMC programmer functions;
PROGRAMMER ENABLE (%SK2) ”YES”
HIDE PMC PROGRAM (%SK1) ”NO”

/
WARNING

om
If a sequence program is stopped while the
machine is operating, the machine may behave
unexpectedly. Before stopping the sequence
program, make sure that nobody is near the
machine and that the tool cannot interfere with the

s.c
work–piece or machine. Incorrect operation of the
machine presents an extreme risk of death or
serious injury to the user. Damage the tool,
work–piece, and/or the machine is also likely.

re
Screen for Setting/Displaying Online Monitor Parameters (ONLINE)

pa
If PROGRAMMER ENABLE is set to YES on the GENERAL screen,
the [ONLINE] soft key appears on the setting menu screen. Pressing
this soft key displays the following screen.
cs
.cn
w
w
w
://

When you use the online function, the setting of communication


tp

condition is necessary in advance.

CAUTION
ht

When the online function is used with RS-232C,


the selected channel is occupied by the PMC
system. To use other input/output functions with
RS-232C, specify other channel setting than the
one used by online function.

- 305 -
6.OPERATION B-63823EN/02

Menu descriptions
• CPU ID
The CPU ID value is displayed. The value can also be entered here,
but its entry is usually not necessary.
• RS-232C (prompt)

/
USE: An RS-232C port can be connected to FANUC

om
LADDER-IIIC.
NOT USE: RS-232C port is not used.
Note) If no RS-232C is to be connected to FANUC LADDER-IIIC,
select NOT USE.
• CHANNEL

s.c
A channel number to be used is displayed. The number can also be
entered.
• BAUD RATE
300: A baud rate of 300 is specified.

re
600: A baud rate of 600 is specified.
900: A baud rate of 900 is specified.
1200: A baud rate of 1200 is specified.

pa
2400: A baud rate of 2400 is specified.
4800: A baud rate of 4800 is specified.
9600: A baud rate of 9600 is specified.
19200: A baud rate of 19200 is specified.
cs
• PARITY
NONE: No parity is specified.
ODD: Odd parity is specified.
.cn

EVEN: Even parity is specified.


• STOP BIT
1 BIT: The number of stop bits is set to 1.
2 BITS: The number of stop bits is set to 2.
• TIMER 1
w

The value in communication parameter timer 1 is displayed. The value


can also be entered, but its specification is usually not necessary.
w

• TIMER 2
The value in communication parameter timer 2 is displayed. The value
can also be entered, but its specification is usually not necessary.
w

• TIMER 3
The value in communication parameter timer 3 is displayed. The value
can also be entered, but its specification is usually not necessary.
://

• MAX PACKET SIZE


The maximum packet size for the communication parameter is
displayed. The size can also be entered, but its specification is usually
tp

not necessary.
• RS-232C (status display)
The status of an RS-232C port is displayed.
ht

INACTIVE: No RS-232C port is in use.


STOPPING: An RS-232C port is closed.
STARTING: An RS-232C port is open.
STAND-BY: An RS-232C port is waiting to be connected to
FANUC LADDER-IIIC.
CONNECTED: An RS-232C port has been connected to FANUC
LADDER-IIIC.

- 306 -
B-63823EN/02 6.OPERATION

If the high speed interface is included in the system configuration, the


HIGH SPEED I/F prompt menu appears above the RS-232C status
display menu, and the HIGH SPEED I/F status display menu appears
below the RS-232C status display menu.
• HIGH SPEED I/F (prompt)

/
USE: A HIGH SPEED I/F port can be connected to FANUC
LADDER-IIIC.

om
NOT USE: No HIGH SPEED I/F port will be connected to FANUC
LADDER-IIIC.
• HIGH SPEED I/F (status display)
The status of a HIGH SPEED I/F port is displayed.

s.c
INACTIVE: No HIGH SPEED I/F port is in use.
STOPPING: A HIGH SPEED I/F port is closed.
STARTING: A HIGH SPEED I/F port is open.
STAND-BY: A HIGH SPEED I/F port is waiting to be connected to
FANUC LADDER-IIIC.

re
CONNECTED: A HIGH SPEED I/F port has been connected to
FANUC LADDER-IIIC.

pa
Soft key descriptions
[EMG ST]: Pressing this key causes communication to be
terminated. It is used if it is impossible to terminate a
cs
connection due to abnormal communication.
[INIT]: Pressing this key initializes the parameter settings.
.cn

Setting of online connection


To communicate with FANUC LADDER-IIIC, you need to put the
PMC system in waiting situation of the connection. There are two
ways for setting this, setting at PMC screen and setting in NC
parameter. Also, there are three connection types, for example
w

Ethernet or RS-232C.
w

(a) How to set at PMC Screen


To display the soft key [ONLINE] in the PMC setting menu
screen, set “PROGRAMMER ENABLE” to “YES” in the setting
w

screen. When pushing the soft key [SETING]->[ONLINE], the


online setting screen is displayed.
://

1. Case of connection by RS-232C (FANUC LADDER-IIIC)


(1) Check that “NOT USE” is selected at the “RS-232C”
item.
tp

(2) Set the parameter of “CHANNEL” and “BAUD


RATE”.
(3) Move the cursor to the “RS-232C” item with Up or
ht

Down Cursor key.


(4) Select “USE” with Left or Right Cursor key.

2. Case of connection by Ethernet (FANUC LADDER-IIIC)


(1) Move the cursor to the “HIGH SPEED I/F” item with
Up or Down Cursor key.
(2) Select “USE” with Left or Right Cursor key.

- 307 -
6.OPERATION B-63823EN/02

NOTE
1 When both "RS-232C = USE" and "HIGH SPEED
I/F = USE" are selected, the PMC system will
communicate with the application which is
connected at first. If PMC system is already

/
connecting with an application, it can not connect

om
with other applications.
2 When you use the online function by Ethernet, the
setting of Ethernet parameters at CNC is
necessary in advance.

s.c
(b) Setting of online connection by NC parameter
You can enable and disable the online connection for Ethernet
and RS-232C by NC parameter No.24 without setting on the
PMC online monitor setting screen. This NC parameter is made

re
effective immediately after setting the parameter.
If the value of this parameter is changed, the items
“RS232-C”and “HIGH SPEED I/F” in the online monitor screen

NC
pa
are automatically changed too. Please refer to following table.
Contents of NC parameter No.24.
Each item of the online monitor
cs
parameter Meanings screen after setting
No.24 RS-232C HIGH SPEED I/F
This does not affect “RS-232C”
0 The settings on the online monitor setting screen are effective.
.cn

and “HIGH SPEED I/F”.


USE
1 Enables “Channel 1 of RS-232C” and disables “HIGH SPEED I/F”. NOT USE
(Channel 1)
USE
2 Enables “Channel 2 of RS-232C” and disables “HIGH SPEED I/F”. NOT USE
(Channel 2)
w

10 Disables “RS-232C” and enables “HIGH SPEED I/F”. NOT USE USE
USE
11 Enables “Channel 1 of RS-232C” and “HIGH SPEED I/F”. USE
(Channel 1)
w

USE
12 Enables “Channel 2 of RS-232C” and “HIGH SPEED I/F”. USE
(Channel 2)
3 to 10
w

Reserve (Don’t use this setting.) (Reserved) (Reserved)


13 to 254
Terminates communication forcibly.
255 NOT USE NOT USE
It is the same effect as soft key [EMG ST].
://

NOTE
The Smart Download to PMC and the Verify
tp

Equality with the Logic of the FANUC LADDER-IIIC


are only supported by HIGH SPEED I/F.
RS232C does not support these functions.
ht

How to set the parameter


(1) Display the No.24 of NC parameter.
(2) To connect by Ethernet, input “10”, “11” or “12”.
(3) To connect by RS-232C, input “1”, “2”, “11” or “12”.

- 308 -
B-63823EN/02 6.OPERATION

NOTE
Even if the setting of the online monitor screen of
PMC is changed, the value of No.24 in NC
parameter is not changed

/
Setting of Ethernet parameters

om
When you try to connect FANUC LADDER-IIIC with PMC by
Ethernet, it is necessary to set some Ethernet parameters. The setting
of Ethernet parameters can be set in the following Ethernet parameter
screen of CNC. Please refer to “FANUC Ethernet Board/DATA
SERVER Board OPERATOR'S MANUAL” (B-63354EN) about the

s.c
detail of the setting screen and setting parameters. The setting item
necessary for Ethernet connection for PMC online function is as
follows.

re
• IP ADDRESS (Set the IP address of CNC. 192.168.0.1 etc.)
• SUBNET MASK(Set the mask address of the IP address.
255.255.255.0 etc.)

pa
• ROUTER IP ADDRESS (If you use the router, set the Router IP
Address.)
• PORT NUMBER (TCP) (8193 etc.)
cs
.cn

Fig. (a)
Ethernet Board
w
w
w

Fig. (b)
Embedded Ethernet
://
tp
ht

Fig. (c)
Ethernet Card (PCMCIA)

- 309 -
6.OPERATION B-63823EN/02

Communication Status
The communication status of RS-232C and HIGH SPEED I/F are
displayed at the online monitor screen during the online
communication.

/
om
s.c
re
pa
cs
USE TIME : The maximum time in the communication processing is displayed.
RS-232C : The communication condition of RS-232C is displayed.
HIGH SPEED I/F : The communication condition of HIGH SPEED I/F is displayed.
.cn

Displayed during the communication with Ethernet board.


ETHER_BOARD :
The IP address of the communication partner is displayed.
Displayed during the communication with embedded Ethernet.
EMB_ ETHERNET :
The IP address of the communication partner is displayed.
w

The display messages and the meanings are shown in the table of
below.
Displayed messages Meanings
w

INACTIVE The communication is inactive.


The communication is being stopped.
STOPPING
(Wait for the termination of communication)
w

The communication is being started.


STARTING
(Wait for the termination of communication over another communication path)
STAND-BY The communication is active and in standby mode.
://

CONNECTED The communication is active and being connected.


NO OPTION The port can be not opened because there is not option of RS-232C.
BAD PARAMETER Invalid open parameters are specified.
tp

TIMEOUT ERROR A time-out has occurred and communication is aborted.


TIMEOUT(K) ERROR A time-out has occurred and communication is aborted.
BCC ERROR A Block Check Code (packet parity) error has occurred.
ht

PARITY ERROR A parity error has occurred.


OVER-RUN ERROR A reception overrun has occurred and the communication can not recover.
Packets are out of sequence.
SEQUENCE ERROR
(Incorrect procedure)
DATA ERROR Incorrect packets have been received through retry process.
QUEUE OVERFLOW The transmit/receive queue has overflowed.
DISCONNECTED Communication has been terminated successfully.
NO CONNECTION The cable is disconnected.

- 310 -
B-63823EN/02 6.OPERATION

6.5 SEQUENCE PROGRAM EXECUTION

6.5.1 Starting and Stopping a Sequence Program

/
(1) Starting a sequence program (RUN)

om
When a program is stopped, clicking the [RUN] soft key causes
the program to start and the status line display to change to
“PMC RUN.”
The sequence program starts from the beginning. The soft key
changes to [STOP].

s.c
(2) Stopping a sequence program (STOP)
When a program is executed, clicking the [STOP] soft key causes
the program to stop and the status line display to change to
“PMC STOP.”

re
The soft key changes to [RUN].

WARNING

pa
If the sequence program is stopped while the
machine is operating, the machine may behave in
an unexpected way.
cs
Before stopping the sequence program, ensure
that there are no people near the machine and that
the tool cannot collide with the workpiece or
.cn

machine.
Otherwise, there is an extreme risk of death or
serious injury, as well as the likelihood of the tool,
workpiece, and machine being damaged.
w

(3) Automatic operation of a sequence program


When AUTOMATIC LADDER START is set to AUTO (the
w

keep relay %SK3 = 0) on the setting screen, a sequence program


can be executed automatically when the power is turned on.
w

6.5.2 Forced Termination of Sequence Program


://

To forcibly stop starting the sequence program at power-on, turn on


the power by pressing the [Z] key while pressing the [CAN] key. This
method is effective for locating the error when a system error occurs
tp

after power is turned on and when the error may be caused by the
sequence program.
Never perform this operation in a normal state.
ht

WARNING
In normal operation, do not use the Z + CAN keys
to stop the sequence program forcibly.

- 311 -
6.OPERATION B-63823EN/02

6.6 WRITING, READING, AND VERIFYING THE SEQUENCE


PROGRAM AND PMC PARAMETER DATA (I/O)

6.6.1 I/O Screen

/
om
When the [I/O] soft key on the PMC main menu is pressed, the
following screen appears.

s.c
re
pa
cs
.cn

On this screen, sequence programs and PMC parameters can be


written to the specified device, read from the device, and compared.
The question selection cursor, which moves vertically from one
question to another, is displayed, as is the option selection cursor,
w

which moves horizontally from one option to another. The displayed


soft keys differ depending on the position of the question selection
cursor.
w

The following types of devices can be used for input/output. The


desired device type can be selected by positioning the question
w

selection cursor to “DEVIDE” and either moving the option selection


cursor to that type or selecting the soft key corresponding the type.
://

MEMORY Data can be output to and input from a memory


CARD card.
FLASH ROM Data can be output to and input from frash ROM.
tp

FLOPPY Data can be output to and input from handy files


or floppy cassettes.
OTHERS Data can be output to and input from other
ht

input/output devices.

- 312 -
B-63823EN/02 6.OPERATION

When you read a file from an I/O device, one of following messages
appear and whether to operate the important thing is confirmed.

<WARNING> READING SEQUENCE PROGRAM OR PMC PARAMETER


REQUIRES SPECIAL CARE.
* READING IMPROPER DATA MAY CAUSE UNEXPECTED

/
MOVEMENT OF MACHINE.

om
* PROGRAM WILL BE STOPPED BY READING SEQUENCE
PROGRAM.
ARE YOU SURE YOU WANT TO READ THIS FILE?

When you proceed to read PMC parameters, new PMC parameters

s.c
will be stored even if the ladder program is running. If the ladder and
the parameter are protected, the error message of "THIS FUCTION IS
PROTECTED" is displayed. Please refer to “Programmer Protection
Function” in Subsection 6.4.4.

re
WARNING
1 If a Ladder program is input while a Ladder
pa
program is being executed, the executions of the
Ladder program stop automatically by the setting
of GENERAL screen. You have to pay special
cs
attention to stop Ladder program. Stopping Ladder
program in a wrong timing, or with machine in
improper status, may cause unexpected reaction of
.cn

machine. You have to make it sure that machine


is in proper status, and nobody is near the machine
when you stop Ladder program.
2 At stopping Ladder program, it may take rather
w

long time to completely stop it in some cases


according to the activity of Ladder program. If
Ladder takes too long time to stop, or never stop,
w

correct Ladder program.


3 If the PMC parameters are input while a Ladder
w

program is being executed, You have to special


attention to input it. Because changed PMC
parameters, may cause unexpected effect to
://

Ladder. You have to make it sure that PMC


parameters are not effect to Ladder when you input
PMC parameters.
tp

4 Set keep relay %SK2 to 0 when the machine tool is


shipped.
ht

- 313 -
6.OPERATION B-63823EN/02

In STATUS in the lower part of the screen, a detailed explanation of


execution and the execution status are displayed. During write, read,
and comparison, the size of the data already transferred is indicated as
the execution (intermediate) result.
The following gives a display example shown when PMC parameters
are written to a memory card:

/
om
s.c
re
pa
cs
NOTE
1 For an explanation of error messages on I/O
.cn

screen, see Subsection 6.6.9, “I/O screen Error


Messages”.
2 The conditions of outputting PMC parameters
1) When sequence program is stopped
w

You can input/output them.


2) When sequence program is executed
You must satisfy the following conditions.
w

Output (WRITE) Set NC to “EDIT” mode.


Input (READ) Set NC to “Emergency Stop”
status, and, set “PWE” of NC
w

parameters to 1.
://
tp
ht

- 314 -
B-63823EN/02 6.OPERATION

6.6.2 Outputting to and Inputting from Memory Cards

/
om
s.c
re
pa
When “MEMORY CARD” is selected for DEVICE, output to and input
cs
from memory cards are enabled.
• FUNCTION
A data I/O command appears. Select FUNCTION with the item select
.cn

cursor, then select an item by moving the content select soft key
horizontally or pressing an appropriate soft key.

Soft keys displayed when the question selection cursor is positioned to


“FUNCTION”
w
w

Explanation of options
WRITE: Outputs data from the PMC to a memory card.
READ: Inputs data from a memory card to the PMC.
w

COMPARE: Compares the sequence programs on the PMC


with those on a memory card.
DELETE: Deletes files from a memory card. (Files on a
://

flash card cannot be deleted.)


FORMAT: Formats a memory card.
tp

CAUTION
When “FORMAT” is selected and executed, all
data in the memory card is lost. Be careful when
ht

executing this function.

- 315 -
6.OPERATION B-63823EN/02

When you read a file from a memory card, one of following messages
appear and whether to operate the important thing is confirmed.

<WARNING> READING SEQUENCE PROGRAM OR PMC PARAMETER


REQUIRES SPECIAL CARE.
* READING IMPROPER DATA MAY CAUSE UNEXPECTED

/
MOVEMENT OF MACHINE.

om
* PROGRAM WILL BE STOPPED BY READING SEQUENCE
PROGRAM.
ARE YOU SURE YOU WANT TO READ THIS FILE?

When you proceed to read PMC parameters, new PMC parameters

s.c
will be stored even if the ladder program is running. If the ladder and
the parameter are protected, the error message of "THIS FUCTION IS
PROTECTED" is displayed. Please refer to “Programmer Protection
Function” in Subsection 6.4.4.

re
WARNING
1 If a Ladder program is input while a Ladder
pa
program is being executed, the executions of the
Ladder program stop automatically by the setting
of GENERAL screen. You have to pay special
cs
attention to stop Ladder program. Stopping Ladder
program in a wrong timing, or with machine in
improper status, may cause unexpected reaction of
.cn

machine. You have to make it sure that machine


is in proper status, and nobody is near the machine
when you stop Ladder program.
2 At stopping Ladder program, it may take rather
w

long time to completely stop it in some cases


according to the activity of Ladder program. If
Ladder takes too long time to stop, or never stop,
w

correct Ladder program.


3 If the PMC parameters are input while a Ladder
w

program is being executed, You have to special


attention to input it. Because changed PMC
parameters, may cause unexpected effect to
://

Ladder. You have to make it sure that PMC


parameters are not effect to Ladder when you input
PMC parameters.
tp

4 Set keep relay %SK2 to 0 when the machine tool is


shipped.
ht

• KIND OF DATA
KIND OF DATA is displayed only when “WRITE” is selected for
“FUNCTION.”
Set the type of data to be output by moving the cursor horizontally to
that type or by pressing the corresponding soft key.
Soft keys displayed when the question selection cursor is positioned to
“KIND OF DATA”

- 316 -
B-63823EN/02 6.OPERATION

Explanation of options
PROGRAM: Outputs sequence programs only.
PARAMETER: Outputs PMC parameters.
• FILE NO.

/
om
FILE NO. is displayed only when “READ,” ”COMPARE,” or
“DELETE” is selected for “FUNCTION.”
Enter the file number in the edit box.
• FILE NAME
FILE NAME is displayed when “WRITE,” “READ,” “COMPARE,”

s.c
or “DELETE” is selected for “FUNCTION.”
Enter the file name in the edit box.
When “READ,” “COMPARE,” or “DELETE” is selected for
“FUNCTION,” the file name corresponding to the file number entered

re
in “FILE NO.” is displayed automatically.
The file name must be in MS-DOS format: a file name of up to 8
characters followed by an extension of up to 3 characters.

DATA KIND
LADDER
pa
When “WRITE” is selected for “FUNCTION” and the file name is not
entered, the following names are automatically assumed.
File name
PMCSD7.LAD
cs
PARAM PMCSD7.PRM

CAUTION
.cn

When both “FILE NO.” and “FILE NAME” are


displayed at the same time, and a value is entered
for “FILE NO.” and another file name is entered in
“FILE NAME,” the value entered in “FILE NO.” is
w

erased and the file name entered in “FILE NAME”


becomes effective.
w

Explanation of soft keys


[EXEC]: Executes the function selected for “FUNCTION.”
During execution, the soft key disappears and the
w

[CANCEL] soft key appears to the right of the key.


[CANCEL]: Cancels the execution of the function. When the
://

function terminates normally, the soft key disappears.


[LIST]: Replaces the current display with the memory card
list screen. See Subsection 6.6.3 “Memory Card List
Screen” for details.
tp

The system supports the following memory cards:


ht

O: Supported
X: Not supported
SRAM Flash Memory Card ATA
Card Supported Card Unsupported Card Card
Read of a file O O O O
Format of a card O O X O
Write of a file O O X O
Delete of a file O X X O
List of a file O O O O

- 317 -
6.OPERATION B-63823EN/02

6.6.3 Memory Card List Screen


When MEMORY CARD is selected in DEVICE, pressing the [LIST]
soft key displays the following screen:

/
om
s.c
re
pa
If a memory card holding files is in the slot, the contents of the
memory card are displayed as shown in the above.
cs
NOTE
Up to 128 files can be displayed on this screen.
When 129 or more files are saved in the memory
.cn

card, the 129th and subsequent files are ignored.

When a file is selected on this screen, the screen display can be


returned to the previous screen. To select a file, place the cursor at the
w

name of the file, then press either the [SELECT] soft key or the
INPUT key. After the key entry, the screen display switches to the
previous screen automatically. In this case, the cursor is positioned at
w

READ on the FUNCTION menu, and the number and name of the file
selected on the list screen are indicated in the FILE NO. and FILE
NAME fields, respectively. A display example is shown below.
w
://
tp
ht

- 318 -
B-63823EN/02 6.OPERATION

/
om
s.c
re
To return the screen display to the previous screen without selecting a

pa
file, press the return key.
When the memory card is replaced with another card while the list
screen is being displayed, the displayed information is not updated
automatically. In this case, press the [REFRES] soft key. The contents
cs
of the new memory card are then displayed.
Explanation of soft keys
[SELECT]: Selects a file, and returns the screen display to the
.cn

previous screen.
[REFRES]: Redisplays the contents of the memory card.
w
w
w
://
tp
ht

- 319 -
6.OPERATION B-63823EN/02

6.6.4 Outputting to and Inputting from Flash ROM

/
om
s.c
re
pa
When “FLASH ROM” is selected for DEVICE, output to and input
from flash ROM are enabled.
cs
• FUNCTION
The available data input/output commands are displayed. Select the
.cn

desired command by moving the cursor horizontally to that


command or select it with the corresponding soft key.
Explanation of options
WRITE: Outputs sequence programs from the PMC to flash
ROM.
w

• KIND OF DATA
w

Explanation
PROGRAM: Outputs sequence programs only.
w

Explanation of soft keys


[EXEC]: Executes the function selected for “FUNCTION.”
://
tp
ht

- 320 -
B-63823EN/02 6.OPERATION

6.6.5 Outputting to and Inputting from Floppy

/
om
s.c
re
pa
When “FLOPPY” is selected for “DEVICE”, output to and input from a
floppy cassette or a handy file that is connected via RS-232C are enabled.
cs
• FUNCTION
The available data input/output commands are displayed. Select the
desired command by moving the cursor horizontally to that
.cn

command or select it with the corresponding soft key.


Soft keys displayed when the question selection cursor is positioned
to “FUNCTION”
w

Explanation of options
WRITE: Outputs data from the PMC to a floppy disk or
a handy file.
w

READ: Inputs data from a floppy disk or a handy file to


the PMC.
w

COMPARE: Compares the sequence program on the PMC


with those on a floppy disk or a handy file.
DELETE: Deletes a file from a floppy disk or a handy file.
://

When you read a file from a floppy cassette or a handy file, one of
following messages appear and whether to operate the important thing
tp

is confirmed.

<WARNING> READING SEQUENCE PROGRAM OR PMC PARAMETER


ht

REQUIRES SPECIAL CARE.


* READING IMPROPER DATA MAY CAUSE UNEXPECTED
MOVEMENT OF MACHINE.
* PROGRAM WILL BE STOPPED BY READING SEQUENCE
PROGRAM.
ARE YOU SURE YOU WANT TO READ THIS FILE?

- 321 -
6.OPERATION B-63823EN/02

When you proceed to read PMC parameters, new PMC parameters


will be stored even if the ladder program is running. If the ladder and
the parameter are protected, the error message of "THIS FUCTION IS
PROTECTED" is displayed. Please refer to “Programmer Protection
Function” in Subsection 6.4.4.

/
om
WARNING
1 If a Ladder program is input while a Ladder
program is being executed, the executions of the
Ladder program stop automatically by the setting
of GENERAL screen. You have to pay special

s.c
attention to stop Ladder program. Stopping Ladder
program in a wrong timing, or with machine in
improper status, may cause unexpected reaction of
machine. You have to make it sure that machine

re
is in proper status, and nobody is near the machine
when you stop Ladder program.
2 At stopping Ladder program, it may take rather
pa
long time to completely stop it in some cases
according to the activity of Ladder program. If
Ladder takes too long time to stop, or never stop,
cs
correct Ladder program.
3 If the PMC parameters are input while a Ladder
program is being executed, You have to special
.cn

attention to input it. Because changed PMC


parameters, may cause unexpected effect to
Ladder. You have to make it sure that PMC
parameters are not effect to Ladder when you input
w

PMC parameters.
4 Set keep relay %SK2 to 0 when the machine tool is
shipped.
w

• KIND OF DATA
w

“KIND OF DATA” is displayed only when “WRITE” is selected for


“FUNCTION”.
Set the type of data to be output by moving the cursor horizontally to
://

that command or select it with the corresponding soft key.


Soft keys displayed when the question selection cursor is positioned to
“KIND OF DATA”
tp

Explanation of options
ht

PROGRAM: Outputs sequence program.


PARAMETER: Outputs PMC parameters.

• FILE NO.
“FILE NO.” is displayed only when “READ”, “COMPARE”, or
“DELETE” is selected for “FUNCTION”.
Enter the file number in the edit box.

- 322 -
B-63823EN/02 6.OPERATION

• FILE NANE
“FILE NAME” is displayed when “WRITE”, “READ”, “COMPARE”,
or “DELETE” is selected for “FUNCTION”.
Enter the file name in the edit box.
When “READ”, “COMPARE”, or “DELETE” is selected for

/
“FUNCTION”, the file name corresponding to the file number entered
in “FILE NO.” is displayed automatically.

om
When you output to or input from a floppy disk formatted in DOS
format, the file name must be in MS-DOS format: a file name of up to
eight characters followed by an extension of up to three characters.
When you output to or input from floppy disk formatted in FANUC

s.c
format, a file name of up to 17 characters will be input.
When “WRITE” is selected for “FUNCTION” and the file name is not
entered, the following names are automatically assumed.
DATA KIND File name

re
LADDER PMCSD7.LAD
PARAM PMCSD7.PRM

CAUTION
pa
1 When both “FILE NO.” and “FILE NAME” are
displayed at the same time, and a value is entered
for “FILE NO.” and another file name is entered in
cs
“FILE NAME”, the value entered in “FILE NO.” is
erased and the file name entered in “FILE NAME”
becomes effective.
.cn

2 Specifying the same name as that of an existing


file results in an error.

Explanation of soft keys


w

[EXEC]: Executes the function selected for “FUNCTION”.


During execution, the soft key disappears and the
[CANCEL] soft key appears to the right of the
w

key.
[CANCEL]: Cancels the execution of the function. When the
function terminates normally, the soft key
w

disappears.
[LIST]: Replaces the current display with the Floppy list
://

screen. See Subsection 6.6.6, “Floppy List


Screen” for details.
[PORT]: Replaces the current display with the screen for
tp

setting communication parameters. See Subsection


6.6.8, “Port Setting Screen” for details.
ht

- 323 -
6.OPERATION B-63823EN/02

6.6.6 Floppy List Screen


When “FLOPPY” is selected for “DEVICE”, pressing the [LIST] soft
key display the following screen.

/
om
s.c
re
pa
The contents of the floppy cassettes or the handy files are displayed.
cs
When a file is selected on this screen, the screen display can be
returned to the previous screen. To select the file, place the cursor at
the name of the file, then press either the [SELECT] soft key or the
.cn

INPUT key. After the key entry, the screen display switches to the
previous screen automatically. In this case, the cursor is positioned at
“READ” on the “FUNCTION” menu, and the number and name of the
file selected on the list screen are indicated in the “FILE NO.” and
w

“FILE NAME” fields, respectively.


To return the screen display to the previous screen without selecting a
file, press the return key.
w

When the floppy cassette or the handy file is replaced with another
one while the list screen is being displayed, the displayed information
is not updated automatically. In this case, press the [REFRES] soft key.
w

The contents are then displayed.

NOTE
://

Up to 128 files can be displayed on this screen.


When 129 or more files are saved, the 129th and
subsequent files are ignored.
tp

Explanation of soft keys


ht

[SELECT] Selects a file, and returns the screen display to the


previous screen.
[REFRES] Redisplays the contents of a floppy cassette or a
handy file.

- 324 -
B-63823EN/02 6.OPERATION

6.6.7 Outputting to and Inputting from Other Input/Output Devices

/
om
s.c
re
When “OTHERS” is selected for “DEVICE”, output to and input from

pa
other input/output devices are enabled.

• FUNCTION
cs
The available data input/output commands are displayed. Select the
desired command by moving the cursor horizontally to that command or
select it with the corresponding soft key.
Soft keys displayed when the question selection cursor is positioned to
.cn

“FUNCTION”

Explanation of options
w

WRITE Outputs data from the PMC to other input/output


device.
READ Inputs data from other input/output device to the PMC.
w

COMPAR Compares the sequence program on the PMC with


those on other input/output device.
w

When you read a file from a I/O device, one of following messages
appear and whether to operate the important thing is confirmed.
://

<WARNING> READING SEQUENCE PROGRAM OR PMC PARAMETER


REQUIRES SPECIAL CARE.
* READING IMPROPER DATA MAY CAUSE UNEXPECTED
tp

MOVEMENT OF MACHINE.
* PROGRAM WILL BE STOPPED BY READING SEQUENCE
PROGRAM.
ht

ARE YOU SURE YOU WANT TO READ THIS FILE?

When you proceed to read PMC parameters, new PMC parameters


will be stored even if the ladder program is running. If the ladder and
the parameter are protected, the error message of "THIS FUCTION IS
PROTECTED" is displayed. Please refer to “Programmer Protection
Function” in Subsection 6.4.4.

- 325 -
6.OPERATION B-63823EN/02

WARNING
1 If a Ladder program is input while a Ladder
program is being executed, the executions of the
Ladder program stop automatically by the setting
of GENERAL screen. You have to pay special

/
attention to stop Ladder program. Stopping Ladder

om
program in a wrong timing, or with machine in
improper status, may cause unexpected reaction of
machine. You have to make it sure that machine
is in proper status, and nobody is near the machine
when you stop Ladder program.

s.c
2 At stopping Ladder program, it may take rather
long time to completely stop it in some cases
according to the activity of Ladder program. If

re
Ladder takes too long time to stop, or never stop,
correct Ladder program.
3 If the PMC parameters are input while a Ladder

pa
program is being executed, You have to special
attention to input it. Because changed PMC
parameters, may cause unexpected effect to
cs
Ladder. You have to make it sure that PMC
parameters are not effect to Ladder when you input
PMC parameters.
.cn

4 Set keep relay %SK2 to 0 when the machine tool is


shipped.

• KIND OF DATA
“KIND OF DATA” is displayed only when “WRITE” is selected for
w

“FUNCTION”.
Set the type of data to be output by moving the cursor horizontally to
w

that command or select it with the corresponding soft key.


Soft keys displayed when the question selection cursor is positioned to
w

“KIND OF DATA”
://

Explanation of options
PROGRAM: Outputs sequence program.
PARAMETER: Outputs PMC parameters.
tp

Explanation of soft keys


[EXEC]: Executes the function selected for “FUNCTION”.
ht

During execution, the soft key disappears and the


[CANCEL] soft key appears to the right of the key.
[CANCEL]: Cancels the execution of the function. When the
function terminates normally, the soft key disappears.
[PORT]: Replaces the current display with the screen for
setting communication parameters. See Subsection
5.6.8, “Port Setting Screen” for details.

- 326 -
B-63823EN/02 6.OPERATION

6.6.8 Port Setting Screen


When “FLOPPY” or “OTHERS” is selected for “DEVICE”, the
[PORT] soft key is displayed. When the key is pressed, the following
screen appears. The following gives a display example shown when

/
“OTHERS” is selected for “DEVICE”.

om
s.c
re
pa
cs
This screen allows the setting of the communication data required for
.cn

communication using the RS-232C. Communication data can be set


for each of the two types of devices independently of the other.
Selected device type is displayed to “DEVICE” menu on screen.

Explanation of each question


w

• CHANNEL
Check that an RS-232C cable is connected to the main board of the
w

control unit. Directly enter the number corresponding to the


connected connector.
1 .......... JD36A
w

2 .......... JD36B
://

• BAUDRATE
1200: Sets the baud rate to “1200”.
2400: Sets the baud rate to “2400”.
tp

4800: Sets the baud rate to “4800”.


9600: Sets the baud rate to “9600”.
19200: Sets the baud rate to “19200”.
ht

• STOP BIT
1 BIT: Sets the number of stop bits to “1”.
2 BIT: Sets the number of stop bits to “2”.

- 327 -
6.OPERATION B-63823EN/02

• WRITE CODE
“WRITE CODE” is displayed when “OTHERS” is selected for
“DEVICE”.
ASCII: Sets the output code to “ASCII”.
ISO: Sets the output code to “ISO”.

/
om
NOTE
Parity is always “NONE”.

Explanation of soft key


[INIT] Sets all the parameters to their initial values.

s.c
Initial values
DEVICE = FLOPPY DEVICE = OTHERS
CHANNEL 1 1

re
BAUD RATE 4800 4800
STOP BIT 2 BITS 2 BITS
WRITE CODE (None) ISO

pa
cs
.cn
w
w
w
://
tp
ht

- 328 -
B-63823EN/02 6.OPERATION

6.6.9 I/O Screen Error Messages


The error messages that may appear on the I/O screen and their
meanings and actions are listed below.

/
Error messages displayed during memory card I/O operation

om
Displayed error message Meaning and action
MEMORY CARD IS NOT READY No memory card is installed.
Action: Check whether a memory card is installed.
MEMORY CARD IS FULL There is no available space in the memory card.
Action: Delete files to create available space.

s.c
MEMORY CARD IS WRITE PROTECTED The memory card is write-protected.
Action: Release the write protection of the memory card.
MEMORY CARD IS NOT FORMATTED The memory card cannot be recognized.
Action: Format the memory card.

re
TOO MANY FILES IN MEMORYCARD There are too many files.
Action: Delete unnecessary files to reduce the number of files.
FILE NOT FOUND The specified file cannot be found.

FILE IS READ-ONLY

FILE NAME IS INVALID


pa
Action: On the list screen, check the file name or file number.
Write to the specified file is not permitted.
Action: Check the attributes of the file.
The file name is illegal.
cs
Action: Specify the file name in MS-DOS form.
CAN NOT FORMAT MEMORYCARD The memory card cannot be formatted.
Action: The NC cannot format this memory card. Use another unit
such as a personal computer to format the memory card.
.cn

UNSUPPORTED MEMORYCARD This memory card is not supported.


Action: Replace the memory card with another one.
CAN NOT DELETE FILE An error occurred when a file was deleted from the memory card.
Action: Check the attributes of the file.
w

MEMORYCARD BATTERY ALARM The battery of the memory card has become weak.
Action: Replace the battery of the memory card.
THIS FILE NAME IS ALREADY USED The file name is already used.
w

Action: Change the file name to another one.


MEMORYCARD ACCESS ERROR The memory card cannot be accessed.
Action: Replace the memory card with another one.
w

DIFFERENCE FOUND File comparison detected a mismatch.


MEMORYCARD IS LOCKED BY OTHER Another PMC user is using the memory card.
FUNCTION Action: Wait until the PMC user completes processing, then retry.
://

MEMORY CARD HEADER ROM DATA ID IS An attempt was made to read a file, but its ROM data ID was illegal.
ILLEGAL Action: This file cannot be read. Check the type of the file.
FLASH ROM HEADER ROM DATA ID IS An attempt was made to read a file, but its ROM data ID was illegal.
tp

ILLEGAL Action: This file cannot be read. Check the type of the file.
FILE NUMBER CAN NOT SELECTED The file number cannot be selected.
Action: If the file does not exist, the key entry is invalid. If this error
ht

occurs even when the cursor is placed at a file name,


contact the FANUC service center.
INPUT FILE NUMBER IS NOT EXIST The entered file number is not present. The entered number exceeds
the total number of files.
Action: Check the total number of files on the list screen.
FILE NUMBER IS RESTRICTED TO ”128” A value up to 128 can be entered as the file number.
Action: Enter a numeric value not exceeding 128.

- 329 -
6.OPERATION B-63823EN/02

Displayed error message Meaning and action


INTERNAL ERROR (xxxxxxxxxx) An error due to an internal factor occurred. Details on the error are
displayed in parentheses.
Action: Contact the FANUC service center, and report the displayed
message correctly.

/
Error messages displayed during flash ROM I/O operation

om
Displayed error message Meaning and action
NOT IN EMG STOP MODE The system is not in the emergency stop state.
Action: Place the system in the emergency stop state.
INVALID LADDER PROGRAM The transfer program is illegal.

s.c
Action: Check the program.
DIFFERENCE FOUND A file comparison detected a mismatch.
FLASH ROM IS LOCKED BY OTHER Another PMC user is using the flash ROM.
FUNCTION. Action: Wait until the PMC user completes processing, then retry.
INTERNAL ERROR (xxxxxxxxxx) An error due to an internal factor occurred. Details on the error are

re
displayed in parentheses.
Action: Contact the FANUC service center, and report the displayed
message correctly.

pa
Error messages displayed during floppy cassettes, handy files or other
input/output devices I/O operation.
cs
Displayed error message Meaning and action
BAD PMC PARAMETER FORMAT Specified file is not PMC parameter format.
Action: Specify file of PMC parameter format, or check the contents
.cn

of the file.
BAD HANDY FILE FORMAT Specified file is not handy file format.
Action: Specify file of handy file format, or check the contents of the
file.
UNKNOWN FILE FORMAT Can not recognize the format of specified file.
w

Action: Specify file of recognizable format such as PMC parameter


format, or check the contents of the file.
FILE NAME OR FILE NUMBER IS Need file name or file number to identify file to read, compare, or
w

REQUIRED delete.
Action: Specify file name or file number for the operation.
COMMUNICATION TIMEOUT Communication with the I/O device has been timeout.
w

Action: Check the communication parameters such as baud rate,


and retry to communicate.
I/O DEVICE IS NOT ATTACHED OR IN Any I/O device is not connected, or some errors have occurred in it.
://

ERROR STATUS Action: Check the power of I/O device is ON. Check the I/O device
is connected. Check the cable that connects I/O device with
PMC is correct one. If some error has occurred in I/O
tp

device, solve it.


RECEIVED BAD DATA: CHECK THE Invalid data has been received.
COMMUNICATION PARAMETERS Action: Check the PMC’s communication parameters such as baud
ht

rate match the ones of I/O device.


RECEIVED DATA HAS OVERRUN Too many data have received at once.
Action: Check the communication parameters about flow control.
OTHERS FUNCTION IS USING THIS Others function is using this channel.
CHANNEL Action: Use the other channel, or stop the function.
BAD COMMUNICATION PARAMETER Setting parameters of communication are not correct.
Action: Check the communication parameters such as baud rate.

- 330 -
B-63823EN/02 6.OPERATION

Displayed error message Meaning and action


OTHER FUNCTION IS USING I/O Others function such us FANUC LADDER-IIIC is using I/O function.
Action: Wait until function that using I/O function do finish, or stop
the function.
SEQUENCE PROGRAM IS IN USE BY Can not input/output of sequence program, because On-line function
ONLINE FUNCTION is using sequence program.

/
Action: Wait until On-line function, do finish the using I/O function.

om
In general, both of I/O function and On-line function should
not be used at the same time.
THIS FUNCTION IS PROTECTED Can not input/output PMC's data because the general setting screen
of PMC protects them.
Action: Cancel PMC's data protection on the general setting screen.

s.c
Refer to “Programmer Protection Function” in Subsection
6.4.4.
WRONG MODE Can not output the PMC parameters because mode of PMC and
CNC is not correct.

re
Action: Change the CNC to MDI mode or change the ladder to the
stop state.
NOT EMG STOP The system is not in the emergency stop state.

WRITE PROTECT
pa
Action: Place the system in the emergency stop state.
Can not input the PMC parameters because PWE of CNC
parameter is 0.
Action: Change “PWE” of CNC parameters to 1.
cs
.cn
w
w
w
://
tp
ht

- 331 -
ht
tp
://
w
w
w
.cn
cs
pa
re
s.c
om
/
ht
tp
://
w
w
w
.cn
cs APPENDIX
pa
re
s.c
om
/
ht
tp
://
w
w
w
.cn
cs
pa
re
s.c
om
/
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A WINDOW FUNCTIONS

/
om
This chapter describes the functions that can be executed with the
PMC_WINDOW functional instructions, as well as the formats and
other details of the control data to be set for executing these functions.

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 335 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.1 FORMATS OF CONTROL DATA

Input and output control data has the following structure.

/
Data size

om
2 Bytes Function code

2 Bytes Completion code

Data length These data set as input data remain


2 Bytes

s.c
(Byte length of data area) unchanged in the output data.

2 Bytes Data number

2 Bytes

re
Data attribute

Data area * Data length


n Bytes
≈ ≈
pa Depends on the function.
cs
(1) In the explanation of the window functions below, minuses (-) in
the data structure fields indicate that input data need not be set in
.cn

these fields or that output data in these fields is not significant.


(2) All data is in binary unless otherwise specified.
(3) All data block lengths and data lengths are indicated in bytes.
(4) Output data is valid only when window processing terminates
normally.
w

(5) Output data always includes one of the following completion


codes. Note, however, that all of the completion codes listed
w

are not always provided for each function.

Completion code Meaning


w

0 Normal termination
1 Error (invalid function code)
2 Error (invalid data block length)
://

3 Error (invalid data number)


4 Error (invalid data attribute)
5 Error (invalid data)
tp

6 Error (necessary option missing)


7 Error (write-protected)
ht

- 336 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.1.1 The Note about the Address Used for Control Data
There are WORD type and BOOL type in the address of PMC-SD7.
When using these for the address for control data structure sets up the
starting address as follows.

/
om
Example of WORD type address:
When the top address is %R00001, address assigned for each data in
the control data structure is as follows.

s.c
WORD
type
offset
Top address +0 %R00001

re
Function code

+1 %R00002
Completion code

+2

+3
%R00003

%R00004
pa
Data length in bytes
(Byte length of data area)
cs
Data number

+4 %R00005
Data attribute
.cn

+5 %R00006
Data area
≈ ≈
w
w
w
://
tp
ht

- 337 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

Example of BOOL type address:


When the top address is %M00001, address assigned for each data in
the control data structure is as follows.

/
BOOL

om
type
offset
Top address +0 %M00001
Function code

+16 %M00017

s.c
Completion code

+32 %M00033 Data length in bytes


(Byte length of data area)
+48 %M00049

re
Data number

+64 %M00065
Data attribute

+80 %M00081


pa Data area

cs
.cn

NOTE
In order to use BOOL type address as BYTE type,
the starting BOOL type address must be “modulo 8
plus 1”, in order words, 1, 9, 17, 25, 33, 41, etc.
w

Farther, starting address at word boundary, in other


word “modulo 16 plus 1” such as 1, 17, 33, etc, is
w

strongly recommended for the performance of


execution.
w
://
tp
ht

- 338 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.2 LOW-SPEED RESPONSE AND HIGH-SPEED RESPONSE

There are two types of window function - one executed at high speed
and the other executed at low speed.

/
om
Number of scans to be executed until the window
TYPE
instruction is completed
TWO SCAN TIMES OR MORE (Depends on the CNC
LOW
processing priority and operation status.)
HIGH 1 SCAN TIME

s.c
In case of a low-speed response, the data is read or written by the
control between CNC and PMC. When using the low-speed response
window function, set EN to 0 immediately after the data transfer end

re
data (Q) is set to 1 (interlock) for the window instruction. For details,
see "CAUTION" below. In a high-speed response, it is not necessity
for take the interlock because the data is directly read.

CAUTION pa
The window instruction of a low-speed response is
controlled exclusively with the other window
cs
instructions of low-speed response.
Therefore, when the data is read or written
continuously, it is necessary to clear EN of the
.cn

functional instruction to 0 once when the completion


information (Q) become 1.
It does not work about EN=1 of the other window
instructions of low-speed response such as Q=1 and
w

EN=1 of the window instruction of a low-speed


response.
w

The window instruction of a high-speed response is


not exclusively controlled like a low-speed response.
Therefore, when the data is read or written
w

continuously, you need not make EN=0.


://
tp
ht

- 339 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.2.1 Note on the Programming of a Low-speed Response Window


Instruction
If a low-speed response window instruction is programmed to keep its
EN condition to on for no apparent reason, it may result in the ladder

/
program taking a long time to stop or not being able to stop at all. If

om
the ladder program does not stop, all operations aimed at changing the
ladder program will take longer to end or will never end.
To avoid such problems, when you code a ladder program using
functional instructions, you need to design the ladder structure based
on a thorough understanding of the control conditions of the

s.c
individual instructions you use.

If the ladder program takes long to stop or does not stop for any of
these reasons, the following operations will be affected.

re
1. Stopping the ladder program using a soft key on the screen
2. Reading a new ladder program from a memory card or other

pa
medium, by using the DATA I/O screen
3. Updating the ladder program with changes made using the FANUC
LADDER-IIIC.
cs
If any of the above phenomena occurs, the functional instruction
causing the problem needs to be fixed. For information about how to
fix the problem, see Section 4.11 or 5.10.
.cn
w
w
w
://
tp
ht

- 340 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.3 LIST OF WINDOW FUNCTIONS

Function group order


Function

/
Group Description Response R/W
code

om
CNC information 1 Reading CNC system information 0 High-speed R
(Section A.4) 2 Reading a tool offset 13 High-speed R
3 Write a tool offset 14 Low-speed W
4 Reading a workpiece origin offset value 15 High-speed R
5 Writing a workpiece origin offset value 16 Low-speed W

s.c
6 Reading a parameter 17, 154 High-speed R
7 Writing a parameter 18 Low-speed W
8 Reading setting data 19, 155 High-speed R
9 Writing setting data 20 Low-speed W

re
10 Reading a custom macro variable 21 High-speed R
11 Writing a custom macro variable 22 Low-speed W
12 Reading the CNC alarm status 23 High-speed R
13
14
15
16
Reading the current program number
Reading the current sequence number
Reading modal data
Reading diagnosis data
pa 24
25
32
33, 156
High-speed
High-speed
High-speed
High-speed
R
R
R
R
cs
17 Reading the P-code macro variable 59 High-speed R
18 Writing the P-code macro variable 60 Low-speed W
19 Reading CNC status information 76 High-speed R
.cn

20 Reading the current program number (8-digit program 90 High-speed R


numbers)
21 Entering data on the program check screen 150 Low-speed W
22 Reading clock data (date and time) 151 High-speed R
23 Specifying the Number of the Program for I/O Link 194 Low-speed W
w

Axis information 1 Reading the actual velocity of controlled axes 26 High-speed R


(Section A.5) 2 Reading the absolute position (absolute coordinates) of 27 High-speed R
controlled axes
w

3 Reading the machine position (machine coordinates) of 28 High-speed R


controlled axes
w

4 Reading a skip position (stop coordinates of skip 29 High-speed R


operation (G31)) of controlled axes
5 Reading the servo delay for controlled axes 30 High-speed R
://

6 Reading the acceleration/deceleration delay on 31 High-speed R


controlled axes
7 Reading the feed motor load current value (A/D 34 High-speed R
tp

conversion data)
8 Reading the actual spindle speed 50 High-speed R
9 Reading the relative position on a controlled axis 74 High-speed R
ht

10 Reading the remaining travel 75 High-speed R


11 Reading actual spindle speeds 138 High-speed R
12 Entering torque limit data for the digital servo motor 152 Low-speed W
13 Reading load information of the spindle motor (serial 153 High-speed R
interface)
14 Reading the servo data of the control axes 207 High-speed R
15 Reading the estimate disturbance torque data 211 High-speed R

- 341 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

Function
Group Description Response R/W
code
Axis information 16 Reading Fine Torque Sensing Data (Statistical 226 High-speed R
(Section A.5) Calculation Results)
17 Reading Fine Torque Sensing Data (Store Data) 232 High-speed R

/
18 Presetting the relative coordinate 249 Low-speed W

om
Tool life 1 Reading the tool life management data (tool group 38 High-speed R
management number)
functions 2 Reading tool life management data (number of tool 39 High-speed R
(Section A.6) groups)
3 Reading tool life management data (number of tools) 40 High-speed R

s.c
4 Reading tool life management data (tool life) 41 High-speed R
5 Reading tool life management data (tool life counter) 42 High-speed R
6 Reading tool life management data (tool length 43 High-speed R
compensation number (1): Tool number)

re
7 Reading tool life management data (tool length 44 High-speed R
compensation number (2): Tool order number)
8 Reading tool life management data (cutter compensation 45 High-speed R

10
number (1): Tool number)

number (2): Tool order number) pa


Reading tool life management data (cutter compensation

Reading tool life management data (tool information (1):


46

47
High-speed

High-speed
R

R
cs
Tool number)
11 Reading tool life management data (tool information (2): 48 High-speed R
Tool order number)
.cn

12 Reading tool life management data (tool number) 49 High-speed R


13 Reading the tool life management data (tool life counter 160 High-speed R
type)
14 Registering tool life management data (tool group) 163 Low-speed W
15 Writing tool life management data (tool life) 164 Low-speed W
w

16 Writing tool life management data (tool life counter) 165 Low-speed W
17 Writing tool life management data (tool life counter type) 166 Low-speed W
w

18 Writing tool life management data (tool length 167 Low-speed W


compensation number (1): Tool number)
19 Writing tool life management data (tool length 168 Low-speed W
w

compensation number (2): Tool order number)


20 Writing tool life management data (cutter compensation 169 Low-speed W
number (1): Tool number)
://

Tool life 21 Writing tool life management data (cutter compensation 170 Low-speed W
management number (2): Tool order number)
functions 22 Writing tool life management data (tool information (1): 171 Low-speed W
tp

(Section A.6) Tool number)


23 Writing the tool management data (tool information (2): 172 Low-speed W
Tool order number)
ht

24 Writing tool life management data (tool number) 173 Low-speed W


25 Reading the tool life management data (tool group No.) 200 High-speed R
(8-digit tool number)
26 Reading tool life management data (tool information (1): 201 High-speed R
Tool number) (8-digit tool number)
27 Registering tool life management data (tool group 202 Low-speed W
number) (8-digit tool number)

- 342 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

Function
Group Description Response R/W
code
Tool life 28 Reading tool life management data (tool length 227 High-speed R
management compensation number (1): Tool number) (8-digit tool
functions number)

/
(Section A.6) 29 Reading tool life management data (cutter compensation 228 High-speed R
number (1): Tool number) (8-digit tool number)

om
30 Writing tool life management data (tool length 229 Low-speed W
compensation number (1): Tool number) (8-digit tool
number)
31 Writing tool life management data (cutter compensation 230 Low-speed W
number (1): Tool number) (8-digit tool number)

s.c
32 Writing the tool life management data (tool information 231 Low-speed W
(1): Tool number) (8-digit tool number)
33 Deleting tool life management data (tool group) 324 Low-speed W
34 Deleting tool life management data (tool data) 325 Low-speed W

re
35 Clearing tool life management data (tool life counter and 326 Low-speed W
tool information)
36 Writing tool life management data (arbitrary group 327 Low-speed W

Tool management
functions
37
1
number)
pa
Writing tool life management data (remaining tool life)
Exchange of tool management data number in the
magazine management table
328
329
Low-speed
Low-speed
W
W
cs
(Section A.7) 2 Search of empty pot 330 Low-speed R
3 New-register of a tool management data 331 Low-speed W
4 Writing a tool management data 332 Low-speed W
.cn

5 Deletion of a tool management data 333 Low-speed W


6 Reading a tool management data 334 Low-speed R
7 Writing each tool data 335 Low-speed W
8 Search of tool management data 366 Low-speed R
9 Shift of tool management data 367 Low-speed W
w

10 Reading a decimal point of the customizing data 392 Low-speed R


11 Searching for a free pot (oversize tools supported) 397 Low-speed R
12 Reading a total life data 409 Low-speed R
w

*1 Function codes that have R in the R/W column are window read
w

functions specifiable with the PMC_WINDOW function


command. Function codes that have W in the R/W column are
window write functions specifiable with the PMC_WINDOW
://

function command.
*2 Functions of "High-speed" in their Response field can read or
write data immediately upon request. On the other hand,
tp

functions of "Low-speed" in their Response field need to request


the CNC to read or write data and receiving response from CNC
completes the request.
ht

CAUTION
To read or write data for the second tool post
(HEAD2) in the TT series, add 1000 to the function
code number.
To read or write data for the third path in three-path
control CNC, add 2000 to the function code number.

- 343 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

Function code order


Function
Description Response R/W
code
0 Reading CNC system information High-speed R
13 Reading a tool offset High-speed R

/
14 Writing a tool offset Low-speed W

om
15 Reading a workpiece origin offset value High-speed R
16 Writing a workpiece origin offset value Low-speed W
17 Reading a parameter High-speed R
18 Writing a parameter Low-speed W
19 Reading setting data High-speed R

s.c
20 Writing setting data Low-speed W
21 Reading a custom macro variable High-speed R
22 Writing a custom macro variable Low-speed W
23 Reading the CNC alarm status High-speed R

re
24 Reading the current program number High-speed R
25 Reading the current sequence number High-speed R
26 Reading the actual velocity of controlled axes High-speed R
27
28
29
pa
Reading the absolute position (absolute coordinates) of controlled axes
Reading the machine position (machine coordinates) of controlled axes
Reading a skip position (stop coordinates of skip operation (G31)) of controlled
axes
High-speed
High-speed
High-speed
R
R
R
cs
30 Reading the servo delay for controlled axes High-speed R
31 Reading the acceleration/deceleration delay on controlled axes High-speed R
32 Reading modal data High-speed R
.cn

33 Reading diagnosis data High-speed R


34 Reading the feed motor load current value (A/D conversion data) High-speed R
38 Reading the tool life management data (tool group number) High-speed R
39 Reading tool life management data (number of tool groups) High-speed R
w

40 Reading tool life management data (number of tools) High-speed R


41 Reading tool life management data (tool life) High-speed R
42 Reading tool life management data (tool life counter) High-speed R
w

43 Reading tool life management data (tool length compensation number (1): Tool High-speed R
number)
44 Reading tool life management data (tool length compensation number (2): Tool High-speed R
w

order number)
45 Reading tool life management data (cutter compensation number (1): Tool High-speed R
number)
://

46 Reading tool life management data (cutter compensation number (2): Tool order High-speed R
number)
47 Reading tool life management data (tool information (1): Tool number) High-speed R
tp

48 Reading tool life management data (tool information (2): Tool order number) High-speed R
49 Reading tool life management data (tool number) High-speed R
50 Reading the actual spindle speed High-speed R
ht

59 Reading the P-code macro variable High-speed R


60 Writing the P-code macro variable Low-speed W
74 Reading the relative position on a controlled axis High-speed R
75 Reading the remaining travel High-speed R
76 Reading CNC status information High-speed R
90 Reading the current program number (8-digit program numbers) High-speed R
138 Reading actual spindle speeds High-speed R
150 Entering data on the program check screen Low-speed W

- 344 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

Function
Description Response R/W
code
151 Reading clock data (date and time) High-speed R
152 Entering torque limit data for the digital servo motor Low-speed W
153 Reading load information of the spindle motor (serial interface) High-speed R

/
154 Reading a parameter High-speed R

om
155 Reading setting data High-speed R
160 Reading the tool life management data (tool life counter type) High-speed R
163 Registering the tool life management data (tool group) Low-speed W
164 Writing the tool life management data (tool life) Low-speed W
165 Writing the tool life management data (tool life counter) Low-speed W

s.c
166 Writing the tool life management data (tool life counter type) Low-speed W
167 Writing the tool life management data (tool length compensation number (1): Tool Low-speed W
number)
168 Writing the tool life management data (tool length compensation number (2): Tool Low-speed W

re
order number)
169 Writing the tool life management data (cutter compensation number (1): Tool Low-speed W
number)
170 Writing the tool life management data (cutter compensation number (2): Tool order Low-speed W

171
172
number)
pa
Writing the tool life management data (tool information (1): Tool number)
Writing the tool management data (tool condition (2): Tool order number)
Low-speed
Low-speed
W
W
cs
173 Writing the tool life management data (tool number) Low-speed W
194 Specifying the Number of the Program for I/O Link Low-speed W
200 Reading the tool life management data (tool group number) (8-digit tool number) High-speed R
.cn

201 Reading tool life management data (tool information (1): Tool number) (8-digit tool High-speed R
number)
202 Registering tool life management data (tool group number) (8-digit tool number) Low-speed W
207 Reading the servo data of the control axes High-speed R
211 Reading the estimate disturbance torque data High-speed R
w

226 Reading Fine Torque Sensing Data (Statistical Calculation Results) High-speed R
227 Reading tool life management data (tool length compensation number (1): Tool High-speed R
number) (8-digit tool number)
w

228 Reading tool life management data (cutter compensation number (1): Tool High-speed R
number) (8-digit tool number)
229 Writing tool life management data (tool length compensation number (1): Tool Low-speed W
w

number) (8-digit tool number)


230 Writing tool life management data (cutter compensation number (1): Tool number) Low-speed W
://

(8-digit tool number)


231 Writing the tool life management data (tool information (1): Tool number) (8-digit Low-speed W
tool number)
232 Reading Fine Torque Sensing Data (Store Data) High-speed R
tp

249 Presetting the relative coordinate Low-speed W


324 Deleting the tool life management data (tool group) Low-speed W
325 Deleting the tool life management data (tool data) Low-speed W
ht

326 Deleting the tool life management data (tool life counter and tool information) Low-speed W
327 Writing the tool life management data (arbitrary group number) Low-speed W
328 Writing the tool life management data (remaining tool life) Low-speed W
329 Exchange of tool management data number in the magazine management table Low-speed W
330 Search of empty pot Low-speed R
331 New-register of a tool management data Low-speed W
332 Writing a tool management data Low-speed W
333 Deletion of a tool management data Low-speed W

- 345 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

Function
Description Response R/W
code
334 Reading a tool management data Low-speed R
335 Writing each tool data Low-speed W
366 Search of tool management data Low-speed R

/
367 Shift of tool management data Low-speed W

om
392 Reading a decimal point of the customizing data Low-speed R
397 Searching for a free pot (oversize tools supported) Low-speed R
409 Reading a total life data Low-speed R

*1 Function codes that have R in the R/W column are window read

s.c
functions specifiable with the PMC_WINDOW function
command. Function codes that have W in the R/W column are
window write functions specifiable with the PMC_WINDOW
function command.

re
*2 Functions of "High-speed" in their Response field can read or
write data immediately upon request. On the other hand,
functions of "Low-speed" in their Response field need to request

pa
the CNC to read or write data and receiving response from CNC
completes the request.

CAUTION
cs
To read or write data for the second tool post
(HEAD2) in the TT series, add 1000 to the function
code number.
.cn

To read or write data for the third path in three-path


control CNC, add 2000 to the function code number.
w
w
w
://
tp
ht

- 346 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4 CNC INFORMATION

A.4.1 Reading CNC System Information (High-speed Response)

/
[Description]

om
The system information specific to the CNC can be read including the
CNC type (e.g., series name like 16), the distinction between the
machining center system (M) and the lathe system (T) for each CNC
path, the ROM series and edition of the CNC system software, and the
number of axes to be controlled for each CNC path.

s.c
[Input data [Input data structure]
WORD BOOL

re
type type
offset offset

Top address +0 +0

+1 +16
pa
(Function code)
0
cs
(Completion code)

(Need not be set)

+2 +32
.cn

(Data length in bytes)



(Need not be set)

+3 +48
(Data number)
w

+4 +64
(Data attribute)
w

+5 +80
(Data area)
w


(Need not be set)

≈ ≈
://
tp
ht

[Completion codes]
0: CNC system information has been read normally.

- 347 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0

om
(Function code)
0

+1 +16
(Completion code)
0
(Always terminates normally.)

s.c
+2 +32
(Data length in bytes)
14

+3 +48

re
(Data number)

+64
+4

+5 +80
pa
(Data attribute)

ASCII characters
Value
cs
CNC series name (2 bytes) (30)
+6 +96
ASCII characters
Machine type M/T (2 bytes)
(M, T)
.cn

+7 +112
ROM series of CNC system software ASCII characters
(4 bytes) (B 0 0 0 1, . . . )
+8 +144 ROM version of CNC system ASCII characters
software (4 bytes) (0 0 0 1, 0 0 0 2, . . . )
w

+11 +176 Number of axes to be controlled for ASCII characters


the specified CNC path (2 bytes) ( 2, 3, 4, . . . )
w

NOTE
w

Data is stored from the upper digit in each lower


byte.
://
tp
ht

- 348 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.2 Reading a Tool Offset (High-speed Response)

[Description]
A tool offset value recorded in the CNC can be read.
Wear offset data, geometric offset data, cutter compensation data, and

/
tool length offset data can be read as a tool offset.

om
[Input data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
13

re
+1 +16
(Completion code)

(Need not be set)

+2 +32
pa
(Data length in bytes)

(Need not be set)
cs
+3 +48
(Data number)
N
(N = offset number)
.cn

+4 +64
(Data attribute)
M
(M = offset type)

+5 +80
(Data area)

w

(Need not be set)


≈ ≈
w
w

(a) Offset types (for machining centers)


Cutter Tool length • If the type of tool offset need
://

Wear 0 2 not be specified, enter 0.


Geometric 1 3
tp

(b) Offset types (for lathes)


X axis Z axis Tool tip R Virtual tool tip Y axis
Wear 0 2 4 6 8
ht

Geometric 1 3 5 7 9

- 349 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool offset has been read normally.
3: The offset number specified for reading is invalid. (This
completion code is returned when the specified offset number data
is not from 1 to the maximum number of offsets.)

/
4: There are mistakes in the data attribute that specifies the type of the

om
offset to be read.
6: For the offset number specified for reading, the additional tool
offset number option is required, but it is missing.
In addition, for the type of the offset specified for reading, an
additional tool function option is required, but it is missing.

s.c
[Output data structure]
WORD BOOL
type type

re
offset offset

Top address +0 +0

+1 +16
pa
(Function code)
13

(Completion code)
?
cs
(See the explanation of
the completion codes.)
+2 +32
(Data length in bytes)
L (Normally set to 4)
.cn

(L: Byte length of offset value)

+3 +48
(Data number)
N
(N = offset number)
w

+4 +64
(Data attribute)
M
(M = offset type) Value
w

+5 +80 Tool offset value Signed binary (A negative value is


represented in 2's complement.)
Upper 3 bytes are always "0" for
w

virtual tool tip.


://

[Output data unit]


Increment system
tp

Input system
IS-B IS-C
mm, deg 0.001 0.0001
Machining center system
inch 0.0001 0.00001
ht

Radius specification 0.001 0.0001


mm, deg
Lathe Diameter specification 0.001 0.0001
system Radius specification 0.0001 0.00001
inch
Diameter specification 0.0001 0.00001

- 350 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.3 Writing a Tool Offset (Low-speed Response)

[Description]
The tool offset value can be directly written into the CNC.
Wear offset data, geometric offset data, cutter compensation data, and

/
tool length offset data can be written as a tool offset.

om
[Input data structure]
WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
14

re
+1 +16
(Completion code)

(Need not to be set)

+2 +32
pa
(Data length in bytes)
4
cs
+3 +48
(Data number)
N
(N = offset number)
.cn

+4 +64
(Data attribute)
M
(M = offset type) Value

+5 +80 Tool offset value Signed binary (A negative value is


represented in 2's complement.)
w

Upper 3 bytes are always "0" for


virtual tool tip.
w

(a) Offset types (for machining centers)


Cutter Tool length • If the type of tool offset need
w

Wear 0 2 not be specified, enter 0.


Geometric 1 3
://

(b) Offset types (for lathes)


X axis Z axis Tool tip R Virtual tool tip Y axis
tp

Wear 0 2 4 6 8
Geometric 1 3 5 7 9
ht

- 351 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Input data unit]


Increment system
Input system
IS-B IS-C
mm, deg 0.001 0.0001
Machining center system
inch 0.0001 0.00001

/
Radius specification 0.001 0.0001

om
mm, deg
Lathe Diameter specification 0.001 0.0001
system Radius specification 0.0001 0.00001
inch
Diameter specification 0.0001 0.00001

[Completion codes]

s.c
0: The tool offset has been written normally.
2: The data byte length for the tool offset specified for writing is
invalid.
3: The offset number specified for writing is invalid. (This

re
completion code is returned when the specified offset number data
is not from 1 to the maximum number of offsets.)
4: There are mistakes in the data attribute that specifies the type of the
offset to be written.
pa
6: For the offset number specified for writing, the additional tool
offset number option is required, but it is missing.
cs
Also, the tool function option is not added that is necessary for the
type of the offset specified for writing.
.cn

[Output data structure]


WORD BOOL
type type
offset offset
w

Top address +0 +0
(Function code)
14
w

+1 +16 (Completion code)


?
(See the explanation of
w

the completion codes.)

+2 +32
(Data length in bytes)
L
://

(L: Input data)

+3 +48
(Data number)
N
tp

(N = Input data)

+4 +64
(Data attribute)
M
ht

(Input data) Value

+5 +80 Signed binary (A negative value is


Tool offset value: Input data represented in 2's complement.)

- 352 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.4 Reading a Workpiece Origin Offset Value (High-speed


Response)

[Description]
The workpiece origin offset recorded in the CNC can be read.

/
A workpiece origin offset is provided for each controlled axis (the

om
first axis to the 8th axis) in the CNC. Either the workpiece origin
offset for a specific axis can be read, or the workpiece origin offsets
for all axes can be read at one time. If the additional axis option is not
provided, however, the workpiece origin offset for the additional axis
cannot be read.

s.c
[Input data structure]

re
WORD BOOL
type type
offset offset

Top address +0 +0

+1 +16
(Function code)
15 pa
cs
(Completion code)

(Need not be set)

+2 +32 N = 0: External workpiece origin offset


.cn

(Data length in bytes) N = 1: G54


− · ·
(Need not be set) · ·
N = 6: G59
+3 +48 With "addition of workpiece coordinate system
(Data number) pair"
N N = 7: G54.1 P1
w

(N = offset group number) · ·


· ·
+4 +64 N = 306: G54.1 P300
(Data attribute)
M
w

M = 1 to n: Workpiece origin offset number of


(M = axis number) a specific axis. n is the axis
number.
+5 +80
(Data area) M = −1: Read for all axes
w


(Need not be set)

≈ ≈
://
tp
ht

- 353 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The workpiece origin offset has been read normally.
3: The specified offset number is invalid.
4: The specified axis number is invalid.
6: There is no workpiece coordinate shift option added.

/
om
[Output data structure]
WORD BOOL
type type
offset offset
Top address +0 +0

s.c
(Function code)
15

+1 +16 (Completion code)


?

re
(See the explanation of
the completion codes.)
+2 +32 (Data length in bytes) L = 4: The workpiece origin offset value
L for a specific axis is read.

+3 +48
origin offset value)

(Data number)
N
pa
(L: Byte length of the workpiece
L = 4*n: Workpiece origin offsets for all
axes are read.
cs
(N = Input data)

+4 +64
(Data attribute)
M
.cn

(M = Input data) Value

+5 +80 Signed binary number (A negative value


Workpiece origin offset value is represented in 2's complement.)
w

[Output data unit]


w

Increment system
Input system
IS-B IS-C
mm, deg 0.001 0.0001
w

Machining center system


inch 0.0001 0.00001
Radius specification 0.001 0.0001
mm, deg
Lathe Diameter specification 0.001 0.0001
://

system Radius specification 0.0001 0.00001


inch
Diameter specification 0.0001 0.00001
tp
ht

- 354 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.5 Writing a Workpiece Origin Offset Value (Low-speed


Response)

[Description]
Data can be written directly as a workpiece origin offset value in the

/
CNC.

om
A workpiece origin offset is provided for each controlled axis (the
first axis to the 8th axis) in the CNC. Either the workpiece origin
offset value for a specific axis can be written, or the workpiece origin
offset values for all axes can be written at one time. If the additional
axis option is not provided, however, the workpiece origin offset value

s.c
for the additional axis cannot be written.

[Input data structure]

re
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)
16 pa L = 4:
L = 4*n:
Workpiece origin offset value for a
specific axis is written.
Workpiece origin offset values for all
cs
+1 +16 axes are written.
(Completion code)

(Need not be set) N = 0: External workpiece origin offset
N = 1: G54
· ·
.cn

+2 +32
(Data length in bytes) · ·
L N = 6: G59
(L: Byte length of the workpiece With the option of adding Workpiece
origin offset value) coordinate systems
+3 +48 N = 7: G54.1P1
(Data number) · ·
N · ·
w

(N = Offset group number) N = 306: G54.1P300


M = 1 to n: Workpiece origin offset number of a
+4 +64 specific axis. n is the axis number.
(Data attribute) M = −1:
w

Write for all


M
(M = Axis number) Value
+5 +80
w

Signed binary (A negative value is


Workpiece origin offset value represented in 2's complement.)
://
tp
ht

- 355 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Input data unit]


Increment system
Input system
IS-B IS-C
mm, deg 0.001 0.0001
Machining center system
inch 0.0001 0.00001

/
Radius specification 0.001 0.0001

om
mm, deg
Lathe Diameter specification 0.001 0.0001
system Radius specification 0.0001 0.00001
inch
Diameter specification 0.0001 0.00001

[Completion codes]

s.c
0: The workpiece origin offset has been written normally.
2: The specified data length is invalid.
3: The offset number is invalid.
4: The specified axis number is invalid.

re
6: There is no workpiece coordinate shift option added.

[Output data structure]


WORD
type
offset
BOOL
type
offset
pa
cs
Top address +0 +0
(Function code)
16
.cn

+1 +16 (Completion code)


?
(See the explanation of
the completion codes.)
+2 +32
w

(Data length in bytes)


L
(L: Input data)

+48
w

+3
(Data number)
N
(N = Input data)
w

+4 +64
(Data attribute)
M
(M = Input data) Value
://

+5 +80 Workpiece origin offset value: Signed binary number (A negative


value is represented in 2's
Input data
complement.)
tp
ht

- 356 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.6 Reading a Parameter (High-speed Response)

[Description]
Parameter data of the CNC is read by directly accessing the CNC.
There are four types of parameters in the CNC: Bit parameters having

/
a definite meaning for each bit, byte parameters holding 1-byte data,

om
word parameters holding 2-byte data, and double word parameters
holding 4-byte data. Therefore, the length of the read data varies
according to the parameter number specified.
Note that bit parameters cannot be read in bit units. The eight bits
(one byte) for a parameter number must be read at a time.

s.c
For axis parameters, data for a specific axis can be read, or data for all
axes can be read at a time.
Specify pitch error compensation data in data Nos. 10000 to 11023
(1024 points in total).

re
For details of parameter data, refer to the Operator's manual of the
CNC.

WORD
type
BOOL
type
[Input data structure]
pa
cs
offset offset
Top address +0 +0
(Function code)
17 or 154
.cn

+1 +16
(Completion code)

(Need not be set)
w

+2 +32
(Data length in bytes)

(Need not be set)
w

+3 +48
(Data number)
N
(N = parameter number)
w

+4 +64 M = 0: No axis
(Data attribute)
M M = 1 to n: A specific axis
://

(M = Axis number)
M = −1: All axes
+5 +80 (Data area)

(Need not be set) When all axes are specified by spindle parameters
tp

(parameters 4000 to 4799), only two axes are


≈ ≈ specified.
ht

- 357 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Parameter data has been read normally.
3: The parameter number specified for reading is invalid.
4: The specified data attribute is invalid because it is neither 0, -1, nor
a value 1 to n (n is the number of axes).

/
6: Although a certain option, such as the pitch error compensation

om
option, is required for the data of the parameter number specified
for reading, it is not provided.

[Output data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
17 or 154

+1

+2
+16

+32
(Completion code)
?
pa
(See the explanation of
the completion codes.)
When no axis or one axis is specified
L = 1: Bit or byte parameter
L = 2: Word parameter
L = 4: Double word parameter
cs
(Data length in bytes)
L
(L = 1, 2, 4, 1*n, 2*n, 4*n) When all axes are specified
L = 1*n: Bit or byte parameter
+3 +48 L = 2*n: Word parameter
.cn

(Data number) L = 4*n: Double word parameter


N
(N = Input data)

+4 +64
(Data attribute)
M
w

(M = Input data) Value

+5 +80
Parameter data Parameter-dependent form
w
w

CAUTION
Macro executor parameters 9000 to 9011 cannot be
read.
://
tp
ht

- 358 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.7 Writing a Parameter (Low-speed Response)

[Description]
Data can be written in a parameter in the CNC.
There are four types of parameters in the CNC: Bit parameters having

/
a definite meaning for each bit, byte parameters holding 1-byte data,

om
word parameters holding 2-byte data, and double word parameters
holding 4-byte data. Therefore, the length of the written data varies
according to the parameter specified.
Note that bit parameters cannot be written in bit units. The eight bits
(one byte) for the parameter number must be written at a time. This

s.c
means that when a bit needs to be written, the whole data for the
corresponding parameter number shall be read first, modify the target
bit in the read data, then the data shall be rewritten.
For axis parameters, data for a specific axis can be read, or data for all

re
axes can be read at a time.
For details of parameter data, refer to the Operator's manual of the
CNC.

pa
Some parameters cause a P/S alarm 000 when data is written. (The
power must be turned off before continuing operation.)

[Input data structure]


cs
WORD BOOL
type type
.cn

offset offset

Top address +0 +0
(Function code)
18

When no axis or one axis is specified


w

+1 +16
(Completion code) L = 1: Bit or byte parameter
− L = 2: Word parameter
(Need not be set) L = 4: Double word parameter
w

+2 +32
(Data length in bytes)
L
(L = 1, 2, 4, 1*n, 2*n, 4*n) When all axes are specified
w

L = 1*n: Bit or byte parameter


+3 +48 L = 2*n: Word parameter
(Data number) L = 4*n: Double word parameter
N
(N = parameter number)
://

+4 +64 M = 0: No axis
(Data attribute) M = 1 to n: A specific axis
M M = −1: All axes
(M = Axis number)
tp

When all axes are specified by spindle parameters


(parameters 4000 to 4799), only two axes are
specified.
ht

Value
+5 +80
Parameter data Parameter-dependent form

- 359 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Parameter data has been written normally.
2: The data byte length of the parameter specified for writing is
invalid.
3: The parameter number specified for writing is invalid.

/
4: The specified data attribute is invalid because it is neither 0, -1, nor

om
a value from 1 to n (n is the number of axes).
6: Although a certain option, such as the pitch error compensation
option, is required for the data of the parameter number specified
for writing, it is not provided.

s.c
[Output data structure]
WORD BOOL
type type

re
offset offset

Top address +0 +0

+1 +16
pa
(Function code)
18

(Completion code)
?
cs
(See the explanation of
the completion codes.)
+2 +32
(Data length in bytes)
L
.cn

(L = Input data)

+3 +48
(Data number)
N
(N = Input data)
w

+4 +64
(Data attribute)
M
(M = Input data) Value
w

+5 +80
Parameter data: Input data Parameter-dependent form
w

CAUTION
://

Parameters may not become effective immediately


depending on the parameter numbers.
tp
ht

- 360 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.8 Reading Setting Data (High-speed Response)

[Description]
The setting data in the CNC is read by directly accessing the CNC.
There are four types of setting data in the CNC: Bit setting data

/
having a definite meaning for each bit, byte setting data stored in

om
bytes, word setting data stored in 2-byte units, and double-word
setting data stored in 4-byte units. Therefore, the length of the read
data varies according to the setting data specified.
Note that bit setting data cannot be read in bit units. The eight bits
(one byte) for the setting data number must be read at a time.

s.c
For axis parameters, data for a specific axis can be read, or data for all
axes can be read at a time.
For details of setting data, refer to the Operator's manual of the CNC.

re
[Input data structure]
WORD BOOL

Top address
type
offset

+0
type
offset

+0 pa
(Function code)
cs
19 or 155

+1 +16
(Completion code)

.cn

(Need not be set)

+2 +32
(Data length in bytes)

(Need not be set)
w

+3 +48
(Data number)
N
(N = Setting data number)
w

+4 +64 M = 0: No axis
(Data attribute)
M M = 1 to n: A specific axis
(M = Axis number)
w

M = −1: All axes


+5 +80
(Data area)

://

(Need not be set)

≈ ≈
tp
ht

- 361 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Setting data has been read normally.
3: The setting number specified for reading is invalid.
4: The specified data attribute is invalid because it is neither 0, -1, nor
a value from 1 to n (n is the number of axes).

/
om
[Output data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
19 or 155

+1 +16 (Completion code) When no axis or one axis is specified

re
? L = 1: Bit or byte parameter
(See the explanation of L = 2: Word parameter
the completion codes.) L = 4: Double word parameter
+2 +32

+3 +48
(Data length in bytes)
L

(Data number)
pa
(L = 1, 2, 4, 1*n, 2*n, 4*n) When all axes are specified
L = 1*n: Bit or byte parameter
L = 2*n: Word parameter
L = 4*n: Double word parameter
cs
N
(N = Input data)

+4 +64
(Data attribute)
.cn

M
(M = Input data) Value

+5 +80
Setting data Setting data-dependent form
w
w
w
://
tp
ht

- 362 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.9 Writing Setting Data (Low-speed Response)

[Description]
Data can be written as setting data in the CNC.
For details of setting data, refer to the Operator's manual of the CNC.

/
om
[Input data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
20

+1 +16 When no axis or one axis is specified

re
(Completion code) L = 1: Bit or byte parameter
− L = 2: Word parameter
(Need not be set.) L = 4: Double word parameter

+2 +32

+3 +48
L

(Data number)
pa
(Data length in bytes)
(L = 1, 2, 4, 1*n, 2*n, 4*n) When all axes are specified
L = 1*n: Bit or byte parameter
L = 2*n: Word parameter
L = 4*n: Double word parameter
cs
N
(N = Setting data number)

+4 +64 M = 0: No axis
(Data attribute)
.cn

M M = 1 to n: A specific axis
(M = Axis number)
M = −1: All axes

Value
w

+5 +80
Setting data Setting data-dependent form
w
w
://
tp
ht

- 363 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Setting data has been written normally.
2: The byte length of the setting data specified for writing is invalid.
3: The setting data number specified for writing is invalid.
4: The specified data attribute is invalid because it is neither 0, -1, nor

/
a value from 1 to n (n is the number of axes).

om
5: Data exceeding the allowable range was specified as setting data to
be written. For example, when data outside the range from 0 to 3 is
specified as the setting data to be written for I/O data, this
completion code is returned.

s.c
[Output data structure]
WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
20

+1 +16 (Completion code)


? pa
(See the explanation of
the completion codes.)
cs
+2 +32
(Data length in bytes)
L
(N = Input data)
.cn

+3 +48
(Data number)
N
(N = Input data)

+4 +64
w

(Data attribute)
M
(M = Input data) Value
w

+5 +80
Setting data: Input data Setting data-dependent form
w
://
tp
ht

- 364 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.10 Reading a Custom Macro Variable (High-speed Response)

[Description]
A custom macro variable in the CNC can be read.
Custom macro variables may or may not be read depending on the

/
variable type.

om
(1) Local variables
Local variables (#1 to #33) cannot be read.
(2) Common variables
Common variables (#100 to #149 and #500 to #531) can be read

s.c
in floating-point representation. When the option to add
common variables is provided, however, common variables
range from #100 to #199 and #500 to #999.

re
For details of the custom macro variables, refer to the Operator's
Manual for the CNC.

CAUTION
pa
System variables cannot be read.
cs
[Input data structure]
WORD BOOL
type type
.cn

offset offset

Top address +0 +0
(Function code)
21
w

+1 +16
(Completion code)

(Need not be set)
w

+2 +32
(Data length in bytes)

w

(Need not be set)

+3 +48 (Data number)


N
://

(N = Custom macro
variable number)

+4 +64
(Data attribute)
M
tp

(M: Number of decimal places)

+5 +80 (Data area)



ht

(Need not be set)


≈ ≈

- 365 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The custom macro variable has been read normally.
3: The number of a custom macro variable that cannot be read was
specified as the data number.
5: The custom macro variable is not within the range from 0.0000001

/
to 99999999.

om
6: The custom macro option is not provided.

[Output data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)

re
21

+1 +16 (Completion code)

+2 +32
?
(See the explanation of
the completion codes.)

(Data length in bytes)


L
pa L = 6: Custom macro B
The mantissa of a floating-
cs
(L: Byte length of custom macro point number is indicated in 4
variable data)
bytes, and the exponent is
+3 +48 indicated in 2 bytes.
(Data number) M = 0: The number of decimal places
.cn

N
(N = Input data) is not specified.
M = 1 ≤ n ≤ 7:
The number of decimal places is specified.
+4 +64
(Data attribute) n stands for the number of decimal places.
M
(M: Number of decimal places) Value
w

+5 +80
Custom macro variable data (4 bytes) Signed binary
Mantissa (custom macro B) (A negative value is represented in 2's
complement.)
w

+7 +112
Custom macro variable data (2 bytes)
Exponent (custom macro B): Signed binary
w

The number of decimal digits 0 to 8 (no negative values)


://
tp
ht

- 366 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.11 Writing a Custom Macro Variable (Low-speed Response)

[Description]
Data can be written in a custom macro variable in the CNC.
For details of common variables, refer to the Operator's manual of the

/
CNC.

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
22

re
+1 +16
(Completion code)

(Need not be set)

+2 +32 (Data length in bytes)


L
(L: Byte length of custom
macro variable data)
pa L = 6: Custom macro B
The mantissa of a floating-point
number is indicated in 4 bytes,
cs
+3 +48 and the exponent is indicated in
(Data number) 2 bytes.
N
(N = Custom macro variable number)
.cn

+4 +64
(Data attribute)
0
Value

+5 +80
Custom macro variable data (4 bytes) Signed binary
w

Mantissa (custom macro B) (A negative value is represented in


2's complement.)
+7 +112 Custom macro variable data (2 bytes)
w

Exponent (custom macro B): Signed binary


The number of decimal digits
w
://
tp
ht

- 367 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The custom macro variable has been written normally.
2: The specified data length is invalid because it is not 6.
3: A custom macro variable number that cannot be written as the data
number was specified.

/
6: The custom macro option or the additional common variable

om
option has not been provided.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
22

re
+1 +16 (Completion code)
?
(See the explanation of

+2 +32 pa
the completion codes.)

(Data length in bytes)


L
(N: Input data)
cs
+3 +48
(Data number)
N
(N = Input data)
.cn

+4 +64
(Data attribute)

(Need not be set) Value
+80
w

+5
Custom macro variable data: Input Signed binary
data (A negative value is represented in
Mantissa (custom macro B) 2's complement.)
w

+7 +112 Custom macro variable data: Input


data
Signed binary
Exponent (custom macro B): The
number of decimal digits
w
://
tp
ht

- 368 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.12 Reading the CNC Alarm Status (High-speed Response)

[Description]
When the CNC is in the alarm status, the alarm status data can be read.
The following alarm status data can be read:

/
om
(1) First byte of alarm status data
7 6 5 4 3 2 1 0

s.c
PS1
PS2
PS3
PS

re
OTS
OH
SV

PS1
PS2
pa MALM

: P/S alarm 100 (PWE (parameter write enable) is set to 1.)


: P/S alarm 000 (Turn off the power before continuing
cs
operation. Some parameters activate this alarm status when
they are written.)
PS3 : P/S alarm 101 (The part program recording area is
.cn

disordered. This alarm is activated when the power to the


CNC is turned off during part program editing or reading of
a machining program. To release the alarm, then press the
RESET key while holding down the PROG key.)
PS : A P/S alarm other than the above alarm is generated
w

OTS : Stroke limit alarm


OH : Overheat alarm
SV : Servo alarm
w

MALM : Memory alarm


w
://
tp
ht

- 369 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

(2) Second byte of alarm status data


7 6 5 4 3 2 1 0

APAL

/
SPA

om
(Not used)
(Not used)
(Not used)
(Not used)
(Not used)

s.c
(Not used)

APAL : APC alarm


SPA : Spindle alarm

re
[Input data structure]
WORD
type
offset
BOOL
type
offset
pa
cs
Top address +0 +0
(Function code)
23
.cn

+1 +16
(Completion code)

(Need not be set)

+2 +32
w

(Data length in bytes)



(Need not be set)

+3 +48
w

(Data number)
0
w

+4 +64
(Data attribute)
0
://

+5 +80
(Data area)

(Need not be set)
tp

≈ ≈
ht

- 370 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Completion codes]
0: This alarm status in the CNC has been read normally.

/
[Output data structure]

om
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)

s.c
23

+1 +16 (Completion code)


?
(See the explanation of

re
the completion codes.)

+2 +32
(Data length in bytes)
L

+3 +48
(L = 2)

(Data number)

pa
cs
+4 +64
(Data attribute)

Value
.cn

+5 +80
2 byte bit data. For the meanings of
CNC alarm status data the bits, see [Description] in this
section.
w
w
w
://
tp
ht

- 371 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.4.13 Reading the Current Program Number (High-speed


Response)

[Description]
The program number of a machining program being executed or

/
selected on the CNC can be read.

om
When a subprogram is executed on the CNC, the program number of
the main program can also be read. Note that the program number that
can be read is the first program number (first loop main program).
This function accepts only 4-digit program numbers. When the
specification supports 8-digit program numbers, specify function code

s.c
90 to read 8-digit program numbers.

[Input data structure]

re
WORD BOOL
type type
offset offset

Top address +0 +0

pa
(Function code)
24
cs
+1 +16
(Completion code)

(Need not be set)
.cn

+2 +32
(Data length in bytes)

(Need not be set)

+3 +48
(Data number)
w

+4 +64
w

(Data attribute)
0

+5 +80
(Data area)
w


(Need not be set)
://
tp
ht

- 372 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Completion codes]
0: The program number of the currently executing program was read
successfully.
6: The program number is an 8 ‐ digit program number. (Use
function code 90.)

/
om
[Output data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
24

re
+1 +16
(Completion code)
?
(See the explanation above.)

+2 +32
pa
(Data length in bytes)
4
cs
+3 +48
(Data number)

.cn

+4 +64
(Data attribute)

Value
+5 +80
Current program number: ON
w

Unsigned binary, 2 bytes long

+6 +96 Program number of main program:


OMN
w
w

(a) Current program number (ON)


The program number of the program being executed is set.
(b) Program number of main program (OMN)
://

When the currently executing program is a subprogram, the


program number of its main program (first loop main
program) is set. When the currently executing program is
tp

not a subprogram, 0 is set.


ht

- 373 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.4.14 Reading the Current Sequence Number (High-speed


Response)

[Description]
The sequence number of a machining program being executed on the

/
CNC can be read. If sequence numbers are not assigned to all blocks

om
of the machining program, the sequence number of the most recently
executed block is read.

[Input data structure]

s.c
WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
25

+1 +16

+32
pa
(Completion code)

(Need not be set)
cs
+2
(Data length in bytes)

(Need not be set)

+48
.cn

+3
(Data number)
0

+4 +64
(Data attribute)
w

+5 +80 (Data area)



w

(Need not be set)

≈ ≈
w
://
tp
ht

- 374 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Completion codes]
0: The current sequence number has been read normally.

[Output data structure]

/
om
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)

s.c
25

+1 +16 (Completion code)


?
(See the explanation of
the completion codes.)

re
+2 +32
(Data length in bytes)
L Note that the data length must be set to 4
(L = 4) bytes even though the current program

+3 +48
(Data number)

pa number is 2 bytes long (the sequence
number is indicated by 5 digits).
cs
+4 +64
(Data attribute)

Value
.cn

+5 +80
Current sequence number Unsigned binary
w
w
w
://
tp
ht

- 375 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.4.15 Reading Modal Data (High-speed Response)

[Description]
Modal information can be read from the CNC.

/
(1) Format and types of modal data for the G function

om
Data corresponding to the specified identification code is read
and stored in the data area. Whether the data is specified in the
block specified in the attribute of the data is determined by the
value at the most significant bit.

s.c
7 6 5 4 3 2 1 0

• Code in a group 1 byte

re
1 byte

pa 0: Not specified in the block


1: Specified in the block
cs
.cn
w
w
w
://
tp
ht

- 376 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

Data type Data Data type Data


Identification G code for machining G code for lathe (T, G) Code in a
Code in a group
code center (M) A series B series C series group
G00 0 G00 G00 G00 0
G01 1 G01 G01 G01 1

/
G02 2 G02 G02 G02 2

om
G03 3 G03 G03 G03 3
G33 4 G32 G33 G33 4
G33 8
G34 G34 G34 9
0
G90 G77 G20 5

s.c
G92 G78 G21 6
G94 G79 G24 7
G71 G71 G72 10
G G G
G72 G72 G73 11
series series series

re
G73 only G73 only G74 only 12
G74 G74 G75 13
G17 0 G96 G96 G96 1
1

2
G18
G19
G90
G91
8
4
0
1
pa G97 G97

G90
G91
G97

G90
G91
0
1
0
cs
G68 G68 G68 1
3
G69 G69 G69 0
G94 0 G98 G94 G94 0
4
.cn

G95 1 G99 G95 G95 1


G20 0 G20 G20 G70 0
5
G21 1 G21 G21 G71 1
G40 0 G40 G40 G40 0
6 G41 1 G41 G41 G41 1
w

G42 2 G42 G42 G42 2


G43 1 G25 G25 G25 0
7 G44 2 G26 G26 G26 1
w

G49 0
G73 10 G22 G22 G22 1
G74 11 G23 G23 G23 0
w

G76 12
G80 0
G81 1
://

G82 2
8 G83 3
G84 4
tp

G85 5
G86 6
G87 7
ht

G88 8
G89 9
G98 0 G80 G80 G80 0
G99 1 G83 G83 G83 1
G84 G84 G84 2
9 G85 G85 G85 3
G87 G87 G87 5
G88 G88 G88 6
G89 G89 G89 7

- 377 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

Data type Data Data type Data


Identification G code for machining G code for lathe (T, G) Code in a
Code in a group
code center (M) A series B series C series group
G50 0 G98 G98 0
10
G51 1 G99 G99 1
G66 1 G66 G66 G66 1

/
11
G67 0 G67 G67 G67 0

om
G54 0 G54 G54 G54 0
G55 1 G55 G55 G55 1
G56 2 G56 G56 G56 2
13
G57 3 G57 G57 G57 3
G58 4 G58 G58 G58 4

s.c
G59 5 G59 G59 G59 5
G61 1
G62 2
14
G63 3

re
G64 0
G68 1
15
G69 0

16

17
G15
G16
G40.1
G41.1
0
1
1
2
pa
cs
G42.1 0
G25 0
18
G26 1
.cn

G50.2 G50.2 G50.2 0


19
G51.2 G51.2 G51.2 1
G13.1 0 G13.1 G13.1 G13.1 0
20
G12.1 1 G12.1 G12.1 G12.1 1
w

(2) Format and types of modal data for other than the G function
w

Data 4 bytes

FLAG1 1 byte
w

FLAG2 1 byte

7 6 5 4 3 2 1 0
://

- Number
- - of-input- digits

0: Positive
tp

1: Negative

0: A decimal point not specified


1: A decimal point specified
ht

0: Not specified in the current block


1: Specified in the current block

- - - - - Number of decimal places

- 378 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

NOTE
1 The specification of whether a decimal point is
specified or not, in FLAG1, and the specification of
the number of decimal places, in FLAG2, are valid
only for F code. Even if a decimal point is not

/
specified, the number of decimal places may not

om
be 0.
2 As the numbers of input digits, M, S, T, and B, in a
command address, the allowable numbers of digits
that are specified for the appropriate parameters
are returned.

s.c
M: Allowable number of digits of M code No. 3030
S: Allowable number of digits of S code No. 3031
T: Allowable number of digits of T code No. 3032

re
B: Allowable number of digits of B code No. 3033

pa
cs
.cn
w
w
w
://
tp
ht

- 379 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

Data type
Identification code Specified address
Enter identification
−2 codes 100 to 126 at

/
one time.

om
100 B (Second auxiliary function)
101 D
102 E (Reserved)
103 F
104 H
105 L

s.c
106 M
107 S
108 T
109 R

re
110 P
111 Q
112 A
113
114
115
116
pa C

K
I
J
cs
117 N
118 O
119 U
.cn

120 V
121 W
122 X
123 Y
124 Z
w

125 M2
126 M3
w
w
://
tp
ht

- 380 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Input data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0

om
(Function code)
32

+1 +16
(Completion code)

(Need not be set)

s.c
+2 +32
(Data length in bytes)

(Need not be set)

+48 N = 0 to: See the identification codes of list

re
+3
(Data number) of data explained above.
N N = −1: All data for G function
(N: Data type)
N = −2: All data for other than G function
+4

+5
+64

+80
(Data attribute)
M
(M: Specified block) pa M = 0: Current block

M = 1: Next block
cs
(Data area)
− M = 2: Block after the next block
(Need not be set)

≈ ≈
.cn
w

When all data items are specified to be read, the data items are all
output simultaneously in the order specified in the above data table.
w
w
://
tp
ht

- 381 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Modal information has been read normally.
3: Invalid data is specified as the data number.
4: Invalid data is specified as the data attribute.

/
om
[Output data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
32

+1 +16 (Completion code)

re
?
(See the explanation of
the completion codes.)
+2 +32 L=2 : G function

+3 +48
(Data length in bytes)
L
(L = 2, 6, 2*n, 6*m)

(Data number)
pa L = 2*n : All data for G function

L=6 : Other than G function


cs
L = 6*m : All data for other than G function
N (n: Number of groups for the G
(N: Input data) function)
(m: Number of types other than
+4 +64 for the G function)
(Data attribute)
.cn

M
(M: Input data) Value

+5 +80 See the data format for the G


Modal data for G function (2 bytes) function. The upper byte must always
be set to 0.
w

Or

+4 +64
(Data attribute)
w

M
(M: Input data) Value
+5 +80
w

Data part of modal data for other than See the data format for other than the
G function (4 bytes) G function.
://

+7 +112 See the flag format of the data for


Flag part of modal data for other than other than the G function. The upper
G function (2 bytes) byte must always be set to 0.
tp

When all data items are specified to be read, the data items are all
output simultaneously in the order specified in the above data table.
ht

- 382 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.16 Reading Diagnosis Data (High-speed Response)

[Description]
The information displayed on the diagnosis data screen in the CNC
can be read.

/
om
[Input data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
33 or 156

+1 +16

re
(Completion code)

(Need not be set)

+2 +32

+3 +48
pa
(Data length in bytes

(Need not be set)
cs
(Data number)
N
(N: Diagnosis No.)

+4 +64 M=0: No axis


.cn

(Data attribute)
M M = 1 to n: One axis
(M: Axis number)
M = −1: All axes
+5 +80 (Data area)

(Need not be set)
w
w
w
://
tp
ht

- 383 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Diagnosis data has been read from the CNC normally.
3: The specified diagnosis data number is invalid.
4: The data specified as the data attribute is invalid because it is
neither 0, -1, nor a value from 1 to n (n is the number of axes).

/
6: An option required for reading the specified diagnosis data, such as

om
the remote buffer option, is not provided.

[Output data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
33 or 156

+16
+1

+2 +32
(Completion code)
?
pa
(See the explanation of
the completion codes.)
When no axis or one axis is specified
L = 1: Bit or byte data
L = 2: Word data
L = 4: Double word data
cs
(Data length in bytes
L
(L = 1, 2, 4, 1*n, 2*n, 4*n)
When all axes are specified
+3 +48 L = 1*n: Bit or byte data
.cn

(Data number) L = 2*n: Word data


N L = 4*n: Double word data
(N: Input data)

+4 +64
(Data attribute)
M
w

(M: Input data) Value


+5 +80
Diagnosis data Data-dependent form
w
w
://
tp
ht

- 384 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.17 Reading Value of the P-code Macro Variable (High-speed


Response)

[Description]
This function gets the value of variable for Macro-compiler (P-code

/
macro variable) of specified number.

om
The extended P-code macro variable is not able to be read.

[Input data structure]


WORD BOOL

s.c
type type
offset offset

Top address +0 +0

(Function code)

re
59

+1 +16
(Completion code)

+2 +32 pa
(Need not be set)

(Data length in bytes)



cs
(Need not be set)

+3 +48
(Data number)
N
.cn

(P-code macro variable number)

+5 +80
(Data attribute)
0
w

+6 +96
(Data area)

(Need not be set)
w

CAUTION
w

The 'Data number' occupies 4 bytes instead of 2


bytes of usual data structure.
://
tp
ht

- 385 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to read the value of P-code macro variable.
3: The P-code macro variable specified by 'Data number' can not be
read.
5: The value of the P-code macro variable is out of range

/
(±0.0000001 -- ±99999999.).

om
6: No option, or no Macro ROM module.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
59

re
+1 +16
(Completion code)
?

+2 +32 pa
(See the explanation above)

(Data length in bytes)


6
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+5 +80
(Data attribute)

(Same as input data)
Value
+6 +96
w

Signed binary
Value of P-code macro variable (Minus number is represented by 2's
(4 bytes) complemental.)
w

+8 +128
Figures after decimal point of the value Signed binary
of P-code macro variable (Minus number is represented by 2's
(2 bytes) complemental.)
w
://
tp
ht

- 386 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.18 Writing Value of the P-code Macro Variable (Low-speed


Response)

[Description]
This function stores the value into the variable for Macro-compiler

/
(P-code macro variable) of specified number.

om
The extended P-code macro variable can not be written into.

[Input data structure]


WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)

re
60

+1 +16
(Completion code)

+2 +32 pa
(Need not be set)

(Data length in bytes)


cs
6

+3 +48
(Data number)
N
.cn

(P-code macro variable number)

+5 +80
(Data attribute)
0
Value
w

+6 +96 Signed binary


Value of P-code macro variable
(4 bytes) (Minus number is represented by 2's
complemental.)
w

+8 +128
Figures after decimal point of the Signed binary
value of P-code macro variable (Minus number is represented by 2's
(2 bytes) complemental.)
w
://

CAUTION
The 'data number' occupies 4 bytes instead of 2
bytes of usual data structure.
tp
ht

- 387 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to store the value into P-code macro variable.
2: The data length has illegal data (is not 6).
3: The P-code macro variable specified by 'Data number' can not be
written.

/
6: No option, or no Macro ROM module.

om
[Output data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
60

re
+1 +16
(Completion code)
?
(See the explanation above)

+2 +32

pa
(Data length in bytes)
6
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+5 +80
(Data attribute)

(Same as input data)

+6 +96
Value of P-code macro variable
w

(4 bytes)

+8 +128
Figures after decimal point of the
w

value of P-code macro variable


(2 bytes)
w
://
tp
ht

- 388 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.4.19 Reading CNC Status Information (High-speed Response)

[Description]
Status information (status indication on the screen) can be read from
the CNC.

/
The types of status information that can be read are as follows.

om
(1) Indication of which mode is selected, automatic or manual
(2) Status of automatic operation
(3) Status of movement along the axis and dwelling
(4) Status of M, S, T, and B functions
(5) Statuses of emergency stop and the reset signal

s.c
(6) Alarm status
(7) Status of program edits

(Indication)

re
pa
cs
[Input data structure]
.cn

WORD BOOL
type type
offset offset

Top address +0 +0
w

(Function code)
76
w

+1 +16
(Completion code)

(Need not be set)
w

+2 +32
(Data length in bytes)

(Need not be set)
://

+3 +48
(Data number)
0
tp

+4 +64
(Data attribute)
0
ht

+5 +80
(Data area)
≈ − ≈
(Need not be set)

- 389 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: CNC status information has been read normally.

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 390 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Output data structure]


WORD BOOL
type type
offset offset
Top address +0 +0

/
(Function code)
76

om
+1 +16 (Completion code)
?
(See the explanation of
the completion codes.)
+2 +32

s.c
(Data length in bytes)
14

+3 +48
(Data number)

re

(Input data)

+4 +64
(Data attribute)

+5 +80

pa
(Input data)

Indication of which mode is currently


selected, automatic or manual
0 : MDI
1 : MEMory
Value
cs
2 : **** (Other states)
(2 bytes) 3 : EDIT
4 : HaNDle
5 : JOG
6 : Teach in JOG
7 : Teach in HND
.cn

8 : INC. feed
9 : REFerence
10 : ReMoTe
+6 +96
Status of automatic operation 0 : **** (Reset states)
(2 bytes) 1 : STOP
2 : HOLD
w

3 : STaRT
+7 +112
Status of movement along the axis 0 : *** (Other states)
or dwelling (2 bytes) 1 : MoTioN
w

2 : DWell

+8 +128
Status of M, S, T, and B functions 0 : *** (Other states)
(2 bytes) 1 : FIN
w

+9 +144
Status of emergency stop (2 bytes) 0 : (Releases the emergency stop state)
1 : − −EMerGency − −
2 : − RESET −
://

(The reset signal is on.)


+10 +160
0 : *** (Other states)
Alarm status (2 bytes) 1 : ALarM
2 : BATtery low
tp

+11 +176 0 : ******* (Non editing)


Status of program edit (2 bytes) 1 : EDIT
2 : SeaRCH
ht

3 : OUTPUT
4 : INPUT
5 : COMPARE
6 : LabelSKip
7 : OFST
8 : WSFT
9 : ReSTaRt

- 391 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.4.20 Reading the Current Program Number (8-digit Program


Numbers) (High-speed Response)

[Description]
This function reads CNC program numbers extended to 8 digits from

/
the usual 4 digits.

om
Basically, this function is the same as function code 24 excluding the
different data length of function code 90.

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
90

+1

+2
+16

+32
pa
(Completion code)

(Need not be set)
cs
(Data length in bytes)

(Need not be set)

+3 +48
.cn

(Data number)
0

+4 +64

(Data attribute)
w

+5 +80
(Data area)

w

(Need not be set)

+9 +144
w
://
tp
ht

- 392 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Completion codes]
0: The program number of the currently executing program has been
read normally.

[Output data structure]

/
om
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)
90

s.c
+1 +16 (Completion code)
?
(See the explanation of the
completion codes, above.)

re
+2 +32
(Data length in bytes)
8

+3 +48
(Data number)
− pa
cs
+4 +64
(Data attribute)

Value
.cn

+5 +80
Number of the program currently Unsigned binary format, 4-byte length
being executed
ON
+7 +112
Program number of the main
w

program
ON

+9 +144
w

(a) Number of the program currently being executed (ON)


The program number of the program currently being executed is set.
(b) Program number of the main program (OFF)
If the program currently being executed is a subprogram, the program
w

number of its main program is set.


If the program currently being executed is not a subprogram, 0 is set.
://
tp
ht

- 393 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.4.21 Entering Data on the Program Check Screen (Low-speed


Response)

[Description]
On the program check screen of the CNC, data can be entered for the

/
spindle tool No. (HD.T) and the next tool No. (NX.T).

om
This function is effective only when bit 2 of parameter 3108 is 1.

[Input data structure]


WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)

re
150

+1 +16
(Completion code)

+2 +32

(Need not be set)

(Data length in bytes)


pa
cs
4

+3 +48 N = 0 : Spindle tool No. (8 digits)


(Data number)
N
.cn

(N = 0, 1)
N = 1 : Next tool No. (8 digits)
+4 +64
(Data attribute)
0 Value
w

+5 +80
Data for the spindle tool No. Unsigned binary
(4 bytes)
or data for the next tool No.
w

(4 bytes)
w
://
tp
ht

- 394 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Completion codes]
0: Data has been entered on the program check screen normally.
2: The data length in bytes is invalid.
3: The data No. is invalid.

/
[Output data structure]

om
WORD BOOL
type type
offset offset

Top address +0 +0

s.c
(Function code)
150

+1 +16 (Completion code)


?
(See the explanation of

re
the completion codes.)
+2 +32
(Data length in bytes)
4

+3 +48 pa
(Input data)

(Data number)
N
(Input data)
N = 0 : Spindle tool No.
cs
N = 1 : Next tool No.
+4 +64
(Data attribute)

.cn

(Input data) Value


+5 +80
Data for the spindle tool No. Unsigned binary
(4 bytes)
or data for the next tool No.
(4 bytes)
w
w
w
://
tp
ht

- 395 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.4.22 Reading Clock Data (Date and Time) (High-speed Response)

[Description]
The current date (year, month, day) and time (hours, minutes,
seconds) can be read from the clock built into the CNC.

/
om
[Input data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
151

+16

re
+1
(Completion code)

(Need not be set)

+2

+3
+32

+48

pa
(Data length in bytes)
(Need not be set)
N = −1: Reads current date and time.
cs
(Data number)
N N = 0: Reads current date.
(N = 0, 1)
N = 1: Reads current time.
+4 +64
.cn

(Data attribute)
0

+5 +80
(Data area)

w

(Need not be set)


w
w
://
tp
ht

- 396 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Completion codes]
0: Data of the clock built into the CNC has been read normally.
3: A value other than 0, 1, and -1 was specified for the data No.

[Output data structure]

/
om
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)
151

s.c
+1 +16 (Completion code)
?
(See the explanation of
the completion codes.)
+2 +32
(Data length in bytes)

re
6/12

+3 +48 (Data number)


N
(Input data)
+4

+5
+64

+80
(Data attribute)

(Input data) pa
Current date (year) or time (hours)
Value

Unsigned binary
cs
+6 +96 Current date (month) or time
(minutes)
.cn

+7 +112
Current date (day) or time (seconds)

When both the current date and current time are specified to be read by entering [−1] for the data No.

(Input data)
w

Value
+5 +80
Current date (year) Unsigned binary
w

+6 +96
Current date (month)
+7 +112
w

Current date (day)


+8 +128
Current time (hours)
://

+9 +144
Current time (minutes)
+10 +160
Current time (seconds)
tp

[Example] September 10th, 1990 [Example] 23:59:59


(hours:minutes:seconds)
ht

Data area Data area


WORD BOOL WORD BOOL
type type type type
offset offset 1990 offset offset 23
+1 +16 +1 +16
9 59
+2 +32 +2 +32
10 59

- 397 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.4.23 Specifying the Number of the Program for I/O Link(Low-speed


Response)

[Explanation of data]
Specify the number of the program to be input/output using the data

/
input/output function with I/O Link.

om
[Input data structure]
WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
194

re
+1 +16 (Completion code)

(Need not be set)

+2 +32
pa
(Data length in bytes)
2
cs
+3 +48
(Data number)
0
.cn

+4 +64
(Data attribute)
0
Value

+5 +80
w

Program number Signed binary format


w

+6 +96
w
://
tp
ht

- 398 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Completion codes]
0: The specification of the program number terminated normally.
5: Invalid data was specified for the program number, i.e., the data
falls outside the range of 1 to 9999 or is not - 9999.

/
[Output data structure]

om
WORD BOOL
type type
offset offset

Top address +0 +0

s.c
(Function code)
194

+1 +16 (Completion code)


re
(See the explanation of completion
codes, above.)
+2 +32
(Data length in bytes)

+3 +48
2
pa
(Data at input time)

(Data number)
0
cs
(Data at input time)

+4 +64 (Data attribute)


0
.cn

(Data at input time) Value

+5 +80 Signed binary format


Program number
(Data at input time)
w

+6 +96
w

CAUTION
For details of this function, see the section on data
w

input/output functions using I/O Link in the "CNC


Connection Manual (Functions)."
://
tp
ht

- 399 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.5 AXIS INFORMATION

A.5.1 Reading the Actual Velocity of Controlled Axes (High-speed


Response)

/
om
[Description]
The actual velocity of a movement on CNC-controlled axes can be
read. Note that the read speed is the composite velocity for the
controlled axes. When movement involves only the basic three axes,

s.c
the X, Y, and Z axes, the composite velocity equals the actual velocity.
When movement, however, involves the fourth axis, such as a rotation
axis or a parallel axis, as well as some of the basic three axes, the
composite velocity for all the relevant axes does not equal the actual
velocity.

re
[Input data structure]
WORD
type
offset
BOOL
type
offset
pa
cs
Top address +0 +0
(Function code)
26
.cn

+1 +16
(Completion code)

(Need not be set)

+2 +32
(Data length in bytes)
w


(Need not be set)

+3 +48
w

(Data number)
0

+4 +64
w

(Data attribute)
0
://

+5 +80
(Data area)

(Need not be set)
tp

≈ ≈
ht

- 400 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Completion codes]
0: The actual velocity for the controlled axes has been read normally.

[Output data structure]

/
WORD BOOL
type type

om
offset offset

Top address +0 +0
(Function code)
26

s.c
+1 +16 (Completion code)
?
(See the explanation of
the completion codes.)
+2 +32

re
(Data length in bytes)
L
(L = 4)

+3 +48

+4 +64
− pa
(Data number)
cs
(Data attribute)

Value

+5 +80 Actual velocity for controlled axes Unsigned binary


.cn

<Data increments>
• Input in mm
1 mm/min.
• Input in inches
0.01 inch/min.
w
w
w
://
tp
ht

- 401 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.5.2 Reading the Absolute Position (Absolute Coordinates) of


Controlled Axes (High-speed Response)

[Description]
The absolute coordinates of the CNC-controlled axes for movement

/
can be read. The absolute coordinates indicate those after cutter

om
compensation or tool length compensation.

[Input data structure]


WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)

re
27

+1 +16
(Completion code)

+2 +32 pa
(Need not be set)

(Data length in bytes)



cs
(Need not be set)

+3 +48
(Data number)
.cn

+4 +64 M = 1 to n: Absolute coordinate of a


(Data attribute) specific axis.
M n is the axis number.
(M = Axis number)
M = −1: Coordinates of all axes
w

+5 +80
(Data area)

(Need not be set)
w

≈ ≈
w
://

[Completion codes]
tp

0: The absolute coordinates of the controlled axes have been read


normally.
4: Data specified as the data attribute is invalid because it is neither -1
ht

nor a value from 1 to n (n is the number of axes). Alternatively,


the specified axis number is greater than the number of controlled
axes.

- 402 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Output data structure]


WORD BOOL
type type
offset offset

Top address +0 +0

/
(Function code)

om
27

+1 +16 (Completion code)


?
(See the explanation of
the completion codes.)

s.c
+2 +32 (Data length in bytes)
L
(L = 4*n, n is the number of
axes specified.)
+3 +48

re
(Data number)

+4 +64

+5 +80
M
pa
(Data attribute)
(M: Input data)

Absolute coordinate of the controlled Signed binary


Value
cs
axis specified (4 bytes) (A negative value is represented in 2's
complement.)

When the number of controlled axes is 4


.cn

Value
+5 +80
Absolute coordinate of the first axis Signed binary
(4 bytes) (A negative value is represented in
2's complement.)
w

+7 +112
Absolute coordinate of the second
axis (4 bytes)
+9 +144
w

Absolute coordinate of the third


axis (4 bytes)

+11 +176
Absolute coordinate of the fourth
w

axis (4 bytes)
://

[Output data unit]


Increment system
Input system
IS-B IS-C
tp

mm, deg 0.001 0.0001


Machining center system
inch 0.0001 0.00001
ht

Radius specification 0.001 0.0001


mm, deg
Lathe Diameter specification 0.001 0.0001
system Radius specification 0.0001 0.00001
inch
Diameter specification 0.0001 0.00001

- 403 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.5.3 Reading the Machine Position (Machine Coordinates) of


Controlled Axes (High-speed Response)

[Description]
The machine coordinates of CNC-controlled axes for movement can

/
be read. The read value equals the machine coordinate indicated on

om
the current position display screen displayed in the CNC. (This
screen can be displayed by pressing the function key POS.)

[Input data structure]

s.c
WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
28

+1 +16
(Completion code)

(Need not be set)
pa
cs
+2 +32
(Data length in bytes)

(Need not be set)
.cn

+3 +48
(Data number)
0

M = 1 to n: Machine coordinate of a
+4 +64
(Data attribute) specific axis.
M n is the axis number.
w

(M = Axis number)
M = −1: Coordinates of all axes
+5 +80
(Data area)
w


(Need not be set)
≈ ≈
w
://

CAUTION
tp

When an inch machine is used in metric input, or


when a millimeter machine is used in inch input, the
machine position that is read with bit 0 of parameter
ht

No. 3104 set to 1 differs from the value indicated by


the CNC. In this case, therefore, the value read
through the ladder must be calculated (converted).

- 404 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Completion codes]
0: The machine coordinates of the controlled axes have been read
normally.
4: Data specified as the data attribute is invalid because it is neither -1
nor a value from 1 to n (n is the number of axes). Alternatively,

/
the specified axis number is greater than the number of the

om
controlled axes.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
28

re
+1 +16 (Completion code)
?
(See the explanation of

+2 +32 pa
the completion codes.)

(Data length in bytes)


L
(L = 4*n, n is the number of
cs
axes specified.)
+3 +48
(Data number)

.cn

+4 +64
(Data attribute)
M
(M: Input data) Value
+5 +80
w

Machine coordinate of the controlled Signed binary


axis specified (4 bytes) (A negative value is represented in
2's complement.)
w

When the number of controlled axes is 4

Value
w

+5 +80
Machine coordinate of the first axis Signed binary
(4 bytes) (A negative value is represented in
2's complement.)
://

+7 +112
Machine coordinate of the second
axis (4 bytes)
+9 +144
Machine coordinate of the third axis
tp

(4 bytes)

+11 +176
Machine coordinate of the fourth
axis (4 bytes)
ht

- 405 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data unit]


Increment system
Input system
IS-B IS-C
mm, deg 0.001 0.0001
Machining center system
inch 0.0001 0.00001

/
Radius specification 0.001 0.0001

om
mm, deg
Lathe Diameter specification 0.001 0.0001
system Radius specification 0.0001 0.00001
inch
Diameter specification 0.0001 0.00001

s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 406 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.4 Reading a Skip Position (Stop Coordinates of Skip Operation


(G31)) of Controlled Axes (High-speed Response)

[Description]
When a block of the skip operation (G31) is executed by the CNC and

/
the skip signal goes on to stop the machine, the absolute coordinates

om
of the stop position on the axes of movement can be read.

[Input data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)

re
29

+1 +16
(Completion code)

+2 +32
(Need not be set)

pa
(Data length in bytes)

cs
(Need not be set)

+3 +48
(Data number)
.cn

+4 +64 M = 1 to n: Skip coordinate on a specific


(Data attribute) axis.
M n is the axis number.
(M = Axis number)
M = −1: Coordinates on all axes
w

+5 +80
(Data area)

(Need not be set)
w

≈ ≈
w
://

[Completion codes]
tp

0: The coordinates of the skip stop position for the controlled axes
have been read normally.
4: Data specified for the data attribute is invalid because it is neither
ht

-1 nor a value from 1 to n (n is the number of axes). Alternatively,


the specified axis number is greater than the number of controlled
axes.

- 407 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]


WORD BOOL
type type
offset offset

Top address +0 +0

/
(Function code)

om
29

+1 +16 (Completion code)


?
(See the explanation of
the completion codes.)

s.c
+2 +32 (Data length in bytes)
L
(L = 4*n, n is the number of
axes specified.)

+3 +48
(Data number)

re

+4 +64

+5 +80
M
pa
(Data attribute)
(M: Input data)

Skip coordinate of the controlled axis Signed binary


Value
cs
specified (4 bytes) (A negative value is represented in
2's complement.)

When the number of controlled axes is 4


.cn

Value
+5 +80
Skip coordinate of the first axis Signed binary
(4 bytes) (A negative value is represented in
2's complement.)
+7 +112
w

Skip coordinate of the second axis


(4 bytes)
+9 +144
Skip coordinate of the third axis
w

(4 bytes)
+11 +176
Skip coordinate of the fourth axis
w

(4 bytes)
://

[Output data unit]


Increment system
Input system
IS-B IS-C
tp

mm, deg 0.001 0.0001


Machining center system
inch 0.0001 0.00001
Radius specification 0.001 0.0001
ht

mm, deg
Lathe Diameter specification 0.001 0.0001
system Radius specification 0.0001 0.00001
inch
Diameter specification 0.0001 0.00001

- 408 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.5 Reading the Servo Delay for Controlled Axes (High-speed


Response)

[Description]
The servo delay, which is the difference between the specified

/
coordinates of CNC-controlled axes and the actual servo position, can

om
be read.

[Input data structure]


WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)

re
30

+1 +16
(Completion code)

+2 +32
(Need not be set)

pa
(Data length in bytes)

cs
(Need not be set)

+3 +48
(Data number)
.cn

+4 +64 M = 1 to n: Servo delay for a specific axis.


(Data attribute) n is the maximum axis number.
M
(M = Axis number)
M = −1: Servo delay for all axes
w

+5 +80
(Data area)

(Need not be set)
w

≈ ≈
w
://
tp
ht

- 409 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The servo delay for the controlled axes have been read normally.
4: The data specified as the data attribute is invalid because it is
neither -1 nor a value from 1 to n (n is the number of axes).
Alternatively, the specified axis number is greater than the number

/
of controlled axes.

om
[Output data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
30

re
+1 +16 (Completion code)
?
(See the explanation of

+2 +32
pa
the completion codes.)

(Data length in bytes)


L
(L = 4*n, n is the number of
axes specified.)
cs
+3 +48
(Data number)

.cn

+4 +64
(Data attribute)
M
(M: Input data) Value
+5 +80 Signed binary
w

Servo delay for the controlled axis


specified (4 bytes) (A negative value is represented in
2's complement.)
w

When the number of controlled axes is 4

Value
+5 +80
w

Servo delay for the first axis (4 bytes) Signed binary


(A negative value is represented in
2's complement.)
+7 +112
://

Servo delay for the second axis


(4 bytes)
+9 +144
Servo delay for the third axis (4 bytes)
tp

+11 +176
Servo delay for the fourth axis
(4 bytes)
ht

- 410 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.6 Reading the Acceleration/Deceleration Delay on Controlled


Axes (High-speed Response)

[Description]
The acceleration/deceleration delay, which is the difference between

/
the coordinates of controlled axes programmed in the CNC and the

om
position after acceleration/deceleration is performed, can be read.

[Input data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)

re
31

+1 +16
(Completion code)

+2 +32

(Need not be set)

(Data length in bytes)



pa
cs
(Need not be set)

+3 +48
(Data number)
.cn

+4 +64 M = 1 to n: Acceleration/deceleration delay


(Data attribute) for a specific axis. n is the
M maximum axis number.
(M = Axis number)
M = −1: Acceleration/deceleration delay
w

+5 +80 for all axes


(Data area)

(Need not be set)
w

≈ ≈
w
://

[Completion codes]
tp

0: The acceleration/deceleration delay for the control axis has been


read normally.
4: The data specified as the data attribute is invalid because it is
ht

neither -1 nor a value from 1 to n (n is the number of axes).


Alternatively, the specified axis number is greater than the number
of controlled axes.

- 411 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]


WORD BOOL
type type
offset offset

/
Top address +0 +0

om
(Function code)
31

+1 +16 (Completion code)


?
(See the explanation of
the completion codes.)

s.c
+2 +32 (Data length in bytes)
L
(L = 4*n, n is the number of
axes specified.)
+3 +48

re
(Data number)

+4

+5
+64

+80
pa
(Data attribute)
M
(M: Input data)

Acceleration/deceleration delay for the Signed binary


Value
cs
controlled axis specified (4 bytes) (A negative value is represented in
2's complement.)

When the number of controlled axes is 4


.cn

Value
+5 +80
Acceleration/deceleration delay for Signed binary
the first axis (4 bytes) (A negative value is represented in
2's complement.)
w

+7 +112
Acceleration/deceleration delay for the
second axis (4 bytes)
+9 +144
w

Acceleration/deceleration delay for the


third axis (4 bytes)
+11 +176
w

Acceleration/deceleration delay for the


fourth axis (4 bytes)
://

[Output data unit]


Increment system
Input system
tp

IS-B IS-C
mm, deg 0.001 0.0001
Machining center system
inch 0.0001 0.00001
ht

Radius specification 0.001 0.0001


mm, deg
Lathe Diameter specification 0.001 0.0001
system Radius specification 0.0001 0.00001
inch
Diameter specification 0.0001 0.00001

- 412 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.7 Reading the Feed Motor Load Current Value (A/D


Conversion Data) (High-speed Response)

[Description]
The digital value converted from the load current of the

/
CNC-controlled axis can be read.

om
[Input data structure]
WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
34

re
+1 +16
(Completion code)

(Need not be set)

+2 +32
pa
(Data length in bytes)

(Need not be set)
cs
+3 +48
(Data number)
N
(N: Type of analog voltage)
.cn

+4 +64
(Data attribute)
M
(M = 1 to 8: Axis specification)

+5 +80
(Data area)
w


(Need not be set)
w

(a) Type of analog voltage (data number)


w

N Type of analog voltage


0 (reserved)
2 Load information for the CNC-controlled axes
://

(b) Specifying a CNC-controlled axis (data attribute)


Specify a CNC-controlled axis number for which the
tp

voltage conversion data for the load current is to be read.


CAUTION
There is no general-purpose analog input on i
ht

series. If you need such a function, use the I/O


Link analog input module.

- 413 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: A/D conversion data has been read normally.
3: The data specified for the data number is invalid.
4: The data specified for the data attribute is invalid, or the specified
axis number is greater than the number of controlled axes.

/
6: No analog input module is connected.

om
[Output data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
34

+1 +16 (Completion code)

re
?
(See the explanation of
the completion codes.)
+2 +32

+3 +48
2
pa
(Data length in bytes)
cs
(Data number)
N
(Input data)

+4 +64
.cn

(Data attribute)
M
(Input data) Value
+5 +80
A/D conversion data (2 bytes) Binary number from 0 to ±6554
(For CNC controlled axis load
w

information)
w

(a) A/D conversion data (AD) of CNC controlled axis load


information
The load current for the specified CNC controlled axis is
w

converted into analog voltage, the input to the A/D


converter to output a digital data.
The value actually set in the AD field is obtained from the
://

following formula:
tp

N
(AD) × = Load current [Apeak]
6554

AD =A/D conversion data [Value read by the window function (±)]


ht

N = Nominal current limit for the amplifier corresponding to the motor

NOTE
For the nominal current limits, see the descriptions
of the control motor.

- 414 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.8 Reading the Actual Spindle Speed (High-speed Response)

[Description]
The actual speed of the spindle can be read from the CNC.

/
[Input data structure]

om
WORD BOOL
type type
offset offset

Top address +0 +0

s.c
(Function code)
50

+1 +16
(Completion code)

re
(Need not be set)

+2 +32
(Data length in bytes)

+3 +48 pa −
(Need not be set)

(Data number)
cs
0

+4 +64

(Data attribute)
.cn

+5 +80
(Data area)

(Need not be set)
w

≈ ≈
w
w
://
tp
ht

- 415 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The actual speed of the spindle has been read normally.

[Output data structure]

/
WORD BOOL
type type

om
offset offset

Top address +0 +0
(Function code)
50

s.c
+1 +16 (Completion code)
?
(See the explanation of
the completion codes.)

+2 +32

re
(Data length in bytes)
4

+3 +48

+4 +64
(Data number)

pa
cs
(Data attribute)
− Value

+5 +80 Actual spindle speed Unsigned binary


.cn

<Data unit>
min−1
w
w
w
://
tp
ht

- 416 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.9 Reading the Relative Position on a Controlled Axis


(High-speed Response)

[Description]
The relative coordinates of the machine moving along an axis

/
controlled by the CNC can be read.

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0

(Function code)
74

re
+1 +16
(Completion code)

+2 +32
(Need not be set)

pa
(Data length in bytes)

(Need not be set)
cs
+3 +48
(Data number)
0
.cn

+4 +64 M = 1 to n: Reads the relative coordinates


(Data attribute)
M of each axis. n is an axis No.
(M: Axis number)
M = −1: Reads the relative coordinates
+5 +80 of all axes.
w

(Data area)

(Need not be set)
w

≈ ≈
w
://

[Completion codes]
tp

0: The relative coordinates on the controlled axis have been read


normally.
4: The specified data attribute is invalid. That is, a value other than
ht

−1 and 1 to n (number of axes) was specified, or the specified axis


No. was greater than the number of controlled axes.

- 417 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]


WORD BOOL
type type
offset offset

Top address +0 +0

/
(Function code)

om
74

+1 +16 (Completion code)


?
(See the explanation of
the completion codes.)

s.c
+2 +32
(Data length in bytes)
L
(L = 4*n. n is the number of
specified axes.)
+3 +48

re
(Data number)

+4 +64

+5 +80
M
pa
(Data attribute)
(M: Input data)

Relative coordinates on the Signed binary


Value
cs
specified controlled axis (4 bytes) (A negative value is represented in
2's complement.)
When the number of controlled axes is 4
.cn

Value
+5 +80
Relative coordinates on the first Signed binary
axis (4 bytes) (A negative value is represented in
2's complement.)
w

+7 +112
Relative coordinates on the second
axis (4 bytes)
+9 +144
w

Relative coordinates on the third


(4 bytes)
+11 +176
Relative coordinates on the fourth
w

axis (4 bytes)
://

[Output data unit]


Increment system
Input system
IS-B IS-C
tp

mm, deg 0.001 0.0001


Machining center system
inch 0.0001 0.00001
Radius specification 0.001 0.0001
ht

mm, deg
Lathe Diameter specification 0.001 0.0001
system Radius specification 0.0001 0.00001
inch
Diameter specification 0.0001 0.00001

Double values can be read for a machining center system or when


radius specification is used for the relevant axis of a lathe system.

- 418 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.10 Reading the Remaining Travel (High-speed Response)

[Description]
The remaining travel of the machine along an axis controlled by the
CNC can be read. The read value equals the remaining travel

/
indicated on the current position display screen on the CNC. (This

om
screen can be called by pressing the function key <POS>.)

[Input data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0

re
(Function code)
75

+1 +16
(Completion code)

+2 +32

(Need not be set)

(Data length in bytes)



pa
cs
(Need not be set)

+3 +48
(Data number)
.cn

+4 +64
M = 1 to n: Reads the remaining travel along
(Data attribute)
M each axis. n is an axis No.
(M: Axis number)
M = −1: Reads the remaining travel along
w

+5 +80 all axes.


(Data area)

(Need not be set)
w

≈ ≈
w
://

[Completion codes]
0: The remaining travel along the controlled axis has been read
tp

normally.
4: The specified data attribute is invalid. That is, a value other than
−1 and 1 to n (number of axes) was specified, or the specified axis
ht

No. was greater than the number of controlled axes.

- 419 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]


WORD BOOL
type type
offset offset
Top address +0 +0

/
(Function code)

om
75

+1 +16 (Completion code)


?
(See the explanation of
the completion codes.)

s.c
+2 +32
(Data length in bytes)
L
(L = 4*n. n is the number of
specified axes.)
+3 +48

re
(Data number)

+4 +64
(Data attribute)

+5 +80
M

pa
(M: Input data)

Remaining travel along the


specified controlled axis (4 bytes)
Signed binary
Value

(A negative value is represented in


cs
2's complement.)

When the number of controlled axes is 4


.cn

Value
+5 +80
Remaining travel along the first Signed binary
axis (4 bytes) (A negative value is represented in
2's complement.)
+7 +112
w

Remaining travel along the second


axis (4 bytes)
+9 +144
Remaining travel along the third
w

axis (4 bytes)
+11 +176
Remaining travel along the fourth
axis (4 bytes)
w

[Output data unit]


://

Increment system
Input system
IS-B IS-C
tp

mm, deg 0.001 0.0001


Machining center system
inch 0.0001 0.00001
Radius specification 0.001 0.0001
mm, deg
ht

Lathe Diameter specification 0.0005 0.00005


system Radius specification 0.0001 0.00001
inch
Diameter specification 0.00005 0.000005
In the above table, when a machining center system is used or the
radius is specified for the corresponding axis of the lathe system,
double the value is read.

- 420 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.11 Reading Actual Spindle Speeds (High-speed Response)


(1) Actual spindle speed

[Description]

/
This function reads the actual speed of the No.1 to No.4 serial

om
spindles.

[Input data structure]


WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
138

re
+1 +16
(Completion code)

+2 +32
(Need not be set)

(Data length in bytes)



(Need not be set)
pa
cs
+3 +48
(Data number)
0
.cn

+4 +64 M = 1 to n: Read spindles on each axis.


(Data attribute) (n is the spindle number.)
M −1: Read spindles on No.1 and No.2 axes
(M = Spindle number)
−2: Read spindles on No.1 to No.3 axes
−3: Read spindles on No.1 to No.4 axes
w

+5 +80
(Data area)

(Need not be set)
w
w
://
tp
ht

- 421 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The actual spindle speed was read successfully.
4: The spindle speed in 'Data Attribute' has wrong values, that is, a
value outside of the range -1 to -(n - 1) or 1 to n (n: number of
spindles).

/
om
[Output data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
138

+1 +16

re
(Completion code)
?
(See the explanation above.)

+2 +32

+3 +48
(L = 4 × n)
pa
(Data length in bytes)
L
cs
(Data number)

+4 +64
(Data attribute)
.cn

M
(Entered data)
Value
+5 +80
Actual speed of specified spindle Signed binary
<Data unit>
min−1
w

+7 +112

Or, 4 spindles:
w

Value
w

+5 +80
Actual speed of No.1 spindle Signed binary
<Data unit>
+7 +112 min−1
Actual speed of No.2 spindle
://

+9 +144
Actual speed of No.3 spindle
tp

+11 +176
Actual speed of No.4 spindle

+13 +208
ht

- 422 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

(2) Position coder-less actual spindle speed

[Description]
This function reads the actual spindle speed (position coder-less actual
spindle speed) obtained by calculating the spindle motor speed of the

/
No.1 to No.4 serial spindles.

om
[Input data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
138

re
+1 +16
(Completion code)

(Need not be set)

+2

+3
+32

+48
(Data length in bytes)

(Need not be set) pa
cs
(Data number)
0

+64
.cn

+4
(Data attribute) M = 11 to
M (10 + n): Read spindles on each axis.
(M = Spindle number + 10) (n is the spindle number.)
−11: Read spindles on No.1 and No.2 axes
+5 +80 −12: Read spindles on No.1 to No.3 axes
(Data area) −13: Read spindles on No.1 to No.4 axes

w

(Need not be set)


+6 +96
w
w
://
tp
ht

- 423 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The actual spindle speed was read successfully.
4: The spindle speed in 'Data Attribute' has wrong values, that is, a
value outside of the range -11 to -(9 + n) or 11 to (10 + n) (n:
number of spindles).

/
om
[Output data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
138

+1 +16

re
(Completion code)
?
(See the explanation above.)

+2 +32

+3 +48
pa
(Data length in bytes)
L
(L = 4 × n)
cs
(Data number)

+4 +64
(Data attribute)
.cn

M
(Entered data)
Value
+5 +80
Position coder-less actual spindle Signed binary
speed <Data unit>
min−1
w

+7 +112

Or, 4 spindles:
w

Value
w

+5 +80
Position coder-less actual No.1 Signed binary
spindle speed <Data unit>
+7 +112 min−1
://

Position coder-less actual No.2


spindle speed
+9 +144
Position coder-less actual No.3
spindle speed
tp

+11 +176
Position coder-less actual No.4
spindle speed
+13 +208
ht

- 424 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.12 Entering Torque Limit Data for the Digital Servo Motor
(Low-speed Response)

[Description]
Torque limit values for the digital servo motor can be entered.

/
om
[Input data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
152

+1 +16

re
(Completion code)

(Need not be set)

+2

+3
+32

+48
pa
(Data length in bytes)
2
cs
(Data number)
0

+4 +64
.cn

(Data attribute)
M M = 1 to n: Axis No.
(M: 1 to n)

Value
+5 +80
w

Torque limit data Unsigned binary


(1 byte) <Unit: %>
The high-order byte is always set to Values from 0 to 255 correspond to
0. 0% to 100%.
w

CAUTION
w

Calculate the torque limit data assuming that the


short time rated value is 100%.
://

Example: To specify a torque limit of 50%, enter


128.
tp
ht

- 425 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Torque limit data has been entered normally.
4: The specified data attribute is invalid. That is, a value other than
1 to n (number of axes) was specified, or the specified axis No.
was greater than the number of controlled axes.

/
om
[Output data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
152

re
+1 +16
(Completion code)
?
(See the explanation of
the completion codes.)
+2 +32
pa
(Data length in bytes)
2
(Input data)
cs
+3 +48
(Data number)

(Input data)
.cn

+4 +64
(Data attribute)
M
(M: Input data) Value
+5 +80
Torque limit data (1 byte): Input data Unsigned binary
<Unit: %>
w

The high-order byte is always set to


0. Values from 0 to 255 correspond to
0% to 100%.
w
w
://
tp
ht

- 426 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.13 Reading Load Information of the Spindle Motor (Serial


Interface) (High-speed Response)

[Description]
Load information of the serial spindle can be read.

/
The equation to normalize the load information is shown below

om
L
Load(%) = λ
32767
L: Data read from the window
λ: The percentage of the maximum output of the motor to the

s.c
continuous rated output of the motor (When the maximum output
is 180% and the continuous rated output is 100%, the percentage is
180.)

re
CAUTION
The "λ" is equal to the value of parameter No. 4127.

WORD BOOL
[Input data structure] pa
cs
type type
offset offset

Top address +0 +0
.cn

(Function code)
153

+1 +16
(Completion code)

(Need not be set)
w

+2 +32
(Data length in bytes)

w

(Need not be set)

+3 +48
(Data number)
w

N N = 0: Read the load of the No.1 spindle.


(Need not be set) 1: Read the load of the No.2 spindle.
2: Read the load of the No.3 spindle.
+4 +64 3: Read the load of the No.4 spindle.
://

(Data attribute) −1: Read the loads of the No.1 and No.2 spindles.
0 −2: Read the loads of the No.1 to No.3 spindles.
−3: Read the loads of the No.1 to No.4 spindles.
+5 +80
tp

(Data area)

(Need not be set)

≈ ≈
ht

- 427 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Load information of the serial spindle has been read normally.

[Output data structure]

/
WORD BOOL

om
type type
offset offset

Top address +0 +0
(Function c of ode)
153

s.c
+1 +16 (Completion code)
?
(See the explanation of the
completion codes.) L = 2: Specifies the first axis.
L = 4: Specifies the second axis. (when N = −1)
Specifies the third axis. (when N = −2)

re
+2 +32 L = 6:
(Data length in bytes) L = 8: Specifies the fourth axis. (when N = −3)
L
N = 0: Read the load of the No.1 spindle.
(L = 2, 4) N = 1: Read the load of the No.2 spindle.
+3

+4
+48

+64
(Data number)
N
(N: Input data)
pa N = 2:
N = 3:
N = −1:
Read the load of the No.3 spindle.
Read the load of the No.4 spindle.
Read the loads of the No.1 and No.2
spindles.
N = −2: Read the loads of the No.1 to No.3
spindles.
cs
N = −3: Read the loads of the No.1 to No.4
(Data attribute)
− Value
+5 +80
.cn

Load information of the serial Unsigned binary, 2 bytes long


spindle (first or second axis)

When two axes are specified


w

+4 +64

(Data attribute)
− Value
w

+5 +80
First axis in the load information of Unsigned binary, 2 bytes long
the serial spindle
w

+6 +96
Second axis in the load information
of the serial spindle
://
tp
ht

- 428 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

When three axes are specified

+4 +64

(Data attribute)

/
Value

om
+5 +80
First axis in the load information of Unsigned binary, 2 bytes long
the serial spindle
+6 +96
Second axis in the load information
of the serial spindle
+7 +112
Third axis in the load information of

s.c
the serial spindle

When four axes are specified

re
+4 +64
(Data attribute)
− Value
+5

+6
+80

+96
the serial spindle pa
First axis in the load information of

Second axis in the load information


Unsigned binary, 2 bytes long
cs
of the serial spindle

+7 +112
Third axis in the load information of
the serial spindle
.cn

+8 +128
Fourth axis in the load information
of the serial spindle
w
w
w
://
tp
ht

- 429 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.5.14 Reading the servo data of the control axes (High-speed


Response)

[Description]
This function can read the following information of servo motor.

/
- Actual speed (rev / min)

om
- Thermal simulation data (OVC data)
- Torque command

The read "Torque command" is normalized from -6554 to 6554. The


value 6554 corresponds to the maximum current of servo amplifier.

s.c
Applying the following formula to this value, you can determine the
ratio of the torque command to the maximum current of amplifier.
Ratio (%) = [data] * 100 / 6554
Applying the following formula, you can also determine the torque

re
command (Apeak).
Torque command (Apeak) = [data] * [maximum current of
amplifier] / 6554

[Input data structure]pa


cs
WORD BOOL
type type
offset offset
.cn

Top Address +0 +0 (Function code)


207

+1 +16 (Completion code)


-
w

(Need not to be set)


+2 +32 (Data length in bytes)
-
w

(Need not to be set)


-1
+3 +48 (Data number) N = 11: Actual speed (min )
N 14: Thermal simulation data
w

(OVC data)
15: Torque command
+4 +64 (Data attribute) M = 1 to n: Axis number
://

M -1: All axes


(M=Axis number)
+5 +80 (Data area)
tp

-
(Need not to be set)
ht

- 430 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Completion codes]
0: Normal completion
3: The data number is invalid.
4: Data specified as the data attribute is invalid because it is neither -1
nor a value from 1 to n (n is the number of axes).

/
om
[Output data structure]

Reading the actual speed for one axis (N=11)

WORD BOOL

s.c
type type
offset offset
Top Address +0 +0 (Function code)
207

re
+1 +16 (Completion code)
-

+2 +32
pa
(See above description)
(Data length in bytes)
L
(L=4*n)
The n means the number of read parameters.
cs
+3 +48 (Data number)
N=11
(Input data)
.cn

+4 +64 (Data attribute)


M
(Input data)
+5 +80 Actual speed Signed binary format in 4 bytes length
-1
Data unit: min
w

(4 bytes)
+7 +112
w
w
://
tp
ht

- 431 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

Reading the actual speed for all axes (N=11, Example for 3 controlled-axes)

WORD BOOL

/
type type

om
offset offset
Top Address +0 +0 (Function code)
207

+1 +16 (Completion code)

s.c
-
(See above description)
+2 +32 (Data length in bytes) The n means the number of read parameters.
L
(L=4*n)

re
+3 +48 (Data number)
N=11
(Input data)
+4

+5
+64

+80
-1 pa
(Data attribute)

Actual speed for 1st axis Signed binary format in 4 bytes length
cs
-1
Data unit: min
(4 bytes)
+7 +112 Actual speed for 2nd axis
.cn

(4 bytes)
+9 +144 Actual speed for 3rd axis

(4 bytes)
w

+11 +176
w
w
://
tp
ht

- 432 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Output data structure]

Reading the thermal simulation data for one axis (N=14)

WORD BOOL

/
type type

om
offset offset
Top Address +0 +0 (Function code)
207

+1 +16 (Completion code)

s.c
-
(See above description)
+2 +32 (Data length in bytes)
L
(L=2*n)

re
+3 +48 (Data number)
N=14
(Input data)
+4

+5
+64

+80
(Data attribute)
M
(Input data)
pa
Thermal simulation data Signed binary format in 2 bytes length
cs
Data unit: %
(2 bytes) The OVC alarm will happen when this value is
100 %.
.cn

+6 +96
w
w
w
://
tp
ht

- 433 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

Reading the thermal simulation data for all axes (N=14, Example for 3 controlled-axes)

WORD BOOL

/
type type

om
offset offset
Top Address +0 +0 (Function code)
207

+1 +16 (Completion code)

s.c
-
(See above description)
+2 +32 (Data length in bytes)
L
(L=2*n)

re
+3 +48 (Data number)
N=14
(Input data)
+4

+5
+64

+80
-1 pa
(Data attribute)

Thermal simulation data for 1st Signed binary format in 2 bytes length
cs
axis Data unit: %
(2 bytes) The OVC alarm will happen when this value is
100 %.
.cn

+6 +96 Thermal simulation data for 2nd


axis
(2 bytes)
+7 +112 Thermal simulation data for 3rd
axis
w

(2 bytes)
+8 +128
w
w
://
tp
ht

- 434 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Output data structure]

Reading the torque command for one axis (N=15)

WORD BOOL

/
type type

om
offset offset
Top Address +0 +0 (Function code)
207

+1 +16 (Completion code)

s.c
-
(See above description)
+2 +32 (Data length in bytes)
L
(L=2*n)

re
+3 +48 (Data number)
N=15
(Input data)
+4

+5
+64

+80
(Input data)
Torque command
pa
(Data attribute)
M

Signed binary format in 2 bytes length


cs
Data: This data is nomalized from -6554 to 6554.
(2 bytes)
+6 +96
.cn
w
w
w
://
tp
ht

- 435 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

Reading the torque command for all axes (N=15, Example for 3 controlled-axes)

WORD BOOL

/
type type

om
offset offset
Top Address +0 +0 (Function code)
207

+1 +16 (Completion code)

s.c
-
(See above description)
+2 +32 (Data length in bytes)
L
(L=2*n)

re
+3 +48 (Data number)
N=15
(Input data)
+4

+5
+64

+80
-1 pa
(Data attribute)

Torque command for 1st axis Signed binary format in 2 bytes length
cs
Data: This data is nomalized from -6554 to 6554.
(2 bytes)
+6 +96 Torque command for 2nd axis
.cn

(2 bytes)
+7 +112 Torque command for 3rd axis

(2 bytes)
w

+8 +128
w
w
://
tp
ht

- 436 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.15 Reading the Estimate Disturbance Torque Data (High-speed


Response)

CAUTION
The unexpected disturbance torque detection

/
function option is required. For detailed settings of

om
parameters and so forth, refer to the description of
unexpected disturbance torque detection in the
connection manual (functions).

s.c
(1) Servo axis

[Description]
The load torques except a necessary torque for acceleration /

re
deceleration of the digital servo axis are read.

WORD
type
BOOL
type
[Input data structure]
pa
cs
offset offset

Top address +0 +0
.cn

(Function code)
211

+1 +16
(Completion code)

(Need not to be set)
w

+2 +32
(Data length in bytes)

(Need not to be set)
w

+3 +48
(Data number)
w

+4 +64
(Data attribute) M = 1 to n: Estimate disturbance torque
://

M data for specific axis. "n" is


(M = Axis number) the axis number.

+5 +80 M = −1: Estimate disturbance torque


(Data area) data for all axes.
tp


(Need not to be set)

+6 +96
ht

- 437 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The estimate disturbance torque data have been read normally.
4: The data specified as the data attribute is invalid because it is
neither -1 nor a value from 1 to n (n is the number of axes).
Alternatively, the specified axis number is greater than the number

/
of controlled axes.

om
[Output data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
211

re
+1 +16 (Completion code)
?
(See the explanation of the
completion codes. )
+2 +32

pa
(Data length in bytes)
L
(L = 2 × n, n is the number
of axes specified.)
cs
+3 +48
(Data number)
0
.cn

+4 +64
(Data attribute)
M
(M: Input data)
Value
+5 +80
Estimate disturbance torque data (A negative value is represented in
for the controlled axis specified 2's complement. )
w

(2 bytes)

+6 +96
w

When the number of controlled axes is 4


w

Value
+5 +80 Estimate disturbance torque
data for first axis Signed binary
(2 bytes)
://

2's complement. )
+6 +96 Estimate disturbance torque
data for second axis
(2 bytes)
+7 +112 Estimate disturbance torque
tp

data for third axis


(2 bytes)
+8 +128 Estimate disturbance torque
data for fourth axis
ht

(2 bytes)
+9 +144

- 438 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

(2) Spindle axis

[Description]
The load torques except a necessary torque for acceleration /
deceleration of the serial spindle axis are read.

/
om
[Input data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0

(Function code)
211

re
+1 +16
(Completion code)

(Need not to be set)

+2 +32
pa
(Data length in bytes)

(Need not to be set)
cs
+3 +48
(Data number)
1 M = 1 to n: Read the load of each spindle.
(n is the spindle number.)
.cn

+4 +64 −1: Read the loads of the No.1 and No.2


(Data attribute) spindles.
M −2: Read the loads of the No.1 to No.3
(M = Spindle number) spindles.
−3: Read the loads of the No.1 to No.4
+5 +80
(Data area) spindles.
w


(Need not to be set)

+6 +96
w
w
://
tp
ht

- 439 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The estimate disturbance torque data have been read normally.
4: The data specified as the data attribute is invalid because it is
neither -1 nor a value from 1 to n (n is the number of axes).
Alternatively, the specified axis number is greater than the number

/
of controlled axes.

om
[Output data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
211

re
+1 +16 (Completion code)
?
(See the explanation of
the completion codes. )
+2 +32
pa
(Data length in bytes)
L
(L = 2 × n, n is the number
of axes specified. )
cs
+3 +48
(Data number)
1
.cn

+4 +64
(Data attribute)
M
(M: Input data)
Value
+5 +80
Estimate disturbance torque Signed binary
(A negative value is represented in
w

data for the controlled axis 2's complement.)


specified (2 bytes)
+6 +96
w

When the number of controlled axes is 2


w

Value
+5 +80
Estimate disturbance torque Signed binary
data for first axis (2 bytes) (A negative value is represented in
://

2's complement.)
≈ ≈
+4 + n +64 +
(16 × n) Estimate disturbance torque
data for second axis (2 bytes)
tp
ht

- 440 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.16 Reading Fine Torque Sensing Data (Statistical Calculation


Results) (High-speed Response)

[Description]
This function reads the statistical calculation results (average value,

/
maximum value, and distribution) in the fine torque sensing function.

om
[Input data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
226

re
+1 +16
(Completion code)

(Need not be set)

+2 +32

pa
(Data length in bytes)

(Need not be set)
cs
+3 +48 N=1 to n: Read spindles on each axis.
(Data number) (n is the spindle number.)
N
(N=Axis number)
-1: Read all axes
.cn

+4 +64
(Data attribute)
0

+5 +80 (Data area)



w

(Need not be set)

+6 +96
w

[Completion codes]
w

0: The statistical calculation results were read successfully.


3: The fine torque sensing data in ’Data Attribute’ has a wrong value,
://

that is, a value outside of the range -1 or 1 to n (n: number of


spindles).
6: The fine torque sensing option has not been added on.
tp
ht

- 441 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]


WORD BOOL
type type
offset offset

Top address +0 +0

/
(Function code)
226

om
+1 +16 (Completion code)

(See the above explanation.)

+2 +32

s.c
(Data length in bytes)
L
L=6×n

+3 +48
(Data number)

re

+4 +64
(Data attribute)

+5 +80

pa
(Entered data)

Signed binary
Value
cs
Average value of target axis

+6 +96
.cn

Maximum value of target axis

+7 +112
Distribution of target axis
w

+8 +128
Or, 4 controlled axes:
w

Value
+5 +80 Signed binary
Average value of target axis 1
(Output only for number of axes
w

+6 +96 specified to parameter No. 6390 to


Maximum value of target axis 1 6363)

+7 +112
Distribution of target axis 1
://

+8 +128
Average value of target axis 2
+9 +144
tp

Maximum value of target axis 2


+10 +160
Distribution of target axis 2
ht


+16 +256
Average value of target axis 4

+17 +272

- 442 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.5.17 Reading Fine Torque Sensing Data (Store Data) (High-speed


Response)
(1) Store counter

[Description]

/
This function reads the number of stored torque data items.

om
[Input data structure]
WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
232

re
+1 +16
(Completion code)
?

+2 +32 pa
(Need not be set)

(Data length in bytes)


2
cs
(Need not be set)

+3 +48 (Data number)


0
.cn

+4 +64
(Data attribute)
M M= 0 : Latest data counter
(M=Tool number) = 1 : Sample data counter
w

+5 +80
(Data area)

(Need not be set)
w
w
://
tp
ht

- 443 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The store counter was read successfully.
3: Incorrect data number, that is, a value other than 0 is specified.
4: The fine torque sensing data in ’Data Attribute’ has wrong values,
that is, a value other than 0 or 1.
6: The fine torque sensing option has not been added on.

/
om
[Output data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
232

re
+1 +16 (Completion code)

(See the explanation above.)

+2

+3
+32

+48
pa
(Data length in bytes)
4
cs
(Data number)
0
(Entered data)
.cn

+4 +64
(Data attribute)
M
(Entered data)
Value
+5 +80
Unsigned binary
w

Store counter value


w

+7 +112
w
://
tp
ht

- 444 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

(2) Stored torque data (latest data)

[Description]
This function reads the latest stored data among stored torque data.

/
[Input data structure]

om
WORD BOOL
type type
offset offset

Top address +0 +0

s.c
(Function code)
232

+1 +16
(Completion code)

re
(Need not be set)

+2 +32
(Data length in bytes)

+3 +48 pa

(Need not be set)

(Data number)

N : Number of axis to be read + 100
cs
(N= Axis number + 10)
+4 +64
(Data attribute)
M= 0 : Latest data counter
.cn

M = 1 : Sample data counter


(M=Data type)

+5 +80
(Data area)

(Need not be set)
w
w

[Completion codes]
0: The stored torque data (latest data) was read successfully.
3: Incorrect data number, that is, a value other than 11 to (10+n) (n:
w

number of spindles) is specified.


4: The fine torque sensing data in ’Data Attribute’ has a wrong value,
that is, a value other than 0 or 1.
://

6: The fine torque sensing option has not been added on.
tp
ht

- 445 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]


WORD BOOL
type type
offset offset

Top address +0 +0

/
(Function code)

om
232

+1 +16
(Completion code)

(See the explanation above.)

+32

s.c
+2
(Data length in bytes)
L
(L=2 or 0)
+3 +48
(Data number)

re
N
(Entered data)

+4 +64
(Data attribute)

+5 +80
M

pa
(Entered data) Value
cs
Latest stored data Signed binary

+6 +96
.cn

NOTE
1 When data has not been stored, data is not output
and processing ends successfully with L set to 0.
w

2 When sample data is selected by data attribute, the


sample data corresponding to the latest stored data
is output.
w

Example) When 10000 sample data items (data


numbers 0 to 9999) and latest data items
5000 (data numbers 0 to 4999) are
w

stored, data number 4999 in the latest


data is output when data attribute M is set
://

to "0", and data number 4999 in the


sample data is output when data attribute
M is set to "1".
tp

3 When sample data is selected by data attribute, and


there is no sample data corresponding to the latest
stored data, data is not output, and processing ends
ht

successfully with L set to 0.


Example) When 5000 sample data items (data
numbers 0 to 4999) and 10000 latest data
items (data numbers 0 to 9999) are
stored, data is not output, and processing
ends successfully with L set to 0 when
data attribute M is set to "1".

- 446 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

(3) Stored torque data (any data)

[Description]
This function reads the arbitrary data among stored torque data.

/
[Input data structure]

om
WORD BOOL
type type
offset offset

Top address +0 +0

s.c
(Function code)
232

+1 +16 (Completion code)


?

re
(Need not be set)

+2 +32
(Data length in bytes)
6

+3 +48
pa
(Data number)

(N= Axis number)
N=1 to n: Axis number
(n is the spindle number.)
cs
+64 )
+4 (Data attribute)
M M =0 : Latest data
(M=Data type) =1 : Sample data
.cn

+5 +80 Data number


n
(Entered data)
+7 +112 Number of data items
I
(Entered data)
w

+8 +128
Data of number n
w

+9 +144
Data of number n+1


w

+10 +160
://

NOTE
The valid range of data number n is calculated as
follows:
tp

1
0 ≤ n ≤ (524288 × 1a × b ) −1
where,
1: Number of target axes 1
ht

a= 2: Number of target axes 2


4: Number of target axes 3 and 4
b = 1: Sample data store function OFF
2: Sample data store function ON
The valid range of number of data items I is
calculated as follows:
1 ≤ I ≤ 20
- 447 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The stored torque data (any data) was read successfully.
2: Incorrect data length, that is, a value other than 6 is specified.
3: Incorrect data number, that is, a value other than 11 to (10+n) (n:
number of spindles) is specified.

/
4: The fine torque sensing data in ’Data Attribute’ has a wrong value,

om
that is, a value other than 0 or 1.
5: Incorrect data area is specified. See Note for details of value
ranges.
6: The fine torque sensing option has not been added on.

s.c
[Output data structure]
WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
232

+1 +16
pa
(Completion code)

(See the explanation above.)
cs
+2 +32
(Data length in bytes)
L
(L=6 + number of data items I × 2)
.cn

+3 +48
(Data number)
N
(Entered data)

+4 +64
w

(Data attribute)
M
(Entered data) Value
+5 +80
w

Data number Signed binary


n
(Entered data)
w

+7 +112
Number of data items
I
(Entered data)
://

+8 +128
Distribution of target axes
tp

+9 +144 Number n data


+10 +160 Number n+1 data
ht

+11 +176 Number n+2 data


+12 +192 :


Number n+I‐1 data

- 448 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

NOTE
1 When the number of actually stored data items is
exceeded even though data number n is in the valid
range, data is not output and processing ends
successfully by number of data items I set to 0.

/
Example) When the number of target axes is 2, and

om
the sample data store function is enabled
(parameter No.6350#2=1), data numbers 0
to 131071 are valid. However, if an attempt
is made to read (example (1) in figure
below) data from data number n = 131020

s.c
when the number of actually stored data
items is 131000 (data numbers 0 to
130999), data is not output, and the

re
number of data items I becomes 0.
2 When data number n is within the number of actually
stored data items, and (n+I-1) exceeds the number

pa
of actually stored data items, data of the stored data
items is output, and processing ends successfully. In
this case, number of data items I is updated to the
cs
number of data items that was output.
Example) If an attempt is made to read (example (2)
in figure below) number of data items I
.cn

(120) from data number 130900 under the


same conditions as in the example above,
the data of data numbers 130900 to
130999 is output, and number of data
items I becomes 100. Also, if an attempt is
w

made to read (example (3) in figure below)


number of data items I (120) from data
w

number 130999 under the same conditions


as in the example above, the data of data
numbers 130990 to 130999 is output, and
w

number of data items becomes 10.


://

Data Number Valid Range


tp

Range of actually stored data

Data range about to be read (1)


ht

Data range about to be read (2)


Data range about to be read (1)

- 449 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.5.18 Presetting the Relative Coordinate (Low-speed Response)

[Description]
The preset data is set to the relative coordinate controlled by CNC.
If 0 is set as preset data it becomes to origin.

/
But it is impossible to write the value of preset data to the transferring

om
axis. In the case of the preset of relative coordinate of all axes is
executed by using this function, if only one axis is transferring, the
preset of relative coordinate cannot be executed, neither.

[Input data structure]

s.c
Case of writing data on each axis.

WORD BOOL

re
type type
offset offset

Top address +0 +0

+1 +16
pa
(Function code)
249

(Completion code)
cs

(Need not be set.)

+2 +32
.cn

(Data length in bytes)


4

+3 +48
(Data number)
0
Value
w

+4 +64
M=1 to n: Write data on each (n
(Data attribute) is the axis number)
M
w

(M: Axis number)


+5 +80
Value of relative coordinate for the Signed binary
controlled axis specified (4 bytes) (A negative value is represented in
w

2's complement)
+6 +96
://

[Input data unit]


tp

Increment system
Input system
IS-B IS-C
mm, deg 0.001 0.0001
Machining center system
ht

inch 0.0001 0.00001


Radius specification 0.001 0.0001
mm, deg
Lathe Diameter specification 0.001 0.0001
system Radius specification 0.0001 0.00001
inch
Diameter specification 0.0001 0.00001

- 450 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

Case of writing data on all axes (controlled axes are 4).

WORD BOOL
type type
offset offset

/
Top address +0 +0

om
(Function code)
249

+1 +16
(Completion code)

(Need not be set.)

s.c
+2 +32
(Data length in bytes)
16

+3 +48

re
(Data number)
0
Value
+4

+5
+64

+80
M
(M = −1)pa
(Data attribute)
−1 must be set

Signed binary
cs
Value of relative coordinate for the (A negative value is represented in
first axis (4 bytes) 2's complement)

+7 +112
.cn

Value of relative coordinate for the


second axis (4 bytes)

+9 +144
Value of relative coordinate for
the third axis (4 bytes)
w

+11 +176
Value of relative coordinate for the
w

fourth axis (4 bytes)


w
://
tp
ht

- 451 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the value of relative coordinate.
4: Data specified for the data attribute is invalid because it is neither
−1 nor a value from 1 to n (n is the number of axes).
Alternatively, the specified axis number is greater than the

/
number of controlled axes.

om
5: Relative coordinate is out of range.
13: Axis is moving now.

[Output data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
249

+1 +16

+2 +32
pa
(Completion code)
?
(See the explanation above)

(Data length in bytes)


cs
L
(Same as input data)

+3 +48
(Data number)
.cn

0
(Same as input data)

+4 +64
(Data attribute)
M
(M: Input data)
w

+5 +80
Value of relative coordinate
w

(4*n bytes)
w
://
tp
ht

- 452 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6 TOOL LIFE MANAGEMENT FUNCTION

A.6.1 Reading The Tool Life Management Data (Tool Group


Number) (High-speed Response)

/
om
[Description]
By specifying a tool number, the number of the tool group to which
the specified tool belongs can be read from tool life management data.

s.c
[Input data structure]

WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
38

+1 +16
pa (Completion code)

(Need not be set)
cs
+2 +32
(Data length in bytes)

(Need not be set)
.cn

+3 +48
(Data number)
0

+4 +64
w

(Data attribute)
M
(M: Tool No.)

+80
w

+5
(Data area)

(Need not be set)
w

≈ ≈
://
tp

CAUTION
If 0 is specified for the tool No., the number of the
ht

tool group currently used is read. In this case, if a


tool group number has not been specified since the
power to the CNC was turned on, 0 is output.
If the same tool belongs to two or more tool groups,
the number of all tool groups to which the tool
belongs are displayed.

- 453 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool group number has been read normally.
4: The value specified for the data attribute is invalid.
5: The specified tool number was not found.
6: The tool life management option has not been added.

/
om
[Output data structure]
WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
38

+1 +16 (Completion code)


?

re
(See the explanation of
the completion codes.)

+2 +32
(Data length in bytes)

+3 +48
L
(L = 4 × n)

(Data number)
pa L = 4 to 4 × n
n is the number of tool groups to
which the specified tool belongs.
cs

+4 +64
(Data attribute)
.cn

M
(M: Input data) Value
+5 +80
Tool group No. (4 bytes) Unsigned binary

+7 +112
w

When the specified tool belongs to two or more tool groups

+5 +80
Unsigned binary
w

Tool group No. (4 bytes)

+7 +112
Tool group No. (4 bytes)
w

+9 +144
Tool group No. (4 bytes)
://

+11 +176
tp

NOTE
1 This cannot be used with those models that do not
have the tool life management function.
ht

2 Tool life management data is not applied to the T


mode of the compound machining function.

- 454 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.2 Reading Tool Life Management Data (Number of Tool Groups)


(High-speed Response)

[Description]
The number of tool groups in tool life management data can be read.

/
The number of tool groups that can be registered varies depending on

om
the setting of parameter 6800 of the CNC, as indicated in the
following table.

Parameter 6800

s.c
Number of tool groups
The numbers in parentheses apply when the additional
GS2 GS1
option is used
M series T series

re
0 0 1 to 16 (1 to 64) 1 to 16 (1 to 16)
0 1 1 to 32 (1 to 128) 1 to 32 (1 to 32)
1 0 1 to 64 (1 to 256) 1 to 64 (1 to 64)
1 1

[Input data structure]


pa
1 to 128 (1 to 512)
M series: For Machining Centers
1 to 16 (1 to 128)
T series: For Lathes
cs
WORD BOOL
type type
offset offset
.cn

Top address +0 +0
(Function code)
39
w

+1 +16
(Completion code)

(Need not be set)
w

+2 +32
(Data length in bytes)

w

(Need not be set)

+3 +48
(Data number)
://

+4 +64
(Data attribute)
tp

+5 +80
(Data area)

ht

(Need not be set)

≈ ≈

- 455 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The number of tool group numbers has been read successfully.
6: The tool life management option has not been added.

[Output data structure]

/
om
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)
39

s.c
+1 +16
(Completion code)
?
(See the explanation of
the completion codes.)

re
+2 +32
(Data length in bytes)
4

+3 +48
pa
(Data number)

cs
+4 +64
(Data attribute)

Value
.cn

+5 +80
Number of tool groups (4 bytes) Unsigned binary
w

NOTE
1 This cannot be used with those models that do not
w

have the tool life management function.


2 Tool life management data is not applied to the T
mode of the compound machining function.
w
://
tp
ht

- 456 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.3 Reading Tool Life Management Data (Number of Tools)


(High-speed Response)

[Description]
By specifying a tool group number, the number of tools that belong to

/
the tool group can be read from tool life management data.

om
The number of tools that can be registered varies depending on the
setting of parameter 6800 of the CNC, as indicated in the following
table.

Parameter 6800

s.c
Number of tools
The numbers in parentheses apply when the additional
GS2 GS1
option is used

re
M series T series
0 0 1 to 16 (1 to 32) 1 to 16 (1 to 32)
0 1 1 to 8 (1 to 16) 1 to 8 (1 to 16)
1
1
0
1
pa 1 to 4 (1 to 8)
1 to 2 (1 to 4)
M series: For Machining Centers
1 to 4 (1 to 8)
1 to 16 (1 to 4)
T series: For Lathes
cs
[Input data structure]

WORD BOOL
.cn

type type
offset offset

Top address +0 +0
(Function code)
40
w

+1 +16
(Completion code)

w

(Need not be set)

+2 +32
(Data length in bytes)
w


(Need not be set)

+3 +48
://

(Data number)
N
(N: Tool group number)

+4 +64
tp

(Data attribute)
0

+80
ht

+5 (Data area)

(Need not be set)

≈ ≈

- 457 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

CAUTION
If 0 is specified for the tool group number, the
number of tools that belong to the tool group
currently used is read. In this case, if a tool group
number has not been specified since the power to

/
the CNC was turned on, 0 is output.

om
[Completion codes]
0: The number of tools has been read normally.
3: The specified tool group number is invalid.

s.c
6: The tool life management option has not been added.

[Output data structure]

re
WORD BOOL
type type
offset offset

Top address +0 +0

pa
(Function code)
40
cs
+1 +16 (Completion code)
?
(See the explanation of
the completion codes.)
.cn

+2 +32
(Data length in bytes)
4

+3 +48
(Data number)
N
w

(N: Input data)

+4 +64
w

(Data attribute)

Value
+5 +80
Number of tools (4 bytes) Unsigned binary
w
://

NOTE
1 This cannot be used with those models that do not
tp

have the tool life management function.


2 Tool life management data is not applied to the T
ht

mode of the compound machining function.

- 458 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.4 Reading Tool Life Management Data (Tool Life) (High-speed


Response)

[Description]
By specifying a tool group number, the life of tools belonging to the

/
tool group can be read from tool life management data.

om
Whether to display the tool life in minutes or the number of cycles is
selected by bit 2 of parameter 6800 (LTM) for the CNC.

[Input data structure]

s.c
WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
41

+1 +16
pa (Completion code)

(Need not be set)
cs
+2 +32
(Data length in bytes)

(Need not be set)
.cn

+3 +48
(Data number)
N
(N: Tool group number)

+4 +64
w

(Data attribute)
0
w

+5 +80
(Data area)

(Need not be set)
w

≈ ≈
://
tp

CAUTION
If 0 is specified for the tool group number, the tool
ht

life of the tool group currently used is read. In this


case, if a tool group number has not been specified
since the power to the CNC was turned on, 0 is
output.

- 459 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool life has been read normally.
3: The specified tool group number is invalid.
6: The tool life management option has not been added.

/
[Output data structure]

om
WORD BOOL
type type
offset offset

Top address +0 +0

s.c
(Function code)
41

+1 +16
(Completion code)
?

re
(See the explanation of
the completion codes.)
+2 +32
(Data length in bytes)

+3 +48
4

pa
(Data number)
N
cs
(N: Input data)

+4 +64
(Data attribute)
.cn


Value
+5 +80 Unsigned binary
Tool life (4 bytes)
Unit: Time (minutes) or
number of cycles
w

NOTE
w

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
w

mode of the compound machining function.


And compound machining function is not applied to
the function of tool life management data B.
://
tp
ht

- 460 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.5 Reading Tool Life Management Data (Tool Life Counter)


(High-speed Response)

[Description]
By specifying a tool group number, the tool life counter for the

/
specified tool group can be read from tool life management data.

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
42

re
+1 +16
(Completion code)

+2 +32 pa (Need not be set)

(Data length in bytes)



(Need not be set)
cs
+3 +48
(Data number)
N
(N: Tool group number)
.cn

+4 +64
(Data attribute)
0

+80
w

+5
(Data area)

(Need not be set)
w

≈ ≈
w
://

CAUTION
If 0 is specified for the tool group number, the tool
tp

life counter for the tool group currently used is read.


In this case, if a tool group number has not been
specified since the power to the CNC was turned on,
ht

0 is output.

- 461 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool life has been read normally.
3: The specified tool group number is invalid.
6: The tool life management option has not been added.

/
[Output data structure]

om
WORD BOOL
type type
offset offset

Top address +0 +0

s.c
(Function code)
42

+1 +16 (Completion code)


?

re
(See the explanation of
the completion codes.)
+2 +32

+3 +48
(Data number)
N
pa
(Data length in bytes)
4
cs
(N: Input data)

+4 +64
(Data attribute)
.cn


Value
+5 +80 Unsigned binary
Tool life counter (4 bytes)
Unit: Time (minutes) or
number of cycles
w

NOTE
w

1 This cannot be used with those models that do not


have the tool life management function.
w

2 Tool life management data is not applied to the T


mode of the compound machining function.
And compound machining function is not applied to
://

the function of tool life management data B.


tp
ht

- 462 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.6 Reading Tool Life Management Data (Tool Length


Compensation Number (1): Tool Number) (High-speed
Response)

[Description]

/
By specifying a tool group number and a tool No., the tool length

om
compensation number for the specified tool can be read from tool life
management data. This function is available only with the M series
CNCs.

s.c
[Input data structure]

WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
43

+1 +16
pa (Completion code)

(Need not be set)
cs
+2 +32
(Data length in bytes)

(Need not be set)
.cn

+3 +48
(Data number)
N
(N: Tool group number)

+4 +64
w

(Data attribute)
M
(M: Tool number)
w

+5 +80
(Data area)

(Need not be set)
w

≈ ≈
://
tp

CAUTION
If 0 is specified for both the tool group number and
ht

tool number, the numbers of the tool group and tool


currently used are read. In this case, if a tool group
number has not been specified since the power to
the CNC was turned on, 0 is output.
For the T series CNCs, 0 is always output.

- 463 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool length compensation number has been read normally.
3: The specified tool group number is invalid.
4: The specified tool number is invalid.
5: The specified tool number was not found in the specified tool

/
group.

om
6: The tool life management option has not been added.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
43

re
+1 +16 (Completion code)
?
(See the explanation of

+2 +32 pa
the completion codes.)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
(N: Input data)
.cn

+4 +64
(Data attribute)
M
(M: Input data) Value
w

+5 +80
Tool length compensation number Unsigned binary
(4 bytes)
w

NOTE
w

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
://

mode of the compound machining function.


tp
ht

- 464 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.7 Reading Tool Life Management Data (Tool Length


Compensation Number (2): Tool Order Number) (High-speed
Response)

[Description]

/
By specifying a tool group number and tool order number, the tool

om
length compensation number for the specified tool can be read from
tool life management data. This function is available only with the M
series CNCs.

s.c
[Input data structure]
WORD BOOL
type type
offset offset

re
Top address +0 +0

(Function code)
44

+1 +16
pa
(Completion code)

(Need not be set)
cs
+2 +32
(Data length in bytes)

(Need not be set)
.cn

+3 +48
(Data number)
N
(N: Tool group number)

+4 +64
(Data attribute)
w

M
(M: Tool order number)

+5 +80
w

(Data area)

(Need not be set)
≈ ≈
w
://

CAUTION
If 0 is specified for the tool group number, the
tp

number of the tool group currently used is read. In


this case, if a tool group number has not been
ht

specified since the power to the CNC was turned on,


0 is output.
When 0 is specified for the tool order number, if the
specified tool group has been used, the tool
currently used is read. In this case, if the specified
tool group has not been used, the first tool in the
group is read.
For the T series CNCs, 0 is always output.
- 465 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool length compensation number has been read normally.
3: The specified tool group number is invalid.
4: The specified tool order is invalid.
5: The tool having the specified tool order is not registered in the

/
specified tool group.

om
6: The tool life management option has not been added.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
44

re
+1 +16 (Completion code)
?
(See the explanation of

+2 +32 pa
the completion codes.)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
(N: Input data)
.cn

+4 +64
(Data attribute)
M
(M: Input data)
Value
+5 +80
w

Tool length compensation number Unsigned binary


(4 bytes)
w

NOTE
1 This cannot be used with those models that do not
w

have the tool life management function.


2 Tool life management data is not applied to the T
://

mode of the compound machining function.


tp
ht

- 466 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.8 Reading Tool Life Management Data (Cutter Radius


Compensation Number (1): Tool Number) (High-speed
Response)

[Description]

/
By specifying a tool group number and a tool number, the cutter

om
compensation number for the specified tool can be read from tool life
management data. This function is available only with the M series
CNCs.

s.c
[Input data structure]

WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)

+1 +16 pa 45

(Completion code)

(Need not be set)
cs
+2 +32
(Data length in bytes)

(Need not be set)
.cn

+3 +48
(Data number)
N
(N: Tool group number)
w

+4 +64
(Data attribute)
M
(M : Tool number)
w

+5 +80
(Data area)

(Need not be set)
w

≈ ≈
://
tp

CAUTION
If 0 is specified for both tool group number and tool
number, the numbers of the tool group and tool
ht

currently used are read. If a tool group number has


not been specified since the power to the CNC was
turned on, 0 is output.
For the T series CNCs, 0 is always read.

- 467 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The cutter compensation number has been read normally.
3: The specified tool group number is invalid.
4: The specified tool number is invalid.
5: The specified tool number was not found in the specified tool

/
group.

om
6: The tool life management option has not been added.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
45

re
+1 +16 (Completion code)
?
(See the explanation of

+2 +32 pa
the completion codes.)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
(N: Input data)
.cn

+4 +64
(Data attribute)
M
(M: Input data)
Value
+5 +80
w

Cutter compensation number Unsigned binary


(4 bytes)
w

NOTE
1 This cannot be used with those models that do not
w

have the tool life management function.


2 Tool life management data is not applied to the T
://

mode of the compound machining function.


tp
ht

- 468 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.9 Reading Tool Life Management Data (Cutter Radius


Compensation Number (2): Tool Order Number) (High-speed
Response)

[Description]

/
By specifying a tool group number and a tool order number, the cutter

om
compensation number for the specified tool can be read from tool life
management data. This function is available only with the M series
CNCs.

s.c
[Input data structure]
WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
46

+1 +16
pa (Completion code)

(Need not be set)
cs
+2 +32
(Data length in bytes)

(Need not be set)
.cn

+3 +48
(Data number)
N
(N: Tool group number)

+4 +64
(Data attribute)
w

M
(M: Tool order number)

+5 +80
w

(Data area)

(Need not be set)
≈ ≈
w
://

CAUTION
If 0 is specified for the tool group number, the
tp

number of the tool group currently used is


referenced. In this case, if a tool group number has
not been specified since the power to the CNC was
ht

turned on, 0 is output.


When 0 is specified for the tool order number, if the
specified tool group has been used, the tool
currently used is read. In this case, if the specified
tool group has not been used, the first tool in the
group is referred to.
For the T series CNCs, 0 is always output.

- 469 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The cutter compensation number has been read normally.
3: The specified tool group number is invalid.
4: The specified tool order number is invalid.
5: The tool having the specified tool order is not registered in the

/
specified tool group.

om
6: The tool life management option has not been added.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)

re
46

+1 +16 (Completion code)


?

+2 +32 pa
(See the explanation of
the completion codes.)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
.cn

(N: Input data)

+4 +64
(Data attribute)
M
(M: Input data) Value
w

+5 +80
Cutter compensation number Unsigned binary
(4 bytes)
w

NOTE
1 This cannot be used with those models that do not
w

have the tool life management function.


2 Tool life management data is not applied to the T
://

mode of the compound machining function.


tp
ht

- 470 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.10 Reading Tool Life Management Data (Tool Information (1):


Tool Number) (High-speed Response)

[Description]
By specifying a tool group number and a tool number, the information

/
for the specified tool can be read from tool life management data.

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)

re
47

+1 +16
(Completion code)

+2 +32 pa (Need not be set)

(Data length in bytes)



(Need not be set)
cs
+3 +48
(Data number)
N
(N: Tool group number)
.cn

+4 +64
(Data attribute)
M
(M: Tool number)
w

+5 +80
(Data area)

(Need not be set)
≈ ≈
w
w
://

CAUTION
If “0” is specified for both tool group number and tool
number, the numbers of the tool group and tool
tp

currently used are referenced.


If neither a tool group number nor a tool number has
been specified since the power to the CNC was
ht

turned on, “0” is output.

- 471 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool status information has been read normally.
3: The specified tool group number is invalid.
4: The specified tool number is invalid.
5: The specified tool number was not found in the specified tool

/
group.

om
6: The tool life management option has not been added.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
47

re
+1 +16 (Completion code)
?
(See the explanation of

+2 +32 pa
the completion codes.)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
(N: Input data)
.cn

+4 +64
(Data attribute)
M
(M: Input data) Value
+80
w

+5
Tool status information (4 bytes) 0: See "CAUTION" on the previous page.
1: The tool is registered.
2: The tool has reached the end of its life.
3: The tool was skipped.
w

The three high-order bytes are fixed to 0.


w

NOTE
1 This cannot be used with those models that do not
://

have the tool life management function.


2 Tool life management data is not applied to the T
mode of the compound machining function.
tp
ht

- 472 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.11 Reading Tool Life Management Data (Tool Information (2):


Tool Order Number) (High-speed Response)

[Description]
By specifying a tool group number and a tool order number, the

/
information for the specified tool can be read from tool life

om
management data.

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)

re
48

+1 +16
(Completion code)

+2 +32
pa −
(Need not be set)

(Data length in bytes)



cs
(Need not be set)

+3 +48
(Data number)
N
.cn

(N: Tool group number)

+4 +64
(Data attribute)
M
(M: Tool order number)
w

+5 +80
(Data area)

(Need not be set)
w

≈ ≈
w
://

CAUTION
If "0" is specified for the tool group number, the
tp

number of the tool group currently used is read. If a


tool group number has not been specified since the
power to the CNC was turned on, "0" is output.
ht

When "0" is specified for the tool order number, if


the specified tool group has ever been used, the tool
currently used is read. In this case, if the specified
tool group has not been used, the first tool in the
group is referred to.

- 473 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool status information has been read normally.
3: The specified tool group number is invalid.
4: The specified tool order number is invalid.
5: The tool having the specified tool order is not registered in the

/
specified tool group.

om
6: The tool life management option has not been added.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
48

re
+1 +16 (Completion code)
?
(See the explanation of

+2 +32
the completion codes.)

(Data length in bytes)


4
pa
cs
+3 +48
(Data number)
N
(N: Input data)
.cn

+4 +64
(Data attribute)
M
(M: Input data) Value
w

+5 +80
Tool status information (4 bytes) 0: See "Caution" on the previous page.
1: The tool is registered.
2: The tool has reached the end of its life.
3: The tool was skipped.
w

The three high-order bytes are fixed to 0.


w

NOTE
1 This cannot be used with those models that do not
://

have the tool life management function.


2 Tool life management data is not applied to the T
mode of the compound machining function.
tp
ht

- 474 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.12 Reading Tool Life Management Data (Tool Number)


(High-speed Response)

[Description]
By specifying a tool group number and a tool order number, the

/
number of the corresponding tool can be read from tool life

om
management data.

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
49

+1 +16
(Completion code)

+2 +32
pa −
(Need not be set)

(Data length in bytes)



cs
(Need not be set)

+3 +48
(Data number)
N
.cn

(N: Tool group number)

+4 +64
(Data attribute)
M
(M: Tool order number)
w

+5 +80
(Data area)

(Need not be set)
w

≈ ≈
w
://

CAUTION
When "0" is specified for the tool group number, the
tool group currently used is referenced. If neither a
tp

tool group number or a tool number has been


specified since the power to the CNC was turned on,
ht

however, "0" is output for the tool group number.


When "0" is specified for the tool order number, if
the specified tool group has been used, the tool
currently used is referred to. If the specified tool
group has not been used, the first tool in the group
is referenced.

- 475 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool number has been read normally.
3: The specified tool group number is invalid.
4: The specified tool order number is invalid.
6: The tool life management option has not been added.

/
om
[Output data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
49

+1 +16 (Completion code)

re
?
(See the explanation of
the completion codes.)
+2 +32

+3 +48
4 pa
(Data length in bytes)
cs
(Data number)
N
(N: Input data)

+4 +64
.cn

(Data attribute)
M
(M: Input data) Value
+5 +80
Tool number (4 bytes) Unsigned binary
w

NOTE
w

1 This cannot be used with those models that do not


have the tool life management function.
w

2 Tool life management data is not applied to the T


mode of the compound machining function.
://
tp
ht

- 476 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.13 Reading the Tool Life Management Data (Tool Life Counter
Type) (High-speed Response)

[Description]
This function gets the Tool life counter type of specified tool group in

/
the Tool life management data. (M series only)

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
160

re
+1 +16
(Completion code)

(Need not be set)

+2 +32
pa
(Data length in bytes)

(Need not be set)
cs
+3 +48
(Data number)
N
(N : Tool group number)
.cn

+4 +64
(Data attribute)
0

+5 +80
w

(Data area)

(Need not be set)
w

CAUTION
w

About Tool group number (in ’Data number’):


"0" as Tool group number indicates the Tool group
://

currently used.
When Tool group has never specified since power‐
on, "0" of Tool group number results "0" as counter
tp

type.
"0" of counter type will be returned on T series.
ht

- 477 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to read the Tool life counter type.
3: The Tool group number is out of range from 0 to 512, or exceeds
the maximum number of registered Tool group.
6: No option for Tool life management.

/
om
[Output data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
160

+1 +16

re
(Completion code)
?
(See the explanation above)

+2 +32

+3 +48
pa
(Data length in bytes)
2

(Data number)
cs
N
(Same as input data)

+4 +64
(Data attribute)
.cn


(Same as input data)
Value
+5 +80
Tool life counter type (2 bytes) 0 : No counter type
1 : Frequency
2 : Real time (in minute)
w
w

NOTE
1 This cannot be used with those models that do not
have the tool life management function.
w

2 Tool life management data is not applied to the T


mode of the compound machining function.
://
tp
ht

- 478 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.14 Registering Tool Life Management Data (Tool Group)


(Low-speed Response)

[Description]
This function registers the Tool group in Tool life management data,

/
with Tool number, length of life and Tool life counter type. On T

om
series, the Tool life counter type will be specified by the NC
parameter "LTM" (No.6800#2), and this function cannot set/change
the counter type.

[Input data structure]

s.c
WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
163

+1 +16
(Completion code)

(Need not be set)
pa
cs
+2 +32
(Data length in bytes)
8
+3 +48
.cn

(Data number)
0

+4 +64
(Data attribute)
M
(M = Tool number)
w

Value
+5 +80
Tool group number Unsigned binary
(2 bytes) 1–512
w

+6 +96
Tool life counter type 1: Frequency
(2 bytes) 2: Real time in minutes
w

+7 +112 Unsigned binary


Tool life (4 bytes)
1–9999 (Frequency)
1–4300 (Real time in minutes: 1count/4s) Note
1–1090 (Real time in minutes: 1count/1s) Note
://
tp

NOTE
The tool life count is changed by parameter
6801#5.
ht

6801#5 = 0: the life is counted every 4seconds.


6801#5 = 1: the life is counted every 1second.

- 479 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to register the tool group.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered Tool group.
4: The tool number in 'Data attribute' has wrong value.

/
5: The length of tool life in 'Data area' is out of range. The tool life

om
counter type does not match on T series.
6: No option for the tool life management.

[Output data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
163

+1 +16

+2 +32
pa (Completion code)
?
(See the explanation above)

(Data length in bytes)


cs
8
(Same as input data)

+3 +48
(Data number)
.cn


(Same as input data)

+4 +64
(Data attribute)
M
(Same as input data)
w

+5 +80
Tool group number (2 bytes)
(Same as input data)
w

+6 +96
Tool life counter type (2 bytes)
(Same as input data)
w

+7 +112
Tool life (4 bytes)
://

(Same as input data)


tp

NOTE
1 This cannot be used with those models that do not
ht

have the tool life management function.


2 Tool life management data is not applied to the T
mode of the compound machining function.

- 480 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.15 Writing Tool Life Management Data (Tool Life)


(Low-speed Response)

[Description]
This function sets the length of tool life of the specified tool group in

/
the tool life management data.

om
[Input data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
164

re
+1 +16
(Completion code)

+2 +32 pa
(Need not be set)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
(N = Tool group number)
.cn

+4 +64
(Data attribute)
0
Value
+80
w

+5 Unsigned binary
1–9999 (Frequency)
1–4300 (Real time minutes: 1count/4s) Note
Tool life (4 bytes) 1–1090 (Real time minutes: 1count/1s) Note
w

Case of the tool life management data B


1–999999 (Frequency)
1–100000 (Real time in minutes)
w

NOTE
://

The tool life count is changed by parameter


6801#5.
6801#5 = 0: the life is counted every 4seconds.
tp

6801#5 = 1: the life is counted every 1second.


ht

- 481 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the length of tool life.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered tool group.
5: The length of tool life is out of range.

/
6: No option for the tool life management.

om
13: The data of the currently selected tool group or the next tool
group cannot be rewritten. An attempt was made to rewrite the
data of the currently selected tool group or the next group.

[Output data structure]

s.c
WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
164

+1 +16
pa
(Completion code)
?
(See the explanation above)
cs
+2 +32
(Data length in bytes)
4
(Same as input data)
.cn

+3 +48
(Data number)
N
(Same as input data)

+4 +64
(Data attribute)

w

(Same as input data)

+5 +80 Length of Tool life (4 bytes)


w
w

NOTE
://

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
tp

mode of the compound machining function.


And compound machining function is not applied to
the function of tool life management data B.
ht

- 482 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.16 Writing Tool Life Management Data (Tool Life Counter)


(Low-speed Response)

[Description]
This function sets the tool life counter in the specified tool group in

/
the tool life management data.

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
165

re
+1 +16
(Completion code)

+2 +32
pa
(Need not be set)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
(N = Tool group number)
.cn

+4 +64
(Data attribute)
0
Value
+5 +80 Unsigned binary
w

Tool life counter (4 bytes)


1–9999 (Frequency)
1–4300 (Real time minutes: 1count/4s) Note
1–1090 (Real time minutes: 1count/1s) Note
Case of the tool life management data B
w

1–999999 (Frequency)
1–100000 (Real time in minutes)
w

NOTE
://

The tool life count is changed by parameter


6801#5.
6801#5 = 0: the life is counted every 4seconds.
tp

6801#5 = 1: the life is counted every 1second.


ht

- 483 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the tool life counter.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered tool group.
5: The value for tool life counter is out of range.

/
6: No option for the tool life management.

om
[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)

re
165

+1 +16
(Completion code)

+2 +32 pa ?
(See the explanation above)

(Data length in bytes)


4
cs
(Same as input data)

+3 +48
(Data number)
N
.cn

(Same as input data)

+4 +64
(Data attribute)

(Same as input data)
w

+5 +80
Tool life counter(4 bytes)
w
w

NOTE
1 This cannot be used with those models that do not
have the tool life management function.
://

2 Tool life management data is not applied to the T


mode of the compound machining function.
tp

And compound machining function is not applied to


the function of tool life management data B.
ht

- 484 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.17 Writing Tool Life Management Data (Tool Life Counter Type)
(Low-speed Response)

[Description]
This function sets the tool life counter type of specified tool group in

/
the tool life management data. (M series only)

om
[Input data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
166

re
+1 +16
(Completion code)

+2 +32 pa
(Need not be set)

(Data length in bytes)


cs
2

+3 +48
(Data number)
N
.cn

(N = Tool group number)

+4 +64
(Data attribute)
0
Value
w

+5 +80
Tool life counter type (2 bytes) 1: Frequency
2: Real time in minutes
w
w
://
tp
ht

- 485 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the tool life counter type.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered tool group.
5: The value for tool life counter type is wrong.

/
6: No option for the tool life management.

om
[Output data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
166

re
+1 +16
(Completion code)
?
(See the explanation above)

+2 +32
pa (Data length in bytes)
2
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+4 +64
(Data attribute)

(Same as input data)

+5 +80
Tool life counter type (2 bytes)
w
w

NOTE
w

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
://

mode of the compound machining function.


tp
ht

- 486 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.18 Writing Tool Life Management Data (Tool Length


Compensation Number (1): Tool Number)
(Low-speed Response)

[Description]

/
This function sets the tool length compensation number of the

om
specified tool group in the tool life management data. (M series only)

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
167

+1 +16

+2 +32
pa
(Completion code)

(Need not be set)
cs
(Data length in bytes)
4

+3 +48
(Data number)
.cn

N
(N = Tool group number)

+4 +64
(Data attribute)
M
(M = Tool number)
w

Value
+5 +80
Tool length compensation number Unsigned binary
(4 bytes) 1-255
w
w
://
tp
ht

- 487 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the tool length compensation number.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered tool group.
4: The tool number in 'Data attribute' has wrong value.

/
5: The tool number is not found in the tool group.

om
6: No option for the tool life management.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
167

re
+1 +16
(Completion code)
?

+2 +32 pa
(See the explanation above)

(Data length in bytes)


4
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+4 +64
(Data attribute)
M
(Same as input data)

+5 +80
w

Tool length compensation number


(4 bytes)
w
w

CAUTION
The effective value for tool length compensation
number depends on tool compensation number
://

available on CNC.

NOTE
tp

1 This cannot be used with those models that do not


have the tool life management function.
ht

2 Tool life management data is not applied to the T


mode of the compound machining function.

- 488 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.19 Writing Tool Life Management Data (Tool Length


Compensation Number (2): Tool Order Number)
(Low-speed Response)

[Description]

/
This function sets the tool length compensation number of the tool of

om
the specified tool order number in the tool life management data. (M
series only)

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
168

+1

+2
+16

+32

pa
(Completion code)
(Need not be set)
cs
(Data length in bytes)
4

+3 +48
.cn

(Data number)
N
(N = Tool group number)

+4 +64
(Data attribute)
M
w

(M = Tool order number)


Value
+5 +80
Tool length compensation number Unsigned binary
1-255
w

(4 bytes)
w
://
tp
ht

- 489 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the tool length compensation number.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered tool group.
4: The tool order number is wrong.

/
6: No option for the tool life management.

om
[Output data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
168

re
+1 +16
(Completion code)
?
(See the explanation above)

+2 +32
pa (Data length in bytes)
4
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+4 +64
(Data attribute)
M
(Same as input data)

+5 +80
Tool length compensation number
(4 bytes)
w
w

CAUTION
w

The effective value for tool length compensation


number depends on tool compensation number
available on CNC.
://

NOTE
1 This cannot be used with those models that do not
tp

have the tool life management function.


2 Tool life management data is not applied to the T
ht

mode of the compound machining function.

- 490 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.20 Writing Tool Life Management Data (Cutter Compensation


Number (1): Tool Number)
(Low-speed Response)

[Description]

/
This function sets the cutter compensation number of the specified

om
tool group in the tool life management data. (M series only)

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
169

+1 +16
(Completion code)

+2 +32

pa
(Need not be set)
cs
(Data length in bytes)
4

+3 +48
(Data number)
.cn

N
(N = Tool group number)

+4 +64
(Data attribute)
M
(M = Tool number) Value
w

+5 +80
Cutter Unsigned binary
compensation number 1-255
(4 bytes)
w
w
://
tp
ht

- 491 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the cutter compensation number.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered tool group.
4: The tool number in 'Data attribute' has wrong value.

/
5: The tool number is not found in the tool group.

om
6: No option for the tool life management.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
169

re
+1 +16
(Completion code)
?

+2 +32 pa
(See the explanation above)

(Data length in bytes)


4
(Same as input data)
cs
+3 +48
(Data number)
N
.cn

(Same as input data)

+4 +64
(Data attribute)
M
(Same as input data)
w

+5 +80
Cutter
compensation number
(4 bytes)
w
w

CAUTION
The effective value for Cutter compensation number
depends on tool compensation number available on
://

CNC.

NOTE
tp

1 This cannot be used with those models that do not


have the tool life management function.
ht

2 Tool life management data is not applied to the T


mode of the compound machining function.

- 492 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.21 Writing Tool Life Management Data (Cutter Compensation


Number (2): Tool Order Number)
(Low-speed Response)

[Description]

/
This function sets the cutter compensation number of the tool of the

om
specified tool order number in the tool life management data. (M
series only)

[Input data structure]

s.c
WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
170

+1 +16
pa
(Completion code)

(Need not be set)
cs
+2 +32

(Data length in bytes)


4
.cn

+3 +48
(Data number)
N
(N = Tool group number)

+4 +64
(Data attribute)
M
w

(M = Tool order number)


Value
+5 +80
Cutter Unsigned binary
w

compensation number 1-255


(4 bytes)
w
://
tp
ht

- 493 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the cutter compensation number.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered tool group.
4: The tool order number is wrong.

/
6: No option for the tool life management.

om
[Output data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
170

re
+1 +16
(Completion code)
?
(See the explanation above)

+2 +32
pa (Data length in bytes)
4
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+4 +64
(Data attribute)
M
(Same as input data)

+5 +80
Cutter
w

compensation number
(4 bytes)
w

CAUTION
w

The effective value for cutter compensation number


depends on tool compensation number available on
://

CNC.

NOTE
tp

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
ht

mode of the compound machining function.

- 494 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.22 Writing the Tool Life Management Data (Tool Information (1):
Tool Number) (Low-speed Response)

[Description]
This function sets the Tool information of the specified Tool group in

/
the Tool life management data. (M series only)

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
171

re
+1 +16
(Completion code)

(Need not be set)

+2 +32
pa
(Data length in bytes)
2
cs
+3 +48
(Data number)
N
(N = Tool group number)
.cn

+4 +64
(Data attribute)
M
(M = Tool number) Value
+5 +80
Tool information (2 bytes) 1: Tool state clear
w

2: Tool state skip

+6 +96
w
w
://
tp
ht

- 495 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the tool information.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered tool group.
4: The tool number in ’Data attribute’ has wrong value.

/
5: The tool number is not found in the tool group.

om
6: No option for tool life management.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
171

re
+1 +16
(Completion code)
?

+2 +32 pa
(See the explanation above)

(Data length in bytes)


2
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+4 +64
(Data attribute)
M
(Same as input data)

+5 +80
w

Tool information (2 bytes)

+6 +96
w

This function changes tool condition as shown below.


w

Command Before call After call


Skip (#) Unused ( )
://

clear Skip (#) In use (@)


Consumed ( * ) Unused ( )
Unused ( ) Skip (#)
tp

skip In use (@) Skip (#)


Consumed ( * ) Skip (*)
ht

NOTE
1 This cannot be used with those models that do not
have the tool life management function.
2 Tool life management data is not applied to the T
mode of the compound machining function.

- 496 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.23 Writing the Tool Management Data (Tool Information (2): Tool
Order Number) (Low-speed Response)

[Description]
This function sets the tool information of the tool of the specified tool

/
order number in the tool life management data. (M series only)

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
172

re
+1 +16
(Completion code)

(Need not be set)

+2 +32
pa
(Data length in bytes)
2
cs
+3 +48
(Data number)
N
(N : Tool group number)
.cn

+4 +64
(Data attribute)
M
(M : Tool order number)
Value
+5 +80
Tool information (2 bytes) 1: Tool status clear
w

2: Tool status skip


w
w
://
tp
ht

- 497 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the tool information.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered tool group.
4: The tool order number is wrong.

/
6: No option for Tool life management.

om
[Output data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
172

re
+1 +16
(Completion code)
?
(See the explanation above)

+2 +32
pa (Data length in bytes)
2
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+4 +64
(Data attribute)
M
(Same as input data)

+5 +80
Tool information (2 bytes)
w
w

This function changes tool condition as shown below.


w

Command Before call After call


Skip (#) Unused ( )
clear Skip (#) In use (@)
://

Consumed (*) Unused ( )


Unused ( ) Skip (#)
skip In use (@) Skip (#)
tp

Consumed (*) Skip (*)

NOTE
ht

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
mode of the compound machining function.

- 498 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.24 Writing Tool Life Management Data (Tool Number)


(Low-speed Response)

[Description]
This function registers a tool to the specified tool group in the tool life

/
management data.

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
173

re
+1 +16
(Completion code)

(Need not be set)

+2 +32
pa
(Data length in bytes)
4
cs
+3 +48
(Data number)
N
(N = Tool group number)
.cn

+4 +64
(Data attribute)
M
(M = Tool order number)
Value
+5 +80
Tool number (4 bytes) Unsigned binary
w

1–9999
w
w
://
tp
ht

- 499 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to register the tool number.
3: The tool group number is out of range from 1 to 512, or exceeds
the maximum number of registered tool group.
4: The tool order number is wrong.

/
6: No option for the tool life management.

om
[Output data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
173

re
+1 +16
(Completion code)
?
(See the explanation above)

+2 +32
pa (Data length in bytes)
4
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+4 +64
(Data attribute)
M
(Same as input data)

+5 +80
Tool number (4 bytes)
w
w

NOTE
w

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
://

mode of the compound machining function.


tp
ht

- 500 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.25 Reading The Tool Life Management Data (Tool Group


Number) (8-digit tool number) (High-speed Response)

[Description]
This function reads the tool group number to which the tool number is

/
currently registered. This function supports 8 digits tool number.

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
200

re
+1 +16
(Completion code)

(Need not be set)

+2 +32
pa
(Data length in bytes)

(Need not be set)
cs
+3 +48

(Data number)
0
.cn

+4 +64
(Data attribute)
M
(M = Tool number)

+6 +96
(Data area)
w


(Need not be set)
w

NOTE
w

When the tool number is set to "0", the tool group


number of the currently used tool is read.
If a tool group number is not specified after the
://

power is turned ON, tool group number "0" is read.


Also, if a tool number is registered to two or more
tool group numbers, the tool group numbers of all
tp

tool groups to which the tool number is registered


are read.
ht

- 501 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool group number was read successfully.
4: The tool number in 'Data Attribute' has a wrong value.
5: The tool number is not registered.
6: The tool life management option has not been added on.

/
om
[Output data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
200

re
+1 +16
(Completion code)
?
(See the explanation above.)

+2

+3
+32

+48
(L = 4 × n)pa
(Data length in bytes)
L L = 4 to 4 × n
n is the number of tool group numbers
when multiple groups is specified.
cs
(Data number)

+4 +64
.cn

(Data attribute)
M
(M: Entered data)
Value
+6 +96
Unsigned binary
Tool group number
w

(4 bytes)

+8 +128
w

Or, when the tool number is registered to multiple groups

Value
w

+6 +96
Tool group number Unsigned binary
(4 bytes)
+8 +128
://

Tool group number


(4 bytes)
+10 +160
Tool group number
(4 bytes)
tp

+12 +192
ht

NOTE
1 This cannot be used with those models that do not
have the tool life management function.
2 Tool life management data is not applied to the T
mode of the compound machining function.
And compound machining function is not applied to
the function of tool life management data B.

- 502 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.26 Reading Tool Life Management Data (Tool Information (1):


Tool Number) (8-digit tool number) (High-speed Response)

[Description]
This function reads the tool information (status) according to the

/
specified tool group number and tool number.

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
201

re
+1 +16
(Completion code)

(Need not be set)

+2 +32
pa (Data length in bytes)

(Need not be set)
cs
+3 +48
(Data number)
N
(N : Tool group number)
.cn

+4 +64
(Data attribute)
M
(M : Tool number)

+6 +96
w

(Data area)

(Need not be set)
+8 +128
w

CAUTION
w

When the tool group number and tool number are


set to "0", the currently used tool group and tool
://

number are referenced.


If a tool group number is not specified after the
power is turned ON, tool group number "0" is read.
tp
ht

- 503 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool information was read successfully.
3: The specified tool group number is incorrect.
4: The specified tool number is incorrect.
5: The specified tool number is not registered to the specified tool

/
group.

om
6: The tool life management option has not been added on.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)

re
201

+1 +16
(Completion code)
?

+2 +32 pa
(See the explanation above.)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
.cn

(N: Entered data)

+4 +64
(Data attribute)
M
(M: Entered data) Value
w

+6 +96
0: See "CAUTION" on the previous page.
Tool status information 1: Tool is registered.
(4 bytes) 2: End of tool life.
3: Tool skipped.
w

All above three must be “0”.


+8 +128
w

NOTE
1 This cannot be used with those models that do not
://

have the tool life management function.


2 Tool life management data is not applied to the T
mode of the compound machining function.
tp

And compound machining function is not applied to


the function of tool life management data B.
ht

- 504 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.27 Registering Tool Life Management Data (Tool Group Number)


(8-digit tool number) (Low-speed Response)

[Description]
This function registers the tool group number to tool life management

/
data. Set the tool number, life value and life counter type to the

om
specified tool group. On the T series, since the life counter type is
specified by CNC parameter LTM (No. 6800#2), it cannot be set nor
changed here.

[Input data structure]

s.c
WORD BOOL
type type
offset offset

re
Top address +0 +0
(Function code)
202

+1 +16
(Completion code)

(Need not be set)
pa
cs
+2 +32
(Data length in bytes)
8
.cn

+3 +48
(Data number)
0

+4 +64
(Data attribute)
w

M
(M = Tool number)
Value
+6 +96
Unsigned binary
w

Tool group number 1–512


(2 bytes)

+7 +112
w

Tool life counter type 1: Frequency


(2 bytes) 2: Real time in minutes
://

+8 +128 Unsigned binary


Tool life 1–9999 (Frequency)
(4 bytes) 1–4300 (Real time minutes: 1count/4s) Note
1–1090 (Real time minutes: 1count/1s) Note
tp

Case of the tool life management data B


1–999999 (Frequency)
1–100000 (Real time in minutes)
+10 +160
ht

NOTE
The tool life count is changed by parameter
6801#5.
6801#5 = 0: the life is counted every 4seconds.
6801#5 = 1: the life is counted every 1second.

- 505 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool group was registered successfully.
3: The tool group number exceeded the range 1 to 512 or maximum
number of registered groups.
4: The tool number in 'Data Attribute' has a wrong value.

/
5: The tool life value is out-of-range. On the T series, the tool life

om
counter type is different.
6: The tool life management option has not been added on.

[Output data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)

re
202

+1 +16
(Completion code)

+2 +32
pa ?
(See the explanation above.)

(Data length in bytes)


8
cs
(Same as input data)

+3 +48
(Data number)
.cn


(Same as input data)

+4 +64 (Data attribute)


M
(Same as input data)
w

+6 +96
Tool group number
(2 bytes)
(Same as input data)
w

+7 +112
Tool life counter type
(2 bytes)
w

(Same as input data)

+8 +128
://

Tool life value


(4 bytes)
(Same as input data)
tp

+10 +160
ht

NOTE
1 This cannot be used with those models that do not
have the tool life management function.
2 Tool life management data is not applied to the T
mode of the compound machining function.
And compound machining function is not applied to
the function of tool life management data B.
- 506 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.28 Reading Tool Life Management Data (Tool Length


Compensation Number (1): Tool Number)
(8-digit tool number) (High-speed Response)

[Description]

/
This function reads the tool length compensation number according to

om
the specified tool group number and tool number. (M series only)

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
227

+1 +16

+2 +32
pa (Completion code)

(Need not be set)

(Data length in bytes)


cs

(Need not be set)

+3 +48
(Data number)
.cn

N
(N : Tool group number)

+4 +64
(Data attribute)
M
(M : Tool number)
w

+6 +96
(Data area)

(Need not be set)
w

+8 +128
w

CAUTION
When the tool group number and tool number are
://

set to "0", the currently used tool group and tool


number are referenced.
If a tool group number is not specified after the
tp

power is turned ON, tool group number "0" is read.


"0" is always read on the T series.
ht

- 507 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool length compensation number was read successfully.
3: The specified tool group number is incorrect.
4: The specified tool number is incorrect.
5: The specified tool number is not registered to the specified tool

/
group.

om
6: The tool life management option has not been added on.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
227

re
+1 +16
(Completion code)
?

+2 +32
pa
(See the explanation above.)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
(N: Entered data)
.cn

+4 +64
(Data attribute)
M
(M: Entered data) Value
+6 +96
w

Tool length compensation number Unsigned binary


(4 bytes)

+8 +128
w
w

NOTE
1 This cannot be used with those models that do not
have the tool life management function.
://

2 Tool life management data is not applied to the T


mode of the compound machining function.
And compound machining function is not applied to
tp

the function of tool life management data B.


ht

- 508 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.29 Reading Tool Life Management Data (Cutter Compensation


Number (1): Tool Number) (8-digit tool number)
(High-speed Response)

[Description]

/
This function reads the cutter compensation number according to the

om
specified tool group number and tool number. (M series only)

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)

re
228

+1 +16
(Completion code)

+2 +32
pa −
(Need not be set)

(Data length in bytes)



cs
(Need not be set)

+3 +48
(Data number)
N
.cn

(N : Tool group number)

+4 +64
(Data attribute)
M
(M : Tool number)
w

+6 +96
(Data area)

(Need not be set)
w

+8 +128
w

CAUTION
When the tool group number and tool number are
://

set to "0", the currently used tool group and tool


number are referenced.
If a tool group number is not specified after the
tp

power is turned ON, tool group number "0" is read.


"0" is always read on the T series.
ht

- 509 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The cutter compensation number was read successfully.
3: The specified tool group number is incorrect.
4: The specified tool number is incorrect.
5: The specified tool number is not registered to the specified tool

/
group.

om
6: The tool life management option has not been added on.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)

re
228

+1 +16
(Completion code)

+2 +32
?

pa
(See the explanation above.)

(Data length in bytes)


cs
4

+3 +48
(Data number)
N
.cn

(N: Entered data)

+4 +64
(Data attribute)
M
(M: Entered data) Value
w

+6 +96
Unsigned binary
Cutter compensation number
(4 bytes)
w

+8 +128
w

NOTE
1 This cannot be used with those models that do not
://

have the tool life management function.


2 Tool life management data is not applied to the T
mode of the compound machining function.
tp

And compound machining function is not applied to


the function of tool life management data B.
ht

- 510 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.30 Writing Tool Life Management Data (Tool Length


Compensation Number (1): Tool Number)
(8-digit tool number) (Low-speed Response)

[Description]

/
This function sets the tool length compensation number of a specified

om
tool group in the tool life management data. (M series only)

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
229

+1 +16

+2 +32
pa
(Completion code)

(Need not be set)
cs
(Data length in bytes)
4

+3 +48
(Data number)
.cn

N
(N = Tool group number)

+4 +64

(Data attribute)
M
w

(M = Tool number)

Value
w

+6 +96
Unsigned binary
Tool length 1–255
compensation number
w

(4 bytes)
://

+8 +128
tp
ht

- 511 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The tool length compensation number was written successfully.
3: The specified tool group number is incorrect.
4: The specified tool number is incorrect.
5: The specified tool number is not registered to the specified tool

/
group.

om
6: The tool life management option has not been added on.

[Output data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
229

re
+1 +16
(Completion code)
?

+2 +32 pa
(See the explanation above.)

(Data length in bytes)


4
cs
(Same as input data)
+3 +48
(Data number)
N
.cn

(Same as input data)


+4 +64
(Data attribute)
M
(Same as input data)

+6 +96
w

Tool length
compensation number
(4 bytes)
w

+8 +128
w

CAUTION
The effective value for tool length compensation
number depends on tool compensation number
://

available on CNC.
tp

NOTE
1 This cannot be used with those models that do not
have the tool life management function.
ht

2 Tool life management data is not applied to the T


mode of the compound machining function.
And compound machining function is not applied to
the function of tool life management data B.

- 512 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.31 Writing Tool Life Management Data (Cutter Compensation


Number (1): Tool Number) (8-digit tool number)
(Low-speed Response)

[Description]

/
This function sets the cutter compensation number of a tool belonging

om
to a specified tool group in the tool life management data. (M series
only)

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
230

+1

+2
+16

+32
− pa
(Completion code)
(Need not be set)
cs
(Data length in bytes)
4

+3 +48
.cn

(Data number)
N
(N = Tool group number)

+4 +64

(Data attribute)
w

M
(M = Tool number)
w

Value
+6 +96
Unsigned binary
1–255
w

Cutter
compensation number
(4 bytes)
://

+8 +128
tp
ht

- 513 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: The cutter compensation number was written successfully.
3: The tool group number exceeded the range 1 to 512 or maximum
number of registered groups.
4: The specified tool number is incorrect.

/
5: The specified tool number is not registered to the specified tool

om
group.
6: The tool life management option has not been added on.

[Output data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
230

+16
+1

+2 +32
pa
(Completion code)
?
(See the explanation above.)
cs
(Data length in bytes)
4
(Same as input data)

+3 +48
.cn

(Data number)
N
(Same as input data)
+4 +64
(Data attribute)
M
w

(Same as input data)

+6 +96
Cutter
compensation number
w

(4 bytes)
+8 +128
w

CAUTION
://

The effective value for Cutter compensation number


depends on tool compensation number available on
CNC.
tp

NOTE
1 This cannot be used with those models that do not
ht

have the tool life management function.


2 Tool life management data is not applied to the T
mode of the compound machining function.
And compound machining function is not applied to
the function of tool life management data B.

- 514 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.32 Writing the Tool Life Management Data (Tool Information (1):
Tool Number) (8-digit tool number) (Low-speed Response)

[Description]

/
This function sets the tool information of a tool belonging to a

om
specified tool group in the tool life management data. (M series only)

[Input data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
231

re
+1 +16
(Completion code)

+2 +32 pa
(Need not be set)

(Data length in bytes)


2
cs
+3 +48
(Data number)
N
.cn

(N = Tool group number)

+4 +64

(Data attribute)
M
(M = Tool number)
w

Value
+6 +96
w

1: Clears tool status.


Tool information
(2 bytes) 2: Skips tool status.

+7 +112
w

[Completion codes]
://

0: The tool information was written successfully.


3: The tool group number exceeded the range 1 to 512 or maximum
number of registered groups.
tp

4: The specified tool number is incorrect.


5: The specified tool number is not registered to the specified tool
group.
ht

6: The tool life management option has not been added on.

- 515 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0

om
(Function code)
231

+1 +16
(Completion code)
?
(See the explanation above.)

s.c
+2 +32
(Data length in bytes)
2
(Entered data)

+48

re
+3
(Data number)
N
(Entered data)

+4 +64

pa (Data attribute)
M
(Entered data)
cs
+6 +96
.cn

Tool information
(2 bytes)

+7 +112
w

The following table shows how the tool status changes before and
after this function is specified.
Command Before call After call
w

Skip (#) Unused ( )


clear Skip (#) In use (@)
w

Used (*) Unused ( )


Unused ( ) Skip (#)
skip In use (@) Skip (#)
://

Used (*) Skip (*)

NOTE
tp

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
ht

mode of the compound machining function.


And compound machining function is not applied to
the function of tool life management data B.

- 516 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.33 Deleting Tool life Management Data (Tool Group)


(Low-speed Response)

[Description]
This function deletes the specified tool group in the tool life

/
management data. In short, it makes the condition that Tool group is

om
not registered.

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0

re
(Function code)
324

+1 +16
(Completion code)

+2 +32
pa −
(Need not be set)
cs
(Data length in bytes)
0

+3 +48
(Data number)
.cn

N
(N = Tool group number)

+4 +64

(Data attribute)
0
w

+5 +80
w
w
://
tp
ht

- 517 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to delete the tool group number.
3: The tool group number is out of range from 1 to 512,or exceeds
the maximum number of registered tool group.
6: No option for the tool life management.

/
om
[Output data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
324

+1 +16

re
(Completion code)
?
(See the explanation above)

+2 +32

+3 +48
pa
(Data length in bytes)
0
(Same as input data)

(Data number)
cs
N
(Same as input data)

+4 +64
(Data attribute)
.cn

0
(Same as input data)

+5 +80
w

NOTE
1 This cannot be used with those models that do not
w

have the tool life management function.


2 Tool life management data is not applied to the T
mode of the compound machining function.
w
://
tp
ht

- 518 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.34 Deleting Tool life Management Data (Tool Data)


(Low-speed Response)

[Description]
The function deletes the tool data of the tool of the specified tool order

/
number in the tool life management data. (M series only)

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
325

re
+1 +16
(Completion code)

+2 +32
pa (Need not be set)

(Data length in bytes)


0
cs
+3 +48
(Data number)
N
(N = Tool group number)
.cn

+4 +64
(Data attribute)
M
(M = Tool order number)

+5 +80
w
w
w
://
tp
ht

- 519 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to delete the tool group number.
3: The tool group number is out of range from 1 to 512,or exceeds
the maximum number of registered tool group.
4: The tool order number is wrong.

/
6: No option for the tool life management.

om
[Output data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
325

re
+1 +16
(Completion code)
?
(See the explanation above)

+2 +32
pa (Data length in bytes)
0
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+4 +64
(Data attribute)
M
(Same as input data)

+5 +80
w

NOTE
w

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
w

mode of the compound machining function.


://
tp
ht

- 520 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.35 Clearing Tool Life Management Data (Tool Life Counter and
Tool Information) (Low-speed Response)

[Description]
This function clears the tool life counter and all tool information of the

/
specified tool group in the tool life management data.

om
[Input data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
326

re
+1 +16
(Completion code)

+2 +32 pa (Need not be set)

(Data length in bytes)


cs
0

+3 +48
(Data number)
N
.cn

(N = Tool group number)

+4 +64

(Data attribute)
0

+5 +80
w
w
w
://
tp
ht

- 521 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to clear the tool life counter and the tool information.
3: The tool group number is out of range from 1 to 512,or exceeds
the maximum number of registered tool group.
6: No option for the tool life management.

/
om
[Output data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
326

re
+1 +16
(Completion code)
?
(See the explanation above)

+2

+3
+32

+48
pa (Data length in bytes)
0
(Same as input data)
cs
(Data number)
N
(Same as input data)

+4 +64
.cn

(Data attribute)
0
(Same as input data)

+5 +80
w

NOTE
1 This cannot be used with those models that do not
w

have the tool life management function.


2 Tool life management data is not applied to the T
w

mode of the compound machining function.


://
tp
ht

- 522 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.36 Writing Tool Life Management Data (Arbitrary Group Number)


(Low-speed Response)

[Description]
This function sets arbitrary group number of the specified tool group

/
in the tool life management data.

om
[Input data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
327

re
+1 +16
(Completion code)

+2 +32 pa (Need not be set)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
(N = Tool group number)
.cn

+4 +64
(Data attribute)
0
w

+5 +80
Arbitrary group number
(4 bytes)
w

NOTE
w

Writing the tool life Management Data (Arbitrary


group number) is available for tool life management
://

data B.
tp
ht

- 523 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the arbitrary group number.
3: The tool group number is out of range from 1 to 512,or exceeds
the maximum number of registered tool group.
5: Arbitrary group number is out of range.

/
6: No option for the tool life management.

om
[Output data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
327

re
+1 +16
(Completion code)
?
(See the explanation above)

+2 +32
pa (Data length in bytes)
4
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+4 +64
(Data attribute)
0
(Same as input data)

+5 +80
w

Arbitrary group number


(4 bytes)
w

NOTE
w

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
://

mode of the compound machining function.


And compound machining function is not applied to
the function of tool life management data B.
tp
ht

- 524 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.6.37 Writing Tool Life Management Data (Remaining Tool Life)


(Low-speed Response)

[Description]
This function sets the length of remaining tool life of the specified tool

/
group in the tool life management data.

om
[Input data structure]

WORD BOOL

s.c
type type
offset offset

Top address +0 +0
(Function code)
328

re
+1 +16
(Completion code)

+2 +32
pa (Need not be set)

(Data length in bytes)


4
cs
+3 +48
(Data number)
N
(N = Tool group number)
.cn

+4 +64
(Data attribute)
0

+5 +80
w

Remaining tool life


(4 bytes)
w

NOTE
w

Writing the tool life Management Data (Remaining


tool life) is available for tool life management data B.
://
tp
ht

- 525 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Success to set the length of remaining tool life.
3: The tool group number is out of range from 1 to 512,or exceeds
the maximum number of registered tool group.
5: Remaining tool life is out of range.

/
6: No option for the tool life management.

om
[Output data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
328

re
+1 +16
(Completion code)
?
(See the explanation above)

+2 +32
pa (Data length in bytes)
4
(Same as input data)
cs
+3 +48
(Data number)
N
(Same as input data)
.cn

+4 +64
(Data attribute)
0
(Same as input data)

+5 +80
w

Remaining tool life


(4 bytes)
w

NOTE
w

1 This cannot be used with those models that do not


have the tool life management function.
2 Tool life management data is not applied to the T
://

mode of the compound machining function.


And compound machining function is not applied to
the function of tool life management data B.
tp
ht

- 526 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7 TOOL MANAGEMENT FUNCTIONS

Command of special magazine at multipath system

/
The tool management data and the magazine management table are

om
common to all paths. But the spindle position table and wait position
table are individual at each path. When the spindle position or the wait
position at each path will be specified as the magazine through PMC
window, the magazine number is depend on the following table.

s.c
Spindle position
1st 2nd 3rd 4th
st
1 Path 111 (11) 112 (12) 113 (13) 114 (14)
2nd Path 211 212 213 214

re
3rd Path 311 312 313 314

st
1 Path
2nd Path
pa 1st
121 (21)
221
Wait position
2nd
122 (22)
222
3rd
123 (23)
223
4th
124 (24)
224
cs
3rd Path 321 322 323 324

NOTE
.cn

The CNC can control a maximum of four axes per


path.
w
w
w
://
tp
ht

- 527 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

A.7.1 Exchange of Tool Management Data Numbers in a Magazine


Management Table (Low-speed Response)

[Description]

/
This function exchanges tool management data number in a pair of

om
pots of specified magazine.
When the magazine number is set to 11‐14(1‐4th spindle position)
or 21‐24(1‐4th waiting position), the pot number may be dummy
number. It is necessary for specifying the 2nd or 3rd spindle/wait

s.c
position at the multipath system to specify the path number by the
place of 100. For example, the magazine number 213 means the 3rd
spindle position at the 2nd path. Especially, the 1st spindle position
can be specified without the third of hundreds (The magazine number
22 and 122 indicates the same magazine).

re
When tool management function oversize tools support option is
effective, if changed tools are interfered with other tools, completion
code 5 and detail completion code 27 are returned. Refer to note of the
pa
following description for details.
cs
.cn
w
w
w
://
tp
ht

- 528 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Input data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0

om
(Function code)
329
+1 +16
(Completion code)

(Need not be set)
+2 +32

s.c
(Data length in bytes)
8

+3 +48
(Data number)

re
(Need not be set)
+4 +64 (Data attribute)

(Need not be set)
+5

+6
+80

+96
pa (Data number 2)

(Need not be set)
(Detailed completion code)
cs

(Need not be set)
+7 +112 Magazine number 1 (2 bytes)
.cn

+8 +128
Pot number 1 (2 bytes)

+9 +144
w

Magazine number 2 (2 bytes)

+10 +160
w

Pot number 2 (2 bytes)


w
://
tp
ht

- 529 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Normal end.
5: Specified magazine number / pot number is not registered / Tool
interference
6: No required option.

/
om
[Detailed completion codes]
This code is 0 except completion code is 5.
Completion code = 5
21: Error of magazine No.1
22: Error of pot No.1

s.c
24: Error of magazine No.2
25: Error of pot No.2
27: Interfere with other tools

re
[Output data structure]

WORD BOOL

Top address
type
offset
+0
type
offset
+0
pa
(Function code)
cs
329
+1 +16 (Completion code)
See the above explanation of
.cn

the completion codes.


+2 +32
(Data length in bytes)
8

+3 +48
(Data number)
w

+4 +64 (Data attribute)


w

+5 +80
(Data number 2)
w

+6 +96
(Detailed completion code)
://

See the above explanation of the


detailed completion codes.
+7 +112
Magazine number 1 (2 bytes)
tp

+8 +128
Pot number 1 (2 bytes)
ht

+9 +144
Magazine number 2 (2 bytes)

+10 +160
Pot number 2 (2 bytes)

- 530 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.2 Search of empty pot (Low-speed Response)

[Description]
This function searches the nearest empty pot, which is expressed, as
tool management data is 0, from specified pot in the magazine.

/
Spindle and waiting position are not searched as empty pot.

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
330

re
+1 +16
(Completion code)

(Need not be set)
+2

+3
+32

+48
pa
(Data length in bytes)

(Need not be set)
(Data number)
cs
Magazine number

+4 +64
(Data attribute)
Search direction
.cn

+5 +80
(Data number 2)
Pot number

+6 +96 (Detailed completion code)


w


(Need not be set)
+7 +112
Data area (4 bytes)
w

(Need not be set)


w
://

[Search direction]
−1: Descending order
tp

0: No order (The nearest pot is searched)


1: Ascending order
ht

- 531 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Normal end
3: Error of magazine number/pot number
4: Error of search direction
6: No required option

/
8: No empty pot

om
[Detailed completion codes]
This code is 0 except completion code is 3.
Completion code = 3
21: Error of magazine number

s.c
22: Error of pot number

[Output data structure]

re
WORD BOOL
type type
offset offset
Top address +0

+1
+0

+16
pa (Function code)
330

(Completion code)
cs
See the above explanation of
the completion codes.
+2 +32
(Data length in bytes)
.cn

+3 +48
(Data number)
Magazine number

+4 +64
w

(Data attribute)
Search direction

+5 +80
w

(Data number 2)
Pot number

+6 +96 (Detailed completion code)


w

See the above explanation of the


detailed completion codes.
+7 +112
Searched magazine number (2 bytes)
://

+8 +128
Searched pot number (2 bytes)
tp
ht

When this function is executed without specifying search direction,


the pot found in ascending direction is output if empty pots are found
at the same distance away from the specified pot in both orders.

- 532 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.3 New-register of a Tool Management Data (Low-speed


Response)

[Description]
This function registers new tool data according to specified magazine

/
and pot number. The tool data was registered at the first vacant area

om
from the top of the database in NC system.
Vacant area means that tool management data of the area is ignored.
(It is equal to the state that bit 0 of tool information is 0.) If there is no
vacant area, completion code 8 is returned.
If a set of specified magazine and pot number is allocated, completion

s.c
code 13 is returned.
When tool management function oversize tools support is effective, if
a set of specified magazine and pot number is the empty pot but
interferes with other tools because of tool geometry, then completion

re
code 13 is returned.

NOTE
pa
The data length varies depending on whether the
"tool management function customized data
extension (5 to 20)" and "tool management function
cs
customized data extension (5 to 40)" options are
present or not.
.cn

(a) Data length


76: When there is no option
140: When the "tool management function customized data
extension (5 to 20)" option is present
w

220: When the "tool management function customized data


extension (5 to 40)" option is present
w
w
://
tp
ht

- 533 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Input data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0
(Function code)

om
331
+1 +16
(Completion code)

(Need not be set)
+2 +32
(Data length in byte)

s.c
76, 140, or 220

+3 +48
(Data number)
Magazine number

re
+4 +64
(Data attribute)

(Need not be set)
+5

+6
+80

+96
pa (Data number 2)
Pot number

(Detailed completion code)


cs

(Need not be set)
+7 +112
Tool type number (4 bytes)
.cn

+9 +144
Tool life counter (4 bytes)

+11 +176
w

Maximum of tool life (4 bytes)

+13 +208
≈ ≈
w
w
://
tp
ht

- 534 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

WORD BOOL
type type
offset offset
≈ ≈
Top address +13 +208

/
Previous notice tool life (4 bytes)

om
+15 +240
(LOW)
State of tool life (1 byte)

+15 +248
(HIGH)
Customizing data 0 (1 byte)

s.c
+16 +256
Tool information (2 bytes)

+17 +272

re
Tool length compensation H (2 bytes)
For the machining and
+18 +288 lathe (compound) system

+19 +304 pa
Cutter compensation number D

Spindle speed S (4 bytes)


cs
+21 +336
Feedrate F (4 bytes)
.cn

+23 +368
Dummy (magazine number)

+24 +384
Dummy (pot number) (2 bytes)
w

+25 +400
Tool geometric compensation

number G (2 bytes)
w

+26 +416 For the lathe system


Tool wear compensation number

W (2 bytes)
w

+27 +432
Tool geometry number GNO

(2 bytes)
://

+28 +448
(Reserved) (18 bytes)
≈ ≈
0
tp

+37 +592
Customizing data 1 (4 bytes)
ht

+39 +624

Customizing data 2 (4 bytes)

≈ ≈

- 535 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

WORD BOOL
type type
offset offset
≈ ≈
Top address +41 +656

/
Customizing data 3 (4 bytes)

om
≈ ≈

+75 +1200
Customizing data 20 (4 bytes)

s.c
+77 +1232
Customizing data 21 (4 bytes)

re
≈ ≈

+115 +1840

pa
Customizing data 40 (4 bytes)
cs
[Completion codes]
0: Normal end
.cn

2: Error of data length


3: Error of magazine or pot number
5: There is an error in data area / Tool interference
6: No required option
7: Protected area
w

8: There is no space
13: Already allocated
w
w
://
tp
ht

- 536 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Detailed completion codes]


This code is 0 except completion code is 5.
Completion code = 5
1: Error of tool type number
2: Error of tool life counter

/
3: Error of maximum of tool life

om
4: Error of previous notices tool life
5: Error of state of tool life
7: Error of tool information
8: Error of tool length compensation number (H)
(Machining and Lathe (Compound) system)

s.c
9: Error of cutter compensation number (D)
(Machining and Lathe (Compound) system)
10: Error of spindle speed (S)
11: Error of feedrate (F)

re
12: Error of tool geometric compensation number (G)
(Lathe system)
13: Error of tool wears compensation number (W)

pa
(Lathe system)
14: Error of tool geometry number (GNO)
27: Interfere with other tools
31 to 50: Error of customizing data 1 - 20
cs
51 to 70: Error of customizing data 21 - 40
.cn
w
w
w
://
tp
ht

- 537 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0
(Function code)

om
331

+1 +16 (Completion code)


See the above explanation of
the completion codes.
+2 +32

s.c
(Data length in bytes)
76, 140, or 220

+3 +48 (Data number)


Magazine number

re
+4 +64
(Data attribute)

+5

+6
+80

+96
pa (Data number 2)
Pot number

(Detailed completion code)


cs
See the above explanation of the
detailed completion codes.
+7 +112
.cn

Tool type number (4 bytes)

+9 +144
Tool life counter (4 bytes)

+11 +176
w

Maximum of tool life (4 bytes)

+13 +208
w

Previous notice tool life (4 bytes)


w

≈ ≈

+75 +1200
://

Customizing data 20 (4 bytes)

+77 +1232

Customizing data 21 (4 bytes)


tp

≈ ≈
ht

+115 +1840

Customizing data 40 (4 bytes)

- 538 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.4 Writing a Tool Management Data (Low-speed Response)

[Description]
This function writes a tool data according to specified magazine and
pot number. If the pot has no tool (if tool management data number is

/
not allocated), error 9 is output.

om
NOTE
The data length varies depending on whether the
"tool management function customized data

s.c
extension (5 to 20)" and "tool management function
customized data extension (5 to 40)" options are
present or not.

re
(a) Data length
76: When there is no option
140: When the "tool management function customized data

pa
extension (5 to 20)" option is present
220: When the "tool management function customized data
extension (5 to 40)" option is present
cs
.cn
w
w
w
://
tp
ht

- 539 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Input data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0
(Function code)

om
332

+1 +16 (Completion code)



(Need not be set)
+2 +32
(Data length in bytes)

s.c
76, 140, or 220

+3 +48
(Data number)
Magazine number

re
+4 +64 (Data attribute)

(Need not be set)
+5

+6
+80

+96
pa (Data number 2)
Pot number

(Detailed completion code)


cs

(Need not be set)
+7 +112
Tool type number (4 bytes)
.cn

+9 +144
Tool life counter (4 bytes)

+11 +176
w

Maximum of tool life (4 bytes)

+13 +208
≈ ≈
w
w
://
tp
ht

- 540 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

WORD BOOL
type type
offset offset
≈ ≈
Top address +13 +208

/
Previous notice tool life (4 bytes)

om
+15 +240
(LOW)
State of tool life (1 byte)

+15 +248
(HIGH)
Customizing data 0 (1 byte)

s.c
+16 +256
Tool information (2 bytes)

+17 +272 Tool length compensation number H

re
(2 bytes)
+18 +288 For the machining and lathe systems
Cutter compensation number D

+19 +304 pa
(2 bytes)

Spindle speed S

(4 bytes)
( d)
cs
+21 +336
Feedrate F (4 bytes)
.cn

+23 +368
Dummy (magazinenumber)

+24 +384
Dummy (pot number) (2 bytes)
w

+25 +400
Tool geometric compensation

number G (2 bytes)
w

+26 +416 For the lathe system


Tool wear compensation number

W (2 bytes)
w

+27 +432
Tool geometry number GNO

(2 bytes)
://

+28 +448
(Reserved) (18 bytes)
≈ ≈
0
tp

+37 +592

Customizing data 1 (4 bytes)


ht

+39 +624

Customizing data 2 (4 bytes)

≈ ≈

- 541 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

WORD BOOL
type type
offset offset
≈ ≈
Top address +41 +656

/
Customizing data 3 (4 bytes)

om

+75 +1200
Customizing data 20 (4 bytes)

s.c
+77 +1232
Customizing data 21 (4 bytes) ≈

re
≈ ≈

+115 +1840

pa
Customizing data 40 (4 bytes)
cs
[Completion codes]
0: Normal end
.cn

2: Error of data length


3: Error of magazine or pot number
5: There is an error in data area / Tool interference
6: No required option
7: Protected area
w

9: The pot has no tool


w
w
://
tp
ht

- 542 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Detailed completion codes]


This code is 0 except completion code is 3 or 5.
Completion code = 3
21: Error of magazine number
22: Error of pot number

/
23: Error of tool management data number

om
Completion code = 5
1: Error of tool type number
2: Error of tool life counter
3: Error of maximum of tool life
4: Error of previous notices tool life

s.c
5: Error of state of tool life
7: Error of tool information
8: Error of tool length compensation number (H)
(Machining and Lathe (Compound) system)

re
9: Error of cutter compensation number (D)
(Machining and Lathe (Compound) system)
10: Error of spindle speed (S)

pa
11: Error of feedrate (F)
12: Error of tool geometric compensation number (G)
(Lathe system)
13: Error of tool wears compensation number (W)
cs
(Lathe system)
14: Error of tool geometry number (GNO)
27: Interfere with other tools
.cn

31 to 50: Error of customizing data 1 - 20


51 to 70: Error of customizing data 21 - 40
w
w
w
://
tp
ht

- 543 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0
(Function code)

om
332
+1 +16
(Completion code)
See the above explanation of
the completion codes.
+2 +32
(Data length in bytes)

s.c
76, 140, or 220

+3 +48
(Data number)
Magazine number

re
+4 +64
(Data attribute)

+5

+6
+80

+96
pa (Data number 2)
Pot number

(Detailed completion code)


cs
See the above explanation of the
detailed completion codes.
+7 +112

Tool type number (4 bytes)


.cn

+9 +144
Tool life counter (4 bytes)

+11 +176
w

Maximum of tool life (4 bytes)

+13 +208
w

Previous notice tool life (4 bytes)

≈ ≈
w

+75 +1200
://

Customizing data 20 (4 bytes)


+77 +1232

Customizing data 21 (4 bytes)


tp

≈ ≈
ht

+115 +1840

Customizing data 40 (4 bytes)

- 544 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.5 Deletion of a Tool Management Data (Low-speed Response)

[Description]
This function deletes a tool management data according to specified
magazine and pot number.

/
If the pot has no tool (if tool management data number is not

om
allocated), error 9 is output.

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)

re
333
+1 +16
(Completion code)

+2

+3
+32

+48
pa
(Need not be set)
(Data length in bytes)
0
cs
(Data number)
Magazine number

+4 +64 (Data attribute)


.cn


(Need not be set)
+5 +80
(Data number 2)
Pot number
w

+6 +96 (Detailed completion code)



(Need not be set)
w
w
://
tp
ht

- 545 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Normal end
3: Invalid magazine number or pot number
6: No required option
7: Protected area

/
9: The pot has no tool

om
[Detailed completion codes]
This code is 0 except completion code is 3.
Completion code = 3
21: Error of magazine number

s.c
22: Error of pot number
23: Error of tool management data number

[Output data structure]

re
WORD BOOL
type type

Top address
offset

+0
offset

+0 pa
(Function code)
333
cs
+1 +16
(Completion code)
See the above explanation of
the completion codes.
.cn

+2 +32
(Data length in bytes)
0

+3 +48
(Data number)
Magazine number
w

+4 +64
(Data attribute)

w

+5 +80
(Data number 2)
Pot number
w

+6 +96
(Detailed completion code)
See the above explanation of the
detailed completion codes.
://
tp
ht

- 546 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.6 Reading a Tool Management Data (Low-speed Response)

[Description]
This function reads a tool management data according to specified
magazine and pot number. If the pot has no tool (if tool management

/
data number is not allocated), error 9 is output.

om
NOTE
1 Customizing data 5~20 can be read when the option
" Additional customized data on tool management

s.c
function (5~20)" or " Additional customized data on
tool management function (5~40)" exists.
Customizing data 21~40 can be read when the
option "Additional customized data on tool

re
management (5~40)" exists.
2 When tool management function oversize tools
support is effective, the tool geometry number can
be read.
pa
[Input data structure]
cs
WORD BOOL
type type
offset offset
.cn

Top address +0 +0
(Function code)
334
+1 +16 (Completion code)
w


(Need not be set)
+2 +32
(Data length in bytes)
w


(Need not be set)
+3 +48
(Data number)
w

Magazine number

+4 +64
(Data attribute)

://

(Need not be set)


+5 +80
(Data number 2)
Pot number
tp

+6 +96 (Detailed completion code)



(Need not be set)
ht

+7 +112
(Data area)
76, 140, 220

- 547 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Normal end
3: Invalid magazine number or pot number
6: No required option
7: Protected area

/
9: The pot has no tool

om
[Detailed completion codes]
This code is 0 except completion code is 3.
Completion code = 3
21: Error of magazine number

s.c
22: Error of pot number

re
pa
cs
.cn
w
w
w
://
tp
ht

- 548 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Output data structure]


WORD BOOL
type type
offset offset
Top address +0 +0

/
(Function code)

om
334
+1 +16
(Completion code)
See the above explanation of
the completion codes.
+2 +32
(Data length in bytes)

s.c
76, 140 or 230

+3 +48
(Data number)
Magazine number

+4 +64

re
(Data attribute)

+5 +80

+6 +96
(Data number 2)
Pot number
pa
(Detailed completion code)
See the above explanation of the
cs
detailed completion codes.
+7 +112

Tool type number (4 bytes)


.cn

+9 +144
Tool life counter (4 bytes)

+11 +176
Maximum of tool life (4 bytes)
w

+13 +208
Previous notice tool life (4 bytes)
w

+15 +240
(LOW) State of tool life (1 byte)
w

+15 +248
(HIGH)
Customizing data 0 (1 byte)
://

+16 +256
Tool information (2 bytes)
tp

+17 +272
Tool length compensation number H

(2 bytes) For the machining and lathe (compound)


ht

+18 +288
Cutter compensation number D systems

(2 bytes)
+19 +304
Spindle speed S (4 bytes)

≈ ≈

- 549 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

WORD BOOL
type type
offset offset
≈ ≈
Top address +21 +336

/
Feedrate F (4 bytes)

om
+23 +368
Dummy (magazine number)

+24 +384

Dummy (pot number) (2 bytes)

s.c
+25 +400
Tool geometric compensation

number G (2 bytes)
For the lathe system only
+26 +416
Tool wear compensation number W

re
(2 bytes)
+27 +432
Tool geometry number GNO

+28 +448

pa (2 bytes)
(Reserved) (18 bytes)
0 ≈
cs
+37 +592
Customizing data 1 (4 bytes)
.cn

+39 +624
Customizing data 2 (4 bytes)

+41 +656
Customizing data 3 (4 bytes)
w

+43 +688
Customizing data 4 (4 bytes)
w

+45 +720

Customizing data 5 (4 bytes)


w

≈ ≈
://

+75 +1200
Customizing data 20 (4 bytes)
tp

+77 +1232
Customizing data 21 (4 bytes)
ht

≈ ≈

+115 +1840
Customizing data 40 (4 bytes)

- 550 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.7 Writing each Tool Data (Low-speed Response)

[Description]
This function writes specified data into tool management data.
The type of written data is input to the data attribute area.

/
The size of a necessary data area changes depending on the data type.

om
The relation among a data type, an input value and a necessary data
area size is as follows.

Table A.7.7 Input value to the data attribute and the data area size
Input value Data type Data area size Remarks

s.c
1 Tool type number 4 bytes
2 Tool life counter 4 bytes
3 Maximum of tool life 4 bytes
4 Previous tool life 4 bytes

re
5 State of tool life 4 bytes
6 Customizing data 0 1 byte Bit type
7 Tool information 2 bytes
8
pa
Tool length compensation
number (H)
2 bytes Machining and
Lathe (Compound)
system
cs
9 Cutter compensation 2 bytes Machining and
number (D) Lathe (Compound)
system
10 Spindle speed (S) 4 bytes
.cn

11 Feedrate (F) 4 bytes


12 Tool geometric 2 bytes Lathe system
compensation number (G)
13 Tool wear compensation 2 bytes Lathe system
w

number (W)
14 Tool geometry number 2 bytes
(GNO)
w

31 Customizing data 1 4 bytes


32 Customizing data 2 4 bytes
33 Customizing data 3 4 bytes
w

34 Customizing data 4 4 bytes


35 Customizing data 5 4 bytes
36 Customizing data 6 4 bytes
://

≈ ≈ ≈ ≈
50 Customizing data 20 4 bytes
51 Customizing data 21 4 bytes
tp

≈ ≈ ≈ ≈
70 Customizing data 40 4 bytes
ht

- 551 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

NOTE
1 Customizing data 5~20 can be read when the option
" Additional customized data on tool management
function (5~20)" or " Additional customized data on
tool management function (5~40)" exists.

/
Customizing data 21~40 can be read when the

om
option "Additional customized data on tool
management (5~40)" exists.
2 Tool geometry number (GNO) can be written when
the option "Tool management function oversize tools
support" exists.

s.c
[Input data structure]

re
WORD BOOL
type type
offset offset

Top address +0

+1
+0

+16
pa (Function code)
335

(Completion code)
cs

(Need not be set)
+2 +32
(Data length in bytes)
1, 2, 4
.cn

+3 +48
(Data number)
Magazine number

+4 +64
(Data attribute)
w

Data type

+5 +80
(Data number 2)
w

Pot number

+6 +96 (Detailed completion code)



w

(Need not be set)


+7 +112 (Data area)
1, 2, 4
://
tp

[Completion codes]
0: Normal end
3: Invalid magazine number, pot number or tool management data
ht

number
4: Error of data type
5: Error of data area / Tool interference
6: No required option
7: Protected area

- 552 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

[Detailed completion codes]


This code is 0 except completion code is 3 or 5.
Completion code = 3
21: Error of magazine number
22: Error of pot number

/
23: Error of tool management data number

om
Completion code = 5
1: Error of tool type number
2: Error of tool life counter
3: Error of maximum of tool life
4: Error of previous notices tool life

s.c
5: Error of state of tool life
7: Error of tool information
8: Error of tool length compensation number (H)
(Machining and Lathe (Compound) system)

re
9: Error of cutter compensation number (D)
(Machining and Lathe (Compound) system)
10: Error of spindle speed (S)

pa
11: Error of feedrate (F)
12: Error of tool geometric compensation number (G)
(Lathe system)
13: Error of tool wears compensation number (W)
cs
(Lathe system)
14: Error of tool geometry number (GNO)
27: Interfere with other tools
.cn

31 to 50: Error of customizing data 1 - 20


51 to 70: Error of customizing data 21 - 40
w
w
w
://
tp
ht

- 553 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

WORD BOOL
type type
offset offset
Top address +0 +0

/
(Function code)

om
335
+1 +16
(Completion code)
See the above explanation of
the completion codes.
+2 +32
(Data length in bytes)

s.c
1, 2, 4

+3 +48
(Data number)
Magazine number

re
+4 +64
(Data attribute)
Data type

+5 +80

+6 +96
pa (Data number 2)
Pot number

(Detailed completion code)


See the above explanation of the
cs
detailed completion codes.
+7 +112
(Data area)
1, 2, 4
.cn
w
w
w
://
tp
ht

- 554 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.8 Search of Tool Management Data (Low-speed Response)

[Description]
This function searches the tool by customizing data.
This function searches whether there is corresponding data to the

/
specified customizing data for the tool registered in the magazine

om
management table, and returns the magazine and pot number of the
tool found first.

Search order
1. Normal magazine

s.c
2. Spindle position
3. Wait position

[Input data structure]

re
WORD BOOL
type type

Top address
offset

+0
offset

+0 pa
(Function code)
366
cs
+1 +16 (Completion code)

(Need not be set)
.cn

+2 +32
(Data length in bytes)

(Need not be set)
+3 +48
(Data number)
Customizing data number
w

+4 +64
(Data attribute)
w

Comparison data
+5 +80
(Data number 2)
w

+6 +96 (Detailed completion code)



://

(Need not be set)


tp
ht

- 555 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Completion codes]
0: Normal end
3: Invalid customizing data number
6: No required option

/
[Detailed completion codes]

om
This code is 0 except completion code is 3.
Completion code = 3
1: Too small customizing data number (under 0)
2: Too large customizing data number
3: The tool is not found

s.c
[Output data structure]

WORD BOOL

re
type type
offset offset

Top address +0 +0

+1 +16
pa (Function code)
366

(Completion code)
See the above explanation of
cs
the completion codes.
+2 +32
(Data length in bytes)
4 or 0
.cn

+3 +48
(Data number)

+4 +64 (Data attribute)



w

+5 +80
(Data number 2)

w

+6 +96 (Detailed completion code)


See the above explanation of the
w

detailed completion codes.


+7 +112
Magazine number (2 bytes)
://

+8 +128
Pot number (2 bytes)
tp
ht

- 556 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.9 Shifting Tool Management Data (Low-speed Response)

[Description]
This function shifts the magazine management table.
This function shifts tool management table for the fixed pot number

/
type magazine.

om
[Input data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
367

re
+1 +16 (Completion code)

(Need not be set)
+2 +32

+3 +48
pa (Data length in bytes)
0

(Data number)
cs
Magazine number

+4 +64
(Data attribute)
Shift direction
.cn

+5 +80
(Data number 2)
Shift amount

+6 +96 (Detailed completion code)



w

(Need not be set)


w

[Completion codes]
0: Normal end
w

3: Invalid magazine number or shift amount


4: Invalid shift direction
6: No required option
://

[Detailed completion codes]


This code is 0 except completion code is 3.
tp

Completion code = 3
1: Invalid magazine number
2: Invalid shift amount
ht

(Specified under 0 or over magazine number)

- 557 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0

om
(Function code)
367
+1 +16 (Completion code)
See the above explanation of
the completion codes.
+2 +32

s.c
(Data length in bytes)
0

+3 +48
(Data number)
Magazine number

re
+4 +64
(Data attribute)
Shift direction

+5

+6
+80

+96
pa (Data number 2)
Shift amount

(Detailed completion code)


cs
See the above explanation of the
detailed completion codes.
.cn

The shift direction is defined follows.

Shift direction: 1
The tool data in pot 1 shifts pot 2.
w

The tool data in pot 2 shifts pot 3.


The tool data in pot 3 shifts pot 4.
The tool data in pot 4 shifts pot 5.
w

The tool data in pot 5 shifts pot 1.


w

Shift direction: -1
The tool data in pot 1 shifts pot 5.
The tool data in pot 2 shifts pot 1.
://

The tool data in pot 3 shifts pot 2.


The tool data in pot 4 shifts pot 3.
The tool data in pot 5 shifts pot 4.
tp

Pot number 1 2 3 4 5
ht

Direction: 1 7 3 4 5 6
Original condition 3 4 5 6 7
Direction: −1 4 5 6 7 3

- 558 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.10 Reading a Decimal Point of the Customizing Data (Low-speed


Response)

[Description]
This function reads a decimal point of the customizing data.

/
om
NOTE
Customizing data 5~20 can be read when the option
" Additional customized data on tool management
function (5~20)" or " Additional customized data on

s.c
tool management function (5~40)" exists.
Customizing data 21~40 can be read when the
option "Additional customized data on tool
management (5~40)" exists.

re
[Input data structure]

WORD
type
offset
BOOL
type
offset
pa
cs
Top address +0 +0
(Function code)
392
+1 +16
(Completion code)
.cn


(Need not be set)
+2 +32
(Data length in bytes)

(Need not be set)
w

+3 +48 (Data number)



(Need not be set)
w

+4 +64 (Data attribute)



(Need not be set)
+5 +80
w

(Data area)

(Need not be set)
://

[Completion codes]
tp

0: Normal end
6: No required option
ht

- 559 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0
(Function code)

om
392
+1 +16
(Completion code)
See the above explanation of
the completion codes.
+2 +32
(Data length in bytes)

s.c
4, 20, or 40

+3 +48
(Data number)

re
+4 +64
(Data attribute)

+5
(LOW)

+5
+80

+88
pa
Decimal point of the customizing
data1 (1byte)

Decimal point of the customizing


cs
(HIGH)
data2 (1byte)
+6 +96
(LOW) Decimal point of the customizing
.cn

data3 (1byte)
+6 +104
Decimal point of the customizing
(HIGH)
data4 (1byte)

+7 +112
Decimal point of the customizing
w

(LOW)
data5 (1byte)
w

≈ ≈

+14 +232
(HIGH) Decimal point of the customizing
w

data20 (1byte)

≈ ≈
://

+24 +392
(HIGH) Decimal point of the customizing
data40 (1byte)
tp
ht

- 560 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.11 Search of Empty Pot for Oversize Tool Use (Low-speed


Response)

[Description]
This function searches the nearest empty pot, which can store the

/
specified oversize tool in the same magazine.

om
Spindle and waiting position are not searched as empty pot.

[Input data structure]

s.c
WORD BOOL
type type
offset offset

Top address +0 +0
(Function code)

re
397
+1 +16
(Completion code)

+2 +32
pa (Need not be set)
(Data length in bytes)
6
cs
+3 +48
(Data number)
Magazine number

+4 +64
.cn

(Data attribute)
Search direction
+5 +80
(Data number 2)
Pot number
w

+6 +96 (Detailed completion code)



(Need not be set)
w

+7 +112
Tool geometry number (GNO)
(2 bytes)
w

[Search direction]
://

−1: Descending order


0: No order (The nearest pot is searched)
1: Ascending order
tp

[Completion codes]
ht

0: Normal end
3: Error of magazine number / pot number / tool geometry number
4: Error of search direction
6: No required option
8: No empty pot

- 561 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Detailed completion codes]


This code is 0 except completion code is 3.
Completion code = 3
21: Error of magazine number
22: Error of pot number

/
26: Error of tool geometry number

om
[Output data structure]

WORD BOOL
type type

s.c
offset offset

Top address +0 +0
(Function code)
397

re
+1 +16
(Completion code)
See the above explanation of
the completion codes.
+2 +32

+3 +48
pa (Data length in bytes)
6

(Data number)
cs
Magazine number

+4 +64
(Data attribute)
Search direction
.cn

+5 +80
(Data number 2)
Pot number

+6 +96 (Detailed completion code)


w

See the above explanation of the


detailed completion codes.
+7 +112
Tool geometry number (GNO)
w

(2 bytes)
+8 +128 Magazine number (2 bytes)
w

+9 +144
Pot number (2 bytes)
://
tp

When this function is executed without specifying search direction,


the pot found in ascending direction is output if empty pots are found
at the same distance away from the specified pot in both orders.
ht

- 562 -
B-63823EN/02 APPENDIX A.WINDOW FUNCTIONS

A.7.12 Reading a Total Life Data (Low-speed Response)

[Description]
This function reads total life data according to specified tool type
number.

/
om
[Input data structure]

WORD BOOL
type type
offset offset

s.c
Top address +0 +0
(Function code)
409
+1 +16
(Completion code)

re

(Need not be set)
+2 +32
(Data length in bytes)

+3 +48 pa −
(Need not be set)
(Data number)
Tool type number (4 bytes)
cs
+5 +80
(Data attribute)
Display type (0: count / 1: time)
.cn

+6 +96 (Detailed completion code)



(Need not be set)
w

[Completion codes]
0: Normal end
w

3: Error of tool type number


4: Error of display type
6: No required option
w

[Detailed completion codes]


://

This code is 0 except completion code is 3.


Completion code = 3
1: Error of tool type number (except 1 to 99,999,999)
tp

28: Tool type number is not found


ht

- 563 -
A.WINDOW FUNCTIONS APPENDIX B-63823EN/02

[Output data structure]

WORD BOOL
type type
offset offset

/
Top address +0 +0
(Function code)

om
409

+1 +16 (Completion code)


See the above explanation of
the completion codes.
+2 +32

s.c
(Data length in bytes)
26

+3 +48
(Data number)
Tool type number (4 bytes)

re
+5 +80
(Data attribute)
Display type (0: count / 1: time)

+6

+7
+96

+112
pa
(Detailed completion code)
See the above explanation of the
detailed completion codes.
cs
Tool type number (4 bytes)

+9 +144
.cn

Tool life counter (4 bytes)

+11 +176
Total remain life (4 bytes)

+13 +208
w

Total maximum of life (4 bytes)

+15 +240
w

Tool notice life (4 bytes)

+17 +272
w

Number (2 bytes)

+18 +288
://

(LOW) Status (1 byte)

+18 +296
(HIGH) Display type (0: count / 1: time) (1byte)
tp
ht

- 564 -
B-63823EN/02 APPENDIX B.DIFFERENCES BETWEEN PMC-SB7

B DIFFERENCES BETWEEN PMC-SB7

/
om
Those users who are already familiar with the specifications of CNC
system with PMC-SB7 should note the differences between PMC-SB7
and PMC-SD7. This chapter explains such differences between the
two types of PMC.

s.c
Availability of Additional Options
There are some differences in the additional options that can be used

re
with the CNC system related to the type of PMC. When you are going
to use the following options, please be careful to specify correct
combinations of the options.

No.
1
Items
Loader control board Not supported.
pa
PMC-SD7

(Refer to Appendix B.1)


PMC-SB7
Supported.
cs
2 PMC C language board Not supported. Supported.
(Refer to Appendix B.1)
3 Programming software on PC FANUC LADDER-IIIC FANUC LADDER-III
.cn

(Refer to Appendix B.2)


4 PMC operation software on FANUC LADDER-IIIC for Open CNC Ladder Editing Package
Open CNC (Refer to Appendix B.2)
5 Machine Remote Diagnosis PMC diagnosis functions are not available. Full functions are available.
Package (Refer to Appendix B.3)
w

Differences Concerning Application Programming


w

There are following differences in the programming and setting of


PMC sequence program and CNC customizing software.
w
://
tp
ht

- 565 -
B.DIFFERENCES BETWEEN PMC-SB7 APPENDIX B-63823EN/02

No. Items PMC-SD7 PMC-SB7


1 Programming language and Instructions are basically Refer to B-61863E
available instructions different. However, most of the (FANUC PMC-MODEL PA1/
instructions of PMC-SD7 PA3/ SA1/ SA2/ SA3/ SA5/ SB/

/
correspond the ones of SB2/ SB3/ SB4/ SB5/ SB6/

om
PMC-SB7. Sequence Program SB7/ SC/ SC3/ SC4/ NB/ NB2/
Conversion Tool NB6 Ladder Language
(A08B-9210-J525) is provided Programming Manual)
for conversion of instructions
from PMC-SB7.
Refer to B-64213EN (FANUC

s.c
PMC Program Conversion Tool
OPERATOR’S MANUAL) and
other chapters in this manual.
2 PMC program monitoring and Ladder display and edit screens Ladder display and edit screens

re
editing on CNC are not built in CNC. are built in CNC.
Use an Open CNC type display
unit running FANUC

3 Levels of PMC sequence


program
pa
LADDER-IIIC software instead.
(Refer to Appendix B.4)
Level-1 and level-2 are
available. Level-2 can cover all
In addition to level-1 and
level-2, level-3 is available.
cs
the features of level-3.
(Refer to Appendix B.5)
4 PMC setting parameter for Not supported. Supported.
.cn

“Selectable I/O Link As the assignment data can be


Assignment Function” set up for each machine, this
function is not necessary.
(Refer to Appendix B.6)
5 PMC system parameter Not supported. Supported.
w

for ”F0 Operator Panel” This function is seldom used


now.
(Refer to Appendix B.6)
w

6 PMC setting parameter for Not supported. Supported.


“Multi-language As PMC-SD7 is typically used
Alarm/Operator Message with the HMI with
w

Display Function” alarm/operator messages on


the screen implemented in
PC-based display unit, the
://

function for switching the


languages by PMC program is
not supported.
tp

(Refer to Appendix B.7)


7 C language executor library Not supported. Supported.
function for “Reading PMC Since it is rare to display PMC
ht

Message” message on the application


screen created by C language
executor in CNC with
PMC-SD7, this function is not
supported.
(Refer to Appendix B.7)

- 566 -
B-63823EN/02 APPENDIX B.DIFFERENCES BETWEEN PMC-SB7

Differently Implemented Equivalent Features


Even the equivalent functions used for the same purpose, different
implementations may have been done regarding the screen display or
operations related to the type of PMC. In case of using these functions,
please be careful.

/
om
No. Items PMC-SD7 PMC-SB7
1 Setting for Timer/Counter Neither specific screen nor Following PMC parameter
system parameter setting is screens for setting
necessary because each Timer/Counter specific address
timer/counter is programmed are to be used.

s.c
using freely assigned %R - [PMCPRM] –[TIMER] for T
address in binary type only. address
(Refer to Appendix B.8) - [PMCPRM] –[COUNTR] for C
address
PMC system parameter for

re
“Counter Data Type” is to be
set.
2 Use of MDI keys on CNC for Some punctuation characters Most of punctuation characters
PMC address and symbol
(variable name) pa
unavailable on MDI keys are
omitted or substituted. For
are interpreted as they are
entered. PMC address such as
example, IEC61131-3 compliant “X0.0” is entered as it is.
PMC address with “%” like
cs
“%I1” is to be entered as “I1”.
(Refer to Appendix B.9)
3 Display screens for FA The same option boards are Following FA network option
.cn

network board supported. boards are supported.


Note that the PMC address in - Profibus-DP
the setting or diagnosis screens - Device-Net
for these boards is displayed in - FL-Net
the PMC-SB7 address - I/O Link-II
w

representation.
(Refer to Appendix B.10)
4 Editing program “On-the-Fly” “Smart Download to PMC” of On-line editing with FANUC
w

FANUC LADDER-IIIC supports LADDER-III is supported.


the feature.
(Refer to Appendix B.11)
w

5 Protection of sub-program Each sub-program (block) is All sub-programs are protected


protected individually with by one EDIT password and one
://

Ladder Key Lock Setting. READ password.


(Refer to Appendix B.11)
tp
ht

- 567 -
B.DIFFERENCES BETWEEN PMC-SB7 APPENDIX B-63823EN/02

B.1 SUPPORT OF OPTION BOARDS

Following option boards and relevant software options are not


supported with PMC-SD7.

/
• Loader control board

om
• PMC C language board

B.2 PROGRAMMING SOFTWARE ON PC

s.c
Different programming software, FANUC LADDER-III and FANUC
LADDER-IIIC, are used for PMC-SB7 and PMC-SD7 respectively.
FANUC LADDER-III for programming PMC-SB7 does not support
PMC-SD7. Oppositely, FANUC LADDER-IIIC does not support

re
PMC-SB7. FANUC LADDER-IIIC should be solely used for
programming PMC-SD7.

pa
When the CNC system is Open CNC type, Ladder Editing Package,
which is the dedicated software for maintenance operation on CNC, is
available for PMC-SB7. In case of PMC-SD7, such dedicated
software is not provided. Instead, FANUC LADDER-IIIC for Open
cs
CNC, which is another type of software license intended for the use of
FANUC LADDER-IIIC on an Open CNC type display unit connected
with one CNC, is provided.
.cn

B.3 MACHINE REMOTE DIAGNOSIS PACKAGE


w

CNC with Ethernet interface features remote diagnosis functions. In


case of PMC-SB7, functions equivalent to FANUC LADDER-III are
integrated in the Machine Remote Diagnosis Package for the purpose
w

of remote diagnosis on PMC. In case of PMC-SD7, such functions are


not provided. If necessary, use any remote operation software in the
market to operate FANUC LADDER-IIIC running on the Open CNC
w

type CNC display unit.


://
tp
ht

- 568 -
B-63823EN/02 APPENDIX B.DIFFERENCES BETWEEN PMC-SB7

B.4 MONITORING AND EDITING ON CNC

PMC-SD7 does not support the following functions for monitoring


and editing PMC program which are available on PMC-SB7.

/
om
(1) Built-in Editing Function

The built-in editing function is not supported. Program editing is


performed using FANNUC LADDER-IIIC software on the PC.
To delete PMC data (sequence programs, PMC parameters), hold

s.c
down the following keys and turn on the system power.
Delete of sequence program: <O> + <X>
Delete of all PMC parameters: <O> + <Z>

re
(2) Debugging Function

Debugging functions other than the online function (ONLINE) are

B.5 LEVEL3
not supported.
pa
cs
The 3rd level program was originally intended to execute low-priority
program, which does not require critical response for the machine
.cn

control, to reduce the load of the 2nd level program and to shorten the
PMC execution cycle time by transferring some part of the program
from the 2nd level to the 3rd level.

In case of PMC-SB7, with which the hardware performance has been


w

highly improved, using the 2nd level is recommended and the 3rd
level is simply meant for the compatibility with existing ladder
w

programs created in the 3rd level for older models than PMC-SB7.

In case of PMC-SD7, with which hardware performance has been


w

improved as well as PMC-SB7, the 3rd level is no longer needed for


the reason of performance. When converting 3rd level programs from
PMC-SB7 to PMC-SD7, use the 2nd level.
://
tp
ht

- 569 -
B.DIFFERENCES BETWEEN PMC-SB7 APPENDIX B-63823EN/02

B.6 MISCELLANEOUS PMC PARAMETERS

The following PMC setting parameter and PMC system parameter are
no longer supported by PMC-SD7 because they are rarely used even

/
on the PMC-SB7.

om
(1) Selectable I/O Link Assignment Function (Setting Parameter)

This function enables the common use of a sequence program for


several machines, which have different I/O device configuration

s.c
with each other, by setting the parameter to enable/disable each
group in I/O link assignment data. Typically, the configuration of
I/O devices differs for each machine and assignment data is to be set
up for each machine. Therefore, this function is not supported by

re
PMC-SD7.

(2) F0 Operator Panel (System Parameter)

pa
This setting is to support a very old type operator panel interface,
which is rarely used now. As this function is meant for the
compatibility with ladder programs created for the models before
cs
PMC-SB7, substitution of other types of operator panels are
recommended.
.cn

B.7 MISCELLANEOUS FEATURES OF MESSAGE

The following features regarding PMC alarm/operator message


display function is not supported by PMC-SD7.
w

(1) Multi-language Message Display (Setting Parameter)


w

PMC supports a message display function. In case of PMC-SB7, the


following PMC setting parameters used for PMC program to
w

determine the display language for alarm and operator message are
available. This feature for language switching by PMC setting is not
supported by PMC-SD7.
://

• MESSAGE SHIFT VALUE


• MESSAGE SHIFT START ADDRESS
tp

(2) C language executor function to read PMC message

In case of PMC-SB7, user can read the text of message data from the
ht

C language executor program by calling a C-language function


pmc_rdpcmsg(). This function is not supported by PMC-SD7.

- 570 -
B-63823EN/02 APPENDIX B.DIFFERENCES BETWEEN PMC-SB7

B.8 FEATURES OF TIMER/COUNTER

The PMC-SB7 supports screens for displaying and setting the


reference data for the timer and counter. These screens are not

/
supported by the PMC-SD7, however.

om
There is a PMC system parameter for PMC-SB7 to select the counter
data type among binary or BCD. However, this PMC system
parameter does not exist for PMC-SD7 because only the binary
counter is available.

s.c
B.9 USE OF MDI KEY FOR INPUT ON CNC

re
Programs for PMC-SD7 are mainly edited on PC with full keyboard.
When operating on CNC with MDI keyboard on which some
characters may not be unavailable, such characters are to be typed
differently.
pa
(1) IEC61131-3 address
cs
The reference addresses defined in IEC61131-3 (ex. %I, %IF, %Q)
may not be input by some type of MDI key. Input all the reference
addresses without “%” (ex. I, IF, Q), and perform a search. (Ex. For
.cn

trace address input, perform an address search using the PMCPRM


screen)

(2) Symbol or variable name


w

The limitation to input SYMBOL name is as the following.


• The small letter may not be inputted. Input the capital.
w

• The ‘_’ may not be input by MDI. Input the ‘-‘.


• The ‘$’ may not be input by MDI. Input the ‘&’.
w

B.10 FA NETWORK BOARD


://

Following FA network boards are supported by both PMC-SB7 and


PMC-SD7. Most of the boards have specific setting and diagnosis
screens on which some parameters in PMC memory address notation
tp

are shown. Even on PMC-SD7, such parameters are displayed in the


PMC-SB7 address.
ht

• Profibus-DP
• Device-Net
• FL-Net
• I/O Link-II

- 571 -
B.DIFFERENCES BETWEEN PMC-SB7 APPENDIX B-63823EN/02

B.11 EDIT ON-THE-FLY

FANUC LADDER-IIIC supports the “Smart Download to PMC”. It


works as “Editing On-the-Fly”. While the PMC is online and the PMC

/
and the FANUC LADDER-IIIC project are equal, if some logic blocks

om
are edited, the “Smart Download to PMC” transfers only the edited
blocks into the PMC on which it is running.

B.12 PASSWORD FUNCTION

s.c
A password function for protecting the PMC program is not supported
by PMC-SD7. Please use the Lock Settings for each ladder level in
FANUC LADDER-IIIC side.

re
PMC-SD7 PMC-SB7
Protection Unit Logic Block (sub-program) Whole program
Protection Type Edit Lock:
Block cannot be edited.
View Lock:
Block cannot be viewed.
pa R‐password:
To protect against reading.
RW‐password:
To protect against reading and writing.
cs
Permanent Edit Lock:
Block can never be edited.
Permanent View Lock:
.cn

Block can never be viewed in an editor.

Since PMC-SB7 only sets one or two passwords to the whole ladder
program, it is easy to handle. On the other hand, PMC-SD7 can set
various Lock Settings for each logic block. Therefore, more flexible
w

protection can be allowed.


w

NOTE
Neither of the PMC-SD7 and PMC-SB7 can set a
password / Lock Settings to the I/O link assignment
w

data, message data, and symbol data.


://
tp
ht

- 572 -
B-63823EN/02 APPENDIX C.ALARM MESSAGE LIST

C ALARM MESSAGE LIST

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 573 -
C.ALARM MESSAGE LIST APPENDIX B-63823EN/02

C.1 PMC ALARMS/SYSTEM ALARMS

Alarm number Faulty location/corrective action Contents


ER01 PROGRAM DATA ERROR 1) Re-input the sequence program. The sequence program is invalid.

/
2) Replace the master printed

om
circuit board.
ER02 PROGRAM SIZE OVER 1) Reduce the sequence program. The sequence program is too large.
2) Contact FANUC to have a larger The sequence program is invalid.
number-of-Ladder-steps option
specified.

s.c
ER03 PROGRAM SIZE ERROR 1) Reduce the sequence program. The sequence program exceeds the size
(OPTION) 2) Contact FANUC to have a larger specified by the number-of-Ladder-steps
number-of-Ladder-steps option option.
specified.

re
ER04 PMC TYPE UNMATCH Using an offline programmer, The setting of the type in the sequence
change the sequence program to program differs from the actual type.
that for the correct PMC type.
ER06 PMC CONTROL Contact FANUC to specify certain The combination of CNC system
SOFTWARE TYPE UNMATCH PMC type.
pa configuration and PMC type is invalid.
(Example: PMC-SB5 is used for a 3-path
CNC system.)
cs
ER07 NO OPTION(LADDER 1) Restore the backed up CNC No number-of-Ladder-steps option is found.
STEP) parameter data.
2) Check the data sheet and
re-input the CNC parameters.
.cn

3) Contact FANUC to specify a


number-of-Ladder-steps option
of the necessary size.
ER08 OBJECT UNMATCH 1) Contact FANUC. An unsupported function is used in the
sequence program.
w

ER09 PMC LABEL CHECK 1) Press and hold down the ’O’ With a change in the PMC type, for example,
ERROR and ’Z’ key combination, and turn the retention-type memory of the PMC must
PLEASE TURN ON POWER the CNC back on. be initialized.
w

AGAIN WITH PUSH ’O’&’Z’. 2) Replace the backup battery.


(CLEAR PMC SRAM) 3) Replace the master printed
circuit board.
w

ER10 OPTION AREA NOTHING Contact FANUC to reconfigure the The PMC management software is not
(xxxx) PMC management software. loaded correctly.
://

ER11 OPTION AREA Contact FANUC to reconfigure the The PMC C board management software is
NOTHING(xxxx) PMC management software. not loaded correctly.
ER12 OPTION AREA Contact FANUC to reconfigure the The PMC management software is invalid.
ERROR(xxxx) PMC management software. (The series of BASIC and OPTION do not
tp

match.)
ER13 OPTION AREA Contact FANUC to reconfigure the The PMC C board management software is
ERROR(xxxx) PMC management software. invalid.
ht

(The series of BASIC and OPTION do not


match.)
ER14 OPTION AREA VERSION Contact FANUC to reconfigure the The PMC management software is invalid.
ERROR (xxxx) PMC management software. (The editions of BASIC and OPTION do not
match.)
ER15 OPTION AREA VERSION Contact FANUC to reconfigure the The PMC C board management software is
ERROR (xxxx) PMC management software. invalid.
(The editions of BASIC and OPTION do not
match.)

- 574 -
B-63823EN/02 APPENDIX C.ALARM MESSAGE LIST

Alarm number Faulty location/corrective action Contents


ER16 RAM CHECK ERROR Replace the master printed circuit The initialization of the memory used to
(PROGRAM RAM) board. store the sequence program failed.
ER17 PROGRAM PARITY 1) Re-input the sequence program. The parity of the sequence program is
2) Replace the master printed invalid.

/
circuit board.

om
ER18 PROGRAM DATA ERROR Re-input the sequence program. While the sequence program was being
BY I/O read, an interrupt command was generated.
ER22 PROGRAM NOTHING 1) Re-input the sequence program. The sequence program is empty.
2) Replace the master printed
circuit board.

s.c
ER23 PLEASE TURN OFF Turn the CNC off and then back on. With a change in the PMC type, for example,
POWER the power must be turned off and then back
on.
ER25 SOFTWARE VERSION Contact FANUC to reconfigure the The PMC management software is invalid.
ERROR (PMCAOPT) PMC management software. (The edition of PMCAOPT does not match.)

re
ER26 PMC CONTROL MODULE 1) Contact FANUC to reconfigure The initialization of the PMC management
ERROR(PMCAOPT) the PMC management software. software failed.
2) 2) Replace the master printed

ER32 NO I/O DEVICE


circuit board.
pa
1) Check that the I/O device is on. An I/O device such as the I/O Link,
2) Check that the I/O device was connection unit, and Power Mate is not
cs
turned on before the CNC was connected.
turned on.
3) Check the connection of the
cable.
.cn

ER33 I/O LINK ERROR Replace the master printed circuit The LSI of the I/O Link is defective.
board.
ER34 I/O LINK ERROR (xx) 1) Check the connection of the In a slave in group xx, an error occurred in
cable leading to a device in communication with an I/O device.
group xx.
w

2) Check that the I/O device was


turned on before the CNC.
3) Replace that device in group xx
w

in which the PMC control module


is installed.
w

ER35 TOO MUCH OUTPUT DATA Reduce the amount of output data in The amount of output data in I/O Link group
IN GROUP (xx) group xx. xx exceeds the limit (33 bytes). The excess
data is nullified.
://

ER36 TOO MUCH INPUT DATA IN Reduce the amount of input data in The amount of input data in I/O Link group
GROUP (xx) group xx. xx exceeds the limit (33 bytes). The excess
data is nullified.
ER38 MAX SETTING OUTPUT Modify the total amount of output The I/O Link I/O area is insufficient.
tp

DATA OVER (xx) data in each group to 128 bytes or (The allocation of any group after group xx
less. on the output side is nullified.)
ER39 MAX SETTING INPUT DATA Modify the total amount of input data The I/O Link I/O area is insufficient.
ht

OVER (xx) in each group to 128 bytes or less. (The allocation of any group after group xx
on the input side is nullified.)
ER40 I/O LINK-II SETTING Reconfigure the I/O Link-II. The I/O Link-II setting is invalid.
ERROR (CHx) (CH1: Primary board, CH2: Secondary
board)
ER41 I/O LINK-II MODE Reconfigure the I/O Link-II. The I/O Link-II mode setting is invalid.
ERROR(CHx) (CH1: Primary board, CH2: Secondary
board)

- 575 -
C.ALARM MESSAGE LIST APPENDIX B-63823EN/02

Alarm number Faulty location/corrective action Contents


ER42 I/O LINK-II STATION Reconfigure the I/O Link-II. The I/O Link-II station number setting is
NO.ERROR (CHx) invalid.
(CH1: Primary board, CH2: Secondary
board)
ER97 I/O LINK FAILURE 1) Check whether the cables of I/O The number of assigned I/O modules in

/
devices in group yy are connected group yy differs from that of I/O devices

om
(CHx yyGROUP)
properly. actually connected.
2) Check the power to each I/O
device.
3) Check the parameter setting of
the I/O link assignment data

s.c
selection function.
WN02 OPERATE ADDRESS Modify the setting of the PMC The setting of the PMC system parameter,
ERROR system parameter, address of the address of the operator’s panel for Series 0,
operator’s panel for Series 0. is invalid.

re
WN03 ABORT NC-WINDOW/EXIN 1) Check that the Ladder program The Ladder program was stopped during
is free from problems and then communication between the CNC and PMC.
restart the Ladder program (by Function instructions such as WINDR,
pressing the RUN key). WINDW, EXIN, and DISPB may not be

WN05 PMC TYPE NO


on. pa
2) Turn the CNC off and then back

Using an offline programmer,


executed normally.

The setting of the type in the sequence


cs
CONVERSION change the sequence program to program differs from the actual type.
that for the correct PMC type. (Example: For the PMC-SB5, the Ladder
program of the PMC-SA3/SA5 was
transferred.)
.cn

WN06 TASK STOPPED BY To restart a user task that has been When a PMC C board is used, a user task
DEBUG FUNC stopped, stop the sequence program has been stopped due to a break by a debug
and then execute it again. function.
WN07 LADDER SP ERROR Modify the sequence program so For a subprogram call with the function
(STACK) that the subprogram nesting level is instruction CALL or CALLU, the nesting level
w

eight or less. is too deep (exceeds 8).


w
w
://
tp
ht

- 576 -
B-63823EN/02 APPENDIX C.ALARM MESSAGE LIST

C.2 PMC SYSTEM ALARM MESSAGES

Alarm number Faulty location/corrective action Contents


PC004 CPU ERR xxxxxxxx:yyyyyyyy 1) Replace the master printed A CPU error occurred in the PMC.

/
PC006 CPU ERR xxxxxxxx:yyyyyyyy circuit board. xxxxxxxx and yyyyyyyyy are internal error

om
PC009 CPU ERR xxxxxxxx:yyyyyyyy 2) If the error recurs even after the codes.
PC010 CPU ERR xxxxxxxx:yyyyyyyy
replacement, contact FANUC to
PC012 CPU ERR xxxxxxxx:yyyyyyyy report the status (displayed
message, system configuration,
operation, when the error occurs,
occurrence frequency, etc.).

s.c
PC030 RAM PARITY aa:bb 1) Replace the master printed A RAM parity error occurred in the PMC.
circuit board. aa and bb are internal error codes.
2) If the error recurs even after the
replacement, contact FANUC to

re
report the status (displayed
message, system configuration,
operation, when the error occurs,
occurrence frequency, etc.) and

PC050 NMI SLC aa:bb


PC050 I/O LINK(CH1) aa:bb
aa:bb
pa
the above internal error codes.
1) Check that the I/O allocation data A communication error occurred in the I/O
matches the actual I/O device LINK.
connection. aa, bb and cc are internal error codes.
cs
PC050 IOLINK CH1 2) Check that the cable is If this alarm is generated, probable causes
connected properly. include the following:
aaaa-bbbb:cccc
3) Check the cable specifications. 1) Although the base expansion is assigned
when the I/O Unit A is used, the base is
.cn

4) Replace the I/O device interface


not connected.
module, cable, master printed
circuit board, etc. 2) A cable is not connected securely.
3) Cabling is faulty.
4) I/O equipment (I/O unit, Power Mate, etc.)
is faulty.
w

5) Power failure of Master or Slave device


on I/O Link
w

6) Short circuit of DO terminal on I/O device


7) The motherboard is faulty.
PC060 FBUS xxxxxxxx:yyyyyyyy 1) Replace the master printed A bus error occurred in the PMC.
w

PC061 FL-R xxxxxxxx:yyyyyyyy circuit board.


2) If the error recurs even after the
replacement, contact FANUC to
://

report the status (displayed


message, system configuration,
operation, when the error occurs,
occurrence frequency, etc.).
tp

PC070 SUB65 CALL (STACK) Check the correspondence between A stack error occurred in Ladder function
the CALL/CALLU and SPE instruction CALL/CALLU.
instructions.
ht

PC090 NMI(___) xxxxxxxx:yyyyyyyy 1) Replace the master printed An NMI with an unknown cause occurred in
circuit board. the PMC management software.
2) If the error recurs even after the
replacement, contact FANUC to
report the status (displayed
message, system configuration,
operation, when the error occurs,
occurrence frequency, etc.).

- 577 -
C.ALARM MESSAGE LIST APPENDIX B-63823EN/02

Alarm number Faulty location/corrective action Contents


PC092 USER TRAP 1) Replace the master printed The TRAP instruction, which is not used in
aa:xxxxxxxx circuit board. the PMC management software, was
2) If the error recurs even after the executed.
replacement, contact FANUC to
report the status (displayed

/
message, system configuration,

om
operation, when the error occurs,
occurrence frequency, etc.).
PC093 INT(SYS) 1) Replace the master printed An interrupt with an unknown cause
xxxxxxxx:yyyyyyyy circuit board. occurred in the PMC management software.
PC094 INT(TRAP) 2) If the error recurs even after the

s.c
xxxxxxxx:yyyyyyyy replacement, contact FANUC to
PC095 INT(EX) report the status (displayed
xxxxxxxx:yyyyyyyy message, system configuration,
PC096 INT(IN) xxxxxxxx:yyyyyyyy operation, when the error occurs,
occurrence frequency, etc.).

re
PC087 PARITY ERR (LADDER-2) 1) Replace the master printed An error occurred in a RAM check.
PC097 PARITY ERR (LADDER) circuit board.
PC098 PARITY ERR (DRAM) 2) If the error recurs even after the

pa
replacement, contact FANUC to
report the status (displayed
message, system configuration,
operation, when the error occurs,
occurrence frequency, etc.).
cs
PC501 NC/PMC INTERFACE ERR 1) Replace the master printed The reading/writing of signals between the
PATH_ circuit board. CNC and the PMC failed.
2) If the error recurs even after the
.cn

replacement, contact FANUC to


report the status (displayed
message, system configuration,
operation, when the error occurs,
occurrence frequency, etc.).
w

PC502 ILLEGAL FUNCTION (SUB Modify the sequence program so Unsupported function instruction xx is used.
xx) that instruction function xx is not
used.
w
w
://
tp
ht

- 578 -
B-63823EN/02 APPENDIX D.CHINESE CHARACTER CODE, HIRAGANA CODE, AND SPECIAL CODE LIST

D CHINESE CHARACTER CODE,

/
HIRAGANA CODE, AND SPECIAL CODE

om
LIST
When coding kanji character in message data, please used 4 digits of

s.c
hexadecimal in ‘JIS” column in the following table.

re
pa
cs
.cn
w
w
w
://
tp
ht

- 579 -
D.CHINESE CHARACTER CODE, HIRAGANA CODE, AND SPECIAL CODE LIST APPENDIX B-63823EN/02

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 580 -
B-63823EN/02 APPENDIX D.CHINESE CHARACTER CODE, HIRAGANA CODE, AND SPECIAL CODE LIST

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 581 -
D.CHINESE CHARACTER CODE, HIRAGANA CODE, AND SPECIAL CODE LIST APPENDIX B-63823EN/02

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 582 -
B-63823EN/02 APPENDIX D.CHINESE CHARACTER CODE, HIRAGANA CODE, AND SPECIAL CODE LIST

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 583 -
D.CHINESE CHARACTER CODE, HIRAGANA CODE, AND SPECIAL CODE LIST APPENDIX B-63823EN/02

/
om
s.c
re
pa
cs
.cn
w
w
w
://
tp
ht

- 584 -
B-63823EN/02 INDEX

INDEX
Assignment Method for I/O Unit-MODEL B .................37
<A>
Assignment Method for the Power Mate.........................47
ABS_(type) ..................................................................... 76
AXCTL .........................................................................255

/
ABS_DINT(in).............................................................. 180

om
AXIS INFORMATION.................................................400
ABS_INT(in) ................................................................ 180
ABS_SINT(in) .............................................................. 180 <B>
Absolute ........................................................................ 180 BASIC INSTRUCTIONS .............................................159
Add................................................................................ 170 BCD2_TO_SINT(operand) ...........................................236

s.c
Add BCD....................................................................... 245 BCD2_TO_USINT(operand) ........................................236
ADD_(type)/SUB_(type)/MUL_(type)/DIV_(type) ....... 72 BCD4_TO_INT(operand) .............................................236
ADD_DINT(in1, in2).................................................... 170 BCD4_TO_UINT(operand) ..........................................236
ADD_INT(in1, in2)....................................................... 170 BCD8_TO_DINT(operand) ..........................................236

re
ADD_SINT(in1, in2) .................................................... 170 BCD8_TO_UDINT(operand)........................................237
ADD_UDINT(in1, in2) ................................................. 171 BCDx_TO_(type) (x = 2, 4, 8) ......................................123
ADD_UINT(in1, in2).................................................... 170
ADD_USINT(in1, in2).................................................. 170
ALARM MESSAGE LIST ........................................... 573
paBCDx_TO_(type)(x=2,4,8) ...........................................236
BIT OPERATIONS.........................................................85
Bit Position....................................................................212
cs
Alarm Screen (ALARM)............................................... 272 Bit Sequencer ................................................................213
AND_(type)/OR_(type) .................................................. 86 Bit Set, Clear .................................................................210
AND_BYTE(in1, in2)................................................... 201 Bit Test.......................................................................... 209
.cn

AND_DWORD(in1, in2) .............................................. 201 BIT_CLR_BYTE(in, bit, length) ..................................210


AND_WORD(in1, in2) ................................................. 201 BIT_CLR_DWORD(in, bit, length)..............................211
Array Move ................................................................... 226 BIT_CLR_WORD(in, bit, length).................................210
ARRAY_MOVE_(type)................................................ 115 BIT_POS_(type) .............................................................99
w

ARRAY_MOVE_BOOL(sr, snx, dnx, n, length, ds) .... 228 BIT_POS_BYTE(in, length) .........................................212
ARRAY_MOVE_BYTE(sr, snx, dnx, n, length, ds)..... 229 BIT_POS_DWORD(in, length) ....................................212
w

ARRAY_MOVE_DINT(sr, snx, dnx, n, length, ds) ..... 227 BIT_POS_WORD(in, length) .......................................212
ARRAY_MOVE_DWORD(sr, snx, dnx, n, length, ds) 230 BIT_SEQ.......................................................................101
ARRAY_MOVE_INT(sr, snx, dnx, n, length, ds) ........ 227 BIT_SEQ(address, r, dir, n, st, length) ..........................213
w

ARRAY_MOVE_SINT(sr, snx, dnx, n, length, ds) ...... 226 BIT_SET_(type)/BIT_CLR_(type) .................................97


ARRAY_MOVE_UDINT(sr, snx, dnx, n, length, ds)... 228 BIT_SET_BYTE(in, bit, length) ...................................210
://

ARRAY_MOVE_UINT(sr, snx, dnx, n, length, ds) ..... 227 BIT_SET_DWORD(in, bit, length) ..............................210
ARRAY_MOVE_USINT(sr, snx, dnx, n, length, ds) ... 226 BIT_SET_WORD(in, bit, length) .................................210
ARRAY_MOVE_WORD(sr, snx, dnx, n, length, ds)... 229 BIT_TEST_(type) ...........................................................95
tp

ASSIGNMENT METHOD ............................................. 26 BIT_TEST_BYTE(in, bit, length).................................209


Assignment Method for a Handy Machine Operator's BIT_TEST_DWORD(in, bit, length) ............................209
ht

Panel................................................................................ 50 BIT_TEST_WORD(in, bit, length) ...............................209


Assignment Method for an AS-i Converter Unit............. 52 BLK_CLR_(type) .........................................................110
Assignment Method for Distribution I/O Connection BLK_CLR_BYTE(in, length) .......................................221
Panel I/O Unit and Distribution I/O Operator's Panel BLK_CLR_DINT(in, length) ........................................221
I/O Units.......................................................................... 40 BLK_CLR_DWORD(in, length) ..................................222
Assignment Method for I/O Link Connection Units ....... 48 BLK_CLR_INT(in, length)...........................................220
Assignment Method for I/O Unit-MODEL A ................. 34 BLK_CLR_SINT(in, length).........................................220

i-1
INDEX B-63823EN/02

BLK_CLR_UDINT(in, length) ..................................... 221 DISPLAYING AND SETTING THE PMC


BLK_CLR_UINT(in, length)........................................ 220 PARAMETERS (PMCPRM) ........................................289
BLK_CLR_USINT(in, length)...................................... 220 DISPLAYING PMC INPUT/ OUTPUT SIGNALS
BLK_CLR_WORD(in, length) ..................................... 221 AND INTERNAL RELAY (PMCDGN).......................262

/
Block Clear ................................................................... 220 DIV_DINT(in1, in2) .....................................................177

om
DIV_INT(in1, in2) ........................................................176
<C>
DIV_SINT(in1, in2) ......................................................176
CALL ............................................................................ 138
DIV_UDINT(in1, in2)...................................................177
Check Even Parity......................................................... 253
DIV_UINT(in1, in2) .....................................................176
Check Odd Parity .......................................................... 254
DIV_USINT(in1, in2) ...................................................176

s.c
CHINESE CHARACTER CODE, HIRAGANA CODE,
Divide............................................................................176
AND SPECIAL CODE LIST........................................ 579
Divide BCD...................................................................248
Clearing Tool Life Management Data (Tool Life
DNCTR ...........................................................................69
Counter and Tool Information) (Low-speed Response) 521

re
DNCTR(address, r, pv) .................................................168
CNC INFORMATION.................................................. 347
Down Counter ...............................................................168
Coils ................................................................................ 57
COMMENT .................................................................. 141
Configuration of an I/O Link .......................................... 24
CONTACTS & COILS ................................................... 56
pa
<E>
EDIT ON-THE-FLY .....................................................572
END ..............................................................................138
cs
CONTENTS OF THIS MANUAL....................................4 Entering Data on the Program Check Screen
Continuous Contacts & Continuous Coils....................... 59 (Low-speed Response) ..................................................394
Entering Torque Limit Data for the Digital Servo
.cn

<D>
Motor (Low-speed Response) .......................................425
DATA MOVE............................................................... 106
EQ_(type)/NE_(type) ......................................................79
DATA TABLE FUNCTIONS....................................... 114
EQ_BYTE(in1, in2) ......................................................185
DATA TYPE CONVERSION ...................................... 120
EQ_DINT(in1, in2) .......................................................185
w

DATA TYPES ..................................................................9


EQ_DWORD(in1, in2)..................................................186
Decode .......................................................................... 251
EQ_INT(in1, in2) ..........................................................184
DEFINITION OF WARNING, CAUTION, AND
w

EQ_SINT(in1, in2)........................................................184
NOTE............................................................................. s-1
EQ_UDINT(in1, in2) ....................................................185
Deleting Tool life Management Data (Tool Data)
w

EQ_UINT(in1, in2) .......................................................184


(Low-speed Response) .................................................. 519
EQ_USINT(in1, in2).....................................................184
Deleting Tool life Management Data (Tool Group)
EQ_WORD(in1, in2) ....................................................185
://

(Low-speed Response) .................................................. 517


Equal .............................................................................184
Deletion of a Tool Management Data (Low-speed
Exchange of Tool Management Data Numbers in a
Response) ...................................................................... 545
tp

Magazine Management Table (Low-speed Response) ..528


DIFFERENCES BETWEEN PMC-SB7 ....................... 565
EXIN .............................................................................255
DINT_TO_BCD8(operand) .......................................... 235
<F>
ht

DINT_TO_INT(operand).............................................. 240
DINT_TO_SINT(operand)............................................ 238 F_TRIG(in) ...................................................................250
DINT_TO_UDINT(operand) ........................................ 243 FA NETWORK BOARD ..............................................571
DINT_TO_UINT(operand) ........................................... 241 FEATURES OF TIMER/COUNTER ...........................571
DINT_TO_USINT(operand)......................................... 239 Floppy List Screen ........................................................324
Displaying and Setting the Configuration Status of Forced Termination of Sequence Program....................311
I/O Devices (I/OCHK) .................................................. 285 FORMATS OF CONTROL DATA ..............................336

i-2
B-63823EN/02 INDEX

<G> LE_INT(in1, in2) ..........................................................196


GE_DINT(in1, in2) ....................................................... 193 LE_SINT(in1, in2) ........................................................196
GE_INT(in1, in2).......................................................... 192 LE_UDINT(in1, in2).....................................................197
GE_SINT(in1, in2)........................................................ 192 LE_UINT(in1, in2)........................................................197
GE_UDINT(in1, in2) .................................................... 193

/
LE_USINT(in1, in2) .....................................................196
GE_UINT(in1, in2) ....................................................... 192

om
Less or Equal.................................................................196
GE_USINT(in1, in2)..................................................... 192 Less Than ......................................................................194
Greater or Equal ............................................................ 192 LEVEL3 ........................................................................569
Greater Than ................................................................. 190 LIST OF WINDOW FUNCTIONS...............................341
GT_(type)/GE_(type)/LT_(type)/LE_(type) ................... 81 Logical AND.................................................................201

s.c
GT_DINT(in1, in2) ....................................................... 191 Logical NOT .................................................................204
GT_INT(in1, in2).......................................................... 190 Logical OR.................................................................... 202
GT_SINT(in1, in2)........................................................ 190 Logical XOR .................................................................203

re
GT_UDINT(in1, in2) .................................................... 191 LOW-SPEED RESPONSE AND HIGH-SPEED
GT_UINT(in1, in2) ....................................................... 191 RESPONSE...................................................................339
GT_USINT(in1, in2)..................................................... 190 LT_DINT(in1, in2)........................................................195

<I>
I/O LINK......................................................................... 22
pa
LT_INT(in1, in2) ..........................................................194
LT_SINT(in1, in2) ........................................................194
LT_UDINT(in1, in2).....................................................195
cs
I/O LINK CONNECTION CHECK FUNCTION........... 54
LT_UINT(in1, in2)........................................................195
I/O Screen ..................................................................... 312
LT_USINT(in1, in2) .....................................................194
I/O Screen Error Messages............................................ 329
.cn

IL BIT OPERATIONS.................................................. 200 <M>


IL CONVERSIONS ...................................................... 234 MACHINE REMOTE DIAGNOSIS PACKAGE .........568
IL DATA MOVE FUNCTIONS ................................... 216 MASK_COMP_(type)...................................................103
IL DATA TABLE FUNCTIONS.................................. 225 MASK_COMP_BYTE(in1, in2, m, bit, length, q, bn) ..214
w

IL INSTRUCTIONS ..................................................... 158 MASK_COMP_DWORD


IL MATH FUNCTIONS ............................................... 169 (in1, in2, m, bit, length, q, bn).......................................215
w

IL PMC OPERATIONS................................................ 244 MASK_COMP_WORD


IL RELATIONAL FUNCTIONS.................................. 183 (in1, in2, m, bit, length, q, bn).......................................214
IL TIMERS & COUNTERS ......................................... 161
w

Masked Compare...........................................................214
Input PMC Parameters from MDI Panel ....................... 289 MATH OPERATIONS ...................................................71
INT_TO_BCD4(operand) ............................................. 235 MCR/ENDMCR/MCRN/ENDMCRN ..........................139
://

INT_TO_DINT(operand).............................................. 242 Memory Card List Screen .............................................318


INT_TO_SINT(operand) .............................................. 238 Message Display Reference ............................................16
INT_TO_UDINT(operand) ........................................... 243
tp

MISCELLANEOUS FEATURES OF MESSAGE .......570


INT_TO_UINT(operand).............................................. 241 MISCELLANEOUS PMC PARAMETERS .................570
INT_TO_USINT(operand)............................................ 239 Mnemonics....................................................................231
ht

MOD_(type)....................................................................74
<J>
MOD_DINT(in1, in2) ...................................................179
JUMPN.......................................................................... 140
MOD_INT(in1, in2) ......................................................178
<L> MOD_SINT(in1, in2)....................................................178
LABELN....................................................................... 141 MOD_UDINT(in1, in2) ................................................179
LD INSTRUCTION GROUP.......................................... 55 MOD_UINT(in1, in2) ...................................................178
LE_DINT(in1, in2) ....................................................... 197 MOD_USINT(in1, in2) .................................................178

i-3
INDEX B-63823EN/02

Modulus ........................................................................ 178 Note on the Programming of a Low-speed Response


Modulus BCD ............................................................... 249 Window Instruction.......................................................340
MONITORING AND EDITING ON CNC................... 569 Numbers of Input Points and of Output Points of
Move Data..................................................................... 217 the I/O Link.....................................................................25

/
MOVE_(type) ............................................................... 107
<O>

om
MOVE_BOOL(in, length, q)......................................... 218
OFDT ..............................................................................65
MOVE_BYTE(in, length, q) ......................................... 218
OFDT_HUNDS(address, pv) ........................................162
MOVE_DINT(in, length, q).......................................... 217
OFDT_MIN(address, pv) ..............................................163
MOVE_DWORD(in, length, q) .................................... 218
OFDT_SECS(address, pv) ............................................162
MOVE_INT(in, length, q)............................................. 217

s.c
OFDT_TENSEC(address, pv).......................................163
MOVE_SINT(in, length, q) .......................................... 217
OFDT_TENTHS(address, pv).......................................162
MOVE_UDINT(in, length, q) ....................................... 218
OFDT_THOUS(address, pv).........................................162
MOVE_UINT(in, length, q).......................................... 217
Off Delay Timer............................................................162

re
MOVE_USINT(in, length, q)........................................ 217
On Delay Stopwatch Timer...........................................164
MOVE_WORD(in, length, q) ....................................... 218
On Delay Timer.............................................................166
MUL_DINT(in1, in2).................................................... 175
MUL_INT(in1, in2) ...................................................... 174
MUL_SINT(in1, in2) .................................................... 174
MUL_UDINT(in1, in2)................................................. 175
paONDTR...........................................................................61
ONDTR_HUNDS(address, r, pv)..................................164
ONDTR_MIN(address, r, pv)........................................165
cs
ONDTR_SECS(address, r, pv)......................................164
MUL_UINT(in1, in2).................................................... 174
ONDTR_TENSEC(address, r, pv) ................................165
MUL_USINT(in1, in2) ................................................. 174
ONDTR_TENTHS(address, r, pv) ................................164
.cn

Multiply......................................................................... 174
ONDTR_THOUS(address, r, pv) ..................................164
Multiply BCD ............................................................... 247
Operands .......................................................................233
<N> Operation.......................................................................232
NE_BYTE(in1, in2) ...................................................... 188 OPERATION ................................................................257
w

NE_DINT(in1, in2) ....................................................... 188 OR_BYTE(in1, in2) ......................................................202


NE_DWORD(in1, in2).................................................. 189 OR_DWORD(in1, in2) .................................................202
w

NE_INT(in1, in2).......................................................... 187 OR_WORD(in1, in2) ....................................................202


NE_SINT(in1, in2)........................................................ 187 Outputting to and Inputting from Flash ROM...............320
w

NE_UDINT(in1, in2) .................................................... 188 Outputting to and Inputting from Floppy ......................321
NE_UINT(in1, in2) ....................................................... 187 Outputting to and Inputting from Memory Cards..........315
NE_USINT(in1, in2)..................................................... 187 Outputting to and Inputting from Other Input/Output
://

NE_WORD(in1, in2) .................................................... 188 Devices..........................................................................325


New-register of a Tool Management Data
<P>
tp

(Low-speed Response) .................................................. 533


PASSWORD FUNCTION ............................................572
Normally Close Contacts (B Contacts) ........................... 56
PMC ALARMS/SYSTEM ALARMS...........................574
Normally Open Contacts (A Contacts)............................ 56
ht

PMC BASIC CONFIGURATION ....................................3


Not Equal ...................................................................... 187
PMC Basic Menu ..........................................................259
NOT_(type)..................................................................... 90
PMC OPERATIONS.....................................................142
NOT_BYTE(operand)................................................... 204
PMC Screen Transition and Related Soft Keys.............261
NOT_DWORD(operand) .............................................. 204
PMC SYSTEM ALARM MESSAGES.........................577
NOT_WORD(operand) ................................................. 204
PMC_ADD_BCD2(in1, in2).........................................245
NOTE ON IL PROGRAMMING ................................. 256
PMC_ADD_BCD4(in1, in2).........................................245
NOTE ON LD PROGRAMMING ................................ 157

i-4
B-63823EN/02 INDEX

PMC_ADD_BCD8(in1, in2)......................................... 245 R_TRIG/F_TRIG ..........................................................147


PMC_ADD_BCDx/PMC_SUB_BCDx/ Range ............................................................................198
PMC_MUL_BCDx/ PMC_DIV_BCDx (x = 2, 4, 8) .... 143 RANGE_(type) ...............................................................83
PMC_AXCTL ............................................................... 155 RANGE_DINT(l1, l2, in)..............................................199

/
PMC_AXCTL(r, grp, cmd, dt1, dt2, err) ...................... 255 RANGE_INT(l1, l2, in) ................................................198

om
PMC_DECODE_(type)................................................. 148 RANGE_SINT(l1, l2, in) ..............................................198
PMC_DECODE_DINT(in, base, n, q) .......................... 252 RANGE_UDINT(l1, l2, in)...........................................199
PMC_DECODE_INT(in, base, n, q)............................. 251 RANGE_UINT(l1, l2, in)..............................................198
PMC_DECODE_SINT(in, base, n, q)........................... 251 RANGE_USINT(l1, l2, in) ...........................................198
PMC_DECODE_UDINT(in, base, n, q) ....................... 252 Reading a Custom Macro Variable

s.c
PMC_DECODE_UINT(in, base, n, q) .......................... 252 (High-speed Response)..................................................365
PMC_DECODE_USINT(in, base, n, q)........................ 251 Reading a Decimal Point of the Customizing Data
PMC_DIV_BCD2(in1, in2) .......................................... 248 (Low-speed Response) ..................................................559

re
PMC_DIV_BCD4(in1, in2) .......................................... 248 Reading a Parameter (High-speed Response)................357
PMC_DIV_BCD8(in1, in2) .......................................... 248 Reading a Skip Position (Stop Coordinates of Skip
PMC_EVPAR_(type)/PMC_ODPAR_(type)................ 150 Operation (G31)) of Controlled Axes
PMC_EVPAR_BYTE(in1) ........................................... 253
PMC_EVPAR_DWORD(in1)....................................... 253
PMC_EVPAR_WORD(in1).......................................... 253
pa
(High-speed Response)..................................................407
Reading a Tool Management Data
(Low-speed Response) ..................................................547
cs
PMC_EXIN................................................................... 153 Reading a Tool Offset (High-speed Response) .............349
PMC_EXIN(head, cmd, dt, err) .................................... 255 Reading a Total Life Data (Low-speed Response)........563
.cn

PMC_MOD_BCD2(in1, in2) ........................................ 249 Reading a Workpiece Origin Offset Value


PMC_MOD_BCD4(in1, in2) ........................................ 249 (High-speed Response)..................................................353
PMC_MOD_BCD8(in1, in2) ........................................ 249 Reading Actual Spindle Speeds (High-speed Response)421
PMC_MOD_BCDx (x = 2, 4, 8) ................................... 145 Reading Clock Data (Date and Time) (High-speed
w

PMC_MUL_BCD2(in1, in2)......................................... 247 Response) ......................................................................396


PMC_MUL_BCD4(in1, in2)......................................... 247 Reading CNC Status Information
PMC_MUL_BCD8(in1, in2)......................................... 247 (High-speed Response)..................................................389
w

PMC_ODPAR_BYTE(in1)........................................... 254 Reading CNC System Information


PMC_ODPAR_DWORD(in1) ...................................... 254 (High-speed Response)..................................................347
w

PMC_ODPAR_WORD(in1) ......................................... 254 Reading Diagnosis Data (High-speed Response) ..........383


PMC_SUB_BCD2(in1, in2).......................................... 246 Reading Fine Torque Sensing Data
://

PMC_SUB_BCD4(in1, in2).......................................... 246 (Statistical Calculation Results)


PMC_SUB_BCD8(in1, in2).......................................... 246 (High-speed Response)..................................................441
PMC_WINDOW........................................................... 151 Reading Fine Torque Sensing Data (Store Data)
tp

PMC_WINDOW(ar, n, err)........................................... 254 (High-speed Response)..................................................443


Port Setting Screen........................................................ 327 Reading Load Information of the Spindle Motor
PREFACE ......................................................................p-1 (Serial Interface) (High-speed Response)......................427
ht

Presetting the Relative Coordinate Reading Modal Data (High-speed Response)................376


(Low-speed Response) .................................................. 450 Reading Setting Data (High-speed Response)...............361
PROGRAM FLOW....................................................... 137 Reading the Absolute Position (Absolute Coordinates)
PROGRAMMING SOFTWARE ON PC...................... 568 of Controlled Axes (High-speed Response) ..................402
Reading the Acceleration/Deceleration Delay on
<R>
Controlled Axes (High-speed Response) ......................411
R_TRIG(in)................................................................... 250

i-5
INDEX B-63823EN/02

Reading the Actual Spindle Speed Reading Tool Life Management Data
(High-speed Response) ................................................. 415 (Number of Tools) (High-speed Response)...................457
Reading the Actual Velocity of Controlled Axes Reading Tool Life Management Data
(High-speed Response) ................................................. 400 (Tool Information (1): Tool Number)

/
Reading the CNC Alarm Status (8-digit tool number) (High-speed Response) ...............503

om
(High-speed Response) ................................................. 369 Reading Tool Life Management Data
Reading the Current Program Number (Tool Information (1): Tool Number)
(8-digit Program Numbers) (High-speed Response) ..... 392 (High-speed Response)..................................................471
Reading the Current Program Number Reading Tool Life Management Data
(High-speed Response) ................................................. 372 (Tool Information (2): Tool Order Number)

s.c
Reading the Current Sequence Number (High-speed Response)..................................................473
(High-speed Response) ................................................. 374 Reading Tool Life Management Data
Reading the Estimate Disturbance Torque Data (Tool Length Compensation Number (1): Tool Number)

re
(High-speed Response) ................................................. 437 (8-digit tool number) (High-speed Response) ...............507
Reading the Feed Motor Load Current Value Reading Tool Life Management Data
(A/D Conversion Data) (High-speed Response) ........... 413 (Tool Length Compensation Number (1): Tool Number)
Reading the Machine Position (Machine Coordinates)
of Controlled Axes (High-speed Response) .................. 404
Reading the Relative Position on a Controlled Axis
pa
(High-speed Response)..................................................463
Reading Tool Life Management Data
(Tool Length Compensation Number (2):
cs
(High-speed Response) ................................................. 417 Tool Order Number) (High-speed Response)................465
Reading the Remaining Travel Reading Tool Life Management Data
.cn

(High-speed Response) ................................................. 419 (Tool Life Counter) (High-speed Response) .................461
Reading the servo data of the control axes Reading Tool Life Management Data (Tool Life)
(High-speed Response) ................................................. 430 (High-speed Response)..................................................459
Reading the Servo Delay for Controlled Axes Reading Tool Life Management Data (Tool Number)
w

(High-speed Response) ................................................. 409 (High-speed Response)..................................................475


Reading The Tool Life Management Data Reading Value of the P-code Macro Variable
(Tool Group Number) (8-digit tool number) (High-speed Response)..................................................385
w

(High-speed Response) ................................................. 501 Reference Address...........................................................10


Reading The Tool Life Management Data REFERENCES................................................................10
w

(Tool Group Number) (High-speed Response) ............. 453 Registering Tool Life Management Data (Tool Group
Reading the Tool Life Management Data Number) (8-digit tool number) (Low-speed Response).505
://

(Tool Life Counter Type) (High-speed Response)........ 477 Registering Tool Life Management Data (Tool Group)
Reading Tool Life Management Data (Low-speed Response) ..................................................479
(Cutter Compensation Number (1): Tool Number) RELATIONAL OPERATIONS ......................................78
tp

(8-digit tool number) (High-speed Response) .............. 509 Reset Coil (RESET) ........................................................58
Reading Tool Life Management Data Reverse-wound Coils ......................................................57
(Cutter Radius Compensation Number (1): Tool Number) ROL_(type)/ROR_(type) ................................................93
ht

(High-speed Response) ................................................. 467 ROL_BYTE(in, n, length, q).........................................207


Reading Tool Life Management Data ROL_DWORD(in, n, length, q) ....................................207
(Cutter Radius Compensation Number (2): ROL_WORD(in, n, length, q) .......................................207
Tool Order Number) (High-speed Response)............... 469 ROR_BYTE(in, n, length, q).........................................207
Reading Tool Life Management Data ROR_DWORD(in, n, length, q) ....................................208
(Number of Tool Groups) (High-speed Response)........ 455 ROR_WORD(in, n, length, q).......................................208

i-6
B-63823EN/02 INDEX

Rotate Bits..................................................................... 207 SQRT_(type) ...................................................................77


SQRT_DINT(in) ...........................................................181
<S>
SQRT_INT(in) ..............................................................181
Search for Values in a Memory Block .......................... 231
SQRT_SINT(in) ............................................................181
Search of empty pot (Low-speed Response) ................. 531

/
SQRT_UDINT(in) ........................................................182
Search of Empty Pot for Oversize Tool Use

om
SQRT_UINT(in) ...........................................................181
(Low-speed Response) .................................................. 561
SQRT_USINT(in) .........................................................181
Search of Tool Management Data
Square Root...................................................................181
(Low-speed Response) .................................................. 555
Starting and Stopping a Sequence Program ..................311
SEARCH_EQ_(type)/SEARCH_NE_(type)/
SUB_DINT(in1, in2).....................................................173

s.c
SEARCH_GT_(type)/SEARCH_GE_(type)/
SUB_INT(in1, in2)........................................................172
SEARCH_LT_(type)/SEARCH_LE_(type).................. 117
SUB_SINT(in1, in2) .....................................................172
SEQUENCE PROGRAM EXECUTION...................... 311
SUB_UDINT(in1, in2)..................................................173
Setting and Display Screen ........................................... 291

re
SUB_UINT(in1, in2).....................................................172
Setting Coil (SET)........................................................... 57
SUB_USINT(in1, in2)...................................................172
Setting Screen (SETING).............................................. 296
Subtract .........................................................................172
SHFR_(type) ................................................................. 112
SHFR_BIT(r, in, st, length, q)....................................... 223
SHFR_BYTE(r, in, st, length, q)................................... 223
paSubtract BCD ................................................................246
SUPPORT OF OPTION BOARDS...............................568
Swap Data .....................................................................219
cs
SHFR_DWORD(r, in, st, length, q) .............................. 224
SWAP_(type) ................................................................109
SHFR_WORD(r, in, st, length, q) ................................. 223
SWAP_DWORD(in, length, q) .....................................219
Shift Bits ....................................................................... 205
.cn

SWAP_WORD(in, length, q) ........................................219


Shift Register................................................................. 223
SYSTEM CONFIGURATION..........................................2
Shifting Tool Management Data
System References ..........................................................13
(Low-speed Response) .................................................. 557
SHIFTL_(type)/SHIFTR_(type) ..................................... 91 <T>
w

SHIFTL_BYTE(in, n, length, b1, q) ............................. 205 The Note about the Address Used for Control Data......337
SHIFTL_DWORD(in, n, length, b1, q)......................... 205 TIMERS & COUNTERS ................................................60
w

SHIFTL_WORD(in, n, length, b1, q)............................ 205 Title Data Display (TITLE)...........................................262


SHIFTR_BYTE(in, n, length, b1, q) ............................. 205 TMR ................................................................................63
w

SHIFTR_DWORD(in, n, length, b1, q) ........................ 206 TMR_HUNDS(address, pv) ..........................................166


SHIFTR_WORD(in, n, length, b1, q) ........................... 206 TMR_MIN(address, pv)................................................167
Signal Status Display (STATUS).................................. 263 TMR_SECS(address, pv) ..............................................166
://

SINT_TO_BCD2(operand) ........................................... 235 TMR_TENSEC(address, pv).........................................167


SINT_TO_DINT(operand)............................................ 242 TMR_TENTHS(address, pv) ........................................166
tp

SINT_TO_INT(operand) .............................................. 240 TMR_THOUS(address, pv) ..........................................166


SINT_TO_UDINT(operand)......................................... 243 TOOL LIFE MANAGEMENT FUNCTION ................453
SINT_TO_UINT(operand)............................................ 241 TOOL MANAGEMENT FUNCTIONS .......................527
ht

SINT_TO_USINT(operand) ......................................... 239 Trace Screen (TRACE) .................................................273


SOFT KEY-BASED PMC MENU SELECTION Trigger...........................................................................250
PROCEDURE ............................................................... 259 (type)_TO_BCDx (x = 2, 4, 8) ......................................121
SPECIFICATIONS ...........................................................5 (type)_TO_BCDx(x=2,4,8) ...........................................235
SPECIFICATIONS OF PMC............................................6 (type)_TO_DINT ..........................................................133
Specifying the Number of the Program for I/O (type)_TO_DINT ..........................................................242
Link(Low-speed Response)........................................... 398 (type)_TO_INT .............................................................129

i-7
INDEX B-63823EN/02

(type)_TO_INT ............................................................. 240 Writing a Workpiece Origin Offset Value


(type)_TO_SINT ........................................................... 125 (Low-speed Response) ..................................................355
(type)_TO_SINT ........................................................... 238 Writing each Tool Data (Low-speed Response)............551
(type)_TO_UDINT ....................................................... 135 Writing Setting Data (Low-speed Response) ................363

/
(type)_TO_UDINT ....................................................... 243 Writing the Tool Life Management Data

om
(type)_TO_UINT .......................................................... 131 (Tool Information (1): Tool Number)
(type)_TO_UINT .......................................................... 241 (8-digit tool number) (Low-speed Response)................515
(type)_TO_USINT ........................................................ 127 Writing the Tool Life Management Data
(type)_TO_USINT ........................................................ 239 (Tool Information (1): Tool Number)
(Low-speed Response) ..................................................495

s.c
<U>
Writing the Tool Management Data
UDINT_TO_BCD8(operand) ....................................... 235
(Tool Information (2): Tool Order Number)
UDINT_TO_DINT(operand) ........................................ 242
(Low-speed Response) ..................................................497
UDINT_TO_INT(operand) ........................................... 240

re
Writing Tool Life Management Data
UDINT_TO_SINT(operand)......................................... 238
(Arbitrary Group Number) (Low-speed Response).......523
UDINT_TO_UINT(operand) ........................................ 241
Writing Tool Life Management Data
UDINT_TO_USINT(operand) ...................................... 239
UINT_TO_BCD4(operand) .......................................... 235
UINT_TO_DINT(operand) ........................................... 242
pa
(Cutter Compensation Number (1): Tool Number)
(8-digit tool number) (Low-speed Response)................513
Writing Tool Life Management Data
cs
UINT_TO_INT(operand).............................................. 240
(Cutter Compensation Number (1): Tool Number)
UINT_TO_SINT(operand)............................................ 238
(Low-speed Response) ..................................................491
UINT_TO_UDINT(operand) ........................................ 243
.cn

Writing Tool Life Management Data


UINT_TO_USINT(operand)......................................... 239
(Cutter Compensation Number (2): Tool Order Number)
Up Counter.................................................................... 168
(Low-speed Response) ..................................................493
UPCTR............................................................................ 67
Writing Tool Life Management Data
UPCTR(address, r, pv) .................................................. 168
w

(Remaining Tool Life) (Low-speed Response) .............525


USE OF MDI KEY FOR INPUT ON CNC .................. 571
Writing Tool Life Management Data
User References .............................................................. 11
(Tool Length Compensation Number (1): Tool Number)
w

USINT_TO_BCD2(operand) ........................................ 235


(8-digit tool number) (Low-speed Response)................511
USINT_TO_DINT(operand)......................................... 242
Writing Tool Life Management Data
w

USINT_TO_INT(operand)............................................ 240
(Tool Length Compensation Number (1): Tool Number)
USINT_TO_SINT(operand) ......................................... 238
(Low-speed Response) ..................................................487
USINT_TO_UDINT(operand) ...................................... 243
://

Writing Tool Life Management Data


USINT_TO_UINT(operand)......................................... 241
(Tool Length Compensation Number (2):
<W> Tool Order Number) (Low-speed Response) ................489
tp

WHAT IS THE I/O LINK? ............................................. 23 Writing Tool Life Management Data
Window......................................................................... 254 (Tool Life Counter Type) (Low-speed Response).........485
Writing Tool Life Management Data
ht

WINDOW FUNCTIONS .............................................. 335


Writing a Custom Macro Variable (Tool Life Counter) (Low-speed Response)..................483
(Low-speed Response) .................................................. 367 Writing Tool Life Management Data
Writing a Parameter (Low-speed Response) ................. 359 (Tool Life) (Low-speed Response) ...............................481
Writing a Tool Management Data Writing Tool Life Management Data
(Low-speed Response) .................................................. 539 (Tool Number) (Low-speed Response) .........................499
Writing a Tool Offset (Low-speed Response)............... 351

i-8
B-63823EN/02 INDEX

Writing Value of the P-code Macro Variable


(Low-speed Response) .................................................. 387
WRITING, READING, AND VERIFYING THE
SEQUENCE PROGRAM AND PMC PARAMETER

/
DATA (I/O)................................................................... 312

om
<X>
XOR_(type)..................................................................... 88
XOR_BYTE(in1, in2) ................................................... 203
XOR_DWORD(in1, in2)............................................... 203

s.c
XOR_WORD(in1, in2) ................................................. 203

re
pa
cs
.cn
w
w
w
://
tp
ht

i-9
ht
tp
://
w
w
w
.cn
cs
pa
re
s.c
om
/
ht Revision Record

FANUC PMC-MODEL SD7 PROGRAMMING MANUAL (B-63823EN)


tp
://
w
w
w
.cn
Addition of following items
cs
• I/O LINK
• NOTE ON LD PROGRAMMING
• NOTE ON IL PROGRAMMING
02 Nov., 2004
• WINDOW FUNCTIONS
pa
• CHINESE CHARACTER CODE, HIRAGANA
CODE, AND SPECIAL CODE LIST
Correction of errors
re
01 Oct., 2002
s.c
Edition Date Contents Edition Date Contents
om
/
ht
tp
://
w
w
w
.cn
cs
pa
re
s.c
om
/

You might also like