diff --git a/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter b/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter index d39ad6fc0abb11..d1db961895a078 100644 --- a/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter +++ b/examples/all-clusters-app/all-clusters-common/all-clusters-app.matter @@ -963,6 +963,12 @@ server cluster DoorLock = 257 { kForcedDoorOpenUnderDoorLockedCondition = 0x40; } + bitmap DlCredentialRuleMask : BITMAP8 { + kSingle = 0x1; + kDual = 0x2; + kTri = 0x4; + } + bitmap DlCredentialRulesSupport : BITMAP8 { kSingle = 0x1; kDual = 0x2; @@ -1154,13 +1160,13 @@ server cluster DoorLock = 257 { readonly attribute int8u minPINCodeLength = 24; readonly attribute int8u maxRFIDCodeLength = 25; readonly attribute int8u minRFIDCodeLength = 26; - readonly attribute bitmap8 credentialRulesSupport = 27; + readonly attribute DlCredentialRuleMask credentialRulesSupport = 27; attribute char_string<3> language = 33; attribute int32u autoRelockTime = 35; attribute int8u soundVolume = 36; attribute DlOperatingMode operatingMode = 37; - readonly attribute bitmap16 supportedOperatingModes = 38; - readonly attribute bitmap16 defaultConfigurationRegister = 39; + readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38; + readonly attribute DlDefaultConfigurationRegister defaultConfigurationRegister = 39; attribute boolean enableOneTouchLocking = 41; attribute boolean enableInsideStatusLED = 42; attribute boolean enablePrivacyModeButton = 43; diff --git a/examples/door-lock-app/door-lock-common/door-lock-app.matter b/examples/door-lock-app/door-lock-common/door-lock-app.matter index cd3a9880e1b3cb..e3b1801ed4055f 100644 --- a/examples/door-lock-app/door-lock-common/door-lock-app.matter +++ b/examples/door-lock-app/door-lock-common/door-lock-app.matter @@ -382,6 +382,12 @@ server cluster DoorLock = 257 { kForcedDoorOpenUnderDoorLockedCondition = 0x40; } + bitmap DlCredentialRuleMask : BITMAP8 { + kSingle = 0x1; + kDual = 0x2; + kTri = 0x4; + } + bitmap DlCredentialRulesSupport : BITMAP8 { kSingle = 0x1; kDual = 0x2; @@ -569,12 +575,12 @@ server cluster DoorLock = 257 { readonly attribute int8u minPINCodeLength = 24; readonly attribute int8u maxRFIDCodeLength = 25; readonly attribute int8u minRFIDCodeLength = 26; - readonly attribute bitmap8 credentialRulesSupport = 27; + readonly attribute DlCredentialRuleMask credentialRulesSupport = 27; attribute char_string<3> language = 33; attribute int32u autoRelockTime = 35; attribute int8u soundVolume = 36; attribute DlOperatingMode operatingMode = 37; - readonly attribute bitmap16 supportedOperatingModes = 38; + readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38; attribute boolean enableOneTouchLocking = 41; attribute boolean enablePrivacyModeButton = 43; attribute int8u wrongCodeEntryLimit = 48; diff --git a/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter b/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter index 9dc39d2c85a8b0..95bfda66b02b6b 100644 --- a/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter +++ b/examples/tv-casting-app/tv-casting-common/tv-casting-app.matter @@ -922,6 +922,12 @@ server cluster DoorLock = 257 { kForcedDoorOpenUnderDoorLockedCondition = 0x40; } + bitmap DlCredentialRuleMask : BITMAP8 { + kSingle = 0x1; + kDual = 0x2; + kTri = 0x4; + } + bitmap DlCredentialRulesSupport : BITMAP8 { kSingle = 0x1; kDual = 0x2; @@ -1110,13 +1116,13 @@ server cluster DoorLock = 257 { readonly attribute int8u numberOfHolidaySchedulesSupported = 22; readonly attribute int8u maxPINCodeLength = 23; readonly attribute int8u minPINCodeLength = 24; - readonly attribute bitmap8 credentialRulesSupport = 27; + readonly attribute DlCredentialRuleMask credentialRulesSupport = 27; attribute char_string<3> language = 33; attribute int32u autoRelockTime = 35; attribute int8u soundVolume = 36; attribute DlOperatingMode operatingMode = 37; - readonly attribute bitmap16 supportedOperatingModes = 38; - readonly attribute bitmap16 defaultConfigurationRegister = 39; + readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38; + readonly attribute DlDefaultConfigurationRegister defaultConfigurationRegister = 39; attribute boolean enableOneTouchLocking = 41; attribute boolean enableInsideStatusLED = 42; attribute boolean enablePrivacyModeButton = 43; diff --git a/src/app/zap-templates/zcl/data-model/chip/door-lock-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/door-lock-cluster.xml index 0af50b69c7be7f..bd05cae4f1e937 100644 --- a/src/app/zap-templates/zcl/data-model/chip/door-lock-cluster.xml +++ b/src/app/zap-templates/zcl/data-model/chip/door-lock-cluster.xml @@ -109,7 +109,7 @@ limitations under the License. MinRFIDCodeLength - CredentialRulesSupport + CredentialRulesSupport EnableLogging @@ -141,8 +141,8 @@ limitations under the License. - SupportedOperatingModes - DefaultConfigurationRegister + SupportedOperatingModes + DefaultConfigurationRegister EnableLocalProgramming @@ -163,7 +163,7 @@ limitations under the License. - + LocalProgrammingFeatures @@ -199,49 +199,49 @@ limitations under the License. - + AlarmMask - + KeypadOperationEventMask - + RemoteOperationEventMask - + ManualOperationEventMask - + RFIDOperationEventMask - + KeypadProgrammingEventMask - + RemoteProgrammingEventMask - + RFIDProgrammingEventMask @@ -663,6 +663,13 @@ limitations under the License. + + + + + + + @@ -882,7 +889,7 @@ limitations under the License. - + diff --git a/src/controller/data_model/controller-clusters.matter b/src/controller/data_model/controller-clusters.matter index 0ba1b9da8ad16f..f45c0e17f0d0fd 100644 --- a/src/controller/data_model/controller-clusters.matter +++ b/src/controller/data_model/controller-clusters.matter @@ -1249,6 +1249,12 @@ client cluster DoorLock = 257 { kForcedDoorOpenUnderDoorLockedCondition = 0x40; } + bitmap DlCredentialRuleMask : BITMAP8 { + kSingle = 0x1; + kDual = 0x2; + kTri = 0x4; + } + bitmap DlCredentialRulesSupport : BITMAP8 { kSingle = 0x1; kDual = 0x2; @@ -1440,7 +1446,7 @@ client cluster DoorLock = 257 { attribute int32u autoRelockTime = 35; attribute int8u soundVolume = 36; attribute DlOperatingMode operatingMode = 37; - readonly attribute bitmap16 supportedOperatingModes = 38; + readonly attribute DlSupportedOperatingModes supportedOperatingModes = 38; attribute boolean enableOneTouchLocking = 41; attribute boolean enablePrivacyModeButton = 43; attribute int8u wrongCodeEntryLimit = 48; diff --git a/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp b/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp index 0f1188b2e1d185..5a9a0ba4d8ebbc 100644 --- a/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp +++ b/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp @@ -4631,7 +4631,7 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR std::string valueClassName = "java/lang/Integer"; std::string valueCtorSignature = "(I)V"; chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(), - cppValue, value); + cppValue.Raw(), value); return value; } case Attributes::EnableOneTouchLocking::Id: { diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPAttributeTLVValueDecoder.mm b/src/darwin/Framework/CHIP/zap-generated/CHIPAttributeTLVValueDecoder.mm index 5330268f99c07d..e597ef73fa9ef4 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPAttributeTLVValueDecoder.mm +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPAttributeTLVValueDecoder.mm @@ -3776,7 +3776,7 @@ id CHIPDecodeAttributeValue(const ConcreteAttributePath & aPath, TLV::TLVReader return nil; } NSNumber * _Nonnull value; - value = [NSNumber numberWithUnsignedShort:cppValue]; + value = [NSNumber numberWithUnsignedShort:cppValue.Raw()]; return value; } case Attributes::EnableOneTouchLocking::Id: { diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPCallbackBridge.mm b/src/darwin/Framework/CHIP/zap-generated/CHIPCallbackBridge.mm index c16fbfaf47b22c..aa1763580925de 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPCallbackBridge.mm +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPCallbackBridge.mm @@ -3702,6 +3702,30 @@ } } +void CHIPDoorLockSupportedOperatingModesAttributeCallbackBridge::OnSuccessFn( + void * context, chip::BitFlags value) +{ + NSNumber * _Nonnull objCValue; + objCValue = [NSNumber numberWithUnsignedShort:value.Raw()]; + DispatchSuccess(context, objCValue); +}; + +void CHIPDoorLockSupportedOperatingModesAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished(void * context) +{ + auto * self = static_cast(context); + if (!self->mQueue) { + return; + } + + if (self->mEstablishedHandler != nil) { + dispatch_async(self->mQueue, self->mEstablishedHandler); + // On failure, mEstablishedHandler will be cleaned up by our destructor, + // but we can clean it up earlier on successful subscription + // establishment. + self->mEstablishedHandler = nil; + } +} + void CHIPDoorLockServerGeneratedCommandListListAttributeCallbackBridge::OnSuccessFn( void * context, const chip::app::DataModel::DecodableList & value) { diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPCallbackBridge_internal.h b/src/darwin/Framework/CHIP/zap-generated/CHIPCallbackBridge_internal.h index 0a9748496d1942..3b13366ce5ef45 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPCallbackBridge_internal.h +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPCallbackBridge_internal.h @@ -564,6 +564,8 @@ typedef void (*ChannelLineupStructAttributeCallback)( void *, const chip::app::DataModel::Nullable &); typedef void (*ChannelCurrentChannelStructAttributeCallback)( void *, const chip::app::DataModel::Nullable &); +typedef void (*DoorLockSupportedOperatingModesAttributeCallback)( + void *, chip::BitFlags); typedef void (*GeneralCommissioningBasicCommissioningInfoStructAttributeCallback)( void *, const chip::app::Clusters::GeneralCommissioning::Structs::BasicCommissioningInfo::DecodableType &); typedef void (*MediaPlaybackSampledPositionStructAttributeCallback)( @@ -3367,6 +3369,34 @@ class CHIPDiagnosticLogsAttributeListListAttributeCallbackSubscriptionBridge SubscriptionEstablishedHandler mEstablishedHandler; }; +class CHIPDoorLockSupportedOperatingModesAttributeCallbackBridge + : public CHIPCallbackBridge +{ +public: + CHIPDoorLockSupportedOperatingModesAttributeCallbackBridge(dispatch_queue_t queue, ResponseHandler handler, + CHIPActionBlock action, bool keepAlive = false) : + CHIPCallbackBridge(queue, handler, action, OnSuccessFn, keepAlive){}; + + static void OnSuccessFn(void * context, chip::BitFlags value); +}; + +class CHIPDoorLockSupportedOperatingModesAttributeCallbackSubscriptionBridge + : public CHIPDoorLockSupportedOperatingModesAttributeCallbackBridge +{ +public: + CHIPDoorLockSupportedOperatingModesAttributeCallbackSubscriptionBridge(dispatch_queue_t queue, ResponseHandler handler, + CHIPActionBlock action, + SubscriptionEstablishedHandler establishedHandler) : + CHIPDoorLockSupportedOperatingModesAttributeCallbackBridge(queue, handler, action, true), + mEstablishedHandler(establishedHandler) + {} + + static void OnSubscriptionEstablished(void * context); + +private: + SubscriptionEstablishedHandler mEstablishedHandler; +}; + class CHIPDoorLockServerGeneratedCommandListListAttributeCallbackBridge : public CHIPCallbackBridge { diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.h b/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.h index d87818164bc742..825eafe5bf6fb2 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.h +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.h @@ -15575,6 +15575,12 @@ typedef NS_OPTIONS(NSUInteger, CHIPDoorLockDlAlarmMask) { CHIPDoorLockDlAlarmMaskForcedDoorOpenUnderDoorLockedCondition = 0x40, }; +typedef NS_OPTIONS(NSUInteger, CHIPDoorLockDlCredentialRuleMask) { + CHIPDoorLockDlCredentialRuleMaskSingle = 0x1, + CHIPDoorLockDlCredentialRuleMaskDual = 0x2, + CHIPDoorLockDlCredentialRuleMaskTri = 0x4, +}; + typedef NS_OPTIONS(NSUInteger, CHIPDoorLockDlCredentialRulesSupport) { CHIPDoorLockDlCredentialRulesSupportSingle = 0x1, CHIPDoorLockDlCredentialRulesSupportDual = 0x2, diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm b/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm index 508267c609f8c8..2347d7ff02d45b 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPClustersObjc.mm @@ -15672,12 +15672,13 @@ new CHIPDoorLockClusterDlOperatingModeAttributeCallbackBridge( - (void)readAttributeSupportedOperatingModesWithCompletionHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - using TypeInfo = DoorLock::Attributes::SupportedOperatingModes::TypeInfo; - auto successFn = Callback::FromCancelable(success); - auto failureFn = Callback::FromCancelable(failure); - return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); - }); + new CHIPDoorLockSupportedOperatingModesAttributeCallbackBridge( + self.callbackQueue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + using TypeInfo = DoorLock::Attributes::SupportedOperatingModes::TypeInfo; + auto successFn = Callback::FromCancelable(success); + auto failureFn = Callback::FromCancelable(failure); + return self.cppCluster.ReadAttribute(successFn->mContext, successFn->mCall, failureFn->mCall); + }); } - (void)subscribeAttributeSupportedOperatingModesWithMinInterval:(NSNumber * _Nonnull)minInterval @@ -15688,7 +15689,7 @@ - (void)subscribeAttributeSupportedOperatingModesWithMinInterval:(NSNumber * _No reportHandler:(void (^)(NSNumber * _Nullable value, NSError * _Nullable error))reportHandler { - new CHIPInt16uAttributeCallbackSubscriptionBridge( + new CHIPDoorLockSupportedOperatingModesAttributeCallbackSubscriptionBridge( self.callbackQueue, reportHandler, ^(Cancelable * success, Cancelable * failure) { if (params != nil && params.autoResubscribe != nil && ![params.autoResubscribe boolValue]) { @@ -15696,11 +15697,11 @@ new CHIPInt16uAttributeCallbackSubscriptionBridge( return CHIP_ERROR_INVALID_ARGUMENT; } using TypeInfo = DoorLock::Attributes::SupportedOperatingModes::TypeInfo; - auto successFn = Callback::FromCancelable(success); + auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.SubscribeAttribute(successFn->mContext, successFn->mCall, failureFn->mCall, [minInterval unsignedShortValue], [maxInterval unsignedShortValue], - CHIPInt16uAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, + CHIPDoorLockSupportedOperatingModesAttributeCallbackSubscriptionBridge::OnSubscriptionEstablished, params == nil || params.fabricFiltered == nil || [params.fabricFiltered boolValue], params != nil && params.keepPreviousSubscriptions != nil && [params.keepPreviousSubscriptions boolValue]); }, @@ -15713,23 +15714,24 @@ + (void)readAttributeSupportedOperatingModesWithAttributeCache:(CHIPAttributeCac completionHandler: (void (^)(NSNumber * _Nullable value, NSError * _Nullable error))completionHandler { - new CHIPInt16uAttributeCallbackBridge(queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { - if (attributeCacheContainer.cppAttributeCache) { - chip::app::ConcreteAttributePath path; - using TypeInfo = DoorLock::Attributes::SupportedOperatingModes::TypeInfo; - path.mEndpointId = static_cast([endpoint unsignedShortValue]); - path.mClusterId = TypeInfo::GetClusterId(); - path.mAttributeId = TypeInfo::GetAttributeId(); - TypeInfo::DecodableType value; - CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); - auto successFn = Callback::FromCancelable(success); - if (err == CHIP_NO_ERROR) { - successFn->mCall(successFn->mContext, value); + new CHIPDoorLockSupportedOperatingModesAttributeCallbackBridge( + queue, completionHandler, ^(Cancelable * success, Cancelable * failure) { + if (attributeCacheContainer.cppAttributeCache) { + chip::app::ConcreteAttributePath path; + using TypeInfo = DoorLock::Attributes::SupportedOperatingModes::TypeInfo; + path.mEndpointId = static_cast([endpoint unsignedShortValue]); + path.mClusterId = TypeInfo::GetClusterId(); + path.mAttributeId = TypeInfo::GetAttributeId(); + TypeInfo::DecodableType value; + CHIP_ERROR err = attributeCacheContainer.cppAttributeCache->Get(path, value); + auto successFn = Callback::FromCancelable(success); + if (err == CHIP_NO_ERROR) { + successFn->mCall(successFn->mContext, value); + } + return err; } - return err; - } - return CHIP_ERROR_NOT_FOUND; - }); + return CHIP_ERROR_NOT_FOUND; + }); } - (void)readAttributeEnableOneTouchLockingWithCompletionHandler:(void (^)(NSNumber * _Nullable value, diff --git a/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.mm b/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.mm index 73e16e163c828f..38a0b370fcf076 100644 --- a/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.mm +++ b/src/darwin/Framework/CHIP/zap-generated/CHIPTestClustersObjc.mm @@ -5117,7 +5117,7 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = DoorLock::Attributes::SupportedOperatingModes::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + cppValue = static_cast>(value.unsignedShortValue); auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); diff --git a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp index 014cec69b4c5b3..715630b90fea87 100644 --- a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp +++ b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.cpp @@ -14271,9 +14271,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value) namespace CredentialRulesSupport { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -14285,9 +14285,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -14487,9 +14487,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, chip::app::Clusters::DoorLock::DlOp namespace SupportedOperatingModes { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -14501,9 +14501,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -14518,9 +14518,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) namespace DefaultConfigurationRegister { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -14532,9 +14532,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -14673,9 +14673,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, bool value) namespace LocalProgrammingFeatures { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -14687,9 +14687,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -14859,9 +14859,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) namespace AlarmMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -14873,9 +14873,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -14890,9 +14890,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) namespace KeypadOperationEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -14904,9 +14904,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -14921,9 +14921,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) namespace RemoteOperationEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -14935,9 +14935,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -14952,9 +14952,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) namespace ManualOperationEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -14966,9 +14966,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -14983,9 +14983,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) namespace RFIDOperationEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -14997,9 +14997,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -15014,9 +15014,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) namespace KeypadProgrammingEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -15028,9 +15028,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -15045,9 +15045,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) namespace RemoteProgrammingEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -15059,9 +15059,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; @@ -15076,9 +15076,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) namespace RFIDProgrammingEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; Traits::StorageType temp; uint8_t * readable = Traits::ToAttributeStoreRepresentation(temp); EmberAfStatus status = emberAfReadServerAttribute(endpoint, Clusters::DoorLock::Id, Id, readable, sizeof(temp)); @@ -15090,9 +15090,9 @@ EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value) *value = Traits::StorageToWorking(temp); return status; } -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value) +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value) { - using Traits = NumericAttributeTraits; + using Traits = NumericAttributeTraits>; if (!Traits::CanRepresentValue(/* isNullable = */ false, value)) { return EMBER_ZCL_STATUS_CONSTRAINT_ERROR; diff --git a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h index 7928ae7778d7b5..8c36603379e522 100644 --- a/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h +++ b/zzz_generated/app-common/app-common/zap-generated/attributes/Accessors.h @@ -2561,8 +2561,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value); } // namespace MinRFIDCodeLength namespace CredentialRulesSupport { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value); // bitmap8 -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlCredentialRuleMask +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace CredentialRulesSupport namespace EnableLogging { @@ -2596,13 +2597,16 @@ EmberAfStatus Set(chip::EndpointId endpoint, chip::app::Clusters::DoorLock::DlOp } // namespace OperatingMode namespace SupportedOperatingModes { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // bitmap16 -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlSupportedOperatingModes +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace SupportedOperatingModes namespace DefaultConfigurationRegister { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // bitmap16 -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus +Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlDefaultConfigurationRegister +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace DefaultConfigurationRegister namespace EnableLocalProgramming { @@ -2626,8 +2630,9 @@ EmberAfStatus Set(chip::EndpointId endpoint, bool value); } // namespace EnablePrivacyModeButton namespace LocalProgrammingFeatures { -EmberAfStatus Get(chip::EndpointId endpoint, uint8_t * value); // bitmap8 -EmberAfStatus Set(chip::EndpointId endpoint, uint8_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlLocalProgrammingFeatures +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace LocalProgrammingFeatures namespace WrongCodeEntryLimit { @@ -2656,43 +2661,51 @@ EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); } // namespace ExpiringUserTimeout namespace AlarmMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // bitmap16 -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus Get(chip::EndpointId endpoint, chip::BitFlags * value); // DlAlarmMask +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace AlarmMask namespace KeypadOperationEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // bitmap16 -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlKeypadOperationEventMask +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace KeypadOperationEventMask namespace RemoteOperationEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // bitmap16 -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlRemoteOperationEventMask +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace RemoteOperationEventMask namespace ManualOperationEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // bitmap16 -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlManualOperationEventMask +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace ManualOperationEventMask namespace RFIDOperationEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // bitmap16 -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlRFIDOperationEventMask +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace RFIDOperationEventMask namespace KeypadProgrammingEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // bitmap16 -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlKeypadOperationEventMask +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace KeypadProgrammingEventMask namespace RemoteProgrammingEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // bitmap16 -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus +Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlRemoteProgrammingEventMask +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace RemoteProgrammingEventMask namespace RFIDProgrammingEventMask { -EmberAfStatus Get(chip::EndpointId endpoint, uint16_t * value); // bitmap16 -EmberAfStatus Set(chip::EndpointId endpoint, uint16_t value); +EmberAfStatus Get(chip::EndpointId endpoint, + chip::BitFlags * value); // DlRFIDProgrammingEventMask +EmberAfStatus Set(chip::EndpointId endpoint, chip::BitFlags value); } // namespace RFIDProgrammingEventMask namespace FeatureMap { diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h b/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h index 2471223302da32..d3207eef9140c3 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-enums.h @@ -1188,6 +1188,14 @@ enum class DlAlarmMask : uint16_t kForcedDoorOpenUnderDoorLockedCondition = 0x40, }; +// Bitmap for DlCredentialRuleMask +enum class DlCredentialRuleMask : uint8_t +{ + kSingle = 0x1, + kDual = 0x2, + kTri = 0x4, +}; + // Bitmap for DlCredentialRulesSupport enum class DlCredentialRulesSupport : uint8_t { diff --git a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h index 0dd2d68e998832..7e0f841c37c3bb 100644 --- a/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h +++ b/zzz_generated/app-common/app-common/zap-generated/cluster-objects.h @@ -19397,9 +19397,9 @@ struct TypeInfo namespace CredentialRulesSupport { struct TypeInfo { - using Type = uint8_t; - using DecodableType = uint8_t; - using DecodableArgType = uint8_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::CredentialRulesSupport::Id; } @@ -19482,9 +19482,9 @@ struct TypeInfo namespace SupportedOperatingModes { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::SupportedOperatingModes::Id; } @@ -19494,9 +19494,9 @@ struct TypeInfo namespace DefaultConfigurationRegister { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::DefaultConfigurationRegister::Id; } @@ -19554,9 +19554,9 @@ struct TypeInfo namespace LocalProgrammingFeatures { struct TypeInfo { - using Type = uint8_t; - using DecodableType = uint8_t; - using DecodableArgType = uint8_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::LocalProgrammingFeatures::Id; } @@ -19626,9 +19626,9 @@ struct TypeInfo namespace AlarmMask { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::AlarmMask::Id; } @@ -19638,9 +19638,9 @@ struct TypeInfo namespace KeypadOperationEventMask { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::KeypadOperationEventMask::Id; } @@ -19650,9 +19650,9 @@ struct TypeInfo namespace RemoteOperationEventMask { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::RemoteOperationEventMask::Id; } @@ -19662,9 +19662,9 @@ struct TypeInfo namespace ManualOperationEventMask { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::ManualOperationEventMask::Id; } @@ -19674,9 +19674,9 @@ struct TypeInfo namespace RFIDOperationEventMask { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::RFIDOperationEventMask::Id; } @@ -19686,9 +19686,9 @@ struct TypeInfo namespace KeypadProgrammingEventMask { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::KeypadProgrammingEventMask::Id; } @@ -19698,9 +19698,9 @@ struct TypeInfo namespace RemoteProgrammingEventMask { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::RemoteProgrammingEventMask::Id; } @@ -19710,9 +19710,9 @@ struct TypeInfo namespace RFIDProgrammingEventMask { struct TypeInfo { - using Type = uint16_t; - using DecodableType = uint16_t; - using DecodableArgType = uint16_t; + using Type = chip::BitFlags; + using DecodableType = chip::BitFlags; + using DecodableArgType = chip::BitFlags; static constexpr ClusterId GetClusterId() { return Clusters::DoorLock::Id; } static constexpr AttributeId GetAttributeId() { return Attributes::RFIDProgrammingEventMask::Id; } @@ -19805,38 +19805,50 @@ struct TypeInfo static_cast(0); Attributes::NumberOfHolidaySchedulesSupported::TypeInfo::DecodableType numberOfHolidaySchedulesSupported = static_cast(0); - Attributes::MaxPINCodeLength::TypeInfo::DecodableType maxPINCodeLength = static_cast(0); - Attributes::MinPINCodeLength::TypeInfo::DecodableType minPINCodeLength = static_cast(0); - Attributes::MaxRFIDCodeLength::TypeInfo::DecodableType maxRFIDCodeLength = static_cast(0); - Attributes::MinRFIDCodeLength::TypeInfo::DecodableType minRFIDCodeLength = static_cast(0); - Attributes::CredentialRulesSupport::TypeInfo::DecodableType credentialRulesSupport = static_cast(0); - Attributes::EnableLogging::TypeInfo::DecodableType enableLogging = static_cast(0); + Attributes::MaxPINCodeLength::TypeInfo::DecodableType maxPINCodeLength = static_cast(0); + Attributes::MinPINCodeLength::TypeInfo::DecodableType minPINCodeLength = static_cast(0); + Attributes::MaxRFIDCodeLength::TypeInfo::DecodableType maxRFIDCodeLength = static_cast(0); + Attributes::MinRFIDCodeLength::TypeInfo::DecodableType minRFIDCodeLength = static_cast(0); + Attributes::CredentialRulesSupport::TypeInfo::DecodableType credentialRulesSupport = + static_cast>(0); + Attributes::EnableLogging::TypeInfo::DecodableType enableLogging = static_cast(0); Attributes::Language::TypeInfo::DecodableType language; Attributes::LEDSettings::TypeInfo::DecodableType LEDSettings = static_cast(0); Attributes::AutoRelockTime::TypeInfo::DecodableType autoRelockTime = static_cast(0); Attributes::SoundVolume::TypeInfo::DecodableType soundVolume = static_cast(0); Attributes::OperatingMode::TypeInfo::DecodableType operatingMode = static_cast(0); - Attributes::SupportedOperatingModes::TypeInfo::DecodableType supportedOperatingModes = static_cast(0); - Attributes::DefaultConfigurationRegister::TypeInfo::DecodableType defaultConfigurationRegister = static_cast(0); - Attributes::EnableLocalProgramming::TypeInfo::DecodableType enableLocalProgramming = static_cast(0); - Attributes::EnableOneTouchLocking::TypeInfo::DecodableType enableOneTouchLocking = static_cast(0); - Attributes::EnableInsideStatusLED::TypeInfo::DecodableType enableInsideStatusLED = static_cast(0); - Attributes::EnablePrivacyModeButton::TypeInfo::DecodableType enablePrivacyModeButton = static_cast(0); - Attributes::LocalProgrammingFeatures::TypeInfo::DecodableType localProgrammingFeatures = static_cast(0); + Attributes::SupportedOperatingModes::TypeInfo::DecodableType supportedOperatingModes = + static_cast>(0); + Attributes::DefaultConfigurationRegister::TypeInfo::DecodableType defaultConfigurationRegister = + static_cast>(0); + Attributes::EnableLocalProgramming::TypeInfo::DecodableType enableLocalProgramming = static_cast(0); + Attributes::EnableOneTouchLocking::TypeInfo::DecodableType enableOneTouchLocking = static_cast(0); + Attributes::EnableInsideStatusLED::TypeInfo::DecodableType enableInsideStatusLED = static_cast(0); + Attributes::EnablePrivacyModeButton::TypeInfo::DecodableType enablePrivacyModeButton = static_cast(0); + Attributes::LocalProgrammingFeatures::TypeInfo::DecodableType localProgrammingFeatures = + static_cast>(0); Attributes::WrongCodeEntryLimit::TypeInfo::DecodableType wrongCodeEntryLimit = static_cast(0); Attributes::UserCodeTemporaryDisableTime::TypeInfo::DecodableType userCodeTemporaryDisableTime = static_cast(0); Attributes::SendPINOverTheAir::TypeInfo::DecodableType sendPINOverTheAir = static_cast(0); Attributes::RequirePINforRemoteOperation::TypeInfo::DecodableType requirePINforRemoteOperation = static_cast(0); Attributes::ExpiringUserTimeout::TypeInfo::DecodableType expiringUserTimeout = static_cast(0); - Attributes::AlarmMask::TypeInfo::DecodableType alarmMask = static_cast(0); - Attributes::KeypadOperationEventMask::TypeInfo::DecodableType keypadOperationEventMask = static_cast(0); - Attributes::RemoteOperationEventMask::TypeInfo::DecodableType remoteOperationEventMask = static_cast(0); - Attributes::ManualOperationEventMask::TypeInfo::DecodableType manualOperationEventMask = static_cast(0); - Attributes::RFIDOperationEventMask::TypeInfo::DecodableType RFIDOperationEventMask = static_cast(0); - Attributes::KeypadProgrammingEventMask::TypeInfo::DecodableType keypadProgrammingEventMask = static_cast(0); - Attributes::RemoteProgrammingEventMask::TypeInfo::DecodableType remoteProgrammingEventMask = static_cast(0); - Attributes::RFIDProgrammingEventMask::TypeInfo::DecodableType RFIDProgrammingEventMask = static_cast(0); + Attributes::AlarmMask::TypeInfo::DecodableType alarmMask = + static_cast>(0); + Attributes::KeypadOperationEventMask::TypeInfo::DecodableType keypadOperationEventMask = + static_cast>(0); + Attributes::RemoteOperationEventMask::TypeInfo::DecodableType remoteOperationEventMask = + static_cast>(0); + Attributes::ManualOperationEventMask::TypeInfo::DecodableType manualOperationEventMask = + static_cast>(0); + Attributes::RFIDOperationEventMask::TypeInfo::DecodableType RFIDOperationEventMask = + static_cast>(0); + Attributes::KeypadProgrammingEventMask::TypeInfo::DecodableType keypadProgrammingEventMask = + static_cast>(0); + Attributes::RemoteProgrammingEventMask::TypeInfo::DecodableType remoteProgrammingEventMask = + static_cast>(0); + Attributes::RFIDProgrammingEventMask::TypeInfo::DecodableType RFIDProgrammingEventMask = + static_cast>(0); Attributes::ServerGeneratedCommandList::TypeInfo::DecodableType serverGeneratedCommandList; Attributes::ClientGeneratedCommandList::TypeInfo::DecodableType clientGeneratedCommandList; Attributes::AttributeList::TypeInfo::DecodableType attributeList; diff --git a/zzz_generated/app-common/app-common/zap-generated/enums.h b/zzz_generated/app-common/app-common/zap-generated/enums.h index 5a0bdf956c7cef..1fada60b916043 100644 --- a/zzz_generated/app-common/app-common/zap-generated/enums.h +++ b/zzz_generated/app-common/app-common/zap-generated/enums.h @@ -583,6 +583,12 @@ enum EmberAfWiFiVersionType : uint8_t #define EMBER_AF_DL_ALARM_MASK_FRONT_ESCUTCHEON_REMOVED_FROM_MAIN_OFFSET (5) #define EMBER_AF_DL_ALARM_MASK_FORCED_DOOR_OPEN_UNDER_DOOR_LOCKED_CONDITION (64) #define EMBER_AF_DL_ALARM_MASK_FORCED_DOOR_OPEN_UNDER_DOOR_LOCKED_CONDITION_OFFSET (6) +#define EMBER_AF_DL_CREDENTIAL_RULE_MASK_SINGLE (1) +#define EMBER_AF_DL_CREDENTIAL_RULE_MASK_SINGLE_OFFSET (0) +#define EMBER_AF_DL_CREDENTIAL_RULE_MASK_DUAL (2) +#define EMBER_AF_DL_CREDENTIAL_RULE_MASK_DUAL_OFFSET (1) +#define EMBER_AF_DL_CREDENTIAL_RULE_MASK_TRI (4) +#define EMBER_AF_DL_CREDENTIAL_RULE_MASK_TRI_OFFSET (2) #define EMBER_AF_DL_CREDENTIAL_RULES_SUPPORT_SINGLE (1) #define EMBER_AF_DL_CREDENTIAL_RULES_SUPPORT_SINGLE_OFFSET (0) #define EMBER_AF_DL_CREDENTIAL_RULES_SUPPORT_DUAL (2) diff --git a/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.mm b/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.mm index 73e16e163c828f..38a0b370fcf076 100644 --- a/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.mm +++ b/zzz_generated/chip-tool-darwin/zap-generated/cluster/CHIPTestClustersObjc.mm @@ -5117,7 +5117,7 @@ new CHIPDefaultSuccessCallbackBridge( ListFreer listFreer; using TypeInfo = DoorLock::Attributes::SupportedOperatingModes::TypeInfo; TypeInfo::Type cppValue; - cppValue = value.unsignedShortValue; + cppValue = static_cast>(value.unsignedShortValue); auto successFn = Callback::FromCancelable(success); auto failureFn = Callback::FromCancelable(failure); return self.cppCluster.WriteAttribute(cppValue, successFn->mContext, successFn->mCall, failureFn->mCall); diff --git a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h index 6aae4c8c2579f4..921be7ceddb760 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/Commands.h +++ b/zzz_generated/chip-tool/zap-generated/cluster/Commands.h @@ -8767,7 +8767,7 @@ class WriteDoorLockLocalProgrammingFeatures : public WriteAttribute } private: - uint8_t mValue; + chip::BitFlags mValue; }; class WriteDoorLockWrongCodeEntryLimit : public WriteAttribute @@ -8928,7 +8928,7 @@ class WriteDoorLockAlarmMask : public WriteAttribute } private: - uint16_t mValue; + chip::BitFlags mValue; }; class WriteDoorLockKeypadOperationEventMask : public WriteAttribute @@ -8955,7 +8955,7 @@ class WriteDoorLockKeypadOperationEventMask : public WriteAttribute } private: - uint16_t mValue; + chip::BitFlags mValue; }; class WriteDoorLockRemoteOperationEventMask : public WriteAttribute @@ -8982,7 +8982,7 @@ class WriteDoorLockRemoteOperationEventMask : public WriteAttribute } private: - uint16_t mValue; + chip::BitFlags mValue; }; class WriteDoorLockManualOperationEventMask : public WriteAttribute @@ -9009,7 +9009,7 @@ class WriteDoorLockManualOperationEventMask : public WriteAttribute } private: - uint16_t mValue; + chip::BitFlags mValue; }; class WriteDoorLockRFIDOperationEventMask : public WriteAttribute @@ -9036,7 +9036,7 @@ class WriteDoorLockRFIDOperationEventMask : public WriteAttribute } private: - uint16_t mValue; + chip::BitFlags mValue; }; class WriteDoorLockKeypadProgrammingEventMask : public WriteAttribute @@ -9063,7 +9063,7 @@ class WriteDoorLockKeypadProgrammingEventMask : public WriteAttribute } private: - uint16_t mValue; + chip::BitFlags mValue; }; class WriteDoorLockRemoteProgrammingEventMask : public WriteAttribute @@ -9090,7 +9090,7 @@ class WriteDoorLockRemoteProgrammingEventMask : public WriteAttribute } private: - uint16_t mValue; + chip::BitFlags mValue; }; class WriteDoorLockRFIDProgrammingEventMask : public WriteAttribute @@ -9117,7 +9117,7 @@ class WriteDoorLockRFIDProgrammingEventMask : public WriteAttribute } private: - uint16_t mValue; + chip::BitFlags mValue; }; /*----------------------------------------------------------------------------*\ diff --git a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp index 0ecc381437c736..e6599f539d8f63 100644 --- a/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp +++ b/zzz_generated/chip-tool/zap-generated/cluster/logging/DataModelLogger.cpp @@ -5582,7 +5582,7 @@ CHIP_ERROR DataModelLogger::LogAttribute(const chip::app::ConcreteDataAttributeP return DataModelLogger::LogValue("MinRFIDCodeLength", 1, value); } case DoorLock::Attributes::CredentialRulesSupport::Id: { - uint8_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("CredentialRulesSupport", 1, value); } @@ -5617,12 +5617,12 @@ CHIP_ERROR DataModelLogger::LogAttribute(const chip::app::ConcreteDataAttributeP return DataModelLogger::LogValue("OperatingMode", 1, value); } case DoorLock::Attributes::SupportedOperatingModes::Id: { - uint16_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("SupportedOperatingModes", 1, value); } case DoorLock::Attributes::DefaultConfigurationRegister::Id: { - uint16_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("DefaultConfigurationRegister", 1, value); } @@ -5647,7 +5647,7 @@ CHIP_ERROR DataModelLogger::LogAttribute(const chip::app::ConcreteDataAttributeP return DataModelLogger::LogValue("EnablePrivacyModeButton", 1, value); } case DoorLock::Attributes::LocalProgrammingFeatures::Id: { - uint8_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("LocalProgrammingFeatures", 1, value); } @@ -5677,42 +5677,42 @@ CHIP_ERROR DataModelLogger::LogAttribute(const chip::app::ConcreteDataAttributeP return DataModelLogger::LogValue("ExpiringUserTimeout", 1, value); } case DoorLock::Attributes::AlarmMask::Id: { - uint16_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("AlarmMask", 1, value); } case DoorLock::Attributes::KeypadOperationEventMask::Id: { - uint16_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("KeypadOperationEventMask", 1, value); } case DoorLock::Attributes::RemoteOperationEventMask::Id: { - uint16_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("RemoteOperationEventMask", 1, value); } case DoorLock::Attributes::ManualOperationEventMask::Id: { - uint16_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("ManualOperationEventMask", 1, value); } case DoorLock::Attributes::RFIDOperationEventMask::Id: { - uint16_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("RFIDOperationEventMask", 1, value); } case DoorLock::Attributes::KeypadProgrammingEventMask::Id: { - uint16_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("KeypadProgrammingEventMask", 1, value); } case DoorLock::Attributes::RemoteProgrammingEventMask::Id: { - uint16_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("RemoteProgrammingEventMask", 1, value); } case DoorLock::Attributes::RFIDProgrammingEventMask::Id: { - uint16_t value; + chip::BitFlags value; ReturnErrorOnFailure(chip::app::DataModel::Decode(*data, value)); return DataModelLogger::LogValue("RFIDProgrammingEventMask", 1, value); }