gcode-estimator icon indicating copy to clipboard operation
gcode-estimator copied to clipboard

Better support for length estimation with G02 & G03

Open pyrech opened this issue 1 year ago • 3 comments

G02 and G03 are gcode commands doing arc moving, so the current length estimations are not exact for those commands.

Here is a french explanation of the commands: https://www.e-techno-tutos.com/2018/06/10/gcode-g02-g03/

pyrech avatar Jun 03 '24 09:06 pyrech

I created a simple model to test. The G2/G3 commands are only used in Prusa if the Arc setting is turned on. I'm not sure about the other slicers (yet). However, the estimated provided by Prusa Slicer doesn't change, so I'm not certain how much this will actually affect the totals.

Also, I ran the same model on two slicers (Prusa & Bambu) and got the following: Prusa Slicer Estimate: 72.62 Gcode-Estimator: 71.82218

Bambu Slicer Estimate: 69.92 Gcode-Estimator: 68.11578

Orca Slicer Estimate: 114.99 Gcode-Estimator: 79.08641

Cura 5.4 Slicer Estimate: 52.1109 GCode-Estimator: 72.81091

Cura 4.8 Slicer Estimate: 25.8882 GCode-Estimator: 46.58828

There seems to be a small discrepancy, but it may be insignificant.

cdburgess avatar Dec 27 '24 19:12 cdburgess

Thanks a lot for the detailled information and your research 💛

That's a good news that the estimation is not too far from the slicer's computed length.

I do not have time for now to invest on this topic but if someone want to give a try to add support for these two gcode, PR will be more than welcome 😉

pyrech avatar Dec 27 '24 20:12 pyrech

After further review. I'm not certain how anything can be done in the code to make any difference for the discrepancies. It seems the code is running the correct estimations based on the E parameter. I would think the slicer may be the issue. Given that this code cannot modify the gcode output from the slicer, I would say the estimations are as accurate as they can be for any gcode file output by any slicer.

cdburgess avatar Dec 27 '24 22:12 cdburgess