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

pc-ble-driver example heart_rate_collector get disconnected with error 0x22

Hi,

I am running on pc-ble-driver master branch.

https://github.com/NordicSemiconductor/pc-ble-driver

Currently I am using abce7974fe983c23930d362b1769e51c8fa13cbf.

I am trying to verifying the newly added connectivity firmware for nRF52840 Dongle PCA10059.

So I compiled and loaded hex/sd_api_v6/connectivity_<ver>_usb_with_s140_6.1.0.hex

I am now getting error 0x22 which is BLE_HCI_STATUS_CODE_LMP_RESPONSE_TIMEOUT, once I connect to a Nordic_HRM peripheral. Peripheral is built with nRF5_SDK_15.2.0_9412b96 and run on PCA10040.

My host is Ubuntu 18.04.

I am doing this because the release note 4.0.0 says:"Support SoftDevice API version 2, 3, 5 and 6 in the same release". And I am aware that PCA10059 works fine with https://github.com/NordicSemiconductor/pc-ble-driver/blob/release/v2.3.2/hex/sd_api_v3/connectivity_1.2.3_usb_with_s132_3.1.hex

Beside this problem, I also found that hex/sd_api_v6/connectivity_<ver>_1m_with_s132_6.1.0.hex does not work anymore on PCA10040. Does not know when this has started.

Thanks & best regards,

Chencheng

  • As I mentioned earlier, I run everything under Ubuntu 18.04. I follow the instruction to compile from source. I compiled connectivity firmware hex file as well. I flashed it using nrf-connect AppImage under Linux with latest updates.

    I am running heart_rate_colletcor_v6 by:

    $ ./heart_rate_collector_v6 /dev/ttyACM2 

  • connectivity_4.0.0_1m_with_s132_6.1.0.hex

    Just for fun, can you try to flash this image instead? The pc-ble-driver has some patches for the connectivity firmware, so depending on how you compiled it, these patches were might not included. Let me know if it still behaves the same.

    BR,

    Edvin

  • Tried flashed under Linux with nRF connect programmer. Didn't work:

    $ ./heart_rate_collector_v6 /dev/ttyACM2 
    Serial port used: /dev/ttyACM2
    Baud rate used: 1000000
    Info: Successfully opened /dev/ttyACM2. Baud rate: 1000000. Flow control: none. Parity: none.
    Log: State change: STATE_START -> STATE_RESET
    Log:        1 ->  [N/A] type:          RESERVED_5 reliable: no seq#:0 ack#:0 payload_length:0 data_integrity:0 err_code:0x0
    Status: 6, message: Target Reset performed
    Log: State change: STATE_RESET -> STATE_UNINITIALIZED
    Log:        2 ->  [01 7e ] type: LINK_CONTROL_PACKET reliable: no seq#:0 ack#:0 payload_length:2 data_integrity:0 err_code:0x0 [SYNC]
    Log:        3 ->  [01 7e ] type: LINK_CONTROL_PACKET reliable: no seq#:0 ack#:0 payload_length:2 data_integrity:0 err_code:0x0 [SYNC]
    Log:        4 ->  [01 7e ] type: LINK_CONTROL_PACKET reliable: no seq#:0 ack#:0 payload_length:2 data_integrity:0 err_code:0x0 [SYNC]
    Log:        5 ->  [01 7e ] type: LINK_CONTROL_PACKET reliable: no seq#:0 ack#:0 payload_length:2 data_integrity:0 err_code:0x0 [SYNC]
    Log:        6 ->  [01 7e ] type: LINK_CONTROL_PACKET reliable: no seq#:0 ack#:0 payload_length:2 data_integrity:0 err_code:0x0 [SYNC]
    Log:        7 ->  [01 7e ] type: LINK_CONTROL_PACKET reliable: no seq#:0 ack#:0 payload_length:2 data_integrity:0 err_code:0x0 [SYNC]
    Status: 0, message: No response from device. Tried to send packet 6 times.
    Log: State change: STATE_UNINITIALIZED -> STATE_NO_RESPONSE
    Failed to open nRF BLE Driver. Error code: 0x0D
    

  • Do you reset the nRF after programming it with the .hex file? Try to power cycle it before you run your project from the terminal. Any luck?

Related