Skip to content

Commit 1218080

Browse files
AlexPyginpull[bot]
authored andcommitted
Adding required fields for Light App (#24977)
* Adding required fields for Switch * Adding changes to .zap file * Removing lint ignore for failure fixed in this PR * Regenerated lighting-app.matter
1 parent 1e8cf88 commit 1218080

File tree

3 files changed

+72
-3
lines changed

3 files changed

+72
-3
lines changed

.github/workflows/lint.yml

-2
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,6 @@ jobs:
6464
for idl_file in $(find . -name '*.matter'); do
6565
# TODO: all these conformance failures should be fixed
6666
# Issues exist for most of them:
67-
# https://github.com/project-chip/connectedhomeip/issues/19180
6867
# https://github.com/project-chip/connectedhomeip/issues/19176
6968
# https://github.com/project-chip/connectedhomeip/issues/19175
7069
# https://github.com/project-chip/connectedhomeip/issues/19173
@@ -90,7 +89,6 @@ jobs:
9089
if [ "$idl_file" = './examples/chef/devices/rootnode_temperaturesensor_Qy1zkNW7c3.matter' ]; then continue; fi
9190
if [ "$idl_file" = './examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter' ]; then continue; fi
9291
if [ "$idl_file" = './examples/chef/devices/rootnode_windowcovering_RLCxaGi9Yx.matter' ]; then continue; fi
93-
if [ "$idl_file" = './examples/lighting-app/lighting-common/lighting-app.matter' ]; then continue; fi
9492
if [ "$idl_file" = './examples/log-source-app/log-source-common/log-source-app.matter' ]; then continue; fi
9593
if [ "$idl_file" = './examples/placeholder/linux/apps/app1/config.matter' ]; then continue; fi
9694
if [ "$idl_file" = './examples/placeholder/linux/apps/app2/config.matter' ]; then continue; fi

examples/lighting-app/lighting-common/lighting-app.matter

+4
Original file line numberDiff line numberDiff line change
@@ -1291,6 +1291,8 @@ server cluster Switch = 59 {
12911291
INT8U totalNumberOfPressesCounted = 1;
12921292
}
12931293

1294+
readonly attribute int8u numberOfPositions = 0;
1295+
readonly attribute int8u currentPosition = 1;
12941296
readonly attribute command_id generatedCommandList[] = 65528;
12951297
readonly attribute command_id acceptedCommandList[] = 65529;
12961298
readonly attribute event_id eventList[] = 65530;
@@ -2055,6 +2057,8 @@ endpoint 0 {
20552057
}
20562058

20572059
server cluster Switch {
2060+
ram attribute numberOfPositions default = 2;
2061+
ram attribute currentPosition;
20582062
ram attribute featureMap;
20592063
ram attribute clusterRevision default = 1;
20602064
}

examples/lighting-app/lighting-common/lighting-app.zap

+68-1
Original file line numberDiff line numberDiff line change
@@ -4540,7 +4540,42 @@
45404540
"mfgCode": null,
45414541
"define": "SWITCH_CLUSTER",
45424542
"side": "client",
4543-
"enabled": 0
4543+
"enabled": 0,
4544+
"attributes": [
4545+
4546+
{
4547+
"name": "NumberOfPositions",
4548+
"code": 0,
4549+
"mfgCode": null,
4550+
"side": "server",
4551+
"type": "int8u",
4552+
"included": 1,
4553+
"storageOption": "RAM",
4554+
"singleton": 0,
4555+
"bounded": 0,
4556+
"defaultValue": "2",
4557+
"reportable": 1,
4558+
"minInterval": 0,
4559+
"maxInterval": 65344,
4560+
"reportableChange": 0
4561+
},
4562+
{
4563+
"name": "CurrentPosition",
4564+
"code": 1,
4565+
"mfgCode": null,
4566+
"side": "server",
4567+
"type": "int8u",
4568+
"included": 1,
4569+
"storageOption": "RAM",
4570+
"singleton": 0,
4571+
"bounded": 0,
4572+
"defaultValue": "",
4573+
"reportable": 1,
4574+
"minInterval": 0,
4575+
"maxInterval": 65344,
4576+
"reportableChange": 0
4577+
}
4578+
]
45444579
},
45454580
{
45464581
"name": "Switch",
@@ -4550,6 +4585,38 @@
45504585
"side": "server",
45514586
"enabled": 1,
45524587
"attributes": [
4588+
{
4589+
"name": "NumberOfPositions",
4590+
"code": 0,
4591+
"mfgCode": null,
4592+
"side": "server",
4593+
"type": "int8u",
4594+
"included": 1,
4595+
"storageOption": "RAM",
4596+
"singleton": 0,
4597+
"bounded": 0,
4598+
"defaultValue": "2",
4599+
"reportable": 1,
4600+
"minInterval": 0,
4601+
"maxInterval": 65344,
4602+
"reportableChange": 0
4603+
},
4604+
{
4605+
"name": "CurrentPosition",
4606+
"code": 1,
4607+
"mfgCode": null,
4608+
"side": "server",
4609+
"type": "int8u",
4610+
"included": 1,
4611+
"storageOption": "RAM",
4612+
"singleton": 0,
4613+
"bounded": 0,
4614+
"defaultValue": "",
4615+
"reportable": 1,
4616+
"minInterval": 0,
4617+
"maxInterval": 65344,
4618+
"reportableChange": 0
4619+
},
45534620
{
45544621
"name": "FeatureMap",
45554622
"code": 65532,

0 commit comments

Comments
 (0)