DIY TLO and Probe Setup - GCode Only

I finally got to install my touchplate and TLO button probe tonight! I hate to do it, but I finally just cut the clips off my leftover limit switches and wired them to the P header and bitsetter pins. I ordered the wrong ones twice on Amazon, and now that I’m starting advanced jobs I can’t wait any longer.
-It would be really great if C3D sold the 3 pin connectors/pigtails as an accessory :innocent:

Now that I have the capability for probing, is there a software-agnostic way to use them, like sending pure GCode to run a manual tool change? I’ve got touchplate probing figured out (G38.2), but I can’t wrap my head around how to set tool length offset for second/third/fourth tools.

Does anyone have a capture of what CM sends when it runs the bitsetter?

Here’s what I’ve got so far for touching off job zero:
G38.2 Z-10 F250
G0 z2
G38.2 z-5 F40
G90
G53 Z-1
G0x0y0

Now I just need the rest of the commands to run a TLO adjustment after a tool change.

This thread may be of interest.

Assuming you don’t know the tool length offsets ahead of time, the sender UI (what are you using?) will have to handle adjusting those with a G43.1 or, preferably, with a simple WCS offset.

That thread is of much interest! Thanks

Well I got fired CNCjs back up on my Pi to get some things figured out. I do like the interface on it, BUT it is missing adjustable jogging feedrate :frowning:

Anyways, it is nice enough to pop up with the GCode it runs for probing based on user input settings:

; Z-Probe
G91
G38.3 Z-40 F100
G90
; Set the active WCS Z0
G10 L20 P1 Z0
; Retract from the touch plate
G91
G0 Z4
G90

That’s pretty neat.
Here is a TLO probe op:

; Cancel tool length offset
G49
; Z-Probe
G91
G38.3 Z-40 F100
G90
; A dwell time of one second
G4 P1
; Set tool length offset
G43.1 Z[posz-0] ; THIS IS A CNCJS VARIABLE
; Retract from the touch plate
G91
G0 Z4
G90

@neilferreri I will be testing out your TLO macros this week, now that I’m starting to understand CNCjs variables.

I wouldn’t bother with G43.1. I’ve been down that road and it’s much cleaner to just adjust your WCS offset.
There are probably outdated macros on that thread. The ones that people use are up on GitHub.
Depending on your probe setup, you’d use either the BitSetter macros or the generic “Initial & New Tool”.

Yep I’ve got those loaded and ready for testing. The native probe function has a toggle for TLO and it output the G43.1.

Yup. And you’ll see other macros and software that use G43.1. I think Carbide Motion does, but I haven’t looked at it in a while.
G43.1 is a dynamic Tool Length Offset (TLO) which temporarily shifts the Z height to accommodate longer or shorter tools. This has the same effect as adjusting your Z-zero. The reason I moved away from using the TLO is that it is temporary, much like a G92 work coordinate offset shift.
By just changing, permanently, the Z offset, I can still maintain my zero after an issue or from job to job. I, and others, had enough issues related to tool changes that I decided to adjust Z-zero (using G10 L20) rather than mess around, for no gain, with Tool length offsets.

Now, when Carbide 3D comes out with a Plug and Play ATC, I’ll probably look at G43.1 again. But I’d imagine they’d move on to a more powerful MCU by then and we’d have more gcode options available.

The macros work great. If you don’t mind, I’m going to break them down into pure Gcode so they can potentially be used with other senders.

Unfortunately, I’m going to have to save CNCjs for multi tool jobs that have extra time to work on. Having to scroll up and down to get to the different functions on my 1080p display is killing me with the little touchpad on the wireless keyboard. I found myself sorely missing the hotkeys in UGS. Looking deep, it appears CNCjs isn’t fond of custom hot keys, so I’m still stuck with UGS.

Of course I don’t mind, but, again, GRBL compatible gcode can’t store information or do math for you.

This topic was automatically closed after 30 days. New replies are no longer allowed.