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

nrf52832 talks to a laptop running v4.2 BT, but not v5

Folks,

I have a dev board PCA10040, which is running, I think, soft device s132. Additional load file is:

components/softdevice/s132/hex/s132_nrf52_6.1.1_softdevice.hex

I have written a BLE program with Qt on a laptop running v4.0 and v4.2 Bluetooth and had it talking and playing nicely with the nrf. However, having just got an LG Gram 17 which has BT5.0, I can no longer properly communicate with the nrf. It [Qt program] recognises the nrf, but it only reads two services not the three it actually has and the handles it reads back for my custom service is different from what I read back with older devices (including Light Blue sniffer software on my Android phone (which also runs v4.2 BT)).

Does something need to be set up differently to communicate with BT5 devices? I was under the impression I was running BT 5 code which was backwards compatible with BT4.x. Do I have that wrong?

I thought that maybe this:

    ble_version_t p_version;
    uint8_t vn;
    sd_ble_version_get( &p_version);
    vn = p_version.version_number; 

Would tell me what version I'm running, but gives valuue nothing like what I expected. ie vn is 9 and subversion b7!

I appreciate that it might be an issue with the Qt program, but I wanted to check I wasn't doing something wrong at the Nordic end.

Many thanks. Slight smile

Parents
  • All BLE 5.0 devices are backwards compatible with 4.2 devices.

    When a BLE link is established the central and peripheral devices will query each other with a Feature Request. Each device will then tell the other device exactly what part of the BLE spec it is capable of adhering to, f.ex. 2mbps PHY or Extended MTUs. 
    Our SoftDevices will then make sure not to use a feature that is not supported by both ends of the link. 
    This leads me to believe that the issue is in the LG device or the Qt program. 


    The BLE program in nRF Connect For Desktop requires an nRF52DK attached to the computer to act as a BLE modem, as I understand it you want to use the native BT+wifi multi-modem of your PC and in that case, nRF Connect is not really suited.

    I do suggest you capture a sniffer trace of your BLE communication as this will help immensely in debugging BLE problems like this.
    See nRF Sniffer User Guide v2.1.

  • Hi and thanks for the reply.

    I'm not sure I have worded my question very well really. The nrf works just fine talking to BT4.x computers, so it's not so much backwards compatibility as forwards compatibility. Maybe.

    So, I would stress that the nrf talks to computers [and phones] with BT4.2, it's 5.0  that causes problems. So, what I am wondering is whether there is something in the nrf firmware I have to change so that it will talk "properly" to 5.0 devices. Once that is done, I am getting what you're saying that it will then also talk to 4.x devices.

    I did kind of suss, eventually,  that you needed to have an nrf kit connected to the computer running the nrf Connect to Desktop, but that still didn't seem to do anything as it wouldn't connect to my devkit. Even if it would I am not really sure i's going to help with my issue.

    On top of that when I have SES running on the new laptop it crashes. Over and over and over again. To the extent it's unusable - both v4.16 and 4.18 - so I'm having to run SES on my old laptop. I feel like Rick Wakeman with all these keyboards ;-)

    So, in summary: nrf device talks to computers with BT4.x. I can sent files using my custom characteristic and all services and characteristics are visible, available and correct.

    I connect to this BT5.0 laptop and my Qt program only sees two services not three, and when I connect to my custom service the two custom characteristics' handles are wrong.

    Sorry if you already understood that. I fully appreciate that the problem could lay with my Qt program but as things stand I just have no way of proving that. No-one in work has anything else BT5.0, not even a phone. :-/

    Many thanks and again sorry if I'm just repeating what you understand!

Reply
  • Hi and thanks for the reply.

    I'm not sure I have worded my question very well really. The nrf works just fine talking to BT4.x computers, so it's not so much backwards compatibility as forwards compatibility. Maybe.

    So, I would stress that the nrf talks to computers [and phones] with BT4.2, it's 5.0  that causes problems. So, what I am wondering is whether there is something in the nrf firmware I have to change so that it will talk "properly" to 5.0 devices. Once that is done, I am getting what you're saying that it will then also talk to 4.x devices.

    I did kind of suss, eventually,  that you needed to have an nrf kit connected to the computer running the nrf Connect to Desktop, but that still didn't seem to do anything as it wouldn't connect to my devkit. Even if it would I am not really sure i's going to help with my issue.

    On top of that when I have SES running on the new laptop it crashes. Over and over and over again. To the extent it's unusable - both v4.16 and 4.18 - so I'm having to run SES on my old laptop. I feel like Rick Wakeman with all these keyboards ;-)

    So, in summary: nrf device talks to computers with BT4.x. I can sent files using my custom characteristic and all services and characteristics are visible, available and correct.

    I connect to this BT5.0 laptop and my Qt program only sees two services not three, and when I connect to my custom service the two custom characteristics' handles are wrong.

    Sorry if you already understood that. I fully appreciate that the problem could lay with my Qt program but as things stand I just have no way of proving that. No-one in work has anything else BT5.0, not even a phone. :-/

    Many thanks and again sorry if I'm just repeating what you understand!

Children
Related