0x4530 · dualPlatform
Read or select one of two persistent keyboard OS families, and receive hardware platform-change events.
DualPlatform selects the HID key-code family for a two-platform device. IosOrMac is value 0, and AndroidOrWindows is value 1.
Spec: No public Logitech specification. Layout reverse-engineered from Logi Options+ 2.8 (static analysis). Cross-checked: Solaar. Used by: Not used by OpenLogi outside the
openlogi-hidppwrapper.
Function reference
DualPlatformFeature is creatable for feature version 0.
Methods
| Function | HID++ fn | Signature | Returns |
|---|---|---|---|
get_platform | 0 | () | DualPlatformSelection |
set_platform | 2 | (platform: DualPlatformSelection) | DualPlatformSelection |
listen | event | () | async_channel::Receiver<DualPlatformEvent> |
get_platform and set_platform are async and return Result<…, Hidpp20Error>. listen comes from EmittingFeature<DualPlatformEvent>.
Types
DualPlatformSelection
| Variant | Value | Description |
|---|---|---|
IosOrMac | 0 | iOS or macOS HID key-code family. |
AndroidOrWindows | 1 | Android or Windows HID key-code family. |
The selection is persistent. The user can select it during pairing or with a short press of the OS-selection button.
Events
| Variant | Payload | Description |
|---|---|---|
PlatformChanged | DualPlatformSelection | The user changed the platform with an OS-selection button. |
set_platform does not emit this event. OpenLogi accepts only event function 0.
Wire format
Each request uses a 3-byte short payload. OpenLogi normalizes the reply to 16 bytes, then parses byte 0 as DualPlatformSelection.
get_platform (fn 0)
Request:
| Byte | Field | Notes |
|---|---|---|
| 0–2 | — | No parameters. OpenLogi sends 0x00, 0x00, 0x00. |
Response:
| Byte | Field | Notes |
|---|---|---|
| 0 | platform | 0 = IosOrMac; 1 = AndroidOrWindows. |
| 1–15 | — | OpenLogi ignores these bytes. |
set_platform (fn 2)
Request:
| Byte | Field | Notes |
|---|---|---|
| 0 | platform | DualPlatformSelection as u8. |
| 1–2 | — | Padding. OpenLogi sends 0x00. |
Response:
| Byte | Field | Notes |
|---|---|---|
| 0 | platform | OpenLogi parses this byte as the device echo. |
| 1–15 | — | OpenLogi ignores these bytes. |
PlatformChanged event (fn 0)
| Byte | Field | Notes |
|---|---|---|
| 0 | platform | 0 = IosOrMac; 1 = AndroidOrWindows. |
| 1–15 | — | OpenLogi ignores these bytes. |
How OpenLogi uses it
OpenLogi v0.8.15 exposes this typed wrapper and its broadcast listener. No device-layer, agent, CLI, or user-interface path reads or writes 0x4530.
The wrapper does not cache the selection. It does not restore this persistent setting at exit.
Open questions
Logi Options+ 2.8 uses function 0 to read and function 1 to write. Solaar uses function 0 to read and function 2 to write.
OpenLogi v0.8.15 uses function 0 for reads and function 2 for writes. PR #1766 corrected the read in v0.8.14, so a read no longer sends a possible setter request.
No public function table or hardware capture resolves the write index. Logi Options+ also does not parse a setter echo, so the meaning of OpenLogi's returned byte remains unverified.
Usage (Rust)
use hidpp::{
device::Device,
feature::{
EmittingFeature,
dual_platform::{DualPlatformEvent, DualPlatformFeature, DualPlatformSelection},
},
};
// `device` is a discovered HID++ device.
device.enumerate_features().await?;
if let Some(feature) = device.get_feature::<DualPlatformFeature>() {
let current = feature.get_platform().await?;
println!("current platform: {current:?}");
let echoed = feature
.set_platform(DualPlatformSelection::AndroidOrWindows)
.await?;
println!("returned platform: {echoed:?}");
let events = feature.listen();
if let Ok(DualPlatformEvent::PlatformChanged(platform)) = events.recv().await {
println!("hardware platform change: {platform:?}");
}
}