class

Matter::Cluster::GroupsCluster

Inherits Matter::Cluster::Base < Reference < Object

Groups Cluster Implementation (0x0004) Manages group membership for multicast communication

Features:

  • GroupNames (GN): Store names for groups

Specification: Matter 1.4 § 1.3

Constants

CLUSTER_ID = 4_u32
CLUSTER_REVISION = 65533_u32

Global attributes

CMD_ADD_GROUP = 0_u32

Command IDs

CMD_ADD_GROUP_IF_IDENTIFYING = 5_u32
CMD_ADD_GROUP_RESPONSE = 0_u32

Response IDs

CMD_GET_GROUP_MEMBERSHIP = 2_u32
CMD_GET_GROUP_MEMBERSHIP_RESPONSE = 2_u32
CMD_REMOVE_ALL_GROUPS = 4_u32
CMD_REMOVE_GROUP = 3_u32
CMD_REMOVE_GROUP_RESPONSE = 3_u32
CMD_VIEW_GROUP = 1_u32
CMD_VIEW_GROUP_RESPONSE = 1_u32
FEATURE_MAP_ATTR = 65532_u32
NAME_SUPPORT = 0_u32

Attribute IDs

Constructors

new(endpoint_id : DataType::EndpointNumber, feature_map : Feature = Feature::GroupNames, max_groups : UInt8 = 16_u8)
Source

Class methods

cluster_id

Groups Cluster Implementation (0x0004) Manages group membership for multicast communication

Features:

  • GroupNames (GN): Store names for groups

Specification: Matter 1.4 § 1.3

Source

Instance methods

attributes

Get all attribute metadata

Source
commands

Get all command metadata

Source
feature_map

Feature map

Source
feature_map=(feature_map : Feature)

Feature map

Source
group_count
Source
groups

Group storage: GroupId => GroupName

Source
groups=(groups : Hash(UInt16, String))

Group storage: GroupId => GroupName

Source
member_of?(group_id : UInt16) : Bool

Public API

Source
name

Get cluster name

Source
read_attribute(attribute_id : UInt32, fabric_index : UInt8 | Nil = nil) : InteractionModel::Status | Bytes

Read an attribute value The fabric_index parameter is optional and used for fabric-scoped attributes like CurrentFabricIndex in OperationalCredentialsCluster

Source
restore_state(json : String) : Nil

Restore cluster state from JSON. Override in subclasses that need to restore state. The json parameter is the string returned by save_state.

Source
save_state

Save cluster state to JSON for persistence. Override in subclasses that need to persist state (e.g., scenes, groups). Returns nil if no state needs to be persisted.

Source

Nested types