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

Serial not working after DFU through BLE and nrfconnect

Good day,

I have done DFU using the secure bootloader example in sdk16 using the nrf connect app. The DFU process completes successfully and the controller runs the new application firmware on the device. But I have a strange issue after DFU the serial port stopped working. There is an RFID reader attached to the serial port and stopped working after DFU even we debug the RFID after erasing the controller's flash and bootloader memory then again the serial port did not respond.

My main concern here is:

Is there any impact of the DFU/bootloader on the serial of the controller(nrf52832 chip)?

What should I do to track the issue?

Also when we completed the DFU after the restart we had some prints RTT viewer.

it gives following prints on the RTT viewer.
<info> app: Inside main
00> <debug> app: In nrf_bootloader_init
00> <debug> nrf_dfu_settings: Calling nrf_dfu_settings_init()...
00> <debug> nrf_dfu_flash: Initializing nrf_fstorage_nvmc backend.
00> <debug> nrf_dfu_settings: Using settings page.
00> <debug> nrf_dfu_settings: Copying forbidden parts from backup page.
00> <debug> nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.
00> <info> nrf_dfu_settings: Backing up settings page to address 0x7E000.
00> <debug> nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.
00> <debug> app: Enter nrf_bootloader_fw_activate
00> <info> app: No firmware to activate. 
00> <debug> nrf_dfu_validation: CRC check of app failed. Return 1
00> <debug> app: App is valid
00> <info> nrf_dfu_settings: Backing up settings page to address 0x7E000.
00> <debug> nrf_dfu_settings: Destination settings are identical to source, write not needed. Skipping.
00> <debug> app: Running nrf_bootloader_app_start with address: 0x00001000
00> <debug> app: Disabling interrupts. NVIC->ICER[0]: 0x0
  • I'm using the BLE bootloader. My application uses the UART and it's not working in applications after dfu. However everything else works fine.

    If I run my application without bootloader then UART works fine

  • Edvin said:
    Have you tried to debug?

     Have you tried to debug the application? Does the UART initialize as expected? Perhaps you have a bug in your UART implementation in the new application that makes you believe that the uart isn't responding? 

    I feel that I am working blind here. Can you be a bit more specific? Have you ensured that the UART is properly initialized? Have you tried to debug for UART interrupts? Do you get any? Perhaps you get the communication error from the UART event handler? The UART HW peripheral doesn't care if there is a bootloader present or not.

  • But why the UART works fine when we burn only the application to the nrf?

    Also, I have debugged the application after adding bootloader, it seems that the UART does not respond when we push some data to it.  

    it seems that the UART initializes but the responses I get are 

    00> app_uart_put Response: NRF_SUCCESS
    00> app_uart_put Error code : 0

    in the UART event handler, I get the event APP_UART_TX_EMPTY.

    But there is no error event in the event handler and nothing response from the UART.

    Thanks

  • In event handler, the event APP_UART_DATA is not happening, it seems UART is not responding

  • Hi,

    I have debugged the UART again using the Logic Analyser, it shows that when I try to push some data to UART it does not show on the logic analyzer and similar in case of receiving.

    But when I run the same application without bootloader it shows data communication through the logic analyzer.

    I'm a bit confused about tracking the main issue. My finding says maybe there is something on a bootloader that is affecting the UART in the new application, please guide me on this what could be the possible issue with the bootloader + application combined with the UART?

    Thanks.

Related