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

  • 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!

  • OK, amazingly, we've just had a visitor who has a One Plus 6 phone which has BT5.0 and it works OK. So the problem must lay with Qt.

    Many thanks for all the suggestions and help.

Related