On Tue, Jan 27, 2009 at 06:56:26PM -0500, Eric H. Johnson wrote: > Hi all, > > A related question to the tangential tool configuration thread. When EMC > does an open g-code file, is there a way to interpose a preprocessor? For > instance, one which would take the selected file, calculate the A axis > rotation and interpose head lifts where necessary, and then pass that output > on to EMC for processing.
The AXIS user interface has a capability to preprocess files into gcode. This is in the manual. If your *starting point* is also gcode, then you can process it into a simpler and more regular representation with the 'rs274' binary. This is probably not documented anywhere yet. If test.var and test.tbl exist, here's how to process flowsnake.ngc into the 'canon call' format: rs274 -v test.var -t test.tbl -g flowsnake.ngc and here are a few lines from the output: 7 N..... START_SPINDLE_CLOCKWISE() 8 N..... STRAIGHT_TRAVERSE(0.0000, 0.0000, 1.0000, 0.0000, 0.0000, 0.0000) 9 N..... STRAIGHT_TRAVERSE(0.2500, 1.0000, 1.0000, 0.0000, 0.0000, 0.0000) 10 N..... SET_FEED_RATE(10.0000) (looks like rs274 doesn't print a whole 9 axes of information, it's stuck back at 6 axes) An *extensible* program to turn this "canon" representation back into gcode would make for some neat possibilities such as the one you're contemplating! This means you have to give up some of the more interesting parts of gcode, such as infinite loops and things that branch on the result of probes or other external inputs, but them's the breaks. Jeff ------------------------------------------------------------------------------ This SF.net email is sponsored by: SourcForge Community SourceForge wants to tell your story. http://p.sf.net/sfu/sf-spreadtheword _______________________________________________ Emc-developers mailing list Emc-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-developers