Change the initial states of OPTIONAL_STOP and BLOCK-DELECT

More
3 years 10 months ago #259307 by CTB_le123
Hey, I want to change the initial states of optianal-stop and block-delect when I open the Linuxcnc. But I don't know how to change. Please help me!  Now the state is like piture 1, and I want to change the initial state to the picture 2. I have tried to write something in the .ini file but falied. Thank you!

Please Log in to join the conversation.

More
3 years 10 months ago #259399 by andypugh
These are both controlled by HAL pins, so you would need to add something to the HAL.
Code:
setp halui.program.block-delete.off 0 setp halui.program.block-delete.on 1 setp halui.program.optional-stop.off 0 setp halui.program.optional-stop.on 1

linuxcnc.org/docs/stable/html/man/man1/halui.1.html

Please Log in to join the conversation.

More
3 years 10 months ago #259407 by CTB_le123
Thank you for your replay.
I add these to my hal.
setp halui.program.block-delete.off 1
setp halui.program.block-delete.on 0
setp halui.program.optional-stop.off 1
setp halui.program.optional-stop.on 0
But it doesn't work.

The halshow show as the picture.
The result should be that the  halui.program.block-delete.is-on FALSE  and halui.program.optional-stop.is-on FALSE. It doesn't work as we wish.
 

Please Log in to join the conversation.

More
3 years 10 months ago #259408 by cmorley
What screen are you using? What version of linuxcnc?

Please Log in to join the conversation.

More
3 years 10 months ago #259413 by CTB_le123
I used the axis screen as the first picture. The version is 2.9.0~pre0.
The ini file as follow.

Please Log in to join the conversation.

More
3 years 10 months ago #259422 by cmorley
Try this:

in the ini under DISPLAY add:
USER_COMMAND_FILE=customize_axis.py

in the config folder add a file named customized_axis.py

in that file add:
c.set_block_delete(0)

if you want to adjust optional stop also add:
c.set_optional_stop(0)

Chris
 

Please Log in to join the conversation.

More
3 years 10 months ago #259424 by CTB_le123
Thank you for your help.
 I change as your advice,  I find the origin code is in the axis.py.

 

Please Log in to join the conversation.

Time to create page: 0.123 seconds
Powered by Kunena Forum