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 60dcee96599899..b2cd9511209687 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 @@ -2516,6 +2516,16 @@ server cluster PumpConfigurationAndControl = 512 { kLocal = 3; } + bitmap PumpFeature : BITMAP32 { + kConstantPressure = 0x1; + kCompensatedPressure = 0x2; + kConstantFlow = 0x4; + kConstantSpeed = 0x8; + kConstantTemperature = 0x10; + kAutomatic = 0x20; + kLocal = 0x40; + } + bitmap PumpStatus : BITMAP16 { kDeviceFault = 0x1; kSupplyfault = 0x2; @@ -4513,8 +4523,8 @@ endpoint 1 { ram attribute lifetimeEnergyConsumed; ram attribute operationMode; ram attribute controlMode; - ram attribute featureMap; - ram attribute clusterRevision default = 3; + ram attribute featureMap default = 0x1F; + ram attribute clusterRevision default = 4; } server cluster Thermostat { diff --git a/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap b/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap index 260eb750385755..6d5c7e8e55679b 100644 --- a/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap +++ b/examples/all-clusters-app/all-clusters-common/all-clusters-app.zap @@ -14724,7 +14724,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0", + "defaultValue": "0x1F", "reportable": 1, "minInterval": 1, "maxInterval": 65534, @@ -14740,7 +14740,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "3", + "defaultValue": "4", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter index 98845287f96850..5546326758f3da 100644 --- a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter +++ b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.matter @@ -2169,6 +2169,16 @@ server cluster PumpConfigurationAndControl = 512 { kLocal = 3; } + bitmap PumpFeature : BITMAP32 { + kConstantPressure = 0x1; + kCompensatedPressure = 0x2; + kConstantFlow = 0x4; + kConstantSpeed = 0x8; + kConstantTemperature = 0x10; + kAutomatic = 0x20; + kLocal = 0x40; + } + bitmap PumpStatus : BITMAP16 { kDeviceFault = 0x1; kSupplyfault = 0x2; @@ -2235,6 +2245,8 @@ server cluster PumpConfigurationAndControl = 512 { readonly attribute nullable int16s maxPressure = 0; readonly attribute nullable int16u maxSpeed = 1; readonly attribute nullable int16u maxFlow = 2; + readonly attribute nullable int16s minConstPressure = 3; + readonly attribute nullable int16s maxConstPressure = 4; readonly attribute PumpOperationMode effectiveOperationMode = 17; readonly attribute PumpControlMode effectiveControlMode = 18; readonly attribute nullable int16s capacity = 19; @@ -3664,12 +3676,14 @@ endpoint 1 { ram attribute maxPressure; ram attribute maxSpeed; ram attribute maxFlow; + ram attribute minConstPressure; + ram attribute maxConstPressure; ram attribute effectiveOperationMode; ram attribute effectiveControlMode; ram attribute capacity; ram attribute operationMode; - ram attribute featureMap; - ram attribute clusterRevision default = 3; + ram attribute featureMap default = 1; + ram attribute clusterRevision default = 4; } server cluster Thermostat { diff --git a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap index aba2e9b00a89ac..f1966cfbe7b475 100644 --- a/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap +++ b/examples/all-clusters-minimal-app/all-clusters-common/all-clusters-minimal-app.zap @@ -13956,11 +13956,11 @@ "mfgCode": null, "side": "server", "type": "int16s", - "included": 0, + "included": 1, "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "", + "defaultValue": null, "reportable": 1, "minInterval": 1, "maxInterval": 65534, @@ -13972,11 +13972,11 @@ "mfgCode": null, "side": "server", "type": "int16s", - "included": 0, + "included": 1, "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "", + "defaultValue": null, "reportable": 1, "minInterval": 1, "maxInterval": 65534, @@ -14280,7 +14280,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0", + "defaultValue": "1", "reportable": 1, "minInterval": 1, "maxInterval": 65534, @@ -14296,7 +14296,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "3", + "defaultValue": "4", "reportable": 1, "minInterval": 0, "maxInterval": 65344, diff --git a/examples/placeholder/linux/apps/app1/config.matter b/examples/placeholder/linux/apps/app1/config.matter index b77b029c92ee6b..1edc8484a8dd6b 100644 --- a/examples/placeholder/linux/apps/app1/config.matter +++ b/examples/placeholder/linux/apps/app1/config.matter @@ -1760,6 +1760,16 @@ server cluster PumpConfigurationAndControl = 512 { kLocal = 3; } + bitmap PumpFeature : BITMAP32 { + kConstantPressure = 0x1; + kCompensatedPressure = 0x2; + kConstantFlow = 0x4; + kConstantSpeed = 0x8; + kConstantTemperature = 0x10; + kAutomatic = 0x20; + kLocal = 0x40; + } + bitmap PumpStatus : BITMAP16 { kDeviceFault = 0x1; kSupplyfault = 0x2; diff --git a/examples/placeholder/linux/apps/app2/config.matter b/examples/placeholder/linux/apps/app2/config.matter index 4aa5878cbcffce..cdf7e4da214b93 100644 --- a/examples/placeholder/linux/apps/app2/config.matter +++ b/examples/placeholder/linux/apps/app2/config.matter @@ -1737,6 +1737,16 @@ server cluster PumpConfigurationAndControl = 512 { kLocal = 3; } + bitmap PumpFeature : BITMAP32 { + kConstantPressure = 0x1; + kCompensatedPressure = 0x2; + kConstantFlow = 0x4; + kConstantSpeed = 0x8; + kConstantTemperature = 0x10; + kAutomatic = 0x20; + kLocal = 0x40; + } + bitmap PumpStatus : BITMAP16 { kDeviceFault = 0x1; kSupplyfault = 0x2; diff --git a/examples/pump-app/pump-common/pump-app.matter b/examples/pump-app/pump-common/pump-app.matter index 0037ecdd5a6f51..55517bbc246f6f 100644 --- a/examples/pump-app/pump-common/pump-app.matter +++ b/examples/pump-app/pump-common/pump-app.matter @@ -1110,6 +1110,16 @@ server cluster PumpConfigurationAndControl = 512 { kLocal = 3; } + bitmap PumpFeature : BITMAP32 { + kConstantPressure = 0x1; + kCompensatedPressure = 0x2; + kConstantFlow = 0x4; + kConstantSpeed = 0x8; + kConstantTemperature = 0x10; + kAutomatic = 0x20; + kLocal = 0x40; + } + bitmap PumpStatus : BITMAP16 { kDeviceFault = 0x1; kSupplyfault = 0x2; @@ -1503,8 +1513,8 @@ endpoint 1 { callback attribute generatedCommandList; callback attribute acceptedCommandList; callback attribute attributeList; - ram attribute featureMap; - ram attribute clusterRevision default = 3; + ram attribute featureMap default = 31; + ram attribute clusterRevision default = 4; } server cluster TemperatureMeasurement { diff --git a/examples/pump-app/pump-common/pump-app.zap b/examples/pump-app/pump-common/pump-app.zap index d546d1333f1074..f590f49c579b05 100644 --- a/examples/pump-app/pump-common/pump-app.zap +++ b/examples/pump-app/pump-common/pump-app.zap @@ -7150,7 +7150,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "0", + "defaultValue": "31", "reportable": 1, "minInterval": 1, "maxInterval": 65534, @@ -7166,7 +7166,7 @@ "storageOption": "RAM", "singleton": 0, "bounded": 0, - "defaultValue": "3", + "defaultValue": "4", "reportable": 1, "minInterval": 0, "maxInterval": 65344, @@ -7914,5 +7914,6 @@ "endpointVersion": 1, "deviceIdentifier": 771 } - ] + ], + "log": [] } \ No newline at end of file diff --git a/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter b/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter index 8a9a3ff1b82778..6783ecf90163a5 100644 --- a/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter +++ b/examples/pump-controller-app/pump-controller-common/pump-controller-app.matter @@ -1009,6 +1009,16 @@ client cluster PumpConfigurationAndControl = 512 { kLocal = 3; } + bitmap PumpFeature : BITMAP32 { + kConstantPressure = 0x1; + kCompensatedPressure = 0x2; + kConstantFlow = 0x4; + kConstantSpeed = 0x8; + kConstantTemperature = 0x10; + kAutomatic = 0x20; + kLocal = 0x40; + } + bitmap PumpStatus : BITMAP16 { kDeviceFault = 0x1; kSupplyfault = 0x2; diff --git a/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp b/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp index ae3552eaef68dc..b06d5105aa6bd6 100644 --- a/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp +++ b/src/app/clusters/pump-configuration-and-control-server/pump-configuration-and-control-server.cpp @@ -21,7 +21,6 @@ #include #include #include -#include #include #include #include @@ -33,23 +32,10 @@ using namespace chip::app; using namespace chip::app::Clusters; using namespace chip::app::Clusters::PumpConfigurationAndControl; -namespace { - -class PumpConfigurationAndControlAttrAccess : public AttributeAccessInterface -{ -public: - // Register for the Pump Configuration And Control cluster on all endpoints. - PumpConfigurationAndControlAttrAccess() : - AttributeAccessInterface(Optional::Missing(), PumpConfigurationAndControl::Id) - {} - - CHIP_ERROR Read(const ConcreteReadAttributePath & aPath, AttributeValueEncoder & aEncoder) override; - CHIP_ERROR Write(const ConcreteDataAttributePath & aPath, AttributeValueDecoder & aDecoder) override; - -private: -}; - -PumpConfigurationAndControlAttrAccess gAttrAccess; +namespace chip { +namespace app { +namespace Clusters { +namespace PumpConfigurationAndControl { // Enum for RemoteSensorType enum class RemoteSensorType : uint8_t @@ -68,7 +54,7 @@ static RemoteSensorType detectRemoteSensorConnected() return RemoteSensorType::kNoSensor; } -static void updateAttributeLinks(EndpointId endpoint) +static void setEffectiveModes(EndpointId endpoint) { PumpControlMode controlMode; PumpOperationMode operationMode; @@ -242,109 +228,25 @@ static void updateAttributeLinks(EndpointId endpoint) } } -CHIP_ERROR PumpConfigurationAndControlAttrAccess::Read(const ConcreteReadAttributePath & aPath, AttributeValueEncoder & aEncoder) +bool HasFeature(EndpointId endpoint, PumpFeature feature) { - emberAfDebugPrintln("Reading from PCC"); + bool hasFeature; + uint32_t featureMap; + hasFeature = (Attributes::FeatureMap::Get(endpoint, &featureMap) == EMBER_ZCL_STATUS_SUCCESS); - VerifyOrDie(aPath.mClusterId == PumpConfigurationAndControl::Id); - - switch (aPath.mAttributeId) - { - default: - break; - } - return CHIP_NO_ERROR; + return hasFeature ? ((featureMap & to_underlying(feature)) != 0) : false; } -CHIP_ERROR PumpConfigurationAndControlAttrAccess::Write(const ConcreteDataAttributePath & aPath, AttributeValueDecoder & aDecoder) -{ - emberAfDebugPrintln("Writing to PCC"); - - VerifyOrDie(aPath.mClusterId == PumpConfigurationAndControl::Id); - - switch (aPath.mAttributeId) - { - default: - break; - } - return CHIP_NO_ERROR; -} -} // namespace +} // namespace PumpConfigurationAndControl +} // namespace Clusters +} // namespace app +} // namespace chip // SDK Callbacks -template -bool IsFeatureSupported(EndpointId endpoint, EmberAfStatus (*getFn1)(chip::EndpointId endpointId, T1 & value), - EmberAfStatus (*getFn2)(chip::EndpointId endpointId, T2 & value)) -{ - EmberAfStatus status; - - T1 value1; - T2 value2; - - status = getFn1(endpoint, value1); - if (status == EMBER_ZCL_STATUS_SUCCESS) - { - if (!value1.IsNull()) - { - status = getFn2(endpoint, value2); - if (status == EMBER_ZCL_STATUS_SUCCESS) - { - if (!value2.IsNull()) - { - return true; - } - } - } - } - - return false; -} - -template -const char * FeatureSupportedDebugString(EndpointId endpoint, EmberAfStatus (*getFn1)(chip::EndpointId endpointId, T1 & value), - EmberAfStatus (*getFn2)(chip::EndpointId endpointId, T2 & value)) -{ - return IsFeatureSupported(endpoint, getFn1, getFn2) ? "Supported" : "Not Supported"; -} - void emberAfPumpConfigurationAndControlClusterServerInitCallback(EndpointId endpoint) { emberAfDebugPrintln("Initialize PCC Server Cluster [EP:%d]", endpoint); - - // Determine the internal feature set of the pump, depending on the pump - // specific attributes available, and their values. This is a temporary - // implementation to get a kind of "pseudo-FeatureMap" until we get a real - // FeatureMap implementation in the PCC cluster. If an attribute is - // present/available, then there is a possibility for the associated - // feature being present as well. But we will have to distinguis between - // the attributes being available and null also. At this point (init) - // we can only examine the list of attributes available, and then detect - // if they each have a NonNull value. Later on, when the pump application - // has finished its init process, it might setup these attributevalues - // to something NonNull, and then we must re-calcualte the feature set. - - emberAfDebugPrintln( - "Constant Pressure %s", - FeatureSupportedDebugString(endpoint, Attributes::MinConstPressure::Get, Attributes::MaxConstPressure::Get)); - emberAfDebugPrintln("PCC Server: Constant Proportional Pressure %s", - FeatureSupportedDebugString(endpoint, Attributes::MinCompPressure::Get, Attributes::MaxCompPressure::Get)); - emberAfDebugPrintln("PCC Server: Constant Flow %s", - FeatureSupportedDebugString(endpoint, Attributes::MinConstFlow::Get, Attributes::MaxConstFlow::Get)); - emberAfDebugPrintln("PCC Server: Constant Temperature %s", - FeatureSupportedDebugString(endpoint, Attributes::MinConstTemp::Get, Attributes::MaxConstTemp::Get)); - emberAfDebugPrintln("PCC Server: Constant Speed %s", - FeatureSupportedDebugString(endpoint, Attributes::MinConstSpeed::Get, Attributes::MaxConstSpeed::Get)); - - if (!emberAfContainsAttribute(endpoint, PumpConfigurationAndControl::Id, Attributes::ControlMode::Id)) - { - emberAfDebugPrintln("PCC Server: ControlMode attribute not available"); - } - - if (!emberAfContainsAttribute(endpoint, PumpConfigurationAndControl::Id, Attributes::PumpStatus::Id)) - { - emberAfDebugPrintln("PCC Server: PumpStatus attribute not available"); - } } chip::Protocols::InteractionModel::Status MatterPumpConfigurationAndControlClusterServerPreAttributeChangedCallback( @@ -365,38 +267,40 @@ chip::Protocols::InteractionModel::Status MatterPumpConfigurationAndControlClust switch (controlMode) { case PumpControlMode::kConstantFlow: - if (!IsFeatureSupported(attributePath.mEndpointId, Attributes::MinConstFlow::Get, Attributes::MaxConstFlow::Get)) + if (!HasFeature(attributePath.mEndpointId, PumpFeature::kConstantFlow)) { status = Protocols::InteractionModel::Status::ConstraintError; } break; case PumpControlMode::kConstantPressure: - if (!IsFeatureSupported(attributePath.mEndpointId, Attributes::MinConstPressure::Get, - Attributes::MaxConstPressure::Get)) + if (!HasFeature(attributePath.mEndpointId, PumpFeature::kConstantPressure)) { status = Protocols::InteractionModel::Status::ConstraintError; } break; case PumpControlMode::kConstantSpeed: - if (!IsFeatureSupported(attributePath.mEndpointId, Attributes::MinConstSpeed::Get, Attributes::MaxConstSpeed::Get)) + if (!HasFeature(attributePath.mEndpointId, PumpFeature::kConstantSpeed)) { status = Protocols::InteractionModel::Status::ConstraintError; } break; case PumpControlMode::kConstantTemperature: - if (!IsFeatureSupported(attributePath.mEndpointId, Attributes::MinConstTemp::Get, Attributes::MaxConstTemp::Get)) + if (!HasFeature(attributePath.mEndpointId, PumpFeature::kConstantTemperature)) { status = Protocols::InteractionModel::Status::ConstraintError; } break; case PumpControlMode::kProportionalPressure: - if (!IsFeatureSupported(attributePath.mEndpointId, Attributes::MinCompPressure::Get, Attributes::MaxCompPressure::Get)) + if (!HasFeature(attributePath.mEndpointId, PumpFeature::kCompensatedPressure)) { status = Protocols::InteractionModel::Status::ConstraintError; } break; case PumpControlMode::kAutomatic: - status = Protocols::InteractionModel::Status::Success; + if (!HasFeature(attributePath.mEndpointId, PumpFeature::kAutomatic)) + { + status = Protocols::InteractionModel::Status::ConstraintError; + } break; case PumpControlMode::kUnknownEnumValue: status = Protocols::InteractionModel::Status::ConstraintError; @@ -414,18 +318,23 @@ chip::Protocols::InteractionModel::Status MatterPumpConfigurationAndControlClust switch (operationMode) { case PumpOperationMode::kMinimum: - if (!IsFeatureSupported(attributePath.mEndpointId, Attributes::MinConstSpeed::Get, Attributes::MaxConstSpeed::Get)) + if (!HasFeature(attributePath.mEndpointId, PumpFeature::kConstantSpeed)) { status = Protocols::InteractionModel::Status::ConstraintError; } break; case PumpOperationMode::kMaximum: - if (!IsFeatureSupported(attributePath.mEndpointId, Attributes::MinConstSpeed::Get, Attributes::MaxConstSpeed::Get)) + if (!HasFeature(attributePath.mEndpointId, PumpFeature::kConstantSpeed)) { status = Protocols::InteractionModel::Status::ConstraintError; } break; case PumpOperationMode::kLocal: + if (!HasFeature(attributePath.mEndpointId, PumpFeature::kLocal)) + { + status = Protocols::InteractionModel::Status::ConstraintError; + } + break; case PumpOperationMode::kNormal: status = Protocols::InteractionModel::Status::Success; break; @@ -449,22 +358,13 @@ void MatterPumpConfigurationAndControlClusterServerAttributeChangedCallback(cons switch (attributePath.mAttributeId) { - case Attributes::ControlMode::Id: { - updateAttributeLinks(attributePath.mEndpointId); - } - break; - case Attributes::OperationMode::Id: { - updateAttributeLinks(attributePath.mEndpointId); - } - break; + case Attributes::ControlMode::Id: + case Attributes::OperationMode::Id: + setEffectiveModes(attributePath.mEndpointId); + break; default: emberAfDebugPrintln("PCC Server: unhandled attribute ID"); } } -void MatterPumpConfigurationAndControlPluginServerInitCallback() -{ - emberAfDebugPrintln("Initialize PCC Plugin Server Cluster."); - - registerAttributeAccessOverride(&gAttrAccess); -} +void MatterPumpConfigurationAndControlPluginServerInitCallback() {} diff --git a/src/app/tests/suites/certification/PICS.yaml b/src/app/tests/suites/certification/PICS.yaml index 67d5ea70a77b02..c68e8915b65014 100644 --- a/src/app/tests/suites/certification/PICS.yaml +++ b/src/app/tests/suites/certification/PICS.yaml @@ -2807,6 +2807,27 @@ PICS: id: FLW.M.FlowChange # Pump Configuration and Control cluster + - label: "Supports operating in constant pressure mode" + id: PCC.S.F00 + + - label: "Supports operating in compensated pressure mode" + id: PCC.S.F01 + + - label: "Supports operating in constant flow mode" + id: PCC.S.F02 + + - label: "Supports operating in constant speed mode" + id: PCC.S.F03 + + - label: "Supports operating in constant temperature mode" + id: PCC.S.F04 + + - label: "Supports operating in automatic mode" + id: PCC.S.F05 + + - label: "Supports operating using local settings" + id: PCC.S.F06 + - label: "Does the device implement the MaxPressure attribute?" id: PCC.S.A0000 @@ -2876,24 +2897,6 @@ PICS: - label: "Does the device implement the LifetimeEnergyConsumed attribute?" id: PCC.S.A0021 - - label: "Does the device implement the ConstantSpeed control mode?" - id: PCC.M.ControlModeConstSpeed - - - label: "Does the device implement the ConstantPressure control mode?" - id: PCC.M.ControlModeConstPressure - - - label: "Does the device implement the ProportionalPressure control mode?" - id: PCC.M.ControlModeCompPressure - - - label: "Does the device implement the ConstantFlow control mode?" - id: PCC.M.ControlModeConstFlow - - - label: "Does the device implement the ConstantTemperature control mode?" - id: PCC.M.ControlModeConstTemp - - - label: "Does the device implement the Automatic control mode?" - id: PCC.M.ControlModeAuto - #Power Source Cluster - label: "Does the device implement the Status attribute?" id: PS.S.A0000 diff --git a/src/app/tests/suites/certification/Test_TC_PCC_1_1.yaml b/src/app/tests/suites/certification/Test_TC_PCC_1_1.yaml index dd3d65fd00c92f..d8805c991eee8c 100644 --- a/src/app/tests/suites/certification/Test_TC_PCC_1_1.yaml +++ b/src/app/tests/suites/certification/Test_TC_PCC_1_1.yaml @@ -35,11 +35,14 @@ tests: command: "readAttribute" attribute: "ClusterRevision" response: - value: 3 + value: 4 constraints: type: int16u - label: "TH reads the FeatureMap attribute from the DUT" + PICS: + " !PCC.S.F00 && !PCC.S.F01 && !PCC.S.F02 && !PCC.S.F03 && !PCC.S.F04 + && !PCC.S.F05 && !PCC.S.F06 " command: "readAttribute" attribute: "FeatureMap" response: @@ -47,6 +50,71 @@ tests: constraints: type: bitmap32 + - label: + "Given PCC.S.F00(PRSCONST) ensure featuremap has the correct bit set" + PICS: PCC.S.F00 + command: "readAttribute" + attribute: "FeatureMap" + response: + constraints: + type: bitmap32 + hasMasksSet: [0x1] + + - label: + "Given PCC.S.F01(PRSCOMP) ensure featuremap has the correct bit set" + PICS: PCC.S.F01 + command: "readAttribute" + attribute: "FeatureMap" + response: + constraints: + type: bitmap32 + hasMasksSet: [0x2] + + - label: "Given PCC.S.F02(FLW) ensure featuremap has the correct bit set" + PICS: PCC.S.F02 + command: "readAttribute" + attribute: "FeatureMap" + response: + constraints: + type: bitmap32 + hasMasksSet: [0x4] + + - label: "Given PCC.S.F03(SPD) ensure featuremap has the correct bit set" + PICS: PCC.S.F03 + command: "readAttribute" + attribute: "FeatureMap" + response: + constraints: + type: bitmap32 + hasMasksSet: [0x8] + + - label: "Given PCC.S.F04(TEMP) ensure featuremap has the correct bit set" + PICS: PCC.S.F04 + command: "readAttribute" + attribute: "FeatureMap" + response: + constraints: + type: bitmap32 + hasMasksSet: [0x10] + + - label: "Given PCC.S.F05(AUTO) ensure featuremap has the correct bit set" + PICS: PCC.S.F05 + command: "readAttribute" + attribute: "FeatureMap" + response: + constraints: + type: bitmap32 + hasMasksSet: [0x20] + + - label: "Given PCC.S.F06(LOCAL) ensure featuremap has the correct bit set" + PICS: PCC.S.F06 + command: "readAttribute" + attribute: "FeatureMap" + response: + constraints: + type: bitmap32 + hasMasksSet: [0x40] + - label: "TH reads the AttributeList attribute from the DUT" command: "readAttribute" attribute: "AttributeList" diff --git a/src/app/tests/suites/certification/Test_TC_PCC_2_2.yaml b/src/app/tests/suites/certification/Test_TC_PCC_2_2.yaml index 1019d114098154..0d02638d029fe6 100644 --- a/src/app/tests/suites/certification/Test_TC_PCC_2_2.yaml +++ b/src/app/tests/suites/certification/Test_TC_PCC_2_2.yaml @@ -48,14 +48,14 @@ tests: - label: "TH write 1 (Minimum) to the OperationMode attribute to DUT" command: "writeAttribute" attribute: "OperationMode" - PICS: PCC.S.A0020 && PCC.M.ControlModeConstSpeed + PICS: PCC.S.F03 && PCC.S.A0020 arguments: value: 1 - label: "TH reads from the DUT the EffectiveOperationMode attribute" command: "readAttribute" attribute: "EffectiveOperationMode" - PICS: PCC.S.A0011 && PCC.M.ControlModeConstSpeed + PICS: PCC.S.F03 && PCC.S.A0011 response: value: 1 @@ -64,27 +64,27 @@ tests: time." command: "writeAttribute" attribute: "OperationMode" - PICS: PCC.S.A0020 && PCC.M.ControlModeConstSpeed + PICS: PCC.S.F03 && PCC.S.A0020 arguments: value: 2 - label: "TH reads from the DUT the EffectiveOperationMode attribute" command: "readAttribute" attribute: "EffectiveOperationMode" - PICS: PCC.S.A0011 && PCC.M.ControlModeConstSpeed + PICS: PCC.S.F03 && PCC.S.A0011 response: value: 2 - label: "TH write 3 (Local) to the OperationMode attribute to DUT" command: "writeAttribute" attribute: "OperationMode" - PICS: PCC.S.A0020 + PICS: PCC.S.F06 && PCC.S.A0020 arguments: value: 3 - label: "TH reads from the DUT the EffectiveOperationMode attribute" command: "readAttribute" attribute: "EffectiveOperationMode" - PICS: PCC.S.A0011 + PICS: PCC.S.F06 && PCC.S.A0011 response: value: 3 diff --git a/src/app/tests/suites/certification/Test_TC_PCC_2_3.yaml b/src/app/tests/suites/certification/Test_TC_PCC_2_3.yaml index fbf880d3668745..75f7789392027d 100644 --- a/src/app/tests/suites/certification/Test_TC_PCC_2_3.yaml +++ b/src/app/tests/suites/certification/Test_TC_PCC_2_3.yaml @@ -48,83 +48,83 @@ tests: - label: "Write 0 to the ControlMode attribute to DUT" command: "writeAttribute" attribute: "ControlMode" - PICS: PCC.S.A0021 && PCC.M.ControlModeConstSpeed + PICS: PCC.S.F03 && PCC.S.A0021 arguments: value: 0 - label: "Reads the attribute: EffectiveControlMode" command: "readAttribute" attribute: "EffectiveControlMode" - PICS: PCC.S.A0012 && PCC.M.ControlModeConstSpeed + PICS: PCC.S.F03 && PCC.S.A0012 response: value: 0 - label: "Write 1 to the ControlMode attribute to DUT" command: "writeAttribute" attribute: "ControlMode" - PICS: PCC.S.A0021 && PCC.M.ControlModeConstPressure + PICS: PCC.S.F00 && PCC.S.A0021 arguments: value: 1 - label: "Reads the attribute: EffectiveControlMode" command: "readAttribute" attribute: "EffectiveControlMode" - PICS: PCC.S.A0012 && PCC.M.ControlModeConstPressure + PICS: PCC.S.F00 && PCC.S.A0012 response: value: 1 - label: "Write 2 to the ControlMode attribute to DUT" command: "writeAttribute" attribute: "ControlMode" - PICS: PCC.S.A0021 && PCC.M.ControlModeCompPressure + PICS: PCC.S.F01 && PCC.S.A0021 arguments: value: 2 - label: "Reads the attribute: EffectiveControlMode" command: "readAttribute" attribute: "EffectiveControlMode" - PICS: PCC.S.A0012 && PCC.M.ControlModeCompPressure + PICS: PCC.S.F01 && PCC.S.A0012 response: value: 2 - label: "Write 3 to the ControlMode attribute to DUT" command: "writeAttribute" attribute: "ControlMode" - PICS: PCC.S.A0021 && PCC.M.ControlModeConstFlow + PICS: PCC.S.F02 && PCC.S.A0021 arguments: value: 3 - label: "Reads the attribute: EffectiveControlMode" command: "readAttribute" attribute: "EffectiveControlMode" - PICS: PCC.S.A0012 && PCC.M.ControlModeConstFlow + PICS: PCC.S.F02 && PCC.S.A0012 response: value: 3 - label: "Write 5 to the ControlMode attribute to DUT" command: "writeAttribute" attribute: "ControlMode" - PICS: PCC.S.A0021 && PCC.M.ControlModeConstTemp + PICS: PCC.S.F04 && PCC.S.A0021 arguments: value: 5 - label: "Reads the attribute: EffectiveControlMode" command: "readAttribute" attribute: "EffectiveControlMode" - PICS: PCC.S.A0012 && PCC.M.ControlModeConstTemp + PICS: PCC.S.F04 && PCC.S.A0012 response: value: 5 - label: "Write 7 to the ControlMode attribute to DUT" command: "writeAttribute" attribute: "ControlMode" - PICS: PCC.S.A0021 && PCC.M.ControlModeAuto + PICS: PCC.S.F05 && PCC.S.A0021 arguments: value: 7 - label: "Reads the attribute: EffectiveControlMode" command: "readAttribute" attribute: "EffectiveControlMode" - PICS: PCC.S.A0012 && PCC.M.ControlModeAuto + PICS: PCC.S.F02 && PCC.S.A0012 response: value: 7 diff --git a/src/app/tests/suites/certification/ci-pics-values b/src/app/tests/suites/certification/ci-pics-values index 077b01e51c37bf..e5d27bdef66a39 100644 --- a/src/app/tests/suites/certification/ci-pics-values +++ b/src/app/tests/suites/certification/ci-pics-values @@ -730,6 +730,13 @@ FLW.S.A0003=1 FLW.M.FlowChange=1 #Pump Configuration and Control +PCC.S.F00=1 +PCC.S.F01=0 +PCC.S.F02=0 +PCC.S.F03=0 +PCC.S.F04=0 +PCC.S.F05=0 +PCC.S.F06=0 PCC.S.A0000=1 PCC.S.A0001=1 PCC.S.A0002=1 @@ -753,12 +760,6 @@ PCC.S.A0016=1 PCC.S.A0017=1 PCC.S.A0020=1 PCC.S.A0021=1 -PCC.M.ControlModeConstSpeed=1 -PCC.M.ControlModeConstPressure=1 -PCC.M.ControlModeCompPressure=1 -PCC.M.ControlModeConstFlow=1 -PCC.M.ControlModeConstTemp=1 -PCC.M.ControlModeAuto=1 #Power Source Cluster PS.S.A0000=1 diff --git a/src/app/zap-templates/zcl/data-model/chip/pump-configuration-and-control-cluster.xml b/src/app/zap-templates/zcl/data-model/chip/pump-configuration-and-control-cluster.xml index 0d00dc829a7385..112f30fc8b1e46 100644 --- a/src/app/zap-templates/zcl/data-model/chip/pump-configuration-and-control-cluster.xml +++ b/src/app/zap-templates/zcl/data-model/chip/pump-configuration-and-control-cluster.xml @@ -149,4 +149,15 @@ limitations under the License. + + + + + + + + + + + diff --git a/src/controller/data_model/controller-clusters.matter b/src/controller/data_model/controller-clusters.matter index f6a67bc58d9a60..42146d4d5b434f 100644 --- a/src/controller/data_model/controller-clusters.matter +++ b/src/controller/data_model/controller-clusters.matter @@ -2811,6 +2811,16 @@ client cluster PumpConfigurationAndControl = 512 { kLocal = 3; } + bitmap PumpFeature : BITMAP32 { + kConstantPressure = 0x1; + kCompensatedPressure = 0x2; + kConstantFlow = 0x4; + kConstantSpeed = 0x8; + kConstantTemperature = 0x10; + kAutomatic = 0x20; + kLocal = 0x40; + } + bitmap PumpStatus : BITMAP16 { kDeviceFault = 0x1; kSupplyfault = 0x2; diff --git a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h index 456e9a26a002b8..baff7acd0e3c7b 100644 --- a/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h +++ b/src/darwin/Framework/CHIP/zap-generated/MTRBaseClusters.h @@ -18417,6 +18417,16 @@ typedef NS_ENUM(uint8_t, MTRPumpConfigurationAndControlPumpOperationMode) { MTRPumpConfigurationAndControlPumpOperationModeLocal API_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x03, } API_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)); +typedef NS_OPTIONS(uint32_t, MTRPumpConfigurationAndControlPumpFeature) { + MTRPumpConfigurationAndControlPumpFeatureConstantPressure MTR_NEWLY_AVAILABLE = 0x1, + MTRPumpConfigurationAndControlPumpFeatureCompensatedPressure MTR_NEWLY_AVAILABLE = 0x2, + MTRPumpConfigurationAndControlPumpFeatureConstantFlow MTR_NEWLY_AVAILABLE = 0x4, + MTRPumpConfigurationAndControlPumpFeatureConstantSpeed MTR_NEWLY_AVAILABLE = 0x8, + MTRPumpConfigurationAndControlPumpFeatureConstantTemperature MTR_NEWLY_AVAILABLE = 0x10, + MTRPumpConfigurationAndControlPumpFeatureAutomatic MTR_NEWLY_AVAILABLE = 0x20, + MTRPumpConfigurationAndControlPumpFeatureLocal MTR_NEWLY_AVAILABLE = 0x40, +} MTR_NEWLY_AVAILABLE; + typedef NS_OPTIONS(uint16_t, MTRPumpConfigurationAndControlPumpStatus) { MTRPumpConfigurationAndControlPumpStatusDeviceFault API_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x1, MTRPumpConfigurationAndControlPumpStatusSupplyfault API_AVAILABLE(ios(16.1), macos(13.0), watchos(9.1), tvos(16.1)) = 0x2, 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 3b6da269e54300..ce05711413631b 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 @@ -1585,6 +1585,18 @@ enum class PumpOperationMode : uint8_t kUnknownEnumValue = 4, }; +// Bitmap for PumpFeature +enum class PumpFeature : uint32_t +{ + kConstantPressure = 0x1, + kCompensatedPressure = 0x2, + kConstantFlow = 0x4, + kConstantSpeed = 0x8, + kConstantTemperature = 0x10, + kAutomatic = 0x20, + kLocal = 0x40, +}; + // Bitmap for PumpStatus enum class PumpStatus : uint16_t { 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 fe568a150e46ce..595cfa9e6aa1ed 100644 --- a/zzz_generated/app-common/app-common/zap-generated/enums.h +++ b/zzz_generated/app-common/app-common/zap-generated/enums.h @@ -798,6 +798,20 @@ enum EmberAfWiFiVersionType : uint8_t #define EMBER_AF_POWER_SOURCE_FEATURE_REPLACEABLE_OFFSET (3) #define EMBER_AF_PRESSURE_FEATURE_EXTENDED (1) #define EMBER_AF_PRESSURE_FEATURE_EXTENDED_OFFSET (0) +#define EMBER_AF_PUMP_FEATURE_CONSTANT_PRESSURE (1) +#define EMBER_AF_PUMP_FEATURE_CONSTANT_PRESSURE_OFFSET (0) +#define EMBER_AF_PUMP_FEATURE_COMPENSATED_PRESSURE (2) +#define EMBER_AF_PUMP_FEATURE_COMPENSATED_PRESSURE_OFFSET (1) +#define EMBER_AF_PUMP_FEATURE_CONSTANT_FLOW (4) +#define EMBER_AF_PUMP_FEATURE_CONSTANT_FLOW_OFFSET (2) +#define EMBER_AF_PUMP_FEATURE_CONSTANT_SPEED (8) +#define EMBER_AF_PUMP_FEATURE_CONSTANT_SPEED_OFFSET (3) +#define EMBER_AF_PUMP_FEATURE_CONSTANT_TEMPERATURE (16) +#define EMBER_AF_PUMP_FEATURE_CONSTANT_TEMPERATURE_OFFSET (4) +#define EMBER_AF_PUMP_FEATURE_AUTOMATIC (32) +#define EMBER_AF_PUMP_FEATURE_AUTOMATIC_OFFSET (5) +#define EMBER_AF_PUMP_FEATURE_LOCAL (64) +#define EMBER_AF_PUMP_FEATURE_LOCAL_OFFSET (6) #define EMBER_AF_PUMP_STATUS_DEVICE_FAULT (1) #define EMBER_AF_PUMP_STATUS_DEVICE_FAULT_OFFSET (0) #define EMBER_AF_PUMP_STATUS_SUPPLYFAULT (2) diff --git a/zzz_generated/chip-tool/zap-generated/test/Commands.h b/zzz_generated/chip-tool/zap-generated/test/Commands.h index be6f025dc132ce..30592b6a430fb4 100644 --- a/zzz_generated/chip-tool/zap-generated/test/Commands.h +++ b/zzz_generated/chip-tool/zap-generated/test/Commands.h @@ -38004,7 +38004,7 @@ class Test_TC_PRS_2_2Suite : public TestCommand class Test_TC_PCC_1_1Suite : public TestCommand { public: - Test_TC_PCC_1_1Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_PCC_1_1", 22, credsIssuerConfig) + Test_TC_PCC_1_1Suite(CredentialIssuerCommands * credsIssuerConfig) : TestCommand("Test_TC_PCC_1_1", 29, credsIssuerConfig) { AddArgument("nodeId", 0, UINT64_MAX, &mNodeId); AddArgument("cluster", &mCluster); @@ -38054,7 +38054,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand { uint16_t value; VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); - VerifyOrReturn(CheckValue("clusterRevision", value, 3U)); + VerifyOrReturn(CheckValue("clusterRevision", value, 4U)); VerifyOrReturn(CheckConstraintType("value", "int16u", "int16u")); } break; @@ -38068,6 +38068,69 @@ class Test_TC_PCC_1_1Suite : public TestCommand } break; case 3: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "bitmap32", "bitmap32")); + VerifyOrReturn(CheckConstraintHasMasksSet("value", value, 1UL)); + } + break; + case 4: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "bitmap32", "bitmap32")); + VerifyOrReturn(CheckConstraintHasMasksSet("value", value, 2UL)); + } + break; + case 5: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "bitmap32", "bitmap32")); + VerifyOrReturn(CheckConstraintHasMasksSet("value", value, 4UL)); + } + break; + case 6: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "bitmap32", "bitmap32")); + VerifyOrReturn(CheckConstraintHasMasksSet("value", value, 8UL)); + } + break; + case 7: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "bitmap32", "bitmap32")); + VerifyOrReturn(CheckConstraintHasMasksSet("value", value, 16UL)); + } + break; + case 8: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "bitmap32", "bitmap32")); + VerifyOrReturn(CheckConstraintHasMasksSet("value", value, 32UL)); + } + break; + case 9: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + { + uint32_t value; + VerifyOrReturn(CheckDecodeValue(chip::app::DataModel::Decode(*data, value))); + VerifyOrReturn(CheckConstraintType("value", "bitmap32", "bitmap32")); + VerifyOrReturn(CheckConstraintHasMasksSet("value", value, 64UL)); + } + break; + case 10: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38087,7 +38150,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 65533UL)); } break; - case 4: + case 11: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38096,7 +38159,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 3UL)); } break; - case 5: + case 12: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38105,7 +38168,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 4UL)); } break; - case 6: + case 13: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38114,7 +38177,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 5UL)); } break; - case 7: + case 14: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38123,7 +38186,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 6UL)); } break; - case 8: + case 15: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38132,7 +38195,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 7UL)); } break; - case 9: + case 16: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38141,7 +38204,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 8UL)); } break; - case 10: + case 17: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38150,7 +38213,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 9UL)); } break; - case 11: + case 18: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38159,7 +38222,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 10UL)); } break; - case 12: + case 19: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38168,7 +38231,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 11UL)); } break; - case 13: + case 20: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38177,7 +38240,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 12UL)); } break; - case 14: + case 21: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38186,7 +38249,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 16UL)); } break; - case 15: + case 22: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38195,7 +38258,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 20UL)); } break; - case 16: + case 23: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38204,7 +38267,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 21UL)); } break; - case 17: + case 24: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38213,7 +38276,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 22UL)); } break; - case 18: + case 25: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38222,7 +38285,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 23UL)); } break; - case 19: + case 26: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38231,7 +38294,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintContains("value", value, 33UL)); } break; - case 20: + case 27: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38243,7 +38306,7 @@ class Test_TC_PCC_1_1Suite : public TestCommand VerifyOrReturn(CheckConstraintType("value", "list", "list")); } break; - case 21: + case 28: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); { chip::app::DataModel::DecodableList value; @@ -38290,117 +38353,162 @@ class Test_TC_PCC_1_1Suite : public TestCommand } case 2: { LogStep(2, "TH reads the FeatureMap attribute from the DUT"); + VerifyOrDo( + !ShouldSkip(" !PCC.S.F00 && !PCC.S.F01 && !PCC.S.F02 && !PCC.S.F03 && !PCC.S.F04 && !PCC.S.F05 && !PCC.S.F06 "), + return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::FeatureMap::Id, true, chip::NullOptional); } case 3: { - LogStep(3, "TH reads the AttributeList attribute from the DUT"); + LogStep(3, "Given PCC.S.F00(PRSCONST) ensure featuremap has the correct bit set"); + VerifyOrDo(!ShouldSkip("PCC.S.F00"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, - PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); + PumpConfigurationAndControl::Attributes::FeatureMap::Id, true, chip::NullOptional); } case 4: { - LogStep(4, "TH reads optional attribute(MinConstPressure) attribute in AttributeList from the DUT"); + LogStep(4, "Given PCC.S.F01(PRSCOMP) ensure featuremap has the correct bit set"); + VerifyOrDo(!ShouldSkip("PCC.S.F01"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, + PumpConfigurationAndControl::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 5: { + LogStep(5, "Given PCC.S.F02(FLW) ensure featuremap has the correct bit set"); + VerifyOrDo(!ShouldSkip("PCC.S.F02"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, + PumpConfigurationAndControl::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 6: { + LogStep(6, "Given PCC.S.F03(SPD) ensure featuremap has the correct bit set"); + VerifyOrDo(!ShouldSkip("PCC.S.F03"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, + PumpConfigurationAndControl::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 7: { + LogStep(7, "Given PCC.S.F04(TEMP) ensure featuremap has the correct bit set"); + VerifyOrDo(!ShouldSkip("PCC.S.F04"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, + PumpConfigurationAndControl::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 8: { + LogStep(8, "Given PCC.S.F05(AUTO) ensure featuremap has the correct bit set"); + VerifyOrDo(!ShouldSkip("PCC.S.F05"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, + PumpConfigurationAndControl::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 9: { + LogStep(9, "Given PCC.S.F06(LOCAL) ensure featuremap has the correct bit set"); + VerifyOrDo(!ShouldSkip("PCC.S.F06"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, + PumpConfigurationAndControl::Attributes::FeatureMap::Id, true, chip::NullOptional); + } + case 10: { + LogStep(10, "TH reads the AttributeList attribute from the DUT"); + return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, + PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); + } + case 11: { + LogStep(11, "TH reads optional attribute(MinConstPressure) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0003"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 5: { - LogStep(5, "TH reads optional attribute(MaxConstPressure) attribute in AttributeList from the DUT"); + case 12: { + LogStep(12, "TH reads optional attribute(MaxConstPressure) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0004"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 6: { - LogStep(6, "TH reads optional attribute(MinCompPressure) attribute in AttributeList from the DUT"); + case 13: { + LogStep(13, "TH reads optional attribute(MinCompPressure) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0005"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 7: { - LogStep(7, "TH reads optional attribute(MaxCompPressure) attribute in AttributeList from the DUT"); + case 14: { + LogStep(14, "TH reads optional attribute(MaxCompPressure) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0006"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 8: { - LogStep(8, "TH reads optional attribute(MinConstSpeed) attribute in AttributeList from the DUT"); + case 15: { + LogStep(15, "TH reads optional attribute(MinConstSpeed) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0007"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 9: { - LogStep(9, "TH reads optional attribute(MaxConstSpeed) attribute in AttributeList from the DUT"); + case 16: { + LogStep(16, "TH reads optional attribute(MaxConstSpeed) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0008"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 10: { - LogStep(10, "TH reads optional attribute(MinConstFlow) attribute in AttributeList from the DUT"); + case 17: { + LogStep(17, "TH reads optional attribute(MinConstFlow) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0009"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 11: { - LogStep(11, "TH reads optional attribute(MaxConstFlow) attribute in AttributeList from the DUT"); + case 18: { + LogStep(18, "TH reads optional attribute(MaxConstFlow) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A000a"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 12: { - LogStep(12, "TH reads optional attribute(MinConstTemp) attribute in AttributeList from the DUT"); + case 19: { + LogStep(19, "TH reads optional attribute(MinConstTemp) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A000b"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 13: { - LogStep(13, "TH reads optional attribute(MaxConstTemp) attribute in AttributeList from the DUT"); + case 20: { + LogStep(20, "TH reads optional attribute(MaxConstTemp) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A000c"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 14: { - LogStep(14, "TH reads optional attribute(PumpStatus) attribute in AttributeList from the DUT"); + case 21: { + LogStep(21, "TH reads optional attribute(PumpStatus) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0010"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 15: { - LogStep(15, "TH reads optional attribute(Speed) attribute in AttributeList from the DUT"); + case 22: { + LogStep(22, "TH reads optional attribute(Speed) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0014"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 16: { - LogStep(16, "TH reads optional attribute(LifetimeRunningHours) attribute in AttributeList from the DUT"); + case 23: { + LogStep(23, "TH reads optional attribute(LifetimeRunningHours) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0015"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 17: { - LogStep(17, "TH reads optional attribute(Power) attribute in AttributeList from the DUT"); + case 24: { + LogStep(24, "TH reads optional attribute(Power) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0016"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 18: { - LogStep(18, "TH reads optional attribute(LifetimeEnergyConsumed) attribute in AttributeList from the DUT"); + case 25: { + LogStep(25, "TH reads optional attribute(LifetimeEnergyConsumed) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0017"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 19: { - LogStep(19, "TH reads optional attribute(ControlMode) attribute in AttributeList from the DUT"); + case 26: { + LogStep(26, "TH reads optional attribute(ControlMode) attribute in AttributeList from the DUT"); VerifyOrDo(!ShouldSkip("PCC.S.A0021"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AttributeList::Id, true, chip::NullOptional); } - case 20: { - LogStep(20, "TH reads the AcceptedCommandList attribute from the DUT"); + case 27: { + LogStep(27, "TH reads the AcceptedCommandList attribute from the DUT"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::AcceptedCommandList::Id, true, chip::NullOptional); } - case 21: { - LogStep(21, "TH reads the GeneratedCommandList attribute from the DUT"); + case 28: { + LogStep(28, "TH reads the GeneratedCommandList attribute from the DUT"); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::GeneratedCommandList::Id, true, chip::NullOptional); } @@ -38996,7 +39104,7 @@ class Test_TC_PCC_2_2Suite : public TestCommand } case 3: { LogStep(3, "TH write 1 (Minimum) to the OperationMode attribute to DUT"); - VerifyOrDo(!ShouldSkip("PCC.S.A0020 && PCC.M.ControlModeConstSpeed"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F03 && PCC.S.A0020"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode value; value = static_cast(1); @@ -39006,13 +39114,13 @@ class Test_TC_PCC_2_2Suite : public TestCommand } case 4: { LogStep(4, "TH reads from the DUT the EffectiveOperationMode attribute"); - VerifyOrDo(!ShouldSkip("PCC.S.A0011 && PCC.M.ControlModeConstSpeed"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F03 && PCC.S.A0011"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::EffectiveOperationMode::Id, true, chip::NullOptional); } case 5: { LogStep(5, "TH write 2 (Maximum) to the OperationMode attribute to DUT one at a time."); - VerifyOrDo(!ShouldSkip("PCC.S.A0020 && PCC.M.ControlModeConstSpeed"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F03 && PCC.S.A0020"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode value; value = static_cast(2); @@ -39022,13 +39130,13 @@ class Test_TC_PCC_2_2Suite : public TestCommand } case 6: { LogStep(6, "TH reads from the DUT the EffectiveOperationMode attribute"); - VerifyOrDo(!ShouldSkip("PCC.S.A0011 && PCC.M.ControlModeConstSpeed"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F03 && PCC.S.A0011"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::EffectiveOperationMode::Id, true, chip::NullOptional); } case 7: { LogStep(7, "TH write 3 (Local) to the OperationMode attribute to DUT"); - VerifyOrDo(!ShouldSkip("PCC.S.A0020"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F06 && PCC.S.A0020"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::PumpConfigurationAndControl::PumpOperationMode value; value = static_cast(3); @@ -39038,7 +39146,7 @@ class Test_TC_PCC_2_2Suite : public TestCommand } case 8: { LogStep(8, "TH reads from the DUT the EffectiveOperationMode attribute"); - VerifyOrDo(!ShouldSkip("PCC.S.A0011"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F06 && PCC.S.A0011"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::EffectiveOperationMode::Id, true, chip::NullOptional); } @@ -39218,7 +39326,7 @@ class Test_TC_PCC_2_3Suite : public TestCommand } case 3: { LogStep(3, "Write 0 to the ControlMode attribute to DUT"); - VerifyOrDo(!ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeConstSpeed"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F03 && PCC.S.A0021"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value; value = static_cast(0); @@ -39228,14 +39336,13 @@ class Test_TC_PCC_2_3Suite : public TestCommand } case 4: { LogStep(4, "Reads the attribute: EffectiveControlMode"); - VerifyOrDo(!ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeConstSpeed"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F03 && PCC.S.A0012"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::EffectiveControlMode::Id, true, chip::NullOptional); } case 5: { LogStep(5, "Write 1 to the ControlMode attribute to DUT"); - VerifyOrDo(!ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeConstPressure"), - return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F00 && PCC.S.A0021"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value; value = static_cast(1); @@ -39245,14 +39352,13 @@ class Test_TC_PCC_2_3Suite : public TestCommand } case 6: { LogStep(6, "Reads the attribute: EffectiveControlMode"); - VerifyOrDo(!ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeConstPressure"), - return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F00 && PCC.S.A0012"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::EffectiveControlMode::Id, true, chip::NullOptional); } case 7: { LogStep(7, "Write 2 to the ControlMode attribute to DUT"); - VerifyOrDo(!ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeCompPressure"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F01 && PCC.S.A0021"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value; value = static_cast(2); @@ -39262,13 +39368,13 @@ class Test_TC_PCC_2_3Suite : public TestCommand } case 8: { LogStep(8, "Reads the attribute: EffectiveControlMode"); - VerifyOrDo(!ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeCompPressure"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F01 && PCC.S.A0012"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::EffectiveControlMode::Id, true, chip::NullOptional); } case 9: { LogStep(9, "Write 3 to the ControlMode attribute to DUT"); - VerifyOrDo(!ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeConstFlow"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F02 && PCC.S.A0021"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value; value = static_cast(3); @@ -39278,13 +39384,13 @@ class Test_TC_PCC_2_3Suite : public TestCommand } case 10: { LogStep(10, "Reads the attribute: EffectiveControlMode"); - VerifyOrDo(!ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeConstFlow"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F02 && PCC.S.A0012"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::EffectiveControlMode::Id, true, chip::NullOptional); } case 11: { LogStep(11, "Write 5 to the ControlMode attribute to DUT"); - VerifyOrDo(!ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeConstTemp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F04 && PCC.S.A0021"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value; value = static_cast(5); @@ -39294,13 +39400,13 @@ class Test_TC_PCC_2_3Suite : public TestCommand } case 12: { LogStep(12, "Reads the attribute: EffectiveControlMode"); - VerifyOrDo(!ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeConstTemp"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F04 && PCC.S.A0012"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::EffectiveControlMode::Id, true, chip::NullOptional); } case 13: { LogStep(13, "Write 7 to the ControlMode attribute to DUT"); - VerifyOrDo(!ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeAuto"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F05 && PCC.S.A0021"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); ListFreer listFreer; chip::app::Clusters::PumpConfigurationAndControl::PumpControlMode value; value = static_cast(7); @@ -39310,7 +39416,7 @@ class Test_TC_PCC_2_3Suite : public TestCommand } case 14: { LogStep(14, "Reads the attribute: EffectiveControlMode"); - VerifyOrDo(!ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeAuto"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); + VerifyOrDo(!ShouldSkip("PCC.S.F02 && PCC.S.A0012"), return ContinueOnChipMainThread(CHIP_NO_ERROR)); return ReadAttribute(kIdentityAlpha, GetEndpoint(1), PumpConfigurationAndControl::Id, PumpConfigurationAndControl::Attributes::EffectiveControlMode::Id, true, chip::NullOptional); } diff --git a/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h b/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h index 44c27e9d9a852c..29e91879267357 100644 --- a/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h +++ b/zzz_generated/darwin-framework-tool/zap-generated/test/Commands.h @@ -53282,165 +53282,225 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { break; case 2: ChipLogProgress(chipTool, " ***** Test Step 2 : TH reads the FeatureMap attribute from the DUT\n"); + if (ShouldSkip(" !PCC.S.F00 && !PCC.S.F01 && !PCC.S.F02 && !PCC.S.F03 && !PCC.S.F04 && !PCC.S.F05 && !PCC.S.F06 ")) { + NextTest(); + return; + } err = TestThReadsTheFeatureMapAttributeFromTheDut_2(); break; case 3: - ChipLogProgress(chipTool, " ***** Test Step 3 : TH reads the AttributeList attribute from the DUT\n"); - err = TestThReadsTheAttributeListAttributeFromTheDut_3(); + ChipLogProgress(chipTool, " ***** Test Step 3 : Given PCC.S.F00(PRSCONST) ensure featuremap has the correct bit set\n"); + if (ShouldSkip("PCC.S.F00")) { + NextTest(); + return; + } + err = TestGivenPccsf00prsconstEnsureFeaturemapHasTheCorrectBitSet_3(); break; case 4: + ChipLogProgress(chipTool, " ***** Test Step 4 : Given PCC.S.F01(PRSCOMP) ensure featuremap has the correct bit set\n"); + if (ShouldSkip("PCC.S.F01")) { + NextTest(); + return; + } + err = TestGivenPccsf01prscompEnsureFeaturemapHasTheCorrectBitSet_4(); + break; + case 5: + ChipLogProgress(chipTool, " ***** Test Step 5 : Given PCC.S.F02(FLW) ensure featuremap has the correct bit set\n"); + if (ShouldSkip("PCC.S.F02")) { + NextTest(); + return; + } + err = TestGivenPccsf02flwEnsureFeaturemapHasTheCorrectBitSet_5(); + break; + case 6: + ChipLogProgress(chipTool, " ***** Test Step 6 : Given PCC.S.F03(SPD) ensure featuremap has the correct bit set\n"); + if (ShouldSkip("PCC.S.F03")) { + NextTest(); + return; + } + err = TestGivenPccsf03spdEnsureFeaturemapHasTheCorrectBitSet_6(); + break; + case 7: + ChipLogProgress(chipTool, " ***** Test Step 7 : Given PCC.S.F04(TEMP) ensure featuremap has the correct bit set\n"); + if (ShouldSkip("PCC.S.F04")) { + NextTest(); + return; + } + err = TestGivenPccsf04tempEnsureFeaturemapHasTheCorrectBitSet_7(); + break; + case 8: + ChipLogProgress(chipTool, " ***** Test Step 8 : Given PCC.S.F05(AUTO) ensure featuremap has the correct bit set\n"); + if (ShouldSkip("PCC.S.F05")) { + NextTest(); + return; + } + err = TestGivenPccsf05autoEnsureFeaturemapHasTheCorrectBitSet_8(); + break; + case 9: + ChipLogProgress(chipTool, " ***** Test Step 9 : Given PCC.S.F06(LOCAL) ensure featuremap has the correct bit set\n"); + if (ShouldSkip("PCC.S.F06")) { + NextTest(); + return; + } + err = TestGivenPccsf06localEnsureFeaturemapHasTheCorrectBitSet_9(); + break; + case 10: + ChipLogProgress(chipTool, " ***** Test Step 10 : TH reads the AttributeList attribute from the DUT\n"); + err = TestThReadsTheAttributeListAttributeFromTheDut_10(); + break; + case 11: ChipLogProgress(chipTool, - " ***** Test Step 4 : TH reads optional attribute(MinConstPressure) attribute in AttributeList from the DUT\n"); + " ***** Test Step 11 : TH reads optional attribute(MinConstPressure) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0003")) { NextTest(); return; } - err = TestThReadsOptionalAttributeMinConstPressureAttributeInAttributeListFromTheDut_4(); + err = TestThReadsOptionalAttributeMinConstPressureAttributeInAttributeListFromTheDut_11(); break; - case 5: + case 12: ChipLogProgress(chipTool, - " ***** Test Step 5 : TH reads optional attribute(MaxConstPressure) attribute in AttributeList from the DUT\n"); + " ***** Test Step 12 : TH reads optional attribute(MaxConstPressure) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0004")) { NextTest(); return; } - err = TestThReadsOptionalAttributeMaxConstPressureAttributeInAttributeListFromTheDut_5(); + err = TestThReadsOptionalAttributeMaxConstPressureAttributeInAttributeListFromTheDut_12(); break; - case 6: + case 13: ChipLogProgress(chipTool, - " ***** Test Step 6 : TH reads optional attribute(MinCompPressure) attribute in AttributeList from the DUT\n"); + " ***** Test Step 13 : TH reads optional attribute(MinCompPressure) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0005")) { NextTest(); return; } - err = TestThReadsOptionalAttributeMinCompPressureAttributeInAttributeListFromTheDut_6(); + err = TestThReadsOptionalAttributeMinCompPressureAttributeInAttributeListFromTheDut_13(); break; - case 7: + case 14: ChipLogProgress(chipTool, - " ***** Test Step 7 : TH reads optional attribute(MaxCompPressure) attribute in AttributeList from the DUT\n"); + " ***** Test Step 14 : TH reads optional attribute(MaxCompPressure) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0006")) { NextTest(); return; } - err = TestThReadsOptionalAttributeMaxCompPressureAttributeInAttributeListFromTheDut_7(); + err = TestThReadsOptionalAttributeMaxCompPressureAttributeInAttributeListFromTheDut_14(); break; - case 8: + case 15: ChipLogProgress(chipTool, - " ***** Test Step 8 : TH reads optional attribute(MinConstSpeed) attribute in AttributeList from the DUT\n"); + " ***** Test Step 15 : TH reads optional attribute(MinConstSpeed) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0007")) { NextTest(); return; } - err = TestThReadsOptionalAttributeMinConstSpeedAttributeInAttributeListFromTheDut_8(); + err = TestThReadsOptionalAttributeMinConstSpeedAttributeInAttributeListFromTheDut_15(); break; - case 9: + case 16: ChipLogProgress(chipTool, - " ***** Test Step 9 : TH reads optional attribute(MaxConstSpeed) attribute in AttributeList from the DUT\n"); + " ***** Test Step 16 : TH reads optional attribute(MaxConstSpeed) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0008")) { NextTest(); return; } - err = TestThReadsOptionalAttributeMaxConstSpeedAttributeInAttributeListFromTheDut_9(); + err = TestThReadsOptionalAttributeMaxConstSpeedAttributeInAttributeListFromTheDut_16(); break; - case 10: + case 17: ChipLogProgress(chipTool, - " ***** Test Step 10 : TH reads optional attribute(MinConstFlow) attribute in AttributeList from the DUT\n"); + " ***** Test Step 17 : TH reads optional attribute(MinConstFlow) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0009")) { NextTest(); return; } - err = TestThReadsOptionalAttributeMinConstFlowAttributeInAttributeListFromTheDut_10(); + err = TestThReadsOptionalAttributeMinConstFlowAttributeInAttributeListFromTheDut_17(); break; - case 11: + case 18: ChipLogProgress(chipTool, - " ***** Test Step 11 : TH reads optional attribute(MaxConstFlow) attribute in AttributeList from the DUT\n"); + " ***** Test Step 18 : TH reads optional attribute(MaxConstFlow) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A000a")) { NextTest(); return; } - err = TestThReadsOptionalAttributeMaxConstFlowAttributeInAttributeListFromTheDut_11(); + err = TestThReadsOptionalAttributeMaxConstFlowAttributeInAttributeListFromTheDut_18(); break; - case 12: + case 19: ChipLogProgress(chipTool, - " ***** Test Step 12 : TH reads optional attribute(MinConstTemp) attribute in AttributeList from the DUT\n"); + " ***** Test Step 19 : TH reads optional attribute(MinConstTemp) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A000b")) { NextTest(); return; } - err = TestThReadsOptionalAttributeMinConstTempAttributeInAttributeListFromTheDut_12(); + err = TestThReadsOptionalAttributeMinConstTempAttributeInAttributeListFromTheDut_19(); break; - case 13: + case 20: ChipLogProgress(chipTool, - " ***** Test Step 13 : TH reads optional attribute(MaxConstTemp) attribute in AttributeList from the DUT\n"); + " ***** Test Step 20 : TH reads optional attribute(MaxConstTemp) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A000c")) { NextTest(); return; } - err = TestThReadsOptionalAttributeMaxConstTempAttributeInAttributeListFromTheDut_13(); + err = TestThReadsOptionalAttributeMaxConstTempAttributeInAttributeListFromTheDut_20(); break; - case 14: + case 21: ChipLogProgress(chipTool, - " ***** Test Step 14 : TH reads optional attribute(PumpStatus) attribute in AttributeList from the DUT\n"); + " ***** Test Step 21 : TH reads optional attribute(PumpStatus) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0010")) { NextTest(); return; } - err = TestThReadsOptionalAttributePumpStatusAttributeInAttributeListFromTheDut_14(); + err = TestThReadsOptionalAttributePumpStatusAttributeInAttributeListFromTheDut_21(); break; - case 15: + case 22: ChipLogProgress( - chipTool, " ***** Test Step 15 : TH reads optional attribute(Speed) attribute in AttributeList from the DUT\n"); + chipTool, " ***** Test Step 22 : TH reads optional attribute(Speed) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0014")) { NextTest(); return; } - err = TestThReadsOptionalAttributeSpeedAttributeInAttributeListFromTheDut_15(); + err = TestThReadsOptionalAttributeSpeedAttributeInAttributeListFromTheDut_22(); break; - case 16: + case 23: ChipLogProgress(chipTool, - " ***** Test Step 16 : TH reads optional attribute(LifetimeRunningHours) attribute in AttributeList from the " + " ***** Test Step 23 : TH reads optional attribute(LifetimeRunningHours) attribute in AttributeList from the " "DUT\n"); if (ShouldSkip("PCC.S.A0015")) { NextTest(); return; } - err = TestThReadsOptionalAttributeLifetimeRunningHoursAttributeInAttributeListFromTheDut_16(); + err = TestThReadsOptionalAttributeLifetimeRunningHoursAttributeInAttributeListFromTheDut_23(); break; - case 17: + case 24: ChipLogProgress( - chipTool, " ***** Test Step 17 : TH reads optional attribute(Power) attribute in AttributeList from the DUT\n"); + chipTool, " ***** Test Step 24 : TH reads optional attribute(Power) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0016")) { NextTest(); return; } - err = TestThReadsOptionalAttributePowerAttributeInAttributeListFromTheDut_17(); + err = TestThReadsOptionalAttributePowerAttributeInAttributeListFromTheDut_24(); break; - case 18: + case 25: ChipLogProgress(chipTool, - " ***** Test Step 18 : TH reads optional attribute(LifetimeEnergyConsumed) attribute in AttributeList from the " + " ***** Test Step 25 : TH reads optional attribute(LifetimeEnergyConsumed) attribute in AttributeList from the " "DUT\n"); if (ShouldSkip("PCC.S.A0017")) { NextTest(); return; } - err = TestThReadsOptionalAttributeLifetimeEnergyConsumedAttributeInAttributeListFromTheDut_18(); + err = TestThReadsOptionalAttributeLifetimeEnergyConsumedAttributeInAttributeListFromTheDut_25(); break; - case 19: + case 26: ChipLogProgress(chipTool, - " ***** Test Step 19 : TH reads optional attribute(ControlMode) attribute in AttributeList from the DUT\n"); + " ***** Test Step 26 : TH reads optional attribute(ControlMode) attribute in AttributeList from the DUT\n"); if (ShouldSkip("PCC.S.A0021")) { NextTest(); return; } - err = TestThReadsOptionalAttributeControlModeAttributeInAttributeListFromTheDut_19(); + err = TestThReadsOptionalAttributeControlModeAttributeInAttributeListFromTheDut_26(); break; - case 20: - ChipLogProgress(chipTool, " ***** Test Step 20 : TH reads the AcceptedCommandList attribute from the DUT\n"); - err = TestThReadsTheAcceptedCommandListAttributeFromTheDut_20(); + case 27: + ChipLogProgress(chipTool, " ***** Test Step 27 : TH reads the AcceptedCommandList attribute from the DUT\n"); + err = TestThReadsTheAcceptedCommandListAttributeFromTheDut_27(); break; - case 21: - ChipLogProgress(chipTool, " ***** Test Step 21 : TH reads the GeneratedCommandList attribute from the DUT\n"); - err = TestThReadsTheGeneratedCommandListAttributeFromTheDut_21(); + case 28: + ChipLogProgress(chipTool, " ***** Test Step 28 : TH reads the GeneratedCommandList attribute from the DUT\n"); + err = TestThReadsTheGeneratedCommandListAttributeFromTheDut_28(); break; } @@ -53519,6 +53579,27 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { case 21: VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); break; + case 22: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 23: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 24: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 25: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 26: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 27: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; + case 28: + VerifyOrReturn(CheckValue("status", chip::to_underlying(status.mStatus), 0)); + break; } // Go on to the next test. @@ -53532,7 +53613,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { private: std::atomic_uint16_t mTestIndex; - const uint16_t mTestCount = 22; + const uint16_t mTestCount = 29; chip::Optional mNodeId; chip::Optional mCluster; @@ -53564,7 +53645,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { { id actualValue = value; - VerifyOrReturn(CheckValue("ClusterRevision", actualValue, 3U)); + VerifyOrReturn(CheckValue("ClusterRevision", actualValue, 4U)); } VerifyOrReturn(CheckConstraintType("clusterRevision", "int16u", "int16u")); @@ -53601,7 +53682,161 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsTheAttributeListAttributeFromTheDut_3() + CHIP_ERROR TestGivenPccsf00prsconstEnsureFeaturemapHasTheCorrectBitSet_3() + { + + MTRBaseDevice * device = GetDevice("alpha"); + commissionerNodeId = mCommissionerNodeId.ValueOr(0); + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Given PCC.S.F00(PRSCONST) ensure featuremap has the correct bit set Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestGivenPccsf01prscompEnsureFeaturemapHasTheCorrectBitSet_4() + { + + MTRBaseDevice * device = GetDevice("alpha"); + commissionerNodeId = mCommissionerNodeId.ValueOr(0); + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Given PCC.S.F01(PRSCOMP) ensure featuremap has the correct bit set Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestGivenPccsf02flwEnsureFeaturemapHasTheCorrectBitSet_5() + { + + MTRBaseDevice * device = GetDevice("alpha"); + commissionerNodeId = mCommissionerNodeId.ValueOr(0); + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Given PCC.S.F02(FLW) ensure featuremap has the correct bit set Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestGivenPccsf03spdEnsureFeaturemapHasTheCorrectBitSet_6() + { + + MTRBaseDevice * device = GetDevice("alpha"); + commissionerNodeId = mCommissionerNodeId.ValueOr(0); + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Given PCC.S.F03(SPD) ensure featuremap has the correct bit set Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestGivenPccsf04tempEnsureFeaturemapHasTheCorrectBitSet_7() + { + + MTRBaseDevice * device = GetDevice("alpha"); + commissionerNodeId = mCommissionerNodeId.ValueOr(0); + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Given PCC.S.F04(TEMP) ensure featuremap has the correct bit set Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestGivenPccsf05autoEnsureFeaturemapHasTheCorrectBitSet_8() + { + + MTRBaseDevice * device = GetDevice("alpha"); + commissionerNodeId = mCommissionerNodeId.ValueOr(0); + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Given PCC.S.F05(AUTO) ensure featuremap has the correct bit set Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestGivenPccsf06localEnsureFeaturemapHasTheCorrectBitSet_9() + { + + MTRBaseDevice * device = GetDevice("alpha"); + commissionerNodeId = mCommissionerNodeId.ValueOr(0); + __auto_type * cluster = [[MTRBaseClusterPumpConfigurationAndControl alloc] initWithDevice:device + endpointID:@(1) + queue:mCallbackQueue]; + VerifyOrReturnError(cluster != nil, CHIP_ERROR_INCORRECT_STATE); + + [cluster readAttributeFeatureMapWithCompletion:^(NSNumber * _Nullable value, NSError * _Nullable err) { + NSLog(@"Given PCC.S.F06(LOCAL) ensure featuremap has the correct bit set Error: %@", err); + + VerifyOrReturn(CheckValue("status", err ? err.code : 0, 0)); + + VerifyOrReturn(CheckConstraintType("featureMap", "bitmap32", "bitmap32")); + NextTest(); + }]; + + return CHIP_NO_ERROR; + } + + CHIP_ERROR TestThReadsTheAttributeListAttributeFromTheDut_10() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53636,7 +53871,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeMinConstPressureAttributeInAttributeListFromTheDut_4() + CHIP_ERROR TestThReadsOptionalAttributeMinConstPressureAttributeInAttributeListFromTheDut_11() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53660,7 +53895,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeMaxConstPressureAttributeInAttributeListFromTheDut_5() + CHIP_ERROR TestThReadsOptionalAttributeMaxConstPressureAttributeInAttributeListFromTheDut_12() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53684,7 +53919,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeMinCompPressureAttributeInAttributeListFromTheDut_6() + CHIP_ERROR TestThReadsOptionalAttributeMinCompPressureAttributeInAttributeListFromTheDut_13() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53708,7 +53943,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeMaxCompPressureAttributeInAttributeListFromTheDut_7() + CHIP_ERROR TestThReadsOptionalAttributeMaxCompPressureAttributeInAttributeListFromTheDut_14() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53732,7 +53967,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeMinConstSpeedAttributeInAttributeListFromTheDut_8() + CHIP_ERROR TestThReadsOptionalAttributeMinConstSpeedAttributeInAttributeListFromTheDut_15() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53756,7 +53991,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeMaxConstSpeedAttributeInAttributeListFromTheDut_9() + CHIP_ERROR TestThReadsOptionalAttributeMaxConstSpeedAttributeInAttributeListFromTheDut_16() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53780,7 +54015,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeMinConstFlowAttributeInAttributeListFromTheDut_10() + CHIP_ERROR TestThReadsOptionalAttributeMinConstFlowAttributeInAttributeListFromTheDut_17() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53804,7 +54039,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeMaxConstFlowAttributeInAttributeListFromTheDut_11() + CHIP_ERROR TestThReadsOptionalAttributeMaxConstFlowAttributeInAttributeListFromTheDut_18() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53828,7 +54063,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeMinConstTempAttributeInAttributeListFromTheDut_12() + CHIP_ERROR TestThReadsOptionalAttributeMinConstTempAttributeInAttributeListFromTheDut_19() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53852,7 +54087,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeMaxConstTempAttributeInAttributeListFromTheDut_13() + CHIP_ERROR TestThReadsOptionalAttributeMaxConstTempAttributeInAttributeListFromTheDut_20() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53876,7 +54111,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributePumpStatusAttributeInAttributeListFromTheDut_14() + CHIP_ERROR TestThReadsOptionalAttributePumpStatusAttributeInAttributeListFromTheDut_21() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53900,7 +54135,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeSpeedAttributeInAttributeListFromTheDut_15() + CHIP_ERROR TestThReadsOptionalAttributeSpeedAttributeInAttributeListFromTheDut_22() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53924,7 +54159,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeLifetimeRunningHoursAttributeInAttributeListFromTheDut_16() + CHIP_ERROR TestThReadsOptionalAttributeLifetimeRunningHoursAttributeInAttributeListFromTheDut_23() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53948,7 +54183,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributePowerAttributeInAttributeListFromTheDut_17() + CHIP_ERROR TestThReadsOptionalAttributePowerAttributeInAttributeListFromTheDut_24() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53972,7 +54207,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeLifetimeEnergyConsumedAttributeInAttributeListFromTheDut_18() + CHIP_ERROR TestThReadsOptionalAttributeLifetimeEnergyConsumedAttributeInAttributeListFromTheDut_25() { MTRBaseDevice * device = GetDevice("alpha"); @@ -53996,7 +54231,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsOptionalAttributeControlModeAttributeInAttributeListFromTheDut_19() + CHIP_ERROR TestThReadsOptionalAttributeControlModeAttributeInAttributeListFromTheDut_26() { MTRBaseDevice * device = GetDevice("alpha"); @@ -54020,7 +54255,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsTheAcceptedCommandListAttributeFromTheDut_20() + CHIP_ERROR TestThReadsTheAcceptedCommandListAttributeFromTheDut_27() { MTRBaseDevice * device = GetDevice("alpha"); @@ -54047,7 +54282,7 @@ class Test_TC_PCC_1_1 : public TestCommandBridge { return CHIP_NO_ERROR; } - CHIP_ERROR TestThReadsTheGeneratedCommandListAttributeFromTheDut_21() + CHIP_ERROR TestThReadsTheGeneratedCommandListAttributeFromTheDut_28() { MTRBaseDevice * device = GetDevice("alpha"); @@ -55116,7 +55351,7 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { break; case 3: ChipLogProgress(chipTool, " ***** Test Step 3 : TH write 1 (Minimum) to the OperationMode attribute to DUT\n"); - if (ShouldSkip("PCC.S.A0020 && PCC.M.ControlModeConstSpeed")) { + if (ShouldSkip("PCC.S.F03 && PCC.S.A0020")) { NextTest(); return; } @@ -55124,7 +55359,7 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { break; case 4: ChipLogProgress(chipTool, " ***** Test Step 4 : TH reads from the DUT the EffectiveOperationMode attribute\n"); - if (ShouldSkip("PCC.S.A0011 && PCC.M.ControlModeConstSpeed")) { + if (ShouldSkip("PCC.S.F03 && PCC.S.A0011")) { NextTest(); return; } @@ -55133,7 +55368,7 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { case 5: ChipLogProgress( chipTool, " ***** Test Step 5 : TH write 2 (Maximum) to the OperationMode attribute to DUT one at a time.\n"); - if (ShouldSkip("PCC.S.A0020 && PCC.M.ControlModeConstSpeed")) { + if (ShouldSkip("PCC.S.F03 && PCC.S.A0020")) { NextTest(); return; } @@ -55141,7 +55376,7 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { break; case 6: ChipLogProgress(chipTool, " ***** Test Step 6 : TH reads from the DUT the EffectiveOperationMode attribute\n"); - if (ShouldSkip("PCC.S.A0011 && PCC.M.ControlModeConstSpeed")) { + if (ShouldSkip("PCC.S.F03 && PCC.S.A0011")) { NextTest(); return; } @@ -55149,7 +55384,7 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { break; case 7: ChipLogProgress(chipTool, " ***** Test Step 7 : TH write 3 (Local) to the OperationMode attribute to DUT\n"); - if (ShouldSkip("PCC.S.A0020")) { + if (ShouldSkip("PCC.S.F06 && PCC.S.A0020")) { NextTest(); return; } @@ -55157,7 +55392,7 @@ class Test_TC_PCC_2_2 : public TestCommandBridge { break; case 8: ChipLogProgress(chipTool, " ***** Test Step 8 : TH reads from the DUT the EffectiveOperationMode attribute\n"); - if (ShouldSkip("PCC.S.A0011")) { + if (ShouldSkip("PCC.S.F06 && PCC.S.A0011")) { NextTest(); return; } @@ -55499,7 +55734,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 3: ChipLogProgress(chipTool, " ***** Test Step 3 : Write 0 to the ControlMode attribute to DUT\n"); - if (ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeConstSpeed")) { + if (ShouldSkip("PCC.S.F03 && PCC.S.A0021")) { NextTest(); return; } @@ -55507,7 +55742,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 4: ChipLogProgress(chipTool, " ***** Test Step 4 : Reads the attribute: EffectiveControlMode\n"); - if (ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeConstSpeed")) { + if (ShouldSkip("PCC.S.F03 && PCC.S.A0012")) { NextTest(); return; } @@ -55515,7 +55750,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 5: ChipLogProgress(chipTool, " ***** Test Step 5 : Write 1 to the ControlMode attribute to DUT\n"); - if (ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeConstPressure")) { + if (ShouldSkip("PCC.S.F00 && PCC.S.A0021")) { NextTest(); return; } @@ -55523,7 +55758,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 6: ChipLogProgress(chipTool, " ***** Test Step 6 : Reads the attribute: EffectiveControlMode\n"); - if (ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeConstPressure")) { + if (ShouldSkip("PCC.S.F00 && PCC.S.A0012")) { NextTest(); return; } @@ -55531,7 +55766,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 7: ChipLogProgress(chipTool, " ***** Test Step 7 : Write 2 to the ControlMode attribute to DUT\n"); - if (ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeCompPressure")) { + if (ShouldSkip("PCC.S.F01 && PCC.S.A0021")) { NextTest(); return; } @@ -55539,7 +55774,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 8: ChipLogProgress(chipTool, " ***** Test Step 8 : Reads the attribute: EffectiveControlMode\n"); - if (ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeCompPressure")) { + if (ShouldSkip("PCC.S.F01 && PCC.S.A0012")) { NextTest(); return; } @@ -55547,7 +55782,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 9: ChipLogProgress(chipTool, " ***** Test Step 9 : Write 3 to the ControlMode attribute to DUT\n"); - if (ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeConstFlow")) { + if (ShouldSkip("PCC.S.F02 && PCC.S.A0021")) { NextTest(); return; } @@ -55555,7 +55790,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 10: ChipLogProgress(chipTool, " ***** Test Step 10 : Reads the attribute: EffectiveControlMode\n"); - if (ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeConstFlow")) { + if (ShouldSkip("PCC.S.F02 && PCC.S.A0012")) { NextTest(); return; } @@ -55563,7 +55798,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 11: ChipLogProgress(chipTool, " ***** Test Step 11 : Write 5 to the ControlMode attribute to DUT\n"); - if (ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeConstTemp")) { + if (ShouldSkip("PCC.S.F04 && PCC.S.A0021")) { NextTest(); return; } @@ -55571,7 +55806,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 12: ChipLogProgress(chipTool, " ***** Test Step 12 : Reads the attribute: EffectiveControlMode\n"); - if (ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeConstTemp")) { + if (ShouldSkip("PCC.S.F04 && PCC.S.A0012")) { NextTest(); return; } @@ -55579,7 +55814,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 13: ChipLogProgress(chipTool, " ***** Test Step 13 : Write 7 to the ControlMode attribute to DUT\n"); - if (ShouldSkip("PCC.S.A0021 && PCC.M.ControlModeAuto")) { + if (ShouldSkip("PCC.S.F05 && PCC.S.A0021")) { NextTest(); return; } @@ -55587,7 +55822,7 @@ class Test_TC_PCC_2_3 : public TestCommandBridge { break; case 14: ChipLogProgress(chipTool, " ***** Test Step 14 : Reads the attribute: EffectiveControlMode\n"); - if (ShouldSkip("PCC.S.A0012 && PCC.M.ControlModeAuto")) { + if (ShouldSkip("PCC.S.F02 && PCC.S.A0012")) { NextTest(); return; }