122 lines
3.4 KiB
YAML
122 lines
3.4 KiB
YAML
# joyful-config.yml - joyful config for Thrustmaster Sol-R1
|
|
# (grip + base) -> Space Engineers.
|
|
#
|
|
# DRAFT / UNVERIFIED: joyful's exact per-rule-type field names below
|
|
# were not checked against `examples/ruletypes.yml` in the installed
|
|
# version - do that before trusting this file. See mapping-brief.md
|
|
# "Known caveats".
|
|
#
|
|
# Every TODO_* below is a placeholder. Run find_codes.py (repo root)
|
|
# against the actual hardware and replace every one before use.
|
|
|
|
devices:
|
|
base:
|
|
match: "TODO: Sol-R Base" # evdev device name substring, see find_codes.py --list
|
|
grip:
|
|
match: "TODO: Sol-R Grip"
|
|
|
|
modes:
|
|
space_engineers:
|
|
devices: [base, grip]
|
|
|
|
rules:
|
|
# Throttle (base) -> Move Forward/Backward.
|
|
# Original bug: SE read the raw HID throttle axis like a trigger.
|
|
# Straight axis passthrough fixes it.
|
|
- device: base
|
|
type: axis
|
|
input: TODO_ABS_THROTTLE
|
|
output: ABS_Y
|
|
|
|
# Main stick (grip) X/Y -> View/look/rotate
|
|
- device: grip
|
|
type: axis
|
|
input: TODO_ABS_STICK_X
|
|
output: ABS_RX
|
|
- device: grip
|
|
type: axis
|
|
input: TODO_ABS_STICK_Y
|
|
output: ABS_RY
|
|
|
|
# Ministick (grip) -> Strafe horizontal/vertical
|
|
- device: grip
|
|
type: axis
|
|
input: TODO_ABS_MINISTICK_X
|
|
output: ABS_Z
|
|
- device: grip
|
|
type: axis
|
|
input: TODO_ABS_MINISTICK_Y
|
|
output: ABS_RZ
|
|
|
|
# Dual-position trigger stage 1/2 -> Primary/secondary click (use/fire, alt-fire)
|
|
- device: grip
|
|
type: button
|
|
input: TODO_BTN_TRIGGER_STAGE1
|
|
output: BTN_TRIGGER
|
|
- device: grip
|
|
type: button
|
|
input: TODO_BTN_TRIGGER_STAGE2
|
|
output: BTN_THUMB
|
|
|
|
# 2 orange buttons (top of stick) -> Dampeners on/off (Z) + Relative
|
|
# dampers (Ctrl+Z). Key emulation, not gamepad buttons - Relative
|
|
# Dampers isn't confirmed as a standalone bindable action, it's a
|
|
# modifier on the toggle key.
|
|
- device: grip
|
|
type: key
|
|
input: TODO_BTN_ORANGE_1
|
|
output: [KEY_Z]
|
|
- device: grip
|
|
type: key
|
|
input: TODO_BTN_ORANGE_2
|
|
output: [KEY_LEFTCTRL, KEY_Z]
|
|
|
|
# Rotary knob 1 (base) -> Switch toolbar (next/prev, default `,`/`.`).
|
|
# ASSUMES the knob reports as BTN detent pulses, not an ABS axis -
|
|
# confirm with find_codes.py. If it's an ABS axis instead, this
|
|
# needs joyful's segmented axis-to-button rule type instead.
|
|
- device: base
|
|
type: key
|
|
input: TODO_BTN_KNOB1_CW
|
|
output: [KEY_DOT]
|
|
- device: base
|
|
type: key
|
|
input: TODO_BTN_KNOB1_CCW
|
|
output: [KEY_COMMA]
|
|
|
|
# Rotary knob 2 (base) -> Hotbar slot select, same pulse assumption
|
|
# as knob 1 above.
|
|
- device: base
|
|
type: key
|
|
input: TODO_BTN_KNOB2_CW
|
|
output: [TODO_KEY_HOTBAR_NEXT]
|
|
- device: base
|
|
type: key
|
|
input: TODO_BTN_KNOB2_CCW
|
|
output: [TODO_KEY_HOTBAR_PREV]
|
|
|
|
# 4-button group (base, left side) -> Jetpack/Helmet/Flashlight/
|
|
# Parking toggles, bound in SE's own control menu (gamepad button
|
|
# passthrough, not key emulation).
|
|
- device: base
|
|
type: button
|
|
input: TODO_BTN_GROUP_JETPACK
|
|
output: BTN_TRIGGER_HAPPY1
|
|
- device: base
|
|
type: button
|
|
input: TODO_BTN_GROUP_HELMET
|
|
output: BTN_TRIGGER_HAPPY2
|
|
- device: base
|
|
type: button
|
|
input: TODO_BTN_GROUP_FLASHLIGHT
|
|
output: BTN_TRIGGER_HAPPY3
|
|
- device: base
|
|
type: button
|
|
input: TODO_BTN_GROUP_PARKING
|
|
output: BTN_TRIGGER_HAPPY4
|
|
|
|
# NOTE: the 4 tilt switches (base, top) are intentionally NOT mapped
|
|
# here - they're handled by switch_sync.py instead of joyful,
|
|
# because they need game-state feedback to avoid desync. See
|
|
# switch_sync-config.yaml.
|