diff --git a/.github/workflows/examples-bl602.yaml b/.github/workflows/examples-bl602.yaml index 56166d9e667756..59e6a44b499ab5 100644 --- a/.github/workflows/examples-bl602.yaml +++ b/.github/workflows/examples-bl602.yaml @@ -31,7 +31,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:latest + image: connectedhomeip/chip-build-bouffalolab:0.6.12 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" steps: @@ -44,7 +44,7 @@ jobs: attempt_limit: 3 attempt_delay: 2000 - name: Checkout submodules - run: scripts/checkout_submodules.py --shallow --platform bl602 + run: scripts/checkout_submodules.py --shallow --platform bl602 --recursive - name: Set up environment for size reports if: ${{ !env.ACT }} diff --git a/.github/workflows/examples-bouffalolab.yaml b/.github/workflows/examples-bouffalolab.yaml index 4f32c97aaf424e..ce291036cdfe1a 100644 --- a/.github/workflows/examples-bouffalolab.yaml +++ b/.github/workflows/examples-bouffalolab.yaml @@ -31,7 +31,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build:latest + image: connectedhomeip/chip-build-bouffalolab:0.6.12 volumes: - "/tmp/bloat_reports:/tmp/bloat_reports" steps: @@ -44,7 +44,7 @@ jobs: attempt_limit: 3 attempt_delay: 2000 - name: Checkout submodules - run: scripts/checkout_submodules.py --shallow --platform bouffalolab + run: scripts/checkout_submodules.py --shallow --platform bouffalolab --recursive - name: Set up environment for size reports if: ${{ !env.ACT }} diff --git a/.gitmodules b/.gitmodules index 5a60849e011130..cc98c5312bedfb 100644 --- a/.gitmodules +++ b/.gitmodules @@ -268,11 +268,6 @@ [submodule "third_party/boringssl/repo/src"] path = third_party/boringssl/repo/src url = https://github.com/google/boringssl.git -[submodule "boufalolab_repo"] - path = third_party/bouffalolab/repo - url = https://github.com/bouffalolab/bl_iot_sdk.git - branch = master - platforms = bouffalolab,bl602 [submodule "third_party/mt793x_sdk/filogic"] path = third_party/mt793x_sdk/filogic url = https://github.com/MediaTek-Labs/genio-matter-bsp.git @@ -288,3 +283,9 @@ url = https://github.com/matter-mtk/genio-matter-lwip.git branch = main platforms = genio +[submodule "bouffalolab_sdk"] + path = third_party/bouffalolab/repo + url = https://github.com/bouffalolab/bl_iot_sdk_tiny.git + branch = master + platforms = bouffalolab,bl602 + diff --git a/build_overrides/bouffalolab_iot_sdk.gni b/build_overrides/bouffalolab_iot_sdk.gni index 165bf5944f16d8..77ab3440927271 100644 --- a/build_overrides/bouffalolab_iot_sdk.gni +++ b/build_overrides/bouffalolab_iot_sdk.gni @@ -19,6 +19,5 @@ declare_args() { # Root directory for bl702 SDK build files. bl702_sdk_build_root = "//third_party/bouffalolab/bl702" - # Root directory of toolchain of Bouffalolab chips - bouffalolab_toolchain = "//third_party/bouffalolab/repo/toolchain/riscv" + bouffalolab_sdk_root = "/opt/bouffalolab_sdk" } diff --git a/examples/build_overrides/bouffalolab_iot_sdk.gni b/examples/build_overrides/bouffalolab_iot_sdk.gni index c11bd8fa0507f7..1eb018a7ef2c85 100644 --- a/examples/build_overrides/bouffalolab_iot_sdk.gni +++ b/examples/build_overrides/bouffalolab_iot_sdk.gni @@ -21,6 +21,5 @@ declare_args() { bl702_sdk_build_root = "//third_party/connectedhomeip/third_party/bouffalolab/bl702" - # Root directory of toolchain of Bouffalolab chips - bouffalolab_toolchain = "/third_party/bouffalolab/repo/toolchain/riscv" + bouffalolab_sdk_root = "/opt/bouffalolab_sdk" } diff --git a/examples/lighting-app/bouffalolab/bl602/BUILD.gn b/examples/lighting-app/bouffalolab/bl602/BUILD.gn index a00a5a47503269..b5820d2d99845e 100644 --- a/examples/lighting-app/bouffalolab/bl602/BUILD.gn +++ b/examples/lighting-app/bouffalolab/bl602/BUILD.gn @@ -43,6 +43,8 @@ declare_args() { # OTA periodic query timeout in seconds ota_periodic_query_timeout = 86400 + + baudrate = 115200 } show_qr_code = false @@ -68,8 +70,8 @@ bl602_sdk("sdk") { "CONFIG_PSM_EASYFLASH_SIZE=16384", "CHIP_DEVICE_CONFIG_USE_TEST_SETUP_PIN_CODE=${setupPinCode}", "OTA_PERIODIC_QUERY_TIMEOUT=${ota_periodic_query_timeout}", + "UART_BAUDRATE=${baudrate}", ] - if (chip_enable_pw_rpc) { defines += [ "PW_RPC_ENABLED" ] } @@ -113,6 +115,8 @@ bl602_executable("lighting_app") { defines = [ "BOARD_ID=1" ] } + defines += [ "UART_BAUDRATE=${baudrate}" ] + if (show_qr_code) { sources += [ "${examples_plat_dir}/display/lcd.c" ] diff --git a/examples/lighting-app/bouffalolab/bl602/README.md b/examples/lighting-app/bouffalolab/bl602/README.md index 1c66c73ecc5c83..d1eca72d0890a1 100644 --- a/examples/lighting-app/bouffalolab/bl602/README.md +++ b/examples/lighting-app/bouffalolab/bl602/README.md @@ -31,6 +31,22 @@ The steps in this document were validated on Ubuntu 18.04 and 20.04. source ./scripts/activate.sh ``` +- Setup build environment for `Bouffalo Lab` SoC + + Run `setup.sh` to install `Bouffalo Lab` SDK to /opt/bouffalolab_sdk + + ``` + cd third_party/bouffalolab/repo + sudo bash script/setup.sh + ``` + + Please execute following command export `BOUFFALOLAB_SDK_ROOT` before + building. + + ``` + export BOUFFALOLAB_SDK_ROOT=/opt/bouffalolab_sdk + ``` + ## Build the image and flash the board - Build the diff --git a/examples/lighting-app/bouffalolab/bl602/src/AppTask.cpp b/examples/lighting-app/bouffalolab/bl602/src/AppTask.cpp index cd865f515b85e4..4e8f886c5d7698 100644 --- a/examples/lighting-app/bouffalolab/bl602/src/AppTask.cpp +++ b/examples/lighting-app/bouffalolab/bl602/src/AppTask.cpp @@ -168,8 +168,6 @@ void AppTask::AppTaskMain(void * pvParameter) CHIP_ERROR err; log_info("App Task entered\r\n"); - log_async_init(); - enable_async_log(); err = sWiFiNetworkCommissioningInstance.Init(); if (CHIP_NO_ERROR != err) diff --git a/examples/lighting-app/bouffalolab/bl702/README.md b/examples/lighting-app/bouffalolab/bl702/README.md index f02b1b84758f86..ac753d97d77115 100644 --- a/examples/lighting-app/bouffalolab/bl702/README.md +++ b/examples/lighting-app/bouffalolab/bl702/README.md @@ -31,6 +31,21 @@ following boards: ```shell source scripts/activate.sh ``` +- Setup build environment for `Bouffalo Lab` SoC + + Run `setup.sh` to install `Bouffalo Lab` SDK to /opt/bouffalolab_sdk + + ``` + cd third_party/bouffalolab/repo + sudo bash script/setup.sh + ``` + + Please execute following command export `BOUFFALOLAB_SDK_ROOT` before + building. + + ``` + export BOUFFALOLAB_SDK_ROOT=/opt/bouffalolab_sdk + ``` ## Build CHIP BL702 Lighting App example diff --git a/examples/platform/bouffalolab/common/toolchain/riscv_toolchain.gni b/examples/platform/bouffalolab/common/toolchain/riscv_toolchain.gni index d382cb3179ee66..db46fc1a98f4fa 100644 --- a/examples/platform/bouffalolab/common/toolchain/riscv_toolchain.gni +++ b/examples/platform/bouffalolab/common/toolchain/riscv_toolchain.gni @@ -23,9 +23,9 @@ template("riscv_toolchain") { _tool_name_root = "" if ("linux" == host_os) { - _tool_name_root = "${root_build_dir}/../../${bouffalolab_toolchain}/Linux/bin/riscv64-unknown-elf-" + _tool_name_root = "${bouffalolab_sdk_root}/toolchain/riscv/Linux/bin/riscv64-unknown-elf-" } else if ("mac" == host_os || "darwin" == host_os) { - _tool_name_root = "${root_build_dir}/../../${bouffalolab_toolchain}/Darwin/bin/riscv64-unknown-elf-" + _tool_name_root = "${bouffalolab_sdk_root}/toolchain/riscv/Darwin/bin/riscv64-unknown-elf-" } ar = _tool_name_root + "ar" diff --git a/scripts/build/build/targets.py b/scripts/build/build/targets.py index 99be77b3ad7c3c..cf3cc478bab55c 100755 --- a/scripts/build/build/targets.py +++ b/scripts/build/build/targets.py @@ -618,7 +618,8 @@ def TizenTargets(): def Bl602Targets(): target = Target('bl602', Bl602Builder) - yield target.Extend('light', board=Bl602Board.BL602BOARD, app=Bl602App.LIGHT) + yield target.Extend('light', board=Bl602Board.BL602BOARD, app=Bl602App.LIGHT, baudrate=115200) + yield target.Extend('light-2m-uart', board=Bl602Board.BL602BOARD, app=Bl602App.LIGHT, baudrate=2000000) def BouffalolabTargets(): diff --git a/scripts/build/builders/bl602.py b/scripts/build/builders/bl602.py index f8fd4cacf32a5f..c6211b6a192758 100644 --- a/scripts/build/builders/bl602.py +++ b/scripts/build/builders/bl602.py @@ -57,7 +57,8 @@ def __init__(self, root, runner, app: Bl602App = Bl602App.LIGHT, - board: Bl602Board = Bl602Board.BL602BOARD): + board: Bl602Board = Bl602Board.BL602BOARD, + baudrate=115200): super(Bl602Builder, self).__init__( root=os.path.join(root, 'examples', app.ExampleName(), 'bouffalolab', 'bl602'), @@ -72,9 +73,12 @@ def __init__(self, self.app = app self.board = board + self.baudrate = baudrate + + self.argsOpt.append('bouffalolab_sdk_root="%s"' % os.environ['BOUFFALOLAB_SDK_ROOT']) def GnBuildArgs(self): - return self.argsOpt + ['bl602_board="%s"' % self.board.GnArgName()] + return self.argsOpt + ['bl602_board="%s"' % self.board.GnArgName()] + ['baudrate=%d' % self.baudrate] def build_outputs(self): items = { diff --git a/scripts/build/builders/bouffalolab.py b/scripts/build/builders/bouffalolab.py index b391251093653f..eafd4b080bf9de 100644 --- a/scripts/build/builders/bouffalolab.py +++ b/scripts/build/builders/bouffalolab.py @@ -88,6 +88,8 @@ def __init__(self, if enable_rpcs: self.argsOpt.append('import("//with_pw_rpc.gni")') + self.argsOpt.append('bouffalolab_sdk_root="%s"' % os.environ['BOUFFALOLAB_SDK_ROOT']) + def GnBuildArgs(self): return self.argsOpt diff --git a/scripts/build/test.py b/scripts/build/test.py index 056d34166a40ef..37861aa2798c0a 100644 --- a/scripts/build/test.py +++ b/scripts/build/test.py @@ -47,6 +47,7 @@ def build_actual_output(root: str, out: str, args: List[str]) -> List[str]: 'NXP_K32W0_SDK_ROOT': 'TEST_NXP_K32W0_SDK_ROOT', 'IMX_SDK_ROOT': 'IMX_SDK_ROOT', 'TI_SYSCONFIG_ROOT': 'TEST_TI_SYSCONFIG_ROOT', + 'BOUFFALOLAB_SDK_ROOT': 'TEST_BOUFFALOLAB_SDK_ROOT', }) retval = subprocess.run([ diff --git a/scripts/build/testdata/all_targets_except_host.txt b/scripts/build/testdata/all_targets_except_host.txt index 039d833eb36fcf..5f0ace02087a71 100644 --- a/scripts/build/testdata/all_targets_except_host.txt +++ b/scripts/build/testdata/all_targets_except_host.txt @@ -18,6 +18,7 @@ android-x64-tv-server android-x86-chip-tool android-x86-tv-server bl602-light +bl602-light-2m-uart bouffalolab-BL706-IoT-DVK-light bouffalolab-BL706-IoT-DVK-light-rpc bouffalolab-BL706-NIGHT-LIGHT-light diff --git a/scripts/build/testdata/build_all_except_host.txt b/scripts/build/testdata/build_all_except_host.txt index 401f68cedf0f17..0a6f07f064b817 100644 --- a/scripts/build/testdata/build_all_except_host.txt +++ b/scripts/build/testdata/build_all_except_host.txt @@ -149,16 +149,19 @@ gn gen --check --fail-on-unused-args {out}/android-x86-tv-server '--args=target_ bash -c 'yes | TEST_ANDROID_HOME/tools/bin/sdkmanager --licenses >/dev/null' # Generating bl602-light -gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/bouffalolab/bl602 '--args=custom_toolchain="{root}/../../examples/platform/bouffalolab/common/toolchain:riscv_gcc" bl602_board="BL-HWC-G1"' {out}/bl602-light +gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/bouffalolab/bl602 '--args=custom_toolchain="{root}/../../examples/platform/bouffalolab/common/toolchain:riscv_gcc" bouffalolab_sdk_root="TEST_BOUFFALOLAB_SDK_ROOT" bl602_board="BL-HWC-G1" baudrate=115200' {out}/bl602-light + +# Generating bl602-light-2m-uart +gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/bouffalolab/bl602 '--args=custom_toolchain="{root}/../../examples/platform/bouffalolab/common/toolchain:riscv_gcc" bouffalolab_sdk_root="TEST_BOUFFALOLAB_SDK_ROOT" bl602_board="BL-HWC-G1" baudrate=2000000' {out}/bl602-light-2m-uart # Generating bouffalolab-BL706-IoT-DVK-light -gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/bouffalolab/bl702 '--args=custom_toolchain="{root}/../../examples/platform/bouffalolab/common/toolchain:riscv_gcc" board="BL706-IoT-DVK" module_type="BL706C-22"' {out}/bouffalolab-BL706-IoT-DVK-light +gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/bouffalolab/bl702 '--args=custom_toolchain="{root}/../../examples/platform/bouffalolab/common/toolchain:riscv_gcc" board="BL706-IoT-DVK" module_type="BL706C-22" bouffalolab_sdk_root="TEST_BOUFFALOLAB_SDK_ROOT"' {out}/bouffalolab-BL706-IoT-DVK-light # Generating bouffalolab-BL706-IoT-DVK-light-rpc -gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/bouffalolab/bl702 '--args=custom_toolchain="{root}/../../examples/platform/bouffalolab/common/toolchain:riscv_gcc" board="BL706-IoT-DVK" module_type="BL706C-22" import("//with_pw_rpc.gni")' {out}/bouffalolab-BL706-IoT-DVK-light-rpc +gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/bouffalolab/bl702 '--args=custom_toolchain="{root}/../../examples/platform/bouffalolab/common/toolchain:riscv_gcc" board="BL706-IoT-DVK" module_type="BL706C-22" import("//with_pw_rpc.gni") bouffalolab_sdk_root="TEST_BOUFFALOLAB_SDK_ROOT"' {out}/bouffalolab-BL706-IoT-DVK-light-rpc # Generating bouffalolab-BL706-NIGHT-LIGHT-light -gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/bouffalolab/bl702 '--args=custom_toolchain="{root}/../../examples/platform/bouffalolab/common/toolchain:riscv_gcc" board="BL706-NIGHT-LIGHT" module_type="BL702"' {out}/bouffalolab-BL706-NIGHT-LIGHT-light +gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/lighting-app/bouffalolab/bl702 '--args=custom_toolchain="{root}/../../examples/platform/bouffalolab/common/toolchain:riscv_gcc" board="BL706-NIGHT-LIGHT" module_type="BL702" bouffalolab_sdk_root="TEST_BOUFFALOLAB_SDK_ROOT"' {out}/bouffalolab-BL706-NIGHT-LIGHT-light # Generating cc13x2x7_26x2x7-all-clusters gn gen --check --fail-on-unused-args --export-compile-commands --root={root}/examples/all-clusters-app/cc13x2x7_26x2x7 '--args=ti_sysconfig_root="TEST_TI_SYSCONFIG_ROOT"' {out}/cc13x2x7_26x2x7-all-clusters @@ -1577,6 +1580,9 @@ cp {out}/android-x86-tv-server/lib/TvApp.jar {root}/examples/tv-app/android/App/ # Building bl602-light ninja -C {out}/bl602-light +# Building bl602-light-2m-uart +ninja -C {out}/bl602-light-2m-uart + # Building bouffalolab-BL706-IoT-DVK-light ninja -C {out}/bouffalolab-BL706-IoT-DVK-light diff --git a/scripts/build/testdata/glob_star_targets_except_host.txt b/scripts/build/testdata/glob_star_targets_except_host.txt index c5db6a27cb177c..51dec0a388eebf 100644 --- a/scripts/build/testdata/glob_star_targets_except_host.txt +++ b/scripts/build/testdata/glob_star_targets_except_host.txt @@ -18,6 +18,7 @@ android-x64-tv-server android-x86-chip-tool android-x86-tv-server bl602-light +bl602-light-2m-uart bouffalolab-BL706-IoT-DVK-light bouffalolab-BL706-IoT-DVK-light-rpc bouffalolab-BL706-NIGHT-LIGHT-light diff --git a/scripts/examples/gn_bl602_example.sh b/scripts/examples/gn_bl602_example.sh index 9ae95a0a960d2d..11aae92984498a 100755 --- a/scripts/examples/gn_bl602_example.sh +++ b/scripts/examples/gn_bl602_example.sh @@ -60,6 +60,6 @@ for arg; do esac done -gn gen --fail-on-unused-args --root="$EXAMPLE_DIR" "$OUTPUT_DIR" --args="${GN_ARGS[*]} custom_toolchain=\"$MATTER_ROOT/examples/platform/bouffalolab/common/toolchain:riscv_gcc\"" +gn gen --fail-on-unused-args --root="$EXAMPLE_DIR" "$OUTPUT_DIR" --args="${GN_ARGS[*]} bouffalolab_sdk_root=\"$BOUFFALOLAB_SDK_ROOT\" custom_toolchain=\"$MATTER_ROOT/examples/platform/bouffalolab/common/toolchain:riscv_gcc\"" ninja -C "$OUTPUT_DIR" "${NINJA_ARGS[@]}" diff --git a/scripts/examples/gn_bouffalolab_example.sh b/scripts/examples/gn_bouffalolab_example.sh index f04307607ba30b..dafae9fa1f0c73 100755 --- a/scripts/examples/gn_bouffalolab_example.sh +++ b/scripts/examples/gn_bouffalolab_example.sh @@ -140,6 +140,8 @@ else exit 1 fi + optArgs=$optArgs' bouffalolab_sdk_root="'$BOUFFALOLAB_SDK_ROOT'"' + example_dir=$MATTER_ROOT/examples/$example_name/bouffalolab/$bouffalo_chip output_dir=$MATTER_ROOT/$output_folder diff --git a/src/platform/bouffalolab/BL602/lwip_default_hooks.h b/src/platform/bouffalolab/BL602/lwip_default_hooks.h new file mode 100644 index 00000000000000..3c1d1d186c8836 --- /dev/null +++ b/src/platform/bouffalolab/BL602/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/third_party/bouffalolab/bl602/bl602_executable.gni b/third_party/bouffalolab/bl602/bl602_executable.gni index 8f775f6292ccbc..71c2bc6b8283b5 100644 --- a/third_party/bouffalolab/bl602/bl602_executable.gni +++ b/third_party/bouffalolab/bl602/bl602_executable.gni @@ -25,11 +25,9 @@ template("bl602_executable") { objcopy_image_format = "binary" objcopy = "riscv64-unknown-elf-objcopy" if ("linux" == host_os) { - objcopy = - "../../${bouffalolab_toolchain}/Linux/bin/riscv64-unknown-elf-objcopy" + objcopy = "${bouffalolab_sdk_root}/toolchain/riscv/Linux/bin/riscv64-unknown-elf-objcopy" } else if ("mac" == host_os || "darwin" == host_os) { - objcopy = - "../../${bouffalolab_toolchain}/Darwin/bin/riscv64-unknown-elf-objcopy" + objcopy = "${bouffalolab_sdk_root}/toolchain/riscv/Darwin/bin/riscv64-unknown-elf-objcopy" } # Copy flashing dependencies to the output directory so that the output diff --git a/third_party/bouffalolab/bl602/bl602_sdk.gni b/third_party/bouffalolab/bl602/bl602_sdk.gni index 5c9c2b370eb39d..afbd85304a50d9 100644 --- a/third_party/bouffalolab/bl602/bl602_sdk.gni +++ b/third_party/bouffalolab/bl602/bl602_sdk.gni @@ -121,6 +121,7 @@ template("bl602_sdk") { "${bl602_sdk_root}/components/network/wifi_manager/bl60x_wifi_driver/include", "${bl602_sdk_root}/components/network/wifi_manager/bl60x_wifi_driver", "${bl602_sdk_root}/components/network/dns_server/include", + "${bl602_sdk_root}/components/network/rfparam_adapter_tmp/rftlv", "${bl602_sdk_root}/components/platform/soc/bl602/bl602_std/bl602_std/StdDriver/Inc", "${bl602_sdk_root}/components/security/blcrypto_suite/inc/blcrypto_suite", @@ -251,6 +252,7 @@ template("bl602_sdk") { #include defines "OS_USING_FREERTOS", "BL602_MATTER_SUPPORT", + "PBUF_POOL_SIZE=20", "TD_DIAGNOSIS_STA", "CONFIG_ENABLE_IPV6_ADDR_CALLBACK", "CONFIG_LWIP_HOOK_IP6_ROUTE_DEFAULT", @@ -330,6 +332,7 @@ template("bl602_sdk") { "${bl602_sdk_root}/components/stage/easyflash4/src/ef_utils.c", "${bl602_sdk_root}/components/sys/blmtd/bl_mtd.c", "${bl602_sdk_root}/components/sys/blota/bl_sys_ota_cli.c", + "${bl602_sdk_root}/components/utils/src/utils_hex.c", "${bl602_sdk_root}/components/utils/src/utils_hexdump.c", "${bl602_sdk_root}/components/utils/src/utils_sha256.c", "${chip_root}/third_party/mbedtls/repo/library/aes.c", @@ -557,6 +560,7 @@ template("bl602_sdk") { "${bl602_sdk_root}/components/utils/src/utils_rbtree.c", #rebase add + "${bl602_sdk_root}/components/network/rfparam_adapter_tmp/rftlv/phy_rftlv.c", "${bl602_sdk_root}/components/network/wifi_hosal/port/wifi_hosal_bl602.c", "${bl602_sdk_root}/components/network/wifi_hosal/wifi_hosal.c", "${bl602_sdk_root}/components/os/bl_os_adapter/bl_os_adapter/bl_os_hal.c", diff --git a/third_party/bouffalolab/bl602/portable/bfl_main.c b/third_party/bouffalolab/bl602/portable/bfl_main.c index 9bb2f4c9ed986f..48be367c1de810 100644 --- a/third_party/bouffalolab/bl602/portable/bfl_main.c +++ b/third_party/bouffalolab/bl602/portable/bfl_main.c @@ -35,7 +35,7 @@ #include #endif -HOSAL_UART_DEV_DECL(uart_stdio, 0, 16, 7, 115200); +HOSAL_UART_DEV_DECL(uart_stdio, 0, 16, 7, UART_BAUDRATE); extern uint8_t _heap_start; extern uint8_t _heap_size; // @suppress("Type cannot be resolved") diff --git a/third_party/bouffalolab/bl702/bl702_executable.gni b/third_party/bouffalolab/bl702/bl702_executable.gni index 7fa34fa759a46a..b18348f372613e 100644 --- a/third_party/bouffalolab/bl702/bl702_executable.gni +++ b/third_party/bouffalolab/bl702/bl702_executable.gni @@ -26,11 +26,9 @@ template("bl702_executable") { objcopy = "riscv64-unknown-elf-objcopy" if ("linux" == host_os) { - objcopy = - "../../${bouffalolab_toolchain}/Linux/bin/riscv64-unknown-elf-objcopy" + objcopy = "${bouffalolab_sdk_root}/toolchain/riscv/Linux/bin/riscv64-unknown-elf-objcopy" } else if ("mac" == host_os || "darwin" == host_os) { - objcopy = - "../../${bouffalolab_toolchain}/Darwin/bin/riscv64-unknown-elf-objcopy" + objcopy = "${bouffalolab_sdk_root}/toolchain/riscv/Darwin/bin/riscv64-unknown-elf-objcopy" } # Copy flashing dependencies to the output directory so that the output diff --git a/third_party/bouffalolab/repo b/third_party/bouffalolab/repo index dc526317d2903c..ae0622d85476ed 160000 --- a/third_party/bouffalolab/repo +++ b/third_party/bouffalolab/repo @@ -1 +1 @@ -Subproject commit dc526317d2903c4d3a8466226983ce34dc8f23d1 +Subproject commit ae0622d85476ed838ebc3efde9743c376bc9f96d