LinuxCNC 2.7.7
Steps to reproduce the issue:
1. Take sim axis_mm example configuration.
2. Change axis_1 parameters in INI file to:
# Second axis
[AXIS_1]
TYPE = LINEAR
HOME = 1400
MAX_VELOCITY = 1000
MAX_ACCELERATION = 5000
MIN_LIMIT = 141
MAX_LIMIT = 1420
FERROR = 1
MIN_FERROR = 0.5
HOME_OFFSET = 1396
HOMESEARCHVEL = 0
HOMELATCHVEL = 0
HOMEFINALVEL = 70
HOMEUSEINDEX = NO
HOMEIGNORELIMITS = NO
HOME_SEQUENCE = 0
1. Open this .ngc file:
G64 P0.01
G1 F10000 ; Misinterpreted line, X,Y taken as 0?
X0 Y10
X20 Y20
M30
1. Touch-off axes that the path should fit in machine limits.
2. Try to run the program.
3. LinuxCNC complaints:
_Program exceeds machine limits
Program exceeds machine minimum on axis Y_
While it shouldn’t
4. Choose run anyway. Notice how toolpath and liveplot are displayed.
5. Check Y bounds and Feed distance in File/Properties. They are wrong.
#1 – jepler 于 2016-10-20
Your guess about the interpretation of “G1 F10000” is approximately on target; the preview and bounds calculations assume that the start of a program is a number of preparatory G0 moves, which fully establish the starting coordinates; otherwise, some arbitrary value (possibly the origin of the active coordinate system?) is used instead.
Note that in linuxcnc there is no problem programming an F-number even when the active motion mode is G0 or G80, so if you can change your post to say “F10000” instead of “G1 F10000” you may be happier with how the preview and bounds check behave.
Revamping this code so that it does “something smarter” when the program doesn’t start with a series of G0 moves that fully establish the starting position is a topic for development, unfortunately not a simple bugfix.