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

buttonless dfu ble. error in uploading file.

nrf52810 used and sdk 15.3 used . i able to run my program without error and i even able connect my ble dfu. but i cant upload my zip file and i cant bond with nordic dfu. its showing invalid object. even i cant bond with device

Parents
  • Hi,

    A typical reason for getting invalid object error is that the DFU image was not signed with the correct key. Can you confirm that the bootloader was built with your public key, and that the DFU image was signed with the corresponding private key?

    If the above is not the issue, can you elaborate on the issue? Also, can you upload the log from the DFU master?

  • sir sorry... where i can get log. im new to this field

  • Can you show me the full nrfutil command you use to build the zip package as well as the settings page? (no need for a screenshot, just copy-past the full commands - that gives better readability).

    Generally, the most important things for an APP update that relies on the SoftDevice is:

    • Specify the correct (existing) SoftDevice ID with --sd-req
    • Specify the correct application hex with --application
    • Specify a application version that is higher than what is currently installed using --application-version
    • specify the correct HW version (meaning same as you used when generating the settings page) using --hw-version
    • Sign with the correct private key using --key-file

    See Generating DFU packages for details.

  • nRF Connect, 2020-12-17
    DfuTarg (E0:6E:0D:23:1D:8E)
    I	15:33:34.503	[Server] Server started
    V	15:33:34.523	Heart Rate (0x180D)
    - Heart Rate Measurement [N] (0x2A37)
       Client Characteristic Configuration (0x2902)
    - Body Sensor Location [R] (0x2A38)
    - Heart Rate Control Point [W] (0x2A39)
    Unknown Service (0000aaa0-0000-1000-8000-aabbccddeeff)
    - Unknown Characteristic [N R] (0000aaa1-0000-1000-8000-aabbccddeeff)
       Client Characteristic Configuration (0x2902)
       Unknown Descriptor (0000aab0-0000-1000-8000-aabbccddeeff)
       Characteristic User Description (0x2901)
       Characteristic Presentation Format (0x2904)
    - Unknown Characteristic [I W WNR] (0000aaa2-0000-1000-8000-aabbccddeeff)
       Client Characteristic Configuration (0x2902)
    User Data (0x181C)
    - First Name [R W] (0x2A8A)
    - Last Name [R W] (0x2A90)
    - Gender [R W] (0x2A8C)
    V	15:33:35.249	Connecting to E0:6E:0D:23:1D:8E...
    D	15:33:35.249	gatt = device.connectGatt(autoConnect = false, TRANSPORT_LE, preferred PHY = LE 1M)
    D	15:33:35.284	[Server callback] Connection state changed with status: 0 and new state: CONNECTED (2)
    I	15:33:35.284	[Server] Device with address E0:6E:0D:23:1D:8E connected
    D	15:33:35.295	[Callback] Connection state changed with status: 0 and new state: CONNECTED (2)
    I	15:33:35.295	Connected to E0:6E:0D:23:1D:8E
    D	15:33:35.352	[Broadcast] Action received: android.bluetooth.device.action.ACL_CONNECTED
    V	15:33:35.352	Discovering services...
    D	15:33:35.352	gatt.discoverServices()
    I	15:33:35.738	Connection parameters updated (interval: 15.0ms, latency: 0, timeout: 6000ms)
    I	15:33:35.841	Connection parameters updated (interval: 7.5ms, latency: 0, timeout: 5000ms)
    D	15:33:35.931	[Callback] Services discovered with status: 0
    I	15:33:35.931	Services discovered
    V	15:33:35.945	Generic Access (0x1800)
    - Device Name [R W] (0x2A00)
    - Appearance [R] (0x2A01)
    - Peripheral Preferred Connection Parameters [R] (0x2A04)
    - Central Address Resolution [R] (0x2AA6)
    Generic Attribute (0x1801)
    Secure DFU Service (0xFE59)
    - DFU Packet [WNR] (8ec90002-f315-4f60-9fb8-838830daea50)
    - DFU Control Point [N W] (8ec90001-f315-4f60-9fb8-838830daea50)
       Client Characteristic Configuration (0x2902)
    I	15:33:35.995	Connection parameters updated (interval: 15.0ms, latency: 0, timeout: 6000ms)
    V	15:33:44.149	[DFU] DFU service started
    V	15:33:44.149	[DFU] Opening file...
    I	15:33:44.160	[DFU] Firmware file opened successfully
    V	15:33:44.160	[DFU] Connecting to DFU target...
    D	15:33:44.160	[DFU] gatt = device.connectGatt(autoConnect = false, TRANSPORT_LE, preferredPhy = LE_1M | LE_2M)
    I	15:33:44.165	[DFU] Connected to E0:6E:0D:23:1D:8E
    V	15:33:44.166	[DFU] Discovering services...
    D	15:33:44.166	[DFU] gatt.discoverServices()
    I	15:33:44.176	[DFU] Services discovered
    D	15:33:44.194	[DFU] wait(1000)
    V	15:33:45.204	[DFU] Requesting new MTU...
    D	15:33:45.204	[DFU] gatt.requestMtu(517)
    I	15:33:45.215	[DFU] MTU changed to: 247
    V	15:33:45.215	[DFU] Enabling notifications for 8ec90001-f315-4f60-9fb8-838830daea50
    D	15:33:45.215	[DFU] gatt.setCharacteristicNotification(8ec90001-f315-4f60-9fb8-838830daea50, true)
    D	15:33:45.216	[DFU] gatt.writeDescriptor(00002902-0000-1000-8000-00805f9b34fb, value=0x01-00)
    I	15:33:45.244	[DFU] Data written to descr.8ec90001-f315-4f60-9fb8-838830daea50, value (0x): 01-00
    V	15:33:45.244	[DFU] Notifications enabled for 8ec90001-f315-4f60-9fb8-838830daea50
    A	15:33:45.246	[DFU] Notifications enabled
    D	15:33:45.246	[DFU] wait(1000)
    V	15:33:46.247	[DFU] Writing to characteristic 8ec90001-f315-4f60-9fb8-838830daea50
    D	15:33:46.247	[DFU] gatt.writeCharacteristic(8ec90001-f315-4f60-9fb8-838830daea50)
    I	15:33:46.279	[DFU] Data written to 8ec90001-f315-4f60-9fb8-838830daea50, value (0x): 06-01
    I	15:33:46.281	[DFU] Notification received from 8ec90001-f315-4f60-9fb8-838830daea50, value (0x): 60-06-01-00-01-00-00-8D-00-00-00-80-7B-36-E2
    A	15:33:46.281	[DFU] Command object info received (Max size = 256, Offset = 141, CRC = E2367B80)
    A	15:33:46.281	[DFU] Received CRC match Init packet
    V	15:33:46.282	[DFU] Writing to characteristic 8ec90001-f315-4f60-9fb8-838830daea50
    D	15:33:46.282	[DFU] gatt.writeCharacteristic(8ec90001-f315-4f60-9fb8-838830daea50)
    I	15:33:46.310	[DFU] Data written to 8ec90001-f315-4f60-9fb8-838830daea50, value (0x): 04
    I	15:33:46.311	[DFU] Notification received from 8ec90001-f315-4f60-9fb8-838830daea50, value (0x): 60-04-01
    A	15:33:46.311	[DFU] Command object executed
    V	15:33:46.311	[DFU] Writing to characteristic 8ec90001-f315-4f60-9fb8-838830daea50
    D	15:33:46.311	[DFU] gatt.writeCharacteristic(8ec90001-f315-4f60-9fb8-838830daea50)
    I	15:33:46.341	[DFU] Data written to 8ec90001-f315-4f60-9fb8-838830daea50, value (0x): 06-02
    I	15:33:46.341	[DFU] Notification received from 8ec90001-f315-4f60-9fb8-838830daea50, value (0x): 60-06-01-00-10-00-00-00-00-00-00-00-00-00-00
    A	15:33:46.342	[DFU] Data object info received (Max size = 4096, Offset = 0, CRC = 00000000)
    V	15:33:46.394	[DFU] Writing to characteristic 8ec90001-f315-4f60-9fb8-838830daea50
    D	15:33:46.394	[DFU] gatt.writeCharacteristic(8ec90001-f315-4f60-9fb8-838830daea50)
    I	15:33:46.459	[DFU] Data written to 8ec90001-f315-4f60-9fb8-838830daea50, value (0x): 01-02-00-10-00-00
    I	15:33:46.460	[DFU] Notification received from 8ec90001-f315-4f60-9fb8-838830daea50, value (0x): 60-01-08
    E	15:33:46.461	[DFU] Remote DFU error: OPERATION NOT PERMITTED
    V	15:33:46.461	[DFU] Disconnecting...
    D	15:33:46.461	[DFU] gatt.disconnect()
    I	15:33:46.479	[DFU] Disconnected
    D	15:33:46.479	[DFU] gatt.refresh() (hidden)
    D	15:33:46.479	[DFU] gatt.disconnect()
    D	15:33:46.479	[DFU] gatt.close()
    D	15:33:46.479	[DFU] wait(600)
    I	15:33:46.565	Connection parameters updated (interval: 7.5ms, latency: 0, timeout: 5000ms)
    I	15:33:46.805	Connection parameters updated (interval: 15.0ms, latency: 0, timeout: 6000ms)
    

  • Hi,

    I see you get a Remote DFU error: OPERATION NOT PERMITTED now. Not sure why that is. Did you change anything? In any case, please let me know how you generate the zip package with nrfutil as I mentioned in my previous reply. I suspect we will find something useful there (and again, if you would like more detailed errors, then testing with the debug bootloader would be better - just remember to modify it to use your own public key).

  • <info> app: Inside main
    <debug> app: In nrf_bootloader_init
    <debug> nrf_dfu_settings: Calling nrf_dfu_settings_init()...
    <debug> nrf_dfu_flash: Initializing nrf_fstorage_nvmc backend.
    <debug> nrf_dfu_settings: Settings OK
    <debug> app: Enter nrf_bootloader_fw_activate
    <info> app: No firmware to activate.
    <debug> app: Enter nrf_dfu_app_is_valid
    <debug> app: No valid app to boot.
    <debug> app: DFU mode because app is not valid.
    <info> nrf_bootloader_wdt: WDT is not enabled
    <debug> app: in weak nrf_dfu_init_user
    <debug> app: timer_stop (0x20002B14)
    <debug> app: timer_activate (0x20002B14)
    <info> app: Entering DFU mode.
    <debug> app: Initializing transports (found: 1)
    <debug> nrf_dfu_ble: Initializing BLE DFU transport
    <debug> nrf_dfu_ble: Setting up vector table: 0x00022000
    <debug> nrf_dfu_ble: Enabling SoftDevice.
    <debug> nrf_dfu_ble: Configuring BLE stack.
    <debug> nrf_dfu_ble: Enabling the BLE stack.
    <debug> nrf_dfu_ble: No advertising name found
    <debug> nrf_dfu_ble: Using default advertising name
    <debug> nrf_dfu_ble: Advertising...
    <debug> nrf_dfu_ble: BLE DFU transport initialized.
    <debug> nrf_dfu_flash: Initializing nrf_fstorage_sd backend.
    <debug> app: Enter main loop
    <debug> nrf_dfu_ble: Connected
    <debug> nrf_dfu_ble: Received BLE_GAP_EVT_CONN_PARAM_UPDATE
    <debug> nrf_dfu_ble: max_conn_interval: 12
    <debug> nrf_dfu_ble: min_conn_interval: 12
    <debug> nrf_dfu_ble: slave_latency: 0
    <debug> nrf_dfu_ble: conn_sup_timeout: 600
    <debug> nrf_dfu_ble: Received BLE_GAP_EVT_CONN_PARAM_UPDATE
    <debug> nrf_dfu_ble: max_conn_interval: 6
    <debug> nrf_dfu_ble: min_conn_interval: 6
    <debug> nrf_dfu_ble: slave_latency: 0
    <debug> nrf_dfu_ble: conn_sup_timeout: 500
    <debug> nrf_dfu_ble: Received BLE_GAP_EVT_CONN_PARAM_UPDATE
    <debug> nrf_dfu_ble: max_conn_interval: 12
    <debug> nrf_dfu_ble: min_conn_interval: 12
    <debug> nrf_dfu_ble: slave_latency: 0
    <debug> nrf_dfu_ble: conn_sup_timeout: 600
    <debug> nrf_dfu_ble: Received BLE_GATTS_EVT_EXCHANGE_MTU_REQUEST (request: 517, reply: 247).
    <debug> nrf_dfu_ble: Advertising...
    <debug> app: timer_stop (0x20002B14)
    <debug> app: timer_fire (0x20002B14)
    <info> app: Inactivity timeout.
    <debug> app: Resetting bootloader.
    <info> nrf_dfu_settings: Backing up settings page to address 0x2E000.
    <debug> nrf_dfu_settings: Writing settings...
    <debug> nrf_dfu_settings: Erasing old settings at: 0x0002E000
    <debug> nrf_dfu_flash: nrf_fstorage_erase(addr=0x0x0002E000, len=1 pages), queue usage: 0
    <debug> nrf_dfu_flash: nrf_fstorage_write(addr=0x0002E000, src=0x20004A94, len=440 bytes), queue usage: 1
    <debug> nrf_dfu_flash: Flash erase success: addr=0x0002E000, pending 1
    <debug> nrf_dfu_flash: Flash write success: addr=0x0002E000, pending 0
    <info> app: Inside main
    <debug> app: In nrf_bootloader_init
    <debug> nrf_dfu_settings: Calling nrf_dfu_settings_init()...
    <debug> nrf_dfu_flash: Initializing nrf_fstorage_nvmc backend.
    <debug> nrf_dfu_settings: Settings OK
    <debug> app: Enter nrf_bootloader_fw_activate
    <info> app: No firmware to activate.
    <debug> app: Enter nrf_dfu_app_is_valid
    <debug> app: No valid app to boot.
    <debug> app: DFU mode because app is not valid.
    <info> nrf_bootloader_wdt: WDT is not enabled
    <debug> app: in weak nrf_dfu_init_user
    <debug> app: timer_stop (0x20002B14)
    <debug> app: timer_activate (0x20002B14)
    <info> app: Entering DFU mode.
    <debug> app: Initializing transports (found: 1)
    <debug> nrf_dfu_ble: Initializing BLE DFU transport
    <debug> nrf_dfu_ble: Setting up vector table: 0x00022000
    <debug> nrf_dfu_ble: Enabling SoftDevice.
    <debug> nrf_dfu_ble: Configuring BLE stack.
    <debug> nrf_dfu_ble: Enabling the BLE stack.
    <debug> nrf_dfu_ble: No advertising name found
    <debug> nrf_dfu_ble: Using default advertising name
    <debug> nrf_dfu_ble: Advertising...
    <debug> nrf_dfu_ble: BLE DFU transport initialized.
    <debug> nrf_dfu_flash: Initializing nrf_fstorage_sd backend.
    <debug> app: Enter main loop

  • this is the error n computer i get while trying to upload a file. showing gatt error

Reply Children
No Data
Related