Hello!

I have been thinking about the problem to be solved and I have came to
2 questions that I do not know, how to solve in python:

1) for input I would like to use a path, defined with G01 and G02/G03
moves.
How do I tell the script to treat each segment in the line separately
- G0x, then X value and finally Y value?
2) how do I create something like "open file" option? And how do I
tell to process one line at a time?

I would like to ask more experienced programmers share some advice or
source of information, where to look for a clue :)

Viesturs

2011/3/28 Viesturs Lācis <[email protected]>:
> Hello, gentlemen!
>
> I have a question about creating g-code for a machine with awkward kinematics.
> Basically my problem can be reduced to following issue:
> How can I create g-code, if I know the path of tool in XY plane and a
> path in XZ plane? I have 2 paths that I have to merge together -
> execute simultaneously.
>
> How can I blend them together?
> Both lines contain straight lines and arcs, so since both of them
> contain X coordinates, that can be used as a reference. I think that
> easiest way would be splitting X in a ~0,5 mm increments and
> calculating corresponding Y and Z values (0,2-0,3 mm precision
> tolerance on the part is acceptable), because:
>    a) blending together arcs in 2 different planes will result in
> crazy shapes, like parabola or something similar;
>    b) somehow I belive that EMC can interpolate movement along 2
> axis, I have to move along 3 axis simultaneously.
> Does anyone have an idea, how to merge two lines together? Should I
> start with dxf or could I convert both contours to g-code and then use
> some custom python filter to merge them together? To ensure that both
> lines are synced by X coordinate, I would like to make it calculate Y
> and Z positions for certain X increments. How hard is that? Am I the
> only one who thinks that this approach makes any sense?
> This way would provide me with a following benefit: with inverse time
> feed rate I could ensure that material is moved with a constant speed
> (actually that is pretty important to move material with a constant
> speed). I understand that this approach means substantial length of
> g-code file, but that is o.k.
>
> Any ideas or suggestions (especially on the programming part) will be
> appreciated :)
>
> Viesturs
>

------------------------------------------------------------------------------
Create and publish websites with WebMatrix
Use the most popular FREE web apps or write code yourself; 
WebMatrix provides all the features you need to develop and 
publish your website. http://p.sf.net/sfu/ms-webmatrix-sf
_______________________________________________
Emc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to