Skip to content

nikitaeight24family/BrightnessMirror

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BrightnessMirror

Make your laptop's brightness keys control your external monitor — smoothly, with a native-looking on-screen indicator.

On Windows, the brightness keys (on your laptop or a keyboard like the Logitech MX Keys) only ever change the built-in laptop panel. Plug in an external monitor — especially in a closed-lid / clamshell dock setup — and the keys do nothing you can see: they're still dimming the hidden internal panel. BrightnessMirror fixes that. It watches the internal brightness change, and mirrors it to your external monitor over DDC/CI, with a Windows 11-style on-screen indicator.

Built and tested on a Huawei MateBook (clamshell) driving a Dell UltraSharp U2725QE over Thunderbolt.

indicator

Does this sound like your problem?

If you searched for any of these, this tool is the fix:

  • Brightness keys don't work / do nothing on my external monitor (Windows)
  • Laptop lid closed (clamshell) or docked — brightness buttons don't change the screen
  • Windows brightness keys only dim the laptop panel, not the external monitor
  • Logitech MX Keys / keyboard brightness keys don't control monitor brightness
  • How to control external monitor brightness with the keyboard / a hotkey on Windows
  • Dell monitor Auto Brightness stuck / dims to 3% / "Range Level" Low vs High
  • Adjust external / desktop monitor brightness via DDC/CI without the OSD buttons

Windows routes the brightness keys only to the built-in laptop panel. On a desktop, or a laptop that's docked or running with the lid closed, the keys appear to do nothing — they're changing a panel you can't see. BrightnessMirror bridges those key presses to your external monitor over DDC/CI, with a native-looking on-screen indicator.

Features

  • Brightness keys drive the external monitor. Press brightness up/down and your DDC/CI monitor follows — even with the laptop lid closed.
  • One clean step per press. Each press moves the monitor by the key's own step (~10%), sent as a single DDC command — deliberately gentle, so it never floods the monitor's DDC/I²C controller. The on-screen indicator eases smoothly between values.
  • Native-style indicator. A crisp, DPI-aware, rounded pill at the top-center of the screen (sun icon + bar + %), eased at 60 fps. Auto-hides after ~1.5 s.
  • "Both keys" gesture → Auto Brightness. Press brightness-up and brightness-down together to toggle the monitor's own ambient-light Auto Brightness on/off. It preserves your Range Level and Auto Color settings (see below). Press both again to return to manual, holding the brightness where auto left it.
  • Invisible & self-contained. No console window, no tray icon, no notifications. A single ~17 KB native .exe, no runtime dependencies beyond the .NET Framework that ships with Windows.
  • Single instance, auto-start. Runs hidden at logon via a per-user registry autostart entry (no admin, no scheduled task); a named mutex prevents duplicates.

Install

  1. Download BrightnessMirror-Setup-x.y.z.exe from the Releases page.
  2. Run it. It installs per-user (no admin required), registers a hidden logon task, and starts immediately.
  3. Make sure DDC/CI is enabled in your monitor's on-screen menu (most Dells have it on by default).

That's it — press a brightness key and your external monitor responds.

Usage

Action Result
Brightness up / down External monitor steps up/down from its current level; indicator shows the value
Both brightness keys at once Toggle the monitor's ambient Auto Brightness (Dell)
Single key while auto is on Nudges brightness from the current level (no dark flash). Auto keeps running underneath — use both keys to turn it fully off

How it works

Windows sends the brightness keys only to the internal panel, and each change raises a WmiMonitorBrightnessEvent (WMI, root\wmi). BrightnessMirror subscribes to that event, computes the delta, and applies it to every external DDC/CI monitor via the Windows monitor API (dxva2.dllGetMonitorBrightness / SetMonitorBrightness). Internal panels and non-DDC monitors are skipped automatically, because they don't answer GetMonitorBrightness.

The "both keys" gesture is detected as an up-then-down reversal in the event stream within a short window.

The Dell Auto-Brightness bitfield

Dell's Auto Brightness isn't a simple on/off VCP. It's a bitfield packed into VCP 0x66 (the standard "Ambient Light Sensor" code):

0x02 = auto ON     0x01 = auto OFF      (low bits: enable/disable)
0x10, 0x80         = Range Level + Auto Color state   (higher bits)

Writing a bare 0x66 = 2 (as most tools would, to "enable the sensor") clears the higher bits, silently resetting Range Level to Low and turning Auto Color off. BrightnessMirror instead reads 0x66, flips only the enable bit, and writes it back — so your Range/Color choices survive. These values were recovered by instrumenting Dell Display and Peripheral Manager (DDPM) with Frida and watching the exact SetVCPFeature calls it makes.

Note: the Auto-Brightness gesture is Dell-specific (the 0x66 bitfield). The core brightness-mirroring and indicator work on any DDC/CI monitor.

Build from source

Requirements: Windows, .NET Framework 4.x (ships with Windows), and Inno Setup 6 for the installer.

# compile the exe + build the installer
powershell -ExecutionPolicy Bypass -File build\build.ps1

Outputs land in dist\.

Uninstall

Settings → Apps → BrightnessMirror → Uninstall. (Or run the entry in Installed apps.) This removes the logon task and stops the process.

Compatibility & notes

  • DDC/CI required on the external monitor. Monitors without it (or that strip DDC through a dock/KVM) can't be controlled.
  • The Auto Brightness gesture targets Dell's 0x66 bitfield; other brands vary. Manual mirroring is brand-agnostic.
  • Dell's U2725QE Auto Brightness has firmware quirks (it can dim aggressively on some firmware even at Range = High) — that's the monitor's algorithm, not BrightnessMirror.
  • Tested with one external DDC monitor. Multiple DDC monitors will all follow the keys.

FAQ

Does it work on non-Dell monitors? Yes for the main feature — any monitor with DDC/CI works for the brightness keys and the indicator. Only the ambient Auto-Brightness gesture is Dell-specific.

Does it need admin rights? No. Per-user install, per-user autostart, no elevation.

My external monitor still doesn't respond after installing. Enable DDC/CI in the monitor's on-screen menu. Some docks, KVMs, or HDMI switches strip DDC — try a direct DisplayPort/USB-C/Thunderbolt connection.

Does it work with the laptop lid closed / in a dock? Yes — that's exactly the case it was built for (clamshell / docked).

Multiple external monitors? All DDC/CI-capable monitors follow the keys together.

Is it safe / open source? Yes — MIT-licensed, a single small C# app, no telemetry, no network access, no background window.

How is this different from Twinkle Tray / Monitorian? Those give you a tray slider you click. BrightnessMirror makes your existing hardware brightness keys drive the external monitor directly, with an on-screen indicator — nothing to click.

License

MIT — see LICENSE.


Keywords: Windows external monitor brightness keys, DDC/CI brightness control, laptop clamshell docked brightness not working, brightness keys only change laptop screen, control monitor brightness with keyboard hotkey, Dell UltraSharp auto brightness range level, Logitech MX Keys brightness external display, dxva2 SetMonitorBrightness, WmiMonitorBrightnessEvent, VCP 0x10 0x66, monitor brightness OSD indicator Windows.

About

Windows tool that makes your laptop's hardware brightness keys control an external DDC/CI monitor - works docked / lid-closed / clamshell. Smooth fade, native on-screen indicator, and a both-keys gesture to toggle Dell ambient Auto Brightness. No admin.

Topics

Resources

License

Stars

0 stars

Watchers

0 watching

Forks

Packages

 
 
 

Contributors