Skip to content

Commit 26e22b6

Browse files
[Silabs]Update our refrigerator app zap configs. (project-chip#36373)
* Update our refrigerator app zap configs. * fix missed rename from a previous pr * Move identify cluster to endpoint 1 (from 0)
1 parent 9961bb8 commit 26e22b6

File tree

5 files changed

+444
-495
lines changed

5 files changed

+444
-495
lines changed

examples/refrigerator-app/silabs/BUILD.gn

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import("//build_overrides/efr32_sdk.gni")
1818
import("//build_overrides/pigweed.gni")
1919

2020
import("${build_root}/config/defaults.gni")
21-
import("${efr32_sdk_build_root}/silabs_executable.gni")
21+
import("${silabs_sdk_build_root}/silabs_executable.gni")
2222

2323
import("${chip_root}/examples/common/pigweed/pigweed_rpcs.gni")
2424
import("${chip_root}/src/platform/device.gni")
@@ -38,7 +38,7 @@ if (wifi_soc) {
3838
import("${chip_root}/third_party/silabs/SiWx917_sdk.gni")
3939
examples_plat_dir = "${chip_root}/examples/platform/silabs/SiWx917"
4040
} else {
41-
import("${efr32_sdk_build_root}/efr32_sdk.gni")
41+
import("${silabs_sdk_build_root}/efr32_sdk.gni")
4242
examples_plat_dir = "${chip_root}/examples/platform/silabs/efr32"
4343
}
4444

examples/refrigerator-app/silabs/data_model/refrigerator-thread-app.matter

Lines changed: 67 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,56 @@ struct AtomicAttributeStatusStruct {
241241
status statusCode = 1;
242242
}
243243

244+
/** Attributes and commands for putting a device into Identification mode (e.g. flashing a light). */
245+
cluster Identify = 3 {
246+
revision 4;
247+
248+
enum EffectIdentifierEnum : enum8 {
249+
kBlink = 0;
250+
kBreathe = 1;
251+
kOkay = 2;
252+
kChannelChange = 11;
253+
kFinishEffect = 254;
254+
kStopEffect = 255;
255+
}
256+
257+
enum EffectVariantEnum : enum8 {
258+
kDefault = 0;
259+
}
260+
261+
enum IdentifyTypeEnum : enum8 {
262+
kNone = 0;
263+
kLightOutput = 1;
264+
kVisibleIndicator = 2;
265+
kAudibleBeep = 3;
266+
kDisplay = 4;
267+
kActuator = 5;
268+
}
269+
270+
attribute int16u identifyTime = 0;
271+
readonly attribute IdentifyTypeEnum identifyType = 1;
272+
readonly attribute command_id generatedCommandList[] = 65528;
273+
readonly attribute command_id acceptedCommandList[] = 65529;
274+
readonly attribute event_id eventList[] = 65530;
275+
readonly attribute attrib_id attributeList[] = 65531;
276+
readonly attribute bitmap32 featureMap = 65532;
277+
readonly attribute int16u clusterRevision = 65533;
278+
279+
request struct IdentifyRequest {
280+
int16u identifyTime = 0;
281+
}
282+
283+
request struct TriggerEffectRequest {
284+
EffectIdentifierEnum effectIdentifier = 0;
285+
EffectVariantEnum effectVariant = 1;
286+
}
287+
288+
/** Command description for Identify */
289+
command access(invoke: manage) Identify(IdentifyRequest): DefaultSuccess = 0;
290+
/** Command description for TriggerEffect */
291+
command access(invoke: manage) TriggerEffect(TriggerEffectRequest): DefaultSuccess = 64;
292+
}
293+
244294
/** The Descriptor Cluster is meant to replace the support from the Zigbee Device Object (ZDO) for describing a node, its endpoints and clusters. */
245295
cluster Descriptor = 29 {
246296
revision 2;
@@ -922,53 +972,6 @@ cluster NetworkCommissioning = 49 {
922972
command access(invoke: administer) QueryIdentity(QueryIdentityRequest): QueryIdentityResponse = 9;
923973
}
924974

925-
/** The cluster provides commands for retrieving unstructured diagnostic logs from a Node that may be used to aid in diagnostics. */
926-
cluster DiagnosticLogs = 50 {
927-
revision 1; // NOTE: Default/not specifically set
928-
929-
enum IntentEnum : enum8 {
930-
kEndUserSupport = 0;
931-
kNetworkDiag = 1;
932-
kCrashLogs = 2;
933-
}
934-
935-
enum StatusEnum : enum8 {
936-
kSuccess = 0;
937-
kExhausted = 1;
938-
kNoLogs = 2;
939-
kBusy = 3;
940-
kDenied = 4;
941-
}
942-
943-
enum TransferProtocolEnum : enum8 {
944-
kResponsePayload = 0;
945-
kBDX = 1;
946-
}
947-
948-
readonly attribute command_id generatedCommandList[] = 65528;
949-
readonly attribute command_id acceptedCommandList[] = 65529;
950-
readonly attribute event_id eventList[] = 65530;
951-
readonly attribute attrib_id attributeList[] = 65531;
952-
readonly attribute bitmap32 featureMap = 65532;
953-
readonly attribute int16u clusterRevision = 65533;
954-
955-
request struct RetrieveLogsRequestRequest {
956-
IntentEnum intent = 0;
957-
TransferProtocolEnum requestedProtocol = 1;
958-
optional char_string<32> transferFileDesignator = 2;
959-
}
960-
961-
response struct RetrieveLogsResponse = 1 {
962-
StatusEnum status = 0;
963-
long_octet_string logContent = 1;
964-
optional epoch_us UTCTimeStamp = 2;
965-
optional systime_us timeSinceBoot = 3;
966-
}
967-
968-
/** Retrieving diagnostic logs from a Node */
969-
command RetrieveLogsRequest(RetrieveLogsRequestRequest): RetrieveLogsResponse = 0;
970-
}
971-
972975
/** The General Diagnostics Cluster, along with other diagnostics clusters, provide a means to acquire standardized diagnostics metrics that MAY be used by a Node to assist a user or Administrative Node in diagnosing potential problems. */
973976
cluster GeneralDiagnostics = 51 {
974977
revision 2;
@@ -1756,10 +1759,12 @@ endpoint 0 {
17561759
ram attribute lastNetworkingStatus;
17571760
ram attribute lastNetworkID;
17581761
ram attribute lastConnectErrorValue;
1762+
callback attribute supportedThreadFeatures;
1763+
callback attribute threadVersion;
17591764
callback attribute generatedCommandList;
17601765
callback attribute acceptedCommandList;
17611766
callback attribute attributeList;
1762-
ram attribute featureMap default = 2;
1767+
callback attribute featureMap default = 2;
17631768
ram attribute clusterRevision default = 1;
17641769

17651770
handle command ScanNetworks;
@@ -1772,17 +1777,6 @@ endpoint 0 {
17721777
handle command ReorderNetwork;
17731778
}
17741779

1775-
server cluster DiagnosticLogs {
1776-
callback attribute generatedCommandList;
1777-
callback attribute acceptedCommandList;
1778-
callback attribute attributeList;
1779-
ram attribute featureMap default = 0;
1780-
ram attribute clusterRevision default = 1;
1781-
1782-
handle command RetrieveLogsRequest;
1783-
handle command RetrieveLogsResponse;
1784-
}
1785-
17861780
server cluster GeneralDiagnostics {
17871781
emits event HardwareFaultChange;
17881782
emits event RadioFaultChange;
@@ -1894,6 +1888,19 @@ endpoint 1 {
18941888
device type ma_refrigerator = 112, version 1;
18951889

18961890

1891+
server cluster Identify {
1892+
ram attribute identifyTime default = 0x0;
1893+
ram attribute identifyType default = 0x00;
1894+
callback attribute generatedCommandList;
1895+
callback attribute acceptedCommandList;
1896+
callback attribute attributeList;
1897+
ram attribute featureMap default = 0;
1898+
ram attribute clusterRevision default = 4;
1899+
1900+
handle command Identify;
1901+
handle command TriggerEffect;
1902+
}
1903+
18971904
server cluster Descriptor {
18981905
callback attribute deviceTypeList;
18991906
callback attribute serverList;
@@ -1920,7 +1927,7 @@ endpoint 1 {
19201927
}
19211928

19221929
server cluster RefrigeratorAlarm {
1923-
ram attribute mask default = 0;
1930+
ram attribute mask default = 1;
19241931
ram attribute state default = 0;
19251932
ram attribute supported default = 0;
19261933
callback attribute generatedCommandList;

0 commit comments

Comments
 (0)