Skip to content

Commit

Permalink
Window Covering: Add FeatureMap (#9246)
Browse files Browse the repository at this point in the history
* WC: Add FeatureMap inside xml + zap

* WC: Update all autogenerated files by ZAP + SDK

* WC: Activate Test for global attribute FeatureMap reading value

* WC: Add missing test dependancies

* WC: Add absolute positioning into FeatureMap

* Fix: Conflict on Cluster gen

* WC: Regenerate/Rebase

* WC: Regen / Rebase

* WC: Regen rebase

* Restyled by autopep8

* Restyled by autopep8

Co-authored-by: Justin Wood <[email protected]>
Co-authored-by: Restyled.io <[email protected]>
  • Loading branch information
3 people authored Oct 27, 2021
1 parent 1d10ef8 commit 1114959
Show file tree
Hide file tree
Showing 24 changed files with 535 additions and 278 deletions.
15 changes: 15 additions & 0 deletions examples/all-clusters-app/all-clusters-common/all-clusters-app.zap
Original file line number Diff line number Diff line change
Expand Up @@ -10408,6 +10408,21 @@
"maxInterval": 65344,
"reportableChange": 0
},
{
"name": "FeatureMap",
"code": 65532,
"mfgCode": null,
"side": "server",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "0",
"reportable": 0,
"minInterval": 0,
"maxInterval": 65344,
"reportableChange": 0
},
{
"name": "ClusterRevision",
"code": 65533,
Expand Down
30 changes: 30 additions & 0 deletions examples/window-app/common/window-app.zap
Original file line number Diff line number Diff line change
Expand Up @@ -5693,6 +5693,21 @@
"maxInterval": 65344,
"reportableChange": 0
},
{
"name": "FeatureMap",
"code": 65532,
"mfgCode": null,
"side": "server",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "0x0001",
"reportable": 0,
"minInterval": 0,
"maxInterval": 65344,
"reportableChange": 0
},
{
"name": "ClusterRevision",
"code": 65533,
Expand Down Expand Up @@ -6909,6 +6924,21 @@
"maxInterval": 65344,
"reportableChange": 0
},
{
"name": "FeatureMap",
"code": 65532,
"mfgCode": null,
"side": "server",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "0x0001",
"reportable": 0,
"minInterval": 0,
"maxInterval": 65344,
"reportableChange": 0
},
{
"name": "ClusterRevision",
"code": 65533,
Expand Down
8 changes: 3 additions & 5 deletions src/app/tests/suites/certification/Test_TC_WNCV_1_1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,7 @@ tests:
response:
value: 5

- label: "read the optional global attribute: FeatureMap"
disabled: 1
- label: "read the global attribute: FeatureMap"
command: "readAttribute"
attribute: "FeatureMap"
response:
Expand All @@ -53,12 +52,11 @@ tests:
command: "writeAttribute"
attribute: "FeatureMap"
arguments:
value: 0
value: 5
response:
error: 1

- label: "reads back optional global attribute: FeatureMap"
disabled: true
- label: "reads back global attribute: FeatureMap"
command: "readAttribute"
attribute: "FeatureMap"
response:
Expand Down
15 changes: 11 additions & 4 deletions src/app/zap-templates/zcl/data-model/chip/window-covering.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,16 @@ limitations under the License.
<define>WINDOW_COVERING_CLUSTER</define>
<client tick="false" init="false">true</client>
<server tick="false" init="false">true</server>
<!-- TODO: Add feature map once it is supported -->
<tag name="LF" description="Lift Control"/>
<tag name="TL" description="Tilt Control"/>
<tag name="PA" description="Position Aware"/>
<tag name="ABS" description="Absolute Positioning"/>
<globalAttribute side="server" code="0xFFFC" value="0x0001">
<featureBit tag="LF" bit="0">true</featureBit>
<featureBit tag="TL" bit="1">false</featureBit>
<featureBit tag="PA" bit="2">false</featureBit>
<featureBit tag="ABS" bit="3">false</featureBit>
</globalAttribute>
<globalAttribute side="either" code="0xFFFD" value="5"/>
<!-- Window Covering Information Attribute Set -->
<attribute side="server" writable="false" code="0x0000" define="WC_TYPE" type="ENUM8" min="0x00" max="0x09" default="0x00" optional="false">Type</attribute>
Expand Down Expand Up @@ -86,7 +95,6 @@ limitations under the License.

<!-- Window Covering Descriptive Enum Set -->
<enum name="WcType" type="ENUM8">
<cluster code="0x0102"/>
<item value="00" name="Rollershade"/>
<item value="01" name="Rollershade2Motor"/>
<item value="02" name="RollershadeExterior"/>
Expand All @@ -101,7 +109,6 @@ limitations under the License.
</enum>

<enum name="WcEndProductType" type="ENUM8">
<cluster code="0x0102"/>
<item value="00" name="RollerShade"/>
<item value="01" name="RomanShade"/>
<item value="02" name="BalloonShade"/>
Expand Down Expand Up @@ -171,4 +178,4 @@ limitations under the License.
<field mask="0x0400" name="ManualOperation"/>
<field mask="0x0800" name="Protection"/>
</bitmap>
</configurator>
</configurator>
15 changes: 15 additions & 0 deletions src/controller/data_model/controller-clusters.zap
Original file line number Diff line number Diff line change
Expand Up @@ -6523,6 +6523,21 @@
"maxInterval": 65344,
"reportableChange": 0
},
{
"name": "FeatureMap",
"code": 65532,
"mfgCode": null,
"side": "server",
"included": 1,
"storageOption": "RAM",
"singleton": 0,
"bounded": 0,
"defaultValue": "0x0001",
"reportable": 0,
"minInterval": 0,
"maxInterval": 65344,
"reportableChange": 0
},
{
"name": "ClusterRevision",
"code": 65533,
Expand Down
25 changes: 25 additions & 0 deletions src/controller/java/zap-generated/CHIPClusters-JNI.cpp

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions src/controller/python/chip/clusters/CHIPClusters.cpp

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 12 additions & 0 deletions src/controller/python/chip/clusters/CHIPClusters.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

41 changes: 0 additions & 41 deletions src/controller/python/chip/clusters/Objects.py

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 1114959

Please sign in to comment.