Workflow recommendation for z-probe

Good morning,

I’m trying to understand the workflow when using Z-probe touchplate, help would be welcome

Essentially, if I understand correctly:

  • Z-offset between probe and toolhead needs to be set to zero (unlike a 3D printer, where there’s an offset between BLTouch and the hotend tip)
  • Workflow be would as follow:
    • Home all three axis (Z axis will home up)
    • Send a G29 command to zero Z between the toolhead and the build plate
    • start machining :slight_smile:

Am I correct ?

Regards !

There is a very important distinction between 3D printing and CNC milling. For 3D printing, all your g-code coordinates are relative to the build plate. For CNC milling, all your g-code coordinates are relative to the stock. When you do the CAM for your milling, you set the origin point you want to use for your milling. For X and Y, the common origin points are the center (XY) of the stock, and the bottom left corner of the stock. For Z, the most common choice is the top of the stock followed by the surface of the spoil board. You make these choices when you author the toolpaths in your CAM for your machine.

A common workflow would be:

  • Home the machine
  • Navigate your router to above the surface you want to use for the Z origin
  • Probe that surface and set your Z height using a G92
  • Navigate your router the XY origin relative to the stock you authored as your origin in CAM
  • Execute a G92 to set that as X0 Y0
  • Run your job
1 Like

Thanks for the clarification

So actually workflow would be, with detailed commands:

  • Home the machine : G28
  • Navigate your router to above the surface you want to use for the Z origin
  • Probe that surface and set your Z height using a G92 : G30 then G92 Z0
  • Navigate your router the XY origin relative to the stock you authored as your origin in CAM
  • Execute a G92 to set that as X0 Y0 : G92 X0 Y0
  • Run your job

Am I correct ? (especially the z probe command)

This depends a bit on what “probe” you are using. If you have a classic probe, then you still need an offset to account for the difference in length of the probe versus the length of the cutting tool. Many here use a metal “touch plate” as one side of a switch, and a connection to the tool/bit as the other side of the switch. In this case, instead of setting Z=0, you’d want to set it to the thickness of your touch plate.
I suppose for conductive work pieces, you could connect the bit as described above but connect directly to the workpiece instead of the touch plate, then you would set Z=0 when the tool touched the work.

1 Like

Largely correct. For probing you must account for the thickness of the touch plate. Say your touch plate was 0.4mm thick, you would use a G92 Z0.4 to account for the thickness.

Thanks everyone, that’s clear !

Now if I could find a way to add macros accessible through the touchscreen, that would make life easier

Regards

Assuming you are running Marlin, there are a few “hacks.”

  • Place each macro g-code in a separate file and run that file from the display

  • Modify the V1 custom menu to add your macros. You would need to be in Marlin mode to run them.

  • Use Marlin’s Autostart functionality to populate M810-M819 at startup. This would allow you to run your macros by executing a single g-code from the touch screen’s console.

Option 1/ looks good to me
I’m not running the touchscreen in Marlin mode, so I don’t think I can easily add custom menu to the touchscreen interface

Regards

Coming back on this workflow question, since I’m a little bit puzzled, there’s probably something missing in my G code generation script.

When I run G30, it does probe, stop the head when probing, but reports a “Probing failed” error.
That said, I can still enter G92 Z0.4 (thickness of my touchplate) and perform the rest of the procedure.

However, if I raise the toolhead, say by 10mm, and I start the job, it will start at with Z at 10mm. Z dimension does report 10mm, so it knows it’s above.

I’m assuming therefore I’m missing a step in my G-Code, which would be move to X0,Y0,Z0, but in this case the toolhead is too close to the material, and it can’t move without risking scratching the surface.

So I assume I need to define a few starter code in the G-code script generation ?

Regards

Hmmm.

I never include probing in the job gcode. I handle all probing operations separately, so that I can re-do them in the event of a problem with the probe. (Something wasn’t making good contact, like the magnet/clamp to the bit, or I missed the touch plate, or accidentally touched the bit with the plate before it got to the bottom. – All of these things have happened to me.)

So I set the machine origin before I start a job.

On RepRap Firmware, I use G30 to probe, but on Marlin, generally G38.2 is used. It treats the probe a little differently. This is the more normal way to do it around here, so you can probably get more support for it.

The general format (Assuming the V1 touchplate) is:

G38.2 Z0 ; Probe towards Z=0 which works from the home position being Z=200
M400 ; Wait for all motion to clear the buffer
G92 Z0.5 ; Set the Z position to the thickness of the touch plate
G0 Z5 ; lift the tool to be able to remove the touch plate

I have something similar set up as a macro.

Thanks for this, I’ll test it

On a sidenote, I figured out why it was machining above the stock: that’s because the post processor script I use, MCPCNC.cs adds a G92 command at the beginning of the job, so obviously… zero is reset. If I remove it, all is fine.

As for G38, do you also get a “probing error” when using it ? I’m using the touchscreen with V1Engineering recommended firmware (so not in touchscreen mode), and I get this error. For the first probe it’s not a problem, but when doing a tool change it’s problematic since it interrupts the gcode any feedback ?

Regards

Well, I no longer use the V1 firmware, I use Duet boards for my CNC machines, which use RepRap Firmware, so although I know how the V1 Marlin firmware works, and have worked with the FluidNC firmware some as well, I dont use jt regularly.