From 59347bdeef5186329ba423f8fdedbad4d127f975 Mon Sep 17 00:00:00 2001 From: Alex Tsitsiura Date: Fri, 27 Jan 2023 11:31:31 +0200 Subject: [PATCH] [Telink] Logs optimization --- config/telink/chip-module/Kconfig | 21 ++++++++++++++- .../all-clusters-app/telink/src/AppTask.cpp | 2 +- .../telink/src/ZclDoorLockCallbacks.cpp | 2 +- examples/all-clusters-app/telink/src/main.cpp | 2 +- .../telink/src/AppTask.cpp | 2 +- .../telink/src/main.cpp | 2 +- .../contact-sensor-app/telink/src/AppTask.cpp | 2 +- .../telink/src/ContactSensorManager.cpp | 2 +- .../telink/src/ZclCallbacks.cpp | 2 ++ .../contact-sensor-app/telink/src/main.cpp | 2 +- .../light-switch-app/telink/src/AppTask.cpp | 2 +- .../telink/src/ZclCallbacks.cpp | 2 ++ .../telink/src/binding-handler.cpp | 2 ++ examples/light-switch-app/telink/src/main.cpp | 2 +- examples/lighting-app/telink/src/AppTask.cpp | 14 +++++----- .../lighting-app/telink/src/ZclCallbacks.cpp | 14 +++++----- examples/lighting-app/telink/src/main.cpp | 2 +- .../ota-requestor-app/telink/src/AppTask.cpp | 2 +- .../telink/src/ZclCallbacks.cpp | 2 ++ .../ota-requestor-app/telink/src/main.cpp | 2 +- .../platform/telink/util/src/PWMDevice.cpp | 2 +- examples/thermostat/telink/src/AppTask.cpp | 2 +- .../thermostat/telink/src/SensorManager.cpp | 2 +- .../telink/src/TemperatureManager.cpp | 2 +- .../thermostat/telink/src/ZclCallbacks.cpp | 2 ++ examples/thermostat/telink/src/main.cpp | 2 +- src/platform/telink/CHIPPlatformConfig.h | 26 +++++++++++++++++++ 27 files changed, 89 insertions(+), 32 deletions(-) diff --git a/config/telink/chip-module/Kconfig b/config/telink/chip-module/Kconfig index aa58ad3c58a8cb..894986b2bf69ec 100644 --- a/config/telink/chip-module/Kconfig +++ b/config/telink/chip-module/Kconfig @@ -1,5 +1,5 @@ # -# Copyright (c) 2022 Project CHIP Authors +# Copyright (c) 2023 Project CHIP Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. @@ -20,6 +20,16 @@ rsource "../../zephyr/Kconfig" config CHIP_DEVICE_VENDOR_NAME default "Telink semiconductor" +config CHIP_APP_LOG_LEVEL + int "Logging level in application" + default LOG_DEFAULT_LEVEL + depends on LOG + help + Sets the logging level in the Matter application. Use this configuration + option only within the application. To set the logging level for the + Matter stack, use the MATTER_LOG_LEVEL configuration option. + + # See config/zephyr/Kconfig for full definition config CHIP_OTA_REQUESTOR bool @@ -130,3 +140,12 @@ endif #CHIP_FACTORY_DATA_BUILD config CHIP_FACTORY_RESET_ERASE_NVS bool default y + +config CHIP_LOG_SIZE_OPTIMIZATION + bool "Disable some detailed logs to decrease flash usage" + default y + help + Disables some log levels for specific Matter log modules that provide + information that is too detailed to be used in most cases. You can find + full configuration enabled by this option in the + platform/telink/CHIPPlatformConfig.h file. diff --git a/examples/all-clusters-app/telink/src/AppTask.cpp b/examples/all-clusters-app/telink/src/AppTask.cpp index bc05a343618354..6e802ab3250477 100644 --- a/examples/all-clusters-app/telink/src/AppTask.cpp +++ b/examples/all-clusters-app/telink/src/AppTask.cpp @@ -61,7 +61,7 @@ SHELL_STATIC_SUBCMD_SET_CREATE(sub_telink, SHELL_CMD(reboot, NULL, "Reboot board SHELL_CMD_REGISTER(telink, &sub_telink, "Telink commands", NULL); #endif // CONFIG_CHIP_LIB_SHELL -LOG_MODULE_DECLARE(app); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); namespace { constexpr int kFactoryResetTriggerTimeout = 2000; diff --git a/examples/all-clusters-app/telink/src/ZclDoorLockCallbacks.cpp b/examples/all-clusters-app/telink/src/ZclDoorLockCallbacks.cpp index ddf996bfc48f2c..068b990444b4f5 100644 --- a/examples/all-clusters-app/telink/src/ZclDoorLockCallbacks.cpp +++ b/examples/all-clusters-app/telink/src/ZclDoorLockCallbacks.cpp @@ -26,7 +26,7 @@ using namespace ::chip; using namespace ::chip::app::Clusters; using namespace ::chip::app::Clusters::DoorLock; -LOG_MODULE_DECLARE(app, CONFIG_MATTER_LOG_LEVEL); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); // Provided some empty callbacks and replaced feature map // to simulate DoorLock endpoint for All-Clusters-App example diff --git a/examples/all-clusters-app/telink/src/main.cpp b/examples/all-clusters-app/telink/src/main.cpp index dd1480f6677e45..4061e239ee8fbc 100644 --- a/examples/all-clusters-app/telink/src/main.cpp +++ b/examples/all-clusters-app/telink/src/main.cpp @@ -23,7 +23,7 @@ #include -LOG_MODULE_REGISTER(app); +LOG_MODULE_REGISTER(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::Inet; diff --git a/examples/all-clusters-minimal-app/telink/src/AppTask.cpp b/examples/all-clusters-minimal-app/telink/src/AppTask.cpp index 2b5a51b524f879..1a8c1e08ff2f60 100644 --- a/examples/all-clusters-minimal-app/telink/src/AppTask.cpp +++ b/examples/all-clusters-minimal-app/telink/src/AppTask.cpp @@ -59,7 +59,7 @@ SHELL_STATIC_SUBCMD_SET_CREATE(sub_telink, SHELL_CMD(reboot, NULL, "Reboot board SHELL_CMD_REGISTER(telink, &sub_telink, "Telink commands", NULL); #endif // CONFIG_CHIP_LIB_SHELL -LOG_MODULE_DECLARE(app); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); namespace { constexpr int kFactoryResetTriggerTimeout = 2000; diff --git a/examples/all-clusters-minimal-app/telink/src/main.cpp b/examples/all-clusters-minimal-app/telink/src/main.cpp index dd1480f6677e45..4061e239ee8fbc 100644 --- a/examples/all-clusters-minimal-app/telink/src/main.cpp +++ b/examples/all-clusters-minimal-app/telink/src/main.cpp @@ -23,7 +23,7 @@ #include -LOG_MODULE_REGISTER(app); +LOG_MODULE_REGISTER(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::Inet; diff --git a/examples/contact-sensor-app/telink/src/AppTask.cpp b/examples/contact-sensor-app/telink/src/AppTask.cpp index 598bed97832585..1550775d8585e3 100644 --- a/examples/contact-sensor-app/telink/src/AppTask.cpp +++ b/examples/contact-sensor-app/telink/src/AppTask.cpp @@ -42,7 +42,7 @@ #include #include -LOG_MODULE_DECLARE(app); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::app; diff --git a/examples/contact-sensor-app/telink/src/ContactSensorManager.cpp b/examples/contact-sensor-app/telink/src/ContactSensorManager.cpp index b555e4e0a2c958..c0a7612084d000 100644 --- a/examples/contact-sensor-app/telink/src/ContactSensorManager.cpp +++ b/examples/contact-sensor-app/telink/src/ContactSensorManager.cpp @@ -27,7 +27,7 @@ #include #include -LOG_MODULE_DECLARE(app); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); ContactSensorManager ContactSensorManager::sContactSensor; diff --git a/examples/contact-sensor-app/telink/src/ZclCallbacks.cpp b/examples/contact-sensor-app/telink/src/ZclCallbacks.cpp index 89d6aed77f16d2..1b8424eeb1e90c 100644 --- a/examples/contact-sensor-app/telink/src/ZclCallbacks.cpp +++ b/examples/contact-sensor-app/telink/src/ZclCallbacks.cpp @@ -26,6 +26,8 @@ using namespace chip; using namespace chip::app::Clusters; +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); + void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & attributePath, uint8_t type, uint16_t size, uint8_t * value) { diff --git a/examples/contact-sensor-app/telink/src/main.cpp b/examples/contact-sensor-app/telink/src/main.cpp index e71632de12fddb..9dd145f55ba0c9 100755 --- a/examples/contact-sensor-app/telink/src/main.cpp +++ b/examples/contact-sensor-app/telink/src/main.cpp @@ -23,7 +23,7 @@ #include -LOG_MODULE_REGISTER(app); +LOG_MODULE_REGISTER(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::Inet; diff --git a/examples/light-switch-app/telink/src/AppTask.cpp b/examples/light-switch-app/telink/src/AppTask.cpp index 0c8013067fc9d7..3e692851fc410b 100644 --- a/examples/light-switch-app/telink/src/AppTask.cpp +++ b/examples/light-switch-app/telink/src/AppTask.cpp @@ -63,7 +63,7 @@ SHELL_STATIC_SUBCMD_SET_CREATE(sub_telink, SHELL_CMD(reboot, NULL, "Reboot board SHELL_CMD_REGISTER(telink, &sub_telink, "Telink commands", NULL); #endif // CONFIG_CHIP_LIB_SHELL -LOG_MODULE_DECLARE(app); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::app; diff --git a/examples/light-switch-app/telink/src/ZclCallbacks.cpp b/examples/light-switch-app/telink/src/ZclCallbacks.cpp index cb2b2ab490b48a..e7edb8514e7a18 100644 --- a/examples/light-switch-app/telink/src/ZclCallbacks.cpp +++ b/examples/light-switch-app/telink/src/ZclCallbacks.cpp @@ -23,6 +23,8 @@ #include #include +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); + using namespace chip; using namespace chip::app::Clusters; diff --git a/examples/light-switch-app/telink/src/binding-handler.cpp b/examples/light-switch-app/telink/src/binding-handler.cpp index 60efbcf8857f5c..f982266828c583 100755 --- a/examples/light-switch-app/telink/src/binding-handler.cpp +++ b/examples/light-switch-app/telink/src/binding-handler.cpp @@ -31,6 +31,8 @@ #include "lib/shell/commands/Help.h" #endif // CONFIG_CHIP_LIB_SHELL +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); + using namespace chip; using namespace chip::app; diff --git a/examples/light-switch-app/telink/src/main.cpp b/examples/light-switch-app/telink/src/main.cpp index e71632de12fddb..9dd145f55ba0c9 100755 --- a/examples/light-switch-app/telink/src/main.cpp +++ b/examples/light-switch-app/telink/src/main.cpp @@ -23,7 +23,7 @@ #include -LOG_MODULE_REGISTER(app); +LOG_MODULE_REGISTER(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::Inet; diff --git a/examples/lighting-app/telink/src/AppTask.cpp b/examples/lighting-app/telink/src/AppTask.cpp index 0dd80c267c668e..4a47b652c13f9b 100644 --- a/examples/lighting-app/telink/src/AppTask.cpp +++ b/examples/lighting-app/telink/src/AppTask.cpp @@ -64,7 +64,7 @@ SHELL_STATIC_SUBCMD_SET_CREATE(sub_telink, SHELL_CMD(reboot, NULL, "Reboot board SHELL_CMD_REGISTER(telink, &sub_telink, "Telink commands", NULL); #endif // CONFIG_CHIP_LIB_SHELL -LOG_MODULE_DECLARE(app); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::app; @@ -488,15 +488,15 @@ void AppTask::ActionInitiated(PWMDevice::Action_t aAction, int32_t aActor) { if (aAction == PWMDevice::ON_ACTION) { - LOG_INF("ON_ACTION initiated"); + LOG_DBG("ON_ACTION initiated"); } else if (aAction == PWMDevice::OFF_ACTION) { - LOG_INF("OFF_ACTION initiated"); + LOG_DBG("OFF_ACTION initiated"); } else if (aAction == PWMDevice::LEVEL_ACTION) { - LOG_INF("LEVEL_ACTION initiated"); + LOG_DBG("LEVEL_ACTION initiated"); } } @@ -504,15 +504,15 @@ void AppTask::ActionCompleted(PWMDevice::Action_t aAction, int32_t aActor) { if (aAction == PWMDevice::ON_ACTION) { - LOG_INF("ON_ACTION completed"); + LOG_DBG("ON_ACTION completed"); } else if (aAction == PWMDevice::OFF_ACTION) { - LOG_INF("OFF_ACTION completed"); + LOG_DBG("OFF_ACTION completed"); } else if (aAction == PWMDevice::LEVEL_ACTION) { - LOG_INF("LEVEL_ACTION completed"); + LOG_DBG("LEVEL_ACTION completed"); } if (aActor == AppEvent::kEventType_Button) diff --git a/examples/lighting-app/telink/src/ZclCallbacks.cpp b/examples/lighting-app/telink/src/ZclCallbacks.cpp index 5a0a6dbec4c07f..f25ae759db8150 100644 --- a/examples/lighting-app/telink/src/ZclCallbacks.cpp +++ b/examples/lighting-app/telink/src/ZclCallbacks.cpp @@ -26,6 +26,8 @@ #include #include +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); + using namespace chip; using namespace chip::app::Clusters; using namespace chip::app::Clusters::OnOff; @@ -40,7 +42,7 @@ void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & if (clusterId == OnOff::Id && attributeId == OnOff::Attributes::OnOff::Id) { - ChipLogProgress(Zcl, "Cluster OnOff: attribute OnOff set to %u", *value); + ChipLogDetail(Zcl, "Cluster OnOff: attribute OnOff set to %u", *value); GetAppTask().SetInitiateAction(*value ? PWMDevice::ON_ACTION : PWMDevice::OFF_ACTION, static_cast(AppEvent::kEventType_Lighting), value); } @@ -48,7 +50,7 @@ void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & { if (GetAppTask().GetPWMDevice().IsTurnedOn()) { - ChipLogProgress(Zcl, "Cluster LevelControl: attribute CurrentLevel set to %u", *value); + ChipLogDetail(Zcl, "Cluster LevelControl: attribute CurrentLevel set to %u", *value); GetAppTask().SetInitiateAction(PWMDevice::LEVEL_ACTION, static_cast(AppEvent::kEventType_Lighting), value); } else @@ -78,7 +80,7 @@ void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & xy.y = *reinterpret_cast(value); } - ChipLogProgress(Zcl, "New XY color: %u|%u", xy.x, xy.y); + ChipLogDetail(Zcl, "New XY color: %u|%u", xy.x, xy.y); GetAppTask().SetInitiateAction(PWMDevice::COLOR_ACTION_XY, static_cast(AppEvent::kEventType_Lighting), (uint8_t *) &xy); } @@ -100,19 +102,19 @@ void MatterPostAttributeChangeCallback(const chip::app::ConcreteAttributePath & { hsv.s = *value; } - ChipLogProgress(Zcl, "New HSV color: hue = %u| saturation = %u", hsv.h, hsv.s); + ChipLogDetail(Zcl, "New HSV color: hue = %u| saturation = %u", hsv.h, hsv.s); GetAppTask().SetInitiateAction(PWMDevice::COLOR_ACTION_HSV, static_cast(AppEvent::kEventType_Lighting), (uint8_t *) &hsv); } /* Temperature Mireds color space */ else if (attributeId == ColorControl::Attributes::ColorTemperatureMireds::Id) { - ChipLogProgress(Zcl, "New Temperature Mireds color = %u", *(uint16_t *) value); + ChipLogDetail(Zcl, "New Temperature Mireds color = %u", *(uint16_t *) value); GetAppTask().SetInitiateAction(PWMDevice::COLOR_ACTION_CT, static_cast(AppEvent::kEventType_Lighting), value); } else { - ChipLogProgress(Zcl, "Ignore ColorControl attribute (%u) that is not currently processed!", attributeId); + ChipLogDetail(Zcl, "Ignore ColorControl attribute (%u) that is not currently processed!", attributeId); } } } diff --git a/examples/lighting-app/telink/src/main.cpp b/examples/lighting-app/telink/src/main.cpp index 2e30e3cc52b6f9..ca6d59cbc9eae8 100644 --- a/examples/lighting-app/telink/src/main.cpp +++ b/examples/lighting-app/telink/src/main.cpp @@ -27,7 +27,7 @@ #include "Rpc.h" #endif -LOG_MODULE_REGISTER(app); +LOG_MODULE_REGISTER(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::Inet; diff --git a/examples/ota-requestor-app/telink/src/AppTask.cpp b/examples/ota-requestor-app/telink/src/AppTask.cpp index af2bc6c906a811..36294dab2a2ea4 100644 --- a/examples/ota-requestor-app/telink/src/AppTask.cpp +++ b/examples/ota-requestor-app/telink/src/AppTask.cpp @@ -70,7 +70,7 @@ SHELL_STATIC_SUBCMD_SET_CREATE(sub_telink, SHELL_CMD(reboot, NULL, "Reboot board SHELL_CMD_REGISTER(telink, &sub_telink, "Telink commands", NULL); #endif // CONFIG_CHIP_LIB_SHELL -LOG_MODULE_DECLARE(app); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); namespace { constexpr int kFactoryResetTriggerTimeout = 2000; diff --git a/examples/ota-requestor-app/telink/src/ZclCallbacks.cpp b/examples/ota-requestor-app/telink/src/ZclCallbacks.cpp index 159ce1f9326c6d..73e99ff759b910 100644 --- a/examples/ota-requestor-app/telink/src/ZclCallbacks.cpp +++ b/examples/ota-requestor-app/telink/src/ZclCallbacks.cpp @@ -23,6 +23,8 @@ #include #include +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); + using namespace chip; using namespace chip::app::Clusters; diff --git a/examples/ota-requestor-app/telink/src/main.cpp b/examples/ota-requestor-app/telink/src/main.cpp index dd1480f6677e45..4061e239ee8fbc 100644 --- a/examples/ota-requestor-app/telink/src/main.cpp +++ b/examples/ota-requestor-app/telink/src/main.cpp @@ -23,7 +23,7 @@ #include -LOG_MODULE_REGISTER(app); +LOG_MODULE_REGISTER(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::Inet; diff --git a/examples/platform/telink/util/src/PWMDevice.cpp b/examples/platform/telink/util/src/PWMDevice.cpp index 6a23b399be7576..2b3ffe79ac035a 100644 --- a/examples/platform/telink/util/src/PWMDevice.cpp +++ b/examples/platform/telink/util/src/PWMDevice.cpp @@ -111,7 +111,7 @@ bool PWMDevice::InitiateAction(Action_t aAction, int32_t aActor, uint8_t * value void PWMDevice::SetLevel(uint8_t aLevel) { - LOG_INF("Setting brightness level to %u", aLevel); + LOG_DBG("Setting brightness level to %u", aLevel); mLevel = aLevel; UpdateLight(); } diff --git a/examples/thermostat/telink/src/AppTask.cpp b/examples/thermostat/telink/src/AppTask.cpp index 28df4af294a3bc..d07e9b0d9ddc9f 100644 --- a/examples/thermostat/telink/src/AppTask.cpp +++ b/examples/thermostat/telink/src/AppTask.cpp @@ -62,7 +62,7 @@ SHELL_STATIC_SUBCMD_SET_CREATE(sub_telink, SHELL_CMD(reboot, NULL, "Reboot board SHELL_CMD_REGISTER(telink, &sub_telink, "Telink commands", NULL); #endif // CONFIG_CHIP_LIB_SHELL -LOG_MODULE_DECLARE(app); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::app; diff --git a/examples/thermostat/telink/src/SensorManager.cpp b/examples/thermostat/telink/src/SensorManager.cpp index c692ae9c95394c..0dac8019360967 100644 --- a/examples/thermostat/telink/src/SensorManager.cpp +++ b/examples/thermostat/telink/src/SensorManager.cpp @@ -21,7 +21,7 @@ #include "AppEvent.h" #include "AppTask.h" -LOG_MODULE_DECLARE(app); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace chip; using namespace ::chip::DeviceLayer; diff --git a/examples/thermostat/telink/src/TemperatureManager.cpp b/examples/thermostat/telink/src/TemperatureManager.cpp index 9798cc0d360e8b..b0e7929cf490f5 100644 --- a/examples/thermostat/telink/src/TemperatureManager.cpp +++ b/examples/thermostat/telink/src/TemperatureManager.cpp @@ -22,7 +22,7 @@ #include "AppTask.h" #include -LOG_MODULE_DECLARE(app); +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace chip; using namespace ::chip::DeviceLayer; diff --git a/examples/thermostat/telink/src/ZclCallbacks.cpp b/examples/thermostat/telink/src/ZclCallbacks.cpp index 4dc43fb88c0834..473f04c778b0eb 100644 --- a/examples/thermostat/telink/src/ZclCallbacks.cpp +++ b/examples/thermostat/telink/src/ZclCallbacks.cpp @@ -24,6 +24,8 @@ #include #include +LOG_MODULE_DECLARE(app, CONFIG_CHIP_APP_LOG_LEVEL); + using namespace chip; using namespace chip::app::Clusters; diff --git a/examples/thermostat/telink/src/main.cpp b/examples/thermostat/telink/src/main.cpp index e71632de12fddb..9dd145f55ba0c9 100755 --- a/examples/thermostat/telink/src/main.cpp +++ b/examples/thermostat/telink/src/main.cpp @@ -23,7 +23,7 @@ #include -LOG_MODULE_REGISTER(app); +LOG_MODULE_REGISTER(app, CONFIG_CHIP_APP_LOG_LEVEL); using namespace ::chip; using namespace ::chip::Inet; diff --git a/src/platform/telink/CHIPPlatformConfig.h b/src/platform/telink/CHIPPlatformConfig.h index f78ab8791d1253..0e7c2cbb2891b5 100644 --- a/src/platform/telink/CHIPPlatformConfig.h +++ b/src/platform/telink/CHIPPlatformConfig.h @@ -65,3 +65,29 @@ #ifndef CHIP_CONFIG_MAX_FABRICS #define CHIP_CONFIG_MAX_FABRICS 5 #endif + +#if CONFIG_CHIP_LOG_SIZE_OPTIMIZATION +// Disable some of the too detailed log modules to save flash +#define CHIP_CONFIG_LOG_MODULE_ExchangeManager_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_Crypto_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_Crypto_PROGRESS 0 +#define CHIP_CONFIG_LOG_MODULE_BDX_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_BDX_PROGRESS 0 +#define CHIP_CONFIG_LOG_MODULE_EventLogging_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_EventLogging_PROGRESS 0 +#define CHIP_CONFIG_LOG_MODULE_SetupPayload_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_SetupPayload_PROGRESS 0 +#define CHIP_CONFIG_LOG_MODULE_CASESessionManager_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_CASESessionManager_PROGRESS 0 +#define CHIP_CONFIG_LOG_MODULE_DataManagement_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_FabricProvisioning_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_chipSystemLayer_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_chipSystemLayer_PROGRESS 0 +#define CHIP_CONFIG_LOG_MODULE_Zcl_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_SecureChannel_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_Ble_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_AppServer_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_Support_DETAIL 0 +#define CHIP_CONFIG_LOG_MODULE_Support_PROGRESS 0 +#define CHIP_CONFIG_LOG_MODULE_DeviceLayer_DETAIL 0 +#endif