Difference (from prior major revision)
(minor diff)
Changed: 210c210
*** INCREMENTS
*** PREFERENCE_FILE_PATH = ~/.gscreen_preferences Allows one to specify the path and name of the preference file to use, otherwise all gscreens use the default one showm. the . at the beginning makes it a hidden file.
Changed: 212c212
*** MAX_SPINDLE_OVERRIDE
*** CYCLE_TIME = 100 The update time of Gscreen in milliseconds. Too low of a number uses too much CPU time making the screen laggy, too high makes it out of date. 50 is the minimum, there is no checked maximum. If this is missing 100 is the default
Changed: 214c214
*** MIN_SPINDLE_OVERRIDE
*** MAX_LINEAR_VELOCITY = 1.2 The maximuim velocity that the machine can be continuously JOGGED at
Changed: 216c216
*** MAX_FEED_OVERRIDE
*** DEFAULT_LINEAR_VELOCITY = .25 T deafult spped the machine will be continuously JOGGED at
Changed: 218c218
*** LATHE
*** INCREMENTS = 1 in, 0.1 in, 10 mil, 1 mil, 1mm, .1mm, 1/8000 in list of incremental jogging rates - note metric and imperial are accepted
Changed: 220c220
*** TOOL_EDITOR
*** MAX_SPINDLE_OVERRIDE = 1.25 Represents percentage of maximum override eg this is 125% of specified speed.
Changed: 222c222
** [TRAJ]
*** MIN_SPINDLE_OVERRIDE =.75 Represents percentage of minimum override. eg this is 75% od specified speed
Changed: 224c224
*** COORDINATES
*** MAX_FEED_OVERRIDE = 2.0 Represents percentage of maximum override eg this is 200% of specified speed.
Changed: 226c226
*** MAX_LINEAR_VELOCITY
*** LATHE = 1 Used to select if the display is used for a lathe. It is ok to have this missing, it's then assumed false.<br?
Changed: 228c228
*** MAX_VELOCITY
*** TOOL_EDITOR
Changed: 230c230,232
*** LINEAR_UNITS
*** GEOMETRY = Used by the gremlin plotter to select how the rotary axis will be displayed
** [TRAJ]
Changed: 232c234
*** AXIS_0
*** COORDINATES= List of axis that are to be displayed.
Changed: 234c236,240
*** GEOMETRY
*** MAX_VELOCITY= Maximum Velocity of the machine, used to calculate velocity override
*** LINEAR_UNITS= Used to set machine's native units
One thing to remember is if you use a custom screen option YOU are responsible for fixing it (if required) when updating linuxcnc.
* Local Glade files if present, local glade files in the config folder will be loaded instead of the stock glade files
There is a switch to set set the base name -c name or if you name them gscreen.glade you don't need the switch
Note when making changes it is far easier to add widgets then subtract widgets and still have the screen work properly
making objects 'not visible' is one way to change the display without getting errors - this won't always work some widgets will be set visible again
Changing the names of gscreens regular widgets is probably not gonna work well either - but moving a widget while keeping the name is usually workable
You can now tell Gscreen to just load the glade file and not connect it's internal signals to it - This allows gscreen to load any GTK builder saved glade file
This means you can display a completely custom screen
* handler files If present a handler file named gscreen_handler.py (or skinname_handler.py if using the switch) will be loaded and registered
only one file is allowed
There is a sample config called gscreen-gaxis
please see the gladevcp write-up about handler files
Here is gaxis and it's handler file:
There are special functions Gscreen checks the handler file for.
* initialize_widgets(self): You can use this to set up any widgets and or call Gscreen's widget initialization function by adding 'self.gscreen.initialize_widgets' or add 'pass' so no widgets are initialized. Gscreen's default initialization call now actually calls many separate functions. If you wish to incorporate some of those widgets then just call those functions directly.
* initialize_pins(self): Same idea for this - it initializes HAL pins
* periodic(self) This is called every 50 milliseconds - use it to update your widgets/HAL pins. you can call Gscreen regular periodic afterwards too, self.gscreen.update_position() or just add pass to not update anything. Gscreen's default initialization call now actually calls many separate functions. If you wish to incorporate some of those widgets then just call those functions directly.
* connect_signals(self,handlers): Same idea again. If you are using a completely different screen the default Gscreen you must add this or gscreen will try to connect signals to widgets that are not there. Gscreen's default function is called with self.gscreen.connect_signals(handlers) If you wish to just add extra signals to your screen but still want the default ones call this first then add more signals. If you signals are simple (no user data passed) then you can also use the GLADE signal selection in the GLADE editor.
* on_tool_change(self,widget) You can use this to override the manual tool change dialog -this is called when 'gscreen.tool-change' changes state.
Changed: 329c305
* dialog_return(self,widget,displaytype,pinname): use this to override any user message or manual tool change dialog. Called when the dialog is closed