Colin, First of all welcome to EMC2! Your G-code looks correct to me, so maybe it's something in your setup. I use tool presetting for my CNC mill too, so here's how I do it:
1) Home the spindle gauge point to the positive Z limit and/or home. 2) Use a master tool (mine is 3.6000 inches long) to touch off the part surface. Note: "no tool" should be displayed during this type of touch off. 3) Enter the master tool length in the Z axis touch off window (mine is 3.6 relative to Z0.) Now the negative distance from home to Z0 is stored as the work offset in *.var file. 4) Use G43 with multiple tools as needed. No more touch off required for that part. Cutter comp G41 is a separate issue. I hope this helps! Jim -----Original Message----- From: Colin K [mailto:cwk....@gmail.com] Sent: Tuesday, July 19, 2011 11:05 PM To: Enhanced Machine Controller (EMC) Subject: [Emc-users] Problem: Tool length compensation not compensating? I recently converted my mill to EMC from Mach, and until now have been using it only with subroutines. Tonight I tried running a program produced by BobCAD v23, which I have used successfully with Mach, and ran into a problem with tool length compensation. Basically, I could not get the offsets to "stick" through a tool change. Here is what my tool table file looks like *: T1 P1 D0.125000 Z+2.269462 ;1/8 end mill T2 P2 D0.062500 Z+2.478416 ;1/16 end mill T3 P3 D0.201000 Z+1.273000 ;#7 tap drill T99999 P99999 Z+0.100000 ;big tool number I also have the same PC set up to run my lathe, and I have run that with three pre-set tools for a few months now with no problem. When I swap tools, I issue a command like M6 T2 G43, and the tool display in Axis changes and the DROs re-set to reflect the tool X/Z offset, and it's all good. But, on my mill, if I enter the same command, the Z value does not change. I touched both tools off and checked the tool table, it matched the values I had set manually by measuring the tools offline, but no matter what I did, it didn't seem to want to apply my offsets properly. Here is the beginning of a program that is giving me trouble. Prior to running this program, I had T1 in (based on the values above). I then ran this program below. It prompted me for tool #2, I put it in, clicked OK (I am using the manual tool change dialog), but it proceeded to behave as though the Z offset for tool 1 was active. At least that's what it looked like as things were off by about .25" which is about the difference between the two tools. /(BEGIN PREDATOR NC HEADER) /(MACH_FILE=3XVMILL.MCH) /(MTOOL T2 S1 D.25 C0. A0. H3.) /(SBOX X0. Y0. Z-1. L4.3 W2. H1.) /(END PREDATOR NC HEADER) N1 ( C2_0718_B.NC) N2 ( EMC2 ) N3 ( TUE. 07/19/2011 10:08PM) N4 G17 G20 G40 G49 N5 G80 G90 N6 (PROFILE) N7 (MSG,LOAD.25 ENDMILL ROUGH) N8 T2 M06 N9 S3000 M3 N10 G0 G54 X-.3657 Y.4444 N11 G43 H2 Z1. N12 M8 N13 G1 Z-.05 F2. Is there anything obviously wrong here? Do I need to share my HAL or other config files? I thought I had this figured out after getting my lathe running so nicely, but this one kind of has me stumped. Thanks in advance, -cwk. * An aside about the tool table: I initially set this up by hand (using the Axis UI), and had this set with only two tools, a .250 center drill and a .250 endmill. I then went back and re-set both tools by using the touch-off, and every time I do that, it adds the #7 tap drill and the T99999 tool, and changes the diameters for T1 and T2. My CAM puts out tool centerline code, so I don't have a pressing problem there, but still, it didn't seem right... ------------------------------------------------------------------------------ 10 Tips for Better Web Security Learn 10 ways to better secure your business today. Topics covered include: Web security, SSL, hacker attacks & Denial of Service (DoS), private keys, security Microsoft Exchange, secure Instant Messaging, and much more. http://www.accelacomm.com/jaw/sfnl/114/51426210/ _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users This communication is for the use of the intended recipient only. It may contain information that is privileged and confidential. If you are not the intended recipient of this communication, the disclosure, copying, distribution or use hereof is prohibited. If you have received this communication in error, please advise me by return e-mail or by telephone and then delete it immediately. ------------------------------------------------------------------------------ 10 Tips for Better Web Security Learn 10 ways to better secure your business today. Topics covered include: Web security, SSL, hacker attacks & Denial of Service (DoS), private keys, security Microsoft Exchange, secure Instant Messaging, and much more. http://www.accelacomm.com/jaw/sfnl/114/51426210/ _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users