diff --git a/projects/ArchR/packages/hardware/quirks/profile.d/999-export b/projects/ArchR/packages/hardware/quirks/profile.d/999-export index 73a807f0a4..403eac40a6 100755 --- a/projects/ArchR/packages/hardware/quirks/profile.d/999-export +++ b/projects/ArchR/packages/hardware/quirks/profile.d/999-export @@ -34,7 +34,6 @@ export OS_VERSION \ DEVICE_LED_BRIGHTNESS \ DEVICE_LED_CHARGING \ DEVICE_LED_CONTROL \ - DEVICE_ANALOG_STICKS_LED_CONTROL \ DEVICE_MANGOHUD_SUPPORT \ DEVICE_MMC_EJECT \ DEVICE_PIPEWIRE_PROFILE \ diff --git a/projects/ArchR/packages/sysutils/system-utils/package.mk b/projects/ArchR/packages/sysutils/system-utils/package.mk index 2821db8219..c8c98fde96 100644 --- a/projects/ArchR/packages/sysutils/system-utils/package.mk +++ b/projects/ArchR/packages/sysutils/system-utils/package.mk @@ -20,7 +20,6 @@ makeinstall_target() { cp ${PKG_DIR}/sources/scripts/hdmi_sense ${INSTALL}/usr/bin cp ${PKG_DIR}/sources/scripts/input_sense ${INSTALL}/usr/bin cp ${PKG_DIR}/sources/scripts/ledcontrol ${INSTALL}/usr/bin - cp ${PKG_DIR}/sources/scripts/analog_sticks_ledcontrol ${INSTALL}/usr/bin cp ${PKG_DIR}/sources/scripts/battery_led_status ${INSTALL}/usr/bin cp ${PKG_DIR}/sources/scripts/turbomode ${INSTALL}/usr/bin if [ -d "${PKG_DIR}/sources/devices/${DEVICE}" ] diff --git a/projects/ArchR/packages/sysutils/system-utils/sources/scripts/analog_sticks_ledcontrol b/projects/ArchR/packages/sysutils/system-utils/sources/scripts/analog_sticks_ledcontrol deleted file mode 100755 index 55ff54f5df..0000000000 --- a/projects/ArchR/packages/sysutils/system-utils/sources/scripts/analog_sticks_ledcontrol +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -# SPDX-License-Identifier: GPL-2.0 -# Copyright (C) 2024-present ArchR (https://github.com/archr-linux/Arch-R) - -### -### LED Control now redirects to the quirk device or platform /bin/analog_sticks_ledcontrol -### so we don't need to have multiple variants in /usr/bin. -### - -if [ -z "${QUIRK_DEVICE}" ] || [ -z "${HW_DEVICE}" ]; then - . /etc/profile -fi - -if [ -f "/usr/lib/autostart/quirks/devices/${QUIRK_DEVICE}/bin/analog_sticks_ledcontrol" ]; then - exec "/usr/lib/autostart/quirks/devices/${QUIRK_DEVICE}/bin/analog_sticks_ledcontrol" $* -elif [ -f "/usr/lib/autostart/quirks/platforms/${HW_DEVICE}/bin/analog_sticks_ledcontrol" ]; then - exec "/usr/lib/autostart/quirks/platforms/${HW_DEVICE}/bin/analog_sticks_ledcontrol" $* -fi diff --git a/projects/ArchR/packages/ui/emulationstation/patches/0003-remove-analog-sticks-led-feature.patch b/projects/ArchR/packages/ui/emulationstation/patches/0003-remove-analog-sticks-led-feature.patch new file mode 100644 index 0000000000..4753415d2e --- /dev/null +++ b/projects/ArchR/packages/ui/emulationstation/patches/0003-remove-analog-sticks-led-feature.patch @@ -0,0 +1,171 @@ +es-menu: remove the dead ANALOG STICKS LED COLOR feature + +No ArchR-supported device has analog-stick RGB LEDs (only the R36S Ultra +has them, and ArchR does not support it; its stock DTB is a generic EVB that +does not even describe the LED control path). No device sets +DEVICE_ANALOG_STICKS_LED_CONTROL, so the menu entry never rendered, and the +backend /usr/bin/analog_sticks_ledcontrol was a dispatcher to a per-device +binary that nothing ships, i.e. a guaranteed no-op. + +Remove the whole chain on the ES side: the menu entry, GuiMenu's +openAnalogSticksLedControls(), its declaration, the include, the two +CMakeLists source refs, and the GuiAnalogSticksLedControls class itself. +The OS-side script + its install + the DEVICE_ANALOG_STICKS_LED_CONTROL +export are removed in the same commit. + +--- a/es-app/src/guis/GuiMenu.cpp ++++ b/es-app/src/guis/GuiMenu.cpp +@@ -21,7 +21,6 @@ + #include "guis/GuiRetroAchievementsSettings.h" + #include "guis/GuiSystemInformation.h" + #include "guis/GuiControllersSettings.h" +-#include "guis/GuiAnalogSticksLedControls.h" + #include "views/UIModeController.h" + #include "views/ViewController.h" + #include "CollectionSystemManager.h" +@@ -1857,10 +1856,6 @@ + }); + } + +- if (Utils::Platform::GetEnv("DEVICE_ANALOG_STICKS_LED_CONTROL") == "true"){ +- s->addEntry(_("ANALOG STICKS LED COLOR"), true, [this] { openAnalogSticksLedControls(); }); +- } +- + if (Utils::Platform::GetEnv("DEVICE_DTB_SWITCH") == "true"){ + s->addGroup(_("DEVICE")); + // Switch device dtb between e.g. the R33S & R36S +@@ -3017,11 +3012,6 @@ + mWindow->pushGui(new GuiNetPlaySettings(mWindow)); + } + +-void GuiMenu::openAnalogSticksLedControls() +-{ +- mWindow->pushGui(new GuiAnalogSticksLedControls(mWindow)); +-} +- + void GuiMenu::addDecorationSetOptionListComponent(Window* window, GuiSettings* parentWindow, const std::vector& sets, const std::string& configName) + { + auto decorations = std::make_shared >(window, _("DECORATION SET"), false); +--- a/es-app/src/guis/GuiMenu.h ++++ b/es-app/src/guis/GuiMenu.h +@@ -63,7 +63,6 @@ + void openResetOptions(); + void openNetplaySettings(); + void openRetroachievementsSettings(); +- void openAnalogSticksLedControls(); + void openMissingBiosSettings(); + void openFormatDriveSettings(); + void exitKidMode(); +--- a/es-app/CMakeLists.txt ++++ b/es-app/CMakeLists.txt +@@ -105,7 +105,6 @@ + ${CMAKE_CURRENT_SOURCE_DIR}/src/guis/GuiFileBrowser.h + ${CMAKE_CURRENT_SOURCE_DIR}/src/guis/GuiFavoriteMusicSelector.h + ${CMAKE_CURRENT_SOURCE_DIR}/src/guis/GuiMoonlight.h +- ${CMAKE_CURRENT_SOURCE_DIR}/src/guis/GuiAnalogSticksLedControls.h + + # Scrapers + ${CMAKE_CURRENT_SOURCE_DIR}/src/scrapers/Scraper.h +@@ -212,7 +211,6 @@ + ${CMAKE_CURRENT_SOURCE_DIR}/src/guis/GuiFileBrowser.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/src/guis/GuiFavoriteMusicSelector.cpp + ${CMAKE_CURRENT_SOURCE_DIR}/src/guis/GuiMoonlight.cpp +- ${CMAKE_CURRENT_SOURCE_DIR}/src/guis/GuiAnalogSticksLedControls.cpp + + # Scrapers + ${CMAKE_CURRENT_SOURCE_DIR}/src/scrapers/Scraper.cpp +--- a/es-app/src/guis/GuiAnalogSticksLedControls.cpp ++++ /dev/null 2026-06-25 17:24:11.918953990 -0300 +@@ -1,78 +0,0 @@ +-#include "GuiAnalogSticksLedControls.h" +- +-#include +-#include "components/SliderComponent.h" +-#include "SystemConf.h" +-#include "utils/Platform.h" +-#include "utils/StringUtil.h" +- +-GuiAnalogSticksLedControls::GuiAnalogSticksLedControls(Window* window) : GuiSettings(window, _("ANALOG STICKS LEDS").c_str()) +-{ +- float brightness_value = 0.f; +- float left_red_value = 0.f, left_green_value = 0.f, left_blue_value = 0.f; +- float right_red_value = 0.f, right_green_value = 0.f, right_blue_value = 0.f; +- +- std::string line = SystemConf::getInstance()->get("analogsticks.led"); +- if (!line.empty()) { +- std::vector tokens = Utils::String::split(line, ' '); +- if (tokens.size() == 7) { +- brightness_value = (float) std::atoi(tokens[0].c_str()) / 255; +- right_red_value = (float) std::atoi(tokens[1].c_str()) / 255; +- right_green_value = (float) std::atoi(tokens[2].c_str()) / 255; +- right_blue_value = (float) std::atoi(tokens[3].c_str()) / 255; +- left_red_value = (float) std::atoi(tokens[4].c_str()) / 255; +- left_green_value = (float) std::atoi(tokens[5].c_str()) / 255; +- left_blue_value = (float) std::atoi(tokens[6].c_str()) / 255; +- } +- } +- +- auto brightness = std::make_shared(mWindow, 0.f, 1.f, 0.1f); +- brightness->setValue(brightness_value); +- addWithLabel(_("BRIGHTNESS"), brightness); +- +- addGroup(_("LEFT")); +- auto left_red = std::make_shared(mWindow, 0.f, 1.f, 0.1f); +- left_red->setValue(left_red_value); +- addWithLabel(_("RED"), left_red); +- +- auto left_green = std::make_shared(mWindow, 0.f, 1.f, 0.1f); +- left_green->setValue(left_green_value); +- addWithLabel(_("GREEN"), left_green); +- +- auto left_blue = std::make_shared(mWindow, 0.f, 1.f, 0.1f); +- left_blue->setValue(left_blue_value); +- addWithLabel(_("BLUE"), left_blue); +- +- addGroup(_("RIGHT")); +- auto right_red = std::make_shared(mWindow, 0.f, 1.f, 0.1f); +- right_red->setValue(right_red_value); +- addWithLabel(_("RED"), right_red); +- +- auto right_green = std::make_shared(mWindow, 0.f, 1.f, 0.1f); +- right_green->setValue(right_green_value); +- addWithLabel(_("GREEN"), right_green); +- +- auto right_blue = std::make_shared(mWindow, 0.f, 1.f, 0.1f); +- right_blue->setValue(right_blue_value); +- addWithLabel(_("BLUE"), right_blue); +- +- const std::string analogSticksLedScript = "/usr/bin/analog_sticks_ledcontrol"; +- mMenu.addButton(_("APPLY"), "apply", [this, analogSticksLedScript, brightness, +- left_red, left_green, left_blue, right_red, right_green, right_blue] +- { +- char buffer[128]; +- +- sprintf(buffer, "%u %u %u %u %u %u %u", +- static_cast(brightness->getValue() * 255), +- static_cast(right_red->getValue() * 255), +- static_cast(right_green->getValue() * 255), +- static_cast(right_blue->getValue() * 255), +- static_cast(left_red->getValue() * 255), +- static_cast(left_green->getValue() * 255), +- static_cast(left_blue->getValue() * 255) +- ); +- +- Utils::Platform::runSystemCommand(analogSticksLedScript + " " + buffer, "", nullptr); +- SystemConf::getInstance()->set("analogsticks.led", buffer); +- }); +-} +--- a/es-app/src/guis/GuiAnalogSticksLedControls.h ++++ /dev/null 2026-06-25 17:24:11.918953990 -0300 +@@ -1,11 +0,0 @@ +-#pragma once +- +-#include "GuiSettings.h" +- +-class Window; +- +-class GuiAnalogSticksLedControls : public GuiSettings +-{ +-public: +- GuiAnalogSticksLedControls(Window* window); +-};