Auto Home when Linux CNC starts
28 Dec 2018 05:41 - 28 Dec 2018 08:18 #123002
by CrashCNC
Auto Home when Linux CNC starts was created by CrashCNC
Is there a way to automatically home when Axis starts?
What can be added to the .ini? Or does it need to be a custom HAL function? linuxcnc.org/docs/2.4/html/gui_halui.html
Matt
What can be added to the .ini? Or does it need to be a custom HAL function? linuxcnc.org/docs/2.4/html/gui_halui.html
Matt
Last edit: 28 Dec 2018 08:18 by CrashCNC.
Please Log in or Create an account to join the conversation.
28 Dec 2018 23:26 #123041
by cmorley
Replied by cmorley on topic Auto Home when Linux CNC starts
I would try loading a python program that sets homing using the python linuxcnc module.
Something like:
Something like:
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import linuxcnc
c = linuxcnc.command()
c.home(-1)
c.wait_complete()
Please Log in or Create an account to join the conversation.
29 Dec 2018 05:20 #123054
by CrashCNC
Replied by CrashCNC on topic Auto Home when Linux CNC starts
Good idea.
I'm familiar with the python script but have no idea how to make that code automatically launch when starting the axis GUI.
Any insight?
I'm familiar with the python script but have no idea how to make that code automatically launch when starting the axis GUI.
Any insight?
Please Log in or Create an account to join the conversation.
29 Dec 2018 08:26 #123057
by cmorley
Replied by cmorley on topic Auto Home when Linux CNC starts
load it with HAL in the post_gui file:
loadusr python PATH_OF_SCRIPT
would probably work, but you would need to add to the script to clear estop and turn the machine on.
I must say it scares me a bit about what you are doing... I hope you have a good reason and safety plan
Chris M
loadusr python PATH_OF_SCRIPT
would probably work, but you would need to add to the script to clear estop and turn the machine on.
I must say it scares me a bit about what you are doing... I hope you have a good reason and safety plan
Chris M
Please Log in or Create an account to join the conversation.
30 Dec 2018 23:38 #123176
by newbynobi
Replied by newbynobi on topic Auto Home when Linux CNC starts
Have you seen NO_FORCE_HOMING in INI settings?
Or execute the python script through halui.machine_is_on
What you are doing is dangerous, so do not blame anyboddy if something goes wrong!
Norbert
Or execute the python script through halui.machine_is_on
What you are doing is dangerous, so do not blame anyboddy if something goes wrong!
Norbert
Please Log in or Create an account to join the conversation.
Time to create page: 0.064 seconds