Hi all!

Maybe you remember my question of a few weeks ago about a more flexible
way to transform the coordinates in a G-code file:
http://sourceforge.net/mailarchive/forum.php?thread_name=528A6D98.7080208%40hb9etc.ch&forum_name=emc-users

My decision was then, to do most of the transforms in Python and
generate the G-code as needed. I've now implemented most of that for my
use case (alignment of a PCB panel based on fiducial marks) with a
little Glade GUI. This works quite well, using the linuxcnc interface
from Python
(http://linuxcnc.org/docs/html/common/python-interface.html), it is
possible to read the current position, do the calculations, generate the
code, load and run it. Except for one thing: When I load the G-code
file, AXIS does not display a preview of the program, neither in the
code pane nor in the live plot. The file name is displayed in the
window's title bar however, and running it works and correctly draws the
backplot.

It is easy to test this in a Python console with LinuxCNC running:

$ python
Python 2.6.5 (r265:79063, Sep 26 2013, 18:51:09)
[GCC 4.4.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import linuxcnc
>>> lcmd=linuxcnc.command()
>>> lcmd.reset_interpreter()
>>> lcmd.mode(linuxcnc.MODE_AUTO)
>>> lcmd.program_open('/home/linuxcnc/linuxcnc/nc_files/simple_symbol.ngc')
>>> lcmd.auto(linuxcnc.AUTO_RUN, 1)

Does anyone have an idea what I could do to trigger the preview?
Clicking the Reload button in AXIS does nothing (no error message, just
nothing happens). Loading the same file from the AXIS menu shows the
expected behaviour, code and graphic preview is generated.

The preview is obviously not critical for this application, but it would
help to check if the alignment is correct (or at least not completely
off). Could anyone give me a hint how to solve that?

Thanks!

Best regards,
Philipp

Attachment: signature.asc
Description: OpenPGP digital signature

------------------------------------------------------------------------------
Rapidly troubleshoot problems before they affect your business. Most IT 
organizations don't have a clear picture of how application performance 
affects their revenue. With AppDynamics, you get 100% visibility into your 
Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics Pro!
http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to