dave wrote:
>>
> Maybe this is a gentle hint to stay with linear programs. KISS
> has its advantages. 
> I do a lot of work with a few lines of C to write G code. 
> Yes it generates lots of lines but to my simple mind an easier way to
> go. ;-)
>   
Well,  but, but, splutter.....  I have all these nice little programs 
that write the G-code for particular things like slots and holes.
And, I had 24 identical slots to cut in a panel.  It seemed so LOGICAL 
to make this a subroutine and just position to a corner of each slot and 
turn the subroutine loose.  This way, the coordinates were all clumped 
together, only given once, and I could visually inspect for typos.
I could have edited the program to comment out the first couple 2-line 
pairs for the slots I didn't need to cut again, but it was easier to 
just re-run the whole program.

To make it a linear program, I would have had to run the slot generator 
program 24 times and type in the coordinates each time, then combine the 
output of these 24 program runs into one file, editing out the M02's.  
Manually typing in the coordinates that many times, I would have made a 
typo for sure.  By editing it the way I did, it made it possible to 
check it carefully and also duplicate and edit the coords to reduce the 
chance of error.  This part of the program would have expanded from 
about 60 lines to about 600 lines.

So, what DOES the interpreter do when you give a run-from-line and that 
line is a G01 move, and the next line is a subroutine call?
It appears to have skipped BOTH of these lines, which just seems 
bizarre.  If it performed each G01 but skipped over the subroutine, that 
might make some little bit of sense.  But, it appears to have even 
skipped the first G01 move, on the specified run-from line, which is 
hard to explain.


Jon

------------------------------------------------------------------------------

_______________________________________________
Emc-developers mailing list
Emc-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-developers

Reply via email to