Exit linuxcnc

More
01 May 2022 07:11 #241773 by mgm
Exit linuxcnc was created by mgm
Is there a way that when linuxcnc exits, it can automatically go to a park position?
Background:
Before linuxcnc can be terminated the x axis must be in front of my spindle support, otherwise I have a problem with the next homing.

Please Log in or Create an account to join the conversation.

More
01 May 2022 08:24 #241775 by robertspark
Replied by robertspark on topic Exit linuxcnc
linuxcnc.org/docs/devel/html/config/ini-config.html

about half way down the page

SHUTDOWN = shutdown.hal - Execute the file shutdown.hal when LinuxCNC is exiting. Depending on the hardware drivers used, this may make it possible to set outputs to defined values when LinuxCNC is exited normally. However, because there is no guarantee this file will be executed (for instance, in the case of a computer crash) it is not a replacement for a proper physical e-stop chain or other protections against software failure.

there are may examples in the forum for different things (like to turn off compressors etc). best to do a bit of research and reading as I've not don't it before

Please Log in or Create an account to join the conversation.

More
01 May 2022 10:30 #241789 by mgm
Replied by mgm on topic Exit linuxcnc
I have already found this one.
Also I have looked at the compressor!

But I need a possibility before the end of the program, because the x axis must still perform a movement!

Please Log in or Create an account to join the conversation.

More
01 May 2022 11:13 #241791 by robertspark
Replied by robertspark on topic Exit linuxcnc
the easy way to do it would be just to alter your post processor to have a bit at the end that sends the torch to a park position at the end of every cut sequence.

That is what I do so that the machine is away from where I am loading materials onto the table.

there is also this thread too
forum.linuxcnc.org/49-basic-configuratio...application-shutdown

Please Log in or Create an account to join the conversation.

More
01 May 2022 23:19 #241819 by andypugh
Replied by andypugh on topic Exit linuxcnc
Changing the postprocessor to add a move before the M2 might be the most reliable way.

G28 and / or G30 are probably the best codes to add.

linuxcnc.org/docs/stable/html/gcode/g-code.html#gcode:g28-g28.1

Please Log in or Create an account to join the conversation.

More
02 May 2022 20:41 #241878 by mgm
Replied by mgm on topic Exit linuxcnc
Thank you for your suggestions. I'll keep them all in mind, I'm already using the parking position before m2.
Since my x axis is 3000 mm long and I am milling right and left parts the z axis is either near 0 or near 2500 mm. I would avoid unnecessary back and forth.

I had imagined something like:
When I want to deactivate the machine it checks where the x axis is.
If it is below 700 mm everything is ok if not the axis should move close to 700 and only then can be deactivated.

Could this be done with a halcomponente.
I already use one to control my spindle support.

If this is possible, how is it written and in which language?

Please Log in or Create an account to join the conversation.

More
02 May 2022 21:42 #241884 by andypugh
Replied by andypugh on topic Exit linuxcnc
User-space Python HAL components can issue MDI commands to move axes. That might be an option.

linuxcnc.org/docs/stable/html/hal/halmodule.html
linuxcnc.org/docs/stable/html/config/python-interface.html

Please Log in or Create an account to join the conversation.

More
03 May 2022 14:54 #241919 by mgm
Replied by mgm on topic Exit linuxcnc
I have now changed the file "axisrc" as Nicolas (furynick) has done.
forum.linuxcnc.org/49-basic-configuratio...tion-shutdown#226443

This is for me now the fastest way.
With theĀ  Python HAL components the learning curve is currently too steep for me!

Thanks to all for the support!

Please Log in or Create an account to join the conversation.

More
03 May 2022 15:34 #241922 by robertspark
Replied by robertspark on topic Exit linuxcnc
If it works for you then it works, glad to have tried to help.

Please Log in or Create an account to join the conversation.

Time to create page: 0.281 seconds
Powered by Kunena Forum