@@ -17,6 +17,49 @@ limitations under the License.
17
17
<configurator >
18
18
<domain name =" CHIP" />
19
19
20
+ <enum name =" GranularityEnum" type =" ENUM8" >
21
+ <cluster code =" 0x0038" />
22
+ <item name =" NoTimeGranularity" value =" 0x00" />
23
+ <item name =" MinutesGranularity" value =" 0x01" />
24
+ <item name =" SecondsGranularity" value =" 0x02" />
25
+ <item name =" MillisecondsGranularity" value =" 0x03" />
26
+ <item name =" MicrosecondsGranularity" value =" 0x04" />
27
+ </enum >
28
+
29
+ <enum name =" TimeSourceEnum" type =" ENUM8" >
30
+ <cluster code =" 0x0038" />
31
+ <item name =" None" value =" 0x00" />
32
+ <item name =" Unknown" value =" 0x01" />
33
+ <item name =" Admin" value =" 0x02" />
34
+ <item name =" NodeTimeCluster" value =" 0x03" />
35
+ <item name =" NonFabricSntp" value =" 0x04" />
36
+ <item name =" NonFabricNtp" value =" 0x05" />
37
+ <item name =" FabricSntp" value =" 0x06" />
38
+ <item name =" FabricNtp" value =" 0x07" />
39
+ <item name =" MixedNtp" value =" 0x08" />
40
+ <item name =" NonFabricSntpNts" value =" 0x09" />
41
+ <item name =" NonFabricNtpNts" value =" 0x0A" />
42
+ <item name =" FabricSntpNts" value =" 0x0B" />
43
+ <item name =" FabricNtpNts" value =" 0x0C" />
44
+ <item name =" MixedNtpNts" value =" 0x0D" />
45
+ <item name =" CloudSource" value =" 0x0E" />
46
+ <item name =" Ptp" value =" 0x0F" />
47
+ <item name =" Gnss" value =" 0x10" />
48
+ </enum >
49
+
50
+ <struct name =" TimeZoneType" >
51
+ <cluster code =" 0x0038" />
52
+ <item fieldId =" 0" name =" Offset" type =" INT32S" />
53
+ <item fieldId =" 1" name =" ValidAt" type =" epoch_us" />
54
+ <item fieldId =" 2" name =" Name" type =" CHAR_STRING" length =" 64" optional =" true" />
55
+ </struct >
56
+
57
+ <struct name =" DstOffsetType" >
58
+ <cluster code =" 0x0038" />
59
+ <item fieldId =" 0" name =" Offset" type =" INT32S" />
60
+ <item fieldId =" 1" name =" ValidStarting" type =" epoch_us" />
61
+ <item fieldId =" 2" name =" ValidUntil" type =" epoch_us" />
62
+ </struct >
20
63
21
64
<cluster >
22
65
<domain >General</domain >
@@ -28,8 +71,39 @@ limitations under the License.
28
71
<description >Accurate time is required for a number of reasons, including scheduling, display and validating
29
72
security materials.</description >
30
73
<!-- Base data types -->
74
+ <attribute side =" server" code =" 0x0000" define =" UTC_TIME" type =" epoch_us" isNullable =" true" optional =" false" >UTCTime</attribute >
75
+ <attribute side =" server" code =" 0x0001" define =" GRANULARITY" type =" GranularityEnum" default =" 0x00" optional =" false" >Granularity</attribute >
76
+ <attribute side =" server" code =" 0x0002" define =" TIME_SOURCE" type =" TimeSourceEnum" default =" 0x00" optional =" true" >TimeSource</attribute >
77
+ <attribute side =" server" code =" 0x0003" define =" TRUSTED_TIME_NODE_ID" type =" node_id" writable =" true" isNullable =" true" optional =" false" >
78
+ <description >TrustedTimeNodeId</description >
79
+ <access op =" read" privilege =" view" />
80
+ <access op =" write" privilege =" administer" />
81
+ </attribute >
82
+ <attribute side =" server" code =" 0x0004" define =" DEFAULT_NTP" type =" CHAR_STRING" length =" 128" writable =" true" isNullable =" true" optional =" true" >
83
+ <description >DefaultNtp</description >
84
+ <access op =" read" privilege =" view" />
85
+ <access op =" write" privilege =" administer" />
86
+ </attribute >
87
+ <attribute side =" server" code =" 0x0005" define =" TIME_ZONE" type =" ARRAY" entryType =" TimeZoneType" min =" 1" max =" 2" writable =" true" optional =" true" >
88
+ <description >TimeZone</description >
89
+ <access op =" read" privilege =" view" />
90
+ <access op =" write" privilege =" manage" />
91
+ </attribute >
92
+ <attribute side =" server" code =" 0x0006" define =" DST_OFFSET" type =" ARRAY" entryType =" DstOffsetType" max =" 20" writable =" true" optional =" true" >
93
+ <description >DstOffset</description >
94
+ <access op =" read" privilege =" view" />
95
+ <access op =" write" privilege =" manage" />
96
+ </attribute >
97
+ <attribute side =" server" code =" 0x0007" define =" LOCAL_TIME" type =" epoch_us" default =" 0x00" isNullable =" true" optional =" true" >LocalTime</attribute >
98
+ <attribute side =" server" code =" 0x0008" define =" TIME_ZONE_DATABASE" type =" boolean" default =" 0" optional =" true" >TimeZoneDatabase</attribute >
99
+ <attribute side =" server" code =" 0x0009" define =" NTP_SERVER_PORT" type =" INT16U" isNullable =" true" optional =" true" >NtpServerPort</attribute >
31
100
32
101
<!-- Test Commands -->
33
-
102
+ <command source =" client" code =" 0x00" name =" SetUtcTime" optional =" false" >
103
+ <description >Upon receipt of this command, the server MAY update its UTCTime Attribute to match the time specified in the command</description >
104
+ <arg name =" UtcTime" type =" epoch_us" />
105
+ <arg name =" Granularity" type =" GranularityEnum" />
106
+ <arg name =" TimeSource" type =" TimeSourceEnum" optional =" true" />
107
+ </command >
34
108
</cluster >
35
109
</configurator >
0 commit comments