Initialize circle problem
first I'd like to say thank you for this excellent piece of software. I've used LinuxCNC for my home-build gantry router since version 2.5.0 and it done lots of jobs absolute perfectly.
Since upgrading to version 2.7.0 (and recently to 2.7.2) I've got a strange problem executing a bigger G code file (unfortunately in the middle of a job). I isolated the problem into a simple ngc-file (please see the attached file f_bad.ngc). After loading the file, the figure looks quite good in the preview window, but when executing the G code, the program statically stops showing the following error messages:
Failed to initialize Circle9, err codes 0, 0, 0, -1
can't add circular move at line 257, error code -1
At first I thought of a rounding problem but even changing the values in the mentioned line a little bit couldn't solve the problem. Only when I decreased the J parameter about 0.1 from 2.0168 to 1.9168 (see f_OK.ngc) the program could be fully executed (of course this also slightly changes the shape).
All files are generated by a slightly modified truetype-tracer (to mirror the direction) but the problem also occurs with the standard version (attached as f.ngc). Here are the calling parameters:
truetype-tracer -u -c 0.0035 -l 50 "f" > f.ngc
Also I haven't seen this problems for other letters, so I don't think that the truetype-tracer is the problem.
Then I checked this issue with an old 2.5.0 live image CD and the "bad" file will be executed like a charm. So it looks like a problem in the new version.
Can anybody confirm this behavior and can tell me how to avoid this problem?
At the moment I completely simulate every job in order to prevent that this problem occurs just while executing a real job.
If necessary, I can also provide a simulation configuration of my machine which allows a reproduction.
Many thanks for your advice
Please Log in or Create an account to join the conversation.
JT
Please Log in or Create an account to join the conversation.
thank your for your quick response. That sounds strange. Maybe the problem is caused by my configuration but I haven't seen this kind of error before and I can reproduce it statically. Well I've added the configuration files (the expanded ini because of my includes and the hal-file) of my simulation environment. I hope this will help to reproduce the problem.
Also I will do additional tests in order to get more informations (and maybe a solution). My only suggestion is, that I made a mistake when applying the config changes for the new LinuxCNC version.
Thanks
Please Log in or Create an account to join the conversation.
JT
Please Log in or Create an account to join the conversation.
Failed to initialize Circle9, err codes 0, 0, 0, -1
occurs in emc/src/tc.c part of the new trajectory planner
included first in 2.7
I modified your config so it would run without the items
which were reference files or directories that are local
to your system:
1) comment out [DISPLAY]PROGRAM_PREFIX
2) add instead [DISPLAY]PROGRAM_PREFIX = .
3) comment out [DISPLAY]NGCGUI lines
4) comment out [DISPLAY]EMBED*
5) comment out [DISPLAY]PYVCP*
6) comment out [APPLICATIONS]APPS=
7) comment out HALFILE=LIB:xhc-hbo4.tcl
I tested f_bad.ngc on:
Debian Jessie 66bit uspace --- no error
Debian Jessie 32bit uspace --- no error
Lucid Ubuntu 2.6.32-122-rtai --- ERROR same as posted by TurboTux
So i edited src/emc/tp/tp_debug.h to enable TP_DEBUG
Addtional details in /var/log/kern.log:
Finalizing tc id 257, type 2
blend_prev = 0, term_cond = 3
min_radius = 0x1.5633AE916EEEBP+9, effective_min_radius = 0x1.5633AE916EEEBP+9
acc_ratio_tan = 0x1.FFA8869916F58P-1
v_max 0x1.9P+6 is within limit of v_max_acc 0x1.E6E9C467F72AP+8
sample_maxvel = 0x1.4CDF1785D6C97P+7
Adding TC id 257 of type 2, total length 0x1.4A9955C934C47P-3
Segment 257, type 2 not finalized, continuing
optimization initial vel for segment 257 is 0x1.010B635ED6B67P+2
found peak due to v_limit
found peak due to v_limit
found peak due to v_limit
found peak due to v_limit
found peak due to v_limit
found peak due to v_limit
ini_maxvel = 0x1.9P+6
setting term condition 2 on tc id -1, type 2
radius = 0x1.2DB44231ED494P+9, angle = 0x1.188484BB21DA7P-12
spiral_coef = 0x1.D3401DE0E57E2P-31
Spiral fit: b0 = 0x1.C08ACCAEA44DDP-32, b1 = 0x1.2DB44231ED494P+9, length = 0x1.4A9955C639FA5P-3, spiral_in = 1
Spiral fit check: fit_err = 0x1.D649B9484FAC3P-16
Failed to initialize Circle9, err codes 0, 0, 0, -1
split time for id 238 is 0x1.9C6DBA972C577P-11
tc id 238 splitting
Doing tangent split
Finished tc id 238
Activate tc id = 238 target_vel = 0x1.0AAAAAAAAAAABP+2 req_vel = 0x1.0AAAAAAAAAAABP+2 final_vel = 0x1.62E525A8B4BEAP+4 length = 0x1.167E808ABAD78P-3
so this looks like a bug in the new trajectory planner that only shows up
for some kernels, for instance:
$ uname -a
Linux shop-lucid 2.6.32-122-rtai #rtai SMP Tue Jul 27 12:44:07 CDT 2010 i686 GNU/Linux
Please Log in or Create an account to join the conversation.
- rellenberg
- Offline
- Junior Member
- Posts: 37
- Thank you received: 10
Please Log in or Create an account to join the conversation.
@rellenberg: I will try your solution as soon as possible.
Very impressed greetings
Please Log in or Create an account to join the conversation.
If I had known that the problem also depends on the operation system version (of course I use the old kernel 2.6.32-122-rtai on my CNC computer) I should better told you so in my initial post - sorry. Thanks to dgarrett for finding out this important information.
Please Log in or Create an account to join the conversation.
- Segitarius
- Offline
- New Member
- Posts: 4
- Thank you received: 0
In my opinion there might be an other way to solve this issue. G64 P0.1 is a function that blends your path and eliminates tight radius and corners. Maby fixing system is not so very neceserry.
Please Log in or Create an account to join the conversation.