From 24b79bd361741e34d26fe165f6515cdc52f51f95 Mon Sep 17 00:00:00 2001 From: David Barbion Date: Wed, 7 Apr 2021 08:27:48 +0200 Subject: [PATCH 1/2] feat: add xpadneo kernel module This module add support for Xbox One controller, Xbox Elite Series 2 Wireless controller, and Xbox Series X|S Wireless controller. More info: https://atar-axis.github.io/xpadneo/ --- CHANGELOG.md | 1 + RELEASE-NOTES.md | 1 + TESTING.md | 4 ++++ package/xpadneo/Config.in | 8 ++++++++ package/xpadneo/xpadneo.mk | 21 +++++++++++++++++++++ 5 files changed, 35 insertions(+) create mode 100644 package/xpadneo/Config.in create mode 100644 package/xpadneo/xpadneo.mk diff --git a/CHANGELOG.md b/CHANGELOG.md index 4ef1d6167f..2c4e6585d1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -72,6 +72,7 @@ All notable changes to this project will be documented in this file. - Bump production nvidia drivers to 460.84 (#1815) - Disable Kodi 19 on rpi1, rpi2 and rpi3 due to compatibility issue (#1815) - Rework bluetooth scripts (#1482) +- Add xpadneo package for handling various xbox wireless controllers (#1609) ## [7.2.2-Reloaded] - Fix controler #2 in swanstation (#1730) diff --git a/RELEASE-NOTES.md b/RELEASE-NOTES.md index 7c2ac5427f..6670fa388a 100644 --- a/RELEASE-NOTES.md +++ b/RELEASE-NOTES.md @@ -16,6 +16,7 @@ as release notes for end user on a Recalbox upgrade. - Add LowRes NX virtual console on all boards - Add CHD support for Mega CD Games with Picodrive core - Add Saturn on Raspberry pi4 (libretro core: Yabasanshiro) +- Better support for Xbox joysticks like Xbox One S Wireless controller, Xbox Elite Series 2 Wireless controller and Xbox Series X|S Wireless controller ### Improvements - Bump Retroarch to v1.9.3 diff --git a/TESTING.md b/TESTING.md index 6eefdde5be..86dd9d6214 100644 --- a/TESTING.md +++ b/TESTING.md @@ -66,6 +66,10 @@ Pour les pending features, elles ne seront activées que si les beta testeurs le - [ ] Test manual refresh - [ ] Once the netplay is on, newly added romw should be hashed automatically in the next reboot - [ ] When setting Netplay on, ES should check if some roms need to be hashed: Set netplay off, then add roms, then refresh lists, then set netplay on +- [ ] Test xpadneo package (#1609) + - [ ] Test Xbox One S Wireless controller + - [ ] Test Xbox Elite Series 2 Wireless controller + - [ ] Test Xbox Series X|S Wireless controller ## [7.2.2] - [X] Test ppsspp saves are copied in share on upgrade (#1773) diff --git a/package/xpadneo/Config.in b/package/xpadneo/Config.in new file mode 100644 index 0000000000..4600acd8aa --- /dev/null +++ b/package/xpadneo/Config.in @@ -0,0 +1,8 @@ +config BR2_PACKAGE_GAMECON_GPIO_RPI + bool "gamecon gpio driver" + depends on BR2_LINUX_KERNEL + help + Kernel module to support snes,nes,psx joysticks on gpios + +comment "gamecon needs a kernel and headers" + depends on !BR2_LINUX_KERNEL diff --git a/package/xpadneo/xpadneo.mk b/package/xpadneo/xpadneo.mk new file mode 100644 index 0000000000..5c5e932a69 --- /dev/null +++ b/package/xpadneo/xpadneo.mk @@ -0,0 +1,21 @@ +################################################################################ +# +# XPADNEO +# +################################################################################ + +XPADNEO_VERSION = v0.9.1 +XPADNEO_SITE = https://github.com/atar-axis/xpadneo +XPADNEO_SITE_METHOD = git +XPADNEO_LICENSE = GPL-3.0 +XPADNEO_MODULE_SUBDIRS = hid-xpadneo/src + +define XPADNEO_COPY_CMDS + $(INSTALL) -D -m 0644 -t $(TARGET_DIR)/etc/modprobe.d $(@D)/hid-xpadneo/etc-modprobe.d/xpadneo.conf + $(INSTALL) -D -m 0644 -t $(TARGET_DIR)/etc/udev/rules.d $(@D)/hid-xpadneo/etc-udev-rules.d/60-xpadneo.rules +endef + +XPADNEO_INSTALL_TARGET_CMDS += $(XPADNEO_COPY_CMDS) + +$(eval $(kernel-module)) +$(eval $(generic-package)) -- GitLab From 85df29102b191375eb5d63a6b41c6b33d5c6c6ba Mon Sep 17 00:00:00 2001 From: David Barbion Date: Wed, 7 Apr 2021 08:41:21 +0200 Subject: [PATCH 2/2] chore: enable xpadneo for rpi1/2/3/4, xu4 and PCs --- Config.in | 2 ++ configs/recalbox-odroidxu4_defconfig | 1 + configs/recalbox-rpi1_defconfig | 1 + configs/recalbox-rpi2_defconfig | 1 + configs/recalbox-rpi3_defconfig | 1 + configs/recalbox-rpi4_defconfig | 1 + configs/recalbox-x86_64_defconfig | 1 + configs/recalbox-x86_defconfig | 1 + package/xpadneo/Config.in | 13 ++++++------- 9 files changed, 15 insertions(+), 7 deletions(-) diff --git a/Config.in b/Config.in index 4ae00c830c..c95428b531 100644 --- a/Config.in +++ b/Config.in @@ -59,7 +59,9 @@ menu "Controllers" source "$BR2_EXTERNAL_RECALBOX_PATH/package/steamcontroller/Config.in" source "$BR2_EXTERNAL_RECALBOX_PATH/package/virtualgamepads/Config.in" source "$BR2_EXTERNAL_RECALBOX_PATH/package/xarcade2jstick/Config.in" + comment "Microsoft Xbox controller support" source "$BR2_EXTERNAL_RECALBOX_PATH/package/xboxdrv/Config.in" + source "$BR2_EXTERNAL_RECALBOX_PATH/package/xpadneo/Config.in" comment "Nintendo switch Joycons support" source "$BR2_EXTERNAL_RECALBOX_PATH/package/joycond/Config.in" source "$BR2_EXTERNAL_RECALBOX_PATH/package/hid-nintendo/Config.in" diff --git a/configs/recalbox-odroidxu4_defconfig b/configs/recalbox-odroidxu4_defconfig index 6428c97a6c..0d6d8adcf6 100644 --- a/configs/recalbox-odroidxu4_defconfig +++ b/configs/recalbox-odroidxu4_defconfig @@ -346,3 +346,4 @@ BR2_PACKAGE_JOYCOND=y BR2_PACKAGE_FLUIDSYNTH_PULSEAUDIO=y BR2_PACKAGE_KODI_PULSEAUDIO=y BR2_PACKAGE_PAMIX=y +BR2_PACKAGE_XPADNEO=y diff --git a/configs/recalbox-rpi1_defconfig b/configs/recalbox-rpi1_defconfig index 38a2d2ccc3..e397eb3e31 100644 --- a/configs/recalbox-rpi1_defconfig +++ b/configs/recalbox-rpi1_defconfig @@ -328,3 +328,4 @@ BR2_PACKAGE_JOYCOND=y BR2_PACKAGE_FLUIDSYNTH_PULSEAUDIO=y BR2_PACKAGE_KODI_PULSEAUDIO=y BR2_PACKAGE_PAMIX=y +BR2_PACKAGE_XPADNEO=y diff --git a/configs/recalbox-rpi2_defconfig b/configs/recalbox-rpi2_defconfig index 5750dcc833..b35c6e5af6 100644 --- a/configs/recalbox-rpi2_defconfig +++ b/configs/recalbox-rpi2_defconfig @@ -354,3 +354,4 @@ BR2_PACKAGE_JOYCOND=y BR2_PACKAGE_FLUIDSYNTH_PULSEAUDIO=y BR2_PACKAGE_KODI_PULSEAUDIO=y BR2_PACKAGE_PAMIX=y +BR2_PACKAGE_XPADNEO=y diff --git a/configs/recalbox-rpi3_defconfig b/configs/recalbox-rpi3_defconfig index db2b592229..a5cadee555 100644 --- a/configs/recalbox-rpi3_defconfig +++ b/configs/recalbox-rpi3_defconfig @@ -355,3 +355,4 @@ BR2_PACKAGE_JOYCOND=y BR2_PACKAGE_FLUIDSYNTH_PULSEAUDIO=y BR2_PACKAGE_KODI_PULSEAUDIO=y BR2_PACKAGE_PAMIX=y +BR2_PACKAGE_XPADNEO=y diff --git a/configs/recalbox-rpi4_defconfig b/configs/recalbox-rpi4_defconfig index f03822cf58..20ac13e9f4 100644 --- a/configs/recalbox-rpi4_defconfig +++ b/configs/recalbox-rpi4_defconfig @@ -344,3 +344,4 @@ BR2_PACKAGE_JOYCOND=y BR2_PACKAGE_FLUIDSYNTH_PULSEAUDIO=y BR2_PACKAGE_KODI_PULSEAUDIO=y BR2_PACKAGE_PAMIX=y +BR2_PACKAGE_XPADNEO=y diff --git a/configs/recalbox-x86_64_defconfig b/configs/recalbox-x86_64_defconfig index a4595f78e3..ba02fa2ca9 100644 --- a/configs/recalbox-x86_64_defconfig +++ b/configs/recalbox-x86_64_defconfig @@ -430,3 +430,4 @@ BR2_PACKAGE_JOYCOND=y BR2_PACKAGE_FLUIDSYNTH_PULSEAUDIO=y BR2_PACKAGE_KODI_PULSEAUDIO=y BR2_PACKAGE_PAMIX=y +BR2_PACKAGE_XPADNEO=y diff --git a/configs/recalbox-x86_defconfig b/configs/recalbox-x86_defconfig index 7986d6354e..40b7b02399 100644 --- a/configs/recalbox-x86_defconfig +++ b/configs/recalbox-x86_defconfig @@ -415,3 +415,4 @@ BR2_PACKAGE_JOYCOND=y BR2_PACKAGE_FLUIDSYNTH_PULSEAUDIO=y BR2_PACKAGE_KODI_PULSEAUDIO=y BR2_PACKAGE_PAMIX=y +BR2_PACKAGE_XPADNEO=y diff --git a/package/xpadneo/Config.in b/package/xpadneo/Config.in index 4600acd8aa..3bbaf2cfab 100644 --- a/package/xpadneo/Config.in +++ b/package/xpadneo/Config.in @@ -1,8 +1,7 @@ -config BR2_PACKAGE_GAMECON_GPIO_RPI - bool "gamecon gpio driver" - depends on BR2_LINUX_KERNEL +config BR2_PACKAGE_XPADNEO + bool "Xbox One controller support" + depends on BR2_PACKAGE_HAS_UDEV + select BR2_PACKAGE_LIBEVDEV help - Kernel module to support snes,nes,psx joysticks on gpios - -comment "gamecon needs a kernel and headers" - depends on !BR2_LINUX_KERNEL + Xbox One controller support + https://atar-axis.github.io/xpadneo/ -- GitLab