# macro startup: calls speeds for constant surface speed (G96)
#                    and rpm speed  (G97)
#
ASSIGN: Tcode= 101;
CLEAR_NOTES.TOOLS:
CLEAR_NOTES.TIME:
CLEAR_NOTES.COST:
CLEAR_NOTES:
NOTEPAD.TOOLS:    Tooling List for Program  {Prog_desc}.
NOTEPAD.TOOLS:
NOTEPAD.TOOLS: ***************************************
NOTEPAD.TOOLS:    Tool number:       T{Tcode}
NOTEPAD.TOOLS:    Tool description:  {Tool_desc}
NOTEPAD.TIME:    Time Analysis for Program  {Prog_desc}.
NOTEPAD.TIME:
MACRO: ../common/lstartup.html
#
MACRO: get_tool_info
ASSIGN: Feed_rem= Feed;
ASSIGN: Feed= 9999;
ASSIGN: X=Diahome/2; Z=Zhome;
ASSIGN: Setcoordinates
ASSIGN: Feed= Feed_rem;
ASSIGN: Part_rotate=1;
GEOMETRYON: 
#
OUTPUT: **o{Prog_num}
OUTPUT: ** ( {Prog_desc}        {Date1} )
#
OUTPUT: **M422
OUTPUT: **G53.5
OUTPUT: **G0G98
OUTPUT: **G28U0
OUTPUT: **G28U0V0W0
OUTPUT: **M200
OUTPUT: **C45.
OUTPUT: **M620
OUTPUT: **T4000.1B1
#OUTPUT: **Z.35X3.6 ( ADJ. X FOR PROBE LOCATION AT Z0)
OUTPUT: **Z.35X{Zprobe} ( ADJ. X FOR PROBE LOCATION AT Z0)
OUTPUT: **M81
OUTPUT: **G65P9013Z0S7
OUTPUT: **Z.5
OUTPUT: **G28U0
OUTPUT: **M82
#OUTPUT: **#550=PEEK[20,#9100,1,1,1]
OUTPUT: ** {Peek_state}
OUTPUT: **#9101=#550
OUTPUT: **G4X.1
OUTPUT: **G128E1
OUTPUT: **G28W0
ASSIGN: Tool_desc= UPC$(Tool_desc);
OUTPUT: ** (  {Tool_desc} T{Tcode} )
#
#
#
SELECT: Power_tool
CASE: 0
#      do nothing
CASE ELSE:
ASSIGN: Comments= "(APPROACH FEEDRATE FOR G43.4)";
OUTPUT: **#600=1200.  {Comments}
ASSIGN: Comments= "(FEEDRATE FOR PLUNGE CUTTING)";
OUTPUT: **#601=40.   {Comments}
ASSIGN: Comments= "(FEEDRATE FOR ENTRY INTO CUTS)";
OUTPUT: **#602=40.   {Comments}
ASSIGN: Comments= "(LINEAR FEEDRATE FOR 2D ROUGH CUTS)";
OUTPUT: **#603=40.   {Comments}
ASSIGN: Comments= "(LINEAR FEEDRATE FOR B AXIS ONLY FINISH CUTS)";
OUTPUT: **#604=40.   {Comments}
END SELECT:
#
#
#
SELECT: Power_tool
CASE: 1
MACRO: caxis_od_setup
CASE: 2
MACRO: cfacesetup
CASE: 3
MACRO: caxis_id_setup
END SELECT:
OUTPUT: G53.5
MACRO: establish_home
ASSIGN: Plot_on= 1;
TOOLSYMBOL:
ASSIGN: Plot_on= (Power_tool<1);
MACRO: speeds                   Repeats= (Thr_cycle<>1);
ASSIGN: Plot_on= 1;
ASSIGN: Tool_descr= Tool_desc;
ASSIGN: Tool_filer= Tool_file; Tool_numr= Tool_num;
ASSIGN: Tcoder= Tcode;
ASSIGN: Power_toolr= Power_tool;
ASSIGN: Prev_odid= Odid_cycle;
ASSIGN: Dia_comp= Tcode;
ASSIGN: Tool_ch= 1;
#
ASSIGN: Tape_on= 0; Plot_on= 0;
ROTARY_POS: A= -.001; C= -.001;
ASSIGN: Tape_on= 1; Plot_on= 1;
ASSIGN: Clast= -.001; Blast= -.001;
