AprilNEA / AprilNEA/OpenLogi

[Feature]: Divert keyboard Backlight Up/Down keys (CID 0x00E2/0x00E3) and add display-brightness actions

Open
#1,115 0 comments 0 reactions 0 assignees View on GitHub
area: hidpp platform: all type: feature
Dominant language
Rust
Stars
21k
Forks
675
Avg merge
2d 5h
Merged PRs (30d)
172

Description

### Pre-flight checklist

- [x] I searched existing issues and the Roadmap. Closest: #710 (media-key capture via the OS event tap — cannot cover these keys, see below) and #431 (broader keyboard remap coverage — doesn't mention these keys or a brightness action).

### Problem / motivation

On the MX Mechanical Mini for Mac (046d:b36d, Bluetooth-direct), the backlight up/down keys (F4/F5 on this model) are handled entirely inside the firmware: with the backlight enabled they adjust LEDs on-device; with it disabled via 0x1982 they do nothing. In neither case does any event reach the host — verified empirically — so the OS-hook remapper and the system-event tap proposed in #710 structurally cannot capture them, nor can Karabiner/hidutil.

Logi Options+ diverts exactly these two controls and ships them pre-mapped to display brightness. On the Mac variant that matters more than a convenience: F1–F3 are the Easy-Switch host keys, so **without this diversion the keyboard has no display-brightness keys at all**. Users migrating from Options+ lose them entirely.

**Hardware supports it** — `openlogi diag controls` on this keyboard:

```
cid task flags capabilities
0x00e2 0x00c1 0x043a divertable, analytics-events
0x00e3 0x00c2 0x043a divertable, analytics-events
```

Tasks 0x00C1/0x00C2 are the firmware-internal backlight functions; both controls report `divertable` — the same 0x1b04 machinery already used for the existing key slots.

### Proposed solution

1. `KeyBacklightDown`/`KeyBacklightUp` slots, diverted only when bound (unbound keys keep stock firmware behavior).
2. `BrightnessUp`/`BrightnessDown` actions: macOS posts the NX system-defined brightness keys (same family as the existing volume events); Linux presses `KEY_BRIGHTNESSUP/DOWN`; Windows has no key event for display brightness, so its injector debug-logs and skips.

Implementation attached as a PR (verified live on the device above). GUI exposure of keyboard slots is left as follow-up — these two slots are config-only, consistent with the nine existing keyboard slots.

### Alternatives considered

OS-level remapping — impossible, the keys emit no host-visible events. Leaving them inert — the current state.

### Environment

OpenLogi 0.8.1 base, macOS 26.6.2, Apple Silicon, Bluetooth-direct.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the existing key-slot diversion and 0x1b04 machinery, then inspect the platform-specific event injectors for macOS, Linux, and Windows. Done means bound KeyBacklightUp/Down slots divert correctly, brightness actions emit the requested platform events or debug-log and skip on Windows, while unbound keys retain firmware behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
macos, rust
Domain
desktop
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.