OpenLogi
Features

0x0001 · featureSet

Enumerate all features a device implements — read the count and look up each feature's ID, type flags, and version by index.

Enumerates the features a device implements. getCount() returns how many features there are; getFeatureId(index) returns the ID (and type flags — hidden, obsolete, etc.) at each index.

Together with 0x0000 root this lets a client discover a device's full capability set without prior knowledge of the model.

Spec: Logitech HID++ 2.0 — x0001 featureSet. Used by: capability discovery.

Function reference

The FeatureSetFeature wrapper (0x0001) exposes:

Methods

FunctionHID++ fnSignatureReturns
count0()u8
get_feature1(index: u8)FeatureInformation

All methods are async and return Result<…, Hidpp20Error>.

Types

FeatureInformation

Information about a specific feature as returned by get_feature.

FieldTypeDescription
idu16The protocol ID of the feature.
typFeatureTypeThe type flags of the feature.
versionu8The latest supported version of the feature. Added in feature version 1; 0 for older versions. Multi-version features are always backwards compatible as long as the feature ID does not change.

FeatureType

A bitfield describing some properties of a feature. Each field corresponds to one flag bit in the type byte returned by the device.

FieldBitDescription
obsolete7Feature replaced by a newer one but still advertised so that older software can support it.
hidden6Should not be known, managed, or used by end-user configuration software; the host should ignore it.
engineering5A hidden feature disabled for user software, used for internal testing and manufacturing.
manufacturing_deactivatable4Manufacturing feature that can be permanently deactivated; usually also hidden and engineering. Added in feature version 2; false on older versions.
compliance_deactivatable3Compliance feature that can be permanently deactivated; usually also hidden and engineering. Added in feature version 2; false on older versions.

Wire format

Both functions use a 3-byte short-report request payload. Responses are read from the 16-byte extended payload (extend_payload(), bytes 0–15; unused trailing bytes are zero-padded).

count (fn 0)

Request: [0x00, 0x00, 0x00] (no parameters)

Response (byte → field):

ByteFieldNotes
0count: u8Number of features supported by the device, excluding the root feature (index 0).

get_feature (fn 1)

Request: [index, 0x00, 0x00]index is the 1-based feature table index (must not be 0).

Response (byte → field):

ByteFieldNotes
0id high byteCombined with byte 1 as (payload[0] as u16) << 8 | payload[1] as u16.
1id low byteSee above.
2typ byteDecoded as a FeatureType bitfield: bit 7 = obsolete, bit 6 = hidden, bit 5 = engineering, bit 4 = manufacturing_deactivatable, bit 3 = compliance_deactivatable.
3version: u8Latest supported version of the feature; 0 for feature version 0 devices.

Usage (Rust)

use std::sync::Arc;
use hidpp::{device::Device, feature::feature_set::FeatureSetFeature};

// chan: Arc<HidppChannel>, device_index: u8 — obtained from a receiver walk.
let mut device = Device::new(Arc::clone(&chan), device_index).await?;

// High-level: enumerate all features and register implementations.
if let Some(features) = device.enumerate_features().await? {
    for info in &features {
        println!("feature 0x{:04x}  version={}  hidden={}", info.id, info.version, info.typ.hidden);
    }
}

// Low-level: use FeatureSetFeature directly after enumeration has registered it.
if let Some(feat) = device.get_feature::<FeatureSetFeature>() {
    let count = feat.count().await?;
    for i in 1..=count {
        let info = feat.get_feature(i).await?;
        println!("  [{i}] id=0x{:04x}  obsolete={}", info.id, info.typ.obsolete);
    }
}

On this page