* 3 axes Post Processor for FANUC
* CIMATRON90 VER 9.0
********************************************************
* modified by Nie Zai Qiu 11/15/1996
********************************************************
* define private variables:
FORMAT (SEQUENCING) Seq SubSeq ;
FORMAT (TOOL) CutterComp FirstTool LastTool ;
FORMAT (COORDINATES) Xold Yold Zold DXcenter DYcenter DZcenter ;
FORMAT (COORDINATES) Zinit Clear Depth ;
FORMAT (COORDINATES) Xhome Yhome Zhome ;
FORMAT (COORDINATES) XfirstOrigin YfirstOrigin ZfirstOrigin ;
FORMAT (USER_1) CurrSubNum ;
FORMAT (USER_1) Fast ;
* define private flags:
FORMAT (USER_2) FlagSub FlagSeq FlagSpin;
FORMAT (USER_2) FirstOriginChange FlagError ;
* define private constants:
FORMAT (USER_2) YES NO ;
* change the format of existing variables:
FORMAT (USER_1) SUB_NUMBER ;
*-----shift all data according to the MCHINE ZERO indicated by the
* user in the POSTPR interaction
TRANS_MATX = 0 - X_MACH ;
TRANS_MATY = 0 - Y_MACH ;
TRANS_MATZ = 0 - Z_MACH ;
*-----shift the HOME according to the MCHINE ZERO indicated by the
* user in the POSTPR interaction
Xhome = X_HOME - X_MACH ;
Yhome = Y_HOME - Y_MACH ;
Zhome = Z_HOME - Z_MACH ;
*-----tool location is HOME
Xold = X_HOME ;
Yold = Y_HOME ;
Zold = Z_HOME ;
*-----Save the first origin data for later use
IF_SET (FirstOriginChange _EQ_ YES )
XfirstOrigin = X_ORIGIN ;
YfirstOrigin = Y_ORIGIN ;
ZfirstOrigin = Z_ORIGIN ;
FirstOriginChange = NO ;
END_IF ;
*.....distance between the rotation center and the ORIGIN
TRANS_MATX = X_ORIGIN - XfirstOrigin - X_MACH ;
TRANS_MATY = Y_ORIGIN - YfirstOrigin - Y_MACH ;
TRANS_MATZ = Z_ORIGIN - ZfirstOrigin - Z_MACH ;