> Am 26.08.2012 um 15:56 schrieb andy pugh:
> > On 26 August 2012 14:04, Michael Haberler <mai...@mah.priv.at> wrote:
> > 
> >> Taking all G7x[.y]/G8x.[y] and writing equivalent new codes eg
G17x[.y]/G18x.[y] in NGC and a bit of Python is possible without any C++.
> > 
> > I am not sure how the G-code can search itself for a profile 
> > definition and parse it. Doesn't that require code introspection?
>
> for using the the thing, the choices are:
> - redefine the builtin  G7x[.y]/G8x.[y] cycles with an optional remapping
config; if the remap statements are disabled the builtin cycles reappear.
But as I said, this needs minor C++ tweakage per > redefined code.
> - just add new ones like in the G17x[.y]/G18x.[y] range - no C++ tweaking
required, but that shows on the usage level - either use say G84 for builtin
or G184 for the remapped cycle.

For most or all of the existing cycles, I can see how moving them out to
remap would work. They take a bunch of parameters, and a location to do the
first cycle at. They then run the cycle at each set of co-ordinates until
they receive a G80. Each of the canned cycles needs nothing more than it's
parameters, they don't need to know where the next cycle will be run, and
the parameters don't change between runs.

For G71 it needs to be able to read the entirety of an arbitrary profile -
which could be anything from 2 g-code blocks to 5000 (or more) blocks. The
profile can be before the G71 cycle command, or after it. The same profile
will usually be used at least twice (G71 then G70). To make it even more
confusing, the profile could theoretically be after M2/M30 so that it is
never accidentally executed.

The profile must contain at least 1 G0 or G1 command, with G2/3 needed for
any arcs, if I'm reading the remap docs correctly, these would break it out
of remapping.

In the patches I added code to rs274ngc_pre.cc which does this readahead -
and then returns execution back to the same point to actually process the
copied blocks, if that section was cleaned up and thoroughly checked all the
rest of the cycle code could be done using remapping, but without it (or an
equivalent) there doesn't seem to be any way to get the data needed.

That said, I'm not exactly familiar with the way remapping has been
implemented, so I could be missing a really obvious command

Ben



------------------------------------------------------------------------------
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

Reply via email to