Fanuc C-Executer Operating Manual
B-62443EN-3/03E
- 520 -
------------------------------------------------------------------------------
1.81 Read tool life management data (tool information 1). <Main,Alarm>
------------------------------------------------------------------------------
[Name]
cnc_t1info
[Syntax]
#include <data.h>
#include <fwindow.h>
int cnc_t1info( int grp_num, int tool_num, struct odbtool *buf ) ;
struct odbtool {
int datano ; /* Tool group number. */
int type ; /* Tool number. */
long data ; /* Tool information. */
} ;
[Arguments]
grp_num Tool group number.
tool_num Tool number.
buf Buffer in which the tool management data are stored.
[Return]
0 Successful.
3 Incorrect tool group number "grp_num".
4 Incorrect tool number "tool_num".
5 The specified tool number is not registered in the specified
tool group.
6 The required option (Tool life management or Tool number
expansion for tool life management (512 sets in total, only
M Series)) is not added.
[Description]
Reads the tool information of the specified tool group and tool
number.
Specify the tool group number in "grp_num" and the tool number in
"tool_num" with binary format.
The tool information of the specified tool is stored in "buf.data"
with binary format as follows.
buf.data Tool information
---------------+------------------------
1 This tool is registered.
2 This tool has expired.
3 This tool was skipped.
The currently used tool group and tool are referenced by specifying
"0" in "grp_num" and "tool_num". However, in case that any tool group
number has never be specified since power-on, "0" is stored.