PDA

View Full Version : 3D milling of hemisphere



Indexschrotter
04-17-2008, 01:10 PM
Hello

I have to mill a hemisphere!!!

Does any body have an example of a program?

I work at a horizontal BAZ with a spherical axis Sinumerik 840D.

Sit22
04-20-2008, 04:32 AM
PROC HK (REAL R_EBENE, REAL S_EBENE, REAL REF_EBENE, REAL B_FOR, REAL K_RAD, REAL V_HUB) SAVE DISPLOF
DEF REAL POSX, POSY, WZ_RAD, T_TIEFE, B_RAD, Z_RAD

;R_EBENE = RUECKZUGSEBENE
;S_EBENE = SICHERHEITSEBENE
;REF_EBENE = REFERENZEBENE
;B_FOR = ZUSTELLUNG IN Z ( AP )
;K_RAD = KREISRADIUS ( ENDTIEFE )
;V_HUB = VORSCHUB

;VARIABLEN WERTE ZUWEISEN
B_RAD=K_RAD ;BEARBEITUNGSRADIUS
T_TIEFE=REF_EBENE ;BEARBEITUNGSTIEFE
Z_RAD=B_RAD*0.1 ;RADIUS FUER ZUSTELLKREIS
POSX=$AA_IW [X] ;AKTUELLE POS IN X
POSY=$AA_IW [Y] ;AKTUELLE POS IN Y
WZ_RAD=$P_TOOLR ;RADIUS1 DES AKTIVEN WZ

G90
G95
G64 CFIN
FFWON

G0 Z=R_EBENE
G0 X=-(K_RAD-WZ_RAD+POSX) Y=POSY
G0 Z=S_EBENE
G1 Z=REF_EBENE F=0.01

N210 BEGIN:
N230 G3 X=-(B_RAD-WZ_RAD+POSX) Y=POSY I=AC(POSX) J=AC(POSY) F=V_HUB*_TEETH ; Vollkreis
N240 G3 X=((-B_RAD+WZ_RAD+POSX)+(Z_RAD*2)) Y=POSY CR=Z_RAD F=V_HUB*_TEETH/2 ; Halbkreis 1
N250 IF B_RAD >= K_RAD/2
N260 T_TIEFE=T_TIEFE-B_FOR
N270 IF T_TIEFE<=0
N280 B_RAD=SQRT(POT(K_RAD)-POT(T_TIEFE))
N290 ENDIF
N300 ELSE
N310 B_RAD=B_RAD-B_FOR
N320 T_TIEFE=-(SQRT(POT(K_RAD)-POT(B_RAD)))
N330 ENDIF
N340 IF B_RAD<=B_FOR GOTOF ENDE
N350 STOPRE
N360 G3 X=(-B_RAD+WZ_RAD+POSX) Y=POSY CR=Z_RAD Z=T_TIEFE F=V_HUB*_TEETH/2 ; Halbkreis 2
N370 GOTOB BEGIN
N380 END:

N390 G0 Z=S_EBENE
N395 G0 Z=R_EBENE


Not tested yet.