Skip to content

v4cachy/legion-linux-toolkit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

73 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Legion Linux Toolkit

Legion Linux Toolkit

A native Linux power management dashboard for Lenovo laptops

Built for CachyOS · KDE Plasma 6 · Wayland


📸 Screenshots

🏠 Home

Home

🔋 Battery                                           ⚡ Performance

🖥️ Display                                            ⌨️ Keyboard RGB

⚙️ System                                              🌀 Fan

🚀 Overclock                                         🎯 Actions

ℹ️ About

About


🖥️ Supported Hardware

Brand Models Support
🎮 Legion Legion 5, 5 Pro, 7, Slim 5/7 ✅ Full — RGB, OC, GPU switching, fan, G-Sync
🎮 LOQ LOQ 15, 16 ✅ Full — power, fan, GPU switching
💼 ThinkPad All modern ThinkPad models ✅ Full + charge thresholds, fan levels 0–7, TrackPoint
🔄 Yoga Yoga 6, 7, 9, Slim series ✅ Full + hinge mode, auto-rotate
💻 IdeaPad IdeaPad 5, Flex, Slim ✅ Standard — power, battery, toggles
📋 ThinkBook ThinkBook 14, 16 ✅ Standard — power, battery, fingerprint

Primary target: Lenovo Legion 5 15ACH6H (2021) — AMD Ryzen 7 5800H · NVIDIA RTX 3060 · CachyOS · KDE Plasma 6


✨ Features

🏠 Home Page
  • ⚡ Power Mode dropdown — Quiet / Balanced / Performance / Custom (also Fn+Q)
  • 🔋 Battery Mode — Normal / Conservation (~60%) / Rapid Charge
  • 🎮 GPU Working Mode — Hybrid / NVIDIA / Integrated (via envycontrol)
  • 🔄 G-Sync & Display Overdrive toggles
  • 🔌 Always on USB & Fn Lock toggles
  • 📊 Live CPU & GPU stats — utilization, clock, temp, fan RPM, VRAM
🔋 Battery Page
  • 📈 Live battery %, voltage, health, charge cycles, power draw, temperature
  • ⚙️ Conservation (~60%), Rapid Charge, USB Charging, Power Charge Mode
  • 🔧 ThinkPad only — Start/Stop charge threshold (e.g. 40%–80%)
🖥️ Display Page
  • ☀️ Screen brightness slider — auto-detects nvidia_wmi_ec_backlight, amdgpu_bl0 etc.
  • 📐 Resolution & Refresh Rate selectors (independent, via kscreen)
  • ✨ Display Overdrive & G-Sync toggles
⌨️ Keyboard RGB (Legion)
  • 🌈 4-zone RGB via LegionAura — Static, Breath, Wave, Hue, Off
  • 🎨 Per-zone colour pickers + hex input
  • 💡 Quick presets — Legion Red, Ocean, Sunset, Aurora
  • 🔆 Keyboard backlight brightness slider
⚙️ System Page
  • 🔒 Fn Lock, Super Key, Touchpad, Camera toggles
  • 🎨 Theme — Dark / Dark Dimmed / OLED Black
  • 🔴 ThinkPad only — TrackPoint sensitivity & speed sliders
  • 💡 ThinkPad only — ThinkLight & Mic Mute LED toggles
  • 🔄 Yoga only — Hinge mode display, orientation lock toggle
🌀 Fan Page
  • 🎡 Animated fan icons — real-time spin driven by actual RPM
  • 🌡️ Auto mode — firmware thermal curves
  • 💨 Full Speed mode — locks both fans to 100%
  • 🌀 ThinkPad only — Fan level dropdown (0–7, Auto, Disengaged)
🚀 Overclock Page
  • 🔛 Master OC enable/disable toggle
  • 🔧 CPU max/min frequency + TDP (PL1/PL2) sliders
  • 🎮 GPU core offset, memory offset, power limit, temp target

🌍 Languages

First-run wizard — choose your language on first launch:

🇬🇧 English · 🇫🇷 Français · 🇩🇪 Deutsch · 🇪🇸 Español · 🇵🇹 Português · 🇹🇷 Türkçe · 🇷🇺 Русский · 🇨🇳 中文 · 🇯🇵 日本語 · 🇰🇷 한국어 · 🇸🇦 العربية


🎨 Power Profiles

Profile Label LED TDP
low-power Quiet 🔵 Blue 15W
balanced Balanced ⚪ White 35W
balanced-performance Performance 🔴 Red 45W
performance Custom 🩷 Pink 54W

📦 Requirements

Core — auto-installed:

python-pyqt6   qt6-wayland   libnotify   kscreen   git

Optional — auto-installed by brand:

Package Manager Brand Feature
lenovolegionlinux + lenovolegionlinux-dkms pacman Legion / LOQ Fan RPM, sysfs paths
envycontrol paru Legion / LOQ GPU mode switching
legionaura yay Legion Keyboard RGB
fprintd pacman ThinkPad / Yoga Fingerprint
iio-sensor-proxy pacman Yoga Auto-rotate

🚀 Install

git clone https://github.com/v4cachy/legion-linux-toolkit
cd legion-linux-toolkit
sudo bash install.sh

✅ Auto-detects your Lenovo brand · installs brand-specific packages · hardware scan · launches tray automatically

🧙 First launch shows the setup wizard — choose language and run one-time hardware detection


🔄 Update

sudo bash update.sh

Pulls latest from GitHub, shows commit log, reinstalls all files, restarts daemon and tray.


🗑️ Uninstall

sudo bash uninstall.sh

Removes everything — service, udev rules, polkit, autostart, CLI. Optionally removes user config.


🆕 What's New (v0.6.1 — 20260320)

  • 🌍 11-language first-run wizard + one-time hardware detection
  • 🏷️ Multi-brand: Legion, LOQ, ThinkPad, ThinkBook, Yoga, IdeaPad
  • 🔧 ThinkPad — charge thresholds, fan levels 0–7, TrackPoint sliders, ThinkLight, Mic LED
  • 🔄 Yoga — hinge mode display, orientation lock toggle
  • 🎡 Animated fan icons driven by real RPM
  • 🔴 Legion Y-blade logo in tray, sidebar and title bar
  • 🎨 UI polish — cleaner topbar, brand-aware sidebar
  • 📦 install.sh — brand detection, auto packages, wizard reset on reinstall
  • 🔄 update.sh — git reset --hard origin (no more merge conflicts ever)

⚠️ Known Limitations

  • Manual fan PWM — not available on Legion driver (firmware-managed)
  • Instant Boot / Flip to Start — BIOS only
  • Dolby Audio / Atmos — Windows driver only
  • IR camera / Windows Hello — not supported

📄 License

MIT — free to use, modify and distribute.


Made with ❤️ for Linux on Lenovo · github.com/v4cachy/legion-linux-toolkit

About

A native Linux power management dashboard for Lenovo Legion laptops — power profiles, RGB keyboard, fan control, OC, battery management and system tray. Built for CachyOS / Arch + KDE Plasma 6.

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors