O1000;
M3 S600;
T0101;
G00 X0 Z150
G98
#24=80(短轴半径,X轴方向)
#26=100(长轴半径,Z轴方向)
#7=0.1
#1=#26+#7(Z轴方向最大值,假设为顶点)
#23=3.15(Z轴方向最小值)
WHILE[#1GT#23]DO1
#1=#1+#7(计算每次Z轴的坐标值)
IF[#1GT#23]GOTO9
#1=#23(最后一次把Z轴终点坐标赋值给#1)
N9 #3=2*#24*SQRT[1-[#1*#1]/[#26*#26]](X轴坐标值计算,此处按直径编程)
G01 X#3 Z#1 F100
END1
M30
(转自jiaweiwei303)
O1234;
T0101 M03 S600;
GOO X34 Z2.0;
G73 U14 W0 R7; G73 P10 Q20 U1 W0.05 F0.25;
N10 G00 X0.;
G42 G01 Z0. F0.1; #1=0;(角度初始值)
WHILE [#1 LE 144] DO1;
#2=14*SIN[#1];
#3=20*COS[#1];
G01 X[2*#2] Z[#3-20]F0.1;
#1=#1+0.5;
END 1;
G01 Z-40;
X28;
W-10;
N20 G40 X33;
M03 S800;
G70 P10 Q20;
G00 X150 Z150;
M5;
M30;