From 1567113430cb571474950e83fd79939ab2f5826a Mon Sep 17 00:00:00 2001 From: Boris Zbarsky Date: Thu, 25 May 2023 00:55:00 -0400 Subject: [PATCH] Mark the non-volatile Color Control attributes as NVM in some examples. (#26808) Fixes https://github.com/project-chip/connectedhomeip/issues/26793 --- .../all-clusters-app.matter | 22 +++++------ .../all-clusters-common/all-clusters-app.zap | 25 ++++++------ .../lighting-common/lighting-app.matter | 24 ++++++------ .../lighting-common/lighting-app.zap | 39 ++++++++++--------- 4 files changed, 56 insertions(+), 54 deletions(-) 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 efb3595a682a07..f688bb36d8acc9 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 @@ -5293,14 +5293,14 @@ endpoint 1 { } server cluster ColorControl { - ram attribute currentHue default = 0x00; - ram attribute currentSaturation default = 0x00; + persist attribute currentHue default = 0x00; + persist attribute currentSaturation default = 0x00; ram attribute remainingTime default = 0x0000; - ram attribute currentX default = 0x616B; - ram attribute currentY default = 0x607D; + persist attribute currentX default = 0x616B; + persist attribute currentY default = 0x607D; ram attribute driftCompensation; ram attribute compensationText; - ram attribute colorTemperatureMireds default = 0x00FA; + persist attribute colorTemperatureMireds default = 0x00FA; ram attribute colorMode default = 0x01; ram attribute options default = 0x00; ram attribute numberOfPrimaries; @@ -5333,18 +5333,18 @@ endpoint 1 { ram attribute colorPointBX; ram attribute colorPointBY; ram attribute colorPointBIntensity; - ram attribute enhancedCurrentHue default = 0x0000; - ram attribute enhancedColorMode default = 0x01; - ram attribute colorLoopActive default = 0x00; - ram attribute colorLoopDirection default = 0x00; - ram attribute colorLoopTime default = 0x0019; + persist attribute enhancedCurrentHue default = 0x0000; + persist attribute enhancedColorMode default = 0x01; + persist attribute colorLoopActive default = 0x00; + persist attribute colorLoopDirection default = 0x00; + persist attribute colorLoopTime default = 0x0019; ram attribute colorLoopStartEnhancedHue default = 0x2300; ram attribute colorLoopStoredEnhancedHue default = 0x0000; ram attribute colorCapabilities default = 0x1F; ram attribute colorTempPhysicalMinMireds default = 0x0000; ram attribute colorTempPhysicalMaxMireds default = 0xFEFF; ram attribute coupleColorTempToLevelMinMireds; - ram attribute startUpColorTemperatureMireds; + persist attribute startUpColorTemperatureMireds; ram attribute featureMap default = 0x1F; ram attribute clusterRevision default = 5; } 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 c8145f2aed189a..0b8df8bdcf80ab 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 @@ -16083,7 +16083,7 @@ "side": "server", "type": "int8u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x00", @@ -16099,7 +16099,7 @@ "side": "server", "type": "int8u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x00", @@ -16131,7 +16131,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x616B", @@ -16147,7 +16147,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x607D", @@ -16195,7 +16195,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x00FA", @@ -16723,7 +16723,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x0000", @@ -16739,7 +16739,7 @@ "side": "server", "type": "enum8", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x01", @@ -16755,7 +16755,7 @@ "side": "server", "type": "int8u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x00", @@ -16771,7 +16771,7 @@ "side": "server", "type": "int8u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x00", @@ -16787,7 +16787,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x0019", @@ -16899,7 +16899,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "", @@ -25580,5 +25580,6 @@ "endpointVersion": 1, "deviceIdentifier": 61442 } - ] + ], + "log": [] } \ No newline at end of file diff --git a/examples/lighting-app/lighting-common/lighting-app.matter b/examples/lighting-app/lighting-common/lighting-app.matter index c78228137c6bb1..be9db4405ba231 100644 --- a/examples/lighting-app/lighting-common/lighting-app.matter +++ b/examples/lighting-app/lighting-common/lighting-app.matter @@ -2285,27 +2285,27 @@ endpoint 1 { } server cluster ColorControl { - ram attribute currentHue default = 0x00; - ram attribute currentSaturation default = 0x00; + persist attribute currentHue default = 0x00; + persist attribute currentSaturation default = 0x00; ram attribute remainingTime default = 0x0000; - ram attribute currentX default = 0x616B; - ram attribute currentY default = 0x607D; - ram attribute colorTemperatureMireds default = 0x00FA; - ram attribute colorMode default = 0x01; + persist attribute currentX default = 0x616B; + persist attribute currentY default = 0x607D; + persist attribute colorTemperatureMireds default = 0x00FA; + persist attribute colorMode default = 0x01; ram attribute options default = 0x00; ram attribute numberOfPrimaries; - ram attribute enhancedCurrentHue default = 0x0000; - ram attribute enhancedColorMode default = 0x01; - ram attribute colorLoopActive default = 0x00; - ram attribute colorLoopDirection default = 0x00; - ram attribute colorLoopTime default = 0x0019; + persist attribute enhancedCurrentHue default = 0x0000; + persist attribute enhancedColorMode default = 0x01; + persist attribute colorLoopActive default = 0x00; + persist attribute colorLoopDirection default = 0x00; + persist attribute colorLoopTime default = 0x0019; ram attribute colorLoopStartEnhancedHue default = 0x2300; ram attribute colorLoopStoredEnhancedHue default = 0x0000; ram attribute colorCapabilities default = 0x1F; ram attribute colorTempPhysicalMinMireds default = 0x0000; ram attribute colorTempPhysicalMaxMireds default = 0xFEFF; ram attribute coupleColorTempToLevelMinMireds; - ram attribute startUpColorTemperatureMireds; + persist attribute startUpColorTemperatureMireds; ram attribute featureMap default = 0x1F; ram attribute clusterRevision default = 5; } diff --git a/examples/lighting-app/lighting-common/lighting-app.zap b/examples/lighting-app/lighting-common/lighting-app.zap index 9d02ec6206d9a6..b327a0d67bdce1 100644 --- a/examples/lighting-app/lighting-common/lighting-app.zap +++ b/examples/lighting-app/lighting-common/lighting-app.zap @@ -16,6 +16,12 @@ } ], "package": [ + { + "pathRelativity": "relativeToZap", + "path": "../../../src/app/zap-templates/app-templates.json", + "type": "gen-templates-json", + "version": "chip-v1" + }, { "pathRelativity": "relativeToZap", "path": "../../../src/app/zap-templates/zcl/zcl.json", @@ -23,12 +29,6 @@ "category": "matter", "version": 1, "description": "Matter SDK ZCL data" - }, - { - "pathRelativity": "relativeToZap", - "path": "../../../src/app/zap-templates/app-templates.json", - "type": "gen-templates-json", - "version": "chip-v1" } ], "endpointTypes": [ @@ -7296,7 +7296,7 @@ "side": "server", "type": "int8u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x00", @@ -7312,7 +7312,7 @@ "side": "server", "type": "int8u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x00", @@ -7344,7 +7344,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x616B", @@ -7360,7 +7360,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x607D", @@ -7408,7 +7408,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x00FA", @@ -7424,7 +7424,7 @@ "side": "server", "type": "enum8", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x01", @@ -7936,7 +7936,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x0000", @@ -7952,7 +7952,7 @@ "side": "server", "type": "enum8", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x01", @@ -7968,7 +7968,7 @@ "side": "server", "type": "int8u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x00", @@ -7984,7 +7984,7 @@ "side": "server", "type": "int8u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x00", @@ -8000,7 +8000,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "0x0019", @@ -8112,7 +8112,7 @@ "side": "server", "type": "int16u", "included": 1, - "storageOption": "RAM", + "storageOption": "NVM", "singleton": 0, "bounded": 0, "defaultValue": "", @@ -8341,5 +8341,6 @@ "endpointVersion": 1, "deviceIdentifier": 257 } - ] + ], + "log": [] } \ No newline at end of file