Here are the steps I follow to reproduce the issue:
1. Creat a sub program (or subprogram file)
2. Creat a program that have while[1] , in while[1] call subprogram
3. Open this program by Linuxcnc gui (axis,gscreen,…)
This is what I expected to happen:
Program run normally
This is what happened instead:
Gui freezing when i open this program
Information about my hardware and software:
* I am using this Linuxcnc 2.8 on ubuntu 16.04
* I am using this kernel version (shown by uname -a): realtime preempt-rt 4.9.47-rt37
#1 – andypugh 于 2019-02-25
There probably should be a trap for this.
What is happening is that LinuxCNC is fine, but the graphical preview is stuck in an infinite loop.
There are workarounds, though I do think that maybe this classes as a bug.
You can use “magic comments” (AXIS, STOP) to a prevent the preview loop, though a cleverer way is to use the #<_task> parameter
O100 WHILE [#<_task> EQ -1.0]