#
# MACRO tool_change1 *** constant surface footage
#
# 
#
SELECT: Power_tool
CASE: 0
ASSIGN: Ccs= 1;
ASSIGN: Speed= SfpmToRpm(Speedcode,3.0,1.0);
ASSIGN: Speed= ValueChoice(Speed,Max_rpm,(Speed<Max_rpm));
MACRO: index_pos
OUTPUT: G50S{Speedmax}M{39+ Range}
OUTPUT:  {Const_surf_speed}S{Speedcode}
OUTPUT: G00T{Tcode} {Coolant}
ASSIGN: Ipr_feed_on=1;
CASE ELSE:
MACRO: power_index_pos 
MACRO: engage_caxis     Repeats= (Power_tool> 0);
OUTPUT: G00T{Tcode} {Coolant}
ASSIGN: Codes= StringChoice(Spindle_cw,Spindle_ccw,(Spindle_dir<>WsCCW));
OUTPUT:  {Direct_rpm}S{Speedcode}
ASSIGN: Feed=Tfeed;
ASSIGN: Ccs=0; Ipr_feed_on=0; Speed= Speedcode;
END SELECT: 
ASSIGN: Gcoder=9999;
