Description
Writes the tool offset value specified by "number", "type". The offset value must be stored in "data" with signed binary format.
The unit of offset value is as follows.
- Series 15
- Series 15i
- Series 16/18/21, 16i/18i/21i, 0i-A/B/C, Power Mate i
- Series 0i-D/F, PMi-A
- Series 30i
6007#0 (ONM) |
6004#0 (OUF) |
6002#1 (OFN) |
6002#0 (ORG) |
Linear axis mm input [mm] |
Linear axis inch input [inch] |
Rotation axis [deg] |
---|---|---|---|---|---|---|
0 | 0 | 0 | 1 | 0.01 | 0.001 | 0.01 |
0 | 0 | 0 | 0 | 0.001 | 0.0001 | 0.001 |
0 | 0 | 1 | 0 | 0.0001 | 0.00001 | 0.0001 |
0 | 1 | 0 | 0 | 0.00001 | 0.000001 | 0.00001 |
1 | 0 | 0 | 0 | 0.000001 | 0.0000001 | 0.000001 |
6007#0 (OFE) |
6004#0 (OFD) |
6002#1 (OFC) |
6002#0 (OFA) |
Linear axis mm input [mm] |
Linear axis inch input [inch] |
Rotation axis [deg] |
---|---|---|---|---|---|---|
0 | 0 | 0 | 1 | 0.01 | 0.001 | 0.01 |
0 | 0 | 0 | 0 | 0.001 | 0.0001 | 0.001 |
0 | 0 | 1 | 0 | 0.0001 | 0.00001 | 0.0001 |
0 | 1 | 0 | 0 | 0.00001 | 0.000001 | 0.00001 |
1 | 0 | 0 | 0 | 0.000001 | 0.0000001 | 0.000001 |
1004#1 (ISC) |
1004#0 (ISA) |
Linear axis mm input [mm] |
Linear axis inch input [inch] |
Rotation axis [deg] |
|
---|---|---|---|---|---|
IS-A | 0 | 1 | 0.01 | 0.001 | 0.01 |
IS-B | 0 | 0 | 0.001 | 0.0001 | 0.001 |
IS-C | 1 | 0 | 0.0001 | 0.00001 | 0.0001 |
IS-C is effective for Power Mate i-D.
5042#1 (OFC) |
5042#0 (OFA) |
Linear axis mm input [mm] |
Linear axis inch input [inch] |
Rotation axis [deg] |
---|---|---|---|---|
0 | 1 | 0.01 | 0.001 | 0.01 |
0 | 0 | 0.001 | 0.0001 | 0.001 |
1 | 0 | 0.0001 | 0.00001 | 0.0001 |
5042#3 (OFE) |
5042#2 (OFD) |
5042#1 (OFC) |
5042#0 (OFA) |
Linear axis mm input [mm] |
Linear axis inch input [inch] |
Rotation axis [deg] |
---|---|---|---|---|---|---|
0 | 0 | 0 | 1 | 0.01 | 0.001 | 0.01 |
0 | 0 | 0 | 0 | 0.001 | 0.0001 | 0.001 |
0 | 0 | 1 | 0 | 0.0001 | 0.00001 | 0.0001 |
0 | 1 | 0 | 0 | 0.00001 | 0.000001 | 0.00001 |
1 | 0 | 0 | 0 | 0.000001 | 0.0000001 | 0.000001 |
The available range of offset value is as follows.
- Series 15
- Series 15i
- Series 16/18/21, 16i/18i/21i, 0i-A/B/C, Power Mate i
- Series 0i-D/F, PMi-A
- Series 30i
6007#0 (ONM) |
6004#0 (OUF) |
6002#1 (OFN) |
6002#0 (ORG) |
Linear axis mm input [mm] |
Linear axis inch input [inch] |
Rotation axis [deg] |
---|---|---|---|---|---|---|
0 | 0 | 0 | 1 | ± 999.99 (±9999.99) |
± 99.999 (±999.999) |
± 999.99 (±9999.99) |
0 | 0 | 0 | 0 | ± 999.999 (±9999.999) |
± 99.9999 (±999.9999) |
± 999.999 (±9999.999) |
0 | 0 | 1 | 0 | ± 999.9999 (±9999.9999) |
± 99.99999 (±999.99999) |
± 999.9999 (±9999.9999) |
0 | 1 | 0 | 0 | ± 99.99999 (±9999.99999) |
± 9.999999 (±999.999999) |
± 99.99999 (±9999.99999) |
1 | 0 | 0 | 0 | ± 9.999999 (±999.999999) |
± 0.9999999 (±99.9999999) |
± 9.999999 (±999.999999) |
6007#0 (OFE) |
6004#0 (OFD) |
6002#1 (OFC) |
6002#0 (OFA) |
Linear axis mm input [mm] |
Linear axis inch input [inch] |
Rotation axis [deg] |
---|---|---|---|---|---|---|
0 | 0 | 0 | 1 | ±9999.99 | ±999.999 | ±9999.99 |
0 | 0 | 0 | 0 | ±9999.999 | ±999.9999 | ±9999.999 |
0 | 0 | 1 | 0 | ±9999.9999 | ±999.99999 | ±9999.9999 |
0 | 1 | 0 | 0 | ±9999.99999 | ±999.999999 | ±9999.99999 |
1 | 0 | 0 | 0 | ± 999.999999 | ± 99.9999999 | ± 999.999999 |
1004#1 (ISC) |
1004#0 (ISA) |
Linear axis mm input [mm] |
Linear axis inch input [inch] |
Rotation axis [deg] |
|
---|---|---|---|---|---|
IS-A | 0 | 1 | ± 999.99 (± 99.99) |
± 99.999 (± 9.999) |
± 999.99 (± 99.99) |
IS-B | 0 | 0 | ± 999.999 (± 99.999) |
± 99.9999 (± 9.9999) |
± 999.999 (± 99.999) |
IS-C | 1 | 0 | ± 999.9999 (± 99.9999) |
± 99.99999 (± 9.99999) |
± 999.9999 (± 99.9999) |
IS-A is effective for Power Mate i-H.
IS-C is effective for Power Mate i-D.
5042#1 (OFC) |
5042#0 (OFA) |
Linear axis mm input [mm] |
Linear axis inch input [inch] |
Rotation axis [deg] |
---|---|---|---|---|
0 | 1 | ±9999.99 | ±999.999 | ±9999.99 |
0 | 0 | ±9999.999 | ±999.9999 | ±9999.999 |
1 | 0 | ±9999.9999 | ±999.99999 | ±9999.9999 |
5042#3 (OFE) |
5042#2 (OFD) |
5042#1 (OFC) |
5042#0 (OFA) |
Linear axis mm input [mm] |
Linear axis inch input [inch] |
Rotation axis [deg] |
---|---|---|---|---|---|---|
0 | 0 | 0 | 1 | ±9999.99 | ±999.999 | ±9999.99 |
0 | 0 | 0 | 0 | ±9999.999 | ±999.9999 | ±9999.999 |
0 | 0 | 1 | 0 | ±9999.9999 | ±999.99999 | ±9999.9999 |
0 | 1 | 0 | 0 | ±9999.99999 | ±999.999999 | ±9999.99999 |
1 | 0 | 0 | 0 | ±999.999999 | ±99.9999999 | ±999.999999 |
Universal Fanuc Driver
Fanuc Focas Library CD
Declaration
Arguments
Specify the library handle. See "Library handle" for details.
Specify the tool offset number.
The available number of tool offset can be got by cnc_rdtofsinfo function.
Specify the tool offset type. (see the following table)
- Machining Center Series (M series, including Power Mate i, PMi-A)
- Machining Center Series (M series, Series 30i)
- Lathe Series (T series)
- Lathe Series (T series, second geometry offset, Series 30i)
- Machining Center Series
- Lathe Series (T series)
- Lathe Series/second geometry offset
Cutter radius | Tool length | |
Wear | 0 | 2 |
Geometry | 1 | 3 |
Cutter radius | Tool length | Imaginary tool nose | Corner R | |
Wear | 0 | 2 | 6 | 10 |
Geometry | 1 | 3 | 7 | 11 |
X axis | Z axis | Nose R | Imaginary tool nose | Y axis | 4th axis | 5th axis | |
Wear | 0 | 2 | 4 | 6 | 8 | 30 | 32 |
Geometry | 1 | 3 | 5 | 7 | 9 | 31 | 33 |
2nd coord Ware(Series 30i) | 15 | 17 | 19 | 21 | 23 | -- | -- |
2nd coord Geometry(Series 30i) | 16 | 18 | 20 | 22 | 24 | -- | -- |
X axis | Z axis | Y axis | |
Geometry | 100 | 101 | 102 |
2nd coord Geometry | 110 | 111 | 112 |
When the tool offset for milling and turning function option is effective, specify the following type.(Series 30i)
X axis | Tool length | Cutter radius | Imaginary tool nose | Y axis | Corner R | |
Wear | 0 | 2 | 4 | 6 | 8 | 10 |
Geometry | 1 | 3 | 5 | 7 | 9 | 11 |
X axis | Z axis | Nose R | Imaginary tool nose | Y axis | |
Wear | 0 | 2 | 4 | 6 | 8 |
Geometry | 1 | 3 | 5 | 7 | 9 |
X axis | Z axis | Y axis | |
Geometry | 100 | 101 | 102 |
Specify 8.
Set the tool offset value.
Return
EW_OK is returned on successful completion, otherwise any value except EW_OK is returned.
The major error codes are as follows.
Return code | Meaning/Error handling |
---|---|
(2) |
Size (length) is not 8. |
(3) |
Offset number (number) is wrong. |
(4) |
Offset type (type) is wrong. |
(15) |
Offset data is out of range of the wrong operation prevention functions. |
(5) |
Offset data (data) is out of range. |
As for the other return codes or the details, see "Return status of Data window function"
CNC option
And this function is related to the following CNC option.
- Series 15
- Series 15i
- Series 16/18/21, 16i/18i/21i
- Series 0i-A/B/C
- Series 0i-D/F
- Series 30i
- Power Motion i
* ( ) : Basic
M
Tool offset extension
(32)/99/200/499/999 sets
Tool offset memory
(A)/B/C
Extended tool offset value(number of offset is half of the above sets.)
T
Tool offset extension
(32)/64/160 sets
Tool offset memory
(A)/B
Cutter radius compensation
Extended tool offset value(number of offset is half of the above sets.)
TT
Tool offset extension(each path)
(16)/32/80 sets
Tool offset memory
(A)/B
Cutter radius compensation
M
Tool offset extension
(32)/99/200/499/999 sets
Tool offset memory
(A)/B/C
M
Tool offset extension
(32)/64/99/200/400/499/999 sets
Tool offset memory
(A)/B/C
T
Tool offset extension
(16)/32/64/99 sets
Geometry/wear offset
Cutter radius compensation
Y axis offset
M
Tool offset extension
32/(400) sets
Tool offset memory
A/(C)
T
Tool offset extension
32/(64) sets
Geometry/wear offset
Cutter radius compensation
Y axis offset
M
Tool offset extension
32/(400) sets
Tool offset memory
A/(C)
T
Tool offset extension
32/(99) sets
Geometry/wear offset
Cutter radius compensation
Y axis offset
M
Tool offset extension
(32)/64/99/200/400/499/999/2000 sets
Tool offset memory
(A)/B/C
Tool radius/Cutter radius compensation
Tool offset for Milling and Turning function
T
Tool offset extension
(32)/64/99/200/400/499/999/2000 sets
Geometry/wear offset
Tool radius/Cutter radius compensation
Y axis offset
Second figure tool offset
4th/5th Axis Offset Function
The changing active offset
Tool offset for Milling and Turning function
Tool offset extension
(32)/99/200 sets
For HSSB connection,
For Ethernet connection,
The Ethernet function and the extended driver/library function are necessary. However, in case of FS16i/18i/21i-B, 0i-B/C/D/F, Series 30i and PMi-A, the required CNC option is as follows. When Embedded Ethernet is used, above two optional functions are not required. When Ethernet board is used, only Ethernet function is required.
CNC parameter
This function is related to the following CNC parameter.
See the manual of CNC parameter for details.
5009#5(Only M Series)
5024
5009#5(Only M Series)
5024
8132#1=1 (must be set)
5009#5(Only M Series)
5024
1004#1(In case of Power Mate i-D)
CNC mode
This function can be used in any CNC mode.
Available CNC
0i-A | 0i-B/C(Note) | 0i-D | 0i-F | 15 | 15i | 16 | 18 | 21 | 16i-A | 18i-A | 21i-A | 16i-B | 18i-B | 21i-B | 30i-A | 30i-B | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
M (Machining) | |||||||||||||||||
T (Turning) | - | ||||||||||||||||
LC (Loader) | - | - | - | - | - | - | - | - |
0i-D | 0i-F | 16i | 18i | 30i-A | 30i-B | |
---|---|---|---|---|---|---|
P (Punch press) | - | |||||
L (Laser) | - | - | - | - | ||
W (Wire) | - | - |
Power Mate i-D | |
Power Mate i-H | |
Power Motion i-A | O |
"O" | : | Both Ethernet and HSSB | |
"E" | : | Ethernet | |
"H" | : | HSSB | |
"X" | : | Cannot be used | |
"-" | : | None |
Note) 0i-C does not support the HSSB function.
See Also
cnc_rdtofs cnc_rdtofsr cnc_wrtofsr cnc_rdtofsinfo
Example(C Language)
The following program writes the offset value of specified offset number.
(for M series)
#include "fwlib32.h"
/* tidx is tool index. */
/* offset is new offset value. */
short example( short tidx, long offset )
{
short ret ;
ret = cnc_wrtofs( h, tidx, 0, 8, offset ) ;
return ( ret ) ;
}
Example(C#)
The following program writes the offset value of specified offset number.
(for M series)
class example
{
/* tidx is tool index. */
/* offset is new offset value. */
public short sample(short tidx, int offset)
{
short ret;
ret = Focas1.cnc_wrtofs(h, tidx, 0, 8, offset);
return (ret);
}
}