
FANUC Series 16i/18i/21i-MA/MB/TB TOOL MANAGEMENT FUNCTION A-78614EN
2002.08.08 Edition 04
126
13.2 Delete Tool management data
Function Name:
cnc_deltool
Declaration:
#include "fwlib32.h"
FWLIBAPI short WINAPI cnc_deltool(unsigned short FlibHndl,
short s_number, short *data_num);
Description:
Deletes the Tool management data which is specified by the start data
number and the number of the data from the Tool management data table.
Deletion by this function is done sequentially one by one. Once the
error occurs, succeeding deletion is aborted.
When the Tool management data is deleted normally from the Tool
management data table by this function, the tool number is also deleted
from the Magazine management table by the CNC process.
Arguments:
FlibHndl
Specify the library handle.
See "1.1.3 Library handle" of SPECIFICATION MANUAL OF
DATA WINDOW LIBRARY for details.
s_number
Specify the start data number for the deletion from the Tool
management data table.
data_num
Specify the pointer to the number of the deleting data for the
deletion from the Tool management data table. Set the number
of the deleting data(1...) to the pointed data before calling
this function.
This function deletes the number of Tool management data
specified by "*data_num", from the index specified by
"s_number". After the execution of this function, *data_num
holds the real deleted number of data.
Return: EW_OK is returned on successful completion, otherwise any value except
EW_OK is returned. The major error codes are as follows.
(As for the details, see "1.1.5 Return status of Data window function" of
SPECIFICATION MANUAL OF DATA WINDOW LIBRARY.)
--------------------------------------------------------------
Return code Meaning/Error handling
--------------------------------------------------------------
EW_BUSY Other users (such as PMC) have accessed to the same
data window.
Try this function again.
EW_NUMBER The start data number for the Tool management
data table (s_number) is invalid. Or, valid number
of the data on the Tool management data table exceeds.