BLE FOTA example for Central device

Hi,

Is there any example of a Central device which is able to connect to a peripheral and update it ? Im guessing the bluetooth_central_dfu_smp sample is probably the closest one to what I want.

Thank you!

Parents Reply
  • Miguel Ferreira said:
    How did you find the zcbor package format to send ? It was based on this doc https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/services/device_mgmt/smp_groups/smp_group_1.html

    Honestly, it was my colleague who did most of the zcbor decoding, and he is out of office.

    But yes, the docs you link do is a good place to look.
    Also have a look how the official SMP Client example does things I guess?

    Some official work is being done on a SMP Client, but it is not done yet. See https://github.com/zephyrproject-rtos/zephyr/pull/56934.
    Maybe you can get some hints on how to work with zcbor from how it is done in the PR?

    Miguel Ferreira said:
    Im getting no errors on bt_dfu_smp_command, but it enters in the if conditional anyway:  "bt_dfu_smp_command failed with 0" Did you have something like this during your tests ?

    It is a little while since I tested this last, but I can not remember this specific error.

    Which version of the nRF Connect SDK do you use?
    Which board?

    If you give these, I can try to see if I get the same.

    It is odd that it fails with 0 though, as it is if(err). Which line is this on?

    Miguel Ferreira said:
    Final question, the above says it fails but the command seems to run because I have the following reply: Error in image upload response: 3.

    From SMP Error codes, 3 = "Invalid value; a request contains an invalid value."

    If I had to guess I would say you had either formatted zcbor  wrong, or put some wrong data in the request or header.

    Regards,
    Sigurd Hellesvik

Children
Related