What's new
What's new

Siemens 840D Tool length offset on Gantry Mill

macauleymaddock

Plastic
Joined
May 9, 2023
Hi guys,

I've been scouring the internet and was hoping I could find some siemens experts on here.

I'm trying to program a new gantry mill with 840D control. The machine isn't reading the tool length offset from Spindle 2 when quoting D1.

Here's an extract of my program:

PROC TEST_PROGRAM
R1=-1000
N10 G71 G17 G0 G64 G90 G40
N15 SOFT FFWON
N20 M224;TOOL CHANGE BOTH HEADS
N30 M6T994
N40 M259;HEADS UNCOUPLED - DRIVE INDIPENDENTLY
N50 G53 G1 F10000 Y0.0 V0.0 Z500.0 W500.0 D0;POSITION HEADS FOR COUPLING
N55 Z400. W400. D1
N60 M256;COUPLE HEADS SYMETRICAL - SIDE 1 IS MASTER
N70 G54 G71 G17 G0 G64 G90 G40 G0
N80 X110.0 Y-175.
N90 G1 Z200.0 F2000 D1;CALL UP D1 TOOL LENGTH
N100 M0 ;CHECK SPINDLES ARE ALIGNED IN Z AND W
N105 M1=3 S1=700
N106 M2=4 S2=700
N110 G41 Y-130.15
N120 G1 X=R1 F10000
N130 G40 Y-175. F2000
N140 SUPA G0Z0.D0
N150 M259;HEADS UNCOUPLED - DRIVE INDIPENDENTLY
N160 M1=5 M2=5
N9999 M30

The machine will only read the tool length from Spindle 1 (XYZ axis).

If i wanted to write a subprogram to compensate for this i wanted to change line N50 in my program, but how would i access the tool length offset in spindle 2?

I saw some information in an old siemens manual which says you can read and write tool offsets from the NC program:
R100=$TC_DP994 [4,1] - This would write T994 length offset to parameter R100 which I could use.

I'm not sure how to access the tool length on spindle 2?

Any help would be greatly appreciated.

Macauley.
 
Hey Macualey, did you get this problem figured out? Seems like a master spindle issue. Are you running multi channel or single channel setup for the 2 different spindles? Also, the variable posted for tool length appears to be incorrect for the 840d control. You would need R100 = $TC_DP3[994,1].
 








 
Back
Top