Skip to content

Instantly share code, notes, and snippets.

@werpu
Created May 31, 2019 11:34
Show Gist options
  • Save werpu/ec5a7e6ae0ac208c090ef69dfbee186d to your computer and use it in GitHub Desktop.
Save werpu/ec5a7e6ae0ac208c090ef69dfbee186d to your computer and use it in GitHub Desktop.
device_config.yaml
######################################################################
# device definitions
#######################################################################
inputs:
digital:
name: Ultimarc I-PAC Ultimarc I-PAC
relpos: 1
analog_left:
name_re: ^Ulimarc.*Ultrastik\sPlayer\1$
relpos: 1
analog_right:
name_re: ^Ulimarc.*Ultrastik\sPlayer\2$
relpos: 1
########################################################################
# output devices
########################################################################
outputs:
xbox1:
create: yes
name: Microsoft X-Box 360 pad
type: xbx360
xbox2:
create: yes
name: Microsoft X-Box 360 pad
type: xbx360
mouse1:
name: mouse
type: mouse
keybd1:
name: key1
type: keybd
##########################################################
# rules section, maps events from one device into another
##########################################################
rules:
- from: digital # analog 1
from_ev: (EV_KEY), code 103 (KEY_UP) # keyup event as coming in from evtest
targets:
- to: xbox1 # artificial xbox controiler
to_ev: (EV_KEY), code 103 (KEY_UP) # pad up event
- from: analog_left
from_ev: (EV_KEY), code 103 (KEY_UP)
targets:
- to: xbox1
to_ev: (EV_KEY), code 103 (KEY_UP)
- to: xbox2
to_ev: (EV_KEY), code 103 (KEY_UP)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment