diff --git a/rootfs/usr/lib/udev/hwdb.d/60-inputplumber-autostart.hwdb b/rootfs/usr/lib/udev/hwdb.d/60-inputplumber-autostart.hwdb index 0f47149b..0f68466a 100644 --- a/rootfs/usr/lib/udev/hwdb.d/60-inputplumber-autostart.hwdb +++ b/rootfs/usr/lib/udev/hwdb.d/60-inputplumber-autostart.hwdb @@ -93,6 +93,8 @@ dmi:*svnONE-NETBOOK:pnONEXPLAYER2PROARP23:* dmi:*svnONE-NETBOOK:pnONEXPLAYER2PROARP23H:* dmi:*svnONE-NETBOOK:pnONEXPLAYER2PROARP23P:* dmi:*svnONE-NETBOOK:pnONEXPLAYER2PROARP23EVA-01:* +# OneXPlayer 3 +dmi:*svnONE-NETBOOK:pnONEXPLAYER3:* # OneXPlayer Mini A07 dmi:*svnONE-NETBOOK:pnONEXPLAYERminiA07:* # OneXPlayer Mini Pro diff --git a/rootfs/usr/share/inputplumber/capability_maps/onexplayer_type9.yaml b/rootfs/usr/share/inputplumber/capability_maps/onexplayer_type9.yaml new file mode 100644 index 00000000..8826b2dd --- /dev/null +++ b/rootfs/usr/share/inputplumber/capability_maps/onexplayer_type9.yaml @@ -0,0 +1,40 @@ +# yaml-language-server: $schema=https://raw.githubusercontent.com/ShadowBlip/InputPlumber/main/rootfs/usr/share/inputplumber/schema/capability_map_v1.json +# Schema version number +version: 1 + +# The type of configuration schema +kind: CapabilityMap + +# Name for the device event map +name: OneXPlayer Type 9 + +# Unique identifier of the capability mapping +id: oxp9 + +# Verification (ONEXPLAYER 3): +# ONEX: evtest reports LeftCtrl+LeftAlt+LeftMeta on HID 1a86:fe00. +# Options: evtest reports LeftCtrl+LeftMeta+O on HID 1a86:fe00. +# Home: no evdev event; OXP HID interface 2 reports vendor button ID 0x24, +# which the OXP HID driver translates to gamepad Keyboard. + +# List of mapped events that are activated by a specific set of activation keys. +mapping: + - name: ONEX + source_events: + - keyboard: KeyLeftCtrl + - keyboard: KeyLeftAlt + - keyboard: KeyLeftMeta + target_event: + gamepad: + button: QuickAccess2 + - name: Options + source_events: + - keyboard: KeyLeftCtrl + - keyboard: KeyLeftMeta + - keyboard: KeyO + target_event: + gamepad: + button: QuickAccess + +# List of events to filter from the source devices +filtered_events: [] diff --git a/rootfs/usr/share/inputplumber/devices/50-onexplayer_3.yaml b/rootfs/usr/share/inputplumber/devices/50-onexplayer_3.yaml new file mode 100644 index 00000000..e09366b3 --- /dev/null +++ b/rootfs/usr/share/inputplumber/devices/50-onexplayer_3.yaml @@ -0,0 +1,62 @@ +# yaml-language-server: $schema=https://raw.githubusercontent.com/ShadowBlip/InputPlumber/main/rootfs/usr/share/inputplumber/schema/composite_device_v1.json +# Schema version number +version: 1 + +# The type of configuration schema +kind: CompositeDevice + +# Name of the composite device mapping +name: ONEXPLAYER 3 + +# Only allow a single source device per composite device of this type. +single_source: false + +# Only use this profile if *any* of the given matches matches. If this list is +# empty, then the source devices will *always* be checked. +# /sys/class/dmi/id/product_name +matches: + - dmi_data: + product_name: ONEXPLAYER 3 + sys_vendor: ONE-NETBOOK + +# One or more source devices to combine into a single virtual device. The events +# from these devices will be watched and translated according to the key map. +source_devices: + - group: gamepad + evdev: + name: Microsoft X-Box 360 pad + phys_path: usb-0000:00:14.0-7/input0 + handler: event* + - group: keyboard + evdev: + name: HID 1a86:fe00 + phys_path: usb-0000:00:14.0-5/input0 + handler: event* + - group: gamepad + hidraw: + vendor_id: 0x1a86 + product_id: 0xfe00 + interface_num: 2 + - group: imu + iio: + name: bmi260 + mount_matrix: + x: [0, 1, 0] + y: [1, 0, 0] + z: [0, 0, 1] + +# Optional configuration for the composite device +options: + # If true, InputPlumber will automatically try to manage the input device. If + # this is false, InputPlumber will not try to manage the device unless an + # external service enables management of the device. Defaults to 'false' + auto_manage: true + +# The target input device(s) that the virtual device profile can use +target_devices: + - xbox-elite + - mouse + - keyboard + +# The ID of a device event mapping in the 'capability_maps' folder +capability_map_id: oxp9