On Fri, 2010-03-19 at 03:44 -0400, Binh Hoang wrote:
> I would first like to know if anyone out there has any other gui for emc2
> other then the ones that come with a normal load. 

There have been several specialized interfaces written for EMC over the
years but most are very specialized or have fallen away.

> I seem to be having
> problems with Tkemc . 

What is the specific problem?

> I would like to know how to change the file for Tkemc
> interface then be able to use it. Do I have to recompile this file when I am
> done changing it? 

No you would probably not have to recompile anything to use a variation
of Tkemc.  The Tcl/Tk programming language is a scripted language that
is read each time it runs.  You would need to know a bit of this
language in order to make successful and meaningful changes.  It is a
fairly easy language to learn enough to make some changes.

If you search for "tcl/tk documentation" you'll find quite a lot of
information.

I'm working with an older version of emc on this box.  The Tkemc script
is located in /usr/share/emc/tcl/tkemc.tcl if you are using a standard
install.  You'll need to change the file permissions in before you can
edit that file.  The terminal commands look a bit like this. (note that
the description of your pc will not be rayh at rayh-a64:)

r...@rayh-a64:~$ cd /usr/share/emc/
r...@rayh-a64:/usr/share/emc$ sudo chmod -R a+rwx tcl 
r...@rayh-a64:/usr/share/emc$ 

That should give you enough permissions to screw things up pretty well.

Now I'd make a backup of the original tkemc.tcl file in there.  You
should be able to do that with the file browser using a right mouse
click and copy then repeat and paste.  Or since you have a terminal open
anyway you can just type

r...@rayh-a64:/usr/share/emc/tcl$ cp tkemc.tcl tkemc.tcl.bak

You could name that backup copy anything that you like.  Just remember
where it is so that when you mess up the edited version you can get back
to the original.

Now all you have to do is click on the tkemc.tcl icon and you'll see the
text in an editor.  

As you begin to edit the Tcl/Tk script you should keep testing to see
that it still runs.  Right now I'm less interested in whether your edits
make emc do what you want as I'm interested in does the script run at
all.

For example, I searched for the color yellow and changed the first
instance it encountered to pink.  I save the file and restarted.  I saw
that the X in the position displays changed color.

Next I changed that pink to rose and emc failed to start.  The reason is
that there is no regularly defined color named rose in the standard
color listing.  But how do you find the error.  You will not get an easy
listing of the error messages unless you start up emc in a terminal
rather than from the menu.  If you open a terminal and type in 

r...@rayh-a64:~$ emc

You'll see a response something like this.

     EMC2 - 2.2.8
     Machine configuration directory is '/home/rayh/emc2/configs/sim-1'
     Machine configuration file is 'tkemc.ini'

If there is an error in the editing you've done you get a message like
this.
    
     Error in startup script: unknown color name "rose"
         (processing "-foreground" option)
         invoked from within
     "$pos0l config -foreground rose"
         (procedure "updateStatus" line 300)
         invoked from within
     "updateStatus"
         (file "/usr/share/emc/tcl/tkemc.tcl" line 2570)
     Shutting down and cleaning up EMC2...
     Cleanup done

TclTk's error messages are often difficult to understand but at least
you will get some hints as to what went wrong with your last edit.

I'd keep many intermediate copies while working.  I tend to name mine
tkemc1.tcl ... tkemc156.tcl.  Then I can go back as far as I need to to
get a copy that has all but the last stuff.

Good luck and get back to us with the problems you see with it and any
issues you have.

rayh



> Or is it like the ini file where I can change it and then
> run it? Any information about Gui's would be great I am just starting out
> using EMC2. Thank you and hope to hear from you experts soon.


------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
Emc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to