A basic .hal file for a simple gamepad
- juergen-home
- Offline
- Junior Member
-
Less
More
- Posts: 39
- Thank you received: 12
12 Sep 2025 11:25 - 12 Sep 2025 11:28 #334877
by juergen-home
A basic .hal file for a simple gamepad was created by juergen-home
This is a basic .hal file for a simple gamepad.
I use this for manual milling on the diy cnc.
For my safety I removed the joysticks and only use the buttons pressed by a 3d printed plug.
#
# jog with 1,2,3,4,11,12
# select jog speed with 9,10
# select increment with 5,6,7,8
# start program with 16
# pause program with 14
# mist-coolant with 15
# e-stop with 13
#
I use this for manual milling on the diy cnc.
For my safety I removed the joysticks and only use the buttons pressed by a 3d printed plug.
#
# jog with 1,2,3,4,11,12
# select jog speed with 9,10
# select increment with 5,6,7,8
# start program with 16
# pause program with 14
# mist-coolant with 15
# e-stop with 13
#
Last edit: 12 Sep 2025 11:28 by juergen-home.
The following user(s) said Thank You: andypugh, tommylight, jpg
Please Log in or Create an account to join the conversation.
- juergen-home
- Offline
- Junior Member
-
Less
More
- Posts: 39
- Thank you received: 12
10 Oct 2025 08:53 #336185
by juergen-home
Replied by juergen-home on topic A basic .hal file for a simple gamepad
I found a safety issue with the toggle2nist function in my gamepad.hal file.
if you e-stop while switching in pause, than switch on and start program again, pause will often not work.
this is a safety problem if you want to trust your pause function.
Therfore I use a special version of toggle2nist: forum.linuxcnc post 05 Oct 2025 18:50 #335873 special toggle2nist.comp from user Aciera. You have to compile that in by hand.
www.forum.linuxcnc.org/24-hal-components...ton-at-the-same-time
With "pulse-length" parameter set to 50 the problem of the hanging pause is gone.
Therefore, the default toggle positioned before the toggle2nist component must be removed across all implementations to ensure correct toggle functionality.
also changed: e-stop with 13 to stop with 13
if you e-stop while switching in pause, than switch on and start program again, pause will often not work.
this is a safety problem if you want to trust your pause function.
Therfore I use a special version of toggle2nist: forum.linuxcnc post 05 Oct 2025 18:50 #335873 special toggle2nist.comp from user Aciera. You have to compile that in by hand.
www.forum.linuxcnc.org/24-hal-components...ton-at-the-same-time
With "pulse-length" parameter set to 50 the problem of the hanging pause is gone.
Therefore, the default toggle positioned before the toggle2nist component must be removed across all implementations to ensure correct toggle functionality.
also changed: e-stop with 13 to stop with 13
Attachments:
Please Log in or Create an account to join the conversation.
Time to create page: 0.090 seconds