class Matter::Cluster::GeneralDiagnosticsCluster

Overview

General Diagnostics Cluster (0x0033)

Provides general diagnostic information about the device. Required on endpoint 0 for Root Node device type.

Matter Specification: Core 1.4 § 11.11 - General Diagnostics Cluster

Defined in:

matter/cluster/general_diagnostics_cluster.cr

Constant Summary

ATTR_ACTIVE_HARDWARE_FAULTS = 5_u32
ATTR_ACTIVE_NETWORK_FAULTS = 7_u32
ATTR_ACTIVE_RADIO_FAULTS = 6_u32
ATTR_ATTRIBUTE_LIST = 65531_u32
ATTR_BOOT_REASON = 4_u32
ATTR_CLUSTER_REVISION = 65533_u32

Global attributes

ATTR_FEATURE_MAP = 65532_u32
ATTR_NETWORK_INTERFACES = 0_u32

Attribute IDs

ATTR_REBOOT_COUNT = 1_u32
ATTR_TEST_EVENT_TRIGGERS_ENABLED = 8_u32
ATTR_TOTAL_OPERATIONAL_HOURS = 3_u32
ATTR_UP_TIME = 2_u32
CLUSTER_ID = 51_u32
CMD_TEST_EVENT_TRIGGER = 0_u32

Command IDs

Log = ::Log.for("matter.cluster.general_diagnostics")

Constructors

Class Method Summary

Instance Method Summary

Instance methods inherited from class Matter::Cluster::Base

attributes : Array(AttributeMetadata) attributes, cluster_id : DataType::ClusterId cluster_id, cluster_id=(cluster_id : DataType::ClusterId) cluster_id=, commands : Array(CommandMetadata) commands, data_version : UInt32 data_version, data_version=(data_version : UInt32) data_version=, endpoint_id : DataType::EndpointNumber endpoint_id, endpoint_id=(endpoint_id : DataType::EndpointNumber) endpoint_id=, events : Array(EventMetadata) events, get_attribute_metadata(attribute_id : UInt32) : AttributeMetadata | Nil get_attribute_metadata, get_command_metadata(command_id : UInt32) : CommandMetadata | Nil get_command_metadata, invoke_command(command_id : UInt32, fields : Bytes = Bytes.new(0), session_id : UInt64 | Nil = nil, is_case_session : Bool = false, fabric_index : UInt8 | Nil = nil) : InteractionModel::Status | CommandResponse invoke_command, name : String name, on_attribute_changed : Proc(UInt16, UInt32, UInt32, Nil) | Nil on_attribute_changed, on_attribute_changed=(on_attribute_changed : Proc(UInt16, UInt32, UInt32, Nil) | Nil) on_attribute_changed=, read_attribute(attribute_id : UInt32, fabric_index : UInt8 | Nil = nil) : InteractionModel::Status | Bytes read_attribute, write_attribute(attribute_id : UInt32, value : Bytes) : InteractionModel::Status write_attribute

Constructor methods inherited from class Matter::Cluster::Base

new(endpoint_id : DataType::EndpointNumber, cluster_id : DataType::ClusterId) new

Constructor Detail

def self.new(endpoint_id : DataType::EndpointNumber = DataType::EndpointNumber.new(0_u16), reboot_count : UInt16 = 0_u16, boot_reason : BootReason = BootReason::PowerOnReboot) #

[View source]

Class Method Detail

def self.cluster_id #

General Diagnostics Cluster (0x0033)

Provides general diagnostic information about the device. Required on endpoint 0 for Root Node device type.

Matter Specification: Core 1.4 § 11.11 - General Diagnostics Cluster


[View source]

Instance Method Detail

def active_hardware_faults : Array(HardwareFault) #

[View source]
def active_hardware_faults=(active_hardware_faults : Array(HardwareFault)) #

[View source]
def active_network_faults : Array(NetworkFault) #

[View source]
def active_network_faults=(active_network_faults : Array(NetworkFault)) #

[View source]
def active_radio_faults : Array(RadioFault) #

[View source]
def active_radio_faults=(active_radio_faults : Array(RadioFault)) #

[View source]
def add_network_interface(interface : NetworkInterfaceInfo) : Nil #

Add a network interface


[View source]
def attributes : Array(AttributeMetadata) #
Description copied from class Matter::Cluster::Base

Get all attribute metadata


[View source]
def boot_reason : BootReason #

[View source]
def boot_reason=(boot_reason : BootReason) #

[View source]
def commands : Array(CommandMetadata) #
Description copied from class Matter::Cluster::Base

Get all command metadata


[View source]
def name : String #
Description copied from class Matter::Cluster::Base

Get cluster name


[View source]
def network_interfaces : Array(NetworkInterfaceInfo) #

Instance variables


[View source]
def network_interfaces=(network_interfaces : Array(NetworkInterfaceInfo)) #

Instance variables


[View source]
def read_attribute(attribute_id : UInt32, fabric_index : UInt8 | Nil = nil) : InteractionModel::Status | Bytes #
Description copied from class Matter::Cluster::Base

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


[View source]
def reboot_count : UInt16 #

[View source]
def reboot_count=(reboot_count : UInt16) #

[View source]
def test_event_triggers_enabled : Bool #

[View source]
def test_event_triggers_enabled=(test_event_triggers_enabled : Bool) #

[View source]
def total_operational_hours : UInt32 #

[View source]
def total_operational_hours=(total_operational_hours : UInt32) #

[View source]
def up_time : UInt64 #

[View source]
def up_time=(up_time : UInt64) #

[View source]
def write_attribute(attribute_id : UInt32, value : Bytes) : InteractionModel::Status #
Description copied from class Matter::Cluster::Base

Write an attribute value


[View source]