Toolpath oscillates

Here's the place for discussion related to CAM/CNC and the development of the Path module.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
dickelec
Posts: 5
Joined: Sat Apr 23, 2022 7:13 pm

Toolpath oscillates

Post by dickelec »

OS: Ubuntu 22.04.1 LTS (KDE/plasma)
Word size of FreeCAD: 64-bit
Version: 0.21.0.31709 (Git) AppImage
Build type: Release
Branch: master
Hash: e188802ca6997d2564e7570ab648462e6a059f87
Python 3.10.8, Qt 5.15.6, Coin 4.0.0, Vtk 9.1.0, OCC 7.6.3
Locale: English/United Kingdom (en_GB)
Installed mods:
* Curves 0.6.5

I am in the process of creating a guitar fret board for a Telecaster style guitar. I have come across a problem whereby the tool oscillates backwards and forwards for several dozen cycles before continuing a little further and then repeating and repeating. The fret board has a curved top surface and the nut end is finished with a concave cut. It is in creating the tool path for this concave cut using 3d surface that the problem arises. I have generated a model of just the end portion of the fret board to demonstrate the problem. Examining the generated g-code or running the simulator reveals the problem.

I should add that problem has not stopped me successfully machining a fret board but, whilst performing this cut, the behavior of the CNC router is somewhat alarming. Also, my computer takes 40 minutes to calculate this path.
I include the FreeCAD file. I would have added the g-code file but the .ngc file is not accepted by the attachment editor.
Attachments
CurvedEndDemo.FCStd
(70.51 KiB) Downloaded 21 times
GeneFC
Veteran
Posts: 5373
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Toolpath oscillates

Post by GeneFC »

dickelec wrote: Wed Feb 01, 2023 11:31 pm
I played with this for a while. It seems the problem is related to the use of "offset" as the pattern strategy. If I switch to "line" the process is almost instant, and the resulting path looks good.

I do not know why, but the meshing algorithm seems to choke when using "offset". I use offset frequently, so it is not some fundamental problem, just difficulty with this particular shape.

You can easily attach a g-code file by changing the extension to ".txt".

Gene
dickelec
Posts: 5
Joined: Sat Apr 23, 2022 7:13 pm

Re: Toolpath oscillates

Post by dickelec »

Thank you GeneFC for your speedy reply. I have used the zigzag pattern with complete success.
I should like to add how impressed I am by FreeCAD's capabilities. As my first proper project, I have drawn, generated the gcode and machined all the wooden parts of a Telecaster style Guitar. Fabulous!
Post Reply