Arc Tolerance
Just my humble opinion but I think this should go in 2.7 as it fixes a long standing error in the code with mismatched tolerance for arcs.
JT
I am quite happy to do a patch for 2.7 too
Don't know where it is located however, I thought they were branches on linuxcnc.git, but the clone I made only has the one branch, master.
Please Log in or Create an account to join the conversation.
git checkout branch_name
The naming for branches from 2.6 and up is just 2.6 and 2.7. They used to be a convoluted v2.4_branch.
To list all branches do:
git branch -r
Wow there is a lot of branches!
JT
Please Log in or Create an account to join the conversation.
To get a branch just do:
To list all branches do:
git branch -r
That just shows the holes in my git-fu
The man page says that command is to list remote branches, I was using just git branch to show the local ones for this clone, obviously not correct.
Like you say, muchos branches
Please Log in or Create an account to join the conversation.
commit 2cc22013dfdbd33ceba36570ed78711e0d310e99
Author: Sebastian Kuzminsky <This email address is being protected from spambots. You need JavaScript enabled to view it.>
Date: Sun Dec 21 19:35:32 2014 -0700
interp: use the same arc radius tolerance in inch and metric
Signed-off-by: Sebastian Kuzminsky <This email address is being protected from spambots. You need JavaScript enabled to view it.>
I am chasing my tail here.
I'll wait and see if Dewey wants to go ahead with the rest of the patch
regards
Please Log in or Create an account to join the conversation.
JT
Please Log in or Create an account to join the conversation.
<seb_kuzminsky> JT_Shop: cradek had the very sensible idea of making the arc tolerance so large that any valid arc in "imperial rounded to 3 figures after the decimal point" or "metric rounded to 2 figures" would be accepted
Reading back there was quite a bit of discussion on arcs lately.
JT
Please Log in or Create an account to join the conversation.
Got busy on my end and just got back to learning more just today. I want to thank you all for taking the time to look into this. I am blown away by your interest in the issue and just by what you found out by looking at it (the difference between mm/inch).
My internet searches revealed that the topic does come up all over the place (various package Cam forums) with Lcnc users, and the answer has always been to fix the cam output. Perhaps some "cam" programs will always have trouble keeping things within the defined limits.
I have to wonder what it was that prompted the developers of the control I have used all these years to add the tolerance option. I am going to assume it has been there since 1998 or so, because I have been using the same program to create code and run on the control.
In any event, it would be wonderful to have this adjust-ability via INI if that is where it fits.
I have been able to wrap up my wiring and actually run some files. I have plenty of them that do not use arcs, just short line segments. I'm finding a few things here and there that surprise me, but I am making good headway. With the machine moving, homing, running files and me getting familiar with gmoccapy, my next step is to thoroughly read documentation so I am not asking silly questions in the future.
THANK YOU for all the assistance !
Please Log in or Create an account to join the conversation.
- seb_kuzminsky
- Offline
- Administrator
- Posts: 64
- Thank you received: 14
1. The default tolerance (if none is specified in the ini file) should be 2 * 0.001 * sqrt(2) for inch, and 2 * 0.01 * sqrt(2) for mm. This would mean that any valid arc where the endpoints and/or centerpoint got rounded or truncated to 0.001 inch or 0.01 mm precision would be accepted, which i think would be a good default behavior. I've verified that Rob Ellenberg's new trajectory planner in 2.7 handles this amount of arc radius slop just fine.
2. I'd like the values in the ini file to be bounded. The largest acceptable value should be the defaults above, and the smallest acceptable should be 0.
Sound good?
Thanks for your work on this.
Please Log in or Create an account to join the conversation.
Once I have figured out how those tests need changing and it is fully tested will port across for 2.7 too
regards
Please Log in or Create an account to join the conversation.
The default arc tolerance is set to the figures you suggested, which equate to
TOLERANCE_INCH 0.0028
TOLERANCE_MM 0.0282
The minimum has been set to
MIN_TOLERANCE_INCH 0.00004
MIN_TOLERANCE_MM 0.001
which is 1 micron and imperial equivalent +/-
Attempting to go down to 0 will produce errors such as abs_err = 2.2e-16 rel_err = 0.0000% .
1 micron is probably fine enough!
Patch submitted direct also
regards
Please Log in or Create an account to join the conversation.