diff --git a/src/app/zap-templates/zcl/data-model/silabs/ha.xml b/src/app/zap-templates/zcl/data-model/silabs/ha.xml
index 2555a29c8ec10e..58fe67cbca289a 100644
--- a/src/app/zap-templates/zcl/data-model/silabs/ha.xml
+++ b/src/app/zap-templates/zcl/data-model/silabs/ha.xml
@@ -406,23 +406,21 @@ limitations under the License.
BALLAST_CONFIGURATION_CLUSTER
true
true
-
- physical min level
- physical max level
- ballast status
- min level
- max level
- power on level
- power on fade time
- intrinsic ballast factor
- ballast factor adjustment
- lamp quality
- lamp type
- lamp manufacturer
- lamp rated hours
- lamp burn hours
- lamp alarm mode
- lamp burn hours trip point
+
+ PhysicalMinLevel
+ PhysicalMaxLevel
+ BallastStatus
+ MinLevel
+ MaxLevel
+ IntrinsicBalanceFactor
+ BallastFactorAdjustment
+ LampQuantity
+ LampType
+ LampManufacturer
+ LampRatedHours
+ LampBurnHours
+ LampAlarmMode
+ LampBurnHoursTripPoint
Occupancy Sensing
diff --git a/src/app/zap_cluster_list.py b/src/app/zap_cluster_list.py
index 1adf32c657f8ef..ce89b6f150fc4e 100755
--- a/src/app/zap_cluster_list.py
+++ b/src/app/zap_cluster_list.py
@@ -16,6 +16,7 @@
'APPLICATION_BASIC_CLUSTER': ['application-basic-server'],
'APPLICATION_LAUNCHER_CLUSTER': ['application-launcher-server'],
'AUDIO_OUTPUT_CLUSTER': ['audio-output-server'],
+ 'BALLAST_CONFIGURATION_CLUSTER': [],
'BARRIER_CONTROL_CLUSTER': ['barrier-control-server'],
'BASIC_CLUSTER': ['basic'],
'BINARY_INPUT_BASIC_CLUSTER': [],
@@ -99,6 +100,7 @@
'APPLICATION_BASIC_CLUSTER': [],
'APPLICATION_LAUNCHER_CLUSTER': [],
'AUDIO_OUTPUT_CLUSTER': [],
+ 'BALLAST_CONFIGURATION_CLUSTER': [],
'BARRIER_CONTROL_CLUSTER': [],
'BASIC_CLUSTER': [],
'BINARY_INPUT_BASIC_CLUSTER': [],
diff --git a/src/controller/data_model/controller-clusters.matter b/src/controller/data_model/controller-clusters.matter
index 95eb8b0fb1c16b..7ca5b0106df4fd 100644
--- a/src/controller/data_model/controller-clusters.matter
+++ b/src/controller/data_model/controller-clusters.matter
@@ -3336,6 +3336,28 @@ client cluster ColorControl = 768 {
command StepColorTemperature(StepColorTemperatureRequest): DefaultSuccess = 76;
}
+client cluster BallastConfiguration = 769 {
+ readonly attribute int8u physicalMinLevel = 0;
+ readonly attribute int8u physicalMaxLevel = 1;
+ readonly attribute bitmap8 ballastStatus = 2;
+ attribute int8u minLevel = 16;
+ attribute int8u maxLevel = 17;
+ attribute nullable int8u intrinsicBalanceFactor = 20;
+ attribute nullable int8u ballastFactorAdjustment = 21;
+ readonly attribute int8u lampQuantity = 32;
+ attribute char_string<16> lampType = 48;
+ attribute char_string<16> lampManufacturer = 49;
+ attribute nullable int24u lampRatedHours = 50;
+ attribute nullable int24u lampBurnHours = 51;
+ attribute bitmap8 lampAlarmMode = 52;
+ attribute nullable int24u lampBurnHoursTripPoint = 53;
+ readonly attribute command_id generatedCommandList[] = 65528;
+ readonly attribute command_id acceptedCommandList[] = 65529;
+ readonly attribute attrib_id attributeList[] = 65531;
+ readonly attribute bitmap32 featureMap = 65532;
+ readonly attribute int16u clusterRevision = 65533;
+}
+
client cluster IlluminanceMeasurement = 1024 {
enum LightSensorType : ENUM8 {
kPhotodiode = 0;
@@ -4393,6 +4415,7 @@ endpoint 1 {
binding cluster FanControl;
binding cluster ThermostatUserInterfaceConfiguration;
binding cluster ColorControl;
+ binding cluster BallastConfiguration;
binding cluster IlluminanceMeasurement;
binding cluster TemperatureMeasurement;
binding cluster PressureMeasurement;
diff --git a/src/controller/data_model/controller-clusters.zap b/src/controller/data_model/controller-clusters.zap
index 7e3e1f0c5080ad..6439260f235608 100644
--- a/src/controller/data_model/controller-clusters.zap
+++ b/src/controller/data_model/controller-clusters.zap
@@ -1,5 +1,5 @@
{
- "featureLevel": 72,
+ "featureLevel": 75,
"creator": "zap",
"keyValuePairs": [
{
@@ -19,14 +19,14 @@
{
"pathRelativity": "relativeToZap",
"path": "../../app/zap-templates/zcl/zcl.json",
- "version": "ZCL Test Data",
- "type": "zcl-properties"
+ "type": "zcl-properties",
+ "version": "ZCL Test Data"
},
{
"pathRelativity": "relativeToZap",
"path": "../../app/zap-templates/app-templates.json",
- "version": "chip-v1",
- "type": "gen-templates-json"
+ "type": "gen-templates-json",
+ "version": "chip-v1"
}
],
"endpointTypes": [
@@ -13561,6 +13561,364 @@
}
]
},
+ {
+ "name": "Ballast Configuration",
+ "code": 769,
+ "mfgCode": null,
+ "define": "BALLAST_CONFIGURATION_CLUSTER",
+ "side": "client",
+ "enabled": 1,
+ "commands": [],
+ "attributes": [
+ {
+ "name": "FeatureMap",
+ "code": 65532,
+ "mfgCode": null,
+ "side": "client",
+ "type": "bitmap32",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ClusterRevision",
+ "code": 65533,
+ "mfgCode": null,
+ "side": "client",
+ "type": "int16u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "4",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ }
+ ]
+ },
+ {
+ "name": "Ballast Configuration",
+ "code": 769,
+ "mfgCode": null,
+ "define": "BALLAST_CONFIGURATION_CLUSTER",
+ "side": "server",
+ "enabled": 0,
+ "commands": [],
+ "attributes": [
+ {
+ "name": "PhysicalMinLevel",
+ "code": 0,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0x01",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "PhysicalMaxLevel",
+ "code": 1,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0xFE",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "BallastStatus",
+ "code": 2,
+ "mfgCode": null,
+ "side": "server",
+ "type": "bitmap8",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0x00",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "MinLevel",
+ "code": 16,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0x01",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "MaxLevel",
+ "code": 17,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0xFE",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "IntrinsicBalanceFactor",
+ "code": 20,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "BallastFactorAdjustment",
+ "code": 21,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0xFE",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "LampQuantity",
+ "code": 32,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int8u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "LampType",
+ "code": 48,
+ "mfgCode": null,
+ "side": "server",
+ "type": "char_string",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "LampManufacturer",
+ "code": 49,
+ "mfgCode": null,
+ "side": "server",
+ "type": "char_string",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "LampRatedHours",
+ "code": 50,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int24u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0xFFFFFF",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "LampBurnHours",
+ "code": 51,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int24u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0x000000",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "LampAlarmMode",
+ "code": 52,
+ "mfgCode": null,
+ "side": "server",
+ "type": "bitmap8",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0x00",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "LampBurnHoursTripPoint",
+ "code": 53,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int24u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0xFFFFFF",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "GeneratedCommandList",
+ "code": 65528,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "AcceptedCommandList",
+ "code": 65529,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "AttributeList",
+ "code": 65531,
+ "mfgCode": null,
+ "side": "server",
+ "type": "array",
+ "included": 1,
+ "storageOption": "External",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "FeatureMap",
+ "code": 65532,
+ "mfgCode": null,
+ "side": "server",
+ "type": "bitmap32",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "0",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ },
+ {
+ "name": "ClusterRevision",
+ "code": 65533,
+ "mfgCode": null,
+ "side": "server",
+ "type": "int16u",
+ "included": 1,
+ "storageOption": "RAM",
+ "singleton": 0,
+ "bounded": 0,
+ "defaultValue": "4",
+ "reportable": 1,
+ "minInterval": 1,
+ "maxInterval": 65534,
+ "reportableChange": 0
+ }
+ ]
+ },
{
"name": "Illuminance Measurement",
"code": 1024,
diff --git a/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp b/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp
index bcfb522f306a5c..af18e87a079d4f 100644
--- a/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp
+++ b/src/controller/java/zap-generated/CHIPAttributeTLVValueDecoder.cpp
@@ -12963,6 +12963,357 @@ jobject DecodeAttributeValue(const app::ConcreteAttributePath & aPath, TLV::TLVR
}
break;
}
+ case app::Clusters::BallastConfiguration::Id: {
+ using namespace app::Clusters::BallastConfiguration;
+ switch (aPath.mAttributeId)
+ {
+ case Attributes::PhysicalMinLevel::Id: {
+ using TypeInfo = Attributes::PhysicalMinLevel::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ std::string valueClassName = "java/lang/Integer";
+ std::string valueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue, value);
+ return value;
+ }
+ case Attributes::PhysicalMaxLevel::Id: {
+ using TypeInfo = Attributes::PhysicalMaxLevel::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ std::string valueClassName = "java/lang/Integer";
+ std::string valueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue, value);
+ return value;
+ }
+ case Attributes::BallastStatus::Id: {
+ using TypeInfo = Attributes::BallastStatus::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ std::string valueClassName = "java/lang/Integer";
+ std::string valueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue, value);
+ return value;
+ }
+ case Attributes::MinLevel::Id: {
+ using TypeInfo = Attributes::MinLevel::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ std::string valueClassName = "java/lang/Integer";
+ std::string valueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue, value);
+ return value;
+ }
+ case Attributes::MaxLevel::Id: {
+ using TypeInfo = Attributes::MaxLevel::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ std::string valueClassName = "java/lang/Integer";
+ std::string valueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue, value);
+ return value;
+ }
+ case Attributes::IntrinsicBalanceFactor::Id: {
+ using TypeInfo = Attributes::IntrinsicBalanceFactor::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ if (cppValue.IsNull())
+ {
+ value = nullptr;
+ }
+ else
+ {
+ std::string valueClassName = "java/lang/Integer";
+ std::string valueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue.Value(), value);
+ }
+ return value;
+ }
+ case Attributes::BallastFactorAdjustment::Id: {
+ using TypeInfo = Attributes::BallastFactorAdjustment::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ if (cppValue.IsNull())
+ {
+ value = nullptr;
+ }
+ else
+ {
+ std::string valueClassName = "java/lang/Integer";
+ std::string valueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue.Value(), value);
+ }
+ return value;
+ }
+ case Attributes::LampQuantity::Id: {
+ using TypeInfo = Attributes::LampQuantity::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ std::string valueClassName = "java/lang/Integer";
+ std::string valueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue, value);
+ return value;
+ }
+ case Attributes::LampType::Id: {
+ using TypeInfo = Attributes::LampType::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ value = env->NewStringUTF(std::string(cppValue.data(), cppValue.size()).c_str());
+ return value;
+ }
+ case Attributes::LampManufacturer::Id: {
+ using TypeInfo = Attributes::LampManufacturer::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ value = env->NewStringUTF(std::string(cppValue.data(), cppValue.size()).c_str());
+ return value;
+ }
+ case Attributes::LampRatedHours::Id: {
+ using TypeInfo = Attributes::LampRatedHours::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ if (cppValue.IsNull())
+ {
+ value = nullptr;
+ }
+ else
+ {
+ std::string valueClassName = "java/lang/Long";
+ std::string valueCtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue.Value(), value);
+ }
+ return value;
+ }
+ case Attributes::LampBurnHours::Id: {
+ using TypeInfo = Attributes::LampBurnHours::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ if (cppValue.IsNull())
+ {
+ value = nullptr;
+ }
+ else
+ {
+ std::string valueClassName = "java/lang/Long";
+ std::string valueCtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue.Value(), value);
+ }
+ return value;
+ }
+ case Attributes::LampAlarmMode::Id: {
+ using TypeInfo = Attributes::LampAlarmMode::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ std::string valueClassName = "java/lang/Integer";
+ std::string valueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue, value);
+ return value;
+ }
+ case Attributes::LampBurnHoursTripPoint::Id: {
+ using TypeInfo = Attributes::LampBurnHoursTripPoint::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ if (cppValue.IsNull())
+ {
+ value = nullptr;
+ }
+ else
+ {
+ std::string valueClassName = "java/lang/Long";
+ std::string valueCtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue.Value(), value);
+ }
+ return value;
+ }
+ case Attributes::GeneratedCommandList::Id: {
+ using TypeInfo = Attributes::GeneratedCommandList::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ chip::JniReferences::GetInstance().CreateArrayList(value);
+
+ auto iter_value_0 = cppValue.begin();
+ while (iter_value_0.Next())
+ {
+ auto & entry_0 = iter_value_0.GetValue();
+ jobject newElement_0;
+ std::string newElement_0ClassName = "java/lang/Long";
+ std::string newElement_0CtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(
+ newElement_0ClassName.c_str(), newElement_0CtorSignature.c_str(), entry_0, newElement_0);
+ chip::JniReferences::GetInstance().AddToList(value, newElement_0);
+ }
+ return value;
+ }
+ case Attributes::AcceptedCommandList::Id: {
+ using TypeInfo = Attributes::AcceptedCommandList::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ chip::JniReferences::GetInstance().CreateArrayList(value);
+
+ auto iter_value_0 = cppValue.begin();
+ while (iter_value_0.Next())
+ {
+ auto & entry_0 = iter_value_0.GetValue();
+ jobject newElement_0;
+ std::string newElement_0ClassName = "java/lang/Long";
+ std::string newElement_0CtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(
+ newElement_0ClassName.c_str(), newElement_0CtorSignature.c_str(), entry_0, newElement_0);
+ chip::JniReferences::GetInstance().AddToList(value, newElement_0);
+ }
+ return value;
+ }
+ case Attributes::AttributeList::Id: {
+ using TypeInfo = Attributes::AttributeList::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ chip::JniReferences::GetInstance().CreateArrayList(value);
+
+ auto iter_value_0 = cppValue.begin();
+ while (iter_value_0.Next())
+ {
+ auto & entry_0 = iter_value_0.GetValue();
+ jobject newElement_0;
+ std::string newElement_0ClassName = "java/lang/Long";
+ std::string newElement_0CtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(
+ newElement_0ClassName.c_str(), newElement_0CtorSignature.c_str(), entry_0, newElement_0);
+ chip::JniReferences::GetInstance().AddToList(value, newElement_0);
+ }
+ return value;
+ }
+ case Attributes::FeatureMap::Id: {
+ using TypeInfo = Attributes::FeatureMap::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ std::string valueClassName = "java/lang/Long";
+ std::string valueCtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue, value);
+ return value;
+ }
+ case Attributes::ClusterRevision::Id: {
+ using TypeInfo = Attributes::ClusterRevision::TypeInfo;
+ TypeInfo::DecodableType cppValue;
+ *aError = app::DataModel::Decode(aReader, cppValue);
+ if (*aError != CHIP_NO_ERROR)
+ {
+ return nullptr;
+ }
+ jobject value;
+ std::string valueClassName = "java/lang/Integer";
+ std::string valueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(valueClassName.c_str(), valueCtorSignature.c_str(),
+ cppValue, value);
+ return value;
+ }
+ default:
+ *aError = CHIP_ERROR_IM_MALFORMED_ATTRIBUTE_PATH_IB;
+ break;
+ }
+ break;
+ }
case app::Clusters::IlluminanceMeasurement::Id: {
using namespace app::Clusters::IlluminanceMeasurement;
switch (aPath.mAttributeId)
diff --git a/src/controller/java/zap-generated/CHIPCallbackTypes.h b/src/controller/java/zap-generated/CHIPCallbackTypes.h
index 87ce0b4174277c..a4a6ec83cc7b51 100644
--- a/src/controller/java/zap-generated/CHIPCallbackTypes.h
+++ b/src/controller/java/zap-generated/CHIPCallbackTypes.h
@@ -1383,6 +1383,45 @@ typedef void (*CHIPColorControlClusterFeatureMapAttributeCallbackType)(
typedef void (*CHIPColorControlClusterClusterRevisionAttributeCallbackType)(
void *, chip::app::Clusters::ColorControl::Attributes::ClusterRevision::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterPhysicalMinLevelAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::PhysicalMinLevel::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterPhysicalMaxLevelAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::PhysicalMaxLevel::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterBallastStatusAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::BallastStatus::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterMinLevelAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::MinLevel::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterMaxLevelAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::MaxLevel::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterIntrinsicBalanceFactorAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::IntrinsicBalanceFactor::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterBallastFactorAdjustmentAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::BallastFactorAdjustment::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterLampQuantityAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::LampQuantity::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterLampTypeAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::LampType::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterLampManufacturerAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::LampManufacturer::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterLampRatedHoursAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::LampRatedHours::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterLampBurnHoursAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::LampBurnHours::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterLampAlarmModeAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::LampAlarmMode::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterLampBurnHoursTripPointAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::LampBurnHoursTripPoint::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterGeneratedCommandListAttributeCallbackType)(
+ void *, const chip::app::Clusters::BallastConfiguration::Attributes::GeneratedCommandList::TypeInfo::DecodableType &);
+typedef void (*CHIPBallastConfigurationClusterAcceptedCommandListAttributeCallbackType)(
+ void *, const chip::app::Clusters::BallastConfiguration::Attributes::AcceptedCommandList::TypeInfo::DecodableType &);
+typedef void (*CHIPBallastConfigurationClusterAttributeListAttributeCallbackType)(
+ void *, const chip::app::Clusters::BallastConfiguration::Attributes::AttributeList::TypeInfo::DecodableType &);
+typedef void (*CHIPBallastConfigurationClusterFeatureMapAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::FeatureMap::TypeInfo::DecodableArgType);
+typedef void (*CHIPBallastConfigurationClusterClusterRevisionAttributeCallbackType)(
+ void *, chip::app::Clusters::BallastConfiguration::Attributes::ClusterRevision::TypeInfo::DecodableArgType);
+
typedef void (*CHIPIlluminanceMeasurementClusterMeasuredValueAttributeCallbackType)(
void *, chip::app::Clusters::IlluminanceMeasurement::Attributes::MeasuredValue::TypeInfo::DecodableArgType);
typedef void (*CHIPIlluminanceMeasurementClusterMinMeasuredValueAttributeCallbackType)(
diff --git a/src/controller/java/zap-generated/CHIPClustersWrite-JNI.cpp b/src/controller/java/zap-generated/CHIPClustersWrite-JNI.cpp
index a8c3724dea95d4..4612f4b7b96bae 100644
--- a/src/controller/java/zap-generated/CHIPClustersWrite-JNI.cpp
+++ b/src/controller/java/zap-generated/CHIPClustersWrite-JNI.cpp
@@ -4529,6 +4529,566 @@ JNI_METHOD(void, ColorControlCluster, writeStartUpColorTemperatureMiredsAttribut
onFailure.release();
}
+JNI_METHOD(void, BallastConfigurationCluster, writeMinLevelAttribute)
+(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jobject value, jobject timedWriteTimeoutMs)
+{
+ chip::DeviceLayer::StackLock lock;
+ ListFreer listFreer;
+ using TypeInfo = chip::app::Clusters::BallastConfiguration::Attributes::MinLevel::TypeInfo;
+ TypeInfo::Type cppValue;
+
+ std::vector> cleanupByteArrays;
+ std::vector> cleanupStrings;
+
+ cppValue =
+ static_cast>(chip::JniReferences::GetInstance().IntegerToPrimitive(value));
+
+ std::unique_ptr onSuccess(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onSuccess.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native success callback", CHIP_ERROR_NO_MEMORY));
+
+ std::unique_ptr onFailure(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onFailure.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native failure callback", CHIP_ERROR_NO_MEMORY));
+
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ BallastConfigurationCluster * cppCluster = reinterpret_cast(clusterPtr);
+ VerifyOrReturn(cppCluster != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Could not get native cluster", CHIP_ERROR_INCORRECT_STATE));
+
+ auto successFn = chip::Callback::Callback::FromCancelable(onSuccess->Cancel());
+ auto failureFn = chip::Callback::Callback::FromCancelable(onFailure->Cancel());
+
+ if (timedWriteTimeoutMs == nullptr)
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall);
+ }
+ else
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall,
+ chip::JniReferences::GetInstance().IntegerToPrimitive(timedWriteTimeoutMs));
+ }
+ VerifyOrReturn(
+ err == CHIP_NO_ERROR,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(env, callback, "Error writing attribute", err));
+
+ onSuccess.release();
+ onFailure.release();
+}
+
+JNI_METHOD(void, BallastConfigurationCluster, writeMaxLevelAttribute)
+(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jobject value, jobject timedWriteTimeoutMs)
+{
+ chip::DeviceLayer::StackLock lock;
+ ListFreer listFreer;
+ using TypeInfo = chip::app::Clusters::BallastConfiguration::Attributes::MaxLevel::TypeInfo;
+ TypeInfo::Type cppValue;
+
+ std::vector> cleanupByteArrays;
+ std::vector> cleanupStrings;
+
+ cppValue =
+ static_cast>(chip::JniReferences::GetInstance().IntegerToPrimitive(value));
+
+ std::unique_ptr onSuccess(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onSuccess.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native success callback", CHIP_ERROR_NO_MEMORY));
+
+ std::unique_ptr onFailure(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onFailure.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native failure callback", CHIP_ERROR_NO_MEMORY));
+
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ BallastConfigurationCluster * cppCluster = reinterpret_cast(clusterPtr);
+ VerifyOrReturn(cppCluster != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Could not get native cluster", CHIP_ERROR_INCORRECT_STATE));
+
+ auto successFn = chip::Callback::Callback::FromCancelable(onSuccess->Cancel());
+ auto failureFn = chip::Callback::Callback::FromCancelable(onFailure->Cancel());
+
+ if (timedWriteTimeoutMs == nullptr)
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall);
+ }
+ else
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall,
+ chip::JniReferences::GetInstance().IntegerToPrimitive(timedWriteTimeoutMs));
+ }
+ VerifyOrReturn(
+ err == CHIP_NO_ERROR,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(env, callback, "Error writing attribute", err));
+
+ onSuccess.release();
+ onFailure.release();
+}
+
+JNI_METHOD(void, BallastConfigurationCluster, writeIntrinsicBalanceFactorAttribute)
+(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jobject value, jobject timedWriteTimeoutMs)
+{
+ chip::DeviceLayer::StackLock lock;
+ ListFreer listFreer;
+ using TypeInfo = chip::app::Clusters::BallastConfiguration::Attributes::IntrinsicBalanceFactor::TypeInfo;
+ TypeInfo::Type cppValue;
+
+ std::vector> cleanupByteArrays;
+ std::vector> cleanupStrings;
+
+ if (value == nullptr)
+ {
+ cppValue.SetNull();
+ }
+ else
+ {
+ auto & nonNullValue_0 = cppValue.SetNonNull();
+ nonNullValue_0 = static_cast>(
+ chip::JniReferences::GetInstance().IntegerToPrimitive(value));
+ }
+
+ std::unique_ptr onSuccess(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onSuccess.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native success callback", CHIP_ERROR_NO_MEMORY));
+
+ std::unique_ptr onFailure(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onFailure.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native failure callback", CHIP_ERROR_NO_MEMORY));
+
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ BallastConfigurationCluster * cppCluster = reinterpret_cast(clusterPtr);
+ VerifyOrReturn(cppCluster != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Could not get native cluster", CHIP_ERROR_INCORRECT_STATE));
+
+ auto successFn = chip::Callback::Callback::FromCancelable(onSuccess->Cancel());
+ auto failureFn = chip::Callback::Callback::FromCancelable(onFailure->Cancel());
+
+ if (timedWriteTimeoutMs == nullptr)
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall);
+ }
+ else
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall,
+ chip::JniReferences::GetInstance().IntegerToPrimitive(timedWriteTimeoutMs));
+ }
+ VerifyOrReturn(
+ err == CHIP_NO_ERROR,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(env, callback, "Error writing attribute", err));
+
+ onSuccess.release();
+ onFailure.release();
+}
+
+JNI_METHOD(void, BallastConfigurationCluster, writeBallastFactorAdjustmentAttribute)
+(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jobject value, jobject timedWriteTimeoutMs)
+{
+ chip::DeviceLayer::StackLock lock;
+ ListFreer listFreer;
+ using TypeInfo = chip::app::Clusters::BallastConfiguration::Attributes::BallastFactorAdjustment::TypeInfo;
+ TypeInfo::Type cppValue;
+
+ std::vector> cleanupByteArrays;
+ std::vector> cleanupStrings;
+
+ if (value == nullptr)
+ {
+ cppValue.SetNull();
+ }
+ else
+ {
+ auto & nonNullValue_0 = cppValue.SetNonNull();
+ nonNullValue_0 = static_cast>(
+ chip::JniReferences::GetInstance().IntegerToPrimitive(value));
+ }
+
+ std::unique_ptr onSuccess(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onSuccess.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native success callback", CHIP_ERROR_NO_MEMORY));
+
+ std::unique_ptr onFailure(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onFailure.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native failure callback", CHIP_ERROR_NO_MEMORY));
+
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ BallastConfigurationCluster * cppCluster = reinterpret_cast(clusterPtr);
+ VerifyOrReturn(cppCluster != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Could not get native cluster", CHIP_ERROR_INCORRECT_STATE));
+
+ auto successFn = chip::Callback::Callback::FromCancelable(onSuccess->Cancel());
+ auto failureFn = chip::Callback::Callback::FromCancelable(onFailure->Cancel());
+
+ if (timedWriteTimeoutMs == nullptr)
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall);
+ }
+ else
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall,
+ chip::JniReferences::GetInstance().IntegerToPrimitive(timedWriteTimeoutMs));
+ }
+ VerifyOrReturn(
+ err == CHIP_NO_ERROR,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(env, callback, "Error writing attribute", err));
+
+ onSuccess.release();
+ onFailure.release();
+}
+
+JNI_METHOD(void, BallastConfigurationCluster, writeLampTypeAttribute)
+(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jstring value, jobject timedWriteTimeoutMs)
+{
+ chip::DeviceLayer::StackLock lock;
+ ListFreer listFreer;
+ using TypeInfo = chip::app::Clusters::BallastConfiguration::Attributes::LampType::TypeInfo;
+ TypeInfo::Type cppValue;
+
+ std::vector> cleanupByteArrays;
+ std::vector> cleanupStrings;
+
+ cleanupStrings.push_back(chip::Platform::MakeUnique(env, static_cast(value)));
+ cppValue = cleanupStrings.back()->charSpan();
+
+ std::unique_ptr onSuccess(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onSuccess.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native success callback", CHIP_ERROR_NO_MEMORY));
+
+ std::unique_ptr onFailure(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onFailure.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native failure callback", CHIP_ERROR_NO_MEMORY));
+
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ BallastConfigurationCluster * cppCluster = reinterpret_cast(clusterPtr);
+ VerifyOrReturn(cppCluster != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Could not get native cluster", CHIP_ERROR_INCORRECT_STATE));
+
+ auto successFn = chip::Callback::Callback::FromCancelable(onSuccess->Cancel());
+ auto failureFn = chip::Callback::Callback::FromCancelable(onFailure->Cancel());
+
+ if (timedWriteTimeoutMs == nullptr)
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall);
+ }
+ else
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall,
+ chip::JniReferences::GetInstance().IntegerToPrimitive(timedWriteTimeoutMs));
+ }
+ VerifyOrReturn(
+ err == CHIP_NO_ERROR,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(env, callback, "Error writing attribute", err));
+
+ onSuccess.release();
+ onFailure.release();
+}
+
+JNI_METHOD(void, BallastConfigurationCluster, writeLampManufacturerAttribute)
+(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jstring value, jobject timedWriteTimeoutMs)
+{
+ chip::DeviceLayer::StackLock lock;
+ ListFreer listFreer;
+ using TypeInfo = chip::app::Clusters::BallastConfiguration::Attributes::LampManufacturer::TypeInfo;
+ TypeInfo::Type cppValue;
+
+ std::vector> cleanupByteArrays;
+ std::vector> cleanupStrings;
+
+ cleanupStrings.push_back(chip::Platform::MakeUnique(env, static_cast(value)));
+ cppValue = cleanupStrings.back()->charSpan();
+
+ std::unique_ptr onSuccess(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onSuccess.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native success callback", CHIP_ERROR_NO_MEMORY));
+
+ std::unique_ptr onFailure(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onFailure.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native failure callback", CHIP_ERROR_NO_MEMORY));
+
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ BallastConfigurationCluster * cppCluster = reinterpret_cast(clusterPtr);
+ VerifyOrReturn(cppCluster != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Could not get native cluster", CHIP_ERROR_INCORRECT_STATE));
+
+ auto successFn = chip::Callback::Callback::FromCancelable(onSuccess->Cancel());
+ auto failureFn = chip::Callback::Callback::FromCancelable(onFailure->Cancel());
+
+ if (timedWriteTimeoutMs == nullptr)
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall);
+ }
+ else
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall,
+ chip::JniReferences::GetInstance().IntegerToPrimitive(timedWriteTimeoutMs));
+ }
+ VerifyOrReturn(
+ err == CHIP_NO_ERROR,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(env, callback, "Error writing attribute", err));
+
+ onSuccess.release();
+ onFailure.release();
+}
+
+JNI_METHOD(void, BallastConfigurationCluster, writeLampRatedHoursAttribute)
+(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jobject value, jobject timedWriteTimeoutMs)
+{
+ chip::DeviceLayer::StackLock lock;
+ ListFreer listFreer;
+ using TypeInfo = chip::app::Clusters::BallastConfiguration::Attributes::LampRatedHours::TypeInfo;
+ TypeInfo::Type cppValue;
+
+ std::vector> cleanupByteArrays;
+ std::vector> cleanupStrings;
+
+ if (value == nullptr)
+ {
+ cppValue.SetNull();
+ }
+ else
+ {
+ auto & nonNullValue_0 = cppValue.SetNonNull();
+ nonNullValue_0 = static_cast>(
+ chip::JniReferences::GetInstance().LongToPrimitive(value));
+ }
+
+ std::unique_ptr onSuccess(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onSuccess.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native success callback", CHIP_ERROR_NO_MEMORY));
+
+ std::unique_ptr onFailure(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onFailure.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native failure callback", CHIP_ERROR_NO_MEMORY));
+
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ BallastConfigurationCluster * cppCluster = reinterpret_cast(clusterPtr);
+ VerifyOrReturn(cppCluster != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Could not get native cluster", CHIP_ERROR_INCORRECT_STATE));
+
+ auto successFn = chip::Callback::Callback::FromCancelable(onSuccess->Cancel());
+ auto failureFn = chip::Callback::Callback::FromCancelable(onFailure->Cancel());
+
+ if (timedWriteTimeoutMs == nullptr)
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall);
+ }
+ else
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall,
+ chip::JniReferences::GetInstance().IntegerToPrimitive(timedWriteTimeoutMs));
+ }
+ VerifyOrReturn(
+ err == CHIP_NO_ERROR,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(env, callback, "Error writing attribute", err));
+
+ onSuccess.release();
+ onFailure.release();
+}
+
+JNI_METHOD(void, BallastConfigurationCluster, writeLampBurnHoursAttribute)
+(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jobject value, jobject timedWriteTimeoutMs)
+{
+ chip::DeviceLayer::StackLock lock;
+ ListFreer listFreer;
+ using TypeInfo = chip::app::Clusters::BallastConfiguration::Attributes::LampBurnHours::TypeInfo;
+ TypeInfo::Type cppValue;
+
+ std::vector> cleanupByteArrays;
+ std::vector> cleanupStrings;
+
+ if (value == nullptr)
+ {
+ cppValue.SetNull();
+ }
+ else
+ {
+ auto & nonNullValue_0 = cppValue.SetNonNull();
+ nonNullValue_0 = static_cast>(
+ chip::JniReferences::GetInstance().LongToPrimitive(value));
+ }
+
+ std::unique_ptr onSuccess(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onSuccess.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native success callback", CHIP_ERROR_NO_MEMORY));
+
+ std::unique_ptr onFailure(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onFailure.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native failure callback", CHIP_ERROR_NO_MEMORY));
+
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ BallastConfigurationCluster * cppCluster = reinterpret_cast(clusterPtr);
+ VerifyOrReturn(cppCluster != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Could not get native cluster", CHIP_ERROR_INCORRECT_STATE));
+
+ auto successFn = chip::Callback::Callback::FromCancelable(onSuccess->Cancel());
+ auto failureFn = chip::Callback::Callback::FromCancelable(onFailure->Cancel());
+
+ if (timedWriteTimeoutMs == nullptr)
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall);
+ }
+ else
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall,
+ chip::JniReferences::GetInstance().IntegerToPrimitive(timedWriteTimeoutMs));
+ }
+ VerifyOrReturn(
+ err == CHIP_NO_ERROR,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(env, callback, "Error writing attribute", err));
+
+ onSuccess.release();
+ onFailure.release();
+}
+
+JNI_METHOD(void, BallastConfigurationCluster, writeLampAlarmModeAttribute)
+(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jobject value, jobject timedWriteTimeoutMs)
+{
+ chip::DeviceLayer::StackLock lock;
+ ListFreer listFreer;
+ using TypeInfo = chip::app::Clusters::BallastConfiguration::Attributes::LampAlarmMode::TypeInfo;
+ TypeInfo::Type cppValue;
+
+ std::vector> cleanupByteArrays;
+ std::vector> cleanupStrings;
+
+ cppValue =
+ static_cast>(chip::JniReferences::GetInstance().IntegerToPrimitive(value));
+
+ std::unique_ptr onSuccess(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onSuccess.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native success callback", CHIP_ERROR_NO_MEMORY));
+
+ std::unique_ptr onFailure(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onFailure.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native failure callback", CHIP_ERROR_NO_MEMORY));
+
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ BallastConfigurationCluster * cppCluster = reinterpret_cast(clusterPtr);
+ VerifyOrReturn(cppCluster != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Could not get native cluster", CHIP_ERROR_INCORRECT_STATE));
+
+ auto successFn = chip::Callback::Callback::FromCancelable(onSuccess->Cancel());
+ auto failureFn = chip::Callback::Callback::FromCancelable(onFailure->Cancel());
+
+ if (timedWriteTimeoutMs == nullptr)
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall);
+ }
+ else
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall,
+ chip::JniReferences::GetInstance().IntegerToPrimitive(timedWriteTimeoutMs));
+ }
+ VerifyOrReturn(
+ err == CHIP_NO_ERROR,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(env, callback, "Error writing attribute", err));
+
+ onSuccess.release();
+ onFailure.release();
+}
+
+JNI_METHOD(void, BallastConfigurationCluster, writeLampBurnHoursTripPointAttribute)
+(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jobject value, jobject timedWriteTimeoutMs)
+{
+ chip::DeviceLayer::StackLock lock;
+ ListFreer listFreer;
+ using TypeInfo = chip::app::Clusters::BallastConfiguration::Attributes::LampBurnHoursTripPoint::TypeInfo;
+ TypeInfo::Type cppValue;
+
+ std::vector> cleanupByteArrays;
+ std::vector> cleanupStrings;
+
+ if (value == nullptr)
+ {
+ cppValue.SetNull();
+ }
+ else
+ {
+ auto & nonNullValue_0 = cppValue.SetNonNull();
+ nonNullValue_0 = static_cast>(
+ chip::JniReferences::GetInstance().LongToPrimitive(value));
+ }
+
+ std::unique_ptr onSuccess(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onSuccess.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native success callback", CHIP_ERROR_NO_MEMORY));
+
+ std::unique_ptr onFailure(
+ Platform::New(callback), Platform::Delete);
+ VerifyOrReturn(onFailure.get() != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Error creating native failure callback", CHIP_ERROR_NO_MEMORY));
+
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ BallastConfigurationCluster * cppCluster = reinterpret_cast(clusterPtr);
+ VerifyOrReturn(cppCluster != nullptr,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(
+ env, callback, "Could not get native cluster", CHIP_ERROR_INCORRECT_STATE));
+
+ auto successFn = chip::Callback::Callback::FromCancelable(onSuccess->Cancel());
+ auto failureFn = chip::Callback::Callback::FromCancelable(onFailure->Cancel());
+
+ if (timedWriteTimeoutMs == nullptr)
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall);
+ }
+ else
+ {
+ err = cppCluster->WriteAttribute(cppValue, onSuccess->mContext, successFn->mCall, failureFn->mCall,
+ chip::JniReferences::GetInstance().IntegerToPrimitive(timedWriteTimeoutMs));
+ }
+ VerifyOrReturn(
+ err == CHIP_NO_ERROR,
+ chip::AndroidClusterExceptions::GetInstance().ReturnIllegalStateException(env, callback, "Error writing attribute", err));
+
+ onSuccess.release();
+ onFailure.release();
+}
+
JNI_METHOD(void, ContentLauncherCluster, writeSupportedStreamingProtocolsAttribute)
(JNIEnv * env, jobject self, jlong clusterPtr, jobject callback, jobject value, jobject timedWriteTimeoutMs)
{
diff --git a/src/controller/java/zap-generated/CHIPEventTLVValueDecoder.cpp b/src/controller/java/zap-generated/CHIPEventTLVValueDecoder.cpp
index ba9dfaefd0fb23..de6775d3df51d3 100644
--- a/src/controller/java/zap-generated/CHIPEventTLVValueDecoder.cpp
+++ b/src/controller/java/zap-generated/CHIPEventTLVValueDecoder.cpp
@@ -2988,6 +2988,16 @@ jobject DecodeEventValue(const app::ConcreteEventPath & aPath, TLV::TLVReader &
}
break;
}
+ case app::Clusters::BallastConfiguration::Id: {
+ using namespace app::Clusters::BallastConfiguration;
+ switch (aPath.mEventId)
+ {
+ default:
+ *aError = CHIP_ERROR_IM_MALFORMED_EVENT_PATH_IB;
+ break;
+ }
+ break;
+ }
case app::Clusters::IlluminanceMeasurement::Id: {
using namespace app::Clusters::IlluminanceMeasurement;
switch (aPath.mEventId)
diff --git a/src/controller/java/zap-generated/CHIPReadCallbacks.cpp b/src/controller/java/zap-generated/CHIPReadCallbacks.cpp
index 3048a83c7e358a..c9bbe64cc955f9 100644
--- a/src/controller/java/zap-generated/CHIPReadCallbacks.cpp
+++ b/src/controller/java/zap-generated/CHIPReadCallbacks.cpp
@@ -18556,6 +18556,555 @@ void CHIPColorControlAttributeListAttributeCallback::CallbackFn(void * context,
env->CallVoidMethod(javaCallbackRef, javaMethod, arrayListObj);
}
+CHIPBallastConfigurationIntrinsicBalanceFactorAttributeCallback::CHIPBallastConfigurationIntrinsicBalanceFactorAttributeCallback(
+ jobject javaCallback, bool keepAlive) :
+ chip::Callback::Callback(CallbackFn, this),
+ keepAlive(keepAlive)
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ return;
+ }
+
+ javaCallbackRef = env->NewGlobalRef(javaCallback);
+ if (javaCallbackRef == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ }
+}
+
+CHIPBallastConfigurationIntrinsicBalanceFactorAttributeCallback::~CHIPBallastConfigurationIntrinsicBalanceFactorAttributeCallback()
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not delete global reference for Java callback");
+ return;
+ }
+ env->DeleteGlobalRef(javaCallbackRef);
+}
+
+void CHIPBallastConfigurationIntrinsicBalanceFactorAttributeCallback::CallbackFn(
+ void * context, const chip::app::DataModel::Nullable & value)
+{
+ chip::DeviceLayer::StackUnlock unlock;
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ jobject javaCallbackRef;
+
+ VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env"));
+ std::unique_ptr cppCallback(
+ reinterpret_cast(context), maybeDestroy);
+
+ // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback.
+ javaCallbackRef = cppCallback.get()->javaCallbackRef;
+ VerifyOrReturn(javaCallbackRef != nullptr,
+ ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null"));
+
+ jmethodID javaMethod;
+ err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method"));
+
+ jobject javaValue;
+ if (value.IsNull())
+ {
+ javaValue = nullptr;
+ }
+ else
+ {
+ std::string javaValueClassName = "java/lang/Integer";
+ std::string javaValueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(),
+ value.Value(), javaValue);
+ }
+
+ env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue);
+}
+
+CHIPBallastConfigurationBallastFactorAdjustmentAttributeCallback::CHIPBallastConfigurationBallastFactorAdjustmentAttributeCallback(
+ jobject javaCallback, bool keepAlive) :
+ chip::Callback::Callback(CallbackFn, this),
+ keepAlive(keepAlive)
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ return;
+ }
+
+ javaCallbackRef = env->NewGlobalRef(javaCallback);
+ if (javaCallbackRef == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ }
+}
+
+CHIPBallastConfigurationBallastFactorAdjustmentAttributeCallback::
+ ~CHIPBallastConfigurationBallastFactorAdjustmentAttributeCallback()
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not delete global reference for Java callback");
+ return;
+ }
+ env->DeleteGlobalRef(javaCallbackRef);
+}
+
+void CHIPBallastConfigurationBallastFactorAdjustmentAttributeCallback::CallbackFn(
+ void * context, const chip::app::DataModel::Nullable & value)
+{
+ chip::DeviceLayer::StackUnlock unlock;
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ jobject javaCallbackRef;
+
+ VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env"));
+ std::unique_ptr cppCallback(
+ reinterpret_cast(context), maybeDestroy);
+
+ // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback.
+ javaCallbackRef = cppCallback.get()->javaCallbackRef;
+ VerifyOrReturn(javaCallbackRef != nullptr,
+ ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null"));
+
+ jmethodID javaMethod;
+ err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Integer;)V", &javaMethod);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method"));
+
+ jobject javaValue;
+ if (value.IsNull())
+ {
+ javaValue = nullptr;
+ }
+ else
+ {
+ std::string javaValueClassName = "java/lang/Integer";
+ std::string javaValueCtorSignature = "(I)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(),
+ value.Value(), javaValue);
+ }
+
+ env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue);
+}
+
+CHIPBallastConfigurationLampRatedHoursAttributeCallback::CHIPBallastConfigurationLampRatedHoursAttributeCallback(
+ jobject javaCallback, bool keepAlive) :
+ chip::Callback::Callback(CallbackFn, this),
+ keepAlive(keepAlive)
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ return;
+ }
+
+ javaCallbackRef = env->NewGlobalRef(javaCallback);
+ if (javaCallbackRef == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ }
+}
+
+CHIPBallastConfigurationLampRatedHoursAttributeCallback::~CHIPBallastConfigurationLampRatedHoursAttributeCallback()
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not delete global reference for Java callback");
+ return;
+ }
+ env->DeleteGlobalRef(javaCallbackRef);
+}
+
+void CHIPBallastConfigurationLampRatedHoursAttributeCallback::CallbackFn(void * context,
+ const chip::app::DataModel::Nullable & value)
+{
+ chip::DeviceLayer::StackUnlock unlock;
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ jobject javaCallbackRef;
+
+ VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env"));
+ std::unique_ptr cppCallback(
+ reinterpret_cast(context), maybeDestroy);
+
+ // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback.
+ javaCallbackRef = cppCallback.get()->javaCallbackRef;
+ VerifyOrReturn(javaCallbackRef != nullptr,
+ ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null"));
+
+ jmethodID javaMethod;
+ err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Long;)V", &javaMethod);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method"));
+
+ jobject javaValue;
+ if (value.IsNull())
+ {
+ javaValue = nullptr;
+ }
+ else
+ {
+ std::string javaValueClassName = "java/lang/Long";
+ std::string javaValueCtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(),
+ value.Value(), javaValue);
+ }
+
+ env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue);
+}
+
+CHIPBallastConfigurationLampBurnHoursAttributeCallback::CHIPBallastConfigurationLampBurnHoursAttributeCallback(jobject javaCallback,
+ bool keepAlive) :
+ chip::Callback::Callback(CallbackFn, this),
+ keepAlive(keepAlive)
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ return;
+ }
+
+ javaCallbackRef = env->NewGlobalRef(javaCallback);
+ if (javaCallbackRef == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ }
+}
+
+CHIPBallastConfigurationLampBurnHoursAttributeCallback::~CHIPBallastConfigurationLampBurnHoursAttributeCallback()
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not delete global reference for Java callback");
+ return;
+ }
+ env->DeleteGlobalRef(javaCallbackRef);
+}
+
+void CHIPBallastConfigurationLampBurnHoursAttributeCallback::CallbackFn(void * context,
+ const chip::app::DataModel::Nullable & value)
+{
+ chip::DeviceLayer::StackUnlock unlock;
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ jobject javaCallbackRef;
+
+ VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env"));
+ std::unique_ptr cppCallback(
+ reinterpret_cast(context), maybeDestroy);
+
+ // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback.
+ javaCallbackRef = cppCallback.get()->javaCallbackRef;
+ VerifyOrReturn(javaCallbackRef != nullptr,
+ ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null"));
+
+ jmethodID javaMethod;
+ err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Long;)V", &javaMethod);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method"));
+
+ jobject javaValue;
+ if (value.IsNull())
+ {
+ javaValue = nullptr;
+ }
+ else
+ {
+ std::string javaValueClassName = "java/lang/Long";
+ std::string javaValueCtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(),
+ value.Value(), javaValue);
+ }
+
+ env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue);
+}
+
+CHIPBallastConfigurationLampBurnHoursTripPointAttributeCallback::CHIPBallastConfigurationLampBurnHoursTripPointAttributeCallback(
+ jobject javaCallback, bool keepAlive) :
+ chip::Callback::Callback(CallbackFn, this),
+ keepAlive(keepAlive)
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ return;
+ }
+
+ javaCallbackRef = env->NewGlobalRef(javaCallback);
+ if (javaCallbackRef == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ }
+}
+
+CHIPBallastConfigurationLampBurnHoursTripPointAttributeCallback::~CHIPBallastConfigurationLampBurnHoursTripPointAttributeCallback()
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not delete global reference for Java callback");
+ return;
+ }
+ env->DeleteGlobalRef(javaCallbackRef);
+}
+
+void CHIPBallastConfigurationLampBurnHoursTripPointAttributeCallback::CallbackFn(
+ void * context, const chip::app::DataModel::Nullable & value)
+{
+ chip::DeviceLayer::StackUnlock unlock;
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ jobject javaCallbackRef;
+
+ VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env"));
+ std::unique_ptr cppCallback(
+ reinterpret_cast(context), maybeDestroy);
+
+ // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback.
+ javaCallbackRef = cppCallback.get()->javaCallbackRef;
+ VerifyOrReturn(javaCallbackRef != nullptr,
+ ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null"));
+
+ jmethodID javaMethod;
+ err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/lang/Long;)V", &javaMethod);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method"));
+
+ jobject javaValue;
+ if (value.IsNull())
+ {
+ javaValue = nullptr;
+ }
+ else
+ {
+ std::string javaValueClassName = "java/lang/Long";
+ std::string javaValueCtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(javaValueClassName.c_str(), javaValueCtorSignature.c_str(),
+ value.Value(), javaValue);
+ }
+
+ env->CallVoidMethod(javaCallbackRef, javaMethod, javaValue);
+}
+
+CHIPBallastConfigurationGeneratedCommandListAttributeCallback::CHIPBallastConfigurationGeneratedCommandListAttributeCallback(
+ jobject javaCallback, bool keepAlive) :
+ chip::Callback::Callback(CallbackFn, this),
+ keepAlive(keepAlive)
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ return;
+ }
+
+ javaCallbackRef = env->NewGlobalRef(javaCallback);
+ if (javaCallbackRef == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ }
+}
+
+CHIPBallastConfigurationGeneratedCommandListAttributeCallback::~CHIPBallastConfigurationGeneratedCommandListAttributeCallback()
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not delete global reference for Java callback");
+ return;
+ }
+ env->DeleteGlobalRef(javaCallbackRef);
+}
+
+void CHIPBallastConfigurationGeneratedCommandListAttributeCallback::CallbackFn(
+ void * context, const chip::app::DataModel::DecodableList & list)
+{
+ chip::DeviceLayer::StackUnlock unlock;
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ jobject javaCallbackRef;
+
+ VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env"));
+
+ std::unique_ptr cppCallback(
+ reinterpret_cast(context), maybeDestroy);
+
+ // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback.
+ javaCallbackRef = cppCallback.get()->javaCallbackRef;
+ VerifyOrReturn(javaCallbackRef != nullptr,
+ ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null"));
+
+ jmethodID javaMethod;
+ err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/util/List;)V", &javaMethod);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method"));
+
+ jobject arrayListObj;
+ chip::JniReferences::GetInstance().CreateArrayList(arrayListObj);
+
+ auto iter_arrayListObj_0 = list.begin();
+ while (iter_arrayListObj_0.Next())
+ {
+ auto & entry_0 = iter_arrayListObj_0.GetValue();
+ jobject newElement_0;
+ std::string newElement_0ClassName = "java/lang/Long";
+ std::string newElement_0CtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(newElement_0ClassName.c_str(),
+ newElement_0CtorSignature.c_str(), entry_0, newElement_0);
+ chip::JniReferences::GetInstance().AddToList(arrayListObj, newElement_0);
+ }
+
+ env->ExceptionClear();
+ env->CallVoidMethod(javaCallbackRef, javaMethod, arrayListObj);
+}
+
+CHIPBallastConfigurationAcceptedCommandListAttributeCallback::CHIPBallastConfigurationAcceptedCommandListAttributeCallback(
+ jobject javaCallback, bool keepAlive) :
+ chip::Callback::Callback(CallbackFn, this),
+ keepAlive(keepAlive)
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ return;
+ }
+
+ javaCallbackRef = env->NewGlobalRef(javaCallback);
+ if (javaCallbackRef == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ }
+}
+
+CHIPBallastConfigurationAcceptedCommandListAttributeCallback::~CHIPBallastConfigurationAcceptedCommandListAttributeCallback()
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not delete global reference for Java callback");
+ return;
+ }
+ env->DeleteGlobalRef(javaCallbackRef);
+}
+
+void CHIPBallastConfigurationAcceptedCommandListAttributeCallback::CallbackFn(
+ void * context, const chip::app::DataModel::DecodableList & list)
+{
+ chip::DeviceLayer::StackUnlock unlock;
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ jobject javaCallbackRef;
+
+ VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env"));
+
+ std::unique_ptr cppCallback(
+ reinterpret_cast(context), maybeDestroy);
+
+ // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback.
+ javaCallbackRef = cppCallback.get()->javaCallbackRef;
+ VerifyOrReturn(javaCallbackRef != nullptr,
+ ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null"));
+
+ jmethodID javaMethod;
+ err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/util/List;)V", &javaMethod);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method"));
+
+ jobject arrayListObj;
+ chip::JniReferences::GetInstance().CreateArrayList(arrayListObj);
+
+ auto iter_arrayListObj_0 = list.begin();
+ while (iter_arrayListObj_0.Next())
+ {
+ auto & entry_0 = iter_arrayListObj_0.GetValue();
+ jobject newElement_0;
+ std::string newElement_0ClassName = "java/lang/Long";
+ std::string newElement_0CtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(newElement_0ClassName.c_str(),
+ newElement_0CtorSignature.c_str(), entry_0, newElement_0);
+ chip::JniReferences::GetInstance().AddToList(arrayListObj, newElement_0);
+ }
+
+ env->ExceptionClear();
+ env->CallVoidMethod(javaCallbackRef, javaMethod, arrayListObj);
+}
+
+CHIPBallastConfigurationAttributeListAttributeCallback::CHIPBallastConfigurationAttributeListAttributeCallback(jobject javaCallback,
+ bool keepAlive) :
+ chip::Callback::Callback(CallbackFn, this),
+ keepAlive(keepAlive)
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ return;
+ }
+
+ javaCallbackRef = env->NewGlobalRef(javaCallback);
+ if (javaCallbackRef == nullptr)
+ {
+ ChipLogError(Zcl, "Could not create global reference for Java callback");
+ }
+}
+
+CHIPBallastConfigurationAttributeListAttributeCallback::~CHIPBallastConfigurationAttributeListAttributeCallback()
+{
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ if (env == nullptr)
+ {
+ ChipLogError(Zcl, "Could not delete global reference for Java callback");
+ return;
+ }
+ env->DeleteGlobalRef(javaCallbackRef);
+}
+
+void CHIPBallastConfigurationAttributeListAttributeCallback::CallbackFn(
+ void * context, const chip::app::DataModel::DecodableList & list)
+{
+ chip::DeviceLayer::StackUnlock unlock;
+ CHIP_ERROR err = CHIP_NO_ERROR;
+ JNIEnv * env = chip::JniReferences::GetInstance().GetEnvForCurrentThread();
+ jobject javaCallbackRef;
+
+ VerifyOrReturn(env != nullptr, ChipLogError(Zcl, "Could not get JNI env"));
+
+ std::unique_ptr cppCallback(
+ reinterpret_cast(context), maybeDestroy);
+
+ // It's valid for javaCallbackRef to be nullptr if the Java code passed in a null callback.
+ javaCallbackRef = cppCallback.get()->javaCallbackRef;
+ VerifyOrReturn(javaCallbackRef != nullptr,
+ ChipLogProgress(Zcl, "Early return from attribute callback since Java callback is null"));
+
+ jmethodID javaMethod;
+ err = chip::JniReferences::GetInstance().FindMethod(env, javaCallbackRef, "onSuccess", "(Ljava/util/List;)V", &javaMethod);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Could not find onSuccess() method"));
+
+ jobject arrayListObj;
+ chip::JniReferences::GetInstance().CreateArrayList(arrayListObj);
+
+ auto iter_arrayListObj_0 = list.begin();
+ while (iter_arrayListObj_0.Next())
+ {
+ auto & entry_0 = iter_arrayListObj_0.GetValue();
+ jobject newElement_0;
+ std::string newElement_0ClassName = "java/lang/Long";
+ std::string newElement_0CtorSignature = "(J)V";
+ chip::JniReferences::GetInstance().CreateBoxedObject(newElement_0ClassName.c_str(),
+ newElement_0CtorSignature.c_str(), entry_0, newElement_0);
+ chip::JniReferences::GetInstance().AddToList(arrayListObj, newElement_0);
+ }
+
+ env->ExceptionClear();
+ env->CallVoidMethod(javaCallbackRef, javaMethod, arrayListObj);
+}
+
CHIPIlluminanceMeasurementMeasuredValueAttributeCallback::CHIPIlluminanceMeasurementMeasuredValueAttributeCallback(
jobject javaCallback, bool keepAlive) :
chip::Callback::Callback(CallbackFn, this),
diff --git a/src/controller/java/zap-generated/CHIPReadCallbacks.h b/src/controller/java/zap-generated/CHIPReadCallbacks.h
index 9c05b560d1fd9b..ebce0164633adc 100644
--- a/src/controller/java/zap-generated/CHIPReadCallbacks.h
+++ b/src/controller/java/zap-generated/CHIPReadCallbacks.h
@@ -7735,6 +7735,246 @@ class CHIPColorControlAttributeListAttributeCallback
bool keepAlive;
};
+class CHIPBallastConfigurationIntrinsicBalanceFactorAttributeCallback
+ : public chip::Callback::Callback
+{
+public:
+ CHIPBallastConfigurationIntrinsicBalanceFactorAttributeCallback(jobject javaCallback, bool keepAlive = false);
+
+ ~CHIPBallastConfigurationIntrinsicBalanceFactorAttributeCallback();
+
+ static void maybeDestroy(CHIPBallastConfigurationIntrinsicBalanceFactorAttributeCallback * callback)
+ {
+ if (!callback->keepAlive)
+ {
+ callback->Cancel();
+ chip::Platform::Delete(callback);
+ }
+ }
+
+ static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value);
+ static void OnSubscriptionEstablished(void * context)
+ {
+ CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished(
+ reinterpret_cast(context)->javaCallbackRef);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err)));
+ };
+
+private:
+ jobject javaCallbackRef;
+ bool keepAlive;
+};
+
+class CHIPBallastConfigurationBallastFactorAdjustmentAttributeCallback
+ : public chip::Callback::Callback
+{
+public:
+ CHIPBallastConfigurationBallastFactorAdjustmentAttributeCallback(jobject javaCallback, bool keepAlive = false);
+
+ ~CHIPBallastConfigurationBallastFactorAdjustmentAttributeCallback();
+
+ static void maybeDestroy(CHIPBallastConfigurationBallastFactorAdjustmentAttributeCallback * callback)
+ {
+ if (!callback->keepAlive)
+ {
+ callback->Cancel();
+ chip::Platform::Delete(callback);
+ }
+ }
+
+ static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value);
+ static void OnSubscriptionEstablished(void * context)
+ {
+ CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished(
+ reinterpret_cast(context)->javaCallbackRef);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err)));
+ };
+
+private:
+ jobject javaCallbackRef;
+ bool keepAlive;
+};
+
+class CHIPBallastConfigurationLampRatedHoursAttributeCallback
+ : public chip::Callback::Callback
+{
+public:
+ CHIPBallastConfigurationLampRatedHoursAttributeCallback(jobject javaCallback, bool keepAlive = false);
+
+ ~CHIPBallastConfigurationLampRatedHoursAttributeCallback();
+
+ static void maybeDestroy(CHIPBallastConfigurationLampRatedHoursAttributeCallback * callback)
+ {
+ if (!callback->keepAlive)
+ {
+ callback->Cancel();
+ chip::Platform::Delete(callback);
+ }
+ }
+
+ static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value);
+ static void OnSubscriptionEstablished(void * context)
+ {
+ CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished(
+ reinterpret_cast(context)->javaCallbackRef);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err)));
+ };
+
+private:
+ jobject javaCallbackRef;
+ bool keepAlive;
+};
+
+class CHIPBallastConfigurationLampBurnHoursAttributeCallback
+ : public chip::Callback::Callback
+{
+public:
+ CHIPBallastConfigurationLampBurnHoursAttributeCallback(jobject javaCallback, bool keepAlive = false);
+
+ ~CHIPBallastConfigurationLampBurnHoursAttributeCallback();
+
+ static void maybeDestroy(CHIPBallastConfigurationLampBurnHoursAttributeCallback * callback)
+ {
+ if (!callback->keepAlive)
+ {
+ callback->Cancel();
+ chip::Platform::Delete(callback);
+ }
+ }
+
+ static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value);
+ static void OnSubscriptionEstablished(void * context)
+ {
+ CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished(
+ reinterpret_cast(context)->javaCallbackRef);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err)));
+ };
+
+private:
+ jobject javaCallbackRef;
+ bool keepAlive;
+};
+
+class CHIPBallastConfigurationLampBurnHoursTripPointAttributeCallback
+ : public chip::Callback::Callback
+{
+public:
+ CHIPBallastConfigurationLampBurnHoursTripPointAttributeCallback(jobject javaCallback, bool keepAlive = false);
+
+ ~CHIPBallastConfigurationLampBurnHoursTripPointAttributeCallback();
+
+ static void maybeDestroy(CHIPBallastConfigurationLampBurnHoursTripPointAttributeCallback * callback)
+ {
+ if (!callback->keepAlive)
+ {
+ callback->Cancel();
+ chip::Platform::Delete(callback);
+ }
+ }
+
+ static void CallbackFn(void * context, const chip::app::DataModel::Nullable & value);
+ static void OnSubscriptionEstablished(void * context)
+ {
+ CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished(
+ reinterpret_cast(context)->javaCallbackRef);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err)));
+ };
+
+private:
+ jobject javaCallbackRef;
+ bool keepAlive;
+};
+
+class CHIPBallastConfigurationGeneratedCommandListAttributeCallback
+ : public chip::Callback::Callback
+{
+public:
+ CHIPBallastConfigurationGeneratedCommandListAttributeCallback(jobject javaCallback, bool keepAlive = false);
+
+ ~CHIPBallastConfigurationGeneratedCommandListAttributeCallback();
+
+ static void maybeDestroy(CHIPBallastConfigurationGeneratedCommandListAttributeCallback * callback)
+ {
+ if (!callback->keepAlive)
+ {
+ callback->Cancel();
+ chip::Platform::Delete(callback);
+ }
+ }
+
+ static void CallbackFn(void * context, const chip::app::DataModel::DecodableList & list);
+ static void OnSubscriptionEstablished(void * context)
+ {
+ CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished(
+ reinterpret_cast(context)->javaCallbackRef);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err)));
+ };
+
+private:
+ jobject javaCallbackRef;
+ bool keepAlive;
+};
+
+class CHIPBallastConfigurationAcceptedCommandListAttributeCallback
+ : public chip::Callback::Callback
+{
+public:
+ CHIPBallastConfigurationAcceptedCommandListAttributeCallback(jobject javaCallback, bool keepAlive = false);
+
+ ~CHIPBallastConfigurationAcceptedCommandListAttributeCallback();
+
+ static void maybeDestroy(CHIPBallastConfigurationAcceptedCommandListAttributeCallback * callback)
+ {
+ if (!callback->keepAlive)
+ {
+ callback->Cancel();
+ chip::Platform::Delete(callback);
+ }
+ }
+
+ static void CallbackFn(void * context, const chip::app::DataModel::DecodableList & list);
+ static void OnSubscriptionEstablished(void * context)
+ {
+ CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished(
+ reinterpret_cast(context)->javaCallbackRef);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err)));
+ };
+
+private:
+ jobject javaCallbackRef;
+ bool keepAlive;
+};
+
+class CHIPBallastConfigurationAttributeListAttributeCallback
+ : public chip::Callback::Callback
+{
+public:
+ CHIPBallastConfigurationAttributeListAttributeCallback(jobject javaCallback, bool keepAlive = false);
+
+ ~CHIPBallastConfigurationAttributeListAttributeCallback();
+
+ static void maybeDestroy(CHIPBallastConfigurationAttributeListAttributeCallback * callback)
+ {
+ if (!callback->keepAlive)
+ {
+ callback->Cancel();
+ chip::Platform::Delete(callback);
+ }
+ }
+
+ static void CallbackFn(void * context, const chip::app::DataModel::DecodableList & list);
+ static void OnSubscriptionEstablished(void * context)
+ {
+ CHIP_ERROR err = chip::JniReferences::GetInstance().CallSubscriptionEstablished(
+ reinterpret_cast(context)->javaCallbackRef);
+ VerifyOrReturn(err == CHIP_NO_ERROR, ChipLogError(Zcl, "Error calling onSubscriptionEstablished: %s", ErrorStr(err)));
+ };
+
+private:
+ jobject javaCallbackRef;
+ bool keepAlive;
+};
+
class CHIPIlluminanceMeasurementMeasuredValueAttributeCallback
: public chip::Callback::Callback
{
diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java b/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java
index 33453cc8a4e5ec..fd4f7047d05ed6 100644
--- a/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java
+++ b/src/controller/java/zap-generated/chip/devicecontroller/ChipClusters.java
@@ -17149,6 +17149,551 @@ private native void subscribeClusterRevisionAttribute(
long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval);
}
+ public static class BallastConfigurationCluster extends BaseChipCluster {
+ public static final long CLUSTER_ID = 769L;
+
+ public BallastConfigurationCluster(long devicePtr, int endpointId) {
+ super(devicePtr, endpointId);
+ }
+
+ @Override
+ public native long initWithDevice(long devicePtr, int endpointId);
+
+ public interface IntrinsicBalanceFactorAttributeCallback {
+ void onSuccess(@Nullable Integer value);
+
+ void onError(Exception ex);
+
+ default void onSubscriptionEstablished() {}
+ }
+
+ public interface BallastFactorAdjustmentAttributeCallback {
+ void onSuccess(@Nullable Integer value);
+
+ void onError(Exception ex);
+
+ default void onSubscriptionEstablished() {}
+ }
+
+ public interface LampRatedHoursAttributeCallback {
+ void onSuccess(@Nullable Long value);
+
+ void onError(Exception ex);
+
+ default void onSubscriptionEstablished() {}
+ }
+
+ public interface LampBurnHoursAttributeCallback {
+ void onSuccess(@Nullable Long value);
+
+ void onError(Exception ex);
+
+ default void onSubscriptionEstablished() {}
+ }
+
+ public interface LampBurnHoursTripPointAttributeCallback {
+ void onSuccess(@Nullable Long value);
+
+ void onError(Exception ex);
+
+ default void onSubscriptionEstablished() {}
+ }
+
+ public interface GeneratedCommandListAttributeCallback {
+ void onSuccess(List valueList);
+
+ void onError(Exception ex);
+
+ default void onSubscriptionEstablished() {}
+ }
+
+ public interface AcceptedCommandListAttributeCallback {
+ void onSuccess(List valueList);
+
+ void onError(Exception ex);
+
+ default void onSubscriptionEstablished() {}
+ }
+
+ public interface AttributeListAttributeCallback {
+ void onSuccess(List valueList);
+
+ void onError(Exception ex);
+
+ default void onSubscriptionEstablished() {}
+ }
+
+ public void readPhysicalMinLevelAttribute(IntegerAttributeCallback callback) {
+ readPhysicalMinLevelAttribute(chipClusterPtr, callback);
+ }
+
+ public void subscribePhysicalMinLevelAttribute(
+ IntegerAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribePhysicalMinLevelAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readPhysicalMaxLevelAttribute(IntegerAttributeCallback callback) {
+ readPhysicalMaxLevelAttribute(chipClusterPtr, callback);
+ }
+
+ public void subscribePhysicalMaxLevelAttribute(
+ IntegerAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribePhysicalMaxLevelAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readBallastStatusAttribute(IntegerAttributeCallback callback) {
+ readBallastStatusAttribute(chipClusterPtr, callback);
+ }
+
+ public void subscribeBallastStatusAttribute(
+ IntegerAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeBallastStatusAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readMinLevelAttribute(IntegerAttributeCallback callback) {
+ readMinLevelAttribute(chipClusterPtr, callback);
+ }
+
+ public void writeMinLevelAttribute(DefaultClusterCallback callback, Integer value) {
+ writeMinLevelAttribute(chipClusterPtr, callback, value, null);
+ }
+
+ public void writeMinLevelAttribute(
+ DefaultClusterCallback callback, Integer value, int timedWriteTimeoutMs) {
+ writeMinLevelAttribute(chipClusterPtr, callback, value, timedWriteTimeoutMs);
+ }
+
+ public void subscribeMinLevelAttribute(
+ IntegerAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeMinLevelAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readMaxLevelAttribute(IntegerAttributeCallback callback) {
+ readMaxLevelAttribute(chipClusterPtr, callback);
+ }
+
+ public void writeMaxLevelAttribute(DefaultClusterCallback callback, Integer value) {
+ writeMaxLevelAttribute(chipClusterPtr, callback, value, null);
+ }
+
+ public void writeMaxLevelAttribute(
+ DefaultClusterCallback callback, Integer value, int timedWriteTimeoutMs) {
+ writeMaxLevelAttribute(chipClusterPtr, callback, value, timedWriteTimeoutMs);
+ }
+
+ public void subscribeMaxLevelAttribute(
+ IntegerAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeMaxLevelAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readIntrinsicBalanceFactorAttribute(
+ IntrinsicBalanceFactorAttributeCallback callback) {
+ readIntrinsicBalanceFactorAttribute(chipClusterPtr, callback);
+ }
+
+ public void writeIntrinsicBalanceFactorAttribute(
+ DefaultClusterCallback callback, Integer value) {
+ writeIntrinsicBalanceFactorAttribute(chipClusterPtr, callback, value, null);
+ }
+
+ public void writeIntrinsicBalanceFactorAttribute(
+ DefaultClusterCallback callback, Integer value, int timedWriteTimeoutMs) {
+ writeIntrinsicBalanceFactorAttribute(chipClusterPtr, callback, value, timedWriteTimeoutMs);
+ }
+
+ public void subscribeIntrinsicBalanceFactorAttribute(
+ IntrinsicBalanceFactorAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeIntrinsicBalanceFactorAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readBallastFactorAdjustmentAttribute(
+ BallastFactorAdjustmentAttributeCallback callback) {
+ readBallastFactorAdjustmentAttribute(chipClusterPtr, callback);
+ }
+
+ public void writeBallastFactorAdjustmentAttribute(
+ DefaultClusterCallback callback, Integer value) {
+ writeBallastFactorAdjustmentAttribute(chipClusterPtr, callback, value, null);
+ }
+
+ public void writeBallastFactorAdjustmentAttribute(
+ DefaultClusterCallback callback, Integer value, int timedWriteTimeoutMs) {
+ writeBallastFactorAdjustmentAttribute(chipClusterPtr, callback, value, timedWriteTimeoutMs);
+ }
+
+ public void subscribeBallastFactorAdjustmentAttribute(
+ BallastFactorAdjustmentAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeBallastFactorAdjustmentAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readLampQuantityAttribute(IntegerAttributeCallback callback) {
+ readLampQuantityAttribute(chipClusterPtr, callback);
+ }
+
+ public void subscribeLampQuantityAttribute(
+ IntegerAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeLampQuantityAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readLampTypeAttribute(CharStringAttributeCallback callback) {
+ readLampTypeAttribute(chipClusterPtr, callback);
+ }
+
+ public void writeLampTypeAttribute(DefaultClusterCallback callback, String value) {
+ writeLampTypeAttribute(chipClusterPtr, callback, value, null);
+ }
+
+ public void writeLampTypeAttribute(
+ DefaultClusterCallback callback, String value, int timedWriteTimeoutMs) {
+ writeLampTypeAttribute(chipClusterPtr, callback, value, timedWriteTimeoutMs);
+ }
+
+ public void subscribeLampTypeAttribute(
+ CharStringAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeLampTypeAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readLampManufacturerAttribute(CharStringAttributeCallback callback) {
+ readLampManufacturerAttribute(chipClusterPtr, callback);
+ }
+
+ public void writeLampManufacturerAttribute(DefaultClusterCallback callback, String value) {
+ writeLampManufacturerAttribute(chipClusterPtr, callback, value, null);
+ }
+
+ public void writeLampManufacturerAttribute(
+ DefaultClusterCallback callback, String value, int timedWriteTimeoutMs) {
+ writeLampManufacturerAttribute(chipClusterPtr, callback, value, timedWriteTimeoutMs);
+ }
+
+ public void subscribeLampManufacturerAttribute(
+ CharStringAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeLampManufacturerAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readLampRatedHoursAttribute(LampRatedHoursAttributeCallback callback) {
+ readLampRatedHoursAttribute(chipClusterPtr, callback);
+ }
+
+ public void writeLampRatedHoursAttribute(DefaultClusterCallback callback, Long value) {
+ writeLampRatedHoursAttribute(chipClusterPtr, callback, value, null);
+ }
+
+ public void writeLampRatedHoursAttribute(
+ DefaultClusterCallback callback, Long value, int timedWriteTimeoutMs) {
+ writeLampRatedHoursAttribute(chipClusterPtr, callback, value, timedWriteTimeoutMs);
+ }
+
+ public void subscribeLampRatedHoursAttribute(
+ LampRatedHoursAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeLampRatedHoursAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readLampBurnHoursAttribute(LampBurnHoursAttributeCallback callback) {
+ readLampBurnHoursAttribute(chipClusterPtr, callback);
+ }
+
+ public void writeLampBurnHoursAttribute(DefaultClusterCallback callback, Long value) {
+ writeLampBurnHoursAttribute(chipClusterPtr, callback, value, null);
+ }
+
+ public void writeLampBurnHoursAttribute(
+ DefaultClusterCallback callback, Long value, int timedWriteTimeoutMs) {
+ writeLampBurnHoursAttribute(chipClusterPtr, callback, value, timedWriteTimeoutMs);
+ }
+
+ public void subscribeLampBurnHoursAttribute(
+ LampBurnHoursAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeLampBurnHoursAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readLampAlarmModeAttribute(IntegerAttributeCallback callback) {
+ readLampAlarmModeAttribute(chipClusterPtr, callback);
+ }
+
+ public void writeLampAlarmModeAttribute(DefaultClusterCallback callback, Integer value) {
+ writeLampAlarmModeAttribute(chipClusterPtr, callback, value, null);
+ }
+
+ public void writeLampAlarmModeAttribute(
+ DefaultClusterCallback callback, Integer value, int timedWriteTimeoutMs) {
+ writeLampAlarmModeAttribute(chipClusterPtr, callback, value, timedWriteTimeoutMs);
+ }
+
+ public void subscribeLampAlarmModeAttribute(
+ IntegerAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeLampAlarmModeAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readLampBurnHoursTripPointAttribute(
+ LampBurnHoursTripPointAttributeCallback callback) {
+ readLampBurnHoursTripPointAttribute(chipClusterPtr, callback);
+ }
+
+ public void writeLampBurnHoursTripPointAttribute(DefaultClusterCallback callback, Long value) {
+ writeLampBurnHoursTripPointAttribute(chipClusterPtr, callback, value, null);
+ }
+
+ public void writeLampBurnHoursTripPointAttribute(
+ DefaultClusterCallback callback, Long value, int timedWriteTimeoutMs) {
+ writeLampBurnHoursTripPointAttribute(chipClusterPtr, callback, value, timedWriteTimeoutMs);
+ }
+
+ public void subscribeLampBurnHoursTripPointAttribute(
+ LampBurnHoursTripPointAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeLampBurnHoursTripPointAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readGeneratedCommandListAttribute(GeneratedCommandListAttributeCallback callback) {
+ readGeneratedCommandListAttribute(chipClusterPtr, callback);
+ }
+
+ public void subscribeGeneratedCommandListAttribute(
+ GeneratedCommandListAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeGeneratedCommandListAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readAcceptedCommandListAttribute(AcceptedCommandListAttributeCallback callback) {
+ readAcceptedCommandListAttribute(chipClusterPtr, callback);
+ }
+
+ public void subscribeAcceptedCommandListAttribute(
+ AcceptedCommandListAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeAcceptedCommandListAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readAttributeListAttribute(AttributeListAttributeCallback callback) {
+ readAttributeListAttribute(chipClusterPtr, callback);
+ }
+
+ public void subscribeAttributeListAttribute(
+ AttributeListAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeAttributeListAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readFeatureMapAttribute(LongAttributeCallback callback) {
+ readFeatureMapAttribute(chipClusterPtr, callback);
+ }
+
+ public void subscribeFeatureMapAttribute(
+ LongAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeFeatureMapAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ public void readClusterRevisionAttribute(IntegerAttributeCallback callback) {
+ readClusterRevisionAttribute(chipClusterPtr, callback);
+ }
+
+ public void subscribeClusterRevisionAttribute(
+ IntegerAttributeCallback callback, int minInterval, int maxInterval) {
+ subscribeClusterRevisionAttribute(chipClusterPtr, callback, minInterval, maxInterval);
+ }
+
+ private native void readPhysicalMinLevelAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback);
+
+ private native void subscribePhysicalMinLevelAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval);
+
+ private native void readPhysicalMaxLevelAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback);
+
+ private native void subscribePhysicalMaxLevelAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval);
+
+ private native void readBallastStatusAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback);
+
+ private native void subscribeBallastStatusAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval);
+
+ private native void readMinLevelAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback);
+
+ private native void writeMinLevelAttribute(
+ long chipClusterPtr,
+ DefaultClusterCallback callback,
+ Integer value,
+ @Nullable Integer timedWriteTimeoutMs);
+
+ private native void subscribeMinLevelAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval);
+
+ private native void readMaxLevelAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback);
+
+ private native void writeMaxLevelAttribute(
+ long chipClusterPtr,
+ DefaultClusterCallback callback,
+ Integer value,
+ @Nullable Integer timedWriteTimeoutMs);
+
+ private native void subscribeMaxLevelAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval);
+
+ private native void readIntrinsicBalanceFactorAttribute(
+ long chipClusterPtr, IntrinsicBalanceFactorAttributeCallback callback);
+
+ private native void writeIntrinsicBalanceFactorAttribute(
+ long chipClusterPtr,
+ DefaultClusterCallback callback,
+ Integer value,
+ @Nullable Integer timedWriteTimeoutMs);
+
+ private native void subscribeIntrinsicBalanceFactorAttribute(
+ long chipClusterPtr,
+ IntrinsicBalanceFactorAttributeCallback callback,
+ int minInterval,
+ int maxInterval);
+
+ private native void readBallastFactorAdjustmentAttribute(
+ long chipClusterPtr, BallastFactorAdjustmentAttributeCallback callback);
+
+ private native void writeBallastFactorAdjustmentAttribute(
+ long chipClusterPtr,
+ DefaultClusterCallback callback,
+ Integer value,
+ @Nullable Integer timedWriteTimeoutMs);
+
+ private native void subscribeBallastFactorAdjustmentAttribute(
+ long chipClusterPtr,
+ BallastFactorAdjustmentAttributeCallback callback,
+ int minInterval,
+ int maxInterval);
+
+ private native void readLampQuantityAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback);
+
+ private native void subscribeLampQuantityAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval);
+
+ private native void readLampTypeAttribute(
+ long chipClusterPtr, CharStringAttributeCallback callback);
+
+ private native void writeLampTypeAttribute(
+ long chipClusterPtr,
+ DefaultClusterCallback callback,
+ String value,
+ @Nullable Integer timedWriteTimeoutMs);
+
+ private native void subscribeLampTypeAttribute(
+ long chipClusterPtr,
+ CharStringAttributeCallback callback,
+ int minInterval,
+ int maxInterval);
+
+ private native void readLampManufacturerAttribute(
+ long chipClusterPtr, CharStringAttributeCallback callback);
+
+ private native void writeLampManufacturerAttribute(
+ long chipClusterPtr,
+ DefaultClusterCallback callback,
+ String value,
+ @Nullable Integer timedWriteTimeoutMs);
+
+ private native void subscribeLampManufacturerAttribute(
+ long chipClusterPtr,
+ CharStringAttributeCallback callback,
+ int minInterval,
+ int maxInterval);
+
+ private native void readLampRatedHoursAttribute(
+ long chipClusterPtr, LampRatedHoursAttributeCallback callback);
+
+ private native void writeLampRatedHoursAttribute(
+ long chipClusterPtr,
+ DefaultClusterCallback callback,
+ Long value,
+ @Nullable Integer timedWriteTimeoutMs);
+
+ private native void subscribeLampRatedHoursAttribute(
+ long chipClusterPtr,
+ LampRatedHoursAttributeCallback callback,
+ int minInterval,
+ int maxInterval);
+
+ private native void readLampBurnHoursAttribute(
+ long chipClusterPtr, LampBurnHoursAttributeCallback callback);
+
+ private native void writeLampBurnHoursAttribute(
+ long chipClusterPtr,
+ DefaultClusterCallback callback,
+ Long value,
+ @Nullable Integer timedWriteTimeoutMs);
+
+ private native void subscribeLampBurnHoursAttribute(
+ long chipClusterPtr,
+ LampBurnHoursAttributeCallback callback,
+ int minInterval,
+ int maxInterval);
+
+ private native void readLampAlarmModeAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback);
+
+ private native void writeLampAlarmModeAttribute(
+ long chipClusterPtr,
+ DefaultClusterCallback callback,
+ Integer value,
+ @Nullable Integer timedWriteTimeoutMs);
+
+ private native void subscribeLampAlarmModeAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval);
+
+ private native void readLampBurnHoursTripPointAttribute(
+ long chipClusterPtr, LampBurnHoursTripPointAttributeCallback callback);
+
+ private native void writeLampBurnHoursTripPointAttribute(
+ long chipClusterPtr,
+ DefaultClusterCallback callback,
+ Long value,
+ @Nullable Integer timedWriteTimeoutMs);
+
+ private native void subscribeLampBurnHoursTripPointAttribute(
+ long chipClusterPtr,
+ LampBurnHoursTripPointAttributeCallback callback,
+ int minInterval,
+ int maxInterval);
+
+ private native void readGeneratedCommandListAttribute(
+ long chipClusterPtr, GeneratedCommandListAttributeCallback callback);
+
+ private native void subscribeGeneratedCommandListAttribute(
+ long chipClusterPtr,
+ GeneratedCommandListAttributeCallback callback,
+ int minInterval,
+ int maxInterval);
+
+ private native void readAcceptedCommandListAttribute(
+ long chipClusterPtr, AcceptedCommandListAttributeCallback callback);
+
+ private native void subscribeAcceptedCommandListAttribute(
+ long chipClusterPtr,
+ AcceptedCommandListAttributeCallback callback,
+ int minInterval,
+ int maxInterval);
+
+ private native void readAttributeListAttribute(
+ long chipClusterPtr, AttributeListAttributeCallback callback);
+
+ private native void subscribeAttributeListAttribute(
+ long chipClusterPtr,
+ AttributeListAttributeCallback callback,
+ int minInterval,
+ int maxInterval);
+
+ private native void readFeatureMapAttribute(
+ long chipClusterPtr, LongAttributeCallback callback);
+
+ private native void subscribeFeatureMapAttribute(
+ long chipClusterPtr, LongAttributeCallback callback, int minInterval, int maxInterval);
+
+ private native void readClusterRevisionAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback);
+
+ private native void subscribeClusterRevisionAttribute(
+ long chipClusterPtr, IntegerAttributeCallback callback, int minInterval, int maxInterval);
+ }
+
public static class IlluminanceMeasurementCluster extends BaseChipCluster {
public static final long CLUSTER_ID = 1024L;
diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ChipIdLookup.java b/src/controller/java/zap-generated/chip/devicecontroller/ChipIdLookup.java
index 702b0e30941cd5..aebfd42cdb56f9 100644
--- a/src/controller/java/zap-generated/chip/devicecontroller/ChipIdLookup.java
+++ b/src/controller/java/zap-generated/chip/devicecontroller/ChipIdLookup.java
@@ -157,6 +157,9 @@ public static String clusterIdToName(long clusterId) {
if (clusterId == 768L) {
return "ColorControl";
}
+ if (clusterId == 769L) {
+ return "BallastConfiguration";
+ }
if (clusterId == 1024L) {
return "IlluminanceMeasurement";
}
@@ -2226,6 +2229,66 @@ public static String attributeIdToName(long clusterId, long attributeId) {
}
return "";
}
+ if (clusterId == 769L) {
+ if (attributeId == 0L) {
+ return "PhysicalMinLevel";
+ }
+ if (attributeId == 1L) {
+ return "PhysicalMaxLevel";
+ }
+ if (attributeId == 2L) {
+ return "BallastStatus";
+ }
+ if (attributeId == 16L) {
+ return "MinLevel";
+ }
+ if (attributeId == 17L) {
+ return "MaxLevel";
+ }
+ if (attributeId == 20L) {
+ return "IntrinsicBalanceFactor";
+ }
+ if (attributeId == 21L) {
+ return "BallastFactorAdjustment";
+ }
+ if (attributeId == 32L) {
+ return "LampQuantity";
+ }
+ if (attributeId == 48L) {
+ return "LampType";
+ }
+ if (attributeId == 49L) {
+ return "LampManufacturer";
+ }
+ if (attributeId == 50L) {
+ return "LampRatedHours";
+ }
+ if (attributeId == 51L) {
+ return "LampBurnHours";
+ }
+ if (attributeId == 52L) {
+ return "LampAlarmMode";
+ }
+ if (attributeId == 53L) {
+ return "LampBurnHoursTripPoint";
+ }
+ if (attributeId == 65528L) {
+ return "GeneratedCommandList";
+ }
+ if (attributeId == 65529L) {
+ return "AcceptedCommandList";
+ }
+ if (attributeId == 65531L) {
+ return "AttributeList";
+ }
+ if (attributeId == 65532L) {
+ return "FeatureMap";
+ }
+ if (attributeId == 65533L) {
+ return "ClusterRevision";
+ }
+ return "";
+ }
if (clusterId == 1024L) {
if (attributeId == 0L) {
return "MeasuredValue";
@@ -3326,6 +3389,9 @@ public static String eventIdToName(long clusterId, long eventId) {
if (clusterId == 768L) {
return "";
}
+ if (clusterId == 769L) {
+ return "";
+ }
if (clusterId == 1024L) {
return "";
}
diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java b/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java
index 4c98bba511db70..7c587859ab2e0f 100644
--- a/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java
+++ b/src/controller/java/zap-generated/chip/devicecontroller/ClusterInfoMapping.java
@@ -4997,6 +4997,78 @@ public void onError(Exception ex) {
}
}
+ public static class DelegatedBallastConfigurationClusterGeneratedCommandListAttributeCallback
+ implements ChipClusters.BallastConfigurationCluster.GeneratedCommandListAttributeCallback,
+ DelegatedClusterCallback {
+ private ClusterCommandCallback callback;
+
+ @Override
+ public void setCallbackDelegate(ClusterCommandCallback callback) {
+ this.callback = callback;
+ }
+
+ @Override
+ public void onSuccess(List valueList) {
+ Map responseValues = new LinkedHashMap<>();
+ CommandResponseInfo commandResponseInfo = new CommandResponseInfo("valueList", "List");
+ responseValues.put(commandResponseInfo, valueList);
+ callback.onSuccess(responseValues);
+ }
+
+ @Override
+ public void onError(Exception ex) {
+ callback.onFailure(ex);
+ }
+ }
+
+ public static class DelegatedBallastConfigurationClusterAcceptedCommandListAttributeCallback
+ implements ChipClusters.BallastConfigurationCluster.AcceptedCommandListAttributeCallback,
+ DelegatedClusterCallback {
+ private ClusterCommandCallback callback;
+
+ @Override
+ public void setCallbackDelegate(ClusterCommandCallback callback) {
+ this.callback = callback;
+ }
+
+ @Override
+ public void onSuccess(List valueList) {
+ Map responseValues = new LinkedHashMap<>();
+ CommandResponseInfo commandResponseInfo = new CommandResponseInfo("valueList", "List");
+ responseValues.put(commandResponseInfo, valueList);
+ callback.onSuccess(responseValues);
+ }
+
+ @Override
+ public void onError(Exception ex) {
+ callback.onFailure(ex);
+ }
+ }
+
+ public static class DelegatedBallastConfigurationClusterAttributeListAttributeCallback
+ implements ChipClusters.BallastConfigurationCluster.AttributeListAttributeCallback,
+ DelegatedClusterCallback {
+ private ClusterCommandCallback callback;
+
+ @Override
+ public void setCallbackDelegate(ClusterCommandCallback callback) {
+ this.callback = callback;
+ }
+
+ @Override
+ public void onSuccess(List valueList) {
+ Map responseValues = new LinkedHashMap<>();
+ CommandResponseInfo commandResponseInfo = new CommandResponseInfo("valueList", "List");
+ responseValues.put(commandResponseInfo, valueList);
+ callback.onSuccess(responseValues);
+ }
+
+ @Override
+ public void onError(Exception ex) {
+ callback.onFailure(ex);
+ }
+ }
+
public static class DelegatedIlluminanceMeasurementClusterGeneratedCommandListAttributeCallback
implements ChipClusters.IlluminanceMeasurementCluster.GeneratedCommandListAttributeCallback,
DelegatedClusterCallback {
@@ -7296,6 +7368,11 @@ public Map initializeClusterMap() {
(ptr, endpointId) -> new ChipClusters.ColorControlCluster(ptr, endpointId),
new HashMap<>());
clusterMap.put("colorControl", colorControlClusterInfo);
+ ClusterInfo ballastConfigurationClusterInfo =
+ new ClusterInfo(
+ (ptr, endpointId) -> new ChipClusters.BallastConfigurationCluster(ptr, endpointId),
+ new HashMap<>());
+ clusterMap.put("ballastConfiguration", ballastConfigurationClusterInfo);
ClusterInfo illuminanceMeasurementClusterInfo =
new ClusterInfo(
(ptr, endpointId) -> new ChipClusters.IlluminanceMeasurementCluster(ptr, endpointId),
@@ -7465,6 +7542,7 @@ public void combineCommand(
.get("thermostatUserInterfaceConfiguration")
.combineCommands(source.get("thermostatUserInterfaceConfiguration"));
destination.get("colorControl").combineCommands(source.get("colorControl"));
+ destination.get("ballastConfiguration").combineCommands(source.get("ballastConfiguration"));
destination.get("illuminanceMeasurement").combineCommands(source.get("illuminanceMeasurement"));
destination.get("temperatureMeasurement").combineCommands(source.get("temperatureMeasurement"));
destination.get("pressureMeasurement").combineCommands(source.get("pressureMeasurement"));
@@ -11005,6 +11083,9 @@ public Map> getCommandMap() {
colorControlClusterInteractionInfoMap.put(
"stepColorTemperature", colorControlstepColorTemperatureInteractionInfo);
commandMap.put("colorControl", colorControlClusterInteractionInfoMap);
+ Map ballastConfigurationClusterInteractionInfoMap =
+ new LinkedHashMap<>();
+ commandMap.put("ballastConfiguration", ballastConfigurationClusterInteractionInfoMap);
Map illuminanceMeasurementClusterInteractionInfoMap =
new LinkedHashMap<>();
commandMap.put("illuminanceMeasurement", illuminanceMeasurementClusterInteractionInfoMap);
diff --git a/src/controller/java/zap-generated/chip/devicecontroller/ClusterReadMapping.java b/src/controller/java/zap-generated/chip/devicecontroller/ClusterReadMapping.java
index 78e10642d375c0..6ad1a6f0886652 100644
--- a/src/controller/java/zap-generated/chip/devicecontroller/ClusterReadMapping.java
+++ b/src/controller/java/zap-generated/chip/devicecontroller/ClusterReadMapping.java
@@ -8782,6 +8782,278 @@ public Map> getReadAttributeMap() {
readColorControlInteractionInfo.put(
"readClusterRevisionAttribute", readColorControlClusterRevisionAttributeInteractionInfo);
readAttributeMap.put("colorControl", readColorControlInteractionInfo);
+ Map readBallastConfigurationInteractionInfo = new LinkedHashMap<>();
+ Map readBallastConfigurationPhysicalMinLevelCommandParams =
+ new LinkedHashMap();
+ InteractionInfo readBallastConfigurationPhysicalMinLevelAttributeInteractionInfo =
+ new InteractionInfo(
+ (cluster, callback, commandArguments) -> {
+ ((ChipClusters.BallastConfigurationCluster) cluster)
+ .readPhysicalMinLevelAttribute((ChipClusters.IntegerAttributeCallback) callback);
+ },
+ () -> new ClusterInfoMapping.DelegatedIntegerAttributeCallback(),
+ readBallastConfigurationPhysicalMinLevelCommandParams);
+ readBallastConfigurationInteractionInfo.put(
+ "readPhysicalMinLevelAttribute",
+ readBallastConfigurationPhysicalMinLevelAttributeInteractionInfo);
+ Map