Skip to content

Commit

Permalink
Add powersource device type to CHEF smokeco (#28795)
Browse files Browse the repository at this point in the history
Co-authored-by: Hare <[email protected]>
  • Loading branch information
2 people authored and pull[bot] committed Oct 2, 2023
1 parent 2027c68 commit 6744380
Show file tree
Hide file tree
Showing 3 changed files with 61 additions and 21 deletions.
5 changes: 1 addition & 4 deletions examples/chef/common/stubs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,4 @@ void emberAfChannelClusterInitCallback(EndpointId endpoint)
}
#endif // EMBER_AF_PLUGIN_CHANNEL_SERVER

bool emberAfPluginSmokeCoAlarmSelfTestRequestCommand(EndpointId endpointId)
{
return true;
}
void emberAfPluginSmokeCoAlarmSelfTestRequestCommand(EndpointId endpointId) {}
17 changes: 17 additions & 0 deletions examples/chef/devices/rootnode_smokecoalarm_686fe0dcb8.matter
Original file line number Diff line number Diff line change
Expand Up @@ -1381,6 +1381,7 @@ endpoint 0 {
}
}
endpoint 1 {
device type ma_powersource = 17, version 1;
device type ma_smokecoalarm = 118, version 1;


Expand All @@ -1389,6 +1390,7 @@ endpoint 1 {
ram attribute identifyType default = 0x0;
callback attribute generatedCommandList default = 0;
callback attribute acceptedCommandList default = 0;
callback attribute eventList;
callback attribute attributeList default = 0;
ram attribute featureMap default = 0;
ram attribute clusterRevision default = 2;
Expand All @@ -1403,6 +1405,19 @@ endpoint 1 {
ram attribute clusterRevision default = 3;
}

server cluster Descriptor {
callback attribute deviceTypeList default = 0;
callback attribute serverList default = 0;
callback attribute clientList default = 0;
callback attribute partsList default = 0;
callback attribute generatedCommandList default = 0;
callback attribute acceptedCommandList default = 0;
callback attribute eventList;
callback attribute attributeList default = 0;
ram attribute featureMap default = 0;
ram attribute clusterRevision default = 1;
}

server cluster PowerSource {
emits event BatFaultChange;
ram attribute status default = 0;
Expand All @@ -1414,6 +1429,7 @@ endpoint 1 {
callback attribute endpointList;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
callback attribute attributeList;
ram attribute featureMap default = 2;
ram attribute clusterRevision default = 2;
Expand Down Expand Up @@ -1446,6 +1462,7 @@ endpoint 1 {
ram attribute expiryDate default = 0;
callback attribute generatedCommandList;
callback attribute acceptedCommandList;
callback attribute eventList;
callback attribute attributeList;
ram attribute featureMap default = 3;
ram attribute clusterRevision default = 1;
Expand Down
60 changes: 43 additions & 17 deletions examples/chef/devices/rootnode_smokecoalarm_686fe0dcb8.zap
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
],
"endpointTypes": [
{
"id": 77,
"id": 10,
"name": "MA-rootdevice",
"deviceTypeRef": {
"id": 2,
Expand Down Expand Up @@ -5420,16 +5420,23 @@
]
},
{
"id": 78,
"id": 9,
"name": "Anonymous Endpoint Type",
"deviceTypeRef": {
"id": 44,
"code": 118,
"id": 3,
"code": 17,
"profileId": 259,
"label": "MA-smokecoalarm",
"name": "MA-smokecoalarm"
"label": "MA-powersource",
"name": "MA-powersource"
},
"deviceTypes": [
{
"id": 3,
"code": 17,
"profileId": 259,
"label": "MA-powersource",
"name": "MA-powersource"
},
{
"id": 44,
"code": 118,
Expand All @@ -5439,16 +5446,19 @@
}
],
"deviceTypeRefs": [
3,
44
],
"deviceVersions": [
1,
1
],
"deviceIdentifiers": [
17,
118
],
"deviceTypeName": "MA-smokecoalarm",
"deviceTypeCode": 118,
"deviceTypeName": "MA-powersource",
"deviceTypeCode": 17,
"deviceTypeProfileId": 259,
"clusters": [
{
Expand Down Expand Up @@ -5530,7 +5540,7 @@
"singleton": 0,
"bounded": 0,
"defaultValue": "0x0",
"reportable": 1,
"reportable": 0,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
Expand All @@ -5546,7 +5556,7 @@
"singleton": 0,
"bounded": 0,
"defaultValue": "0x0",
"reportable": 1,
"reportable": 0,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
Expand Down Expand Up @@ -5589,7 +5599,7 @@
"mfgCode": null,
"side": "server",
"type": "array",
"included": 0,
"included": 1,
"storageOption": "External",
"singleton": 0,
"bounded": 0,
Expand Down Expand Up @@ -7021,7 +7031,7 @@
"mfgCode": null,
"define": "DESCRIPTOR_CLUSTER",
"side": "server",
"enabled": 0,
"enabled": 1,
"attributes": [
{
"name": "DeviceTypeList",
Expand Down Expand Up @@ -7050,7 +7060,7 @@
"singleton": 0,
"bounded": 0,
"defaultValue": "0",
"reportable": 1,
"reportable": 0,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
Expand All @@ -7066,7 +7076,7 @@
"singleton": 0,
"bounded": 0,
"defaultValue": "0",
"reportable": 1,
"reportable": 0,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
Expand All @@ -7082,6 +7092,22 @@
"singleton": 0,
"bounded": 0,
"defaultValue": "0",
"reportable": 0,
"minInterval": 1,
"maxInterval": 65534,
"reportableChange": 0
},
{
"name": "TagList",
"code": 4,
"mfgCode": null,
"side": "server",
"type": "array",
"included": 0,
"storageOption": "External",
"singleton": 0,
"bounded": 0,
"defaultValue": "",
"reportable": 1,
"minInterval": 1,
"maxInterval": 65534,
Expand Down Expand Up @@ -7125,7 +7151,7 @@
"mfgCode": null,
"side": "server",
"type": "array",
"included": 0,
"included": 1,
"storageOption": "External",
"singleton": 0,
"bounded": 0,
Expand Down Expand Up @@ -7949,7 +7975,7 @@
"mfgCode": null,
"side": "server",
"type": "array",
"included": 0,
"included": 1,
"storageOption": "External",
"singleton": 0,
"bounded": 0,
Expand Down Expand Up @@ -8324,7 +8350,7 @@
"mfgCode": null,
"side": "server",
"type": "array",
"included": 0,
"included": 1,
"storageOption": "External",
"singleton": 0,
"bounded": 0,
Expand Down

0 comments on commit 6744380

Please sign in to comment.