Simple Remote Pendant (with 2.8.1) analog joystick values

More
09 Feb 2021 17:45 #198171 by jtrantow
I started adding more joypad functionality to my joypad .hal this morning. There is a bug hiding somewhere in the hal_input or usb driver for the joypad. When this bug occurs values for abs-x-position are using abs-hat0x-position values.

I got into this error condition by:
  • Use an invalid button name in my .hal so configuration failed.
  • Corrected .hal button name in my hal.
  • Configuration runs but the button are "miswired".
Recover by:
  • Exit configuration.
  • Unplug/plug the joypad.
  • Start configuration and everything is working again.

This explains what I was seeing a few days ago. Since this only occurs with an invalid .hal file, I'm not sure whether to file a problem report, but it does prove I'm not crazy. I will add a note to the wiki about unplugging if the .hal fails.

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

More
09 Feb 2021 23:20 - 09 Feb 2021 23:22 #198219 by andypugh

I updated the Simple Remote Pendant of the wiki.


Thanks.

The only thing I'd still like to do is figure out how to attach my joystick_xz.hal and joystick.xyz.hal files to the wiki so people don't have to cut and paste.


One way would be to attach them to a post here, and then put the links to the attachment in the Wiki. That gets the data onto a LinuxCNC server, at least. I see you found a better way, the "upload" button.
Last edit: 09 Feb 2021 23:22 by andypugh.

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

More
10 Feb 2021 01:31 #198236 by jtrantow
Yes, the upload zip file seems like the way to go.

I updated the HereIsHowToCheck page which was out of date and looked like a better place for some of the initial steps. I think these two pages now have all the information I wanted at the start of this effort.

I have a friend who isn't great with computers who also wants to get a joypad working. When he gets back from vacation I will have him run through the wiki as the real test.

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

More
03 Jan 2022 20:03 - 03 Jan 2022 20:04 #230676 by AgentWD40
Thank you for the updates, jtrantow.

I've just picked up a Logitech F310 and found that the device name is different as well as the button names compared to the wiki. But there was enough info in the wiki to point me in the right direction and I have my controller successfully jogging my machine.

I've reviewed hal_input.py and am left wondering where do the button names come from? Are the names assigned by the OS or does the device tell the OS the names? If it's the OS could updates rename buttons and break my config?
Last edit: 03 Jan 2022 20:04 by AgentWD40.

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

More
04 Jan 2022 20:02 #230794 by jtrantow
I believe the USB device reports capabilities to the hal_input driver via the standard USB descriptor and hal_input assigns names to each button/analog input it recognizes. If hal_input sees your device you can go into halmeter to see all the names and test.

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

Time to create page: 0.140 seconds
Powered by Kunena Forum