I think of pyvcp in a different way. I think of it as a modular way to
simply add functionality to a gui.

What I would like to do is to provide a way for the interpreter to generate
traceback information so that when some gcode fails (for whatever reason),
the user can tell what line of gcode it failed in and how it got there. The
gcode subroutine facility makes this important and requires more than a
single line of output to be useful.

One simple way to do this, of course, is to just open a file, write the
file, and close the file. The user can then be directed to look at the file
by the usual error mechanism. He would probably do this using a terminal
window and the 'cat' command.

Another way would be to do it would be for the user to do this is to have
the file created before the program started. That way, the terminal window
could be started with a 'tail' command and when the error occurred, the
information would automatically appear in it. This has the disadvantage that
the file would continue to grow, without any real bound. Of course, it could
be truncated every time that emc was restarted.

A third way to do this is to use a 'fifo' AKA a 'named pipe'. The terminal
window would be started with a command to read the fifo (I'm not sure if
tail or cat will work in this case). This has the advantage that we don't
have a file that is growing without bound.

All of the above are pretty easy to implement. They all suffer from the
shortcoming that the user must start a terminal to look at the output.
Integrating that into the gui would be superior, I think.  To me, PyVCP
looks like a natural way to do this.

Is there something that I'm missing?

1 -- Am I wrong? Is the functionality (generating a traceback) that I want
to implement not necessary, or not important? Am I wasting my time worrying
about it?

2 -- Would my first way of implementing the functionality (just write the
info to a file and tell the user that it is there) be sufficient?  That's
easy. I can just do that.

3 -- Is there another simple way to integrate the traceback into a gui?

4 -- Is there a better way to get the info from the interpreter to the gui?
I've seen the suggestion of a linked list in shared memory, but it is hard
for me to see that as "better". A variable length linked list of variable
length strings in shared memory looks like a bug waiting to happen. Of
course, we could allocate space for a fixed number of fixed length strings.
I cheated in the interpreter and arbitrarily decided that the maximum
subroutine stack depth would be ten levels. We could allocate memory for ten
strings of 256 bytes each.

I'm open to suggestions. Even to the suggestion that I not bother with this.

Ken

[EMAIL PROTECTED]
Mark Kenny Products Company, LLC
55 Main Street                     Voice: (203)426-7166
Newtown, CT 06470                    Fax: (203)426-9138
http://www.MarkKenny.com


-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Jeff
Epler
Sent: Saturday, February 10, 2007 4:22 PM
To: EMC developers
Subject: Re: [Emc-developers] Can Someone Build This PyVCP Widget?


I don't know why you've latched on to this named pipe idea.

This is likely to make embedding an interpreter in AXIS harder than it
is now, for instance because the two interpreters will need to have
different named pipes.

This is also a completely inappropriate idea for pyvcp, which is a
program for displaying the state of HAL items.

Jeff

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job
easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Emc-developers mailing list
Emc-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-developers

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Emc-developers mailing list
Emc-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-developers

Reply via email to