Input: add HID simulation mappings
Add simulation usage page mappings to hid-input.c to support a new crop of joysticks using them to designate Rudder and Throttle controls. Signed-off-by: Vojtech Pavlik <vojtech@suse.cz> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
This commit is contained in:

committed by
Dmitry Torokhov

parent
b8c9c642db
commit
0aebfdac04
@@ -131,6 +131,15 @@ static void hidinput_configure_usage(struct hid_input *hidinput, struct hid_fiel
|
||||
map_key(code);
|
||||
break;
|
||||
|
||||
|
||||
case HID_UP_SIMULATION:
|
||||
|
||||
switch (usage->hid & 0xffff) {
|
||||
case 0xba: map_abs(ABS_RUDDER); break;
|
||||
case 0xbb: map_abs(ABS_THROTTLE); break;
|
||||
}
|
||||
break;
|
||||
|
||||
case HID_UP_GENDESK:
|
||||
|
||||
if ((usage->hid & 0xf0) == 0x80) { /* SystemControl */
|
||||
|
Reference in New Issue
Block a user