From 1253743c4e68d8f1c7764de14d37fd46b89e455c Mon Sep 17 00:00:00 2001 From: Vivien Nicolas Date: Tue, 17 Nov 2020 18:57:43 +0100 Subject: [PATCH] Add '#define EMBER_AF_PLUGIN_{{clusterName}}' and related to src/app/zap-templates/gen_config.h (#3872) --- src/app/zap-templates/gen_config.zapt | 45 +++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/src/app/zap-templates/gen_config.zapt b/src/app/zap-templates/gen_config.zapt index 5cc04b04c1588f..6988c01b21de5b 100644 --- a/src/app/zap-templates/gen_config.zapt +++ b/src/app/zap-templates/gen_config.zapt @@ -16,3 +16,48 @@ {{#all_user_clusters}} #define EMBER_AF_{{asDelimitedMacro define}}_{{asDelimitedMacro side}}_ENDPOINT_COUNT ({{user_endpoint_count_by_cluster id side}}) {{/all_user_clusters}} + +/**** Cluster Plugins ****/ +{{#all_user_clusters}} + +// Use this macro to check if the {{side}} side of the {{name}} cluster is included +#define ZCL_USING_{{asDelimitedMacro define}}_{{asDelimitedMacro side}} +#define EMBER_AF_PLUGIN_{{asDelimitedMacro name}}_{{asDelimitedMacro side}} +{{#if (isServer side)}} +#define EMBER_AF_PLUGIN_{{asDelimitedMacro name}} +{{/if}} +{{#if (isStrEqual name "Color Control")}} +{{#if (isServer side)}} +// User options for {{side}} plugin {{name}} +#define EMBER_AF_PLUGIN_COLOR_CONTROL_SERVER_XY +#define EMBER_AF_PLUGIN_COLOR_CONTROL_SERVER_TEMP +#define EMBER_AF_PLUGIN_COLOR_CONTROL_SERVER_HSV +{{/if}} +{{else if (isStrEqual name "IAS Zone")}} +// User options for {{side}} plugin {{name}} +{{#if (isServer side)}} +#define EMBER_AF_PLUGIN_IAS_ZONE_SERVER_ZONE_TYPE 541 +{{else}} +#define EMBER_AF_PLUGIN_IAS_ZONE_CLIENT_MAX_DEVICES 10 +{{/if}} +{{else if (isStrEqual name "Level Control")}} +{{#if (isServer side)}} +// User options for {{side}} plugin {{name}} +#define EMBER_AF_PLUGIN_LEVEL_CONTROL_MAXIMUM_LEVEL 255 +#define EMBER_AF_PLUGIN_LEVEL_CONTROL_MINIMUM_LEVEL 0 +#define EMBER_AF_PLUGIN_LEVEL_CONTROL_RATE 0 +{{/if}} +{{else if (isStrEqual name "Scenes")}} +{{#if (isServer side)}} +// User options for {{side}} plugin {{name}} +#define EMBER_AF_PLUGIN_SCENES_TABLE_SIZE 3 +{{/if}} +{{/if}} +{{/all_user_clusters}} + +// TODO Issue #3871 Reporting should only be enabled if there are reportable attributes +// Use this macro to check if Reporting plugin is included +#define EMBER_AF_PLUGIN_REPORTING +// User options for plugin Reporting +#define EMBER_AF_PLUGIN_REPORTING_TABLE_SIZE 5 +#define EMBER_AF_PLUGIN_REPORTING_ENABLE_GROUP_BOUND_REPORTS