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

Application updated through BLE DFU (OTA) don't work properly

Dear all,

I'm using NRF52832 with SDK 14.2.0 and SD 132 v5.0.0.

I have my own implemented application working properly when is flashed directly without bootloader, only SD and Application.

But when I update firmware through DFU BLE OTA as described in Getting started with bootloader my application code starts but works very strange. Code is dysfunctional, working in strange manner.

The same is when I create one package containing all in one (bootloader, bootloader settings, softdevice and own app) and flash it directly.

Have you got any idea what happens and how to resolve that problem? I think there is some conflict with memory when bootloader is flashed but I dont know where to search ;/

Best regards

  • Hi Lukasz, 

     

    Could you tell us how exactly your code behavior after using with the bootloader ? Have you managed to do DFU update with one of our SDK's example ? 

    There could be a chance that it has to do with the LFCLK or RTC that has been used in our bootloader and then not initialized properly in your application. 

    We need more debug information to give you advice. 

  • I use HFCLK instead of LFCLK in my application. HCLK is initialized on start in main function.

    RTC is not used in my application.

    After more debug tries there is a chance that there is conflict with pin configuration because I'm using my custom board. I find that current consumption of my board increased. 

    I'm working with secure_dfu_ble bootloader. Is there any posibility to turn off button and leds configuration with steering in bootloader app because i dont need leds and button to set bootloader state.

  • I reviewed problem one more time with some changes in my application code. I resolved my problem in a portion. There was conflict with pin configuration between bootloader (button and 4 LEDs) and my application.

    As in previous post, is there posibility to change in easy way bootloader code not to use button and 4 LEDs?

  • Hi Lukasz, 

     

    I'm not sure how the configuration of LED and button in the bootloader can affect your application. I assume in your application you should do initialization of the LEDs and Buttons before you use. 

    But if you want to disable LED and Button, you can comment out  leds_init(); and buttons_init(); in main.c 

    But how do you plan to enter bootloader ? Using a button or buttonless ? 

     

  • Sorry I wasn't precise enough.

    Now, when I do full initialization of pins and setting default state everything works in my app after bootloader update. (Previously, i don't set default state in my app on one pin which was used in bootloader as LED, so there was other behaviour as I expected ;) ).

    I want to enter bootloader using buttonless ;)

    Now, because of that I'm using my custom board i want to turn off LEDS. I worry about some pin conflict between nRF and other IC on my board when default configuration of bootloader is used. Driving pin in opposite states problem.

    I tried to comment that two functions but leds are still driven in such states I observe that when testing on development board. So comment or uncomment lines leds_init(); and buttons_init(); is not a resolve of that

Related