Joystick competition pro usb

GetControlerName() return the device_name field handed by the kernel device, which is usb_hid.
Seems that this fiield is not set anymore, which will be a bug introduced when usb_joy was deprecated maybe.

How looks the Joystick preference window with this controler detected ?

I could not find this window at all so I can not tell you I’m afraid.

You said usb_joy is deprecated. Does this mean BJoystick is deprecated or is it just something in the kernel unrelated to the API at all.

usb_joy was the old driver for joysticks, it was replaced by the new usb_hid driver which implements the same device interface. BJoystick works with either, as well as old-style gameport joysticks where available.

The joystick preferences is not included in the default image. I tried to build it but it did not seem to work with my USB gamepad (it lists the port, but seems to thnk it should run a “detection” process to use a specific driver for each type of joystick, as was the case on gameports).

IIRC, one have to edit some joystick description file, which is loaded by JoystickTweaker to enhance and set more user-friendly and defined names to device features.

EDIT: giving a look to JoystickTwearker source, it show that indeed the device name (which GetControllerName() returns) and others descriptions are loaded, when found, from a joystick description file that should be located in /boot/home/config/settings/joysticks/ (for an USB joysticks, that would be …/joysticks/usb/0 etc), with a syntax like this:

module =
(only usefull for old gameport-based joystick, usb sticks are dynamically detected by usb_hid kernel module
gadget =
(that’s your ControllerName string, by default a “2-axis” should be returned according API spec, but it’s not the case)

and those below, to statically declare stick features for gameport-based joysticks.
It’s useless for USB sticks are there info are dynamically retrieved from USB HID report

num_axes =
num_hats =
num_buttons =
num_sticks =

So, @dragon, try to create a /boot/home/config/settings/joysticks/usb/0 file with this content:

module = usb_hid
gadget = Here your gamepad controller name

(Beware, code expect gadget=<value…>, so space around the equal are mandatory)

and check if it change something.

hi,

my config:

Haiku hrev 51611 running on VMware12. Haiku shows with listusb the joypad:

0e0f:0003 /dev/bus/usb/0/0 “VMware, Inc.” “Virtual Mouse” ver. 0102
0e0f:0008 /dev/bus/usb/0/1/0 “VMware, Inc.” “” ver. 0100
6666:0667 /dev/bus/usb/0/1/1 “Prototype product Vendor ID” “WiseGroup Smart Joy PSX, PS-PC Smart JoyPad” ver. 0288
0e0f:0002 /dev/bus/usb/0/1/hub “VMware, Inc.” “Virtual USB Hub” ver. 0100
0000:0000 /dev/bus/usb/0/hub “HAIKU Inc.” “UHCI RootHub” ver. 0110
0000:0000 /dev/bus/usb/1/hub “HAIKU Inc.” “EHCI RootHub” ver. 0200

but in joystickutelizer doesn’t work.
what make i wrong or is there a problem?

regards lorglas

In my experience the joystick just disconnect randomly.

Sometimes it work, sometimes it dont work. :frowning: And the other bug i see, sometimes it just dont show when you press a button, seems like it cant put a character in the configurator and it is just blind.