-
-
Notifications
You must be signed in to change notification settings - Fork 91
Conversation
Greptile SummaryThis PR fixes solid-colour keyboard lighting on G-series keyboards by switching from the
Confidence Score: 5/5Safe to merge — the change is hardware-verified, the fallback path is correct, and existing callers of set_keyboard_color() are unaffected. The Auto fallback correctly distinguishes a missing 0x8070 feature from any other error before falling through to 0x8080. Packet layout for the 0x8070 path is consistent with the HID++ 2.0 long-report structure, and the RAM-only persistence byte is the zero value so its exact offset is inconsequential. No callers are broken by the refactor. crates/openlogi-cli/src/cmd/diag/lighting.rs — module doc still references 0x8080 as the primary path. Important Files Changed
Sequence DiagramsequenceDiagram
participant CLI as diag lighting
participant W as set_keyboard_color_with
participant FI as resolve_feature_index
participant E as set_color_effects (0x8070)
participant PK as set_color_per_key (0x8080)
participant HID as HID Device
CLI->>W: "method=Auto, r, g, b"
W->>E: r, g, b
E->>FI: "feature_id=0x8070"
FI->>HID: get_feature(0x8070)
alt 0x8070 present
HID-->>FI: feature index
FI-->>E: Some(index)
loop zones 0..4
E->>HID: write_output_report (setZoneEffect, fixed, RAM-only)
end
E-->>W: Ok(())
W-->>CLI: Ok(())
else 0x8070 absent
HID-->>FI: None
FI-->>E: Ok(None)
E-->>W: "Err(FeatureUnsupported{0x8070})"
W->>PK: r, g, b (fallback)
PK->>FI: "feature_id=0x8080"
FI->>HID: get_feature(0x8080)
HID-->>FI: feature index
FI-->>PK: Some(index)
loop key chunks
PK->>HID: write_output_report (setGroupKeys)
end
PK->>HID: write_output_report (frameEnd)
PK-->>W: Ok(())
W-->>CLI: Ok(())
end
Reviews (4): Last reviewed commit: "docs(hid): fix set_color_effects RAM-onl..." | Re-trigger Greptile |
e954d33 to
c216939
Compare
Uh oh!
There was an error while loading. Please reload this page.
Context
Testing
openlogi diag lighting— solid, confirmed on hardwareScreen
Screenshot 2026年06月10日 at 2 42 22 PM Screenshot 2026年06月10日 at 2 42 26 PM Screenshot 2026年06月10日 at 2 42 30 PM