HI Ralph,

One way to go about this is use python and linuxcnc python module.

you could initialize a headless setup with an ini parameter 
[DISPLAY](DISPLAY)=dummy (or your python script).

The python script connects to linuxcnc using API calls in the linuxcnc 
python module.
initialize the channels i.e., status, command and error, and switch to auto 
mode, load a file and send cycle start. 
Monitor the status channel for current mode and emergency status in your 
python script.

hope this helps.

-automata


On Wednesday, November 16, 2016 at 8:22:23 PM UTC+5:30, Ralph Stirling 
wrote:
>
> Thanks, Schooner.  I can hack on python code, but was hoping I didn't have 
> to start
> with axis, as that is a lot of stuff to rip out.  I won't have time to do 
> that for my immediate
> need, but I'll give it a go later.
>
> -- Ralph
>
> On Wednesday, November 16, 2016 at 1:13:10 AM UTC-8, Schooner wrote:
>>
>> Hi Ralph
>>
>> Without knowing what your programming capabilities are, the best I can 
>> suggest is to look at
>> Axis.
>>
>> When you strip out the GUI feedback and display, you will be able to see 
>> the python binding calls
>> that actually get settings from the ini file and then run a named .ngc 
>> file etc
>>
>> The advantage of hacking Axis would be that you can just leave the config 
>> files more or less 
>> as they are and gradually strip out the graphical bits, until left with a 
>> program that initiates
>> (whatever that might entail) and then starts to run a file.
>>
>> The command line would still be `machinekit inifilename.ini` with DISPLAY 
>> = in the ini file set to 
>> whatever you called you hacked Axis.
>> You could pass an extra arg for the .ngc file name if you write code to 
>> read that arg.
>>
>> A thought
>>
>>
>>
>> On 15/11/16 04:48, Ralph Stirling wrote:
>>
>> I am interested in using Machinekit BBB's as "automation appliances" in
>> my Manufacturing Systems lab.  Axis is handy for getting everything
>> going, but once the program, I/O, and HAL configuration are figured out,
>> it would be nice to unplug from the host PC and have it run headless.
>>
>> I can put a script in /etc/init.d, but haven't found a simple non-gui way 
>> of
>> running G-code.  I've looked at halcmd, hal_ui, and hal_run, but setting
>> everything up to read and run an ngc file appears daunting.  Ideally I'd 
>> like a program I can run from the command line, with arguments for the
>> ngc, ini, and hal files.
>>
>> Any suggestions or examples?
>>
>> Thanks,
>> -- Ralph
>> -- 
>> website: http://www.machinekit.io blog: http://blog.machinekit.io 
>> github: https://github.com/machinekit
>> --- 
>> You received this message because you are subscribed to the Google Groups 
>> "Machinekit" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to machinekit+...@googlegroups.com.
>> Visit this group at https://groups.google.com/group/machinekit.
>> For more options, visit https://groups.google.com/d/optout.
>>
>>
>>

-- 
website: http://www.machinekit.io blog: http://blog.machinekit.io github: 
https://github.com/machinekit
--- 
You received this message because you are subscribed to the Google Groups 
"Machinekit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to machinekit+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/machinekit.
For more options, visit https://groups.google.com/d/optout.

Reply via email to