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

ble_app_hrs + Buttonless DFU on NRF52DK(52832) + OTA update

Hi,

I want to verify

1. Program  ble_app_hrs with buttonless dfu integrated + secure bootloader + bootloader setting to nRF52DK. 

2. Boot up nRF52DK, then use buttonless dfu goto bootloader mode

3. Update app_dfu_package.zip (nrfutil pkg generate --hw-version 52 --application-version 0 --application ble_ap nrfutil pkg generate --hw-version 52 --application-version 0 --application ble_app_hrs_pca10040_s132.hex --sd-req 0xCB --key-file private.key app_dfu_package.zip
Zip created at app_dfu_package.zip)

====

Below are my steps:

Step1 Generate bootloader setting page

Step2  merge secure bootloader(\dfu\secure_bootloader\pca10040_s132_ble\) + bootloader settings

Step3 Program secure bootloader (examples\dfu\secure_bootloader\pca10040_s132_ble)+ bl setting

Step4 Program softdevice (s132_nrf52_7.0.1)

Step5 Program app(ble_app_hrs_pca10040_s132 which is integrate with buttonless_duf already)

Step 6 When nRF52DK bootup, error logs are below:

Are my steps correct?

How can I make it right?

Thanks.

Vick

  • Hi Hung,

    The issue remains.

    I'm not sure what I capture is right. Below is what I'm running the tool.

    PS: I can not find "Nordic_HRM_DFU" in the Device" All advertising device" of interface bar.

    Is that normal? So I think I capture all finally.

    ===

    My steps:

    1. Erase bond info on Phone, disable BT, reset phone, and re-flash hex files to nRF52DK.

    2. nRF52DK goes Advertising.

    3. Set up other nRF52DK to be a sniffer and execute Wireshark.

    4. Click twice hardware interface to start sniffer. (See comport)

    5. Start bond, connect, then update by zip on phone.

    6. Stop sniffer

    7. Save the file (File -> save as)

    Please see the captured file.

    5488.sniffer_trace.pcapng

    Thanks.

  • Hi Vick, 

    The device should be in the "All advertising device" list . Please try again, maybe practice with some other example to see if you can track the device. 
    Without the device to track the sniffer can't follow the connection. 
    Please make sure your device (HRM) doesn't get connected automatically by the phone or other central. 
    Also please describe what exact issue you are having now. Do you have an issue if you simply click the DFU button ? 
    Please try capture a screen capture (video) of when you test so we know what happened. And send us the log on nRF Connect as well as log on the Bootloader side. 

  • Hi Hung,

    Please see the video, pictures and wireshark log.

    Also I attached my main.c, sdk_config.h.(vick_hrs_src_1210.7z)

    vick_hrs_src_1210.7z

    sniffer_trace_1210.pcapng

    BTW, how do I enable/capture log for Bootloader side?

    Thank you !!

  • Hi Vick, 

    Please try the following while running the sniffer: 

    I was testing using the files (flash.bat) bin the .zip I provided. Please also test using the same. 
    It's important to try switch the buttonless to bootloader (DFUTarg) and then reconnect to DFUTarg instead of doing it in one shot. 
    Please capture (you can use an app to capture screen , I used Xrecorder) of the screen.


    You can use the bootloader debug and open UART to see the bootloader log. 

  • Hi Hung,

    I have tried the files what you provided (buttonless only)=> Update process is OK same as your video.

    I have an issue is that my app integrated with hrs+buttonless. (vick_hrs_src_1210.7z

    I tried your step. Please see the video below:

    Setup(before the video operation): 

    1. Forget bond info

    2. Disable BT

    3. Reset Android phone

    The steps of video:

    1. Enable BT

    2. Connect Nordic_HRM_DFU

    3. Enable Secure DFU Service indications

    4. Enable Service Changed indications

    5. Write value -> send

    6. Get GATT ERROR 133 and ERROR 8.

    And please see the logs during the video, there are no logs after I sent "Entering Bootloader".

    Attached sniffer below

    sniffer_trace_1214.pcapng

    Please correct me, if any steps or integration of my apps is wrong.

    Thank you!!

Related