This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nrf52833 ble dfu how to start?

Hi ,

I need to start my application using sdk5 16.0 version, which should have custom ble servivnced and dfu feature.

After getting some trouble with zephyr os, i decided to test with sdk5. 

But it seems that nrf52833DK is not totally supported in all example. i wanted to start from dfu example and then integrate hrs example. Is it the good way to go ? 

Or may be the best is to start with hrs nfc paring ? but then how to integrate dfu. In the doc of how to integrate dfu, it is not for s113 ... 

I tried to migrate blinky ble from s112 10040e to s113 , i update ll the field but i finnaly get some linking .init errors with UNPLACED label.

I have the the feeling that zephyr or sdk5, nothing is really ready for nrf52833...

But i keep c9nfident, it is not like o wanted to do something ompossible, just  question of tile and good practice i guess.

thanks a lot for your help !

Parents
  • Hi,

    nRF5 SDK version 16 is probably the best SDK for nRF52833 unless you have a particular reason for using nRF Connect SDK. It is correct that many examples are not adapted to it, but adjusting an existing example takes just a few minutes once you know what is needed.

    For reference, I started off with the BLE bliky example for nRF52840 in SDK 16, for SES (\examples\ble_peripheral\ble_app_blinky\pca10059\s140\ses\ble_app_blinky_pca10059_s140.emProject).

    1. Adjust the linker configuration macros to be correct for the flash and RAM size of the nRF52833, and the reduced size of the S113 SoftDevice:

    2. Adjust the preprocessor defines to specify the correct board, IC and SoftDevice:

    3. Adjust the include path to include S113 headers instead of S140 headers:

    4. Make SES load the correct S113 SoftDevice when programming from SES:

  • Also, should i use secure_bootloader_dfu + ble_app_buttonless application to have a complete dfu solution ? i  have flashed secure_bootloader_dfu i can see it with nrf toolbox. But there is no while(1) loop so i guess it is not a software where to place custom ble services ans application ? I f you can clarify with big pictur point of view it will help a lot :) . thanks a lot !

Reply
  • Also, should i use secure_bootloader_dfu + ble_app_buttonless application to have a complete dfu solution ? i  have flashed secure_bootloader_dfu i can see it with nrf toolbox. But there is no while(1) loop so i guess it is not a software where to place custom ble services ans application ? I f you can clarify with big pictur point of view it will help a lot :) . thanks a lot !

Children
  • Hi,

    Olfox said:
    Also, should i use secure_bootloader_dfu + ble_app_buttonless application to have a complete dfu solution ?

    That depends on your requirements. If you want to use for instance a button to enter DFU mode, then you don't need to do anything in the application. But if you want to be able to enter DFU mode without any physical interaction with the device, then you must include the DFU service (which ble_app_buttonless application is an example of).

    Olfox said:
    have flashed secure_bootloader_dfu i can see it with nrf toolbox. But there is no while(1) loop so i guess it is not a software where to place custom ble services ans application ? I f you can clarify with big pictur point of view it will help a lot :)

    The bootloader is responsible for updates, including transporting the update over BLE (or other). But it will normally just start the application, which is a separate binary. You should not put your application logic, services etc. in the bootloader.

  • Thanks a lot for all this explaination. My product will not be reachable ( so no button possibility). so if i understand well i just need to configure properly with additional file 0 the softDist, and use ble_app_buttonless in wich i place my custom services. No need of secure boot ( that is already inside ble_app_buttonless )?

    Theoreticaly, 0x20001198 should be enough, but i see there is also a callstack that required 1.75kB ( 0x700) that i should add too ?

    Then it should be like this

    FLASH_PH_START=0x0

    FLASH_PH_SIZE=0x80000

    RAM_PH_START=0x20000000

    RAM_PH_SIZE=0x20000

    FLASH_START=0x1c000

    FLASH_SIZE=0x64000

    RAM_START=0x20001898

    RAM_SIZE=0x1e768

    This should be the minimum required ?

    Here is my project ( just placed here : C:\nordic\nRF5SDK160098a08e2\examples\ble_peripheral\ble_app_buttonless_dfu\pca10100\s113\ses )

    pca10100.zip

  • Hi,

    I have uploaded a working project here: pca10100_fixed.zip. I forgot that you need to replace the startup and system files as shown here:

    With that, it should work.

     

    Olfox said:
    Thanks a lot for all this explaination. My product will not be reachable ( so no button possibility). so if i understand well i just need to configure properly with additional file 0 the softDist, and use ble_app_buttonless in wich i place my custom services. No need of secure boot ( that is already inside ble_app_buttonless )?

    Yes, from the application perspective that is enough. But you of course also need to include the bootloader itself, by using the Secure BLE bootloader example. "Secure" here does not imply secure boot but secure in the sense that only signed update images are accepted.

  • Yes i also changed this files but it was not working. Have you tried my project ?

  • Ha ! i have find the problem in my project , it comes from this :

    I don't know how it is filled , do you know witch option did it please ?

Related