On Monday 17 March 2014 03:11:25 EBo did opine:

> On Mar 16 2014 10:23 AM, Gene Heskett wrote:
> >> ...
> > 
> > (debug,"messsage text = ",#100)
> > 
> > However, in your gcode routine, as you probe the corners, store the
> > #5063
> > into a named variable, then
> > (one of msg|debug|print "whichever corner = ", #<_name_of_var>)
> > 
> > Those globally _named vars are then available for other math uses
> > anywhere
> > in your program, even apparently available to a subsequently loaded
> > gcode
> > routine as long as a reboot has not been done.
> 
> The last time I tried playing with named vars was teaching someone to
> program g-code/  The named vars did not seem to work, but that was with
> v2.5.0 (I think).  When was named vars put in?

I don't recall the exact timing, but someplace in the time frame of 2.5.0 
to the current 2.5.3+gitnumber, someone mentioned it, I found it worked and 
I've used a lot of them since.  The syntax is complex, and typo's in the 
wrappers are my major errors in using them. The difference between a local 
var and a global is beginning the name with an underscore for _globals.

By being able to name the var, its a lot easier for this old fart to keep 
track of what he is doing in a longer program, usually where I define 
longer is several subroutines, sometimes nested, and the whole thing is 
maybe 90 to 100 LOC even if it takes days to run.

#1000 is a numbered var, no clue for sure but I think its global.
It is not something I have specifically written code to test.

#<startx> is a var local to the current subroutine
#<_startx> is a global var that is available to any subroutine and even to 
the next batch of gcode loaded if the next file doesn't redefine it,  That 
surprised me when I discovered it, but no idea if that has now gone away as 
on a balance it could be dangerous, so it wouldn't bother me if it did go 
away.

>    EBo --
> 
> 
> ------------------------------------------------------------------------
> ------ Learn Graph Databases - Download FREE O'Reilly Book
> "Graph Databases" is the definitive new guide to graph databases and
> their applications. Written by three acclaimed leaders in the field,
> this first edition is now available. Download your free book today!
> http://p.sf.net/sfu/13534_NeoTech
> _______________________________________________
> Emc-developers mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/emc-developers


Cheers, Gene
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
Genes Web page <http://geneslinuxbox.net:6309/gene>


------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech
_______________________________________________
Emc-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-developers

Reply via email to