### Automated installation Source: https://github.com/pwr-solaar/solaar/blob/master/RHEL.md Uses the provided installation script or a custom non-interactive script for automated setup. ```bash ./tools/install-rhel.sh ``` ```bash cat > install-rhel-solaar.sh <<'SCRIPT' #!/usr/bin/env bash set -euo pipefail if [[ "${EUID}" -eq 0 ]]; then echo "Run as a regular user with sudo access, not as root." exit 1 fi sudo dnf makecache --refresh sudo dnf install -y \ git \ gtk3 \ python3 \ python3-devel \ python3-dbus \ python3-gobject \ python3-pip \ python3-psutil \ python3-pyudev \ python3-setuptools \ python3-xlib \ python3-yaml if [[ ! -d Solaar/.git ]]; then git clone https://github.com/pwr-Solaar/Solaar.git fi cd Solaar python3 -m pip install --user . sudo make install_udev_uinput ~/.local/bin/solaar --version SCRIPT chmod +x install-rhel-solaar.sh ./install-rhel-solaar.sh ``` -------------------------------- ### Install AppIndicator for Ubuntu Source: https://github.com/pwr-solaar/solaar/blob/master/docs/capabilities.md Installs the required Gnome shell extension for system tray support on Ubuntu and related distributions. ```bash sudo apt install gnome-shell-extension-appindicator ``` -------------------------------- ### Install AppIndicator for Fedora Source: https://github.com/pwr-solaar/solaar/blob/master/docs/capabilities.md Installs the required Gnome shell extension for system tray support on Fedora systems. ```bash sudo dnf install gnome-shell-extension-appindicator ``` -------------------------------- ### Install Solaar package Source: https://github.com/pwr-solaar/solaar/blob/master/RHEL.md Installs Solaar either for the current user or system-wide. ```bash python3 -m pip install --user . ``` ```bash sudo python3 -m pip install . ``` -------------------------------- ### Install macOS dependencies Source: https://github.com/pwr-solaar/solaar/blob/master/docs/installation.md Use Homebrew to install the required libraries for Solaar on macOS. ```bash brew update brew install hidapi gtk+3 pygobject3 ``` -------------------------------- ### HID++ 1.0 Register Communication Examples Source: https://github.com/pwr-solaar/solaar/blob/master/docs/devices/Wireless Illuminated Keyboard K800 2010.txt A collection of raw HID++ 1.0 command and response sequences for interacting with the K800 keyboard registers. ```text # 0x00 - Enabled Notifications. rw (see HID++ 1.0 spec) << ( 0.055) [10 02 8100 000000] '\x10\x02\x81\x00\x00\x00\x00' >> ( 0.084) [10 02 8100 000000] '\x10\x02\x81\x00\x00\x00\x00' ``` ```text # 0x01 - Keyboard hand detection. rw, last param is 00 when hand detection is # enabled, 30 when disabled. (when enabled, keyboard will light up if not # already when hovering over the front) << ( 1.085) [10 02 8101 000000] '\x10\x02\x81\x01\x00\x00\x00' >> ( 1.114) [10 02 8101 000000] '\x10\x02\x81\x01\x00\x00\x00' ``` ```text # 0x07 - Battery status (3 = one bar; 1 = red/critical; 5=two bars; 7=three # bars/full. Second returned param is 25 when keyboard is charging ) << ( 7.327) [10 02 8107 000000] '\x10\x02\x81\x07\x00\x00\x00' >> ( 7.368) [10 02 8107 030000] '\x10\x02\x81\x07\x03\x00\x00' ``` ```text # 0x09 - F key function. rw (read: status, set/get: 00 01 00 means swap # functions, 00 00 00 means do not swap functions) << ( 9.411) [10 02 8109 000000] '\x10\x02\x81\t\x00\x00\x00' >> ( 9.440) [10 02 8109 000000] '\x10\x02\x81\t\x00\x00\x00' ``` ```text # 0x17 - Illumination info r/w. Last param: 02 to disable backlight, 01 to # enable backlight << ( 24.965) [10 02 8117 000000] '\x10\x02\x81\x17\x00\x00\x00' >> ( 24.988) [10 02 8117 3C0001] '\x10\x02\x81\x17<\x00\x01' ``` ```text # 0x51 - ? << ( 99.294) [10 02 8151 000000] '\x10\x02\x81Q\x00\x00\x00' >> ( 99.543) [10 02 8151 000000] '\x10\x02\x81Q\x00\x00\x00' ``` ```text # 0x54 - ? << ( 103.046) [10 02 8154 000000] '\x10\x02\x81T\x00\x00\x00' >> ( 103.295) [10 02 8154 FF0000] '\x10\x02\x81T\xff\x00\x00' ``` ```text # 0xD0 - ? << ( 253.860) [10 02 81D0 000000] '\x10\x02\x81\xd0\x00\x00\x00' >> ( 253.883) [10 02 81D0 000000] '\x10\x02\x81\xd0\x00\x00\x00' ``` ```text # 0xF1 - Version info (params 0n 00 00 where n is 1..4) << ( 289.991) [10 02 81F1 000000] '\x10\x02\x81\xf1\x00\x00\x00' >> ( 290.032) [10 02 8F81 F10300] '\x10\x02\x8f\x81\xf1\x03\x00' ``` ```text # 0xF3 - ? << ( 292.075) [10 02 81F3 000000] '\x10\x02\x81\xf3\x00\x00\x00' >> ( 292.116) [10 02 81F3 000000] '\x10\x02\x81\xf3\x00\x00\x00' ``` ```text # 0x0F - This changes, the last commented line was observed in an earlier run << ( 17.728) [10 02 830F 000000] '\x10\x02\x83\x0f\x00\x00\x00' >> ( 17.976) [11 02 830F FFFB00000240025C000000000FF90080] '\x11\x02\x83\x0f\xff\xfb\x00\x00\x02@\x02\\\x00\x00\x00\x00\x0f\xf9\x00\x80' #>> ( 17.999) [11 02 830F FFFC007F0243025D000000000FF60080] '\x11\x02\x83\x0f\xff\xfc\x00\x7f\x02C\x02]\x00\x00\x00\x00\x0f\xf6\x00\x80' ``` -------------------------------- ### Manage udev rules Source: https://github.com/pwr-solaar/solaar/blob/master/RHEL.md Commands to install, verify, or remove udev rules for Logitech device permissions. ```bash sudo make install_udev_uinput ``` ```bash ls -l /etc/udev/rules.d/42-logitech-unify-permissions.rules ``` ```bash sudo make uninstall_udev ``` -------------------------------- ### Example output of device identification Source: https://github.com/pwr-solaar/solaar/wiki/Example:-Diverted-"Smart-Shift"-button-for-common-devices Sample output showing serial numbers and codenames for connected devices. ```text Serial : 789ABDEF Codename : MX Anywhere 3 Serial number: 123456AB Codename : MX Keys Serial number: 654321CD ``` -------------------------------- ### Install Solaar dependencies via DNF Source: https://github.com/pwr-solaar/solaar/blob/master/RHEL.md Installs required system packages and Python dependencies using the DNF package manager. ```bash sudo dnf makecache --refresh sudo dnf install -y \ git \ gtk3 \ python3 \ python3-devel \ python3-dbus \ python3-gobject \ python3-pip \ python3-psutil \ python3-pyudev \ python3-setuptools \ python3-xlib \ python3-yaml ``` ```bash sudo dnf install -y \ evemu \ libinput \ usbutils ``` -------------------------------- ### Configure macOS LaunchAgent Source: https://github.com/pwr-solaar/solaar/blob/master/docs/installation.md Automatically start Solaar and ensure it stays running in the background using a LaunchAgent. ```bash bash <(curl -fsSL https://raw.githubusercontent.com/pwr-Solaar/Solaar/refs/heads/master/tools/create-macos-launchagent.sh) ``` -------------------------------- ### Define a Pointer Speed Setting Source: https://github.com/pwr-solaar/solaar/blob/master/docs/features.md Example of a setting implementation subclassing _Setting with range validation. ```python class PointerSpeed(_Setting): name = 'pointer_speed' label = _('Sensitivity (Pointer Speed)') description = _('Speed multiplier for mouse (256 is normal multiplier).') feature = _F.POINTER_SPEED validator_class = _RangeV min_value = 0x002e max_value = 0x01ff validator_options = {'byte_count': 2} ``` -------------------------------- ### General Solaar CLI Syntax Source: https://github.com/pwr-solaar/solaar/blob/master/docs/PRO_X2_SUPERSTRIKE_CLI.md Basic commands for listing, reading, and writing device settings. ```bash # List all settings for device solaar config # Read a specific setting solaar config # Write a specific setting solaar config ``` -------------------------------- ### Verify Solaar installation Source: https://github.com/pwr-solaar/solaar/blob/master/RHEL.md Checks if Solaar is installed and verifies the PATH configuration. ```bash command -v solaar solaar --version python3 -m pip show solaar ``` ```bash echo "$PATH" | tr ':' '\n' | grep -Fx "$HOME/.local/bin" >/dev/null || \ echo 'Add ~/.local/bin to PATH' ``` -------------------------------- ### Configure Gaming Profile Source: https://github.com/pwr-solaar/solaar/blob/master/docs/PRO_X2_SUPERSTRIKE_CLI.md Sets up fast actuation, sensitive rapid trigger, and medium haptics for gaming performance. ```bash #!/bin/bash # Gaming profile: fast actuation, sensitive rapid trigger, medium haptics solaar config 1 onboard_profiles Disabled solaar config 1 report_rate_extended 125us solaar config 1 dpi_extended "{X:800, Y:800, LOD:HIGH}" # Left button - hair trigger solaar config 1 superstrike-tuning_actuation-0 1 solaar config 1 superstrike-tuning_rapid-trigger-level-0 1 solaar config 1 superstrike-tuning_haptics-0 3 # Right button - hair trigger solaar config 1 superstrike-tuning_actuation-1 1 solaar config 1 superstrike-tuning_rapid-trigger-level-1 1 solaar config 1 superstrike-tuning_haptics-1 3 ``` -------------------------------- ### Create macOS application launcher Source: https://github.com/pwr-solaar/solaar/blob/master/docs/installation.md Create a Solaar.app launcher in the /Applications directory. ```bash bash <(curl -fsSL https://raw.githubusercontent.com/pwr-Solaar/Solaar/refs/heads/master/tools/create-macos-app.sh) ``` -------------------------------- ### YAML Configuration for Beta Machine Source: https://github.com/pwr-solaar/solaar/wiki/Example:-Diverted-"Smart-Shift"-button-for-common-devices Rules file for the second machine to trigger host switching to channel 0 using diverted Smart Shift or Host Switch Channel 1 keys. ```yaml %YAML 1.3 --- - Or: - Key: [Smart Shift, released] - Key: [Host Switch Channel 1, released] - Rule: - And: - Active: 654321CD - Active: 123456AB - Set: [654321CD, change-host, 0] - Set: [123456AB, change-host, 0] - Execute: [notify-send, --category=device, --expire-time=3000, --app-name=solaar, --icon=/usr/share/solaar/icons/solaar.svg, Change host, Not done – some device not active.] ... ``` -------------------------------- ### Configure Productivity Profile Source: https://github.com/pwr-solaar/solaar/blob/master/docs/PRO_X2_SUPERSTRIKE_CLI.md Sets up deeper actuation, slower rapid trigger, and strong haptics for comfortable daily use. ```bash #!/bin/bash # Productivity profile: deeper actuation, slower rapid trigger, strong haptics solaar config 1 onboard_profiles Disabled solaar config 1 report_rate_extended 1ms solaar config 1 dpi_extended "{X:1600, Y:1600, LOD:HIGH}" # Left button - comfortable click solaar config 1 superstrike-tuning_actuation-0 7 solaar config 1 superstrike-tuning_rapid-trigger-level-0 4 solaar config 1 superstrike-tuning_haptics-0 5 # Right button - comfortable click solaar config 1 superstrike-tuning_actuation-1 7 solaar config 1 superstrike-tuning_rapid-trigger-level-1 4 solaar config 1 superstrike-tuning_haptics-1 5 ``` -------------------------------- ### Specify Non-Default FeatureRW Commands Source: https://github.com/pwr-solaar/solaar/blob/master/docs/features.md Example of overriding default read and write function identifiers for FeatureRW. ```python rw_options = {'read_fnid': 0x10, 'write_fnid': 0x20} ``` -------------------------------- ### Configure Solaar Rules for Beta Machine Source: https://github.com/pwr-solaar/solaar/wiki/Example:-Diverted-"Host-Switch-Channel"-keys-for-common-devices YAML configuration for the second machine to handle host switching logic. ```yaml %YAML 1.3 --- - Key: [Host Switch Channel 1, released] - Rule: - Active: 123456AB - Set: [123456AB, change-host, 0] - Set: [654321CD, change-host, 0] - Execute: [notify-send, --category=device, --expire-time=3000, --app-name=solaar, --icon=/usr/share/solaar/icons/solaar.svg, Change host, Switched keyboard and mouse to beta.] - Set: [654321CD, change-host, 0] - Execute: [notify-send, --category=device, --expire-time=3000, --app-name=solaar, --icon=/usr/share/solaar/icons/solaar.svg, Change host, Switched keyboard to beta. Mouse not active.] ... ``` -------------------------------- ### solaar config Source: https://github.com/pwr-solaar/solaar/blob/master/docs/PRO_X2_SUPERSTRIKE_CLI.md General CLI syntax for reading or writing device configurations. ```APIDOC ## CLI Command: solaar config ### Description Reads or writes configuration settings for the Logitech PRO X 2 Superstrike device. ### Parameters - **device** (string/int) - Required - The device identifier (number, name, or serial number). - **setting-name** (string) - Optional - The specific setting to read or write. - **value** (string) - Optional - The value to set for the specified setting. ### Usage Examples ```bash # List all settings solaar config 1 # Read a setting solaar config 1 onboard_profiles # Write a setting solaar config 1 onboard_profiles Disabled ``` ``` -------------------------------- ### Compile Translation Files Source: https://github.com/pwr-solaar/solaar/blob/master/docs/i18n.md Run this script to compile the PO files into the format required at runtime. ```bash ./tools/po-compile.sh ``` -------------------------------- ### Read All Settings as JSON Source: https://github.com/pwr-solaar/solaar/blob/master/docs/PRO_X2_SUPERSTRIKE_CLI.md Parses the output of the config command into a JSON-like format for programmatic consumption. ```bash # Get all settings as output solaar config 1 2>/dev/null | grep "^[a-z]" | while read line; do setting=$(echo "$line" | cut -d'=' -f1 | tr -d ' ') value=$(echo "$line" | cut -d'=' -f2 | tr -d ' ') echo "{\"setting\": \"$setting\", \"value\": \"$value\"}" done ``` -------------------------------- ### Run Solaar Source: https://github.com/pwr-solaar/solaar/blob/master/RHEL.md Executes the Solaar application. ```bash solaar ``` ```bash python3 -m solaar ```