Re: [Emc-users] subroutines and run from line

2012-10-22 Thread Michael Haberler

Am 20.10.2012 um 22:18 schrieb Jon Elson:

 Jon Elson wrote:
 Michael Haberler wrote:
 
 the - somewhat brittle - run-from-line feature has seen several fixes 
 related to this, both by cradek and me, in 2.5, see
 
 
 
 I have another machine with a brand-new build from master, so I will 
 test on that one.
 I should have thought of doing that first!
 
 Brittle is right!  I tested it on the system I just built from master 
 last week, 2.6.0~pre,
 and it does exactly the same thing.  If I select the line with the G01 move,
 and do run from line, it performs that move, but never executes the 
 subroutine.
 It sits there in some in-between state, forever.
 
 If anyone wants to work on it, the snippet of code I posted on 10/16
 is all you need.  The subroutine waits a second, does a small -Z move,
 turns on mist coolant for 2 seconds, waits 2 seconds, turns off
 coolant, waits a second and does a +Z move and returns.  If you
 want a longer copy of the program, email or reply to this message,
 I can send it.


Re 'working on it': no doubt someone could, somehow, patch the interpreter into 
submission to handle this or that case; I dont think this improves the overall 
situation.

the fundamental issue is that the concept of source location is still in it's 
pre-subroutine, pre-multiple gcode files state, and without a fundamental 
rework of line numbers into a more realistic source location which refers 
to file, linenumber, file type, and call context (definition or reference) this 
is not going to bring about better quality. This is a quite far-reaching change 
because it goes all the way from NGC source file to motion and back - all this 
is currently handled through an integer line number which eventually mutates 
into a 'motion id'.
 
I've sketched some ideas about source location on the wiki a while ago which 
outline the principle; it needs updating though. 

It's one of the two major prerequisites I'd like to see adressed before 
carrying over any interpreter into LinuxCNC3; the other one being generalized 
handling of variable references (see QueuebustersRevisited on the wikie).

- Michael

 
 I'm afraid this behavior probably goes pretty deep into interpreter
 code that I have no understanding of, so I wouldn't have much luck
 researching it myself.
 
 Thanks,
 
 Jon
 
 --
 Everyone hates slow websites. So do we.
 Make your web apps faster with AppDynamics
 Download AppDynamics Lite for free today:
 http://p.sf.net/sfu/appdyn_sfd2d_oct
 ___
 Emc-users mailing list
 Emc-users@lists.sourceforge.net
 https://lists.sourceforge.net/lists/listinfo/emc-users


--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] subroutines and run from line

2012-10-21 Thread cogoman
On 10/20/2012 04:18 PM, Jon Elson wrote:
 If I select the line with the G01 move,
 and do run from line, it performs that move, but never executes the
 subroutine.
 It sits there in some in-between state, forever.
   I'm just throwing something in here with very limited knowledge of 
what's going on, but if Run from line can't see the subroutine (I make 
my very first assumption here, that the sub in in the main program), if 
you were to break the subroutine out to a separate file, would LinuxCNC 
see it there?  Perhaps a work around?

--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] subroutines and run from line

2012-10-20 Thread Jon Elson
Jon Elson wrote:
 Michael Haberler wrote:
   
 the - somewhat brittle - run-from-line feature has seen several fixes 
 related to this, both by cradek and me, in 2.5, see


 
 I have another machine with a brand-new build from master, so I will 
 test on that one.
 I should have thought of doing that first!
   
Brittle is right!  I tested it on the system I just built from master 
last week, 2.6.0~pre,
and it does exactly the same thing.  If I select the line with the G01 move,
and do run from line, it performs that move, but never executes the 
subroutine.
It sits there in some in-between state, forever.

If anyone wants to work on it, the snippet of code I posted on 10/16
is all you need.  The subroutine waits a second, does a small -Z move,
turns on mist coolant for 2 seconds, waits 2 seconds, turns off
coolant, waits a second and does a +Z move and returns.  If you
want a longer copy of the program, email or reply to this message,
I can send it.

I'm afraid this behavior probably goes pretty deep into interpreter
code that I have no understanding of, so I wouldn't have much luck
researching it myself.

Thanks,

Jon

--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Emc-users] subroutines and run from line

2012-10-17 Thread Schooner
All linked to this bug report I think, still not resolved, some of it 
was supposed to be fixed in the master.

sourceforge.net/tracker/?func=detailaid=3440704group_id=6744atid=106744

regards

--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] subroutines and run from line

2012-10-17 Thread Jon Elson
Michael Haberler wrote:
 the - somewhat brittle - run-from-line feature has seen several fixes related 
 to this, both by cradek and me, in 2.5, see

 http://git.mah.priv.at/gitweb/emc2-dev.git/commit/f9085e20130e744df8c239eb6df67654995062cd
 http://git.mah.priv.at/gitweb/emc2-dev.git/commit/9a21aa6fa588c7bd553ad133c84432e1e64bd89f
 http://git.mah.priv.at/gitweb/emc2-dev.git/commit/7034c8c5c755f06f6b190f0e7752ca7ac5fa00fd

 that said, my trust in this feature is so low that I suggest to try this in a 
 2.5 simulator version to make sure it does what you want
   
I have another machine with a brand-new build from master, so I will 
test on that one.
I should have thought of doing that first!

Thanks,

Jon

--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


[Emc-users] subroutines and run from line

2012-10-16 Thread Jon Elson
My production Bridgeport mill runs an older version, 2.0.4~pre,
built from the git repository.  To upgrade this system, I may
have to replace the computer, it is pretty aged and limited in
memory and CPU speed.

Anyway, I ran the following program last night:

N10 G61

N20 O100 SUB
N30   G01 F10 Z-0.02
N40   G04 P2
N50   M7
N60   G04 P2
N70   M9
N80   G04 P1
N90   G01 F10 Z.25
N100 O100 ENDSUB

N2020 G01 X8.364 Y-1.286 F60.0
N2030  O100 CALL
N2040 Y-1.443 F60.0
N2050  O100 CALL
N2060 Y-1.599 F60.0
N2070  O100 CALL
and so on, for 500 more iterations.

This program is for a prototype soldering robot.  So, the O100 sub
pushes the soldering tip down onto a connection, waits a moment
for it to heat, then feeds solder (M7) for a moment, dwells, and
then raises up.  This works fine when you run (R) the program, but
when you try to run from line at one of the (implied) G1 moves,
it makes that move and then just sits there.  Does the run from line
prevent the interpreter from discovering the subroutine, or is
there some other reason for the problem?  Will a 2.5.x version
also do this?

Thanks for any suggestions!

Jo n

--
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


[Emc-users] Subroutines

2012-05-19 Thread Terry Christophersen
Did how subroutines work change from 2.3 to 2.5?
I had a file I ran 6 months ago on 2.3 and with no changes just
moved it to the new computer w/2.5 and I get an error :
 
unable to open file
 
The sub is in the same program just at the bottom 
 
%
some code
 
o31 call    (is the line where the error is)
 
some other code
 
m30
(one line space here)
o31 sub
 
some code here
 
o31 endsub
%
 
 
Terry

--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Subroutines

2012-05-19 Thread Dave Caroline
On Sat, May 19, 2012 at 8:27 PM, Terry Christophersen
tcninj...@yahoo.com wrote:
 Did how subroutines work change from 2.3 to 2.5?
 I had a file I ran 6 months ago on 2.3 and with no changes just

I am not aware of any changes but the subroutines should be defined before use
http://www.linuxcnc.org/docview/html/gcode/o-code.html#sec:subroutines

o100 sub
  G53 G0 X0 Y0 Z0 (rapid move to machine home)
o100 endsub
...
o100 call (call the subroutine here)


Dave Caroline

--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users


Re: [Emc-users] Subroutines

2012-05-19 Thread Terry Christophersen
Thanks Dave taat worked,
So it did change sort of because I have 2.3 on a desktop and it worked at the 
end of the program

Thanks again

Terry

 
- Original Message -
From: Dave Caroline dave.thearchiv...@gmail.com
To: Terry Christophersen tcninj...@yahoo.com; Enhanced Machine Controller 
(EMC) emc-users@lists.sourceforge.net
Cc: 
Sent: Saturday, May 19, 2012 2:45 PM
Subject: Re: [Emc-users] Subroutines

On Sat, May 19, 2012 at 8:27 PM, Terry Christophersen
tcninj...@yahoo.com wrote:
 Did how subroutines work change from 2.3 to 2.5?
 I had a file I ran 6 months ago on 2.3 and with no changes just

I am not aware of any changes but the subroutines should be defined before use
http://www.linuxcnc.org/docview/html/gcode/o-code.html#sec:subroutines

o100 sub
  G53 G0 X0 Y0 Z0 (rapid move to machine home)
o100 endsub
...
o100 call (call the subroutine here)


Dave Caroline


--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users