[McuMgr] Error : NOT_SUPPORTED during DFU by BLE with MCUBoot

Hi

I am currently to add DFU function on my custom device.

So I had McuBoot, and i would like to make the DFU by BLE.

I follow this link in order to do that https://github.com/hellesvik-nordic/samples_for_nrf_connect_sdk/tree/main/bootloader_samples/smp/mcuboot_smp_ble.

It's works well on my nrf5340dk, i also try to report the DFU on peripheral_lbs samples and still working.

But when i am trying to do the same thing on my custom board, i got this error [McuMgr] Error : NOT_SUPPORTED 

nRF Connect, 2023-10-10
KRepgt (CE:71:DC:F2:77:E6)
V	08:47:42.977	[McuMgr] Connecting...
D	08:47:42.981	[McuMgr] gatt = device.connectGatt(autoConnect = false, TRANSPORT_LE, LE 1M)
D	08:47:43.015	[McuMgr] [Callback] Connection state changed with status: 0 and new state: 2 (CONNECTED)
I	08:47:43.020	[McuMgr] Connected to CE:71:DC:F2:77:E6
D	08:47:43.026	[McuMgr] wait(300)
I	08:47:43.031	[McuMgr] MTU changed to: 498
V	08:47:43.332	[McuMgr] Discovering services...
D	08:47:43.337	[McuMgr] gatt.discoverServices()
I	08:47:43.342	[McuMgr] Services discovered
V	08:47:43.346	[McuMgr] Primary service found
D	08:47:43.614	[McuMgr] gatt.setCharacteristicNotification(da2e7828-fbce-4e01-ae9e-261174997c48, true)
V	08:47:43.622	[McuMgr] Enabling notifications for da2e7828-fbce-4e01-ae9e-261174997c48
D	08:47:43.632	[McuMgr] descriptor.setValue(0x01-00)
D	08:47:43.642	[McuMgr] gatt.writeDescriptor(00002902-0000-1000-8000-00805f9b34fb)
I	08:47:43.853	[McuMgr] Data written to descr. 00002902-0000-1000-8000-00805f9b34fb
I	08:47:43.862	[McuMgr] Notifications enabled
V	08:47:43.869	[McuMgr] Waiting for value change...
V	08:47:43.877	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
D	08:47:43.883	[McuMgr] characteristic.setValue(0x000000010000FF06A0)
D	08:47:43.890	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
D	08:47:43.896	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
I	08:47:43.974	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
I	08:47:44.108	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 01-00-00-19-00-00-FF-06-BF-68-62-75-66-5F-73-69-7A-65-19-09-AB-69-62-75-66-5F-63-6F-75-6E-74-04-FF
I	08:47:44.116	[McuMgr] Wait for value changed complete
A	08:47:44.128	[McuMgr] Received Header (Op: 1, Flags: 0, Len: 25, Group: 0, Seq: 255, Command: 6) CBOR {"buf_size":2475,"buf_count":4}
I	08:47:44.140	[McuMgr] SMP reassembly supported with buffer size: 2475 bytes and count: 4
A	08:47:44.147	[McuMgr] Sending (10 bytes) Header (Op: 0, Flags: 0, Len: 2, Group: 1, Seq: 0, Command: 0) CBOR {}
V	08:47:44.150	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
D	08:47:44.155	[McuMgr] characteristic.setValue(0x0000000200010000BFFF)
D	08:47:44.160	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
D	08:47:44.165	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
I	08:47:44.172	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
I	08:47:44.322	Connection parameters updated (interval: 11.25ms, latency: 0, timeout: 420ms)
I	08:47:44.367	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 01-00-00-F4-00-01-00-00-BF-66-69-6D-61-67-65-73-9F-BF-64-73-6C-6F-74-00-67-76-65-72-73-69-6F-6E-65-30-2E-30-2E-30-64-68-61-73-68-58-20-B8-B3-9B-09-96-2F-8B-32-C2-EA-EE-F8-78-8E-0D-E3-2B-16-95-60-8A-F8-D1-F6-6E-6A-43-11-5B-BE-21-2A-68-62-6F-6F-74-61-62-6C-65-F5-67-70-65-6E-64-69-6E-67-F4-69-63-6F-6E-66-69-72-6D-65-64-F5-66-61-63-74-69-76-65-F5-69-70-65-72-6D-61-6E-65-6E-74-F4-FF-BF-64-73-6C-6F-74-01-67-76-65-72-73-69-6F-6E-65-30-2E-30-2E-30-64-68-61-73-68-58-20-BC-1D-3D-F3-0F-1F-9B-C1-93-C2-59-CC-F4-86-D1-FD-75-31-F2-32-44-2B-AF-71-18-FE-4F-2D-34-44-0D-58-68-62-6F-6F-74-61-62-6C-65-F5-67-70-65-6E-64-69-6E-67-F5-69-63-6F-6E-66-69-72-6D-65-64-F4-66-61-63-74-69-76-65-F4-69-70-65-72-6D-61-6E-65-6E-74-F4-FF-FF-6B-73-70-6C-69-74-53-74-61-74-75-73-00-FF
I	08:47:44.377	[McuMgr] Connection parameters updated (interval: 11.25ms, latency: 0, timeout: 420ms)
A	08:47:44.390	[McuMgr] Received Header (Op: 1, Flags: 0, Len: 244, Group: 1, Seq: 0, Command: 0) CBOR {"images":[{"slot":0,"version":"0.0.0","hash":"uLObCZYvizLC6u74eI4N4ysWlWCK+NH2bmpDEVu+ISo=","bootable":true,"pending":false,"confirmed":true,"active":true,"permanent":false},{"slot":1,"version":"0.0.0","hash":"vB098w8fm8GTwlnM9IbR/XUx8jJEK69xGP5PLTREDVg=","bootable":true,"pending":true,"confirmed":false,"active":false,"permanent":false}],"splitStatus":0}
V	08:47:44.433	[McuMgr] Uploading firmware...
A	08:47:44.445	[McuMgr] Sending (10 bytes) Header (Op: 2, Flags: 0, Len: 2, Group: 63, Seq: 1, Command: 0) CBOR {}
V	08:47:44.650	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
D	08:47:44.657	[McuMgr] characteristic.setValue(0x02000002003F0100BFFF)
D	08:47:44.664	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
D	08:47:44.670	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
I	08:47:44.695	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
I	08:47:44.704	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 03-00-00-06-00-3F-01-00-BF-62-72-63-08-FF
A	08:47:44.715	[McuMgr] Received Header (Op: 3, Flags: 0, Len: 6, Group: 63, Seq: 1, Command: 0) CBOR {"rc":8}
W	08:47:44.723	[McuMgr] Error: NOT_SUPPORTED (8)
V	08:47:44.737	[McuMgr] New state: CONFIRM
A	08:47:45.001	[McuMgr] Sending (58 bytes) Header (Op: 2, Flags: 0, Len: 50, Group: 1, Seq: 2, Command: 0) CBOR {"confirm":true,"hash":"vB098w8fm8GTwlnM9IbR/XUx8jJEK69xGP5PLTREDVg="}
V	08:47:45.012	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
D	08:47:45.019	[McuMgr] characteristic.setValue(0x0200003200010200BF67636F6E6669726DF564686173685820BC1D3DF30F1F9BC193C259CCF486D1FD7531F232442BAF7118FE4F2D34440D58FF)
D	08:47:45.027	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
D	08:47:45.034	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
I	08:47:45.058	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
I	08:47:45.239	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 03-00-00-F4-00-01-02-00-BF-66-69-6D-61-67-65-73-9F-BF-64-73-6C-6F-74-00-67-76-65-72-73-69-6F-6E-65-30-2E-30-2E-30-64-68-61-73-68-58-20-B8-B3-9B-09-96-2F-8B-32-C2-EA-EE-F8-78-8E-0D-E3-2B-16-95-60-8A-F8-D1-F6-6E-6A-43-11-5B-BE-21-2A-68-62-6F-6F-74-61-62-6C-65-F5-67-70-65-6E-64-69-6E-67-F4-69-63-6F-6E-66-69-72-6D-65-64-F5-66-61-63-74-69-76-65-F5-69-70-65-72-6D-61-6E-65-6E-74-F4-FF-BF-64-73-6C-6F-74-01-67-76-65-72-73-69-6F-6E-65-30-2E-30-2E-30-64-68-61-73-68-58-20-BC-1D-3D-F3-0F-1F-9B-C1-93-C2-59-CC-F4-86-D1-FD-75-31-F2-32-44-2B-AF-71-18-FE-4F-2D-34-44-0D-58-68-62-6F-6F-74-61-62-6C-65-F5-67-70-65-6E-64-69-6E-67-F5-69-63-6F-6E-66-69-72-6D-65-64-F4-66-61-63-74-69-76-65-F4-69-70-65-72-6D-61-6E-65-6E-74-F4-FF-FF-6B-73-70-6C-69-74-53-74-61-74-75-73-00-FF
A	08:47:45.252	[McuMgr] Received Header (Op: 3, Flags: 0, Len: 244, Group: 1, Seq: 2, Command: 0) CBOR {"images":[{"slot":0,"version":"0.0.0","hash":"uLObCZYvizLC6u74eI4N4ysWlWCK+NH2bmpDEVu+ISo=","bootable":true,"pending":false,"confirmed":true,"active":true,"permanent":false},{"slot":1,"version":"0.0.0","hash":"vB098w8fm8GTwlnM9IbR/XUx8jJEK69xGP5PLTREDVg=","bootable":true,"pending":true,"confirmed":false,"active":false,"permanent":false}],"splitStatus":0}
V	08:47:45.322	[McuMgr] Disconnecting...
D	08:47:45.330	[McuMgr] gatt.disconnect()
D	08:47:45.591	[McuMgr] [Callback] Connection state changed with status: 0 and new state: 0 (DISCONNECTED)
I	08:47:45.600	[McuMgr] Disconnected
D	08:47:45.609	[McuMgr] gatt.close()
I	08:47:50.201	Connection parameters updated (interval: 40.0ms, latency: 0, timeout: 420ms)
V	08:54:07.656	Disconnecting...
D	08:54:07.656	gatt.disconnect()
D	08:54:07.687	[Callback] Connection state changed with status: 0 and new state: DISCONNECTED (0)
I	08:54:07.687	Disconnected
D	08:54:08.702	[Broadcast] Action received: android.bluetooth.device.action.ACL_DISCONNECTED

See my prj.conf

# nothing here
CONFIG_RTT_CONSOLE=y

CONFIG_I2C=y
CONFIG_GPIO=y

CONFIG_NEWLIB_LIBC=y

# BLE definition 
CONFIG_BT=y
CONFIG_BT_CENTRAL=y
CONFIG_BT_GATT_CLIENT=y
CONFIG_BT_GATT_DM=y

CONFIG_BT_PERIPHERAL=y
CONFIG_BT_MAX_CONN=1
CONFIG_BT_L2CAP_TX_BUF_COUNT=5
CONFIG_BT_DEVICE_NAME="KRepet"
CONFIG_BT_DEVICE_APPEARANCE=962

CONFIG_HEAP_MEM_POOL_SIZE=2048

CONFIG_BT_SCAN=y
CONFIG_BT_SCAN_UUID_CNT=8

CONFIG_MPSL=y
CONFIG_MPSL_FEM=y
CONFIG_MPSL_FEM_SIMPLE_GPIO=y

# Ensure an MCUboot-compatible binary is generated.
CONFIG_BOOTLOADER_MCUBOOT=y

CONFIG_SECURE_BOOT=n

# Enable SMP Server
CONFIG_MCUMGR=y
CONFIG_MCUMGR_GRP_IMG=y

# CONFIG_MCUMGR_GRP_IMG dependencies
CONFIG_FLASH=y
CONFIG_IMG_MANAGER=y

# CONFIG_IMG_MANAGER dependencies
CONFIG_STREAM_FLASH=y

# CONFIG_MCUMGR dependencies
CONFIG_NET_BUF=y
CONFIG_ZCBOR=y

# Required for CONFIG_IMG_MANAGER
CONFIG_FLASH_MAP=y

# Enable BLE transfer
CONFIG_NCS_SAMPLE_MCUMGR_BT_OTA_DFU=y

CONFIG_NCS_SAMPLE_MCUMGR_BT_OTA_DFU_SPEEDUP=y

CONFIG_SYSTEM_WORKQUEUE_STACK_SIZE=4096

I am not using an external flash to do the DFU.

My environment are

-IDE : Visual Studio Code

-Zephyr: V2.4.1

-OS: Windows

-custom Board: nrf52833

Thanks,

Best Regards,

Julien

Parents
  • Hi Julien,

    A couple of questions here to start with as an attempt to narrow down what could be wrong

    1. In your previous case you mention that you're testing with a nRF5340DK. Have you at any point tested and verified that you're able to add DFU support to a non-custom nRF52 based board such as the nRF52840DK?
    2. You're mentioning 'Zephyr v2.4.1'. Could you clarify if you're referring to 'nRF Connect SDK v2.4.1' or if you're actually using a pure Zephyr environment? 
    3. Are you able to compile, flash and run any other non-DFU based samples from the SDK to your custom board?
    4. Do you get any warnings when compiling?
    5. Are you able to add DFU to your custom board using other transports than BLE? For instance using the UART sample instead? github.com/.../mcuboot_smp_uart

    Kind regards,
    Andreas

  • Hi AHaug,

    1. Currently my only board are nrf5340, i could test on other board tomorrow

    2. Apologize, it is nRF Connect SDK v2.4.1

    3. I have not try, but i'm able to communicate with i2c, enable bluetooth and connect to it or connect to other device

    4. No warning

    5. I have no uart available on my custom board

    What meaning the error code 8 on McuMgr?

    Regards,

  • Noted, thank you for clarifying!

    Julien said:
    What meaning the error code 8 on McuMgr?

    Based on what I see it is related to something that you receive that is not supported, my best current guess is that it's regarding reading the notification that you receive prior to the error message.

    After examining the project configuration from https://github.com/zephyrproject-rtos/zephyr/blob/main/samples/subsys/mgmt/mcumgr/smp_svr/prj.conf and it's BLE overlay file https://github.com/zephyrproject-rtos/zephyr/blob/main/samples/subsys/mgmt/mcumgr/smp_svr/overlay-bt.conf with your configuration it looks like you've not included the following two configurations from the Zephyr smp_server sample. Does enabling these two change anything on your end?


    CONFIG_MCUMGR_GRP_OS=y
    CONFIG_MCUMGR_GRP_STAT=y

    Kind regards,
    Andreas

  • Hi

    Trying to add

    CONFIG_MCUMGR_GRP_OS=y
    CONFIG_MCUMGR_GRP_STAT=y (need to add CONFIG_STATS=y because of depencies)

    But still got the same issue.

    nRF Connect, 2023-10-10
    KRepet (CE:71:DC:F2:77:E6)
    V	16:20:29.359	[McuMgr] Connecting...
    D	16:20:29.362	[McuMgr] gatt = device.connectGatt(autoConnect = false, TRANSPORT_LE, LE 1M)
    D	16:20:29.387	[McuMgr] [Callback] Connection state changed with status: 0 and new state: 2 (CONNECTED)
    I	16:20:29.390	[McuMgr] Connected to CE:71:DC:F2:77:E6
    D	16:20:29.396	[McuMgr] wait(300)
    V	16:20:29.700	[McuMgr] Discovering services...
    D	16:20:29.705	[McuMgr] gatt.discoverServices()
    I	16:20:29.712	[McuMgr] Services discovered
    V	16:20:29.907	[McuMgr] Primary service found
    V	16:20:29.914	[McuMgr] Requesting new MTU...
    D	16:20:29.920	[McuMgr] gatt.requestMtu(498)
    I	16:20:30.145	[McuMgr] MTU changed to: 498
    D	16:20:30.149	[McuMgr] gatt.setCharacteristicNotification(da2e7828-fbce-4e01-ae9e-261174997c48, true)
    V	16:20:30.155	[McuMgr] Enabling notifications for da2e7828-fbce-4e01-ae9e-261174997c48
    D	16:20:30.161	[McuMgr] descriptor.setValue(0x01-00)
    D	16:20:30.167	[McuMgr] gatt.writeDescriptor(00002902-0000-1000-8000-00805f9b34fb)
    I	16:20:30.368	[McuMgr] Data written to descr. 00002902-0000-1000-8000-00805f9b34fb
    I	16:20:30.374	[McuMgr] Notifications enabled
    V	16:20:30.378	[McuMgr] Waiting for value change...
    V	16:20:30.382	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
    D	16:20:30.384	[McuMgr] characteristic.setValue(0x000000010000FF06A0)
    D	16:20:30.388	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
    D	16:20:30.391	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
    I	16:20:30.473	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
    I	16:20:30.722	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 01-00-00-19-00-00-FF-06-BF-68-62-75-66-5F-73-69-7A-65-19-09-AB-69-62-75-66-5F-63-6F-75-6E-74-04-FF
    I	16:20:30.732	[McuMgr] Wait for value changed complete
    A	16:20:30.743	[McuMgr] Received Header (Op: 1, Flags: 0, Len: 25, Group: 0, Seq: 255, Command: 6) CBOR {"buf_size":2475,"buf_count":4}
    I	16:20:30.755	[McuMgr] SMP reassembly supported with buffer size: 2475 bytes and count: 4
    A	16:20:30.765	[McuMgr] Sending (10 bytes) Header (Op: 0, Flags: 0, Len: 2, Group: 1, Seq: 0, Command: 0) CBOR {}
    V	16:20:30.773	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
    D	16:20:30.781	[McuMgr] characteristic.setValue(0x0000000200010000BFFF)
    D	16:20:30.788	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
    D	16:20:30.795	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
    I	16:20:30.802	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
    I	16:20:30.840	Connection parameters updated (interval: 11.25ms, latency: 0, timeout: 420ms)
    I	16:20:31.021	[McuMgr] Connection parameters updated (interval: 11.25ms, latency: 0, timeout: 420ms)
    I	16:20:31.030	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 01-00-00-F4-00-01-00-00-BF-66-69-6D-61-67-65-73-9F-BF-64-73-6C-6F-74-00-67-76-65-72-73-69-6F-6E-65-30-2E-30-2E-30-64-68-61-73-68-58-20-5C-47-E3-BB-FC-42-41-8C-74-EA-7C-88-10-F2-7A-62-D8-1E-CC-9C-9D-5E-3F-33-3F-0B-A1-19-55-6A-E3-AC-68-62-6F-6F-74-61-62-6C-65-F5-67-70-65-6E-64-69-6E-67-F4-69-63-6F-6E-66-69-72-6D-65-64-F5-66-61-63-74-69-76-65-F5-69-70-65-72-6D-61-6E-65-6E-74-F4-FF-BF-64-73-6C-6F-74-01-67-76-65-72-73-69-6F-6E-65-30-2E-30-2E-30-64-68-61-73-68-58-20-C6-4B-31-F7-65-C6-AE-A5-F8-6B-03-4F-DF-78-73-E5-A9-32-A8-E8-CA-56-78-6C-78-AE-B5-B4-80-43-AD-AF-68-62-6F-6F-74-61-62-6C-65-F5-67-70-65-6E-64-69-6E-67-F5-69-63-6F-6E-66-69-72-6D-65-64-F4-66-61-63-74-69-76-65-F4-69-70-65-72-6D-61-6E-65-6E-74-F4-FF-FF-6B-73-70-6C-69-74-53-74-61-74-75-73-00-FF
    A	16:20:31.042	[McuMgr] Received Header (Op: 1, Flags: 0, Len: 244, Group: 1, Seq: 0, Command: 0) CBOR {"images":[{"slot":0,"version":"0.0.0","hash":"XEfju/xCQYx06nyIEPJ6YtgezJydXj8zPwuhGVVq46w=","bootable":true,"pending":false,"confirmed":true,"active":true,"permanent":false},{"slot":1,"version":"0.0.0","hash":"xksx92XGrqX4awNP33hz5akyqOjKVnhseK61tIBDra8=","bootable":true,"pending":true,"confirmed":false,"active":false,"permanent":false}],"splitStatus":0}
    V	16:20:31.130	[McuMgr] Uploading firmware...
    A	16:20:31.364	[McuMgr] Sending (10 bytes) Header (Op: 2, Flags: 0, Len: 2, Group: 63, Seq: 1, Command: 0) CBOR {}
    V	16:20:31.373	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
    D	16:20:31.382	[McuMgr] characteristic.setValue(0x02000002003F0100BFFF)
    D	16:20:31.390	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
    D	16:20:31.398	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
    I	16:20:31.426	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
    I	16:20:31.437	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 03-00-00-06-00-3F-01-00-BF-62-72-63-08-FF
    A	16:20:31.445	[McuMgr] Received Header (Op: 3, Flags: 0, Len: 6, Group: 63, Seq: 1, Command: 0) CBOR {"rc":8}
    W	16:20:31.450	[McuMgr] Error: NOT_SUPPORTED (8)
    V	16:20:31.466	[McuMgr] New state: RESET
    A	16:20:31.816	[McuMgr] Sending (10 bytes) Header (Op: 2, Flags: 0, Len: 2, Group: 0, Seq: 2, Command: 5) CBOR {}
    V	16:20:31.826	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
    D	16:20:31.835	[McuMgr] characteristic.setValue(0x0200000200000205BFFF)
    D	16:20:31.843	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
    D	16:20:31.852	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
    I	16:20:31.880	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
    I	16:20:31.889	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 03-00-00-02-00-00-02-05-BF-FF
    A	16:20:31.899	[McuMgr] Received Header (Op: 3, Flags: 0, Len: 2, Group: 0, Seq: 2, Command: 5) CBOR {}
    D	16:20:32.555	[Callback] Connection state changed with status: 8 and new state: DISCONNECTED (0)
    E	16:20:32.555	Error 8 (0x8): GATT CONN TIMEOUT
    I	16:20:32.555	Disconnected
    D	16:20:32.592	[McuMgr] [Callback] Connection state changed with status: 8 and new state: 0 (DISCONNECTED)
    W	16:20:32.604	[McuMgr] Error: (0x8): GATT CONN TIMEOUT
    I	16:20:32.611	[McuMgr] Disconnected
    D	16:20:32.621	[McuMgr] gatt.close()
    D	16:20:32.627	[Broadcast] Action received: android.bluetooth.device.action.ACL_DISCONNECTED
    V	16:20:41.924	[McuMgr] Connecting...
    D	16:20:41.933	[McuMgr] gatt = device.connectGatt(autoConnect = false, TRANSPORT_LE, LE 1M)
    V	16:20:41.946	[McuMgr] New state: CONFIRM
    

    Regards,

    Julien

Reply
  • Hi

    Trying to add

    CONFIG_MCUMGR_GRP_OS=y
    CONFIG_MCUMGR_GRP_STAT=y (need to add CONFIG_STATS=y because of depencies)

    But still got the same issue.

    nRF Connect, 2023-10-10
    KRepet (CE:71:DC:F2:77:E6)
    V	16:20:29.359	[McuMgr] Connecting...
    D	16:20:29.362	[McuMgr] gatt = device.connectGatt(autoConnect = false, TRANSPORT_LE, LE 1M)
    D	16:20:29.387	[McuMgr] [Callback] Connection state changed with status: 0 and new state: 2 (CONNECTED)
    I	16:20:29.390	[McuMgr] Connected to CE:71:DC:F2:77:E6
    D	16:20:29.396	[McuMgr] wait(300)
    V	16:20:29.700	[McuMgr] Discovering services...
    D	16:20:29.705	[McuMgr] gatt.discoverServices()
    I	16:20:29.712	[McuMgr] Services discovered
    V	16:20:29.907	[McuMgr] Primary service found
    V	16:20:29.914	[McuMgr] Requesting new MTU...
    D	16:20:29.920	[McuMgr] gatt.requestMtu(498)
    I	16:20:30.145	[McuMgr] MTU changed to: 498
    D	16:20:30.149	[McuMgr] gatt.setCharacteristicNotification(da2e7828-fbce-4e01-ae9e-261174997c48, true)
    V	16:20:30.155	[McuMgr] Enabling notifications for da2e7828-fbce-4e01-ae9e-261174997c48
    D	16:20:30.161	[McuMgr] descriptor.setValue(0x01-00)
    D	16:20:30.167	[McuMgr] gatt.writeDescriptor(00002902-0000-1000-8000-00805f9b34fb)
    I	16:20:30.368	[McuMgr] Data written to descr. 00002902-0000-1000-8000-00805f9b34fb
    I	16:20:30.374	[McuMgr] Notifications enabled
    V	16:20:30.378	[McuMgr] Waiting for value change...
    V	16:20:30.382	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
    D	16:20:30.384	[McuMgr] characteristic.setValue(0x000000010000FF06A0)
    D	16:20:30.388	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
    D	16:20:30.391	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
    I	16:20:30.473	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
    I	16:20:30.722	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 01-00-00-19-00-00-FF-06-BF-68-62-75-66-5F-73-69-7A-65-19-09-AB-69-62-75-66-5F-63-6F-75-6E-74-04-FF
    I	16:20:30.732	[McuMgr] Wait for value changed complete
    A	16:20:30.743	[McuMgr] Received Header (Op: 1, Flags: 0, Len: 25, Group: 0, Seq: 255, Command: 6) CBOR {"buf_size":2475,"buf_count":4}
    I	16:20:30.755	[McuMgr] SMP reassembly supported with buffer size: 2475 bytes and count: 4
    A	16:20:30.765	[McuMgr] Sending (10 bytes) Header (Op: 0, Flags: 0, Len: 2, Group: 1, Seq: 0, Command: 0) CBOR {}
    V	16:20:30.773	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
    D	16:20:30.781	[McuMgr] characteristic.setValue(0x0000000200010000BFFF)
    D	16:20:30.788	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
    D	16:20:30.795	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
    I	16:20:30.802	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
    I	16:20:30.840	Connection parameters updated (interval: 11.25ms, latency: 0, timeout: 420ms)
    I	16:20:31.021	[McuMgr] Connection parameters updated (interval: 11.25ms, latency: 0, timeout: 420ms)
    I	16:20:31.030	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 01-00-00-F4-00-01-00-00-BF-66-69-6D-61-67-65-73-9F-BF-64-73-6C-6F-74-00-67-76-65-72-73-69-6F-6E-65-30-2E-30-2E-30-64-68-61-73-68-58-20-5C-47-E3-BB-FC-42-41-8C-74-EA-7C-88-10-F2-7A-62-D8-1E-CC-9C-9D-5E-3F-33-3F-0B-A1-19-55-6A-E3-AC-68-62-6F-6F-74-61-62-6C-65-F5-67-70-65-6E-64-69-6E-67-F4-69-63-6F-6E-66-69-72-6D-65-64-F5-66-61-63-74-69-76-65-F5-69-70-65-72-6D-61-6E-65-6E-74-F4-FF-BF-64-73-6C-6F-74-01-67-76-65-72-73-69-6F-6E-65-30-2E-30-2E-30-64-68-61-73-68-58-20-C6-4B-31-F7-65-C6-AE-A5-F8-6B-03-4F-DF-78-73-E5-A9-32-A8-E8-CA-56-78-6C-78-AE-B5-B4-80-43-AD-AF-68-62-6F-6F-74-61-62-6C-65-F5-67-70-65-6E-64-69-6E-67-F5-69-63-6F-6E-66-69-72-6D-65-64-F4-66-61-63-74-69-76-65-F4-69-70-65-72-6D-61-6E-65-6E-74-F4-FF-FF-6B-73-70-6C-69-74-53-74-61-74-75-73-00-FF
    A	16:20:31.042	[McuMgr] Received Header (Op: 1, Flags: 0, Len: 244, Group: 1, Seq: 0, Command: 0) CBOR {"images":[{"slot":0,"version":"0.0.0","hash":"XEfju/xCQYx06nyIEPJ6YtgezJydXj8zPwuhGVVq46w=","bootable":true,"pending":false,"confirmed":true,"active":true,"permanent":false},{"slot":1,"version":"0.0.0","hash":"xksx92XGrqX4awNP33hz5akyqOjKVnhseK61tIBDra8=","bootable":true,"pending":true,"confirmed":false,"active":false,"permanent":false}],"splitStatus":0}
    V	16:20:31.130	[McuMgr] Uploading firmware...
    A	16:20:31.364	[McuMgr] Sending (10 bytes) Header (Op: 2, Flags: 0, Len: 2, Group: 63, Seq: 1, Command: 0) CBOR {}
    V	16:20:31.373	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
    D	16:20:31.382	[McuMgr] characteristic.setValue(0x02000002003F0100BFFF)
    D	16:20:31.390	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
    D	16:20:31.398	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
    I	16:20:31.426	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
    I	16:20:31.437	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 03-00-00-06-00-3F-01-00-BF-62-72-63-08-FF
    A	16:20:31.445	[McuMgr] Received Header (Op: 3, Flags: 0, Len: 6, Group: 63, Seq: 1, Command: 0) CBOR {"rc":8}
    W	16:20:31.450	[McuMgr] Error: NOT_SUPPORTED (8)
    V	16:20:31.466	[McuMgr] New state: RESET
    A	16:20:31.816	[McuMgr] Sending (10 bytes) Header (Op: 2, Flags: 0, Len: 2, Group: 0, Seq: 2, Command: 5) CBOR {}
    V	16:20:31.826	[McuMgr] Writing characteristic da2e7828-fbce-4e01-ae9e-261174997c48 (WRITE COMMAND)
    D	16:20:31.835	[McuMgr] characteristic.setValue(0x0200000200000205BFFF)
    D	16:20:31.843	[McuMgr] characteristic.setWriteType(WRITE COMMAND)
    D	16:20:31.852	[McuMgr] gatt.writeCharacteristic(da2e7828-fbce-4e01-ae9e-261174997c48)
    I	16:20:31.880	[McuMgr] Data written to da2e7828-fbce-4e01-ae9e-261174997c48
    I	16:20:31.889	[McuMgr] Notification received from da2e7828-fbce-4e01-ae9e-261174997c48, value: (0x) 03-00-00-02-00-00-02-05-BF-FF
    A	16:20:31.899	[McuMgr] Received Header (Op: 3, Flags: 0, Len: 2, Group: 0, Seq: 2, Command: 5) CBOR {}
    D	16:20:32.555	[Callback] Connection state changed with status: 8 and new state: DISCONNECTED (0)
    E	16:20:32.555	Error 8 (0x8): GATT CONN TIMEOUT
    I	16:20:32.555	Disconnected
    D	16:20:32.592	[McuMgr] [Callback] Connection state changed with status: 8 and new state: 0 (DISCONNECTED)
    W	16:20:32.604	[McuMgr] Error: (0x8): GATT CONN TIMEOUT
    I	16:20:32.611	[McuMgr] Disconnected
    D	16:20:32.621	[McuMgr] gatt.close()
    D	16:20:32.627	[Broadcast] Action received: android.bluetooth.device.action.ACL_DISCONNECTED
    V	16:20:41.924	[McuMgr] Connecting...
    D	16:20:41.933	[McuMgr] gatt = device.connectGatt(autoConnect = false, TRANSPORT_LE, LE 1M)
    V	16:20:41.946	[McuMgr] New state: CONFIRM
    

    Regards,

    Julien

Children
Related