Skip to content

Commit

Permalink
doorlock changes removed
Browse files Browse the repository at this point in the history
  • Loading branch information
Thirsrin committed Jun 25, 2024
1 parent c2dbb93 commit 0bcb940
Show file tree
Hide file tree
Showing 12 changed files with 30 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2973,7 +2973,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down
2 changes: 1 addition & 1 deletion examples/chef/devices/rootnode_doorlock_aNKYAreMXE.matter
Original file line number Diff line number Diff line change
Expand Up @@ -1878,7 +1878,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down
2 changes: 1 addition & 1 deletion examples/lock-app/lock-common/lock-app.matter
Original file line number Diff line number Diff line change
Expand Up @@ -2252,7 +2252,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down
2 changes: 1 addition & 1 deletion examples/lock-app/nxp/zap/lock-app.matter
Original file line number Diff line number Diff line change
Expand Up @@ -1504,7 +1504,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down
2 changes: 1 addition & 1 deletion examples/lock-app/qpg/zap/lock.matter
Original file line number Diff line number Diff line change
Expand Up @@ -1908,7 +1908,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down
4 changes: 2 additions & 2 deletions examples/placeholder/linux/apps/app1/config.matter
Original file line number Diff line number Diff line change
Expand Up @@ -3568,7 +3568,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down Expand Up @@ -4219,7 +4219,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down
4 changes: 2 additions & 2 deletions examples/placeholder/linux/apps/app2/config.matter
Original file line number Diff line number Diff line change
Expand Up @@ -3525,7 +3525,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down Expand Up @@ -4176,7 +4176,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2448,7 +2448,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ limitations under the License.
<access op="read" role="view" />
<access op="write" role="manage" />
</attribute>
<attribute side="server" code="35" define="AUTO_RELOCK_TIME" type="int32u" reportable="true" writable="true">
<attribute side="server" code="35" define="AUTO_RELOCK_TIME" type="int32u" reportable="true" writable="true" optional="true">
<description>AutoRelockTime</description>
<access op="read" role="view" />
<access op="write" role="manage" />
Expand Down
2 changes: 1 addition & 1 deletion src/controller/data_model/controller-clusters.matter
Original file line number Diff line number Diff line change
Expand Up @@ -5559,7 +5559,7 @@ cluster DoorLock = 257 {
readonly attribute optional int8u numberOfCredentialsSupportedPerUser = 28;
attribute access(write: manage) optional char_string<3> language = 33;
attribute access(write: manage) optional int8u LEDSettings = 34;
attribute access(write: manage) int32u autoRelockTime = 35;
attribute access(write: manage) optional int32u autoRelockTime = 35;
attribute access(write: manage) optional int8u soundVolume = 36;
attribute access(write: manage) OperatingModeEnum operatingMode = 37;
readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3647,7 +3647,7 @@ class DoorLockCluster(private val controller: MatterController, private val endp
}
}

suspend fun readAutoRelockTimeAttribute(): UInt {
suspend fun readAutoRelockTimeAttribute(): UInt? {
val ATTRIBUTE_ID: UInt = 35u

val attributePath =
Expand All @@ -3673,7 +3673,12 @@ class DoorLockCluster(private val controller: MatterController, private val endp

// Decode the TLV data into the appropriate type
val tlvReader = TlvReader(attributeData.data)
val decodedValue: UInt = tlvReader.getUInt(AnonymousTag)
val decodedValue: UInt? =
if (tlvReader.isNextTag(AnonymousTag)) {
tlvReader.getUInt(AnonymousTag)
} else {
null
}

return decodedValue
}
Expand Down Expand Up @@ -3759,9 +3764,14 @@ class DoorLockCluster(private val controller: MatterController, private val endp

// Decode the TLV data into the appropriate type
val tlvReader = TlvReader(attributeData.data)
val decodedValue: UInt = tlvReader.getUInt(AnonymousTag)
val decodedValue: UInt? =
if (tlvReader.isNextTag(AnonymousTag)) {
tlvReader.getUInt(AnonymousTag)
} else {
null
}

emit(UIntSubscriptionState.Success(decodedValue))
decodedValue?.let { emit(UIntSubscriptionState.Success(it)) }
}
SubscriptionState.SubscriptionEstablished -> {
emit(UIntSubscriptionState.SubscriptionEstablished)
Expand Down
8 changes: 4 additions & 4 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.

0 comments on commit 0bcb940

Please sign in to comment.