I finally got it working! Thanks Eric.

Emcrsh is really quite neat.  A couple of observations though -
1. I checked the source code for emcrsh and it hard codes the relative
path "../../nc_files".  I think this doesn't make sense since it
precludes absolute paths and creates confusion by implementing relative
paths and hardcoded directories. I would either leave the path off or
allow it to be a parameter to emcrsh. Also the path is different from
the path specified in the .hal file.
2. When a file is finally opened the telnet session gets an ACK but the
Axis screen doesn't refresh. The filename on the title bar changes but
the code and the image in the path window doesn't update. This certainly
doesn't give you the warm fuzzy feeling that the right thing is going to
happen when you hit run!
3. Perhaps it is because my print out of the help text split
task_plan_init onto two pages but I wouldn't have guessed that I needed
to set task_plan_init before opening a file. I think this may have been
the reason that my previous attempts at moving nc_files around and
trying to open my test didn't work. Since I'm not sure how you can open
a file without calling task_plan_init maybe open should call it
automatically.
4. Occasionally when emc initializes it doesn't allow connections
through port 5007.  I'm not sure how to reproduce this but it happens
about 1 in 5 times.

Thanks again for everything - Mike

-----Original Message-----
From: Eric H. Johnson [mailto:ejohn...@camalytics.com] 
Sent: Wednesday, March 11, 2009 3:04 PM
To: 'Enhanced Machine Controller (EMC)'
Subject: Re: [Emc-users] How can I get emc toautomatically run g-code
without an operator?

Michael,

Sorry, I was responding from memory and gave you the wrong path. It is
relative to the nc_files folder ($HOME/emc2/nc_files by default). At any
rate do the following:

In your hal file add the line:
loadusr emcrsh
IOW, with no parameters. To get it going we will use all of the
defaults.

For testing purposes you can use the sim tkemc configuration. Just add
the
above to core_sim.hal in the configs/sim folder.

Then telnet in and issue the following commands:

hello EMC client 1.0
set echo off
set verbose on
set enable EMCTOO
set task_plan_init
set mode auto
set open examples/3D_Chips.ngc

This should load the 3D_Chips.ngc example program.

I turned verbose on so that you get more informative error messages. The
remainder is the sequence I use when loading a new program.

Regards,
Eric


Eric,
Thanks for the response but I still can't convince the "set open
test.ngc"
command to work. I've moved the nc_files directory all over the machine
to
no avail. The relative directory error message, of course, is less than
helpful. I think the trick will be to get the -ini method working. If I
could explicitly specify the path then debugging would be easier.  Has
anyone gotten the "set open" method working on Ubuntu? If so, please
shed
some light.

Rafael,
I think your points are valid but they don't simply apply to linux
novices.
Relative paths without a well documented root are difficult to work with
and
confusing even to folks like me with 30 years of software experience!


------------------------------------------------------------------------
------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based
development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com
_______________________________________________
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to