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

Advertising doesn't after calling sd_ble_gap_adv_start

Hi everybody,

I'm having a problem with the advertising function of the SoftDevice.

When the application starts advertising the function "sd_ble_gap_adv_start()" returns without an error.

But it takes up to 10 seconds until I can see the advertising with the nRF Connect App.

How can I fix this?

I'm using

Laird BL654 (nRF 52840)

SDK16

SD140v7.0.1

I have asked a similar question before but this question seems to be closed

https://devzone.nordicsemi.com/f/nordic-q-a/54839/advertising-doesn-t-start-immediately-after-calling-sd_ble_gap_adv_start

Best regards Fabian

Parents
  • Hi Fabian,

    Assuming that everything works and the nRF is advertising in connectable mode form the start, the time it takes until a connection is established depends mainly on the following factors:

    • Advertising interval on the peripheral
    • Scan duty cycle (window and interval) on the central

    Looking at the old thread, it looks like advertising does not start immediately? If so, that is the first thing you need to check. How long does it take before you call sd_ble_gap_adv_start()? Have you checked with a sniffer? When does the peer try to connect? Is the problem that there are unsuccessful connect requests for some reasons? (just a shot in the dark) A sniffer trace should shed some light on this.

  • Hi Einar,

    thanks for the fast answer.

    sd_ble_gap_adv_start() returns without an error but it takes upto 10 seconds until I can se the advertising with the nRF connect app.

    I think I forgot to mention that there is also a BLE Mesh stack running

    sd_ble_gap_adv_start() is called after everithing is inialized (might take upto 1 s after power up) .

    I could use a nRF Sniffer, if that is OK I will provide you with the sniffer data

    There iseems to no problems with connectiong to the peer.

  • Fabian Hauschild said:
    I think I forgot to mention that there is also a BLE Mesh stack running

     That may be relevant. I assume it is the Nordic BLE Mesh stack? Can you provide more details on your application and config? Depending on the configuration, it might be that the mesh stack uses a lot of time (for scanning in particular), leaving less time for the normal advertiser.

Reply Children
Related