diff --git a/examples/lighting-app/bouffalolab/bl602/BUILD.gn b/examples/lighting-app/bouffalolab/bl602/BUILD.gn
index 125e9ea..592cc5a 100644
--- a/examples/lighting-app/bouffalolab/bl602/BUILD.gn
+++ b/examples/lighting-app/bouffalolab/bl602/BUILD.gn
@@ -47,6 +47,7 @@
   ota_auto_reboot_delay_seconds = 5
 
   enable_heap_monitoring = false
+  enable_reset_counter = false
 
   setupPinCode = 20202021
   setupDiscriminator = 3840
@@ -102,18 +103,20 @@
     "SYS_AOS_LOOP_ENABLE",
   ]
 
+  if (false == enable_reset_counter) {
+    defines += [ "BOOT_PIN_RESET=8" ]
+  }
+
   bl_plat_name = "bl602"
   sources = [
-    "${examples_plat_dir}/route_hook/bl_route_hook.c",
-    "${examples_plat_dir}/route_hook/bl_route_table.c",
+    "${examples_plat_common_dir}/route_hook/bl_route_hook.c",
+    "${examples_plat_common_dir}/route_hook/bl_route_table.c",
   ]
 
   if ("BL602-IoT-Matter-V1" == board) {
     defines += [ "BL602_IoT_Matter_V1" ]
   } else if ("BL602-NIGHT-LIGHT" == board) {
     defines += [ "BL602_NIGHT_LIGHT" ]
-  } else if ("BL602-IOT-DVK-3S" == board) {
-    defines += [ "BL602_IOT_DVK_3S" ]
   }
 
   sources += [
@@ -121,6 +124,7 @@
     "${example_common_dir}/AppTask.cpp",
     "${example_common_dir}/ZclCallbacks.cpp",
     "${examples_plat_common_dir}/plat/LEDWidget.cpp",
+    "${examples_plat_common_dir}/plat/OTAConfig.cpp",
     "${examples_plat_common_dir}/plat/aos_task.c",
     "${examples_plat_common_dir}/plat/demo_pwm.c",
     "${examples_plat_common_dir}/plat/main.cpp",
@@ -140,6 +144,7 @@
   include_dirs = [
     "${chip_root}/src/platform/bouffalolab/BL602",
     "${example_common_dir}",
+    "${examples_plat_common_dir}/route_hook",
     "${examples_plat_common_dir}/plat",
     "${examples_plat_dir}",
   ]
@@ -208,11 +213,6 @@
     defines += [ "HEAP_MONITORING=1" ]
   }
 
-  if (chip_enable_ota_requestor) {
-    defines += [ "OTA_ENABLED" ]
-    sources += [ "${examples_plat_common_dir}/plat/OTAConfig.cpp" ]
-  }
-
   cflags_c = [ "-Wno-sign-compare" ]
   ldscript = "${examples_plat_dir}/ldscripts/flash_rom.ld"
 
diff --git a/examples/lighting-app/bouffalolab/bl602/CHIPProjectConfig.h b/examples/lighting-app/bouffalolab/bl602/CHIPProjectConfig.h
index 18b7923..3e779ae 100644
--- a/examples/lighting-app/bouffalolab/bl602/CHIPProjectConfig.h
+++ b/examples/lighting-app/bouffalolab/bl602/CHIPProjectConfig.h
@@ -1,7 +1,6 @@
 /*
  *
  *    Copyright (c) 2021 Project CHIP Authors
- *    Copyright (c) 2019 Google LLC.
  *    All rights reserved.
  *
  *    Licensed under the Apache License, Version 2.0 (the "License");
@@ -108,13 +107,6 @@
 #define CHIP_DEVICE_CONFIG_DEVICE_PRODUCT_REVISION 1
 
 /**
- * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE
- *
- * Enable support for Chip-over-BLE (CHIPoBLE).
- */
-#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1
-
-/**
  * CHIP_DEVICE_CONFIG_TEST_SERIAL_NUMBER
  *
  * Enables the use of a hard-coded default serial number if none
diff --git a/examples/lighting-app/bouffalolab/bl602/args.gni b/examples/lighting-app/bouffalolab/bl602/args.gni
index 1a7e2dd..4c69abd 100644
--- a/examples/lighting-app/bouffalolab/bl602/args.gni
+++ b/examples/lighting-app/bouffalolab/bl602/args.gni
@@ -23,7 +23,6 @@
 pw_assert_BACKEND = "$dir_pw_assert_log"
 pw_rpc_CONFIG = "$dir_pw_rpc:disable_global_mutex"
 
-chip_enable_ota_requestor = true
 chip_detail_logging = false
 
 pw_build_LINK_DEPS = [
diff --git a/examples/lighting-app/bouffalolab/bl602/board.h b/examples/lighting-app/bouffalolab/bl602/board.h
index 236c974..4e98b26 100644
--- a/examples/lighting-app/bouffalolab/bl602/board.h
+++ b/examples/lighting-app/bouffalolab/bl602/board.h
@@ -48,11 +48,6 @@
 #define LED_G_PIN_PORT 1
 #define LED_G_PIN 11
 
-// comment out for last hardware
-//#define LED_R_PIN_PORT 0
-//#define LED_R_PIN 20
-//#define LED_G_PIN 21
-
 #define MAX_PWM_CHANNEL 3
 
 #else
@@ -64,7 +59,5 @@
 
 #endif
 
-#define LED_BTN_RESET 8
-
 #define CHIP_UART_PIN_RX 7
 #define CHIP_UART_PIN_TX 16
diff --git a/examples/lighting-app/bouffalolab/bl702/BUILD.gn b/examples/lighting-app/bouffalolab/bl702/BUILD.gn
index 028a36f..b382aa7 100644
--- a/examples/lighting-app/bouffalolab/bl702/BUILD.gn
+++ b/examples/lighting-app/bouffalolab/bl702/BUILD.gn
@@ -49,6 +49,8 @@
   config_cache_size = 8192
 
   enable_heap_monitoring = false
+  enable_reset_counter = false
+  enable_cdc_module = false
 
   setupPinCode = 20202021
   setupDiscriminator = 3840
@@ -74,10 +76,13 @@
     "CHIP_DEVICE_CONFIG_USE_TEST_SETUP_DISCRIMINATOR=${setupDiscriminator}",
     "OTA_PERIODIC_TIMEOUT=${ota_periodic_query_timeout_seconds}",
     "OTA_AUTO_REBOOT_DELAY=${ota_auto_reboot_delay_seconds}",
-    "OPENTHREAD_CONFIG_PLATFORM_XTAL_ACCURACY=40",
     "PRINT_DEBUG=0",
   ]
 
+  if (chip_enable_openthread) {
+    defines += [ "OPENTHREAD_CONFIG_PLATFORM_XTAL_ACCURACY=40" ]
+  }
+
   if ("BL706C-22" == module_type) {
     defines += [ "CFG_PSRAM_DUAL_BANK=1" ]
   }
@@ -117,20 +122,20 @@
     "START_ENTRY=bl702_main",
   ]
 
-  if (enable_psram) {
-    defines += [ "CFG_USE_PSRAM=1" ]
+  if (false == enable_reset_counter) {
+    defines += [ "BOOT_PIN_RESET=31" ]
   }
 
-  if ("BL706C-22" == module_type) {
-    defines += [ "BOARD_BTN_BOOT_PIN" ]
+  if (enable_psram) {
+    defines += [ "CFG_USE_PSRAM=1" ]
   }
 
   if ("XT-ZB6-DevKit" == board) {
     defines += [ "XT_ZB6_DevKit" ]
   } else if ("BL706-NIGHT-LIGHT" == board) {
     defines += [ "BL706_NIGHT_LIGHT" ]
-  } else if ("BL702-IoT-DVK" == board || "BL706-IoT-DVK" == board) {
-    defines += [ "BL706_IOT_DVK" ]
+  } else if ("BL706-ETH" == board) {
+    defines += [ "BL706_ETHERNET" ]
   }
 
   if (defined(enable_cdc_module) && enable_cdc_module) {
@@ -141,6 +146,7 @@
     "${example_common_dir}/AppTask.cpp",
     "${example_common_dir}/ZclCallbacks.cpp",
     "${examples_plat_common_dir}/plat/LEDWidget.cpp",
+    "${examples_plat_common_dir}/plat/OTAConfig.cpp",
     "${examples_plat_common_dir}/plat/demo_pwm.c",
     "${examples_plat_common_dir}/plat/main.cpp",
     "${examples_plat_common_dir}/plat/platform.cpp",
@@ -153,27 +159,38 @@
     "${chip_root}/examples/providers:device_info_provider",
     "${chip_root}/src/lib",
     "${chip_root}/src/setup_payload",
-    "${chip_root}/third_party/openthread/platforms:libopenthread-platform",
-    "${chip_root}/third_party/openthread/platforms:libopenthread-platform-utils",
   ]
 
-  if (chip_openthread_ftd) {
-    defines += [ "CHIP_DEVICE_CONFIG_THREAD_FTD=1" ]
+  if (chip_enable_openthread) {
     deps += [
-      "${chip_root}/third_party/openthread/repo:libopenthread-cli-ftd",
-      "${chip_root}/third_party/openthread/repo:libopenthread-ftd",
+      "${chip_root}/third_party/openthread/platforms:libopenthread-platform",
+      "${chip_root}/third_party/openthread/platforms:libopenthread-platform-utils",
     ]
+
+    if (chip_openthread_ftd) {
+      defines += [ "CHIP_DEVICE_CONFIG_THREAD_FTD=1" ]
+      deps += [
+        "${chip_root}/third_party/openthread/repo:libopenthread-cli-ftd",
+        "${chip_root}/third_party/openthread/repo:libopenthread-ftd",
+      ]
+    } else {
+      defines += [ "CHIP_DEVICE_CONFIG_THREAD_FTD=0" ]
+      deps += [
+        "${chip_root}/third_party/openthread/repo:libopenthread-cli-mtd",
+        "${chip_root}/third_party/openthread/repo:libopenthread-mtd",
+      ]
+    }
   } else {
-    defines += [ "CHIP_DEVICE_CONFIG_THREAD_FTD=0" ]
-    deps += [
-      "${chip_root}/third_party/openthread/repo:libopenthread-cli-mtd",
-      "${chip_root}/third_party/openthread/repo:libopenthread-mtd",
+    sources += [
+      "${examples_plat_common_dir}/route_hook/bl_route_hook.c",
+      "${examples_plat_common_dir}/route_hook/bl_route_table.c",
     ]
   }
 
   include_dirs = [
     "${chip_root}/src/platform/bouffalolab/BL702",
     "${example_common_dir}",
+    "${examples_plat_common_dir}/route_hook",
     "${examples_plat_common_dir}/plat",
   ]
 
@@ -212,11 +229,16 @@
       "${chip_root}/examples/common/pigweed:descriptor_service.nanopb_rpc",
       "${chip_root}/examples/common/pigweed:device_service.nanopb_rpc",
       "${chip_root}/examples/common/pigweed:lighting_service.nanopb_rpc",
-      "${chip_root}/examples/common/pigweed:ot_cli_service.nanopb_rpc",
-      "${chip_root}/examples/common/pigweed:thread_service.nanopb_rpc",
       "${examples_plat_common_dir}/rpc/pw_sys_io:pw_sys_io",
     ]
 
+    if (chip_enable_openthread) {
+      deps += [
+        "${chip_root}/examples/common/pigweed:ot_cli_service.nanopb_rpc",
+        "${chip_root}/examples/common/pigweed:thread_service.nanopb_rpc",
+      ]
+    }
+
     deps += pw_build_LINK_DEPS
 
     include_dirs += [
@@ -239,11 +261,6 @@
     defines += [ "HEAP_MONITORING=1" ]
   }
 
-  if (chip_enable_ota_requestor) {
-    defines += [ "OTA_ENABLED" ]
-    sources += [ "${examples_plat_common_dir}/plat/OTAConfig.cpp" ]
-  }
-
   if (enable_psram) {
     ldscript = "${examples_plat_dir}/ldscripts/psram_flash.ld"
   } else {
diff --git a/examples/lighting-app/bouffalolab/bl702/CHIPProjectConfig.h b/examples/lighting-app/bouffalolab/bl702/CHIPProjectConfig.h
index 1a357d1..19ff4f3 100644
--- a/examples/lighting-app/bouffalolab/bl702/CHIPProjectConfig.h
+++ b/examples/lighting-app/bouffalolab/bl702/CHIPProjectConfig.h
@@ -1,7 +1,6 @@
 /*
  *
  *    Copyright (c) 2020 Project CHIP Authors
- *    Copyright (c) 2019 Google LLC.
  *    All rights reserved.
  *
  *    Licensed under the Apache License, Version 2.0 (the "License");
@@ -102,13 +101,6 @@
 #endif
 
 /**
- * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE
- *
- * Enable support for Chip-over-BLE (CHIPoBLE).
- */
-#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1
-
-/**
  * CHIP_DEVICE_CONFIG_TEST_SERIAL_NUMBER
  *
  * Enables the use of a hard-coded default serial number if none
diff --git a/examples/lighting-app/bouffalolab/bl702/args.gni b/examples/lighting-app/bouffalolab/bl702/args.gni
index 8087dc1..e35ae89 100644
--- a/examples/lighting-app/bouffalolab/bl702/args.gni
+++ b/examples/lighting-app/bouffalolab/bl702/args.gni
@@ -23,12 +23,6 @@
 pw_assert_BACKEND = "$dir_pw_assert_log"
 pw_rpc_CONFIG = "$dir_pw_rpc:disable_global_mutex"
 
-chip_enable_ble = true
-chip_enable_openthread = true
-chip_enable_wifi = false
-lwip_platform = "bl702"
-
-chip_enable_ota_requestor = true
 chip_detail_logging = false
 
 pw_build_LINK_DEPS = [
diff --git a/examples/lighting-app/bouffalolab/bl702/board.h b/examples/lighting-app/bouffalolab/bl702/board.h
index 6b5ee14..b8c145c 100644
--- a/examples/lighting-app/bouffalolab/bl702/board.h
+++ b/examples/lighting-app/bouffalolab/bl702/board.h
@@ -52,15 +52,6 @@
 
 #elif defined(XT_ZB6_DevKit)
 
-// #define LED_B_PIN_PORT 3
-// #define LED_B_PIN 18
-
-// #define LED_R_PIN_PORT 4
-// #define LED_R_PIN 19
-
-// #define LED_G_PIN_PORT 0
-// #define LED_G_PIN 20
-
 #define LED_PIN_PORT 3
 #define LED_PIN 18
 
@@ -75,15 +66,5 @@
 
 #endif
 
-#if defined(BOARD_BTN_BOOT_PIN)
-#define LED_BTN_RESET 31
-#endif
-
-#define SPI_WIFI_MISO_PIN 4
-#define SPI_WIFI_MOSI_PIN 5
-#define SPI_WIFI_CLK_PIN 3
-#define SPI_WIFI_CS_PIN 6
-#define SPI_WIFI_IRQ_PIN 10
-
 #define CHIP_UART_PIN_RX 15
 #define CHIP_UART_PIN_TX 14
diff --git a/examples/lighting-app/bouffalolab/bl702l/BUILD.gn b/examples/lighting-app/bouffalolab/bl702l/BUILD.gn
index db0209f..621416e 100644
--- a/examples/lighting-app/bouffalolab/bl702l/BUILD.gn
+++ b/examples/lighting-app/bouffalolab/bl702l/BUILD.gn
@@ -49,6 +49,7 @@
   config_cache_size = 8192
 
   enable_heap_monitoring = false
+  enable_reset_counter = false
 
   setupPinCode = 20202021
   setupDiscriminator = 3840
@@ -97,6 +98,7 @@
   zap_pregenerated_dir = "${chip_root}/zzz_generated/lighting-app/zap-generated"
   is_server = true
 }
+
 bouffalolab_executable("lighting_app") {
   output_name = "chip-bl702l-lighting-example.out"
   bl_plat_name = "bl702l"
@@ -108,9 +110,11 @@
     "START_ENTRY=bl702_main",
   ]
 
-  defines += [ "CFG_USE_PSRAM=1" ]
+  if (false == enable_reset_counter) {
+    defines += [ "BOOT_PIN_RESET=16" ]
+  }
 
-  defines += [ "BOARD_BTN_BOOT_PIN" ]
+  defines += [ "CFG_USE_PSRAM=1" ]
 
   if ("BL704L" == board) {
     defines += [ "XT_ZB6_DevKit" ]
@@ -124,6 +128,7 @@
     "${example_common_dir}/AppTask.cpp",
     "${example_common_dir}/ZclCallbacks.cpp",
     "${examples_plat_common_dir}/plat/LEDWidget.cpp",
+    "${examples_plat_common_dir}/plat/OTAConfig.cpp",
     "${examples_plat_common_dir}/plat/demo_pwm.c",
     "${examples_plat_common_dir}/plat/main.cpp",
     "${examples_plat_common_dir}/plat/platform.cpp",
@@ -222,11 +227,6 @@
     defines += [ "HEAP_MONITORING=1" ]
   }
 
-  if (chip_enable_ota_requestor) {
-    defines += [ "OTA_ENABLED" ]
-    sources += [ "${examples_plat_common_dir}/plat/OTAConfig.cpp" ]
-  }
-
   if (enable_psram) {
     ldscript = "${examples_plat_dir}/ldscripts/psram_flash_rom.ld"
   } else {
diff --git a/examples/lighting-app/bouffalolab/bl702l/CHIPProjectConfig.h b/examples/lighting-app/bouffalolab/bl702l/CHIPProjectConfig.h
index 1a357d1..19ff4f3 100644
--- a/examples/lighting-app/bouffalolab/bl702l/CHIPProjectConfig.h
+++ b/examples/lighting-app/bouffalolab/bl702l/CHIPProjectConfig.h
@@ -1,7 +1,6 @@
 /*
  *
  *    Copyright (c) 2020 Project CHIP Authors
- *    Copyright (c) 2019 Google LLC.
  *    All rights reserved.
  *
  *    Licensed under the Apache License, Version 2.0 (the "License");
@@ -102,13 +101,6 @@
 #endif
 
 /**
- * CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE
- *
- * Enable support for Chip-over-BLE (CHIPoBLE).
- */
-#define CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE 1
-
-/**
  * CHIP_DEVICE_CONFIG_TEST_SERIAL_NUMBER
  *
  * Enables the use of a hard-coded default serial number if none
diff --git a/examples/lighting-app/bouffalolab/bl702l/args.gni b/examples/lighting-app/bouffalolab/bl702l/args.gni
index a897d37..f2eb36a 100644
--- a/examples/lighting-app/bouffalolab/bl702l/args.gni
+++ b/examples/lighting-app/bouffalolab/bl702l/args.gni
@@ -23,12 +23,6 @@
 pw_assert_BACKEND = "$dir_pw_assert_log"
 pw_rpc_CONFIG = "$dir_pw_rpc:disable_global_mutex"
 
-chip_enable_ble = true
-chip_enable_openthread = true
-chip_enable_wifi = false
-lwip_platform = "bl702l"
-
-chip_enable_ota_requestor = true
 chip_detail_logging = false
 
 pw_build_LINK_DEPS = [
diff --git a/examples/lighting-app/bouffalolab/bl702l/board.h b/examples/lighting-app/bouffalolab/bl702l/board.h
index 5bfcc54..62ee364 100644
--- a/examples/lighting-app/bouffalolab/bl702l/board.h
+++ b/examples/lighting-app/bouffalolab/bl702l/board.h
@@ -75,10 +75,6 @@
 
 #endif
 
-#if defined(BOARD_BTN_BOOT_PIN)
-#define LED_BTN_RESET 16
-#endif
-
 #define SPI_WIFI_MISO_PIN 4
 #define SPI_WIFI_MOSI_PIN 5
 #define SPI_WIFI_CLK_PIN 3
diff --git a/examples/lighting-app/bouffalolab/common/AppTask.cpp b/examples/lighting-app/bouffalolab/common/AppTask.cpp
index 28d8e83..3171341 100644
--- a/examples/lighting-app/bouffalolab/common/AppTask.cpp
+++ b/examples/lighting-app/bouffalolab/common/AppTask.cpp
@@ -1,7 +1,6 @@
 /*
  *
  *    Copyright (c) 2020 Project CHIP Authors
- *    Copyright (c) 2019 Google LLC.
  *    All rights reserved.
  *
  *    Licensed under the Apache License, Version 2.0 (the "License");
@@ -17,22 +16,14 @@
  *    limitations under the License.
  */
 
-#include <LEDWidget.h>
-#include <plat.h>
-
 #include <app-common/zap-generated/attributes/Accessors.h>
-#include <app-common/zap-generated/ids/Clusters.h>
 #include <app/clusters/identify-server/identify-server.h>
-#include <app/util/attribute-storage.h>
 
 #include <app/server/Dnssd.h>
 #include <app/server/OnboardingCodesUtil.h>
 #include <app/server/Server.h>
 #include <credentials/DeviceAttestationCredsProvider.h>
 #include <credentials/examples/DeviceAttestationCredsExample.h>
-#include <lib/support/CHIPMem.h>
-#include <lib/support/CodeUtils.h>
-#include <lib/support/ErrorStr.h>
 #include <system/SystemClock.h>
 
 #if HEAP_MONITORING
@@ -51,6 +42,9 @@
 #include <lib/shell/Engine.h>
 #endif
 
+#include <LEDWidget.h>
+#include <plat.h>
+
 extern "C" {
 #include "board.h"
 #include <bl_gpio.h>
@@ -140,21 +134,32 @@
     app_event_t appEvent;
     bool onoff = false;
 
+#ifndef BL706_ETHERNET
     sLightLED.Init();
+#endif
 
-#ifdef LED_BTN_RESET
+#ifdef BOOT_PIN_RESET
     ButtonInit();
 #else
     /** Without RESET PIN defined, factory reset will be executed if power cycle count(resetCnt) >= APP_REBOOT_RESET_COUNT */
     uint32_t resetCnt      = 0;
     size_t saved_value_len = 0;
     ef_get_env_blob(APP_REBOOT_RESET_COUNT_KEY, &resetCnt, sizeof(resetCnt), &saved_value_len);
-    resetCnt++;
-    ef_set_env_blob(APP_REBOOT_RESET_COUNT_KEY, &resetCnt, sizeof(resetCnt));
 
-    /** To share with RESET PIN logic, mButtonPressedTime is used to recorded resetCnt increased.
-     * +1 makes sure mButtonPressedTime is not zero */
-    GetAppTask().mButtonPressedTime = chip::System::SystemClock().GetMonotonicMilliseconds64().count() + 1;
+    if (resetCnt > APP_REBOOT_RESET_COUNT)
+    {
+        resetCnt = 0;
+        /** To share with RESET PIN logic, mButtonPressedTime is used to recorded resetCnt increased.
+         * +1 makes sure mButtonPressedTime is not zero;
+         * a power cycle during factory reset confirm time APP_BUTTON_PRESS_LONG will cancel factoryreset */
+        GetAppTask().mButtonPressedTime = System::SystemClock().GetMonotonicMilliseconds64().count() + 1;
+    }
+    else
+    {
+        resetCnt++;
+        GetAppTask().mButtonPressedTime = 0;
+    }
+    ef_set_env_blob(APP_REBOOT_RESET_COUNT_KEY, &resetCnt, sizeof(resetCnt));
 #endif
 
     GetAppTask().sTimer = xTimerCreate("lightTmr", pdMS_TO_TICKS(1000), false, NULL, AppTask::TimerCallback);
@@ -172,12 +177,12 @@
         appError(ret);
     }
 
-    GetAppTask().PostEvent(AppTask::APP_EVENT_TIMER);
+    GetAppTask().PostEvent(APP_EVENT_TIMER);
+    GetAppTask().PostEvent(APP_EVENT_LIGHTING_MASK);
+
     vTaskSuspend(NULL);
 
-    GetAppTask().mIsConnected = false;
-
-    ChipLogProgress(NotSpecified, "App Task started, with heap %d left\r\n", xPortGetFreeHeapSize());
+    ChipLogProgress(NotSpecified, "App Task started, with SRAM heap %d left\r\n", xPortGetFreeHeapSize());
 
     while (true)
     {
@@ -188,22 +193,23 @@
         {
             PlatformMgr().LockChipStack();
 
-            if (APP_EVENT_SYS_PROVISIONED & appEvent)
+            if (APP_EVENT_LIGHTING_MASK & appEvent)
             {
-                LightingUpdate(APP_EVENT_LIGHTING_MASK);
+                LightingUpdate(appEvent);
             }
 
             if (APP_EVENT_BTN_SHORT & appEvent)
             {
-                Clusters::OnOff::Attributes::OnOff::Get(GetAppTask().GetEndpointId(), &onoff);
-                onoff = !onoff;
-                Clusters::OnOff::Attributes::OnOff::Set(GetAppTask().GetEndpointId(), onoff);
-                LightingUpdate((app_event_t)(APP_EVENT_LIGHTING_MASK & appEvent));
-            }
-
-            if (APP_EVENT_LIGHTING_MASK & appEvent)
-            {
-                LightingUpdate((app_event_t)(APP_EVENT_LIGHTING_MASK & appEvent));
+                if (Server::GetInstance().GetFabricTable().FabricCount())
+                {
+                    Clusters::OnOff::Attributes::OnOff::Get(GetAppTask().GetEndpointId(), &onoff);
+                    onoff = !onoff;
+                    Clusters::OnOff::Attributes::OnOff::Set(GetAppTask().GetEndpointId(), onoff);
+                }
+                else
+                {
+                    sLightLED.Toggle();
+                }
             }
 
             if (APP_EVENT_IDENTIFY_MASK & appEvent)
@@ -211,11 +217,6 @@
                 IdentifyHandleOp(appEvent);
             }
 
-            if (APP_EVENT_SYS_BLE_ADV & appEvent)
-            {
-                LightingUpdate(APP_EVENT_SYS_BLE_ADV);
-            }
-
             if (APP_EVENT_FACTORY_RESET & appEvent)
             {
                 DeviceLayer::ConfigurationMgr().InitiateFactoryReset();
@@ -237,57 +238,60 @@
 
     if (APP_EVENT_LIGHTING_MASK & status)
     {
-        do
+
+        if (Server::GetInstance().GetFabricTable().FabricCount())
         {
-            if (EMBER_ZCL_STATUS_SUCCESS != Clusters::OnOff::Attributes::OnOff::Get(endpoint, &onoff))
+            do
             {
-                break;
-            }
-
-            if (EMBER_ZCL_STATUS_SUCCESS != Clusters::LevelControl::Attributes::CurrentLevel::Get(endpoint, v))
-            {
-                break;
-            }
-
-            if (EMBER_ZCL_STATUS_SUCCESS != Clusters::ColorControl::Attributes::CurrentHue::Get(endpoint, &hue))
-            {
-                break;
-            }
-
-            if (EMBER_ZCL_STATUS_SUCCESS != Clusters::ColorControl::Attributes::CurrentSaturation::Get(endpoint, &sat))
-            {
-                break;
-            }
-
-            if (!onoff)
-            {
-                sLightLED.SetLevel(0);
-            }
-            else
-            {
-                if (v.IsNull())
+                if (EMBER_ZCL_STATUS_SUCCESS != Clusters::OnOff::Attributes::OnOff::Get(endpoint, &onoff))
                 {
-                    // Just pick something.
-                    v.SetNonNull(254);
+                    break;
                 }
-#if defined(BL706_NIGHT_LIGHT) || defined(BL602_NIGHT_LIGHT)
-                sLightLED.SetColor(v.Value(), hue, sat);
-#else
-                sLightLED.SetLevel(v.Value());
-#endif
-            }
 
-        } while (0);
-    }
-    else if (APP_EVENT_SYS_BLE_ADV & status)
-    {
+                if (EMBER_ZCL_STATUS_SUCCESS != Clusters::LevelControl::Attributes::CurrentLevel::Get(endpoint, v))
+                {
+                    break;
+                }
+
+                if (EMBER_ZCL_STATUS_SUCCESS != Clusters::ColorControl::Attributes::CurrentHue::Get(endpoint, &hue))
+                {
+                    break;
+                }
+
+                if (EMBER_ZCL_STATUS_SUCCESS != Clusters::ColorControl::Attributes::CurrentSaturation::Get(endpoint, &sat))
+                {
+                    break;
+                }
+
+                if (!onoff)
+                {
+                    sLightLED.SetLevel(0);
+                }
+                else
+                {
+                    if (v.IsNull())
+                    {
+                        // Just pick something.
+                        v.SetNonNull(254);
+                    }
 #if defined(BL706_NIGHT_LIGHT) || defined(BL602_NIGHT_LIGHT)
-        /** show yellow to indicate BLE advertisement */
-        sLightLED.SetColor(254, 35, 254);
+                    sLightLED.SetColor(v.Value(), hue, sat);
 #else
-        /** show 30% brightness to indicate BLE advertisement */
-        sLightLED.SetLevel(25);
+                    sLightLED.SetLevel(v.Value());
 #endif
+                }
+            } while (0);
+        }
+        else
+        {
+#if defined(BL706_NIGHT_LIGHT) || defined(BL602_NIGHT_LIGHT)
+            /** show yellow to indicate not-provision state for extended color light */
+            sLightLED.SetColor(254, 35, 254);
+#else
+            /** show 30% brightness to indicate not-provision state */
+            sLightLED.SetLevel(25);
+#endif
+        }
     }
 }
 
@@ -323,124 +327,40 @@
 
 void AppTask::TimerEventHandler(app_event_t event)
 {
-    if (event & APP_EVENT_BTN_FACTORY_RESET_PRESS)
+    if (GetAppTask().mButtonPressedTime)
     {
-        GetAppTask().mTimerIntvl = APP_BUTTON_PRESS_JITTER;
-        StartTimer();
-    }
-    else if (event & APP_EVENT_BTN_FACTORY_RESET_IND)
-    {
-        if (GetAppTask().mButtonPressedTime)
+#ifdef BOOT_PIN_RESET
+        if (System::SystemClock().GetMonotonicMilliseconds64().count() - GetAppTask().mButtonPressedTime >= APP_BUTTON_PRESS_SHORT)
         {
-            GetAppTask().mIsFactoryResetIndicat = true;
-#if defined(BL706_NIGHT_LIGHT) || defined(BL602_NIGHT_LIGHT)
+#if defined(BL602_NIGHT_LIGHT) || defined(BL706_NIGHT_LIGHT)
+            /** change color to indicate to wait factory reset confirm */
             sLightLED.SetColor(254, 0, 210);
-#ifndef LED_BTN_RESET
-            uint32_t resetCnt               = 0;
-            GetAppTask().mButtonPressedTime = 0;
-            ef_set_env_blob(APP_REBOOT_RESET_COUNT_KEY, &resetCnt, sizeof(resetCnt));
-
-            vTaskDelay(APP_BUTTON_PRESS_LONG);
-            GetAppTask().PostEvent(APP_EVENT_FACTORY_RESET);
-#endif
 #else
+            /** toggle led to indicate to wait factory reset confirm */
             sLightLED.Toggle();
-            GetAppTask().mTimerIntvl = 100;
-            StartTimer();
 #endif
         }
-    }
-
-    if (event & APP_EVENT_BTN_FACTORY_RESET_CANCEL)
-    {
-        GetAppTask().mTimerIntvl = 1000;
-        StartTimer();
-        if (GetAppTask().mIsFactoryResetIndicat)
-        {
-            if (GetAppTask().mIsConnected)
-            {
-                LightingUpdate(APP_EVENT_LIGHTING_MASK);
-            }
-            else
-            {
-                LightingUpdate(APP_EVENT_SYS_BLE_ADV);
-            }
-        }
-        GetAppTask().mIsFactoryResetIndicat = false;
-        GetAppTask().mButtonPressedTime     = 0;
-    }
-
-    if (APP_EVENT_TIMER & event)
-    {
-        if (GetAppTask().mButtonPressedTime)
-        {
-            if (GetAppTask().mIsFactoryResetIndicat)
-            {
-                if (chip::System::SystemClock().GetMonotonicMilliseconds64().count() - GetAppTask().mButtonPressedTime >=
-                    APP_BUTTON_PRESS_LONG)
-                {
-                    /** factory reset indicat done. */
-                    sLightLED.SetOnoff(false);
-                    GetAppTask().mTimerIntvl = 1000;
-                }
-                else
-                {
-#if !(defined(BL706_NIGHT_LIGHT) || defined(BL602_NIGHT_LIGHT))
-                    sLightLED.Toggle();
-#endif
-                }
-            }
-            else
-            {
-
-#if defined(BL706_NIGHT_LIGHT) && !defined(LED_BTN_RESET)
-
-                if (GetAppTask().mButtonPressedTime)
-                {
-                    uint32_t resetCnt = 0;
-
-                    if (chip::System::SystemClock().GetMonotonicMilliseconds64().count() - GetAppTask().mButtonPressedTime >
-                        APP_BUTTON_PRESS_LONG * 2)
-                    {
-                        GetAppTask().mButtonPressedTime = 0;
-                    }
-                    else if (chip::System::SystemClock().GetMonotonicMilliseconds64().count() - GetAppTask().mButtonPressedTime >
-                             APP_BUTTON_PRESS_LONG)
-                    {
-
-                        size_t saved_value_len = 0;
-
-                        ef_get_env_blob(APP_REBOOT_RESET_COUNT_KEY, &resetCnt, sizeof(resetCnt), &saved_value_len);
-                        if (resetCnt >= APP_REBOOT_RESET_COUNT)
-                        {
-                            GetAppTask().PostEvent(APP_EVENT_BTN_FACTORY_RESET_IND);
-                        }
-
-                        /** a power cycle during factory reset indication state will quit factory reset operation */
-                        resetCnt = 0;
-                        ef_set_env_blob(APP_REBOOT_RESET_COUNT_KEY, &resetCnt, sizeof(resetCnt));
-                    }
-                }
 #else
-                if (ButtonPressed())
-                {
-                    if (!GetAppTask().mIsFactoryResetIndicat &&
-                        chip::System::SystemClock().GetMonotonicMilliseconds64().count() - GetAppTask().mButtonPressedTime >=
-                            APP_BUTTON_PRESS_SHORT)
-                    {
-                        GetAppTask().PostEvent(APP_EVENT_BTN_FACTORY_RESET_IND);
-                    }
-                }
-                else
-                {
-                    GetAppTask().PostEvent(APP_EVENT_BTN_FACTORY_RESET_CANCEL);
-                }
-#endif
-            }
+        if (System::SystemClock().GetMonotonicMilliseconds64().count() - GetAppTask().mButtonPressedTime > APP_BUTTON_PRESS_LONG)
+        {
+            /** factory reset confirm timeout */
+            GetAppTask().mButtonPressedTime = 0;
+            GetAppTask().PostEvent(APP_EVENT_FACTORY_RESET);
         }
-
-        StartTimer();
+        else
+        {
+#if defined(BL602_NIGHT_LIGHT) || defined(BL706_NIGHT_LIGHT)
+            /** change color to indicate to wait factory reset confirm */
+            sLightLED.SetColor(254, 0, 210);
+#else
+            /** toggle led to indicate to wait factory reset confirm */
+            sLightLED.Toggle();
+#endif
+        }
+#endif
     }
+
+    StartTimer();
 }
 
 void AppTask::IdentifyStartHandler(Identify *)
@@ -472,7 +392,7 @@
     if (APP_EVENT_IDENTIFY_STOP & event)
     {
         identifyState = 0;
-        LightingUpdate(APP_EVENT_LIGHTING_MASK);
+        GetAppTask().PostEvent(APP_EVENT_LIGHTING_MASK);
         ChipLogProgress(NotSpecified, "identify stop");
     }
 }
@@ -482,13 +402,12 @@
     GetAppTask().PostEvent(APP_EVENT_FACTORY_RESET);
 }
 
-#ifdef LED_BTN_RESET
-hosal_gpio_dev_t gpio_key = { .port = LED_BTN_RESET, .config = INPUT_HIGH_IMPEDANCE, .priv = NULL };
+#ifdef BOOT_PIN_RESET
+hosal_gpio_dev_t gpio_key = { .port = BOOT_PIN_RESET, .config = INPUT_HIGH_IMPEDANCE, .priv = NULL };
 
 void AppTask::ButtonInit(void)
 {
-    GetAppTask().mButtonPressedTime     = 0;
-    GetAppTask().mIsFactoryResetIndicat = false;
+    GetAppTask().mButtonPressedTime = 0;
 
     hosal_gpio_init(&gpio_key);
     hosal_gpio_irq_set(&gpio_key, HOSAL_IRQ_TRIG_POS_PULSE, GetAppTask().ButtonEventHandler, NULL);
@@ -511,9 +430,9 @@
 #else
         bl_set_gpio_intmod(gpio_key.port, 1, HOSAL_IRQ_TRIG_NEG_LEVEL);
 #endif
-
-        GetAppTask().mButtonPressedTime = chip::System::SystemClock().GetMonotonicMilliseconds64().count();
-        GetAppTask().PostEvent(APP_EVENT_BTN_FACTORY_RESET_PRESS);
+        GetAppTask().mButtonPressedTime = System::SystemClock().GetMonotonicMilliseconds64().count();
+        GetAppTask().mTimerIntvl        = APP_BUTTON_PRESS_JITTER;
+        GetAppTask().PostEvent(APP_EVENT_TIMER);
     }
     else
     {
@@ -524,18 +443,20 @@
 #endif
         if (GetAppTask().mButtonPressedTime)
         {
-            presstime = chip::System::SystemClock().GetMonotonicMilliseconds64().count() - GetAppTask().mButtonPressedTime;
+            presstime = System::SystemClock().GetMonotonicMilliseconds64().count() - GetAppTask().mButtonPressedTime;
             if (presstime >= APP_BUTTON_PRESS_LONG)
             {
                 GetAppTask().PostEvent(APP_EVENT_FACTORY_RESET);
             }
             else if (presstime <= APP_BUTTON_PRESS_SHORT && presstime >= APP_BUTTON_PRESS_JITTER)
             {
+                GetAppTask().mTimerIntvl = 1000;
                 GetAppTask().PostEvent(APP_EVENT_BTN_SHORT);
             }
             else
             {
-                GetAppTask().PostEvent(APP_EVENT_BTN_FACTORY_RESET_CANCEL);
+                GetAppTask().mTimerIntvl = 1000;
+                GetAppTask().PostEvent(APP_EVENT_LIGHTING_MASK);
             }
         }
 
diff --git a/examples/lighting-app/bouffalolab/common/AppTask.h b/examples/lighting-app/bouffalolab/common/AppTask.h
index dc16c63..3c32ee7 100644
--- a/examples/lighting-app/bouffalolab/common/AppTask.h
+++ b/examples/lighting-app/bouffalolab/common/AppTask.h
@@ -29,8 +29,8 @@
 using namespace ::chip::DeviceLayer;
 
 #define APP_BUTTON_PRESS_JITTER 50
-#define APP_BUTTON_PRESS_SHORT 1000
-#define APP_BUTTON_PRESS_LONG 4000
+#define APP_BUTTON_PRESS_SHORT 1500
+#define APP_BUTTON_PRESS_LONG 5000
 
 #define APP_LIGHT_ENDPOINT_ID 1
 #define APP_REBOOT_RESET_COUNT 3
@@ -55,23 +55,9 @@
     {
         APP_EVENT_NONE = 0x00000000,
 
-        APP_EVENT_BTN_FACTORY_RESET_CANCEL = 0x00000002,
-        APP_EVENT_BTN_FACTORY_RESET_IND    = 0x00000004,
-        APP_EVENT_BTN_FACTORY_RESET_PRESS  = 0x00000008,
-
-        APP_EVENT_BTN_ALL_MASK =
-            APP_EVENT_BTN_FACTORY_RESET_CANCEL | APP_EVENT_BTN_FACTORY_RESET_IND | APP_EVENT_BTN_FACTORY_RESET_PRESS,
-        APP_EVENT_TIMER     = 0x00000010,
-        APP_EVENT_BTN_SHORT = 0x00000020,
-
-        APP_EVENT_SYS_BLE_ADV      = 0x00000100,
-        APP_EVENT_SYS_BLE_CONN     = 0x00000200,
-        APP_EVENT_SYS_PROVISIONED  = 0x00000400,
-        APP_EVENT_SYS_LIGHT_TOGGLE = 0x00000800,
-        APP_EVENT_FACTORY_RESET    = 0x00001000,
-
-        APP_EVENT_SYS_ALL_MASK =
-            APP_EVENT_SYS_BLE_ADV | APP_EVENT_SYS_BLE_CONN | APP_EVENT_SYS_PROVISIONED | APP_EVENT_FACTORY_RESET,
+        APP_EVENT_TIMER         = 0x00000010,
+        APP_EVENT_BTN_SHORT     = 0x00000020,
+        APP_EVENT_FACTORY_RESET = 0x00000040,
 
         APP_EVENT_LIGHTING_ONOFF = 0x00010000,
         APP_EVENT_LIGHTING_LEVEL = 0x00020000,
@@ -83,8 +69,7 @@
         APP_EVENT_IDENTIFY_STOP     = 0x04000000,
         APP_EVENT_IDENTIFY_MASK     = APP_EVENT_IDENTIFY_START | APP_EVENT_IDENTIFY_IDENTIFY | APP_EVENT_IDENTIFY_STOP,
 
-        APP_EVENT_ALL_MASK = APP_EVENT_LIGHTING_MASK | APP_EVENT_BTN_ALL_MASK | APP_EVENT_SYS_ALL_MASK | APP_EVENT_TIMER |
-            APP_EVENT_BTN_SHORT | APP_EVENT_IDENTIFY_MASK,
+        APP_EVENT_ALL_MASK = APP_EVENT_LIGHTING_MASK | APP_EVENT_TIMER | APP_EVENT_BTN_SHORT | APP_EVENT_IDENTIFY_MASK,
     };
 
     void SetEndpointId(EndpointId endpointId)
@@ -100,7 +85,6 @@
     static void IdentifyStartHandler(Identify *);
     static void IdentifyStopHandler(Identify *);
     static void IdentifyHandleOp(app_event_t event);
-    bool mIsConnected;
 
 private:
     friend void StartAppTask(void);
@@ -119,7 +103,7 @@
     static void TimerEventHandler(app_event_t event);
     static void TimerCallback(TimerHandle_t xTimer);
 
-#ifdef LED_BTN_RESET
+#ifdef BOOT_PIN_RESET
     static void ButtonInit(void);
     static bool ButtonPressed(void);
     static void ButtonEventHandler(void * arg);
@@ -137,7 +121,6 @@
     TimerHandle_t sTimer;
     uint32_t mTimerIntvl;
     uint64_t mButtonPressedTime;
-    bool mIsFactoryResetIndicat;
 
     static StackType_t appStack[APP_TASK_STACK_SIZE / sizeof(StackType_t)];
     static StaticTask_t appTaskStruct;
diff --git a/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.matter b/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.matter
index 383979f..761728c 100644
--- a/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.matter
+++ b/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.matter
@@ -2140,17 +2140,17 @@
   }
 
   server cluster OnOff {
-    persist  attribute onOff default = 0x00;
+    persist  attribute onOff default = 0x01;
     ram      attribute globalSceneControl default = 0x01;
     ram      attribute onTime default = 0x0000;
     ram      attribute offWaitTime default = 0x0000;
-    persist  attribute startUpOnOff default = 0xFF;
+    persist  attribute startUpOnOff;
     ram      attribute featureMap default = 1;
     ram      attribute clusterRevision default = 5;
   }
 
   server cluster LevelControl {
-    persist  attribute currentLevel default = 0x01;
+    persist  attribute currentLevel default = 0x254;
     ram      attribute remainingTime default = 0x0000;
     ram      attribute minLevel default = 0x01;
     ram      attribute maxLevel default = 0xFE;
@@ -2159,11 +2159,11 @@
     ram      attribute maxFrequency default = 0x0000;
     ram      attribute options default = 0x00;
     ram      attribute onOffTransitionTime default = 0x0000;
-    ram      attribute onLevel default = 0xFF;
+    ram      attribute onLevel;
     ram      attribute onTransitionTime;
     ram      attribute offTransitionTime;
     ram      attribute defaultMoveRate default = 50;
-    persist  attribute startUpCurrentLevel default = 255;
+    persist  attribute startUpCurrentLevel;
     ram      attribute featureMap default = 3;
     ram      attribute clusterRevision default = 5;
   }
diff --git a/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.zap b/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.zap
index 5b31d85..852948f 100644
--- a/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.zap
+++ b/examples/lighting-app/bouffalolab/data_model/lighting-app-thread.zap
@@ -6087,7 +6087,7 @@
               "storageOption": "NVM",
               "singleton": 0,
               "bounded": 0,
-              "defaultValue": "0x00",
+              "defaultValue": "0x01",
               "reportable": 1,
               "minInterval": 0,
               "maxInterval": 65344,
@@ -6151,7 +6151,7 @@
               "storageOption": "NVM",
               "singleton": 0,
               "bounded": 0,
-              "defaultValue": "0xFF",
+              "defaultValue": null,
               "reportable": 1,
               "minInterval": 0,
               "maxInterval": 65344,
@@ -6301,7 +6301,7 @@
               "storageOption": "NVM",
               "singleton": 0,
               "bounded": 0,
-              "defaultValue": "0x01",
+              "defaultValue": "0x254",
               "reportable": 1,
               "minInterval": 0,
               "maxInterval": 65344,
@@ -6445,7 +6445,7 @@
               "storageOption": "RAM",
               "singleton": 0,
               "bounded": 0,
-              "defaultValue": "0xFF",
+              "defaultValue": null,
               "reportable": 1,
               "minInterval": 1,
               "maxInterval": 65534,
@@ -6509,7 +6509,7 @@
               "storageOption": "NVM",
               "singleton": 0,
               "bounded": 0,
-              "defaultValue": "255",
+              "defaultValue": null,
               "reportable": 1,
               "minInterval": 0,
               "maxInterval": 65344,
@@ -8341,5 +8341,6 @@
       "endpointVersion": 1,
       "deviceIdentifier": 269
     }
-  ]
-}
\ No newline at end of file
+  ],
+  "log": []
+}
diff --git a/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.matter b/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.matter
index 06da353..cec65b4 100644
--- a/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.matter
+++ b/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.matter
@@ -2002,17 +2002,17 @@
   }
 
   server cluster OnOff {
-    persist  attribute onOff default = 0x00;
+    persist  attribute onOff default = 0x1;
     ram      attribute globalSceneControl default = 0x01;
     ram      attribute onTime default = 0x0000;
     ram      attribute offWaitTime default = 0x0000;
-    persist  attribute startUpOnOff default = 0xFF;
+    persist  attribute startUpOnOff;
     ram      attribute featureMap default = 1;
     ram      attribute clusterRevision default = 5;
   }
 
   server cluster LevelControl {
-    persist  attribute currentLevel default = 0x01;
+    persist  attribute currentLevel default = 0x254;
     ram      attribute remainingTime default = 0x0000;
     ram      attribute minLevel default = 0x01;
     ram      attribute maxLevel default = 0xFE;
@@ -2021,11 +2021,11 @@
     ram      attribute maxFrequency default = 0x0000;
     ram      attribute options default = 0x00;
     ram      attribute onOffTransitionTime default = 0x0000;
-    ram      attribute onLevel default = 0xFF;
+    ram      attribute onLevel;
     ram      attribute onTransitionTime;
     ram      attribute offTransitionTime;
     ram      attribute defaultMoveRate default = 50;
-    persist  attribute startUpCurrentLevel default = 255;
+    persist  attribute startUpCurrentLevel;
     ram      attribute featureMap default = 3;
     ram      attribute clusterRevision default = 5;
   }
diff --git a/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.zap b/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.zap
index 8d717c4..90bd7a2 100644
--- a/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.zap
+++ b/examples/lighting-app/bouffalolab/data_model/lighting-app-wifi.zap
@@ -6087,7 +6087,7 @@
               "storageOption": "NVM",
               "singleton": 0,
               "bounded": 0,
-              "defaultValue": "0x00",
+              "defaultValue": "0x1",
               "reportable": 1,
               "minInterval": 0,
               "maxInterval": 65344,
@@ -6151,7 +6151,7 @@
               "storageOption": "NVM",
               "singleton": 0,
               "bounded": 0,
-              "defaultValue": "0xFF",
+              "defaultValue": null,
               "reportable": 1,
               "minInterval": 0,
               "maxInterval": 65344,
@@ -6301,7 +6301,7 @@
               "storageOption": "NVM",
               "singleton": 0,
               "bounded": 0,
-              "defaultValue": "0x01",
+              "defaultValue": "0x254",
               "reportable": 1,
               "minInterval": 0,
               "maxInterval": 65344,
@@ -6445,7 +6445,7 @@
               "storageOption": "RAM",
               "singleton": 0,
               "bounded": 0,
-              "defaultValue": "0xFF",
+              "defaultValue": null,
               "reportable": 1,
               "minInterval": 1,
               "maxInterval": 65534,
@@ -6509,7 +6509,7 @@
               "storageOption": "NVM",
               "singleton": 0,
               "bounded": 0,
-              "defaultValue": "255",
+              "defaultValue": null,
               "reportable": 1,
               "minInterval": 0,
               "maxInterval": 65344,
@@ -8341,5 +8341,6 @@
       "endpointVersion": 1,
       "deviceIdentifier": 269
     }
-  ]
-}
\ No newline at end of file
+  ],
+  "log": []
+}
diff --git a/examples/platform/bouffalolab/bl702/ldscripts/psram_flash.ld b/examples/platform/bouffalolab/bl702/ldscripts/psram_flash.ld
index c31a453..c18b569 100644
--- a/examples/platform/bouffalolab/bl702/ldscripts/psram_flash.ld
+++ b/examples/platform/bouffalolab/bl702/ldscripts/psram_flash.ld
@@ -214,79 +214,44 @@
 
     PROVIDE ( __psram_bss_init_start = . );
     /** put the bss data in psram between __psram_bss_init_start and __psram_bss_init_end will bet reset to 0 after psram init*/
-    . = ALIGN(8);
-    KEEP(*lighting-common.*.cpp.o(.bss.*ttributeData*))
-    . = ALIGN(8);
-    KEEP(*lighting-common.*.cpp.o(.bss.*bindingTable*))
-    . = ALIGN(8);
-    KEEP(*lighting-common.*.cpp.o(.bss.appResponseData*))
-    . = ALIGN(8);
-    KEEP(*lighting-common.*.cpp.o(.bss.*NetworkCommissioning*))
-    
-    . = ALIGN(8);
-    KEEP(*dnssd.Advertiser_ImplMinimalMdns.cpp.o(.bss.*gAdvertiser*))
-    . = ALIGN(8);
-    KEEP(*dnssd.MinimalMdnsServer.cpp.o(.bss.*GlobalMinimalMdnsServer*_instance))
-    . = ALIGN(8);
-    KEEP(*dnssd.Resolver_ImplMinimalMdns.cpp.o(.bss.*gResolver*))
-
-    /*. = ALIGN(8);*/
-    /*KEEP(*libCHIPAppServer.Server.cpp.o(.bss.*sServer*))*/
-
-    . = ALIGN(8);
-    KEEP(*bridge-common.*.cpp.o(.bss.*))
-    /* . = ALIGN(8); */
-    /* # KEEP(*bridge-common.*.cpp.o(.bss.*bindingTable*)) */
-    /* # . = ALIGN(8); */
-    /* # KEEP(*bridge-common.*.cpp.o(.bss.appResponseData*)) */
-    /* # . = ALIGN(8); */
-    /* # KEEP(*bridge-common.*.cpp.o(.bss.*NetworkCommissioning*)) */
-
-    . = ALIGN(8);
-    KEEP(*libopenthread-cli-*.cli.cpp.o(.bss.*sInterpreterRaw*))
-
-    . = ALIGN(8);
-    KEEP(*libopenthread-cli-*.cli_dataset.cpp.o(.bss.*sDataset*))
-
-    . = ALIGN(8);
-    KEEP(*libopenthread-ftd.instance.cpp.o(.bss.*gInstanceRaw*))
-
-    . = ALIGN(8);
-    KEEP(*commands.Dns.cpp.o(.bss.*))
-
-    . = ALIGN(8);
-    KEEP(*commands.BLE.cpp.o(.bss.*))
-
-    . = ALIGN(8);
-    KEEP(*commands.Device.cpp.o(.bss.*))
-
-    . = ALIGN(8);
-    KEEP(*commands.Base64.cpp.o(.bss.*))
-
-    . = ALIGN(8);
-    KEEP(*commands.Base64.cpp.o(.bss.*))
-
-    . = ALIGN(8);
-/*    KEEP(*shell_common.cmd_*.cpp.o(.bss.*))*/
-
-    . = ALIGN(8);
-    KEEP(*shell_core.Engine.cpp.o(.bss.*theEngineRoot*)) 
-
-    . = ALIGN(8);
-    /* KEEP(*shell_common.globals.cpp.o(.bss.*))               */
-
-    . = ALIGN(8);
-    KEEP(*lwip.memp.c.o(.bss.lwip_PBUF_POOL))
-    . = ALIGN(8);
-    KEEP(*sdk_lwip.dns.c.o(.bss.dns_table))
-
-    . = ALIGN(8);
-    KEEP(*virt_net_spi.c.o(.bss.tx_buffer))
-
-    PROVIDE ( __psram_bss_init_end = . );
     . = ALIGN(16);
+    KEEP(*libCHIP.a:*(.sbss.*))
+    KEEP(*libCHIP.a:*(.bss.*))
 
+    . = ALIGN(16);
+    KEEP(*libCHIPAppServer.a:*(.sbss.*))
+    KEEP(*libCHIPAppServer.a:*(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*libMatterDeviceInfoProviderExample.a:*(.sbss.*))
+    KEEP(*libMatterDeviceInfoProviderExample.a:*(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*src/app/clusters/*/bouffalolab*.cpp.o(.sbss.*))
+    KEEP(*src/app/clusters/*/bouffalolab*.cpp.o(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*examples/platform/bouffalolab/common/plat/chip*.c.o(.sbss.*))
+    KEEP(*examples/platform/bouffalolab/common/plat/chip*.c.o(.sbss.*))
+    KEEP(*examples/platform/bouffalolab/common/plat/chip*.cpp.o(.bss.*))
+    KEEP(*examples/platform/bouffalolab/common/plat/chip*.cpp.o(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*examples/*/bouffalolab/common/chip*.c.o(.sbss.*))
+    KEEP(*examples/*/bouffalolab/common/chip*.c.o(.sbss.*))
+    KEEP(*examples/*/bouffalolab/common/chip*.cpp.o(.bss.*))
+    KEEP(*examples/*/bouffalolab/common/chip*.cpp.o(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*sdk_lwip.*.c.o(.sbss.*))
+    KEEP(*sdk_lwip.*.c.o(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*stack_main.o(.bss.*))
+    
+    . = ALIGN(16);
     *(.wifi_ram*)
+    PROVIDE ( __psram_bss_init_end = . );
   } >psram
 
   . = ALIGN(8);
diff --git a/examples/platform/bouffalolab/bl702l/ldscripts/psram_flash_rom.ld b/examples/platform/bouffalolab/bl702l/ldscripts/psram_flash_rom.ld
index 6dce5b3..60d1ea8 100644
--- a/examples/platform/bouffalolab/bl702l/ldscripts/psram_flash_rom.ld
+++ b/examples/platform/bouffalolab/bl702l/ldscripts/psram_flash_rom.ld
@@ -10,7 +10,7 @@
   flash  (rxai!w) : ORIGIN = 0x23000000, LENGTH = (2M)
   tcm_ocram (wxa) : ORIGIN = 0x4201C000 + __CACHE_SIZE, LENGTH = (16K - __CACHE_SIZE + 80K - __EM_SIZE)
   hbnram    (wxa) : ORIGIN = 0x40010000, LENGTH = (4K)
-  psram     (wxa) : ORIGIN = 0x26000000, LENGTH = (2M)
+  psram     (wxa) : ORIGIN = 0x24000000, LENGTH = (2M)
 }
 
 SECTIONS
@@ -169,91 +169,53 @@
 
     PROVIDE ( __psram_bss_init_start = . );
     /** put the bss data in psram between __psram_bss_init_start and __psram_bss_init_end will bet reset to 0 after psram init*/
-    . = ALIGN(8);
-    KEEP(*lighting-common.*.cpp.o(.bss.*ttributeData*))
-    . = ALIGN(8);
-    KEEP(*lighting-common.*.cpp.o(.bss.*bindingTable*))
-    . = ALIGN(8);
-    KEEP(*lighting-common.*.cpp.o(.bss.appResponseData*))
-    . = ALIGN(8);
-    KEEP(*lighting-common.*.cpp.o(.bss.*NetworkCommissioning*))
-    
-    . = ALIGN(8);
-    KEEP(*dnssd.Advertiser_ImplMinimalMdns.cpp.o(.bss.*gAdvertiser*))
-    . = ALIGN(8);
-    KEEP(*dnssd.MinimalMdnsServer.cpp.o(.bss.*GlobalMinimalMdnsServer*_instance))
-    . = ALIGN(8);
-    KEEP(*dnssd.Resolver_ImplMinimalMdns.cpp.o(.bss.*gResolver*))
-
-    /*. = ALIGN(8);*/
-    /*KEEP(*libCHIPAppServer.Server.cpp.o(.bss.*sServer*))*/
-
-    . = ALIGN(8);
-    KEEP(*bridge-common.*.cpp.o(.bss.*))
-    /* . = ALIGN(8); */
-    /* # KEEP(*bridge-common.*.cpp.o(.bss.*bindingTable*)) */
-    /* # . = ALIGN(8); */
-    /* # KEEP(*bridge-common.*.cpp.o(.bss.appResponseData*)) */
-    /* # . = ALIGN(8); */
-    /* # KEEP(*bridge-common.*.cpp.o(.bss.*NetworkCommissioning*)) */
-
-    . = ALIGN(8);
-    KEEP(*libopenthread-cli-*.cli.cpp.o(.bss.*sInterpreterRaw*))
-
-    . = ALIGN(8);
-    KEEP(*libopenthread-cli-*.cli_dataset.cpp.o(.bss.*sDataset*))
-
-    . = ALIGN(8);
-    KEEP(*libopenthread-ftd.instance.cpp.o(.bss.*gInstanceRaw*))
-
-    . = ALIGN(8);
-    KEEP(*commands.Dns.cpp.o(.bss.*))
-
-    . = ALIGN(8);
-    KEEP(*commands.BLE.cpp.o(.bss.*))
-
-    . = ALIGN(8);
-    KEEP(*commands.Device.cpp.o(.bss.*))
-
-    . = ALIGN(8);
-    KEEP(*commands.Base64.cpp.o(.bss.*))
-
-    . = ALIGN(8);
-    KEEP(*commands.Base64.cpp.o(.bss.*))
-
-    . = ALIGN(8);
-    KEEP(*shell_core.Engine.cpp.o(.bss.*theEngineRoot*)) 
-
-    . = ALIGN(8);
-    KEEP(*sdk_openthread_port.ot_radio.c.o(.bss.otRadio_buffPool)) 
-
-    . = ALIGN(8);
-    KEEP(*BL702L.PlatformManagerImpl.cpp.o(.bss._ZN4chip11DeviceLayer19PlatformManagerImpl9sInstanceE)) 
-
-    . = ALIGN(8);
-    KEEP(*BL702L.ThreadStackManagerImpl.cpp.o(.bss._ZN4chip11DeviceLayer22ThreadStackManagerImpl9sInstanceE)) 
-
-    . = ALIGN(8);
-    KEEP(*libCHIPAppServer.Server.cpp.o(.bss._ZN4chip6Server7sServerE)) 
-
-    . = ALIGN(8);
-    KEEP(*libaccess.ExampleAccessControlDelegate.cpp.o(.bss.*)) 
-
-    . = ALIGN(8);
-    KEEP(*libTransportLayer.SessionManager.cpp.o(.bss.*)) 
-
-    . = ALIGN(8);
-    KEEP(*lwip.memp.c.o(.bss.*))
-    . = ALIGN(8);
-    KEEP(*sdk_lwip.dns.c.o(.bss.dns_table))
-
-    . = ALIGN(8);
-    KEEP(*virt_net_spi.c.o(.bss.tx_buffer))
-  
-    PROVIDE ( __psram_bss_init_end = . );
     . = ALIGN(16);
+    KEEP(*libCHIP.a:*(.sbss.*))
+    KEEP(*libCHIP.a:*(.bss.*))
 
+    . = ALIGN(16);
+    KEEP(*libCHIPAppServer.a:*(.sbss.*))
+    KEEP(*libCHIPAppServer.a:*(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*libMatterDeviceInfoProviderExample.a:*(.sbss.*))
+    KEEP(*libMatterDeviceInfoProviderExample.a:*(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*libopenthread-ftd.a:*(.sbss.*))
+    KEEP(*libopenthread-ftd.a:*(.bss.*))
+    KEEP(*libopenthread-mtd.a:*(.sbss.*))
+    KEEP(*libopenthread-mtd.a:*(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*src/app/clusters/*/bouffalolab*.cpp.o(.sbss.*))
+    KEEP(*src/app/clusters/*/bouffalolab*.cpp.o(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*examples/platform/bouffalolab/common/plat/chip*.c.o(.sbss.*))
+    KEEP(*examples/platform/bouffalolab/common/plat/chip*.c.o(.sbss.*))
+    KEEP(*examples/platform/bouffalolab/common/plat/chip*.cpp.o(.bss.*))
+    KEEP(*examples/platform/bouffalolab/common/plat/chip*.cpp.o(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*examples/*/bouffalolab/common/chip*.c.o(.sbss.*))
+    KEEP(*examples/*/bouffalolab/common/chip*.c.o(.sbss.*))
+    KEEP(*examples/*/bouffalolab/common/chip*.cpp.o(.bss.*))
+    KEEP(*examples/*/bouffalolab/common/chip*.cpp.o(.bss.*))
+
+    . = ALIGN(16);
+    KEEP(*sdk_lwip.*.c.o(.sbss.*))
+    KEEP(*sdk_lwip.*.c.o(.bss.*))
+    KEEP(*lwip.*.c.o(.bss.*))
+
+
+
+    . = ALIGN(16);
+    KEEP(*stack_main.o(.bss.*))
+    
+    . = ALIGN(16);
     *(.wifi_ram*)
+    PROVIDE ( __psram_bss_init_end = . );
   } > psram
 
   . = ALIGN(8);
diff --git a/examples/platform/bouffalolab/common/plat/MemMonitoring.cpp b/examples/platform/bouffalolab/common/plat/MemMonitoring.cpp
index 3e66d05..6e58131 100644
--- a/examples/platform/bouffalolab/common/plat/MemMonitoring.cpp
+++ b/examples/platform/bouffalolab/common/plat/MemMonitoring.cpp
@@ -18,8 +18,6 @@
 
 #include <FreeRTOS.h>
 #include <MemMonitoring.h>
-#include <lib/support/CodeUtils.h>
-#include <lib/support/ErrorStr.h>
 #include <plat.h>
 #include <platform/CHIPDeviceLayer.h>
 
diff --git a/examples/platform/bouffalolab/common/plat/demo_pwm.c b/examples/platform/bouffalolab/common/plat/demo_pwm.c
index 58e6376..c279ddc 100644
--- a/examples/platform/bouffalolab/common/plat/demo_pwm.c
+++ b/examples/platform/bouffalolab/common/plat/demo_pwm.c
@@ -4,12 +4,13 @@
  * Contact information:
  * web site:    https://www.bouffalolab.com/
  */
-
-#include "demo_pwm.h"
-#include "board.h"
-#include <hosal_pwm.h>
 #include <stdio.h>
 
+#include <hosal_pwm.h>
+
+#include "board.h"
+#include "demo_pwm.h"
+
 #define PWM_FREQ 1000
 #define PWM_DUTY_CYCLE 10000
 
diff --git a/examples/platform/bouffalolab/common/plat/main.cpp b/examples/platform/bouffalolab/common/plat/main.cpp
index abf7ef6..bf04405 100644
--- a/examples/platform/bouffalolab/common/plat/main.cpp
+++ b/examples/platform/bouffalolab/common/plat/main.cpp
@@ -27,8 +27,6 @@
 
 #include <AppTask.h>
 #include <easyflash.h>
-#include <lib/support/CHIPMem.h>
-#include <lib/support/CHIPPlatformMemory.h>
 #include <plat.h>
 
 extern "C" {
@@ -45,7 +43,9 @@
 #include <wifi_mgmr_ext.h>
 #endif
 #include <bl_irq.h>
+#if defined(BL702L_ENABLE)
 #include <bl_rtc.h>
+#endif
 #include <bl_sec.h>
 #include <bl_sys.h>
 #ifdef CFG_USE_PSRAM
@@ -64,6 +64,7 @@
 #endif
 
 #include "board.h"
+#include <uart.h>
 }
 
 using namespace ::chip;
@@ -138,15 +139,13 @@
     /* If the buffers to be provided to the Idle task are declared inside this
     function then they must be declared static - otherwise they will be allocated on
     the stack and so not exists after this function exits. */
-    static StaticTask_t xIdleTaskTCB;
-    static StackType_t uxIdleTaskStack[configMINIMAL_STACK_SIZE];
 
     /* Pass out a pointer to the StaticTask_t structure in which the Idle task's
     state will be stored. */
-    *ppxIdleTaskTCBBuffer = &xIdleTaskTCB;
+    *ppxIdleTaskTCBBuffer = (StaticTask_t *) pvPortMalloc(sizeof(StaticTask_t));
 
     /* Pass out the array that will be used as the Idle task's stack. */
-    *ppxIdleTaskStackBuffer = uxIdleTaskStack;
+    *ppxIdleTaskStackBuffer = (StackType_t *) pvPortMalloc(sizeof(StackType_t) * configMINIMAL_STACK_SIZE);
 
     /* Pass out the size of the array pointed to by *ppxIdleTaskStackBuffer.
     Note that, as the array is necessarily of type StackType_t,
@@ -163,15 +162,13 @@
     /* If the buffers to be provided to the Timer task are declared inside this
     function then they must be declared static - otherwise they will be allocated on
     the stack and so not exists after this function exits. */
-    static StaticTask_t xTimerTaskTCB;
-    static StackType_t uxTimerTaskStack[configTIMER_TASK_STACK_DEPTH];
 
     /* Pass out a pointer to the StaticTask_t structure in which the Timer
     task's state will be stored. */
-    *ppxTimerTaskTCBBuffer = &xTimerTaskTCB;
+    *ppxTimerTaskTCBBuffer = (StaticTask_t *) pvPortMalloc(sizeof(StaticTask_t));
 
     /* Pass out the array that will be used as the Timer task's stack. */
-    *ppxTimerTaskStackBuffer = uxTimerTaskStack;
+    *ppxTimerTaskStackBuffer = (StackType_t *) pvPortMalloc(sizeof(StackType_t) * configTIMER_TASK_STACK_DEPTH);
 
     /* Pass out the size of the array pointed to by *ppxTimerTaskStackBuffer.
     Note that, as the array is necessarily of type StackType_t,
@@ -196,7 +193,15 @@
     void * ra = (void *) __builtin_return_address(0);
 
     taskDISABLE_INTERRUPTS();
-    ChipLogProgress(NotSpecified, "vAssertCalled, ra= %p", ra);
+    if (xPortIsInsideInterrupt())
+    {
+        printf("vAssertCalled, ra = %p in ISR\r\n", (void *) ra);
+    }
+    else
+    {
+        printf("vAssertCalled, ra = %p in task %s\r\n", (void *) ra, pcTaskGetName(NULL));
+    }
+
     while (true)
         ;
 }
@@ -208,7 +213,15 @@
     void * ra = (void *) __builtin_return_address(0);
 
     taskDISABLE_INTERRUPTS();
-    ChipLogProgress(NotSpecified, "vAssertCalled, ra= %p", ra);
+    if (xPortIsInsideInterrupt())
+    {
+        printf("vAssertCalled, ra = %p in ISR\r\n", (void *) ra);
+    }
+    else
+    {
+        printf("vAssertCalled, ra = %p in task %s\r\n", (void *) ra, pcTaskGetName(NULL));
+    }
+
     while (true)
         ;
 }
@@ -330,20 +343,6 @@
 }
 #endif
 
-#ifdef BL702L_ENABLE
-void exception_entry_app(uint32_t mcause, uint32_t mepc, uint32_t mtval, uintptr_t * regs, uintptr_t * tasksp)
-{
-    static const char dbg_str[] = "Exception Entry--->>>\r\n mcause %08lx, mepc %08lx, mtval %08lx\r\n";
-
-    printf(dbg_str, mcause, mepc, mtval);
-
-    while (1)
-    {
-        /*dead loop now*/
-    }
-}
-#endif
-
 extern "C" void setup_heap()
 {
     bl_sys_init();
@@ -362,16 +361,6 @@
 
     vPortDefineHeapRegions(xHeapRegions);
 
-    bl_sys_early_init();
-
-#ifdef BL702L_ENABLE
-    rom_freertos_init(256, 400);
-    rom_hal_init();
-    rom_lmac154_hook_init();
-
-    exception_entry_ptr = exception_entry_app;
-#endif
-
 #ifdef CFG_USE_PSRAM
     bl_psram_init();
     do_psram_test();
@@ -386,6 +375,14 @@
 
 extern "C" void app_init(void)
 {
+    bl_sys_early_init();
+
+#ifdef BL702L_ENABLE
+    rom_freertos_init(256, 400);
+    rom_hal_init();
+    rom_lmac154_hook_init();
+#endif
+
     hosal_uart_init(&uart_stdio);
 
     ChipLogProgress(NotSpecified, "==================================================");
@@ -403,7 +400,9 @@
 
     blog_init();
     bl_irq_init();
+#if defined(BL702L_ENABLE)
     bl_rtc_init();
+#endif
     bl_sec_init();
 #if defined(BL702_ENABLE)
     bl_timer_init();
@@ -414,6 +413,9 @@
     /* board config is set after system is init*/
     hal_board_cfg(0);
 
+#if defined(BL702L_ENABLE) || defined(BL706_WIFI)
+    hosal_dma_init();
+#endif
 #ifdef BL602_ENABLE
     wifi_td_diagnosis_init();
 #endif
@@ -423,12 +425,9 @@
 {
     app_init();
 
-    easyflash_init();
-    ef_load_env_cache();
-
-    ChipLogProgress(NotSpecified, "Init CHIP Memory");
-    chip::Platform::MemoryInit(NULL, 0);
-
+#if CONFIG_ENABLE_CHIP_SHELL || PW_RPC_ENABLED
+    uartInit();
+#endif
 #ifdef SYS_AOS_LOOP_ENABLE
     ChipLogProgress(NotSpecified, "Starting AOS loop Task");
     aos_loop_start();
@@ -439,6 +438,12 @@
 #endif
 #endif
 
+    easyflash_init();
+    ef_load_env_cache();
+
+    ChipLogProgress(NotSpecified, "Init CHIP Memory");
+    chip::Platform::MemoryInit(NULL, 0);
+
     ChipLogProgress(NotSpecified, "Starting App Task");
     StartAppTask();
 
diff --git a/examples/platform/bouffalolab/common/plat/platform.cpp b/examples/platform/bouffalolab/common/plat/platform.cpp
index dc2f2a0..d2e6a43 100644
--- a/examples/platform/bouffalolab/common/plat/platform.cpp
+++ b/examples/platform/bouffalolab/common/plat/platform.cpp
@@ -15,26 +15,40 @@
  *    See the License for the specific language governing permissions and
  *    limitations under the License.
  */
-
+#include <DeviceInfoProviderImpl.h>
+#include <OTAConfig.h>
 #include <app/server/Dnssd.h>
 #include <app/server/OnboardingCodesUtil.h>
 #include <app/server/Server.h>
 #include <credentials/DeviceAttestationCredsProvider.h>
 #include <credentials/examples/DeviceAttestationCredsExample.h>
-#include <lib/support/CodeUtils.h>
-#include <lib/support/ErrorStr.h>
+#include <platform/bouffalolab/common/PlatformManagerImpl.h>
 #include <system/SystemClock.h>
 
+#if HEAP_MONITORING
+#include <MemMonitoring.h>
+#endif
+
+#if CONFIG_ENABLE_CHIP_SHELL
+#include <ChipShellCollection.h>
+#include <lib/shell/Engine.h>
+#endif
+
+#if PW_RPC_ENABLED
+#include <PigweedLogger.h>
+#include <Rpc.h>
+#endif
+#if CONFIG_ENABLE_CHIP_SHELL || PW_RPC_ENABLED
+#include <uart.h>
+#endif
+
+#if CONFIG_BOUFFALOLAB_FACTORY_DATA_ENABLE || defined(CONFIG_BOUFFALOLAB_FACTORY_DATA_TEST)
+#include <platform/bouffalolab/common/FactoryDataProvider.h>
+#endif
+
 #if CHIP_DEVICE_CONFIG_ENABLE_WIFI
 #include <NetworkCommissioningDriver.h>
 #include <app/clusters/network-commissioning/network-commissioning.h>
-#include <route_hook/bl_route_hook.h>
-#endif
-#include <platform/bouffalolab/common/PlatformManagerImpl.h>
-
-#if HEAP_MONITORING
-#include <MemMonitoring.h>
-#include <lib/support/CHIPMem.h>
 #endif
 
 #if CHIP_ENABLE_OPENTHREAD
@@ -44,27 +58,18 @@
 #include <utils_list.h>
 #endif
 
-#ifdef OTA_ENABLED
-#include "OTAConfig.h"
-#endif // OTA_ENABLED
-
-#if CONFIG_ENABLE_CHIP_SHELL
-#include <ChipShellCollection.h>
-#include <lib/shell/Engine.h>
+#if !CHIP_DEVICE_CONFIG_ENABLE_THREAD
+#include <lwip/netif.h>
+#if CHIP_DEVICE_CONFIG_ENABLE_WIFI
+#if defined(BL602_ENABLE)
+#include <wifi_mgmr_ext.h>
+#else
+#include <platform/bouffalolab/BL702/WiFiInterface.h>
 #endif
-
-#if PW_RPC_ENABLED
-#include "PigweedLogger.h"
-#include "Rpc.h"
+#else
+#include <platform/bouffalolab/BL702/EthernetInterface.h>
 #endif
-
-#include <DeviceInfoProviderImpl.h>
-#if CONFIG_BOUFFALOLAB_FACTORY_DATA_ENABLE || defined(CONFIG_BOUFFALOLAB_FACTORY_DATA_TEST)
-#include <platform/bouffalolab/common/FactoryDataProvider.h>
-#endif
-
-#if CONFIG_ENABLE_CHIP_SHELL || PW_RPC_ENABLED
-#include "uart.h"
+#include <bl_route_hook.h>
 #endif
 
 #include <AppTask.h>
@@ -95,55 +100,18 @@
     switch (event->Type)
     {
     case DeviceEventType::kCHIPoBLEAdvertisingChange:
-
-#if CHIP_DEVICE_CONFIG_ENABLE_WIFI
-        GetAppTask().mIsConnected = ConnectivityMgr().IsWiFiStationConnected();
-#endif
-#if CHIP_DEVICE_CONFIG_ENABLE_THREAD
-        GetAppTask().mIsConnected = ConnectivityMgr().IsThreadAttached();
-#endif
-
-        if (ConnectivityMgr().NumBLEConnections())
-        {
-            GetAppTask().PostEvent(AppTask::APP_EVENT_SYS_BLE_CONN);
-        }
-        else
-        {
-            GetAppTask().PostEvent(AppTask::APP_EVENT_SYS_BLE_ADV);
-        }
         ChipLogProgress(NotSpecified, "BLE adv changed, connection number: %d", ConnectivityMgr().NumBLEConnections());
         break;
 #if CHIP_DEVICE_CONFIG_ENABLE_THREAD
     case DeviceEventType::kThreadStateChange:
 
-        ChipLogProgress(NotSpecified, "Thread state changed, IsThreadAttached: %d", ConnectivityMgr().IsThreadAttached());
-        if (!GetAppTask().mIsConnected && ConnectivityMgr().IsThreadAttached())
+        if (ConnectivityMgr().IsThreadAttached())
         {
-            GetAppTask().PostEvent(AppTask::APP_EVENT_SYS_PROVISIONED);
-            GetAppTask().mIsConnected = true;
-#ifdef OTA_ENABLED
             chip::DeviceLayer::SystemLayer().StartTimer(chip::System::Clock::Seconds32(OTAConfig::kInitOTARequestorDelaySec),
                                                         OTAConfig::InitOTARequestorHandler, nullptr);
-#endif
         }
         break;
-#endif
-
-#if CHIP_DEVICE_CONFIG_ENABLE_WIFI
-    case DeviceEventType::kWiFiConnectivityChange:
-
-        ChipLogProgress(NotSpecified, "Wi-Fi state changed to %s.",
-                        ConnectivityMgr().IsWiFiStationConnected() ? "connected" : "disconnected");
-
-        chip::app::DnssdServer::Instance().StartServer();
-        NetworkCommissioning::BLWiFiDriver::GetInstance().SaveConfiguration();
-        if (!GetAppTask().mIsConnected && ConnectivityMgr().IsWiFiStationConnected())
-        {
-            GetAppTask().PostEvent(AppTask::APP_EVENT_SYS_PROVISIONED);
-            GetAppTask().mIsConnected = true;
-        }
-        break;
-
+#else
     case DeviceEventType::kInterfaceIpAddressChanged:
         if ((event->InterfaceIpAddressChanged.Type == InterfaceIpChangeType::kIpV4_Assigned) ||
             (event->InterfaceIpAddressChanged.Type == InterfaceIpChangeType::kIpV6_Assigned))
@@ -152,21 +120,45 @@
             // will not trigger a 'internet connectivity change' as there is no internet
             // connectivity. MDNS still wants to refresh its listening interfaces to include the
             // newly selected address.
-            chip::app::DnssdServer::Instance().StartServer();
-        }
 
-        if (event->InterfaceIpAddressChanged.Type == InterfaceIpChangeType::kIpV6_Assigned)
-        {
-            ChipLogProgress(NotSpecified, "Initializing route hook...");
+            chip::app::DnssdServer::Instance().StartServer();
+
             bl_route_hook_init();
 
-#ifdef OTA_ENABLED
             chip::DeviceLayer::SystemLayer().StartTimer(chip::System::Clock::Seconds32(OTAConfig::kInitOTARequestorDelaySec),
                                                         OTAConfig::InitOTARequestorHandler, nullptr);
-#endif
         }
+
         break;
 #endif
+    case DeviceEventType::kInternetConnectivityChange:
+        if (event->InternetConnectivityChange.IPv4 == kConnectivity_Established)
+        {
+            ChipLogProgress(NotSpecified, "IPv4 connectivity ready...");
+        }
+        else if (event->InternetConnectivityChange.IPv4 == kConnectivity_Lost)
+        {
+            ChipLogProgress(NotSpecified, "Lost IPv4 connectivity...");
+        }
+        if (event->InternetConnectivityChange.IPv6 == kConnectivity_Established)
+        {
+            ChipLogProgress(NotSpecified, "IPv6 connectivity ready...");
+        }
+        else if (event->InternetConnectivityChange.IPv6 == kConnectivity_Lost)
+        {
+            ChipLogProgress(NotSpecified, "Lost IPv6 connectivity...");
+        }
+        break;
+    case DeviceEventType::kCHIPoBLEConnectionEstablished:
+        ChipLogProgress(NotSpecified, "BLE connection established");
+        break;
+    case DeviceEventType::kCHIPoBLEConnectionClosed:
+        ChipLogProgress(NotSpecified, "BLE disconnected");
+        break;
+    case DeviceEventType::kCommissioningComplete:
+        ChipLogProgress(NotSpecified, "Commissioning complete");
+        GetAppTask().PostEvent(AppTask::APP_EVENT_LIGHTING_MASK);
+        break;
     default:
         break;
     }
@@ -253,7 +245,12 @@
 
     ConfigurationMgr().LogDeviceConfig();
 
+#if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE
     PrintOnboardingCodes(chip::RendezvousInformationFlag(chip::RendezvousInformationFlag::kBLE));
+#else
+    PrintOnboardingCodes(chip::RendezvousInformationFlag(chip::RendezvousInformationFlag::kOnNetwork));
+#endif
+
     PlatformMgr().AddEventHandler(ChipEventHandler, 0);
 
 #if PW_RPC_ENABLED
diff --git a/examples/platform/bouffalolab/common/plat/uart.c b/examples/platform/bouffalolab/common/plat/uart.c
index 8f2742f..35e0516 100644
--- a/examples/platform/bouffalolab/common/plat/uart.c
+++ b/examples/platform/bouffalolab/common/plat/uart.c
@@ -19,12 +19,21 @@
 #include <FreeRTOS.h>
 #include <semphr.h>
 
-#include <bl_uart.h>
-#include <hosal_uart.h>
-
 #include <board.h>
 
+#ifdef CFG_USB_CDC_ENABLE
+#include <aos/kernel.h>
+#include <aos/yloop.h>
+#include <device/vfs_uart.h>
+#include <event_device.h>
+#include <hal_board.h>
+#include <libfdt.h>
+#include <vfs.h>
+#else
+#include <bl_uart.h>
+#include <hosal_uart.h>
 extern hosal_uart_dev_t uart_stdio;
+#endif
 
 #if CONFIG_ENABLE_CHIP_SHELL || PW_RPC_ENABLED
 
@@ -42,6 +51,7 @@
 
 static chipUart_t chipUart_var;
 
+#ifndef CFG_USB_CDC_ENABLE
 static int uartTxCallback(void * p_arg)
 {
     hosal_uart_ioctl(&uart_stdio, HOSAL_UART_TX_TRIGGER_OFF, NULL);
@@ -81,6 +91,39 @@
 
     return 0;
 }
+#else
+void aosUartRxCallback(int fd, void * param)
+{
+    uint32_t len = 0, readlen = 0;
+    BaseType_t xHigherPriorityTaskWoken = 1;
+
+    if (chipUart_var.head >= chipUart_var.tail)
+    {
+        if (chipUart_var.head < MAX_BUFFER_SIZE)
+        {
+            readlen = len     = aos_read(fd, chipUart_var.rxbuf + chipUart_var.head, MAX_BUFFER_SIZE - chipUart_var.head);
+            chipUart_var.head = (chipUart_var.head + len) % MAX_BUFFER_SIZE;
+        }
+
+        if (0 == chipUart_var.head)
+        {
+            len = aos_read(fd, chipUart_var.rxbuf, chipUart_var.tail - 1);
+            chipUart_var.head += len;
+            readlen += len;
+        }
+    }
+    else
+    {
+        readlen = aos_read(fd, chipUart_var.rxbuf + chipUart_var.head, chipUart_var.tail - chipUart_var.head - 1);
+        chipUart_var.head += readlen;
+    }
+
+    if (chipUart_var.head != chipUart_var.tail)
+    {
+        xSemaphoreGiveFromISR(chipUart_var.sema, &xHigherPriorityTaskWoken);
+    }
+}
+#endif
 
 void uartInit(void)
 {
@@ -88,11 +131,13 @@
 
     chipUart_var.sema = xSemaphoreCreateBinaryStatic(&chipUart_var.mutx);
 
+#ifndef CFG_USB_CDC_ENABLE
     hosal_uart_finalize(&uart_stdio);
     hosal_uart_init(&uart_stdio);
     hosal_uart_callback_set(&uart_stdio, HOSAL_UART_RX_CALLBACK, uartRxCallback, NULL);
     hosal_uart_callback_set(&uart_stdio, HOSAL_UART_TX_CALLBACK, uartTxCallback, NULL);
     hosal_uart_ioctl(&uart_stdio, HOSAL_UART_MODE_SET, (void *) HOSAL_UART_MODE_INT);
+#endif
 }
 
 int16_t uartRead(char * Buf, uint16_t NbBytesToRead)
@@ -120,7 +165,23 @@
 }
 #endif
 
+#ifndef CFG_USB_CDC_ENABLE
 int16_t uartWrite(const char * Buf, uint16_t BufLength)
 {
     return hosal_uart_send(&uart_stdio, Buf, BufLength);
 }
+#else
+int16_t uartWrite(const char * Buf, uint16_t BufLength)
+{
+    uint16_t sent = 0;
+    do
+    {
+        extern int vfs_fd;
+        if (vfs_fd >= 0)
+        {
+            sent += (uint8_t) aos_write(vfs_fd, Buf + sent, BufLength - sent);
+        }
+    } while (sent < BufLength);
+    return sent;
+}
+#endif
diff --git a/examples/platform/bouffalolab/common/plat/uart.h b/examples/platform/bouffalolab/common/plat/uart.h
index a963a34..ff2a398 100644
--- a/examples/platform/bouffalolab/common/plat/uart.h
+++ b/examples/platform/bouffalolab/common/plat/uart.h
@@ -28,6 +28,10 @@
 int16_t uartWrite(const char * Buf, uint16_t BufLength);
 int16_t uartRead(char * Buf, uint16_t NbBytesToRead);
 
+#ifdef CFG_USB_CDC_ENABLE
+void aosUartRxCallback(int fd, void * param);
+#endif
+
 #ifdef __cplusplus
 } // extern "C"
 #endif
diff --git a/examples/platform/bouffalolab/bl602/route_hook/bl_route_hook.c b/examples/platform/bouffalolab/common/route_hook/bl_route_hook.c
similarity index 88%
rename from examples/platform/bouffalolab/bl602/route_hook/bl_route_hook.c
rename to examples/platform/bouffalolab/common/route_hook/bl_route_hook.c
index bcdbcc4..93cc731 100644
--- a/examples/platform/bouffalolab/bl602/route_hook/bl_route_hook.c
+++ b/examples/platform/bouffalolab/common/route_hook/bl_route_hook.c
@@ -1,8 +1,6 @@
 #include <stdbool.h>
 #include <string.h>
 
-#include "bl_route_hook.h"
-#include "bl_route_table.h"
 #include "utils_log.h"
 
 #include "lwip/icmp6.h"
@@ -12,7 +10,9 @@
 #include "lwip/prot/ip6.h"
 #include "lwip/prot/nd6.h"
 #include "lwip/raw.h"
-#include <wifi_mgmr_ext.h>
+
+#include "bl_route_hook.h"
+#include "bl_route_table.h"
 
 typedef struct bl_route_hook_t
 {
@@ -36,6 +36,8 @@
 
 static bl_route_hook_t * s_hooks;
 
+extern struct netif * deviceInterface_getNetif(void);
+
 static bool is_self_address(struct netif * netif, const ip6_addr_t * addr)
 {
     for (size_t i = 0; i < LWIP_ARRAYSIZE(netif->ip6_addr); i++)
@@ -79,7 +81,7 @@
             const uint8_t * rio_data = &icmp_payload[sizeof(rio_header_t)];
             uint8_t rio_data_len     = opt_len - sizeof(rio_header_t);
 
-            log_info("Received RIO\n");
+            log_info("Received RIO\r\n");
             if (rio_data_len >= prefix_len_bytes)
             {
                 ip6_addr_t prefix;
@@ -93,14 +95,14 @@
                 route.prefix           = prefix;
                 route.preference       = preference;
                 route.lifetime_seconds = lwip_ntohl(rio_header.route_lifetime);
-                log_info("prefix %s lifetime %u\n", ip6addr_ntoa(&prefix), route.lifetime_seconds);
+                log_info("prefix %s lifetime %u\r\n", ip6addr_ntoa(&prefix), route.lifetime_seconds);
                 if (bl_route_table_add_route_entry(&route) == NULL)
                 {
-                    log_error("Failed to add route table entry\n");
+                    log_error("Failed to add route table entry\r\n");
                 }
                 else
                 {
-                    log_info("Added entry to route table\n");
+                    log_info("Added entry to route table\r\n");
                 }
             }
         }
@@ -127,12 +129,12 @@
 
     if (p->tot_len != p->len)
     {
-        log_error("Ignore segmented ICMP packet\n");
+        log_error("Ignore segmented ICMP packet\r\n");
         return 0;
     }
     if (p->tot_len <= sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr))
     {
-        log_error("Ignore invalid ICMP packet\n");
+        log_error("Ignore invalid ICMP packet\r\n");
         return 0;
     }
     if (!ip6_addr_islinklocal(&dest) && !ip6_addr_isallnodes_linklocal(&dest) && !ip6_addr_isallrouters_linklocal(&dest))
@@ -151,16 +153,16 @@
     return 0;
 }
 
-int8_t bl_route_hook_init()
+int8_t bl_route_hook_init(void)
 {
-    struct netif * lwip_netif = wifi_mgmr_sta_netif_get();
     ip_addr_t router_group    = IPADDR6_INIT_HOST(0xFF020000, 0, 0, 0x02);
     bl_route_hook_t * hook    = NULL;
     uint8_t ret               = 0;
+    struct netif * lwip_netif = deviceInterface_getNetif();
 
     if (lwip_netif == NULL)
     {
-        log_error("Invalid network interface\n");
+        log_error("Invalid network interface\r\n");
         return -1;
     }
 
@@ -168,7 +170,6 @@
     {
         if (iter->netif == lwip_netif)
         {
-            log_error("Hook already installed on netif, skip...\n");
             return 0;
         }
     }
@@ -176,13 +177,13 @@
     hook = (bl_route_hook_t *) malloc(sizeof(bl_route_hook_t));
     if (hook == NULL)
     {
-        log_error("Cannot allocate hook\n");
+        log_error("Cannot allocate hook\r\n");
         return -1;
     }
 
     if (mld6_joingroup_netif(lwip_netif, ip_2_ip6(&router_group)) != ERR_OK)
     {
-        log_error("Failed to join multicast group\n");
+        log_error("Failed to join multicast group\r\n");
         ret = -1;
         goto exit;
     }
diff --git a/examples/platform/bouffalolab/bl602/route_hook/bl_route_hook.h b/examples/platform/bouffalolab/common/route_hook/bl_route_hook.h
similarity index 100%
rename from examples/platform/bouffalolab/bl602/route_hook/bl_route_hook.h
rename to examples/platform/bouffalolab/common/route_hook/bl_route_hook.h
diff --git a/examples/platform/bouffalolab/bl602/route_hook/bl_route_table.c b/examples/platform/bouffalolab/common/route_hook/bl_route_table.c
similarity index 99%
rename from examples/platform/bouffalolab/bl602/route_hook/bl_route_table.c
rename to examples/platform/bouffalolab/common/route_hook/bl_route_table.c
index 4d2c901..3e5ae10 100644
--- a/examples/platform/bouffalolab/bl602/route_hook/bl_route_table.c
+++ b/examples/platform/bouffalolab/common/route_hook/bl_route_table.c
@@ -1,7 +1,7 @@
-#include "bl_route_table.h"
 #include <stdbool.h>
 #include <string.h>
 
+#include "bl_route_table.h"
 #include "lwip/ip6_addr.h"
 #include "lwip/netif.h"
 #include "lwip/timeouts.h"
diff --git a/examples/platform/bouffalolab/bl602/route_hook/bl_route_table.h b/examples/platform/bouffalolab/common/route_hook/bl_route_table.h
similarity index 100%
rename from examples/platform/bouffalolab/bl602/route_hook/bl_route_table.h
rename to examples/platform/bouffalolab/common/route_hook/bl_route_table.h
diff --git a/scripts/build/build/targets.py b/scripts/build/build/targets.py
index 0d88140..fe730b3 100755
--- a/scripts/build/build/targets.py
+++ b/scripts/build/build/targets.py
@@ -588,12 +588,16 @@
 
     # Boards
     target.AppendFixedTargets([
-        TargetPart('BL602-IoT-Matter-V1', board=BouffalolabBoard.BL602_IoT_Matter_V1, module_type="BL602"),
-        TargetPart('BL602-IOT-DVK-3S', board=BouffalolabBoard.BL602_IOT_DVK_3S, module_type="BL602"),
-        TargetPart('BL602-NIGHT-LIGHT', board=BouffalolabBoard.BL602_NIGHT_LIGHT, module_type="BL602"),
-        TargetPart('XT-ZB6-DevKit', board=BouffalolabBoard.XT_ZB6_DevKit, module_type="BL706C-22"),
-        TargetPart('BL706-IoT-DVK', board=BouffalolabBoard.BL706_IoT_DVK, module_type="BL706C-22"),
-        TargetPart('BL706-NIGHT-LIGHT', board=BouffalolabBoard.BL706_NIGHT_LIGHT, module_type="BL706C-22"),
+        TargetPart('BL602-IoT-Matter-V1',
+                   board=BouffalolabBoard.BL602_IoT_Matter_V1, module_type="BL602"),
+        TargetPart('BL602-NIGHT-LIGHT',
+                   board=BouffalolabBoard.BL602_NIGHT_LIGHT, module_type="BL602"),
+        TargetPart('XT-ZB6-DevKit', board=BouffalolabBoard.XT_ZB6_DevKit,
+                   module_type="BL706C-22"),
+        TargetPart('BL706-NIGHT-LIGHT',
+                   board=BouffalolabBoard.BL706_NIGHT_LIGHT, module_type="BL706C-22"),
+        TargetPart('BL706-ETH',
+                   board=BouffalolabBoard.BL706_ETH, module_type="BL706C-22"),
         TargetPart('BL704L-DVK', board=BouffalolabBoard.BL704L_DVK, module_type="BL704L"),
     ])
 
@@ -606,6 +610,7 @@
     target.AppendModifier('115200', baudrate=115200)
     target.AppendModifier('rpc', enable_rpcs=True)
     target.AppendModifier('cdc', enable_cdc=True)
+    target.AppendModifier('resetCnt', enable_resetCnt=True)
     target.AppendModifier('rotating_device_id', enable_rotating_device_id=True)
 
     return target
diff --git a/scripts/build/builders/bouffalolab.py b/scripts/build/builders/bouffalolab.py
index 8281ba9..20ef4c7 100644
--- a/scripts/build/builders/bouffalolab.py
+++ b/scripts/build/builders/bouffalolab.py
@@ -43,26 +43,23 @@
 
 class BouffalolabBoard(Enum):
     BL602_IoT_Matter_V1 = auto()
-    BL602_IOT_DVK_3S = auto()
     BL602_NIGHT_LIGHT = auto()
     XT_ZB6_DevKit = auto()
-    BL706_IoT_DVK = auto()
     BL706_NIGHT_LIGHT = auto()
+    BL706_ETH = auto()
     BL704L_DVK = auto()
 
     def GnArgName(self):
         if self == BouffalolabBoard.BL602_IoT_Matter_V1:
             return 'BL602-IoT-Matter-V1'
-        elif self == BouffalolabBoard.BL602_IOT_DVK_3S:
-            return 'BL602-IOT-DVK-3S'
         elif self == BouffalolabBoard.BL602_NIGHT_LIGHT:
             return 'BL602-NIGHT-LIGHT'
         elif self == BouffalolabBoard.XT_ZB6_DevKit:
             return 'XT-ZB6-DevKit'
-        elif self == BouffalolabBoard.BL706_IoT_DVK:
-            return 'BL706-IoT-DVK'
         elif self == BouffalolabBoard.BL706_NIGHT_LIGHT:
             return 'BL706-NIGHT-LIGHT'
+        elif self == BouffalolabBoard.BL706_ETH:
+            return 'BL706-ETH'
         elif self == BouffalolabBoard.BL704L_DVK:
             return 'BL704L-DVK'
         else:
@@ -75,12 +72,13 @@
                  root,
                  runner,
                  app: BouffalolabApp = BouffalolabApp.LIGHT,
-                 board: BouffalolabBoard = BouffalolabBoard.BL706_IoT_DVK,
+                 board: BouffalolabBoard = BouffalolabBoard.XT_ZB6_DevKit,
                  enable_rpcs: bool = False,
                  module_type: str = "BL706C-22",
                  baudrate=2000000,
                  enable_shell: bool = False,
                  enable_cdc: bool = False,
+                 enable_resetCnt: bool = False,
                  enable_rotating_device_id: bool = False
                  ):
 
@@ -113,12 +111,28 @@
         self.argsOpt.append('board=\"{}\"'.format(self.board.GnArgName()))
         self.argsOpt.append('baudrate=\"{}\"'.format(baudrate))
 
+        if bouffalo_chip == "bl602":
+            self.argsOpt.append('chip_enable_openthread=false')
+            self.argsOpt.append('chip_enable_wifi=true')
         if bouffalo_chip == "bl702":
             self.argsOpt.append('module_type=\"{}\"'.format(module_type))
+            if board == BouffalolabBoard.BL706_ETH:
+                self.argsOpt.append('chip_config_network_layer_ble=false')
+                self.argsOpt.append('chip_enable_openthread=false')
+                self.argsOpt.append('chip_enable_wifi=false')
+            else:
+                self.argsOpt.append('chip_enable_openthread=true')
+                self.argsOpt.append('chip_enable_wifi=false')
+        elif bouffalo_chip == "bl702l":
+            self.argsOpt.append('chip_enable_openthread=true')
+            self.argsOpt.append('chip_enable_wifi=false')
 
         if enable_cdc:
             if bouffalo_chip != "bl702":
                 raise Exception('Chip %s does NOT support USB CDC' % bouffalo_chip)
+            if board == BouffalolabBoard.BL706_ETH:
+                raise Exception('Board %s does NOT support USB CDC' % self.board.GnArgName())
+
             self.argsOpt.append('enable_cdc_module=true')
 
         if enable_rpcs:
@@ -126,6 +140,9 @@
         elif enable_shell:
             self.argsOpt.append('chip_build_libshell=true')
 
+        if enable_resetCnt:
+            self.argsOpt.append('enable_reset_counter=true')
+
         if enable_rotating_device_id:
             self.argsOpt.append('chip_enable_additional_data_advertising=true')
             self.argsOpt.append('chip_enable_rotating_device_id=true')
diff --git a/scripts/build/testdata/all_targets_linux_x64.txt b/scripts/build/testdata/all_targets_linux_x64.txt
index 40d65af..1276594 100644
--- a/scripts/build/testdata/all_targets_linux_x64.txt
+++ b/scripts/build/testdata/all_targets_linux_x64.txt
@@ -1,7 +1,7 @@
 ameba-amebad-{all-clusters,all-clusters-minimal,light,light-switch,pigweed}
 asr-{asr582x,asr595x,asr550x}-{all-clusters,all-clusters-minimal,lighting,light-switch,lock,bridge,temperature-measurement,thermostat,ota-requestor}[-ota][-shell][-no_logging][-factory][-rotating_id][-rio]
 android-{arm,arm64,x86,x64,androidstudio-arm,androidstudio-arm64,androidstudio-x86,androidstudio-x64}-{chip-tool,chip-test,tv-server,tv-casting-app,java-matter-controller}[-no-debug]
-bouffalolab-{bl602-iot-matter-v1,bl602-iot-dvk-3s,bl602-night-light,xt-zb6-devkit,bl706-iot-dvk,bl706-night-light,bl704l-dvk}-light[-shell][-115200][-rpc][-cdc][-rotating_device_id]
+bouffalolab-{bl602-iot-matter-v1,bl602-night-light,xt-zb6-devkit,bl706-night-light,bl706-eth,bl704l-dvk}-light[-shell][-115200][-rpc][-cdc][-resetcnt][-rotating_device_id]
 cc32xx-lock
 ti-cc13x2x7_26x2x7-{lighting,lock,pump,pump-controller}[-mtd]
 ti-cc13x4_26x4-{all-clusters,lighting,lock,pump,pump-controller}[-mtd][-ftd]
diff --git a/src/lwip/BUILD.gn b/src/lwip/BUILD.gn
index 60eb4d2..24462da 100644
--- a/src/lwip/BUILD.gn
+++ b/src/lwip/BUILD.gn
@@ -64,6 +64,7 @@
   import("//build_overrides/bouffalolab_iot_sdk.gni")
 } else if (lwip_platform == "bl702") {
   import("//build_overrides/bouffalolab_iot_sdk.gni")
+  import("${chip_root}/src/platform/device.gni")
 } else if (lwip_platform == "bl702l") {
   import("//build_overrides/bouffalolab_iot_sdk.gni")
 } else if (lwip_platform == "mw320") {
@@ -111,28 +112,6 @@
     public_configs = [ "${chip_root}/src:includes" ]
     public_configs += [ "${psoc6_sdk_build_root}:psoc6_sdk_config" ]
   }
-} else if (lwip_platform == "bl702_lwip") {
-  import("${bouffalolab_iot_sdk_build_root}/bl702/bl_iot_sdk.gni")
-
-  group("lwip") {
-    public_deps = [ ":lwip_buildconfig" ]
-    public_deps += [ "${bouffalolab_iot_sdk_build_root}/bl702:bl_iot_sdk" ]
-  }
-
-  group("all") {
-    deps = [ ":lwip" ]
-  }
-} else if (lwip_platform == "bl702l_lwip") {
-  import("${bouffalolab_iot_sdk_build_root}/bl702l/bl_iot_sdk.gni")
-
-  group("lwip") {
-    public_deps = [ ":lwip_buildconfig" ]
-    public_deps += [ "${bouffalolab_iot_sdk_build_root}/bl702l:bl_iot_sdk" ]
-  }
-
-  group("all") {
-    deps = [ ":lwip" ]
-  }
 } else if (lwip_platform == "qpg") {
   config("lwip_config") {
     include_dirs = [ "freertos" ]
@@ -164,6 +143,18 @@
   group("all") {
     deps = [ ":lwip" ]
   }
+} else if (lwip_platform == "bl702" && defined(chip_enable_openthread) &&
+           chip_enable_openthread == false) {
+  # bl702 platform will use ethernet or SPI Wi-Fi for connectivity, if openthread is not enabled
+  import("${bouffalolab_iot_sdk_build_root}/bl702/bl_iot_sdk.gni")
+  group("lwip") {
+    public_deps = [ ":lwip_buildconfig" ]
+    public_deps += [ "${bouffalolab_iot_sdk_build_root}/bl702:bl_iot_sdk" ]
+  }
+
+  group("all") {
+    deps = [ ":lwip" ]
+  }
 } else if (lwip_platform == "asr") {
   group("lwip") {
     public_deps = [ ":lwip_buildconfig" ]
@@ -220,8 +211,6 @@
       public_deps += [ "${k32w0_sdk_build_root}:k32w0_sdk" ]
     } else if (lwip_platform == "cyw30739") {
       public_deps += [ "${cyw30739_sdk_build_root}:cyw30739_sdk" ]
-    } else if (lwip_platform == "bl602") {
-      public_deps += [ "${bouffalolab_iot_sdk_build_root}/bl702l:bl_iot_sdk" ]
     } else if (lwip_platform == "bl702") {
       public_deps += [ "${bouffalolab_iot_sdk_build_root}/bl702:bl_iot_sdk" ]
     } else if (lwip_platform == "bl702l") {
diff --git a/src/platform/BUILD.gn b/src/platform/BUILD.gn
index e0bfc11..04c4d52 100644
--- a/src/platform/BUILD.gn
+++ b/src/platform/BUILD.gn
@@ -120,7 +120,9 @@
 
     if (chip_device_platform == "linux" || chip_device_platform == "darwin" ||
         chip_device_platform == "tizen" || chip_device_platform == "android" ||
-        chip_device_platform == "k32w0" || chip_device_platform == "webos") {
+        chip_device_platform == "k32w0" || chip_device_platform == "webos" ||
+        chip_device_platform == "bl602" || chip_device_platform == "bl702" ||
+        chip_device_platform == "bl702l") {
       defines += [ "CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE=${chip_enable_ble}" ]
     }
 
diff --git a/src/platform/bouffalolab/BL602/ConfigurationManagerImpl.cpp b/src/platform/bouffalolab/BL602/ConfigurationManagerImpl.cpp
index b112fe7..5469fb9 100644
--- a/src/platform/bouffalolab/BL602/ConfigurationManagerImpl.cpp
+++ b/src/platform/bouffalolab/BL602/ConfigurationManagerImpl.cpp
@@ -15,18 +15,8 @@
  *    limitations under the License.
  */
 
-#include <platform/internal/CHIPDeviceLayerInternal.h>
-
 #include <platform/ConfigurationManager.h>
 
-#include <platform/internal/GenericConfigurationManagerImpl.ipp>
-
-#include <lib/core/CHIPVendorIdentifiers.hpp>
-#include <platform/DiagnosticDataProvider.h>
-
-#include <lib/support/CodeUtils.h>
-#include <lib/support/logging/CHIPLogging.h>
-
 extern "C" {
 #include <bl_efuse.h>
 }
diff --git a/src/platform/bouffalolab/BL602/ConnectivityManagerImpl.cpp b/src/platform/bouffalolab/BL602/ConnectivityManagerImpl.cpp
index 9f209d1..25ae917 100644
--- a/src/platform/bouffalolab/BL602/ConnectivityManagerImpl.cpp
+++ b/src/platform/bouffalolab/BL602/ConnectivityManagerImpl.cpp
@@ -18,130 +18,86 @@
 #include <platform/internal/CHIPDeviceLayerInternal.h>
 
 #include <NetworkCommissioningDriver.h>
-#include <lib/support/CodeUtils.h>
-#include <lib/support/logging/CHIPLogging.h>
-#include <platform/ConnectivityManager.h>
-#include <platform/internal/BLEManager.h>
 
-#include <hal_wifi.h>
-#include <wifi_mgmr_ext.h>
-
-#include <platform/internal/GenericConnectivityManagerImpl_UDP.ipp>
-
-#if INET_CONFIG_ENABLE_TCP_ENDPOINT
-#include <platform/internal/GenericConnectivityManagerImpl_TCP.ipp>
-#endif
-
-#include <platform/internal/GenericConnectivityManagerImpl_WiFi.ipp>
-
-#if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE
-#include <platform/internal/GenericConnectivityManagerImpl_BLE.ipp>
-#endif
-
-#if CHIP_DEVICE_CONFIG_ENABLE_THREAD
-#include <platform/internal/GenericConnectivityManagerImpl_Thread.ipp>
-#endif
-
-#include <wifi_mgmr_ext.h>
-
-#include <FreeRTOS.h>
-#include <task.h>
-
-#include <lwip/netifapi.h>
-#include <wifi_mgmr_ext.h>
-
-#include <FreeRTOS.h>
-#include <stdio.h>
-#include <string.h>
-#include <task.h>
-
-#define zero(S) memset(&S, 0, sizeof(S))
+#include <platform/DiagnosticDataProvider.h>
+#include <platform/bouffalolab/common/DiagnosticDataProviderImpl.h>
 
 using namespace ::chip;
-using namespace ::chip::Dnssd;
-using namespace ::chip::Inet;
-using namespace ::chip::System;
-using namespace ::chip::TLV;
-using namespace ::chip::DeviceLayer::Internal;
 
 namespace chip {
 namespace DeviceLayer {
 
-ConnectivityManager::WiFiStationState ConnectivityManagerImpl::mWiFiStationState =
-    ConnectivityManager::kWiFiStationState_NotConnected;
-
-void ConnectivityManagerImpl::WifiStationStateChange(void)
+void ConnectivityManagerImpl::OnWiFiStationDisconnected()
 {
-    ChipDeviceEvent event;
+    NetworkCommissioning::BLWiFiDriver::GetInstance().SetLastDisconnectReason(NULL);
+    uint16_t reason = NetworkCommissioning::BLWiFiDriver::GetInstance().GetLastDisconnectReason();
+    uint8_t associationFailureCause =
+        chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::AssociationFailureCauseEnum::kUnknown);
+    WiFiDiagnosticsDelegate * delegate = GetDiagnosticDataProvider().GetWiFiDiagnosticsDelegate();
 
-    if (ConnectivityManagerImpl::mWiFiStationState == ConnectivityManager::kWiFiStationState_Connected)
+    ChipLogError(DeviceLayer, "WiFi station disconnect, reason %d.", reason);
+
+    switch (reason)
     {
-        event.Type                          = DeviceEventType::kWiFiConnectivityChange;
-        event.WiFiConnectivityChange.Result = kConnectivity_Established;
-        PlatformMgr().PostEventOrDie(&event);
+    case WLAN_FW_TX_ASSOC_FRAME_ALLOCATE_FAIILURE:
+    case WLAN_FW_ASSOCIATE_FAIILURE:
+    case WLAN_FW_4WAY_HANDSHAKE_ERROR_PSK_TIMEOUT_FAILURE:
+        associationFailureCause =
+            chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::AssociationFailureCauseEnum::kAssociationFailed);
+        if (delegate)
+        {
+            delegate->OnAssociationFailureDetected(associationFailureCause, reason);
+        }
+        break;
+    case WLAN_FW_TX_AUTH_FRAME_ALLOCATE_FAIILURE:
+    case WLAN_FW_AUTHENTICATION_FAIILURE:
+    case WLAN_FW_AUTH_ALGO_FAIILURE:
+    case WLAN_FW_DEAUTH_BY_AP_WHEN_NOT_CONNECTION:
+    case WLAN_FW_DEAUTH_BY_AP_WHEN_CONNECTION:
+    case WLAN_FW_4WAY_HANDSHAKE_TX_DEAUTH_FRAME_TRANSMIT_FAILURE:
+    case WLAN_FW_4WAY_HANDSHAKE_TX_DEAUTH_FRAME_ALLOCATE_FAIILURE:
+    case WLAN_FW_AUTH_OR_ASSOC_RESPONSE_TIMEOUT_FAILURE:
+    case WLAN_FW_DISCONNECT_BY_USER_WITH_DEAUTH:
+    case WLAN_FW_DISCONNECT_BY_USER_NO_DEAUTH:
+        associationFailureCause =
+            chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::AssociationFailureCauseEnum::kAuthenticationFailed);
+        if (delegate)
+        {
+            delegate->OnAssociationFailureDetected(associationFailureCause, reason);
+        }
+        break;
+    case WLAN_FW_SCAN_NO_BSSID_AND_CHANNEL:
+        associationFailureCause =
+            chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::AssociationFailureCauseEnum::kSsidNotFound);
+        if (delegate)
+        {
+            delegate->OnAssociationFailureDetected(associationFailureCause, reason);
+        }
+        break;
+    case WLAN_FW_BEACON_LOSS:
+    case WLAN_FW_JOIN_NETWORK_SECURITY_NOMATCH:
+    case WLAN_FW_JOIN_NETWORK_WEPLEN_ERROR:
+    case WLAN_FW_DISCONNECT_BY_FW_PS_TX_NULLFRAME_FAILURE:
+    case WLAN_FW_CREATE_CHANNEL_CTX_FAILURE_WHEN_JOIN_NETWORK:
+    case WLAN_FW_ADD_STA_FAILURE:
+    case WLAN_FW_JOIN_NETWORK_FAILURE:
+        break;
+
+    default:
+        if (delegate)
+        {
+            delegate->OnAssociationFailureDetected(associationFailureCause, reason);
+        }
+        break;
     }
-}
 
-void ConnectivityManagerImpl::DriveStationState()
-{
-    return;
-}
-
-void ConnectivityManagerImpl::DriveStationState(::chip::System::Layer * aLayer, void * aAppState)
-{
-    sInstance.DriveStationState();
-}
-
-CHIP_ERROR ConnectivityManagerImpl::_SetWiFiStationMode(WiFiStationMode val)
-{
-    CHIP_ERROR err = CHIP_NO_ERROR;
-
-    DeviceLayer::SystemLayer().ScheduleWork(DriveStationState, NULL);
-
-    return err;
-}
-
-bool ConnectivityManagerImpl::_IsWiFiStationEnabled(void)
-{
-    return GetWiFiStationMode() == kWiFiStationMode_Enabled;
-}
-
-void ConnectivityManagerImpl::OnStationConnected()
-{
-    NetworkCommissioning::BLWiFiDriver::GetInstance().OnConnectWiFiNetwork();
-    // TODO Invoke WARM to perform actions that occur when the WiFi station interface comes up.
-
-#if 0
-    // Alert other components of the new state.
-    ChipDeviceEvent event;
-    event.Type                          = DeviceEventType::kWiFiConnectivityChange;
-    event.WiFiConnectivityChange.Result = kConnectivity_Established;
-    PlatformMgr().PostEventOrDie(&event);
-
-    UpdateInternetConnectivityState();
-#endif
-}
-
-void ConnectivityManagerImpl::ChangeWiFiStationState(WiFiStationState newState)
-{
-    if (mWiFiStationState != newState)
+    if (delegate)
     {
-        ChipLogProgress(DeviceLayer, "WiFi station state change: %s -> %s", WiFiStationStateToStr(mWiFiStationState),
-                        WiFiStationStateToStr(newState));
-        mWiFiStationState = newState;
-        SystemLayer().ScheduleLambda([]() { NetworkCommissioning::BLWiFiDriver::GetInstance().OnNetworkStatusChange(); });
+        delegate->OnDisconnectionDetected(reason);
+        delegate->OnConnectionStatusChanged(
+            chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::ConnectionStatusEnum::kNotConnected));
     }
 }
 
-void ConnectivityManagerImpl::OnIPv6AddressAvailable()
-{
-    ChipLogProgress(DeviceLayer, "IPv6 addr available.");
-
-    ChipDeviceEvent event;
-    event.Type                           = DeviceEventType::kInterfaceIpAddressChanged;
-    event.InterfaceIpAddressChanged.Type = InterfaceIpChangeType::kIpV6_Assigned;
-    PlatformMgr().PostEventOrDie(&event);
-}
-
 } // namespace DeviceLayer
 } // namespace chip
diff --git a/src/platform/bouffalolab/BL602/DiagnosticDataProviderImpl.cpp b/src/platform/bouffalolab/BL602/DiagnosticDataProviderImpl.cpp
index b49fa9c..8cd34b5 100644
--- a/src/platform/bouffalolab/BL602/DiagnosticDataProviderImpl.cpp
+++ b/src/platform/bouffalolab/BL602/DiagnosticDataProviderImpl.cpp
@@ -20,10 +20,7 @@
 #include <platform/bouffalolab/common/DiagnosticDataProviderImpl.h>
 #include <platform/internal/CHIPDeviceLayerInternal.h>
 
-#include <lwip/tcpip.h>
-
 extern "C" {
-#include <bl_efuse.h>
 #include <bl_sys.h>
 
 #include <bl60x_fw_api.h>
@@ -64,74 +61,6 @@
     return CHIP_NO_ERROR;
 }
 
-static int bl_netif_get_all_ip6(struct netif * netif, ip6_addr_t if_ip6[])
-{
-    if (netif == NULL || if_ip6 == NULL)
-    {
-        return 0;
-    }
-
-    int addr_count = 0;
-    for (int i = 0; (i < LWIP_IPV6_NUM_ADDRESSES) && (i < kMaxIPv6AddrCount); i++)
-    {
-        if (!ip_addr_cmp(&netif->ip6_addr[i], IP6_ADDR_ANY))
-        {
-            memcpy(&if_ip6[addr_count++], &netif->ip6_addr[i], sizeof(ip6_addr_t));
-        }
-    }
-
-    return addr_count;
-}
-
-CHIP_ERROR DiagnosticDataProviderImpl::GetNetworkInterfaces(NetworkInterface ** netifpp)
-{
-    NetworkInterface * ifp = new NetworkInterface();
-    struct netif * netif;
-
-    netif = wifi_mgmr_sta_netif_get();
-    if (netif)
-    {
-        Platform::CopyString(ifp->Name, netif->name);
-        ifp->name          = CharSpan::fromCharString(ifp->Name);
-        ifp->isOperational = true;
-        ifp->type          = EMBER_ZCL_INTERFACE_TYPE_ENUM_WI_FI;
-        ifp->offPremiseServicesReachableIPv4.SetNull();
-        ifp->offPremiseServicesReachableIPv6.SetNull();
-        bl_efuse_read_mac(ifp->MacAddress);
-        ifp->hardwareAddress = ByteSpan(ifp->MacAddress, 6);
-
-        uint32_t ip, gw, mask;
-        wifi_mgmr_sta_ip_get(&ip, &gw, &mask);
-        memcpy(ifp->Ipv4AddressesBuffer[0], &ip, kMaxIPv4AddrSize);
-        ifp->Ipv4AddressSpans[0] = ByteSpan(ifp->Ipv4AddressesBuffer[0], kMaxIPv4AddrSize);
-        ifp->IPv4Addresses       = chip::app::DataModel::List<chip::ByteSpan>(ifp->Ipv4AddressSpans, 1);
-
-        uint8_t ipv6_addr_count = 0;
-        ip6_addr_t ip6_addr[kMaxIPv6AddrCount];
-        ipv6_addr_count = bl_netif_get_all_ip6(netif, ip6_addr);
-        for (uint8_t idx = 0; idx < ipv6_addr_count; ++idx)
-        {
-            memcpy(ifp->Ipv6AddressesBuffer[idx], ip6_addr[idx].addr, kMaxIPv6AddrSize);
-            ifp->Ipv6AddressSpans[idx] = ByteSpan(ifp->Ipv6AddressesBuffer[idx], kMaxIPv6AddrSize);
-        }
-        ifp->IPv6Addresses = chip::app::DataModel::List<chip::ByteSpan>(ifp->Ipv6AddressSpans, ipv6_addr_count);
-    }
-
-    *netifpp = ifp;
-
-    return CHIP_NO_ERROR;
-}
-
-void DiagnosticDataProviderImpl::ReleaseNetworkInterfaces(NetworkInterface * netifp)
-{
-    while (netifp)
-    {
-        NetworkInterface * del = netifp;
-        netifp                 = netifp->Next;
-        delete del;
-    }
-}
-
 CHIP_ERROR DiagnosticDataProviderImpl::GetWiFiBssId(MutableByteSpan & BssId)
 {
     return CopySpanToMutableSpan(ByteSpan(wifiMgmr.wifi_mgmr_stat_info.bssid), BssId);
diff --git a/src/platform/bouffalolab/BL602/NetworkCommissioningDriver.cpp b/src/platform/bouffalolab/BL602/NetworkCommissioningDriver.cpp
index 28f5a5f..9cf57c3 100644
--- a/src/platform/bouffalolab/BL602/NetworkCommissioningDriver.cpp
+++ b/src/platform/bouffalolab/BL602/NetworkCommissioningDriver.cpp
@@ -15,38 +15,25 @@
  *    limitations under the License.
  */
 
-#include <aos/yloop.h>
-#include <bl60x_wifi_driver/wifi_mgmr.h>
-#include <bl60x_wifi_driver/wifi_mgmr_api.h>
-#include <hal_wifi.h>
-#include <lib/support/CodeUtils.h>
-#include <lib/support/SafeInt.h>
-#include <lwip/tcpip.h>
+#include <limits>
+#include <stdint.h>
+#include <string>
+
 #include <platform/CHIPDeviceLayer.h>
 #include <platform/bouffalolab/BL602/NetworkCommissioningDriver.h>
 #include <wifi_mgmr_ext.h>
 #include <wifi_mgmr_portable.h>
 
-#include <limits>
-#include <stdint.h>
-#include <string>
-#include <utils_log.h>
-
 #define WIFI_STA_DISCONNECT_DELAY (pdMS_TO_TICKS(200))
 
 using namespace ::chip;
+using namespace ::chip::DeviceLayer::Internal;
 
 namespace chip {
 namespace DeviceLayer {
 namespace NetworkCommissioning {
 
 namespace {
-constexpr char kWiFiSSIDKeyName[]        = "wifi-ssid";
-constexpr char kWiFiCredentialsKeyName[] = "wifi-pass";
-
-constexpr char blWiFiSSIDKeyName[]        = "bl-wifi-ssid";
-constexpr char blWiFiCredentialsKeyName[] = "bl-wifi-pass";
-
 static char WiFiSSIDStr[DeviceLayer::Internal::kMaxWiFiSSIDLength];
 static uint8_t scan_type = 0;
 } // namespace
@@ -57,10 +44,11 @@
     size_t ssidLen        = 0;
     size_t credentialsLen = 0;
 
-    err = PersistedStorage::KeyValueStoreMgr().Get(kWiFiCredentialsKeyName, mSavedNetwork.credentials,
+    err = PersistedStorage::KeyValueStoreMgr().Get(BLConfig::kBLConfigKey_wifissid, mSavedNetwork.credentials,
                                                    sizeof(mSavedNetwork.credentials), &credentialsLen);
     SuccessOrExit(err);
-    err = PersistedStorage::KeyValueStoreMgr().Get(kWiFiSSIDKeyName, mSavedNetwork.ssid, sizeof(mSavedNetwork.ssid), &ssidLen);
+    err = PersistedStorage::KeyValueStoreMgr().Get(BLConfig::kBLConfigKey_wifipassword, mSavedNetwork.ssid,
+                                                   sizeof(mSavedNetwork.ssid), &ssidLen);
     SuccessOrExit(err);
 
     mSavedNetwork.credentialsLen = credentialsLen;
@@ -88,28 +76,15 @@
 
 CHIP_ERROR BLWiFiDriver::CommitConfiguration()
 {
-    ReturnErrorOnFailure(PersistedStorage::KeyValueStoreMgr().Put(kWiFiSSIDKeyName, mStagingNetwork.ssid, mStagingNetwork.ssidLen));
-    ReturnErrorOnFailure(PersistedStorage::KeyValueStoreMgr().Put(kWiFiCredentialsKeyName, mStagingNetwork.credentials,
+    ChipLogProgress(NetworkProvisioning, "BLWiFiDriver::CommitConfiguration");
+    ReturnErrorOnFailure(
+        PersistedStorage::KeyValueStoreMgr().Put(BLConfig::kBLConfigKey_wifissid, mStagingNetwork.ssid, mStagingNetwork.ssidLen));
+    ReturnErrorOnFailure(PersistedStorage::KeyValueStoreMgr().Put(BLConfig::kBLConfigKey_wifipassword, mStagingNetwork.credentials,
                                                                   mStagingNetwork.credentialsLen));
     mSavedNetwork = mStagingNetwork;
     return CHIP_NO_ERROR;
 }
 
-CHIP_ERROR BLWiFiDriver::SaveConfiguration()
-{
-    if (NULL == mStagingNetwork.ssid || 0 == mStagingNetwork.ssidLen || NULL == mStagingNetwork.credentials ||
-        0 == mStagingNetwork.credentialsLen)
-    {
-        return CHIP_ERROR_KEY_NOT_FOUND;
-    }
-
-    ReturnErrorOnFailure(
-        PersistedStorage::KeyValueStoreMgr().Put(blWiFiSSIDKeyName, mStagingNetwork.ssid, mStagingNetwork.ssidLen));
-    ReturnErrorOnFailure(PersistedStorage::KeyValueStoreMgr().Put(blWiFiCredentialsKeyName, mStagingNetwork.credentials,
-                                                                  mStagingNetwork.credentialsLen));
-    return CHIP_NO_ERROR;
-}
-
 CHIP_ERROR BLWiFiDriver::RevertConfiguration()
 {
     mStagingNetwork = mSavedNetwork;
@@ -164,12 +139,12 @@
 
 CHIP_ERROR BLWiFiDriver::ConnectWiFiNetwork(const char * ssid, uint8_t ssidLen, const char * key, uint8_t keyLen)
 {
-    // ReturnErrorOnFailure(ConnectivityMgr().SetWiFiStationMode(ConnectivityManager::kWiFiStationMode_Disabled));
-
     char wifi_ssid[64] = { 0 };
     char passwd[64]    = { 0 };
     int state          = 0;
 
+    ConnectivityMgrImpl().ChangeWiFiStationState(ConnectivityManager::kWiFiStationState_Connecting);
+
     wifi_mgmr_sta_disconnect();
     vTaskDelay(WIFI_STA_DISCONNECT_DELAY);
 
@@ -187,33 +162,21 @@
     wifi_interface = wifi_mgmr_sta_enable();
     wifi_mgmr_sta_connect(&wifi_interface, wifi_ssid, passwd, NULL, NULL, 0, 0);
 
-    ReturnErrorOnFailure(ConnectivityMgr().SetWiFiStationMode(ConnectivityManager::kWiFiStationMode_Disabled));
-
-    return ConnectivityMgr().SetWiFiStationMode(ConnectivityManager::kWiFiStationMode_Enabled);
-}
-
-CHIP_ERROR BLWiFiDriver::ReConnectWiFiNetwork(void)
-{
-    char ssid[64]  = { 0 };
-    char psk[64]   = { 0 };
-    size_t ssidLen = 0;
-    size_t pskLen  = 0;
-
-    ReturnErrorOnFailure(
-        PersistedStorage::KeyValueStoreMgr().Get((const char *) blWiFiSSIDKeyName, (void *) ssid, 64, &ssidLen, 0));
-    ReturnErrorOnFailure(
-        PersistedStorage::KeyValueStoreMgr().Get((const char *) blWiFiCredentialsKeyName, (void *) psk, 64, &pskLen, 0));
-
-    ConnectWiFiNetwork(ssid, ssidLen, psk, pskLen);
-
     return CHIP_NO_ERROR;
 }
 
-void BLWiFiDriver::OnConnectWiFiNetwork()
+void BLWiFiDriver::OnConnectWiFiNetwork(bool isConnected)
 {
     if (mpConnectCallback)
     {
-        mpConnectCallback->OnResult(Status::kSuccess, CharSpan(), 0);
+        if (isConnected)
+        {
+            mpConnectCallback->OnResult(Status::kSuccess, CharSpan(), 0);
+        }
+        else
+        {
+            mpConnectCallback->OnResult(Status::kUnknownError, CharSpan(), 0);
+        }
         mpConnectCallback = nullptr;
     }
 }
@@ -360,7 +323,7 @@
         return;
     }
 
-    if (ConnectivityManagerImpl::mWiFiStationState == ConnectivityManager::kWiFiStationState_Connected)
+    if (ConnectivityManagerImpl().GetWiFiStationState() == ConnectivityManager::kWiFiStationState_Connected)
     {
         staConnected = true;
     }
@@ -372,14 +335,12 @@
         return;
     }
     mpStatusChangeCallback->OnNetworkingStatusChange(
-        Status::kSuccess, MakeOptional(ByteSpan(configuredNetwork.networkID, configuredNetwork.networkIDLen)),
+        Status::kUnknownError, MakeOptional(ByteSpan(configuredNetwork.networkID, configuredNetwork.networkIDLen)),
         MakeOptional(GetLastDisconnectReason()));
 }
 
 CHIP_ERROR BLWiFiDriver::SetLastDisconnectReason(const ChipDeviceEvent * event)
 {
-    // VerifyOrReturnError(event->Type == DeviceEventType::kRtkWiFiStationDisconnectedEvent, CHIP_ERROR_INVALID_ARGUMENT);
-
     uint16_t status_code, reason_code;
 
     wifi_mgmr_conn_result_get(&status_code, &reason_code);
diff --git a/src/platform/bouffalolab/BL602/NetworkCommissioningDriver.h b/src/platform/bouffalolab/BL602/NetworkCommissioningDriver.h
index fc08f77..edf2d3f 100644
--- a/src/platform/bouffalolab/BL602/NetworkCommissioningDriver.h
+++ b/src/platform/bouffalolab/BL602/NetworkCommissioningDriver.h
@@ -98,7 +98,6 @@
     uint8_t GetConnectNetworkTimeoutSeconds() override { return kWiFiConnectNetworkTimeoutSeconds; }
 
     CHIP_ERROR CommitConfiguration() override;
-    CHIP_ERROR SaveConfiguration();
     CHIP_ERROR RevertConfiguration() override;
 
     Status RemoveNetwork(ByteSpan networkId, MutableCharSpan & outDebugText, uint8_t & outNetworkIndex) override;
@@ -111,8 +110,7 @@
     void ScanNetworks(ByteSpan ssid, ScanCallback * callback) override;
 
     CHIP_ERROR ConnectWiFiNetwork(const char * ssid, uint8_t ssidLen, const char * key, uint8_t keyLen);
-    CHIP_ERROR ReConnectWiFiNetwork(void);
-    void OnConnectWiFiNetwork();
+    void OnConnectWiFiNetwork(bool isConnected);
     void OnScanWiFiNetworkDone();
     void OnNetworkStatusChange();
 
diff --git a/src/platform/bouffalolab/BL602/PlatformManagerImpl.cpp b/src/platform/bouffalolab/BL602/PlatformManagerImpl.cpp
index 5676184..f160128 100644
--- a/src/platform/bouffalolab/BL602/PlatformManagerImpl.cpp
+++ b/src/platform/bouffalolab/BL602/PlatformManagerImpl.cpp
@@ -20,24 +20,14 @@
 
 #include <platform/PlatformManager.h>
 #include <platform/bouffalolab/BL602/NetworkCommissioningDriver.h>
-#include <platform/bouffalolab/common/DiagnosticDataProviderImpl.h>
-#include <platform/internal/GenericPlatformManagerImpl_FreeRTOS.ipp>
 
 #include <lwip/tcpip.h>
-#include <utils_log.h>
 
-#include <aos/kernel.h>
-#include <bl60x_fw_api.h>
 #include <bl_sec.h>
-#include <event_device.h>
+
 #include <hal_wifi.h>
-#include <lwip/tcpip.h>
 #include <wifi_mgmr_ext.h>
 
-extern "C" {
-#include <bl_sec.h>
-}
-
 namespace chip {
 namespace DeviceLayer {
 
@@ -47,117 +37,12 @@
 
 static int app_entropy_source(void * data, unsigned char * output, size_t len, size_t * olen)
 {
-
     bl_rand_stream(reinterpret_cast<uint8_t *>(output), static_cast<int>(len));
     *olen = len;
 
     return 0;
 }
 
-static void WifiStaDisconect(void)
-{
-    NetworkCommissioning::BLWiFiDriver::GetInstance().SetLastDisconnectReason(NULL);
-
-    uint16_t reason = NetworkCommissioning::BLWiFiDriver::GetInstance().GetLastDisconnectReason();
-    uint8_t associationFailureCause =
-        chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::AssociationFailureCauseEnum::kUnknown);
-    WiFiDiagnosticsDelegate * delegate = GetDiagnosticDataProvider().GetWiFiDiagnosticsDelegate();
-
-    if (ConnectivityManagerImpl::mWiFiStationState == ConnectivityManager::kWiFiStationState_Disconnecting)
-    {
-        return;
-    }
-
-    ChipLogError(DeviceLayer, "WiFi station disconnect, reason %d.", reason);
-
-    switch (reason)
-    {
-    case WLAN_FW_TX_ASSOC_FRAME_ALLOCATE_FAIILURE:
-    case WLAN_FW_ASSOCIATE_FAIILURE:
-    case WLAN_FW_4WAY_HANDSHAKE_ERROR_PSK_TIMEOUT_FAILURE:
-        associationFailureCause =
-            chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::AssociationFailureCauseEnum::kAssociationFailed);
-        if (delegate)
-        {
-            delegate->OnAssociationFailureDetected(associationFailureCause, reason);
-        }
-        break;
-    case WLAN_FW_TX_AUTH_FRAME_ALLOCATE_FAIILURE:
-    case WLAN_FW_AUTHENTICATION_FAIILURE:
-    case WLAN_FW_AUTH_ALGO_FAIILURE:
-    case WLAN_FW_DEAUTH_BY_AP_WHEN_NOT_CONNECTION:
-    case WLAN_FW_DEAUTH_BY_AP_WHEN_CONNECTION:
-    case WLAN_FW_4WAY_HANDSHAKE_TX_DEAUTH_FRAME_TRANSMIT_FAILURE:
-    case WLAN_FW_4WAY_HANDSHAKE_TX_DEAUTH_FRAME_ALLOCATE_FAIILURE:
-    case WLAN_FW_AUTH_OR_ASSOC_RESPONSE_TIMEOUT_FAILURE:
-    case WLAN_FW_DISCONNECT_BY_USER_WITH_DEAUTH:
-    case WLAN_FW_DISCONNECT_BY_USER_NO_DEAUTH:
-        associationFailureCause =
-            chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::AssociationFailureCauseEnum::kAuthenticationFailed);
-        if (delegate)
-        {
-            delegate->OnAssociationFailureDetected(associationFailureCause, reason);
-        }
-        break;
-    case WLAN_FW_SCAN_NO_BSSID_AND_CHANNEL:
-        associationFailureCause =
-            chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::AssociationFailureCauseEnum::kSsidNotFound);
-        if (delegate)
-        {
-            delegate->OnAssociationFailureDetected(associationFailureCause, reason);
-        }
-        break;
-    case WLAN_FW_BEACON_LOSS:
-    case WLAN_FW_JOIN_NETWORK_SECURITY_NOMATCH:
-    case WLAN_FW_JOIN_NETWORK_WEPLEN_ERROR:
-    case WLAN_FW_DISCONNECT_BY_FW_PS_TX_NULLFRAME_FAILURE:
-    case WLAN_FW_CREATE_CHANNEL_CTX_FAILURE_WHEN_JOIN_NETWORK:
-    case WLAN_FW_ADD_STA_FAILURE:
-    case WLAN_FW_JOIN_NETWORK_FAILURE:
-        break;
-
-    default:
-        if (delegate)
-        {
-            delegate->OnAssociationFailureDetected(associationFailureCause, reason);
-        }
-        break;
-    }
-
-    if (delegate)
-    {
-        delegate->OnDisconnectionDetected(reason);
-        delegate->OnConnectionStatusChanged(
-            chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::ConnectionStatusEnum::kNotConnected));
-    }
-
-    ConnectivityMgrImpl().ChangeWiFiStationState(ConnectivityManagerImpl::kWiFiStationState_Disconnecting);
-}
-
-static void WifiStaConnected(void)
-{
-    char ap_ssid[64];
-    WiFiDiagnosticsDelegate * delegate = GetDiagnosticDataProvider().GetWiFiDiagnosticsDelegate();
-
-    if (ConnectivityManagerImpl::mWiFiStationState == ConnectivityManager::kWiFiStationState_Connected)
-    {
-        return;
-    }
-
-    memset(ap_ssid, 0, sizeof(ap_ssid));
-    // wifi_mgmr_sta_ssid_get(ap_ssid);
-    // wifi_mgmr_ap_item_t * ap_info = mgmr_get_ap_info_handle();
-    // wifi_mgmr_get_scan_result_filter(ap_info, ap_ssid);
-
-    ConnectivityMgrImpl().ChangeWiFiStationState(ConnectivityManagerImpl::kWiFiStationState_Connected);
-    ConnectivityMgrImpl().WifiStationStateChange();
-    ConnectivityMgrImpl().OnStationConnected();
-    if (delegate)
-    {
-        delegate->OnConnectionStatusChanged(
-            chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::ConnectionStatusEnum::kConnected));
-    }
-}
 typedef void (*aos_event_cb)(input_event_t * event, void * private_data);
 
 void OnWiFiPlatformEvent(input_event_t * event, void * private_data)
@@ -187,9 +72,11 @@
     break;
     case CODE_WIFI_ON_DISCONNECT: {
         ChipLogProgress(DeviceLayer, "WiFi station disconnect, reason %s.", wifi_mgmr_status_code_str(event->value));
-
         chip::DeviceLayer::PlatformMgr().LockChipStack();
-        WifiStaDisconect();
+        if (ConnectivityManager::kWiFiStationState_Connecting == ConnectivityMgrImpl().GetWiFiStationState())
+        {
+            ConnectivityMgrImpl().ChangeWiFiStationState(ConnectivityManager::kWiFiStationState_Connecting_Failed);
+        }
         chip::DeviceLayer::PlatformMgr().UnlockChipStack();
     }
     break;
@@ -198,19 +85,17 @@
     }
     break;
     case CODE_WIFI_ON_GOT_IP: {
-
         ChipLogProgress(DeviceLayer, "WiFi station gets IPv4 address.");
-
         chip::DeviceLayer::PlatformMgr().LockChipStack();
-        WifiStaConnected();
+        ConnectivityMgrImpl().ChangeWiFiStationState(ConnectivityManagerImpl::kWiFiStationState_Connected);
+        ConnectivityMgrImpl().OnConnectivityChanged(wifi_mgmr_sta_netif_get());
         chip::DeviceLayer::PlatformMgr().UnlockChipStack();
     }
     break;
     case CODE_WIFI_ON_GOT_IP6: {
         ChipLogProgress(DeviceLayer, "WiFi station gets IPv6 address.");
-
         chip::DeviceLayer::PlatformMgr().LockChipStack();
-        ConnectivityMgrImpl().OnIPv6AddressAvailable();
+        ConnectivityMgrImpl().OnConnectivityChanged(wifi_mgmr_sta_netif_get());
         chip::DeviceLayer::PlatformMgr().UnlockChipStack();
     }
     break;
@@ -223,26 +108,14 @@
 
 CHIP_ERROR PlatformManagerImpl::_InitChipStack(void)
 {
-    CHIP_ERROR err                 = CHIP_NO_ERROR;
-    static uint8_t stack_wifi_init = 0;
+    CHIP_ERROR err = CHIP_NO_ERROR;
     TaskHandle_t backup_eventLoopTask;
 
-    // Initialize the configuration system.
-    err = Internal::BLConfig::Init();
-    SuccessOrExit(err);
-
     // Initialize LwIP.
     tcpip_init(NULL, NULL);
     aos_register_event_filter(EV_WIFI, OnWiFiPlatformEvent, NULL);
 
-    if (1 == stack_wifi_init)
-    {
-        ChipLogError(DeviceLayer, "Wi-Fi already initialized!");
-        return CHIP_NO_ERROR;
-    }
-
     hal_wifi_start_firmware_task();
-    stack_wifi_init = 1;
     aos_post_event(EV_WIFI, CODE_WIFI_ON_INIT_DONE, 0);
 
     err = chip::Crypto::add_entropy_source(app_entropy_source, NULL, 16);
diff --git a/src/platform/bouffalolab/BL602/args.gni b/src/platform/bouffalolab/BL602/args.gni
index dd482f9..2f8964a 100644
--- a/src/platform/bouffalolab/BL602/args.gni
+++ b/src/platform/bouffalolab/BL602/args.gni
@@ -22,6 +22,8 @@
 
 chip_device_platform = "bl602"
 
+chip_enable_ota_requestor = true
+
 lwip_platform = "bl602"
 
 chip_inet_config_enable_ipv4 = true
diff --git a/src/platform/bouffalolab/BL602/wifi_mgmr_portable.c b/src/platform/bouffalolab/BL602/wifi_mgmr_portable.c
index 04ee57f..47cac9e 100644
--- a/src/platform/bouffalolab/BL602/wifi_mgmr_portable.c
+++ b/src/platform/bouffalolab/BL602/wifi_mgmr_portable.c
@@ -144,3 +144,8 @@
 
     return false;
 }
+
+struct netif * deviceInterface_getNetif(void)
+{
+    return wifi_mgmr_sta_netif_get();
+}
diff --git a/src/platform/bouffalolab/BL602/wifi_mgmr_portable.h b/src/platform/bouffalolab/BL602/wifi_mgmr_portable.h
index cf25c7e..aa855d2 100644
--- a/src/platform/bouffalolab/BL602/wifi_mgmr_portable.h
+++ b/src/platform/bouffalolab/BL602/wifi_mgmr_portable.h
@@ -16,6 +16,7 @@
 bool wifi_mgmr_security_type_is_wpa(void);
 bool wifi_mgmr_security_type_is_wpa2(void);
 bool wifi_mgmr_security_type_is_wpa3(void);
+struct netif * deviceInterface_getNetif(void);
 
 #ifdef __cplusplus
 }
diff --git a/src/platform/bouffalolab/BL702/BUILD.gn b/src/platform/bouffalolab/BL702/BUILD.gn
index dd02791..e32738e 100644
--- a/src/platform/bouffalolab/BL702/BUILD.gn
+++ b/src/platform/bouffalolab/BL702/BUILD.gn
@@ -18,6 +18,8 @@
 import("${chip_root}/src/platform/device.gni")
 
 assert(chip_device_platform == "bl702")
+assert(false == (chip_enable_wifi && chip_enable_openthread),
+       "Not support Wi-Fi and Thread together")
 
 if (chip_enable_openthread) {
   import("//build_overrides/openthread.gni")
@@ -82,6 +84,14 @@
       ]
       deps += [ "${chip_root}/src/lib/dnssd:platform_header" ]
     }
+  } else {
+    sources += [
+      "ConfigurationManagerImpl.cpp",
+      "ConnectivityManagerImpl.cpp",
+      "EthernetInterface.c",
+    ]
+
+    deps = [ "${chip_root}/src/lib/dnssd:platform_header" ]
   }
 
   public_deps = [ "${chip_root}/src/platform:platform_base" ]
diff --git a/src/platform/bouffalolab/BL702/ConfigurationManagerImpl.cpp b/src/platform/bouffalolab/BL702/ConfigurationManagerImpl.cpp
new file mode 100644
index 0000000..5a92ee1
--- /dev/null
+++ b/src/platform/bouffalolab/BL702/ConfigurationManagerImpl.cpp
@@ -0,0 +1,43 @@
+/*
+ *    Copyright (c) 2022 Project CHIP Authors
+ *    All rights reserved.
+ *
+ *    Licensed under the Apache License, Version 2.0 (the "License");
+ *    you may not use this file except in compliance with the License.
+ *    You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+
+#include <platform/ConfigurationManager.h>
+#include <platform/internal/GenericConfigurationManagerImpl.ipp>
+
+#if !CHIP_DEVICE_CONFIG_ENABLE_THREAD & !CHIP_DEVICE_CONFIG_ENABLE_WIFI
+extern "C" {
+#include <eth_bd.h>
+}
+#endif
+
+namespace chip {
+namespace DeviceLayer {
+
+#if !CHIP_DEVICE_CONFIG_ENABLE_THREAD & !CHIP_DEVICE_CONFIG_ENABLE_WIFI
+CHIP_ERROR ConfigurationManagerImpl::GetPrimaryMACAddress(MutableByteSpan buf)
+{
+    if (buf.size() != ConfigurationManager::kPrimaryMACAddressLength)
+        return CHIP_ERROR_INVALID_ARGUMENT;
+
+    eth_get_mac(buf.data());
+
+    return CHIP_NO_ERROR;
+}
+#endif
+
+} // namespace DeviceLayer
+} // namespace chip
diff --git a/src/platform/bouffalolab/BL702/ConnectivityManagerImpl.cpp b/src/platform/bouffalolab/BL702/ConnectivityManagerImpl.cpp
new file mode 100644
index 0000000..09e0550
--- /dev/null
+++ b/src/platform/bouffalolab/BL702/ConnectivityManagerImpl.cpp
@@ -0,0 +1,43 @@
+/*
+ *    Copyright (c) 2022 Project CHIP Authors
+ *    All rights reserved.
+ *
+ *    Licensed under the Apache License, Version 2.0 (the "License");
+ *    you may not use this file except in compliance with the License.
+ *    You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+
+#include <platform/internal/CHIPDeviceLayerInternal.h>
+
+#include <platform/ConnectivityManager.h>
+
+#include <platform/bouffalolab/common/DiagnosticDataProviderImpl.h>
+
+#if !CHIP_DEVICE_CONFIG_ENABLE_THREAD && !CHIP_DEVICE_CONFIG_ENABLE_WIFI
+#include <eth_bd.h>
+#include <platform/bouffalolab/BL702/EthernetInterface.h>
+#endif
+
+using namespace ::chip;
+
+namespace chip {
+namespace DeviceLayer {
+
+#if !CHIP_DEVICE_CONFIG_ENABLE_THREAD && !CHIP_DEVICE_CONFIG_ENABLE_WIFI
+extern "C" void ethernetInterface_eventGotIP(struct netif * interface)
+{
+    ChipLogProgress(DeviceLayer, "ethernetInterface_eventGotIP");
+    ConnectivityMgrImpl().OnConnectivityChanged(interface);
+}
+#endif
+
+} // namespace DeviceLayer
+} // namespace chip
diff --git a/src/platform/bouffalolab/BL702/DiagnosticDataProviderImpl.cpp b/src/platform/bouffalolab/BL702/DiagnosticDataProviderImpl.cpp
index 62fe129..cb067d3 100644
--- a/src/platform/bouffalolab/BL702/DiagnosticDataProviderImpl.cpp
+++ b/src/platform/bouffalolab/BL702/DiagnosticDataProviderImpl.cpp
@@ -15,13 +15,13 @@
  *    limitations under the License.
  */
 
-#include <platform/DiagnosticDataProvider.h>
 #include <platform/bouffalolab/common/DiagnosticDataProviderImpl.h>
 #include <platform/internal/CHIPDeviceLayerInternal.h>
 
 extern "C" {
 #include <bl_sys.h>
 }
+
 namespace chip {
 namespace DeviceLayer {
 
@@ -52,34 +52,5 @@
     return CHIP_NO_ERROR;
 }
 
-CHIP_ERROR DiagnosticDataProviderImpl::GetNetworkInterfaces(NetworkInterface ** netifpp)
-{
-    NetworkInterface * ifp = new NetworkInterface();
-
-    const char * threadNetworkName = otThreadGetNetworkName(ThreadStackMgrImpl().OTInstance());
-    ifp->name                      = Span<const char>(threadNetworkName, strlen(threadNetworkName));
-    ifp->isOperational             = true;
-    ifp->offPremiseServicesReachableIPv4.SetNull();
-    ifp->offPremiseServicesReachableIPv6.SetNull();
-    ifp->type = EMBER_ZCL_INTERFACE_TYPE_ENUM_THREAD;
-    uint8_t macBuffer[ConfigurationManager::kPrimaryMACAddressLength];
-    ConfigurationMgr().GetPrimary802154MACAddress(macBuffer);
-    ifp->hardwareAddress = ByteSpan(macBuffer, ConfigurationManager::kPrimaryMACAddressLength);
-
-    *netifpp = ifp;
-
-    return CHIP_NO_ERROR;
-}
-
-void DiagnosticDataProviderImpl::ReleaseNetworkInterfaces(NetworkInterface * netifp)
-{
-    while (netifp)
-    {
-        NetworkInterface * del = netifp;
-        netifp                 = netifp->Next;
-        delete del;
-    }
-}
-
 } // namespace DeviceLayer
 } // namespace chip
diff --git a/src/platform/bouffalolab/BL702/EthernetInterface.c b/src/platform/bouffalolab/BL702/EthernetInterface.c
new file mode 100644
index 0000000..469ffb7
--- /dev/null
+++ b/src/platform/bouffalolab/BL702/EthernetInterface.c
@@ -0,0 +1,90 @@
+/*
+ *    Copyright (c) 2022 Project CHIP Authors
+ *    All rights reserved.
+ *
+ *    Licensed under the Apache License, Version 2.0 (the "License");
+ *    you may not use this file except in compliance with the License.
+ *    You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+
+#include <eth_bd.h>
+#include <lwip/dhcp6.h>
+#include <lwip/netifapi.h>
+
+#include "EthernetInterface.h"
+static struct dhcp6 dhcp6_val;
+
+extern int8_t bl_route_hook_init(void);
+
+static void netif_status_callback(struct netif * netif)
+{
+    if (netif->flags & NETIF_FLAG_UP)
+    {
+        for (uint32_t i = 0; i < LWIP_IPV6_NUM_ADDRESSES; i++)
+        {
+            if (!ip6_addr_isany(netif_ip6_addr(netif, i)) && ip6_addr_ispreferred(netif_ip6_addr_state(netif, i)))
+            {
+
+                const ip6_addr_t * ip6addr = netif_ip6_addr(netif, i);
+                if (ip6_addr_isany(ip6addr) || ip6_addr_islinklocal(ip6addr))
+                {
+                    continue;
+                }
+
+                ethernetInterface_eventGotIP(netif);
+                break;
+            }
+        }
+    }
+}
+
+static int ethernet_callback(eth_link_state val)
+{
+    switch (val)
+    {
+    case ETH_INIT_STEP_LINKUP:
+        break;
+    case ETH_INIT_STEP_READY:
+        netifapi_netif_set_default(&eth_mac);
+        netifapi_netif_set_up(&eth_mac);
+
+        // netifapi_netif_set_up((struct netif *)&obj->netif);
+        netif_create_ip6_linklocal_address(&eth_mac, 1);
+        eth_mac.ip6_autoconfig_enabled = 1;
+        dhcp6_set_struct(&eth_mac, &dhcp6_val);
+        dhcp6_enable_stateless(&eth_mac);
+
+        /* start dhcp */
+        netifapi_dhcp_start(&eth_mac);
+        break;
+    case ETH_INIT_STEP_LINKDOWN:
+        break;
+    }
+
+    return 0;
+}
+
+void ethernetInterface_init(void)
+{
+    netif_add(&eth_mac, NULL, NULL, NULL, NULL, eth_init, ethernet_input);
+
+    ethernet_init(ethernet_callback);
+
+    /* Set callback to be called when interface is brought up/down or address is changed while up */
+    netif_set_status_callback(&eth_mac, netif_status_callback);
+
+    bl_route_hook_init();
+}
+
+struct netif * deviceInterface_getNetif(void)
+{
+    return &eth_mac;
+}
diff --git a/src/platform/bouffalolab/BL702/EthernetInterface.h b/src/platform/bouffalolab/BL702/EthernetInterface.h
new file mode 100644
index 0000000..7809a54
--- /dev/null
+++ b/src/platform/bouffalolab/BL702/EthernetInterface.h
@@ -0,0 +1,30 @@
+/*
+ *    Copyright (c) 2022 Project CHIP Authors
+ *    All rights reserved.
+ *
+ *    Licensed under the Apache License, Version 2.0 (the "License");
+ *    you may not use this file except in compliance with the License.
+ *    You may obtain a copy of the License at
+ *
+ *        http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *    Unless required by applicable law or agreed to in writing, software
+ *    distributed under the License is distributed on an "AS IS" BASIS,
+ *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *    See the License for the specific language governing permissions and
+ *    limitations under the License.
+ */
+
+#pragma once
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void ethernetInterface_init(void);
+void ethernetInterface_eventGotIP(struct netif * interface);
+struct netif * deviceInterface_getNetif(void);
+
+#ifdef __cplusplus
+}
+#endif
diff --git a/src/platform/bouffalolab/BL702/PlatformManagerImpl.cpp b/src/platform/bouffalolab/BL702/PlatformManagerImpl.cpp
index 51fe963..9b5fea5 100644
--- a/src/platform/bouffalolab/BL702/PlatformManagerImpl.cpp
+++ b/src/platform/bouffalolab/BL702/PlatformManagerImpl.cpp
@@ -25,8 +25,13 @@
 
 #include <lwip/tcpip.h>
 
+#if CHIP_DEVICE_CONFIG_ENABLE_THREAD
 #include <openthread_port.h>
 #include <utils_list.h>
+#else
+#include <platform/bouffalolab/BL702/EthernetInterface.h>
+#endif
+
 extern "C" {
 #include <bl_sec.h>
 }
@@ -51,26 +56,26 @@
 {
     CHIP_ERROR err;
     TaskHandle_t backup_eventLoopTask;
+
+    // Initialize LwIP.
+    tcpip_init(NULL, NULL);
+
+#if CHIP_DEVICE_CONFIG_ENABLE_THREAD
     otRadio_opt_t opt;
-
-    // Initialize the configuration system.
-    err = Internal::BLConfig::Init();
-    SuccessOrExit(err);
-
     opt.byte            = 0;
     opt.bf.isCoexEnable = true;
 
     ot_alarmInit();
     ot_radioInit(opt);
+#else
+    ethernetInterface_init();
+#endif
 
     ReturnErrorOnFailure(System::Clock::InitClock_RealTime());
 
     SetConfigurationMgr(&ConfigurationManagerImpl::GetDefaultInstance());
     SetDiagnosticDataProvider(&DiagnosticDataProviderImpl::GetDefaultInstance());
 
-    // Initialize LwIP.
-    tcpip_init(NULL, NULL);
-
     err = chip::Crypto::add_entropy_source(app_entropy_source, NULL, 16);
     SuccessOrExit(err);
 
diff --git a/src/platform/bouffalolab/BL702/args.gni b/src/platform/bouffalolab/BL702/args.gni
index 47a03c6..4a34946 100644
--- a/src/platform/bouffalolab/BL702/args.gni
+++ b/src/platform/bouffalolab/BL702/args.gni
@@ -20,6 +20,10 @@
 
 chip_device_platform = "bl702"
 
+chip_enable_ota_requestor = true
+
+lwip_platform = "bl702"
+
 riscv_platform_config = "${bouffalolab_iot_sdk_build_root}/common/rsicv.gni"
 
 mbedtls_target = "${bouffalolab_iot_sdk_build_root}/bl702:bl_iot_sdk"
diff --git a/src/platform/bouffalolab/BL702/lwip_default_hooks.h b/src/platform/bouffalolab/BL702/lwip_default_hooks.h
new file mode 100644
index 0000000..3c1d1d1
--- /dev/null
+++ b/src/platform/bouffalolab/BL702/lwip_default_hooks.h
@@ -0,0 +1,17 @@
+#ifndef _LWIP_DEFAULT_HOOKS_H_
+#define _LWIP_DEFAULT_HOOKS_H_
+#include "lwip/arch.h"
+#include "lwip/err.h"
+#include "lwip/ip_addr.h"
+
+#ifdef CONFIG_LWIP_HOOK_IP6_ROUTE_DEFAULT
+extern struct netif * lwip_hook_ip6_route(const ip6_addr_t * src, const ip6_addr_t * dest);
+#define LWIP_HOOK_IP6_ROUTE lwip_hook_ip6_route
+#endif
+
+#ifdef CONFIG_LWIP_HOOK_ND6_GET_GW_DEFAULT
+extern const ip6_addr_t * lwip_hook_nd6_get_gw(struct netif * netif, const ip6_addr_t * dest);
+#define LWIP_HOOK_ND6_GET_GW lwip_hook_nd6_get_gw
+#endif
+
+#endif /* _LWIP_DEFAULT_HOOKS_H_ */
diff --git a/src/platform/bouffalolab/BL702L/DiagnosticDataProviderImpl.cpp b/src/platform/bouffalolab/BL702L/DiagnosticDataProviderImpl.cpp
index c23abe0..fcd805e 100644
--- a/src/platform/bouffalolab/BL702L/DiagnosticDataProviderImpl.cpp
+++ b/src/platform/bouffalolab/BL702L/DiagnosticDataProviderImpl.cpp
@@ -24,6 +24,10 @@
 #include "FreeRTOS.h"
 #include <lwip/tcpip.h>
 
+extern "C" {
+#include <bl_sys.h>
+}
+
 using namespace ::chip::app::Clusters::GeneralDiagnostics;
 
 namespace chip {
@@ -31,63 +35,29 @@
 
 CHIP_ERROR DiagnosticDataProviderImpl::GetBootReason(BootReasonType & bootReason)
 {
-    // BL_RST_REASON_E bootCause = bl_sys_rstinfo_get();
+    BL_RST_REASON_E bootCause = bl_sys_rstinfo_get();
 
-    // if (BL_RST_POR == bootCause)
-    // {
-    //     bootReason = BootReasonType::kPowerOnReboot;
-    // }
-    // else if (BL_RST_BOR == bootCause)
-    // {
-    //     bootReason = BootReasonType::kBrownOutReset;
-    // }
-    // else if (BL_RST_WDT == bootCause)
-    // {
-    //     bootReason = BootReasonType::kHardwareWatchdogReset;
-    // }
-    // else if (BL_RST_SOFTWARE == bootCause)
-    // {
-    //     bootReason = BootReasonType::kSoftwareReset;
-    // }
-    // else
-    // {
-    //     bootReason = BootReasonType::kUnspecified;
-    // }
-    return CHIP_NO_ERROR;
-}
-
-CHIP_ERROR DiagnosticDataProviderImpl::GetNetworkInterfaces(NetworkInterface ** netifpp)
-{
-    NetworkInterface * ifp = new NetworkInterface();
-
-#if CHIP_DEVICE_CONFIG_ENABLE_THREAD
-
-    const char * threadNetworkName = otThreadGetNetworkName(ThreadStackMgrImpl().OTInstance());
-    ifp->name                      = Span<const char>(threadNetworkName, strlen(threadNetworkName));
-    ifp->isOperational             = true;
-    ifp->offPremiseServicesReachableIPv4.SetNull();
-    ifp->offPremiseServicesReachableIPv6.SetNull();
-    ifp->type = InterfaceTypeEnum::EMBER_ZCL_INTERFACE_TYPE_ENUM_THREAD;
-    uint8_t macBuffer[ConfigurationManager::kPrimaryMACAddressLength];
-    ConfigurationMgr().GetPrimary802154MACAddress(macBuffer);
-    ifp->hardwareAddress = ByteSpan(macBuffer, ConfigurationManager::kPrimaryMACAddressLength);
-
-#else
-    /* TODO */
-#endif
-
-    *netifpp = ifp;
-    return CHIP_NO_ERROR;
-}
-
-void DiagnosticDataProviderImpl::ReleaseNetworkInterfaces(NetworkInterface * netifp)
-{
-    while (netifp)
+    if (BL_RST_POR == bootCause)
     {
-        NetworkInterface * del = netifp;
-        netifp                 = netifp->Next;
-        delete del;
+        bootReason = BootReasonType::kPowerOnReboot;
     }
+    else if (BL_RST_BOR == bootCause)
+    {
+        bootReason = BootReasonType::kBrownOutReset;
+    }
+    else if (BL_RST_WDT == bootCause)
+    {
+        bootReason = BootReasonType::kHardwareWatchdogReset;
+    }
+    else if (BL_RST_SOFTWARE == bootCause)
+    {
+        bootReason = BootReasonType::kSoftwareReset;
+    }
+    else
+    {
+        bootReason = BootReasonType::kUnspecified;
+    }
+    return CHIP_NO_ERROR;
 }
 
 } // namespace DeviceLayer
diff --git a/src/platform/bouffalolab/BL702L/PlatformManagerImpl.cpp b/src/platform/bouffalolab/BL702L/PlatformManagerImpl.cpp
index fa88202..798e0c1 100644
--- a/src/platform/bouffalolab/BL702L/PlatformManagerImpl.cpp
+++ b/src/platform/bouffalolab/BL702L/PlatformManagerImpl.cpp
@@ -55,10 +55,6 @@
     CHIP_ERROR err;
     TaskHandle_t backup_eventLoopTask;
 
-    // Initialize the configuration system.
-    err = Internal::BLConfig::Init();
-    SuccessOrExit(err);
-
     otRadio_opt_t opt;
 
     opt.byte            = 0;
diff --git a/src/platform/bouffalolab/BL702L/ThreadStackManagerImpl.cpp b/src/platform/bouffalolab/BL702L/ThreadStackManagerImpl.cpp
index 7b9b879..1b1ebf1 100644
--- a/src/platform/bouffalolab/BL702L/ThreadStackManagerImpl.cpp
+++ b/src/platform/bouffalolab/BL702L/ThreadStackManagerImpl.cpp
@@ -25,8 +25,6 @@
 
 #include <openthread/platform/entropy.h>
 
-#include <lib/support/CHIPPlatformMemory.h>
-
 #include <mbedtls/platform.h>
 
 #include <openthread_port.h>
diff --git a/src/platform/bouffalolab/BL702L/args.gni b/src/platform/bouffalolab/BL702L/args.gni
index 07903ca..58c45b8 100644
--- a/src/platform/bouffalolab/BL702L/args.gni
+++ b/src/platform/bouffalolab/BL702L/args.gni
@@ -20,6 +20,10 @@
 
 chip_device_platform = "bl702l"
 
+chip_enable_ota_requestor = true
+
+lwip_platform = "bl702l"
+
 riscv_platform_config = "${bouffalolab_iot_sdk_build_root}/common/rsicv.gni"
 
 mbedtls_target = "${bouffalolab_iot_sdk_build_root}/bl702l:bl_iot_sdk"
diff --git a/src/platform/bouffalolab/common/BLConfig.cpp b/src/platform/bouffalolab/common/BLConfig.cpp
index b8144dd..de1cc24 100644
--- a/src/platform/bouffalolab/common/BLConfig.cpp
+++ b/src/platform/bouffalolab/common/BLConfig.cpp
@@ -15,27 +15,15 @@
  *    limitations under the License.
  */
 
+#include <easyflash.h>
 #include <platform/internal/CHIPDeviceLayerInternal.h>
 
 #include <platform/bouffalolab/common/BLConfig.h>
 
-#include <lib/core/CHIPEncoding.h>
-#include <lib/support/CHIPMem.h>
-#include <lib/support/CHIPMemString.h>
-#include <lib/support/CodeUtils.h>
-#include <lib/support/logging/CHIPLogging.h>
-
-#include <easyflash.h>
-
 namespace chip {
 namespace DeviceLayer {
 namespace Internal {
 
-CHIP_ERROR BLConfig::Init()
-{
-    return CHIP_NO_ERROR;
-}
-
 CHIP_ERROR BLConfig::ReadConfigValue(const char * key, uint8_t * val, size_t size, size_t & readsize)
 {
     env_node_obj node;
diff --git a/src/platform/bouffalolab/common/BLConfig.h b/src/platform/bouffalolab/common/BLConfig.h
index 916e849..1bd8011 100644
--- a/src/platform/bouffalolab/common/BLConfig.h
+++ b/src/platform/bouffalolab/common/BLConfig.h
@@ -17,10 +17,6 @@
 
 #pragma once
 
-#include <platform/internal/CHIPDeviceLayerInternal.h>
-
-#include <string.h>
-
 namespace chip {
 namespace DeviceLayer {
 namespace Internal {
@@ -80,8 +76,6 @@
     static constexpr const char * kCounterKey_TotalOperationalHours = ("total-hours");
     static constexpr const char * kCounterKey_UpTime                = ("up-time");
 
-    static CHIP_ERROR Init(void);
-
     // Config value accessors.
     static CHIP_ERROR ReadConfigValue(const char * key, uint8_t * val, size_t size, size_t & readsize);
     static CHIP_ERROR ReadConfigValue(const char * key, bool & val);
diff --git a/src/platform/bouffalolab/common/BLEManagerImpl.cpp b/src/platform/bouffalolab/common/BLEManagerImpl.cpp
index 47cfbd8..73a6f8f 100644
--- a/src/platform/bouffalolab/common/BLEManagerImpl.cpp
+++ b/src/platform/bouffalolab/common/BLEManagerImpl.cpp
@@ -20,12 +20,8 @@
 
 #if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE
 
-#include "BLEManagerImpl.h"
-
 #include <ble/CHIPBleServiceData.h>
 #include <lib/support/CHIPMemString.h>
-#include <lib/support/CodeUtils.h>
-#include <lib/support/logging/CHIPLogging.h>
 #include <platform/DeviceInstanceInfoProvider.h>
 #include <platform/internal/BLEManager.h>
 #if CHIP_ENABLE_ADDITIONAL_DATA_ADVERTISING
@@ -43,6 +39,8 @@
 #include <bluetooth/addr.h>
 #include <hci_driver.h>
 
+#include "BLEManagerImpl.h"
+
 using namespace ::chip;
 using namespace ::chip::Ble;
 using namespace ::chip::System;
diff --git a/src/platform/bouffalolab/common/BLEManagerImpl.h b/src/platform/bouffalolab/common/BLEManagerImpl.h
index 394da27..1589d88 100644
--- a/src/platform/bouffalolab/common/BLEManagerImpl.h
+++ b/src/platform/bouffalolab/common/BLEManagerImpl.h
@@ -23,8 +23,6 @@
 #include <bluetooth/conn.h>
 #include <bluetooth/gatt.h>
 
-#include <lib/support/logging/CHIPLogging.h>
-
 namespace chip {
 namespace DeviceLayer {
 namespace Internal {
diff --git a/src/platform/bouffalolab/common/CHIPDevicePlatformConfig.h b/src/platform/bouffalolab/common/CHIPDevicePlatformConfig.h
index 698c941..ded512c 100644
--- a/src/platform/bouffalolab/common/CHIPDevicePlatformConfig.h
+++ b/src/platform/bouffalolab/common/CHIPDevicePlatformConfig.h
@@ -42,4 +42,4 @@
 #define CHIP_DEVICE_CONFIG_ENABLE_THREAD_TELEMETRY_FULL 0
 
 #define CHIP_DEVICE_CONFIG_CHIP_TASK_STACK_SIZE (8 * 1024)
-#define CHIP_DEVICE_CONFIG_MAX_EVENT_QUEUE_SIZE 25
+#define CHIP_DEVICE_CONFIG_MAX_EVENT_QUEUE_SIZE 50
diff --git a/src/platform/bouffalolab/common/CHIPPlatformConfig.h b/src/platform/bouffalolab/common/CHIPPlatformConfig.h
index fce5146..3cb267b 100644
--- a/src/platform/bouffalolab/common/CHIPPlatformConfig.h
+++ b/src/platform/bouffalolab/common/CHIPPlatformConfig.h
@@ -90,12 +90,3 @@
 #ifndef CHIP_CONFIG_DEBUG_CERT_VALIDATION
 #define CHIP_CONFIG_DEBUG_CERT_VALIDATION 0
 #endif // CHIP_CONFIG_DEBUG_CERT_VALIDATION
-
-// ==================== FreeRTOS Configuration Overrides ====================
-#ifndef CHIP_CONFIG_FREERTOS_USE_STATIC_TASK
-#define CHIP_CONFIG_FREERTOS_USE_STATIC_TASK 1
-#endif
-
-#ifndef CHIP_CONFIG_FREERTOS_USE_STATIC_QUEUE
-#define CHIP_CONFIG_FREERTOS_USE_STATIC_QUEUE 1
-#endif
diff --git a/src/platform/bouffalolab/common/ConfigurationManagerImpl.cpp b/src/platform/bouffalolab/common/ConfigurationManagerImpl.cpp
index 4618e7f..d4c06dc 100644
--- a/src/platform/bouffalolab/common/ConfigurationManagerImpl.cpp
+++ b/src/platform/bouffalolab/common/ConfigurationManagerImpl.cpp
@@ -21,12 +21,6 @@
 
 #include <platform/internal/GenericConfigurationManagerImpl.ipp>
 
-#include <lib/core/CHIPVendorIdentifiers.hpp>
-#include <platform/DiagnosticDataProvider.h>
-
-#include <lib/support/CodeUtils.h>
-#include <lib/support/logging/CHIPLogging.h>
-
 extern "C" {
 #include <bl_sys.h>
 }
diff --git a/src/platform/bouffalolab/common/ConfigurationManagerImpl.h b/src/platform/bouffalolab/common/ConfigurationManagerImpl.h
index 0427551..b9d207f 100644
--- a/src/platform/bouffalolab/common/ConfigurationManagerImpl.h
+++ b/src/platform/bouffalolab/common/ConfigurationManagerImpl.h
@@ -64,6 +64,10 @@
     CHIP_ERROR GetPrimaryWiFiMACAddress(uint8_t * buf) override;
 #endif
 
+#if !CHIP_DEVICE_CONFIG_ENABLE_WIFI && !CHIP_DEVICE_CONFIG_ENABLE_THREAD
+    CHIP_ERROR GetPrimaryMACAddress(MutableByteSpan buf) override;
+#endif
+
     static void DoFactoryReset(intptr_t arg);
 };
 
diff --git a/src/platform/bouffalolab/common/ConnectivityManagerImpl.cpp b/src/platform/bouffalolab/common/ConnectivityManagerImpl.cpp
index f1a47e5..4115f56 100644
--- a/src/platform/bouffalolab/common/ConnectivityManagerImpl.cpp
+++ b/src/platform/bouffalolab/common/ConnectivityManagerImpl.cpp
@@ -20,6 +20,9 @@
 #include <lib/support/CodeUtils.h>
 #include <lib/support/logging/CHIPLogging.h>
 #include <platform/ConnectivityManager.h>
+#include <platform/DiagnosticDataProvider.h>
+#include <platform/bouffalolab/common/BLConfig.h>
+#include <platform/bouffalolab/common/DiagnosticDataProviderImpl.h>
 #include <platform/internal/BLEManager.h>
 
 #include <platform/internal/GenericConnectivityManagerImpl_UDP.ipp>
@@ -33,9 +36,13 @@
 #ifdef BL602
 #include <platform/bouffalolab/BL602/NetworkCommissioningDriver.h>
 #endif
+#ifdef BL702
+#include <platform/bouffalolab/BL702/NetworkCommissioningDriver.h>
+#endif
 #endif
 
 #if CHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE
+#include <platform/internal/BLEManager.h>
 #include <platform/internal/GenericConnectivityManagerImpl_BLE.ipp>
 #endif
 
@@ -62,10 +69,8 @@
 #endif
 
 #if CHIP_DEVICE_CONFIG_ENABLE_WIFI
-    CHIP_ERROR err = SetWiFiStationMode(kWiFiStationMode_Enabled);
-    NetworkCommissioning::BLWiFiDriver::GetInstance().ReConnectWiFiNetwork();
-
-    ReturnErrorOnFailure(err);
+    mWiFiStationState = ConnectivityManager::kWiFiStationState_NotConnected;
+    ReturnErrorOnFailure(SetWiFiStationMode(kWiFiStationMode_Enabled));
 #endif
 
     return CHIP_NO_ERROR;
@@ -79,5 +84,258 @@
 #endif
 }
 
+#if CHIP_DEVICE_CONFIG_ENABLE_WIFI
+bool ConnectivityManagerImpl::_IsWiFiStationEnabled(void)
+{
+    return GetWiFiStationMode() == kWiFiStationMode_Enabled;
+}
+
+bool ConnectivityManagerImpl::_IsWiFiStationProvisioned(void)
+{
+    CHIP_ERROR err = CHIP_NO_ERROR;
+    char ssid[64]  = { 0 };
+    char psk[64]   = { 0 };
+    size_t ssidLen = 0;
+    size_t pskLen  = 0;
+
+    err = PersistedStorage::KeyValueStoreMgr().Get(BLConfig::kBLConfigKey_wifissid, (void *) ssid, 64, &ssidLen, 0);
+    SuccessOrExit(err);
+
+    err = PersistedStorage::KeyValueStoreMgr().Get(BLConfig::kBLConfigKey_wifipassword, (void *) psk, 64, &pskLen, 0);
+    SuccessOrExit(err);
+
+    return (ssidLen != 0);
+exit:
+    return false;
+}
+
+CHIP_ERROR ConnectivityManagerImpl::_SetWiFiStationMode(WiFiStationMode val)
+{
+    CHIP_ERROR err = CHIP_NO_ERROR;
+
+    VerifyOrExit(val != kWiFiStationMode_NotSupported, err = CHIP_ERROR_INVALID_ARGUMENT);
+
+    if (val != kWiFiStationMode_ApplicationControlled)
+    {
+        DeviceLayer::SystemLayer().ScheduleWork(DriveStationState, NULL);
+    }
+
+    if (mWiFiStationMode != val)
+    {
+        ChipLogProgress(DeviceLayer, "WiFi station mode change: %s -> %s", WiFiStationModeToStr(mWiFiStationMode),
+                        WiFiStationModeToStr(val));
+    }
+
+    mWiFiStationMode = val;
+
+exit:
+    return err;
+}
+
+void ConnectivityManagerImpl::ChangeWiFiStationState(WiFiStationState newState)
+{
+    if (mWiFiStationState != newState)
+    {
+        ChipLogProgress(DeviceLayer, "WiFi station state change: %s -> %s", WiFiStationStateToStr(mWiFiStationState),
+                        WiFiStationStateToStr(newState));
+        mWiFiStationState = newState;
+        ConnectivityMgrImpl().DriveStationState();
+        SystemLayer().ScheduleLambda([]() { NetworkCommissioning::BLWiFiDriver::GetInstance().OnNetworkStatusChange(); });
+    }
+}
+
+void ConnectivityManagerImpl::_ClearWiFiStationProvision(void)
+{
+    CHIP_ERROR err = CHIP_NO_ERROR;
+
+    err = PersistedStorage::KeyValueStoreMgr().Delete(BLConfig::kBLConfigKey_wifissid);
+    SuccessOrExit(err);
+
+    err = PersistedStorage::KeyValueStoreMgr().Delete(BLConfig::kBLConfigKey_wifipassword);
+    SuccessOrExit(err);
+
+exit:
+    return;
+}
+
+void ConnectivityManagerImpl::_OnWiFiStationProvisionChange(void)
+{
+    DeviceLayer::SystemLayer().ScheduleWork(DriveStationState, NULL);
+}
+
+CHIP_ERROR ConnectivityManagerImpl::ConnectProvisionedWiFiNetwork(void)
+{
+    char ssid[64]  = { 0 };
+    char psk[64]   = { 0 };
+    size_t ssidLen = 0;
+    size_t pskLen  = 0;
+
+    ReturnErrorOnFailure(PersistedStorage::KeyValueStoreMgr().Get(BLConfig::kBLConfigKey_wifissid, (void *) ssid, 64, &ssidLen, 0));
+    ReturnErrorOnFailure(
+        PersistedStorage::KeyValueStoreMgr().Get(BLConfig::kBLConfigKey_wifipassword, (void *) psk, 64, &pskLen, 0));
+
+    NetworkCommissioning::BLWiFiDriver::GetInstance().ConnectWiFiNetwork(ssid, ssidLen, psk, pskLen);
+
+    return CHIP_NO_ERROR;
+}
+
+void ConnectivityManagerImpl::OnWiFiStationConnected()
+{
+    ChipDeviceEvent event;
+    event.Type                          = DeviceEventType::kWiFiConnectivityChange;
+    event.WiFiConnectivityChange.Result = kConnectivity_Established;
+    PlatformMgr().PostEventOrDie(&event);
+
+    WiFiDiagnosticsDelegate * delegate = GetDiagnosticDataProvider().GetWiFiDiagnosticsDelegate();
+    if (delegate)
+    {
+        delegate->OnConnectionStatusChanged(
+            chip::to_underlying(chip::app::Clusters::WiFiNetworkDiagnostics::ConnectionStatusEnum::kConnected));
+    }
+}
+
+void ConnectivityManagerImpl::DriveStationState()
+{
+    ChipLogProgress(DeviceLayer, "DriveStationState: mWiFiStationState=%s", WiFiStationStateToStr(mWiFiStationState));
+    switch (mWiFiStationState)
+    {
+    case ConnectivityManager::kWiFiStationState_NotConnected: {
+        if (GetWiFiStationMode() == ConnectivityManager::kWiFiStationMode_Enabled && IsWiFiStationProvisioned())
+        {
+            ConnectProvisionedWiFiNetwork();
+        }
+    }
+    break;
+    case ConnectivityManager::kWiFiStationState_Connecting: {
+        ChipLogProgress(DeviceLayer, "Wi-Fi station is connecting to AP");
+    }
+    break;
+    case ConnectivityManager::kWiFiStationState_Connecting_Succeeded: {
+        ChipLogProgress(DeviceLayer, "Wi-Fi station successfully connects to AP");
+        mConnectivityFlag.ClearAll();
+        mConnectivityFlag.Set(ConnectivityFlags::kAwaitingConnectivity);
+    }
+    break;
+    case ConnectivityManager::kWiFiStationState_Connecting_Failed: {
+        ChipLogProgress(DeviceLayer, "Wi-Fi station connecting failed");
+        mConnectivityFlag.ClearAll();
+        OnWiFiStationDisconnected();
+        if (ConnectivityManager::kWiFiStationState_Connecting == mWiFiStationState)
+        {
+            SystemLayer().ScheduleLambda([]() { NetworkCommissioning::BLWiFiDriver::GetInstance().OnConnectWiFiNetwork(false); });
+        }
+    }
+    break;
+    case ConnectivityManager::kWiFiStationState_Connected: {
+        ChipLogProgress(DeviceLayer, "Wi-Fi stattion connected.");
+        OnWiFiStationConnected();
+        SystemLayer().ScheduleLambda([]() { NetworkCommissioning::BLWiFiDriver::GetInstance().OnConnectWiFiNetwork(true); });
+    }
+    break;
+    case ConnectivityManager::kWiFiStationState_Disconnecting: {
+        ChipLogProgress(DeviceLayer, "Wi-Fi station is disconnecting to AP");
+        mConnectivityFlag.ClearAll();
+    }
+    break;
+    default:
+        break;
+    }
+}
+
+void ConnectivityManagerImpl::DriveStationState(::chip::System::Layer * aLayer, void * aAppState)
+{
+    ConnectivityMgrImpl().DriveStationState();
+}
+#endif
+
+#if !CHIP_DEVICE_CONFIG_ENABLE_THREAD
+void ConnectivityManagerImpl::OnConnectivityChanged(struct netif * interface)
+{
+    bool haveIPv4Conn      = false;
+    bool haveIPv6Conn      = false;
+    const bool hadIPv4Conn = mConnectivityFlag.Has(ConnectivityFlags::kHaveIPv4InternetConnectivity);
+    const bool hadIPv6Conn = mConnectivityFlag.Has(ConnectivityFlags::kHaveIPv6InternetConnectivity);
+    IPAddress addr;
+
+    if (interface != NULL && netif_is_up(interface) && netif_is_link_up(interface))
+    {
+        mConnectivityFlag.Clear(ConnectivityFlags::kAwaitingConnectivity);
+
+        if (!ip4_addr_isany(netif_ip4_addr(interface)) && !ip4_addr_isany(netif_ip4_gw(interface)))
+        {
+            haveIPv4Conn = true;
+            char addrStr[INET_ADDRSTRLEN];
+            ip4addr_ntoa_r(netif_ip4_addr(interface), addrStr, sizeof(addrStr));
+            IPAddress::FromString(addrStr, addr);
+            if (0 != memcmp(netif_ip4_addr(interface), &m_ip4addr, sizeof(ip4_addr_t)))
+            {
+                ChipLogProgress(DeviceLayer, "IPv4 Address Assigned, %s", ip4addr_ntoa(netif_ip4_addr(interface)));
+                memcpy(&m_ip4addr, netif_ip4_addr(interface), sizeof(ip4_addr_t));
+                ConnectivityMgrImpl().OnIPv4AddressAvailable();
+            }
+        }
+
+        // Search among the IPv6 addresses assigned to the interface for a Global Unicast
+        // address (2000::/3) that is in the valid state.  If such an address is found...
+        for (uint32_t i = 0; i < LWIP_IPV6_NUM_ADDRESSES; i++)
+        {
+            if (!ip6_addr_islinklocal(netif_ip6_addr(interface, i)) && ip6_addr_isvalid(netif_ip6_addr_state(interface, i)))
+            {
+                haveIPv6Conn = true;
+                if (0 != memcmp(netif_ip6_addr(interface, i), m_ip6addr + i, sizeof(ip6_addr_t)))
+                {
+                    ChipLogProgress(DeviceLayer, "IPv6 Address Assigned, %s", ip6addr_ntoa(netif_ip6_addr(interface, i)));
+                    memcpy(m_ip6addr + i, netif_ip6_addr(interface, i), sizeof(ip6_addr_t));
+                    ConnectivityMgrImpl().OnIPv6AddressAvailable();
+                }
+            }
+        }
+    }
+
+    // If the internet connectivity state has changed...
+    if (haveIPv4Conn != hadIPv4Conn || haveIPv6Conn != hadIPv6Conn)
+    {
+        // Update the current state.
+        mConnectivityFlag.Set(ConnectivityFlags::kHaveIPv4InternetConnectivity, haveIPv4Conn);
+        mConnectivityFlag.Set(ConnectivityFlags::kHaveIPv6InternetConnectivity, haveIPv6Conn);
+
+        // Alert other components of the state change.
+        ChipDeviceEvent event;
+        event.Type                                 = DeviceEventType::kInternetConnectivityChange;
+        event.InternetConnectivityChange.IPv4      = GetConnectivityChange(hadIPv4Conn, haveIPv4Conn);
+        event.InternetConnectivityChange.IPv6      = GetConnectivityChange(hadIPv6Conn, haveIPv6Conn);
+        event.InternetConnectivityChange.ipAddress = addr;
+        PlatformMgr().PostEventOrDie(&event);
+
+        if (haveIPv4Conn != hadIPv4Conn)
+        {
+            ChipLogProgress(DeviceLayer, "%s Internet connectivity %s", "IPv4", (haveIPv4Conn) ? "ESTABLISHED" : "LOST");
+        }
+
+        if (haveIPv6Conn != hadIPv6Conn)
+        {
+            ChipLogProgress(DeviceLayer, "%s Internet connectivity %s", "IPv6", (haveIPv6Conn) ? "ESTABLISHED" : "LOST");
+        }
+    }
+}
+
+void ConnectivityManagerImpl::OnIPv4AddressAvailable()
+{
+    ChipDeviceEvent event;
+    event.Type                           = DeviceEventType::kInterfaceIpAddressChanged;
+    event.InterfaceIpAddressChanged.Type = InterfaceIpChangeType::kIpV4_Assigned;
+    PlatformMgr().PostEventOrDie(&event);
+}
+
+void ConnectivityManagerImpl::OnIPv6AddressAvailable()
+{
+    ChipDeviceEvent event;
+    event.Type                           = DeviceEventType::kInterfaceIpAddressChanged;
+    event.InterfaceIpAddressChanged.Type = InterfaceIpChangeType::kIpV6_Assigned;
+    PlatformMgr().PostEventOrDie(&event);
+}
+
+#endif
+
 } // namespace DeviceLayer
 } // namespace chip
diff --git a/src/platform/bouffalolab/common/ConnectivityManagerImpl.h b/src/platform/bouffalolab/common/ConnectivityManagerImpl.h
index 8c06c58..0011a8b 100644
--- a/src/platform/bouffalolab/common/ConnectivityManagerImpl.h
+++ b/src/platform/bouffalolab/common/ConnectivityManagerImpl.h
@@ -67,26 +67,52 @@
     // Allow the ConnectivityManager interface class to delegate method calls to
     // the implementation methods provided by this class.
     friend class ConnectivityManager;
+    friend void netif_status_callback(struct netif * netif);
 
-#if CHIP_DEVICE_CONFIG_ENABLE_WIFI
 public:
-    static WiFiStationState mWiFiStationState;
-
+#if CHIP_DEVICE_CONFIG_ENABLE_WIFI
     bool _IsWiFiStationConnected(void);
-    void WifiStationStateChange(void);
-    void OnStationConnected(void);
+    WiFiStationState GetWiFiStationState(void);
     void ChangeWiFiStationState(WiFiStationState newState);
+    void OnWiFiStationStateChanged(void);
+    void OnWiFiStationConnected(void);
+    void OnWiFiStationDisconnected(void);
+#endif
+
+#if !CHIP_DEVICE_CONFIG_ENABLE_THREAD
+    void OnConnectivityChanged(struct netif * interface);
+    void OnIPv4AddressAvailable();
     void OnIPv6AddressAvailable();
 #endif
 
 private:
     // ===== Members that implement the ConnectivityManager abstract interface.
 #if CHIP_DEVICE_CONFIG_ENABLE_WIFI
+    WiFiStationMode mWiFiStationMode;
+    WiFiStationState mWiFiStationState;
+
+    BitFlags<GenericConnectivityManagerImpl_WiFi::ConnectivityFlags> mConnectivityFlag;
+
     bool _IsWiFiStationEnabled(void);
-    // bool _IsWiFiStationProvisioned(void);
+    ConnectivityManager::WiFiStationMode _GetWiFiStationMode();
     CHIP_ERROR _SetWiFiStationMode(WiFiStationMode val);
-    void GetWifiState(void);
-    WiFiStationState GetWiFiStationState(void);
+    bool _IsWiFiStationProvisioned(void);
+    void _ClearWiFiStationProvision();
+    void _OnWiFiStationProvisionChange();
+    CHIP_ERROR ConnectProvisionedWiFiNetwork();
+#elif !CHIP_DEVICE_CONFIG_ENABLE_THREAD
+    enum class ConnectivityFlags : uint16_t
+    {
+        kHaveIPv4InternetConnectivity = 0x0001,
+        kHaveIPv6InternetConnectivity = 0x0002,
+        kAwaitingConnectivity         = 0x0010,
+    };
+    BitFlags<ConnectivityFlags> mConnectivityFlag;
+#endif
+
+#if !CHIP_DEVICE_CONFIG_ENABLE_THREAD
+    ip4_addr_t m_ip4addr;
+    ip6_addr_t m_ip6addr[LWIP_IPV6_NUM_ADDRESSES];
 #endif
 
     void DriveStationState(void);
@@ -95,7 +121,6 @@
     void _OnPlatformEvent(const ChipDeviceEvent * event);
 
     // ===== Members for internal use by the following friends.
-
     friend ConnectivityManager & ConnectivityMgr(void);
     friend ConnectivityManagerImpl & ConnectivityMgrImpl(void);
 
@@ -112,6 +137,11 @@
 {
     return mWiFiStationState == kWiFiStationState_Connected;
 }
+
+inline ConnectivityManager::WiFiStationMode ConnectivityManagerImpl::_GetWiFiStationMode(void)
+{
+    return kWiFiStationMode_Enabled;
+}
 #endif
 
 /**
diff --git a/src/platform/bouffalolab/common/DiagnosticDataProviderImpl.cpp b/src/platform/bouffalolab/common/DiagnosticDataProviderImpl.cpp
index 6e11e6f..8ad878a 100644
--- a/src/platform/bouffalolab/common/DiagnosticDataProviderImpl.cpp
+++ b/src/platform/bouffalolab/common/DiagnosticDataProviderImpl.cpp
@@ -31,6 +31,7 @@
 #ifdef CFG_USE_PSRAM
 extern "C" size_t get_heap3_size(void);
 #endif
+extern "C" struct netif * deviceInterface_getNetif(void);
 
 DiagnosticDataProviderImpl & DiagnosticDataProviderImpl::GetDefaultInstance()
 {
@@ -208,6 +209,69 @@
     return CHIP_NO_ERROR;
 }
 
+CHIP_ERROR DiagnosticDataProviderImpl::GetNetworkInterfaces(NetworkInterface ** netifpp)
+{
+    NetworkInterface * ifp = new NetworkInterface();
+
+#if CHIP_DEVICE_CONFIG_ENABLE_THREAD
+    const char * threadNetworkName = otThreadGetNetworkName(ThreadStackMgrImpl().OTInstance());
+    ifp->name                      = Span<const char>(threadNetworkName, strlen(threadNetworkName));
+    ifp->isOperational             = true;
+    ifp->offPremiseServicesReachableIPv4.SetNull();
+    ifp->offPremiseServicesReachableIPv6.SetNull();
+    ifp->type = EMBER_ZCL_INTERFACE_TYPE_ENUM_THREAD;
+    uint8_t macBuffer[ConfigurationManager::kPrimaryMACAddressLength];
+    ConfigurationMgr().GetPrimary802154MACAddress(macBuffer);
+    ifp->hardwareAddress = ByteSpan(macBuffer, ConfigurationManager::kPrimaryMACAddressLength);
+#else
+
+    struct netif * netif = deviceInterface_getNetif();
+
+    Platform::CopyString(ifp->Name, netif->name);
+    ifp->name          = CharSpan::fromCharString(ifp->Name);
+    ifp->isOperational = true;
+#if CHIP_DEVICE_CONFIG_ENABLE_WIFI
+    ifp->type          = EMBER_ZCL_INTERFACE_TYPE_ENUM_WI_FI;
+#else
+    ifp->type = EMBER_ZCL_INTERFACE_TYPE_ENUM_ETHERNET;
+#endif
+    ifp->offPremiseServicesReachableIPv4.SetNull();
+    ifp->offPremiseServicesReachableIPv6.SetNull();
+
+    memcpy(ifp->MacAddress, netif->hwaddr, sizeof(netif->hwaddr));
+    ifp->hardwareAddress = ByteSpan(ifp->MacAddress, sizeof(netif->hwaddr));
+
+    memcpy(ifp->Ipv4AddressesBuffer[0], netif_ip_addr4(netif), kMaxIPv4AddrSize);
+    ifp->Ipv4AddressSpans[0] = ByteSpan(ifp->Ipv4AddressesBuffer[0], kMaxIPv4AddrSize);
+    ifp->IPv4Addresses       = chip::app::DataModel::List<chip::ByteSpan>(ifp->Ipv4AddressSpans, 1);
+
+    int addr_count = 0;
+    for (size_t i = 0; (i < LWIP_IPV6_NUM_ADDRESSES) && (i < kMaxIPv6AddrCount); i++)
+    {
+        if (!ip6_addr_isany(&(netif->ip6_addr[i].u_addr.ip6)))
+        {
+            memcpy(ifp->Ipv6AddressesBuffer[addr_count], &(netif->ip6_addr[i].u_addr.ip6), sizeof(ip6_addr_t));
+            ifp->Ipv6AddressSpans[addr_count] = ByteSpan(ifp->Ipv6AddressesBuffer[addr_count], kMaxIPv6AddrSize);
+        }
+    }
+    ifp->IPv6Addresses = chip::app::DataModel::List<chip::ByteSpan>(ifp->Ipv6AddressSpans, addr_count);
+#endif
+
+    *netifpp = ifp;
+
+    return CHIP_NO_ERROR;
+}
+
+void DiagnosticDataProviderImpl::ReleaseNetworkInterfaces(NetworkInterface * netifp)
+{
+    while (netifp)
+    {
+        NetworkInterface * del = netifp;
+        netifp                 = netifp->Next;
+        delete del;
+    }
+}
+
 DiagnosticDataProvider & GetDiagnosticDataProviderImpl()
 {
     return DiagnosticDataProviderImpl::GetDefaultInstance();
diff --git a/src/platform/bouffalolab/common/SystemPlatformConfig.h b/src/platform/bouffalolab/common/SystemPlatformConfig.h
index 2fb7579..4912f40 100644
--- a/src/platform/bouffalolab/common/SystemPlatformConfig.h
+++ b/src/platform/bouffalolab/common/SystemPlatformConfig.h
@@ -26,5 +26,6 @@
 } // namespace chip
 
 // ==================== Platform Adaptations ====================
+#define CHIP_SYSTEM_CONFIG_PLATFORM_PROVIDES_EVENT_FUNCTIONS 1
 #define CHIP_SYSTEM_CONFIG_PLATFORM_PROVIDES_TIME 1
 #define CHIP_SYSTEM_CONFIG_EVENT_OBJECT_TYPE const struct ::chip::DeviceLayer::ChipDeviceEvent *
diff --git a/src/platform/device.gni b/src/platform/device.gni
index d740663..ecf0117 100644
--- a/src/platform/device.gni
+++ b/src/platform/device.gni
@@ -111,11 +111,12 @@
   }
 }
 
-if ((chip_device_platform == "bl702" || chip_device_platform == "bl702l") &&
-    chip_enable_openthread) {
-  chip_mdns = "platform"
-} else if (chip_device_platform == "bl702" && chip_enable_wifi) {
-  chip_mdns = "minimal"
+if (chip_device_platform == "bl702" || chip_device_platform == "bl702l") {
+  if (chip_enable_openthread) {
+    chip_mdns = "platform"
+  } else {
+    chip_mdns = "minimal"
+  }
 }
 
 _chip_device_layer = "none"
diff --git a/third_party/bouffalolab/bl702/bl_iot_sdk.gni b/third_party/bouffalolab/bl702/bl_iot_sdk.gni
index 8b69f1b..5c35e8c 100644
--- a/third_party/bouffalolab/bl702/bl_iot_sdk.gni
+++ b/third_party/bouffalolab/bl702/bl_iot_sdk.gni
@@ -20,8 +20,6 @@
 
 declare_args() {
   bl_iot_sdk_root = "${chip_root}/third_party/bouffalolab/repo"
-
-  enable_cdc_module = false
 }
 
 assert(bl_iot_sdk_root != "", "bl_iot_sdk_root must be specified")
@@ -34,14 +32,6 @@
 template("bl_iot_sdk") {
   sdk_target_name = target_name
 
-  if (defined(invoker.enable_zigbee)) {
-    enable_zigbee = invoker.enable_zigbee
-  }
-
-  if (defined(invoker.enable_cdc_module)) {
-    enable_cdc_module = invoker.enable_cdc_module
-  }
-
   config("${sdk_target_name}_config") {
     defines = [
       "__FILENAME__=strrchr(__FILE__,'/')?strrchr(__FILE__,'/')+1:__FILE__",
@@ -241,7 +231,10 @@
   }
 
   source_set("${sdk_target_name}_hosal") {
-    defines = [ "CFG_USE_XTAL32K=1" ]
+    defines = [
+      "CFG_USE_XTAL32K=1",
+      "DISABLE_PRINT=1",
+    ]
 
     sources = [
       "${bl_iot_sdk_root}/components/platform/hosal/bl702_hal/bl_adc.c",
@@ -728,62 +721,27 @@
     ]
   }
 
-  config("${sdk_target_name}_config_lwip_port") {
-    _include_dirs = [
-      "${bl_iot_sdk_root}/components/network/lwip/lwip-port",
-      "${bl_iot_sdk_root}/components/network/lwip/lwip-port/config",
-      "${bl_iot_sdk_root}/components/stage/virt_net/include",
-      "${bl_iot_sdk_root}/components/stage/throughput/bl702/inc",
-    ]
-
-    defines = [
-      "TCPIP_THREAD_PRIO=24",
-      "CFG_ETHERNET_ENABLE=1",
-    ]
-
-    cflags = []
-    foreach(include_dir, _include_dirs) {
-      cflags += [ "-isystem" + rebase_path(include_dir, root_build_dir) ]
-    }
-
-    cflags += [
-      "-Wno-conversion",
-      "-Wno-unused-function",
+  config("${sdk_target_name}_config_ethernet") {
+    include_dirs = [
+      "${bl_iot_sdk_root}/components/platform/soc/bl702/bl702_ethernet/Inc",
     ]
   }
 
-  source_set("${sdk_target_name}_lwip_port") {
-    defines = [
-      "SPI_WIFI_RXBUFF_IN_PSRAM=1",
-      "VIRT_NET_SPI_RX_TASK_PRIORITY=25",
-    ]
+  source_set("${sdk_target_name}_ethernet") {
+    defines = [ "DISABLE_PRINT=1" ]
+    sources = [ "${bl_iot_sdk_root}/components/platform/soc/bl702/bl702_ethernet/Src/eth_bd.c" ]
 
-    #    include_dirs = [
-    #      "${bl_iot_sdk_root}/components/network/lwip/lwip-port/arch",
-    #      "${bl_iot_sdk_root}/components/network/lwip/lwip-port/FreeRTOS",
-    #      "${bl_iot_sdk_root}/components/stage/throughput"
-    #    ]
-
-    #    sources = [
-    #      "${bl_iot_sdk_root}/components/network/lwip/lwip-port/FreeRTOS/ethernetif.c",
-    #      "${bl_iot_sdk_root}/components/network/lwip/lwip-port/FreeRTOS/sys_arch.c"
-    #    ]
-
-    #    sources += [
-    #      "${bl_iot_sdk_root}/components/stage/throughput/bl702/src/tp_spi_master.c",
-    #    ]
-    #    sources += [
-    #      "${bl_iot_sdk_root}/components/stage/virt_net/src/virt_net.c",
-    #      "${bl_iot_sdk_root}/components/stage/virt_net/src/virt_net_spi.c",
-    #    ]
-
-    public_configs = [
-      ":${sdk_target_name}_config",
-      ":${sdk_target_name}_config_lwip_port",
+    configs += [
+      ":${sdk_target_name}_config_BSP_Driver",
+      ":${sdk_target_name}_config_hosal",
+      ":${sdk_target_name}_config_utils",
+      ":${sdk_target_name}_config_freertos",
       ":${sdk_target_name}_config_lwip",
     ]
-
-    cflags = [ "-Wno-sign-compare" ]
+    public_configs = [
+      ":${sdk_target_name}_config",
+      ":${sdk_target_name}_config_ethernet",
+    ]
   }
 
   config("${sdk_target_name}_config_lwip") {
@@ -797,12 +755,15 @@
     ]
 
     defines = [
+      "CFG_ETHERNET_ENABLE=1",
       "LWIP_IPV6=1",
       "LWIP_IPV4=1",
       "LWIP_IPV6_DHCP6=1",
       "LWIP_IPV6_SCOPES=0",
       "PBUF_POOL_SIZE=20",
-      "PBUF_POOL_BUFSIZE=(1280+150)",
+      "PBUF_POOL_BUFSIZE=1600",
+      "CONFIG_LWIP_HOOK_IP6_ROUTE_DEFAULT",
+      "CONFIG_LWIP_HOOK_ND6_GET_GW_DEFAULT",
     ]
   }
 
@@ -881,6 +842,12 @@
       ":${sdk_target_name}_config",
       ":${sdk_target_name}_config_lwip",
     ]
+
+    cflags = [
+      "-Wno-incompatible-pointer-types",
+      "-Wno-unused-variable",
+      "-Wno-sign-compare",
+    ]
   }
 
   group(sdk_target_name) {
@@ -888,6 +855,7 @@
       ":${sdk_target_name}_BSP_Driver",
       ":${sdk_target_name}_bl702_freertos",
       ":${sdk_target_name}_ble",
+      ":${sdk_target_name}_ethernet",
       ":${sdk_target_name}_fs",
       ":${sdk_target_name}_hosal",
       ":${sdk_target_name}_libc",
@@ -898,16 +866,16 @@
       ":${sdk_target_name}_utils",
     ]
 
-    if (chip_enable_openthread) {
+    if (defined(invoker.chip_enable_wifi) && invoker.chip_enable_wifi) {
+    } else if (defined(invoker.chip_enable_openthread) &&
+               invoker.chip_enable_openthread) {
       public_deps += [ ":${sdk_target_name}_openthread_port" ]
-    }
-
-    if (chip_enable_wifi) {
-      public_deps += [ ":${sdk_target_name}_lwip_port" ]
+    } else {
+      public_deps += [ ":${sdk_target_name}_ethernet" ]
       public_deps += [ ":${sdk_target_name}_lwip" ]
     }
 
-    if (enable_cdc_module) {
+    if (defined(invoker.enable_cdc_module) && invoker.enable_cdc_module) {
       public_deps += [ ":${sdk_target_name}_bl702_usb_cdc" ]
     }
   }
diff --git a/third_party/bouffalolab/bl702l/bl_iot_sdk.gni b/third_party/bouffalolab/bl702l/bl_iot_sdk.gni
index 9362f2d..89d35bc 100644
--- a/third_party/bouffalolab/bl702l/bl_iot_sdk.gni
+++ b/third_party/bouffalolab/bl702l/bl_iot_sdk.gni
@@ -687,7 +687,8 @@
       ":${sdk_target_name}_utils",
     ]
     public_configs = [ ":${sdk_target_name}_config_BSP_Driver" ]
-    if (chip_enable_openthread) {
+    if (defined(invoker.chip_enable_openthread) &&
+        invoker.chip_enable_openthread) {
       public_deps += [ ":${sdk_target_name}_openthread_port" ]
     }
   }
diff --git a/third_party/bouffalolab/repo b/third_party/bouffalolab/repo
index 31489e4..d1aba79 160000
--- a/third_party/bouffalolab/repo
+++ b/third_party/bouffalolab/repo
@@ -1 +1 @@
-Subproject commit 31489e4c11dbe341f7a38792efc6d7a95d1d48ea
+Subproject commit d1aba795ad1b36ab2a0f58f664caf176e26fe97b
