Fix for x86_64 build fail
[platform/upstream/connectedhomeip.git] / src / app / zap-templates / zcl / data-model / silabs / sample-extensions.xml
1 <?xml version="1.0"?>
2 <!--
3 Copyright (c) 2008,2020 Silicon Labs.
4
5 Licensed under the Apache License, Version 2.0 (the "License");
6 you may not use this file except in compliance with the License.
7 You may obtain a copy of the License at
8
9     http://www.apache.org/licenses/LICENSE-2.0
10
11 Unless required by applicable law or agreed to in writing, software
12 distributed under the License is distributed on an "AS IS" BASIS,
13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 See the License for the specific language governing permissions and
15 limitations under the License.
16 -->
17 <!-- 
18      This xml file contains a sample extension to the Application Framework's
19      cluster definitions. There are 4 ways to add manufacturer specific
20      extensions within ZigBee.  
21      
22      1. Private Profile: 
23         You can create your own private ZigBee profile.
24         We do not provide an example of this here since private profiles 
25         may or may not even use the cluster library or something like it. If
26         you create your own custom profile you can basically do whatever you
27         want after the APS frame in the ZigBee packet. If you choose to use
28         the ZigBee cluster library within your private profile the Application
29         Framework will be useful to you. If you do not, it will not be useful
30         to you as all of the code in the Application Framework centers around
31         support for the ZigBee Cluster Library (ZCL).
32       
33     2. Manufacturer Specific Clusters:
34        You can add manufacturer specific clusters to a standard profile.
35        We provide an example of this below. In order to do this you must
36        satisfy two obligations:
37          
38          1. The cluster id MUST be in the manufacturer specific range,
39             0xfc00 - 0xffff.
40          2. The cluster definition must include a manufacturer code 
41             which will be applied to ALL attributes and 
42             commands within that cluster and must be provided when sending 
43             and receiving commands and interacting with attributes. 
44      
45      3. Manufacturer Specific Commands in Standard ZigBee Custer:
46         You can add your own commands to any standard ZigBee cluster with 
47         the following requirements:
48         
49         1. Your manufacturer specific commands may use any command id 
50           within the command id range, 0x00 - 0xff. 
51         2. You must also provide a manufacturer code for the command so 
52            that it can be distinguished from other commands in the cluster 
53            and handled appropriately.
54      
55      4. Manufacturer Specific Attributes in Standard ZigBee Cluster:
56         You can add your own attributes to any standard ZigBee cluster with 
57         the following requirements:
58         
59         1. Your manufacturer specific attributes may use any attribute id 
60            within the attribute id range, 0x0000 - 0xffff. 
61         2. You must also provide a manufacturer code for the attribute so 
62            that it can be distinguished from other attributes in the cluster 
63            and handled appropriately.
64         
65      This sample provides an example of how to:
66        1. Extend the ZCL with a manufacturer specific cluster 
67        2. Extend the standard ZCL on/off cluster with manufacturer specific
68           attributes.
69        3. Extend the standard ZCL on/off cluster with manufacturer specific
70           commands.
71      
72      Manufacturer Code:
73      In all cases below, we have used Ember's manufacturerCode 0x1002 since
74      the cluster, attributes and the commands were created by Ember 
75      as an example of how the Application Framework can be 
76      extended to support manufacturer specific commands and attributes.
77      
78      XML Validation:
79      You may validate any xml file that you create against the 
80      AppBuilder XSD located in tool/appbuilder/appbuilder.xsd
81      
82 -->
83 <configurator>
84   <domain name="Ember"/>
85   <!-- Use manufacturerCode to indicate that this is a manufacturer specific
86        cluster. -->
87   <cluster manufacturerCode="0x1002">
88     <name>Sample Mfg Specific Cluster</name>
89     <domain>Ember</domain>
90     <description>This cluster provides an example of how the Application 
91       Framework can be extended to include manufacturer specific clusters.
92       </description>
93     <!-- Cluster Id must be within the mfg spec range 0xfc00 - 0xffff -->
94     <code>0xFC00</code>
95     <define>SAMPLE_MFG_SPECIFIC_CLUSTER</define>
96     <client init="false" tick="false">true</client>
97     <server init="false" tick="false">true</server>
98     <attribute side="server" code="0x0000" define="ATTRIBUTE_ONE" type="INT8U" min="0x00" max="0xFF" writable="true" default="0x00" optional="true">ember sample attribute</attribute>
99     <attribute side="server" code="0x0001" define="ATTRIBUTE_TWO" type="INT8U" min="0x00" max="0xFF" writable="true" default="0x00" optional="true">ember sample attribute 2</attribute>
100     <command source="client" code="0x00" name="CommandOne" optional="true">
101       <description>
102         A sample manufacturer specific command within the sample manufacturer specific
103         cluster.
104       </description>
105       <arg name="argOne" type="INT8U"/>
106     </command>
107   </cluster>
108   <cluster manufacturerCode="0x1049">
109     <name>Sample Mfg Specific Cluster 2</name>
110     <domain>Ember</domain>
111     <description>This cluster provides an example of how the Application 
112       Framework can be extended to include manufacturer specific clusters.
113       </description>
114     <!-- Cluster Id must be within the mfg spec range 0xfc00 - 0xffff -->
115     <code>0xFC00</code>
116     <define>SAMPLE_MFG_SPECIFIC_CLUSTER_2</define>
117     <client init="false" tick="false">true</client>
118     <server init="false" tick="false">true</server>
119     <attribute side="server" code="0x0000" define="ATTRIBUTE_THREE" type="INT16U" min="0x0000" max="0xFFFF" writable="true" default="0x0000" optional="true">ember sample attribute 2</attribute>
120     <attribute side="server" code="0x0001" define="ATTRIBUTE_FOUR" type="INT16U" min="0x0000" max="0xFFFF" writable="true" default="0x0000" optional="true">ember sample attribute 2</attribute>
121     <command source="client" code="0x00" name="CommandTwo" optional="true">
122       <description>
123         A sample manufacturer specific command within the sample manufacturer specific
124         cluster.
125       </description>
126       <arg name="argOne" type="INT8U"/>
127     </command>
128   </cluster>
129   <!-- Use the cluster extension Extend the on/off cluster -->
130   <clusterExtension code="0x0006">
131     <attribute side="server" code="0x0000" define="SAMPLE_MFG_SPECIFIC_TRANSITION_TIME" type="INT16U" min="0x0000" max="0xFFFF" writable="true" default="0x0000" optional="true" manufacturerCode="0x1002">Sample Mfg Specific Attribute: 0x0000 0x1002</attribute>
132     <attribute side="server" code="0x0000" define="SAMPLE_MFG_SPECIFIC_TRANSITION_TIME_2" type="INT8U" min="0x0000" max="0xFFFF" writable="true" default="0x0000" optional="true" manufacturerCode="0x1049">Sample Mfg Specific Attribute: 0x0000 0x1049</attribute>
133     <attribute side="server" code="0x0001" define="SAMPLE_MFG_SPECIFIC_TRANSITION_TIME_3" type="INT8U" min="0x0000" max="0xFFFF" writable="true" default="0x00" optional="true" manufacturerCode="0x1002">Sample Mfg Specific Attribute: 0x0001 0x1002</attribute>
134     <attribute side="server" code="0x0001" define="SAMPLE_MFG_SPECIFIC_TRANSITION_TIME_4" type="INT16U" min="0x0000" max="0xFFFF" writable="true" default="0x0000" optional="true" manufacturerCode="0x1049">Sample Mfg Specific Attribute: 0x0001 0x1040</attribute>
135     <command source="client" code="0x00" name="SampleMfgSpecificOffWithTransition" optional="true" manufacturerCode="0x1002">
136       <description>Client command that turns the device off with a transition given
137         by the transition time in the Ember Sample transition time attribute.</description>
138     </command>
139     <command source="client" code="0x01" name="SampleMfgSpecificOnWithTransition" optional="true" manufacturerCode="0x1002">
140       <description>Client command that turns the device on with a transition given
141         by the transition time in the Ember Sample transition time attribute.</description>
142     </command>
143     <command source="client" code="0x02" name="SampleMfgSpecificToggleWithTransition" optional="true" manufacturerCode="0x1002">
144       <description>Client command that toggles the device with a transition given
145         by the transition time in the Ember Sample transition time attribute.</description>
146     </command>
147     <command source="client" code="0x01" name="SampleMfgSpecificOnWithTransition2" optional="true" manufacturerCode="0x1049">
148       <description>Client command that turns the device on with a transition given
149         by the transition time in the Ember Sample transition time attribute.</description>
150     </command>
151     <command source="client" code="0x02" name="SampleMfgSpecificToggleWithTransition2" optional="true" manufacturerCode="0x1049">
152       <description>Client command that toggles the device with a transition given
153         by the transition time in the Ember Sample transition time attribute.</description>
154     </command>
155   </clusterExtension>
156 </configurator>