diff --git a/src/app/zap-templates/zcl/data-model/chip/general-diagnostics-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/general-diagnostics-cluster.xml
index 8d9edde2dc1bc7..86ca9d621ecbe9 100644
--- a/src/app/zap-templates/zcl/data-model/chip/general-diagnostics-cluster.xml
+++ b/src/app/zap-templates/zcl/data-model/chip/general-diagnostics-cluster.xml
@@ -89,5 +89,24 @@ limitations under the License.
ActiveHardwareFaults
ActiveRadioFaults
ActiveNetworkFaults
+
+ Indicate a change in the set of hardware faults currently detected by the Node.
+
+
+
+
+ Indicate a change in the set of radio faults currently detected by the Node.
+
+
+
+
+ Indicate a change in the set of network faults currently detected by the Node.
+
+
+
+
+ Indicate the reason that caused the device to start-up.
+
+
diff --git a/src/app/zap-templates/zcl/data-model/chip/software-diagnostics-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/software-diagnostics-cluster.xml
index d24e20ce163cb5..7f4d6bd209f1df 100644
--- a/src/app/zap-templates/zcl/data-model/chip/software-diagnostics-cluster.xml
+++ b/src/app/zap-templates/zcl/data-model/chip/software-diagnostics-cluster.xml
@@ -24,6 +24,12 @@ limitations under the License.
+
+
+
+
+
+
General
Software Diagnostics
@@ -35,7 +41,11 @@ limitations under the License.
CurrentHeapUsed
CurrentHeapHighWatermark
- Reception of this command SHALL reset the values: The StackFreeMinimum field of the ThreadMetrics attribute, CurrentHeapHighWaterMark attribute
+ Reception of this command SHALL reset the values: The StackFreeMinimum field of the ThreadMetrics attribute, CurrentHeapHighWaterMark attribute.
+
+ Indicate the last software fault that has taken place on the Node.
+
+
diff --git a/src/app/zap-templates/zcl/data-model/chip/thread-network-diagnostics-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/thread-network-diagnostics-cluster.xml
index a07c6905abdfe4..0e5d309ae84abc 100644
--- a/src/app/zap-templates/zcl/data-model/chip/thread-network-diagnostics-cluster.xml
+++ b/src/app/zap-templates/zcl/data-model/chip/thread-network-diagnostics-cluster.xml
@@ -30,6 +30,11 @@ limitations under the License.
+
+
+
+
+
@@ -159,6 +164,10 @@ limitations under the License.
ActiveNetworkFaultsList
Reception of this command SHALL reset the OverrunCount attributes to 0
-
+
+
+ Indicate that a Node’s connection status to a Thread network has changed
+
+
-
\ No newline at end of file
+
diff --git a/src/app/zap-templates/zcl/data-model/chip/wifi-network-diagnostics-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/wifi-network-diagnostics-cluster.xml
index 0b0323c618b8d0..166f14d0a1b4b8 100644
--- a/src/app/zap-templates/zcl/data-model/chip/wifi-network-diagnostics-cluster.xml
+++ b/src/app/zap-templates/zcl/data-model/chip/wifi-network-diagnostics-cluster.xml
@@ -33,6 +33,18 @@ limitations under the License.
+
+
+
+
+
+
+
+
+
+
+
+
General
@@ -55,6 +67,19 @@ limitations under the License.
OverrunCount
Reception of this command SHALL reset the Breacon and Packet related count attributes to 0
-
+
+
+ Indicate that a Node’s Wi-Fi connection has been disconnected as a result of de-authenticated or dis-association and indicates the reason.
+
+
+
+ Indicate that a Node has failed to connect, or reconnect, to a Wi-Fi access point.
+
+
+
+
+ Indicate that a Node’s connection status to a Wi-Fi network has changed.
+
+
diff --git a/src/controller/python/chip/clusters/Objects.py b/src/controller/python/chip/clusters/Objects.py
index c123dc32c29de7..53b8781615cc12 100644
--- a/src/controller/python/chip/clusters/Objects.py
+++ b/src/controller/python/chip/clusters/Objects.py
@@ -6609,6 +6609,24 @@ class SoftwareDiagnostics:
id: typing.ClassVar[int] = 0x0034
class Structs:
+ @dataclass
+ class SoftwareFault(ClusterObject):
+ @ChipUtility.classproperty
+ def descriptor(cls) -> ClusterObjectDescriptor:
+ return ClusterObjectDescriptor(
+ Fields=[
+ ClusterObjectFieldDescriptor(
+ Label="id", Tag=0, Type=uint),
+ ClusterObjectFieldDescriptor(
+ Label="name", Tag=1, Type=str),
+ ClusterObjectFieldDescriptor(
+ Label="faultRecording", Tag=2, Type=bytes),
+ ])
+
+ id: 'uint' = None
+ name: 'str' = None
+ faultRecording: 'bytes' = None
+
@dataclass
class ThreadMetrics(ClusterObject):
@ChipUtility.classproperty
@@ -6746,6 +6764,10 @@ class RoutingRole(IntEnum):
kRouter = 0x05
kLeader = 0x06
+ class ThreadConnectionStatus(IntEnum):
+ kConnected = 0x00
+ kNotConnected = 0x01
+
class Structs:
@dataclass
class NeighborTable(ClusterObject):
@@ -7762,6 +7784,12 @@ class WiFiNetworkDiagnostics:
id: typing.ClassVar[int] = 0x0036
class Enums:
+ class AssociationFailureCause(IntEnum):
+ kUnknown = 0x00
+ kAssociationFailed = 0x01
+ kAuthenticationFailed = 0x02
+ kSsidNotFound = 0x03
+
class SecurityType(IntEnum):
kUnspecified = 0x00
kNone = 0x01
@@ -7770,6 +7798,10 @@ class SecurityType(IntEnum):
kWpa2 = 0x04
kWpa3 = 0x05
+ class WiFiConnectionStatus(IntEnum):
+ kConnected = 0x00
+ kNotConnected = 0x01
+
class WiFiVersionType(IntEnum):
k80211a = 0x00
k80211b = 0x01
diff --git a/zzz_generated/app-common/app-common/zap-generated/af-structs.h b/zzz_generated/app-common/app-common/zap-generated/af-structs.h
index 0eb557c5d1d1fb..ae0318953357b9 100644
--- a/zzz_generated/app-common/app-common/zap-generated/af-structs.h
+++ b/zzz_generated/app-common/app-common/zap-generated/af-structs.h
@@ -398,6 +398,14 @@ typedef struct _SemanticTag
uint16_t Value;
} SemanticTag;
+// Struct for SoftwareFault
+typedef struct _SoftwareFault
+{
+ uint64_t Id;
+ chip::CharSpan Name;
+ chip::ByteSpan FaultRecording;
+} SoftwareFault;
+
// Struct for TestListStructOctet
typedef struct _TestListStructOctet
{
diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp
index df34fcb629de25..3514b952973300 100644
--- a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp
+++ b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.cpp
@@ -6144,11 +6144,203 @@ namespace Commands {
} // namespace Commands
namespace Events {
+namespace HardwareFaultChange {
+CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
+{
+ TLV::TLVType outer;
+ ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kCurrent)), current));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kPrevious)), previous));
+ ReturnErrorOnFailure(writer.EndContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
+{
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ TLV::TLVType outer;
+ VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE);
+ ReturnErrorOnFailure(reader.EnterContainer(outer));
+ while ((err = reader.Next()) == CHIP_NO_ERROR)
+ {
+ VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG);
+ switch (TLV::TagNumFromTag(reader.GetTag()))
+ {
+ case to_underlying(Fields::kCurrent):
+ ReturnErrorOnFailure(DataModel::Decode(reader, current));
+ break;
+ case to_underlying(Fields::kPrevious):
+ ReturnErrorOnFailure(DataModel::Decode(reader, previous));
+ break;
+ default:
+ break;
+ }
+ }
+
+ VerifyOrReturnError(err == CHIP_END_OF_TLV, err);
+ ReturnErrorOnFailure(reader.ExitContainer(outer));
+ return CHIP_NO_ERROR;
+}
+} // namespace HardwareFaultChange.
+namespace RadioFaultChange {
+CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
+{
+ TLV::TLVType outer;
+ ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kCurrent)), current));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kPrevious)), previous));
+ ReturnErrorOnFailure(writer.EndContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
+{
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ TLV::TLVType outer;
+ VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE);
+ ReturnErrorOnFailure(reader.EnterContainer(outer));
+ while ((err = reader.Next()) == CHIP_NO_ERROR)
+ {
+ VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG);
+ switch (TLV::TagNumFromTag(reader.GetTag()))
+ {
+ case to_underlying(Fields::kCurrent):
+ ReturnErrorOnFailure(DataModel::Decode(reader, current));
+ break;
+ case to_underlying(Fields::kPrevious):
+ ReturnErrorOnFailure(DataModel::Decode(reader, previous));
+ break;
+ default:
+ break;
+ }
+ }
+
+ VerifyOrReturnError(err == CHIP_END_OF_TLV, err);
+ ReturnErrorOnFailure(reader.ExitContainer(outer));
+ return CHIP_NO_ERROR;
+}
+} // namespace RadioFaultChange.
+namespace NetworkFaultChange {
+CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
+{
+ TLV::TLVType outer;
+ ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kCurrent)), current));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kPrevious)), previous));
+ ReturnErrorOnFailure(writer.EndContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
+{
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ TLV::TLVType outer;
+ VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE);
+ ReturnErrorOnFailure(reader.EnterContainer(outer));
+ while ((err = reader.Next()) == CHIP_NO_ERROR)
+ {
+ VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG);
+ switch (TLV::TagNumFromTag(reader.GetTag()))
+ {
+ case to_underlying(Fields::kCurrent):
+ ReturnErrorOnFailure(DataModel::Decode(reader, current));
+ break;
+ case to_underlying(Fields::kPrevious):
+ ReturnErrorOnFailure(DataModel::Decode(reader, previous));
+ break;
+ default:
+ break;
+ }
+ }
+
+ VerifyOrReturnError(err == CHIP_END_OF_TLV, err);
+ ReturnErrorOnFailure(reader.ExitContainer(outer));
+ return CHIP_NO_ERROR;
+}
+} // namespace NetworkFaultChange.
+namespace BootReason {
+CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
+{
+ TLV::TLVType outer;
+ ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kBootReason)), bootReason));
+ ReturnErrorOnFailure(writer.EndContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
+{
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ TLV::TLVType outer;
+ VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE);
+ ReturnErrorOnFailure(reader.EnterContainer(outer));
+ while ((err = reader.Next()) == CHIP_NO_ERROR)
+ {
+ VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG);
+ switch (TLV::TagNumFromTag(reader.GetTag()))
+ {
+ case to_underlying(Fields::kBootReason):
+ ReturnErrorOnFailure(DataModel::Decode(reader, bootReason));
+ break;
+ default:
+ break;
+ }
+ }
+
+ VerifyOrReturnError(err == CHIP_END_OF_TLV, err);
+ ReturnErrorOnFailure(reader.ExitContainer(outer));
+ return CHIP_NO_ERROR;
+}
+} // namespace BootReason.
} // namespace Events
} // namespace GeneralDiagnostics
namespace SoftwareDiagnostics {
namespace Structs {
+namespace SoftwareFault {
+CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
+{
+ TLV::TLVType outer;
+ ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kId)), id));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kName)), name));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kFaultRecording)), faultRecording));
+ ReturnErrorOnFailure(writer.EndContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
+{
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ TLV::TLVType outer;
+ VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE);
+ err = reader.EnterContainer(outer);
+ ReturnErrorOnFailure(err);
+ while ((err = reader.Next()) == CHIP_NO_ERROR)
+ {
+ VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG);
+ switch (TLV::TagNumFromTag(reader.GetTag()))
+ {
+ case to_underlying(Fields::kId):
+ ReturnErrorOnFailure(DataModel::Decode(reader, id));
+ break;
+ case to_underlying(Fields::kName):
+ ReturnErrorOnFailure(DataModel::Decode(reader, name));
+ break;
+ case to_underlying(Fields::kFaultRecording):
+ ReturnErrorOnFailure(DataModel::Decode(reader, faultRecording));
+ break;
+ default:
+ break;
+ }
+ }
+
+ VerifyOrReturnError(err == CHIP_END_OF_TLV, err);
+ ReturnErrorOnFailure(reader.ExitContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+} // namespace SoftwareFault
namespace ThreadMetrics {
CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
{
@@ -6237,6 +6429,40 @@ CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
} // namespace Commands
namespace Events {
+namespace SoftwareFault {
+CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
+{
+ TLV::TLVType outer;
+ ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kSoftwareFault)), softwareFault));
+ ReturnErrorOnFailure(writer.EndContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
+{
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ TLV::TLVType outer;
+ VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE);
+ ReturnErrorOnFailure(reader.EnterContainer(outer));
+ while ((err = reader.Next()) == CHIP_NO_ERROR)
+ {
+ VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG);
+ switch (TLV::TagNumFromTag(reader.GetTag()))
+ {
+ case to_underlying(Fields::kSoftwareFault):
+ ReturnErrorOnFailure(DataModel::Decode(reader, softwareFault));
+ break;
+ default:
+ break;
+ }
+ }
+
+ VerifyOrReturnError(err == CHIP_END_OF_TLV, err);
+ ReturnErrorOnFailure(reader.ExitContainer(outer));
+ return CHIP_NO_ERROR;
+}
+} // namespace SoftwareFault.
} // namespace Events
} // namespace SoftwareDiagnostics
@@ -6565,6 +6791,40 @@ CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
} // namespace Commands
namespace Events {
+namespace ConnectionStatus {
+CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
+{
+ TLV::TLVType outer;
+ ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kConnectionStatus)), connectionStatus));
+ ReturnErrorOnFailure(writer.EndContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
+{
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ TLV::TLVType outer;
+ VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE);
+ ReturnErrorOnFailure(reader.EnterContainer(outer));
+ while ((err = reader.Next()) == CHIP_NO_ERROR)
+ {
+ VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG);
+ switch (TLV::TagNumFromTag(reader.GetTag()))
+ {
+ case to_underlying(Fields::kConnectionStatus):
+ ReturnErrorOnFailure(DataModel::Decode(reader, connectionStatus));
+ break;
+ default:
+ break;
+ }
+ }
+
+ VerifyOrReturnError(err == CHIP_END_OF_TLV, err);
+ ReturnErrorOnFailure(reader.ExitContainer(outer));
+ return CHIP_NO_ERROR;
+}
+} // namespace ConnectionStatus.
} // namespace Events
} // namespace ThreadNetworkDiagnostics
@@ -6604,6 +6864,113 @@ CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
} // namespace Commands
namespace Events {
+namespace Disconnection {
+CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
+{
+ TLV::TLVType outer;
+ ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kReasonCode)), reasonCode));
+ ReturnErrorOnFailure(writer.EndContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
+{
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ TLV::TLVType outer;
+ VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE);
+ ReturnErrorOnFailure(reader.EnterContainer(outer));
+ while ((err = reader.Next()) == CHIP_NO_ERROR)
+ {
+ VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG);
+ switch (TLV::TagNumFromTag(reader.GetTag()))
+ {
+ case to_underlying(Fields::kReasonCode):
+ ReturnErrorOnFailure(DataModel::Decode(reader, reasonCode));
+ break;
+ default:
+ break;
+ }
+ }
+
+ VerifyOrReturnError(err == CHIP_END_OF_TLV, err);
+ ReturnErrorOnFailure(reader.ExitContainer(outer));
+ return CHIP_NO_ERROR;
+}
+} // namespace Disconnection.
+namespace AssociationFailure {
+CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
+{
+ TLV::TLVType outer;
+ ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer));
+ ReturnErrorOnFailure(
+ DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kAssociationFailure)), associationFailure));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kStatus)), status));
+ ReturnErrorOnFailure(writer.EndContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
+{
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ TLV::TLVType outer;
+ VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE);
+ ReturnErrorOnFailure(reader.EnterContainer(outer));
+ while ((err = reader.Next()) == CHIP_NO_ERROR)
+ {
+ VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG);
+ switch (TLV::TagNumFromTag(reader.GetTag()))
+ {
+ case to_underlying(Fields::kAssociationFailure):
+ ReturnErrorOnFailure(DataModel::Decode(reader, associationFailure));
+ break;
+ case to_underlying(Fields::kStatus):
+ ReturnErrorOnFailure(DataModel::Decode(reader, status));
+ break;
+ default:
+ break;
+ }
+ }
+
+ VerifyOrReturnError(err == CHIP_END_OF_TLV, err);
+ ReturnErrorOnFailure(reader.ExitContainer(outer));
+ return CHIP_NO_ERROR;
+}
+} // namespace AssociationFailure.
+namespace ConnectionStatus {
+CHIP_ERROR Type::Encode(TLV::TLVWriter & writer, TLV::Tag tag) const
+{
+ TLV::TLVType outer;
+ ReturnErrorOnFailure(writer.StartContainer(tag, TLV::kTLVType_Structure, outer));
+ ReturnErrorOnFailure(DataModel::Encode(writer, TLV::ContextTag(to_underlying(Fields::kConnectionStatus)), connectionStatus));
+ ReturnErrorOnFailure(writer.EndContainer(outer));
+ return CHIP_NO_ERROR;
+}
+
+CHIP_ERROR DecodableType::Decode(TLV::TLVReader & reader)
+{
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ TLV::TLVType outer;
+ VerifyOrReturnError(TLV::kTLVType_Structure == reader.GetType(), CHIP_ERROR_WRONG_TLV_TYPE);
+ ReturnErrorOnFailure(reader.EnterContainer(outer));
+ while ((err = reader.Next()) == CHIP_NO_ERROR)
+ {
+ VerifyOrReturnError(TLV::IsContextTag(reader.GetTag()), CHIP_ERROR_INVALID_TLV_TAG);
+ switch (TLV::TagNumFromTag(reader.GetTag()))
+ {
+ case to_underlying(Fields::kConnectionStatus):
+ ReturnErrorOnFailure(DataModel::Decode(reader, connectionStatus));
+ break;
+ default:
+ break;
+ }
+ }
+
+ VerifyOrReturnError(err == CHIP_END_OF_TLV, err);
+ ReturnErrorOnFailure(reader.ExitContainer(outer));
+ return CHIP_NO_ERROR;
+}
+} // namespace ConnectionStatus.
} // namespace Events
} // namespace WiFiNetworkDiagnostics
diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h
index 980f6fc681a9e5..86de01e8024951 100644
--- a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h
+++ b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h
@@ -9128,10 +9128,175 @@ struct TypeInfo
};
} // namespace ClusterRevision
} // namespace Attributes
+namespace Events {
+namespace HardwareFaultChange {
+static constexpr PriorityLevel kPriorityLevel = PriorityLevel::Critical;
+static constexpr EventId kEventId = 0x00000000;
+
+enum class Fields
+{
+ kCurrent = 0,
+ kPrevious = 1,
+};
+
+struct Type
+{
+public:
+ static constexpr PriorityLevel priorityLevel = PriorityLevel::Critical;
+ static constexpr EventId eventId = 0x00000000;
+ static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; }
+
+ DataModel::List current;
+ DataModel::List previous;
+
+ CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const;
+};
+
+struct DecodableType
+{
+public:
+ static constexpr PriorityLevel GetPriorityLevel() { return kPriorityLevel; }
+ static constexpr EventId GetEventId() { return kEventId; }
+ static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; }
+
+ DataModel::DecodableList current;
+ DataModel::DecodableList previous;
+
+ CHIP_ERROR Decode(TLV::TLVReader & reader);
+};
+} // namespace HardwareFaultChange
+namespace RadioFaultChange {
+static constexpr PriorityLevel kPriorityLevel = PriorityLevel::Critical;
+static constexpr EventId kEventId = 0x00000001;
+
+enum class Fields
+{
+ kCurrent = 0,
+ kPrevious = 1,
+};
+
+struct Type
+{
+public:
+ static constexpr PriorityLevel priorityLevel = PriorityLevel::Critical;
+ static constexpr EventId eventId = 0x00000001;
+ static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; }
+
+ DataModel::List current;
+ DataModel::List previous;
+
+ CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const;
+};
+
+struct DecodableType
+{
+public:
+ static constexpr PriorityLevel GetPriorityLevel() { return kPriorityLevel; }
+ static constexpr EventId GetEventId() { return kEventId; }
+ static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; }
+
+ DataModel::DecodableList current;
+ DataModel::DecodableList previous;
+
+ CHIP_ERROR Decode(TLV::TLVReader & reader);
+};
+} // namespace RadioFaultChange
+namespace NetworkFaultChange {
+static constexpr PriorityLevel kPriorityLevel = PriorityLevel::Critical;
+static constexpr EventId kEventId = 0x00000002;
+
+enum class Fields
+{
+ kCurrent = 0,
+ kPrevious = 1,
+};
+
+struct Type
+{
+public:
+ static constexpr PriorityLevel priorityLevel = PriorityLevel::Critical;
+ static constexpr EventId eventId = 0x00000002;
+ static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; }
+
+ DataModel::List current;
+ DataModel::List previous;
+
+ CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const;
+};
+
+struct DecodableType
+{
+public:
+ static constexpr PriorityLevel GetPriorityLevel() { return kPriorityLevel; }
+ static constexpr EventId GetEventId() { return kEventId; }
+ static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; }
+
+ DataModel::DecodableList current;
+ DataModel::DecodableList previous;
+
+ CHIP_ERROR Decode(TLV::TLVReader & reader);
+};
+} // namespace NetworkFaultChange
+namespace BootReason {
+static constexpr PriorityLevel kPriorityLevel = PriorityLevel::Critical;
+static constexpr EventId kEventId = 0x00000003;
+
+enum class Fields
+{
+ kBootReason = 0,
+};
+
+struct Type
+{
+public:
+ static constexpr PriorityLevel priorityLevel = PriorityLevel::Critical;
+ static constexpr EventId eventId = 0x00000003;
+ static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; }
+
+ BootReasonType bootReason;
+
+ CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const;
+};
+
+struct DecodableType
+{
+public:
+ static constexpr PriorityLevel GetPriorityLevel() { return kPriorityLevel; }
+ static constexpr EventId GetEventId() { return kEventId; }
+ static constexpr ClusterId GetClusterId() { return Clusters::GeneralDiagnostics::Id; }
+
+ BootReasonType bootReason;
+
+ CHIP_ERROR Decode(TLV::TLVReader & reader);
+};
+} // namespace BootReason
+} // namespace Events
} // namespace GeneralDiagnostics
namespace SoftwareDiagnostics {
namespace Structs {
+namespace SoftwareFault {
+enum class Fields
+{
+ kId = 0,
+ kName = 1,
+ kFaultRecording = 2,
+};
+
+struct Type
+{
+public:
+ uint64_t id;
+ chip::CharSpan name;
+ chip::ByteSpan faultRecording;
+
+ CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const;
+ CHIP_ERROR Decode(TLV::TLVReader & reader);
+};
+
+using DecodableType = Type;
+
+} // namespace SoftwareFault
namespace ThreadMetrics {
enum class Fields
{
@@ -9267,6 +9432,41 @@ struct TypeInfo
};
} // namespace ClusterRevision
} // namespace Attributes
+namespace Events {
+namespace SoftwareFault {
+static constexpr PriorityLevel kPriorityLevel = PriorityLevel::Info;
+static constexpr EventId kEventId = 0x00000000;
+
+enum class Fields
+{
+ kSoftwareFault = 0,
+};
+
+struct Type
+{
+public:
+ static constexpr PriorityLevel priorityLevel = PriorityLevel::Info;
+ static constexpr EventId eventId = 0x00000000;
+ static constexpr ClusterId GetClusterId() { return Clusters::SoftwareDiagnostics::Id; }
+
+ Structs::SoftwareFault::Type softwareFault;
+
+ CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const;
+};
+
+struct DecodableType
+{
+public:
+ static constexpr PriorityLevel GetPriorityLevel() { return kPriorityLevel; }
+ static constexpr EventId GetEventId() { return kEventId; }
+ static constexpr ClusterId GetClusterId() { return Clusters::SoftwareDiagnostics::Id; }
+
+ Structs::SoftwareFault::DecodableType softwareFault;
+
+ CHIP_ERROR Decode(TLV::TLVReader & reader);
+};
+} // namespace SoftwareFault
+} // namespace Events
} // namespace SoftwareDiagnostics
namespace ThreadNetworkDiagnostics {
// Need to convert consumers to using the new enum classes, so we
@@ -9300,6 +9500,18 @@ enum class RoutingRole : uint8_t
#else // CHIP_USE_ENUM_CLASS_FOR_IM_ENUM
using RoutingRole = EmberAfRoutingRole;
#endif
+// Need to convert consumers to using the new enum classes, so we
+// don't just have casts all over.
+#ifdef CHIP_USE_ENUM_CLASS_FOR_IM_ENUM
+// Enum for ThreadConnectionStatus
+enum class ThreadConnectionStatus : uint8_t
+{
+ kConnected = 0x00,
+ kNotConnected = 0x01,
+};
+#else // CHIP_USE_ENUM_CLASS_FOR_IM_ENUM
+using ThreadConnectionStatus = EmberAfThreadConnectionStatus;
+#endif
namespace Structs {
namespace NeighborTable {
@@ -10200,11 +10412,60 @@ struct TypeInfo
};
} // namespace ClusterRevision
} // namespace Attributes
+namespace Events {
+namespace ConnectionStatus {
+static constexpr PriorityLevel kPriorityLevel = PriorityLevel::Info;
+static constexpr EventId kEventId = 0x00000000;
+
+enum class Fields
+{
+ kConnectionStatus = 0,
+};
+
+struct Type
+{
+public:
+ static constexpr PriorityLevel priorityLevel = PriorityLevel::Info;
+ static constexpr EventId eventId = 0x00000000;
+ static constexpr ClusterId GetClusterId() { return Clusters::ThreadNetworkDiagnostics::Id; }
+
+ ThreadConnectionStatus connectionStatus;
+
+ CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const;
+};
+
+struct DecodableType
+{
+public:
+ static constexpr PriorityLevel GetPriorityLevel() { return kPriorityLevel; }
+ static constexpr EventId GetEventId() { return kEventId; }
+ static constexpr ClusterId GetClusterId() { return Clusters::ThreadNetworkDiagnostics::Id; }
+
+ ThreadConnectionStatus connectionStatus;
+
+ CHIP_ERROR Decode(TLV::TLVReader & reader);
+};
+} // namespace ConnectionStatus
+} // namespace Events
} // namespace ThreadNetworkDiagnostics
namespace WiFiNetworkDiagnostics {
// Need to convert consumers to using the new enum classes, so we
// don't just have casts all over.
#ifdef CHIP_USE_ENUM_CLASS_FOR_IM_ENUM
+// Enum for AssociationFailureCause
+enum class AssociationFailureCause : uint8_t
+{
+ kUnknown = 0x00,
+ kAssociationFailed = 0x01,
+ kAuthenticationFailed = 0x02,
+ kSsidNotFound = 0x03,
+};
+#else // CHIP_USE_ENUM_CLASS_FOR_IM_ENUM
+using AssociationFailureCause = EmberAfAssociationFailureCause;
+#endif
+// Need to convert consumers to using the new enum classes, so we
+// don't just have casts all over.
+#ifdef CHIP_USE_ENUM_CLASS_FOR_IM_ENUM
// Enum for SecurityType
enum class SecurityType : uint8_t
{
@@ -10221,6 +10482,18 @@ using SecurityType = EmberAfSecurityType;
// Need to convert consumers to using the new enum classes, so we
// don't just have casts all over.
#ifdef CHIP_USE_ENUM_CLASS_FOR_IM_ENUM
+// Enum for WiFiConnectionStatus
+enum class WiFiConnectionStatus : uint8_t
+{
+ kConnected = 0x00,
+ kNotConnected = 0x01,
+};
+#else // CHIP_USE_ENUM_CLASS_FOR_IM_ENUM
+using WiFiConnectionStatus = EmberAfWiFiConnectionStatus;
+#endif
+// Need to convert consumers to using the new enum classes, so we
+// don't just have casts all over.
+#ifdef CHIP_USE_ENUM_CLASS_FOR_IM_ENUM
// Enum for WiFiVersionType
enum class WiFiVersionType : uint8_t
{
@@ -10441,6 +10714,110 @@ struct TypeInfo
};
} // namespace ClusterRevision
} // namespace Attributes
+namespace Events {
+namespace Disconnection {
+static constexpr PriorityLevel kPriorityLevel = PriorityLevel::Info;
+static constexpr EventId kEventId = 0x00000000;
+
+enum class Fields
+{
+ kReasonCode = 0,
+};
+
+struct Type
+{
+public:
+ static constexpr PriorityLevel priorityLevel = PriorityLevel::Info;
+ static constexpr EventId eventId = 0x00000000;
+ static constexpr ClusterId GetClusterId() { return Clusters::WiFiNetworkDiagnostics::Id; }
+
+ uint16_t reasonCode;
+
+ CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const;
+};
+
+struct DecodableType
+{
+public:
+ static constexpr PriorityLevel GetPriorityLevel() { return kPriorityLevel; }
+ static constexpr EventId GetEventId() { return kEventId; }
+ static constexpr ClusterId GetClusterId() { return Clusters::WiFiNetworkDiagnostics::Id; }
+
+ uint16_t reasonCode;
+
+ CHIP_ERROR Decode(TLV::TLVReader & reader);
+};
+} // namespace Disconnection
+namespace AssociationFailure {
+static constexpr PriorityLevel kPriorityLevel = PriorityLevel::Info;
+static constexpr EventId kEventId = 0x00000001;
+
+enum class Fields
+{
+ kAssociationFailure = 0,
+ kStatus = 1,
+};
+
+struct Type
+{
+public:
+ static constexpr PriorityLevel priorityLevel = PriorityLevel::Info;
+ static constexpr EventId eventId = 0x00000001;
+ static constexpr ClusterId GetClusterId() { return Clusters::WiFiNetworkDiagnostics::Id; }
+
+ AssociationFailureCause associationFailure;
+ uint16_t status;
+
+ CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const;
+};
+
+struct DecodableType
+{
+public:
+ static constexpr PriorityLevel GetPriorityLevel() { return kPriorityLevel; }
+ static constexpr EventId GetEventId() { return kEventId; }
+ static constexpr ClusterId GetClusterId() { return Clusters::WiFiNetworkDiagnostics::Id; }
+
+ AssociationFailureCause associationFailure;
+ uint16_t status;
+
+ CHIP_ERROR Decode(TLV::TLVReader & reader);
+};
+} // namespace AssociationFailure
+namespace ConnectionStatus {
+static constexpr PriorityLevel kPriorityLevel = PriorityLevel::Info;
+static constexpr EventId kEventId = 0x00000002;
+
+enum class Fields
+{
+ kConnectionStatus = 0,
+};
+
+struct Type
+{
+public:
+ static constexpr PriorityLevel priorityLevel = PriorityLevel::Info;
+ static constexpr EventId eventId = 0x00000002;
+ static constexpr ClusterId GetClusterId() { return Clusters::WiFiNetworkDiagnostics::Id; }
+
+ WiFiConnectionStatus connectionStatus;
+
+ CHIP_ERROR Encode(TLV::TLVWriter & writer, TLV::Tag tag) const;
+};
+
+struct DecodableType
+{
+public:
+ static constexpr PriorityLevel GetPriorityLevel() { return kPriorityLevel; }
+ static constexpr EventId GetEventId() { return kEventId; }
+ static constexpr ClusterId GetClusterId() { return Clusters::WiFiNetworkDiagnostics::Id; }
+
+ WiFiConnectionStatus connectionStatus;
+
+ CHIP_ERROR Decode(TLV::TLVReader & reader);
+};
+} // namespace ConnectionStatus
+} // namespace Events
} // namespace WiFiNetworkDiagnostics
namespace EthernetNetworkDiagnostics {
// Need to convert consumers to using the new enum classes, so we
diff --git a/zzz_generated/app-common/app-common/zap-generated/enums.h b/zzz_generated/app-common/app-common/zap-generated/enums.h
index 8ffe667f4a2af4..5845dca10820d0 100644
--- a/zzz_generated/app-common/app-common/zap-generated/enums.h
+++ b/zzz_generated/app-common/app-common/zap-generated/enums.h
@@ -129,6 +129,15 @@ enum EmberAfApplicationLauncherStatus : uint8_t
EMBER_ZCL_APPLICATION_LAUNCHER_STATUS_SYSTEM_BUSY = 2,
};
+// Enum for AssociationFailureCause
+enum EmberAfAssociationFailureCause : uint8_t
+{
+ EMBER_ZCL_ASSOCIATION_FAILURE_CAUSE_UNKNOWN = 0,
+ EMBER_ZCL_ASSOCIATION_FAILURE_CAUSE_ASSOCIATION_FAILED = 1,
+ EMBER_ZCL_ASSOCIATION_FAILURE_CAUSE_AUTHENTICATION_FAILED = 2,
+ EMBER_ZCL_ASSOCIATION_FAILURE_CAUSE_SSID_NOT_FOUND = 3,
+};
+
// Enum for AttributeWritePermission
enum EmberAfAttributeWritePermission : uint8_t
{
@@ -1561,6 +1570,13 @@ enum EmberAfThermostatSystemMode : uint8_t
EMBER_ZCL_THERMOSTAT_SYSTEM_MODE_FAN_ONLY = 7,
};
+// Enum for ThreadConnectionStatus
+enum EmberAfThreadConnectionStatus : uint8_t
+{
+ EMBER_ZCL_THREAD_CONNECTION_STATUS_CONNECTED = 0,
+ EMBER_ZCL_THREAD_CONNECTION_STATUS_NOT_CONNECTED = 1,
+};
+
// Enum for TimeEncoding
enum EmberAfTimeEncoding : uint8_t
{
@@ -1656,6 +1672,13 @@ enum EmberAfWcType : uint8_t
EMBER_ZCL_WC_TYPE_UNKNOWN = 255,
};
+// Enum for WiFiConnectionStatus
+enum EmberAfWiFiConnectionStatus : uint8_t
+{
+ EMBER_ZCL_WI_FI_CONNECTION_STATUS_CONNECTED = 0,
+ EMBER_ZCL_WI_FI_CONNECTION_STATUS_NOT_CONNECTED = 1,
+};
+
// Enum for WiFiVersionType
enum EmberAfWiFiVersionType : uint8_t
{
diff --git a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h
index abe7a2e40c9e99..081d8a42148cd3 100644
--- a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h
+++ b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h
@@ -60,6 +60,8 @@ CHIP_ERROR LogValue(const char * label, size_t indent,
const chip::app::Clusters::NetworkCommissioning::Structs::WiFiInterfaceScanResult::DecodableType & value);
CHIP_ERROR LogValue(const char * label, size_t indent,
const chip::app::Clusters::GeneralDiagnostics::Structs::NetworkInterfaceType::DecodableType & value);
+CHIP_ERROR LogValue(const char * label, size_t indent,
+ const chip::app::Clusters::SoftwareDiagnostics::Structs::SoftwareFault::DecodableType & value);
CHIP_ERROR LogValue(const char * label, size_t indent,
const chip::app::Clusters::SoftwareDiagnostics::Structs::ThreadMetrics::DecodableType & value);
CHIP_ERROR LogValue(const char * label, size_t indent,
@@ -638,6 +640,38 @@ CHIP_ERROR LogValue(const char * label, size_t indent,
ChipLogProgress(chipTool, "%s}", IndentStr(indent).c_str());
return CHIP_NO_ERROR;
}
+CHIP_ERROR LogValue(const char * label, size_t indent,
+ const chip::app::Clusters::SoftwareDiagnostics::Structs::SoftwareFault::DecodableType & value)
+{
+ ChipLogProgress(chipTool, "%s%s: {", IndentStr(indent).c_str(), label);
+ {
+ CHIP_ERROR err = LogValue("Id", indent + 1, value.id);
+ if (err != CHIP_NO_ERROR)
+ {
+ ChipLogProgress(chipTool, "%sStruct truncated due to invalid value for 'Id'", IndentStr(indent + 1).c_str());
+ return err;
+ }
+ }
+ {
+ CHIP_ERROR err = LogValue("Name", indent + 1, value.name);
+ if (err != CHIP_NO_ERROR)
+ {
+ ChipLogProgress(chipTool, "%sStruct truncated due to invalid value for 'Name'", IndentStr(indent + 1).c_str());
+ return err;
+ }
+ }
+ {
+ CHIP_ERROR err = LogValue("FaultRecording", indent + 1, value.faultRecording);
+ if (err != CHIP_NO_ERROR)
+ {
+ ChipLogProgress(chipTool, "%sStruct truncated due to invalid value for 'FaultRecording'",
+ IndentStr(indent + 1).c_str());
+ return err;
+ }
+ }
+ ChipLogProgress(chipTool, "%s}", IndentStr(indent).c_str());
+ return CHIP_NO_ERROR;
+}
CHIP_ERROR LogValue(const char * label, size_t indent,
const chip::app::Clusters::SoftwareDiagnostics::Structs::ThreadMetrics::DecodableType & value)
{