Hi,

We have a new machine (to us!!) That i am trying to transfer macros from an old machine to the newer one

The old one was a Fanuc 6M the newer one is a Fanuc 0M d

the macro we use is a bolt hole one but we never drill on the 0, 90, 180 and 270 angles

the example is below on line

G65 P8000 D200.0(PCD) K8 number of holes (first hole postion)
G81 Etc etc
G65 P8001 D200.0 K8 rest of the holes


the macros are below

%
:8000
(FULL CIRCLE START POS)
(D#7=P.C.D.)
(K#6=TOTAL.NUMBER.OF.HOLES)
#100=1
#101=SIN[[0.360/#6*#100]-[0.180/#6]]*[#7/2]
#102=COS[[0.360/#6*#100]-[0.180/#6]]*[#7/2]
G90G00X#102Y#101
M99

:8001
(FULL CIRCLE REMAINING HOLES)
#29=[#6*1000]
#100=2
WHILE[#100LE#29]DO1
#101=SIN[[0.360/#6*#100]-[0.180/#6]]*[#7/2]
#102=COS[[0.360/#6*#100]-[0.180/#6]]*[#7/2]
G90X#102Y#101
#100=#100+1
END1
M99
%
there are a few more

it just dont want to work on the 0M controller

im just struggling as im not that used to programming macros Can anybody help???