Error message "Radius to end of arc differs....etc etc"

More
15 Jan 2025 22:01 #319056 by rodw
Try setting the arc distance mode at the beginning of the program
linuxcnc.org/docs/stable/html/gcode/g-co...ml#gcode:g90.1-g91.1
some times the code is in absolute mode and QTplasmac is expecting relative mode or vice versa.

Please Log in or Create an account to join the conversation.

More
15 Jan 2025 22:29 #319060 by gekonko
Thank you for your response, but I forgot to include it in the .ngc file - I have tested it before and it does not help in my case.

Please Log in or Create an account to join the conversation.

More
16 Jan 2025 00:23 #319065 by phillc54
Some things look odd with your gcode file:

The first N12760 should be commented out.
The second N12760 should have a J value of -89.450, not -89.500
N12770 should not be commented out.
The second N12800 should have a J value of 89.450, not -89.400

This comment at the top ";File converted successfully;" hints that a conversion was done somewhere, I don't think that it was successful.

This gcode loads:
Warning: Spoiler!

 

Please Log in or Create an account to join the conversation.

More
16 Jan 2025 09:14 #319102 by gekonko
@phillc54:
I really shouldnt post at midnight. You are right. Lines with R90 were added by me manually and should be commented out.

"The second N12760 should have a J value of -89.450, not -89.500"
- yes and no, really. From the CAM the precision is fixed to 0.1 so therefore it is "correct" in this case. I really just need to adjust tolerance in linuxcnc somehow, because no possibility to change presision in cam. 

The source G-code is originally generated for esab NCE290. ";File converted successfully;" Means, it went trough parser which converts it to linuxcnc readable code without unknown command confilct (values are not checked).

If you are interested, there is complete program from CAM.

 

File Attachment:

File Name: pre00937001.txt
File Size:10 KB

just to show you, how the code looks before


 

File Attachment:

File Name: post00937001.ngc
File Size:34 KB

after converting to Linuxcnc readable code
Attachments:

Please Log in or Create an account to join the conversation.

More
17 Jan 2025 00:48 #319151 by phillc54
It seems that the docs differ slightly with the code in regards to CENTER_ARC_RADIUS_TOLERANCE_MM.

The docs  state that the default is 0.00127 yet the code  sets the default to 0.02828. 

It seems that the default value is also the maximum allowed and the minimum allowed is 0.001.
 

Please Log in or Create an account to join the conversation.

More
17 Jan 2025 07:56 #319160 by hmnijp
What a coincidence! 
Just yesterday I was experimenting with this parameter and noticed that the value cannot be increased.
It's really only in the range of
#define CENTER_ARC_RADIUS_TOLERANCE_MM (2 * 0.01 * M_SQRT2)
#define MIN_CENTER_ARC_RADIUS_TOLERANCE_MM 0.001
rs274ngc_pre.cc
0.001 < tolerance < 0.0225


I wanted to disable the ARC_RADIUS_TOLERANCE constraint and see how interpolation works with a large difference between the start and end radius. This could be used to do spiral interpolation by extending the g-code to g2.1 / g3.1 - just copy interp_arc.cc, but there would be no radius difference check.

 
Attachments:

Please Log in or Create an account to join the conversation.

More
17 Jan 2025 09:04 #319167 by hmnijp
minimal changes allow spiral interpolation with large radius differences
 
Attachments:

Please Log in or Create an account to join the conversation.

More
17 Jan 2025 16:51 #319191 by gekonko
hello hmnijp,
could you please elaborate on that? 
I have tryed to comment out this section of the code in interp_arc.cc and then make the build, but I still get error message.
CHKS((abs_err > spiral_abs_tolerance * 100.0) ||
          (rel_err > spiral_rel_tolerance && abs_err > spiral_abs_tolerance),
      _("Radius to end of arc differs from radius to start: "
       "start=(%c%.4f,%c%.4f) center=(%c%.4f,%c%.4f) end=(%c%.4f,%c%.4f) "
       "r1=%.4f r2=%.4f abs_err=%.4g rel_err=%.4f%%"),
       a, current_x, b, current_y, 
       a, *center_x, b, *center_y, 
       a, end_x, b, end_y, radius, radius2,
       abs_err, rel_err*100);

Please Log in or Create an account to join the conversation.

More
17 Jan 2025 17:17 #319194 by gekonko
ok, I got it, there is section for error generating with and without compensation.
thank you.

Please Log in or Create an account to join the conversation.

More
17 Jan 2025 17:54 - 17 Jan 2025 17:57 #319196 by hmnijp

hello hmnijp,
could you please elaborate on that? 
I have tryed to comment out this section of the code in interp_arc.cc and then make the build, but I still get error message.
CHKS((abs_err > spiral_abs_tolerance * 100.0) ||
          (rel_err > spiral_rel_tolerance && abs_err > spiral_abs_tolerance),
      _("Radius to end of arc differs from radius to start: "
       "start=(%c%.4f,%c%.4f) center=(%c%.4f,%c%.4f) end=(%c%.4f,%c%.4f) "
       "r1=%.4f r2=%.4f abs_err=%.4g rel_err=%.4f%%"),
       a, current_x, b, current_y, 
       a, *center_x, b, *center_y, 
       a, end_x, b, end_y, radius, radius2,
       abs_err, rel_err*100);

 



The simplest solution with minimal changes is to fix the upper limit in "interp_internal.hh" file:
#define CENTER_ARC_RADIUS_TOLERANCE_MM (2 * 0.01 * M_SQRT2)
for example
#define CENTER_ARC_RADIUS_TOLERANCE_MM 1.001

after that the setting in the ini file will allow to set a higher value than before 
Last edit: 17 Jan 2025 17:57 by hmnijp.
The following user(s) said Thank You: gekonko

Please Log in or Create an account to join the conversation.

Time to create page: 0.103 seconds
Powered by Kunena Forum