Marlin icon indicating copy to clipboard operation
Marlin copied to clipboard

Add G81 and G83 drilling cycles

Open estechnical opened this issue 6 years ago • 8 comments

Requirements

This PR aims to add G81 and G83 drilling cycles for better compatibility with many CAM packages.

Description

Since many low cost CNC machines use Marlin as a controller, it makes a lot of sense to properly support common operations which are generated by CAM programs.

Not ready for use, I am opening this PR early for discussion.

Benefits

G81 and G83 drilling cycles are commonly generated by cam programs and drilling is much faster than milling a round hole, when an appropriate sized tool is available.

estechnical avatar Jun 05 '19 07:06 estechnical

I have been try this out and it performs as expected in my early testing.

Example command: G81 X10 Y10 Z-5 R2

The function is as follows:

  • rapid move to X and Y position
  • if R is specified, rapid move Z to specified retract position
  • move Z to specified Z depth at G1 feed speed
  • rapid move Z to original height or R height if specified

I have not yet made this observe G0/G1 feed speeds.

estechnical avatar Jun 05 '19 13:06 estechnical

Rebased, squashed, and augmented. To get this into your working copy, use the Git Console and execute the following commands:

git fetch origin
git checkout add-G81G83
git reset --hard origin/add-G81G83

There is still a lot of work to be done before this will be able to do proper drilling cycles with L repeat, relative mode, and so on. But for a single basic drilling cycle, this sparse implementation should work fine.

thinkyhead avatar Jun 29 '19 09:06 thinkyhead

this one has also been collecting dust for a while? @thinkyhead

boelle avatar Nov 14 '19 12:11 boelle

If you want use what I share on:

[FR] Add Drilling canned cycles to Marlin 2.0 #14448

FNeo31 avatar Nov 26 '19 00:11 FNeo31

If you need some support say something, I don't finish this but it's working (on old version) isn't modal yet, I didn't had time to spend on to because it's functional I removed the modal of post-processor on my CAM software. After put the 5axis working I'll fix this to work in modal way

FNeo31 avatar Nov 26 '19 00:11 FNeo31

I have the drilling cycle's ready to implement but for now like I said before without modal option for now. I add G81(drilling), G82(dwell) and G83(pecking) How can I merge that?

FNeo31 avatar Nov 30 '19 01:11 FNeo31

How can I merge that?

Just keep on adding to this PR by pushing new commits, ~~or if this PR is superseded by #14448 then you should close this one and add onto that PR instead~~.

thinkyhead avatar Nov 30 '20 02:11 thinkyhead

I put in some hours to migrate G81 - G83 updates and M168 into this PR and do a bunch of cleanup. It is clear that the code still needs work, but this is a start towards completion.

thinkyhead avatar Nov 08 '21 14:11 thinkyhead