Skip to content

Commit

Permalink
samples: common: mcumgr_bt_ota_dfu: add suit support
Browse files Browse the repository at this point in the history
Added the SUIT support to the MCUmgr Bluetooth DFU Kconfig helper.

Ref: NCSDK-30339

Signed-off-by: Kamil Piszczek <[email protected]>
  • Loading branch information
kapi-no authored and jukkar committed Dec 18, 2024
1 parent 8ce46e3 commit d677123
Showing 1 changed file with 30 additions and 20 deletions.
50 changes: 30 additions & 20 deletions samples/common/mcumgr_bt_ota_dfu/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -4,39 +4,52 @@
# SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
#

DT_CHOSEN_EXT_FLASH:= nordic,pm-ext-flash

config NCS_SAMPLE_MCUMGR_BT_OTA_DFU
bool "MCUmgr OTA DFU over Bluetooth"
select CRC
select FLASH
select FLASH_MAP
select MCUMGR
select MCUMGR_TRANSPORT_BT
select NET_BUF
select ZCBOR
select CRC
select MCUMGR_TRANSPORT_BT
imply MCUMGR_TRANSPORT_BT_CONN_PARAM_CONTROL
imply IMG_MANAGER
imply STREAM_FLASH
imply FLASH_MAP
imply FLASH
imply MCUMGR_GRP_IMG
imply MCUMGR_GRP_OS
imply MCUMGR_GRP_OS_BOOTLOADER_INFO
imply MCUMGR_TRANSPORT_BT_CONN_PARAM_CONTROL
imply MCUMGR_TRANSPORT_BT_REASSEMBLY
imply NCS_SAMPLE_MCUMGR_BT_OTA_DFU_SPEEDUP
depends on BT_PERIPHERAL
depends on BOOTLOADER_MCUBOOT
depends on BOOTLOADER_MCUBOOT || SUIT
help
Enable this option to include MCUmgr in the build which will enable
the Bluetooth transport and image management group, which allows
for firmware over the air update support of the device.

if NCS_SAMPLE_MCUMGR_BT_OTA_DFU

config NCS_SAMPLE_MCUMGR_BT_OTA_DFU_MCUBOOT_DIRECT_XIP_SUPPORT
config NCS_SAMPLE_MCUMGR_BT_OTA_DFU_BACKEND_MCUBOOT
bool
default y if MCUBOOT_BOOTLOADER_MODE_DIRECT_XIP
default y if MCUBOOT_BOOTLOADER_MODE_DIRECT_XIP_WITH_REVERT
imply MCUMGR_GRP_IMG_REJECT_DIRECT_XIP_MISMATCHED_SLOT
default y
select IMG_MANAGER
select MCUMGR_GRP_IMG
select STREAM_FLASH
imply MCUMGR_GRP_IMG_REJECT_DIRECT_XIP_MISMATCHED_SLOT if \
MCUBOOT_BOOTLOADER_MODE_DIRECT_XIP || MCUBOOT_BOOTLOADER_MODE_DIRECT_XIP_WITH_REVERT
depends on BOOTLOADER_MCUBOOT
help
This option enables the necessary configuration for the MCUboot-based DFU.

config NCS_SAMPLE_MCUMGR_BT_OTA_DFU_BACKEND_SUIT
bool
default y
select MCUMGR_SMP_LEGACY_RC_BEHAVIOUR
select MGMT_SUITFU
select MGMT_SUITFU_GRP_SUIT
select SSF_SUIT_SERVICE_ENABLED
select ZCBOR_CANONICAL
depends on SUIT
help
This option enables the necessary configuration for the SUIT-based DFU.

choice MCUMGR_TRANSPORT_BT_PERM
default MCUMGR_TRANSPORT_BT_PERM_RW
Expand All @@ -55,18 +68,15 @@ config MCUMGR_GRP_OS_MCUMGR_PARAMS

endif # MCUMGR_TRANSPORT_BT_REASSEMBLY

if (SETTINGS_FCB || SETTINGS_NVS)

# Enable support for the storage erase operation only when the storage
# partition is created by the Partition Manager.
if (SETTINGS_FCB || SETTINGS_NVS || SETTINGS_ZMS)

config MCUMGR_GRP_ZBASIC
default y

config MCUMGR_GRP_ZBASIC_STORAGE_ERASE
default y

endif # (SETTINGS_FCB || SETTINGS_NVS)
endif # (SETTINGS_FCB || SETTINGS_NVS || SETTINGS_ZMS)

if NORDIC_QSPI_NOR

Expand Down

0 comments on commit d677123

Please sign in to comment.