Check for gcmc executable was made only if 1 or more gcmc files specified
by ini items like [DISPLAY]NGCGUI_SUBFILE=cpocket.gcmc but was not
checked on use if there were no gcmc ini items
Thanks to forum user phillc54 for the bug report
Signed-off-by: Dewey Garrett <dgarrett@panix.com>
using ps -C linuxcncsvr --noheader -o args
both pyngcgui and gremlin view can be started independently
of the process running linuxcnc so they ask the system for
the inifile
Signed-off-by: Dewey Garrett <dgarrett@panix.com>
The options of pgrep (package procps) changed between:
lucid: procps 1:3.2.8-1ubunt
jessie: procps 2:3.3.9-9
pgrep -lf worked on lucid but not on jessie
pgrep -a worked on jessie but not on lucid
so try the form ps ax|grep ...
ref: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=784143
Signed-off-by: Dewey Garrett <dgarrett@panix.com>
limit msg length for popups when errant input to gcmc compiler
typo on strip()
for detecting options comment, split on // not /
minor: ngcgui.txt update
new: involute-gear.gcmc adapted for ngcgui from B. Stultien's example
new: ensure_mode.gcmd include file to resolve potential conflict
with preamble and gcmc code (gcmc wins)
with updates:
1) popup msg error if entry box for gcmc not a number
2) allow comment after tag when tagging a gcmc option
3) handle gcmc_include_path for new custom tab additions
4) incorporate ensure_mode in .gcmc examples
5) update ngcgui.txt for ensure_mode
(squashed commits from test branch: dgarr/ngcgui-gcmc)
Add support for [py]ngcgui to read .gcmc input files for the gcmc
compiler and make tab pages with entry boxes for tagged variables.
A tabpage 'info' message and compiler options can be specified
by tags too.
Ref: gcmc (G-Code Meta Compiler) http://www.vagrearg.org/content/gcmc
Note: gcmc version 1.4.3 or later must be installed separately and
available in the user PATH
--------------------------------------------------------------------
Tag formats (simplified):
Variable:
//ngcgui: vname [= value , [comment text]]
Info message:
//ngcgui: info: text message
Option:
//ngcgui: -optioname [optionvalue]
--------------------------------------------------------------------
When a feature for a gcmc tab page is created, the variables
and options are passed to the compiler and a gcode subroutine
file is produced and placed at the head of the linuxcnc subroutine
search path. These files are purged at each ngcgui restart
that uses .gcmc files.
--------------------------------------------------------------------
Example ini files for axis, touchy, and gscreen:
configs/sim/axis/ngcgui/ngcgui_gcmc.ini
configs/sim/axis/ngcgui/pyngcgui_gcmc.ini
configs/sim/touchy/ngcgui/pyngcgui_touchy_gcmc.ini
configs/sim/gscreen/ngcgui/pyngcgui_gscreen_gcmc.ini
Example gcmc files:
nc_files/gcmc_lib/drill.gcmc
nc_files/gcmc_lib/square.gcmc
nc_files/gcmc_lib/star.gcmc (Bertho Stultiens)
nc_files/gcmc_lib/wheels.gcmc (Alan Battersby)
use make to create simple standalone executable files for
ngcgui,pyngcgui,gremlin_view,tooledit
instead of copying files from source tree
to add this patch, you may need to rm existing files:
lib/python/gremlin_view.py
lib/python/pyngcgui.py
share/linuxcnc/gremlin_view.ui
2013-12-01 11:15:45 -07:00
Renamed from src/emc/usr_intf/pyngcgui.py (Browse further)