From 98983451269fcabea12ab8f80667da6f70daf362 Mon Sep 17 00:00:00 2001 From: pankore <86098180+pankore@users.noreply.github.com> Date: Fri, 4 Nov 2022 21:39:41 +0800 Subject: [PATCH] use docker image 0.6.03 and change BLE notification to indication (#23494) --- .github/workflows/examples-ameba.yaml | 12 ++++++++++-- .../docker/images/chip-build-ameba/Dockerfile | 2 +- integrations/docker/images/chip-build/version | 2 +- src/platform/Ameba/BLEManagerImpl.cpp | 6 +++--- 4 files changed, 15 insertions(+), 7 deletions(-) diff --git a/.github/workflows/examples-ameba.yaml b/.github/workflows/examples-ameba.yaml index 15e193eb5be452..dfeaaeb8189e93 100644 --- a/.github/workflows/examples-ameba.yaml +++ b/.github/workflows/examples-ameba.yaml @@ -32,7 +32,7 @@ jobs: if: github.actor != 'restyled-io[bot]' container: - image: connectedhomeip/chip-build-ameba:0.5.99 + image: connectedhomeip/chip-build-ameba:0.6.03 options: --user root steps: @@ -47,4 +47,12 @@ jobs: - name: Checkout submodules run: scripts/checkout_submodules.py --shallow --platform ameba - name: Build example Ameba All Clusters App - run: scripts/run_in_build_env.sh "./scripts/build/build_examples.py --target-glob 'ameba-*' build" + run: | + ./scripts/run_in_build_env.sh \ + "./scripts/build/build_examples.py \ + --target ameba-amebad-all-clusters \ + --target ameba-amebad-all-clusters-minimal \ + --target ameba-amebad-light \ + --target ameba-amebad-pigweed \ + build \ + " diff --git a/integrations/docker/images/chip-build-ameba/Dockerfile b/integrations/docker/images/chip-build-ameba/Dockerfile index c8307ae64986f8..3d3b055e820887 100644 --- a/integrations/docker/images/chip-build-ameba/Dockerfile +++ b/integrations/docker/images/chip-build-ameba/Dockerfile @@ -3,7 +3,7 @@ FROM connectedhomeip/chip-build:${VERSION} # Setup Ameba ARG AMEBA_DIR=/opt/ameba -ARG TAG_NAME=ameba_update_2022_07_25 +ARG TAG_NAME=ameba_update_2022_10_03 RUN set -x \ && apt-get update \ && mkdir ${AMEBA_DIR} \ diff --git a/integrations/docker/images/chip-build/version b/integrations/docker/images/chip-build/version index 2c7460f1cae50b..b288fd5e8ac786 100644 --- a/integrations/docker/images/chip-build/version +++ b/integrations/docker/images/chip-build/version @@ -1 +1 @@ -0.5.99 Version bump reason: fix IMX SDK root in vscode dockerfile +0.6.03 Version bump reason: [Ameba] Replace C2 notify with indicate as required by Matter spec diff --git a/src/platform/Ameba/BLEManagerImpl.cpp b/src/platform/Ameba/BLEManagerImpl.cpp index 550be5f78352ad..35dd0a962051ed 100644 --- a/src/platform/Ameba/BLEManagerImpl.cpp +++ b/src/platform/Ameba/BLEManagerImpl.cpp @@ -567,8 +567,8 @@ bool BLEManagerImpl::SendIndication(BLE_CONNECTION_OBJECT conId, const ChipBleUU CHIP_ERROR err = CHIP_NO_ERROR; VerifyOrExit(IsSubscribed(conId), err = CHIP_ERROR_INVALID_ARGUMENT); - server_send_data(conId, bt_matter_adapter_service_id, BT_MATTER_ADAPTER_SERVICE_CHAR_NOTIFY_CCCD_INDEX - 1, data->Start(), - data->DataLength(), GATT_PDU_TYPE_NOTIFICATION); + server_send_data(conId, bt_matter_adapter_service_id, BT_MATTER_ADAPTER_SERVICE_CHAR_INDICATE_CCCD_INDEX - 1, data->Start(), + data->DataLength(), GATT_PDU_TYPE_INDICATION); exit: if (err != CHIP_NO_ERROR) @@ -922,7 +922,7 @@ CHIP_ERROR BLEManagerImpl::gatt_svr_chr_access(void * param, T_SERVER_ID service switch (pp_data->msg_data.notification_indification_index) { case SIMP_NOTIFY_INDICATE_V3_ENABLE: { - sInstance.HandleTXCharCCCDWrite(conn_id, 0, 1); + sInstance.HandleTXCharCCCDWrite(conn_id, 1, 0); } break;