Merge pull request #2353 from porschemad911/yabasanshiro-sa-inputplumber

yabasanshiro-sa - inputplumber
This commit is contained in:
John Williams
2026-02-26 16:02:39 +11:00
committed by GitHub
2 changed files with 12 additions and 4 deletions

View File

@@ -37,12 +37,19 @@ fi
if [ ! -e "${CONFIG_DIR}/input.cfg" ]
then
rm -f ${CONFIG_DIR}/keymapv2.json
# Check for js0, else fall back to joypad
if grep -q "js0" /proc/bus/input/devices; then
GAMEPAD="'$(grep -b4 js0 /proc/bus/input/devices | awk 'BEGIN {FS="\""}; /Name/ {printf $2}')'"
# Handle inputplumber platforms first
if [[ "${HW_DEVICE}" =~ SM8550|SM8650 ]]; then
GAMEPAD="'InputPlumber GameController'"
else
GAMEPAD="'$(grep -b4 joypad /proc/bus/input/devices | awk 'BEGIN {FS="\""}; /Name/ {printf $2}')'"
# Check for js0, else fall back to joypad
if grep -q "js0" /proc/bus/input/devices; then
GAMEPAD="'$(grep -b4 js0 /proc/bus/input/devices | awk 'BEGIN {FS="\""}; /Name/ {printf $2}')'"
else
GAMEPAD="'$(grep -b4 joypad /proc/bus/input/devices | awk 'BEGIN {FS="\""}; /Name/ {printf $2}')'"
fi
fi
GAMEPADCONFIG=$(xmlstarlet sel -t -c "//inputList/inputConfig[@deviceName=${GAMEPAD}]" -n /storage/.emulationstation/es_input.cfg)
MAPPING_FILE="/usr/config/yabasanshiro/devices/keymapv2_$(eval echo $GAMEPAD).json"

View File

@@ -273,6 +273,7 @@ if [[ "${HW_DEVICE}" =~ SM8550|SM8650 && ! -e "/storage/.inputplumber_migration_
rm -rf /storage/.config/Cemu
rm -rf /storage/.config/melonDS
rm -rf /storage/.config/mupen64plus
rm -rf /storage/.config/yabasanshiro
# Mark migration as complete
touch /storage/.inputplumber_migration_complete