Electronics / Software · Maintained software
Zenbook Duo on Hyprland
Automatic dock detection, display switching and keyboard setup for the ASUS Zenbook Duo on Hyprland.
- My role
- Independent Linux integration developer
- Period
- 2026
- Source
- Public repository
The question
Can a physical change in the laptop produce the right software state without another command?
Bash · Hyprland · udev · systemd · BlueZMy contribution
Built hardware-aware setup, dock detection, display switching, keyboard configuration, and recovery tooling for my laptop.
01 / problem
Dock and display behaviour
The Zenbook Duo's detachable keyboard changes how the laptop is used. Docking it over the lower panel should disable that screen; lifting it should restore the second display. Under Hyprland, those physical changes needed an explicit bridge into compositor and keyboard state.
I built the tooling around a machine I use, following the interaction across USB, display configuration, Bluetooth, and optional authentication setup.
02 / architecture
Architecture
- USB identity and dock events establish whether the detachable keyboard is covering the lower display.
- A display helper reconciles the desired monitor state through hyprctl and skips unchanged states.
- Guided BlueZ setup handles bonding and trusting the keyboard for its detached Bluetooth connection.
- Configuration overrides, diagnostics, and an optional user service support installation on the target hardware.
- Optional Howdy integration includes testing, configuration backups, and a rollback path around PAM changes.
03 / decisions
State changes and recovery
The dock loop expresses the desired screen state and applies a change only when needed. That makes repeated events easier to reason about and avoids treating every notification as a new command to toggle blindly.
Machine-specific display names and device identifiers remain configurable. Authentication setup is optional because it changes a different system boundary from display switching; it needs its own validation and recovery path.
04 / evaluation
Testing
The public implementation shows the complete path from dock detection to the Hyprland command, alongside keyboard setup and diagnostic helpers. The work was built and tested for the ASUS Zenbook Duo UX8406MA. It is hardware integration evidence, rather than a claim of support across every laptop or Linux configuration.
05 / limitations
Compatibility limits
- USB identifiers, display names, and desktop-session assumptions must be checked on a different machine.
- Bluetooth and face-authentication behavior also depend on the host configuration and available hardware.
- The repository contains an Arch packaging recipe. It is not a published AUR release.
- The source preview is for inspection; setup scripts make system changes when a user chooses to run them.
06 / next
Next steps
The useful next work is documented validation across more firmware, kernel, and compositor combinations, with clearer diagnostics when assumptions do not match. Wider compatibility should follow evidence from those configurations.
Source
Selected public files, with commit references and links to GitHub.
Public overview reviewed 8 September 2026. Repository commit: 2026-06-09.