Hello,
If a peripheral-to-be starts advertising by GapAdv_enable() with duration and then gets connected with a central, the peripheral, for unknown reason, will become unresponsive to connection events when the duration expires, which will cause disconnection by supervision timeout. However, the peripheral doesn't even get the termination event. After that, if I call GapAdv_enable() again, I will get the result SUCCESS, but there will be no advertising. The peripheral will be in some strange state.
If an advertiser gets connected, the advertising is automatically stopped with GAP_EVT_ADV_END_AFTER_DISABLE, but the duration timer seems to keep going. What I'm observing is, GAP_EVT_ADV_END_AFTER_DISABLE, which should not occur since the advertising was already disabled upon connection establishment, comes again when the duration expires while the peripheral is in connection state. Then the peripheral becomes kind of unresponsive.
The SDK version is 2.40.
Please let me know if there is any workaround or solution. Thanks.
- Cetri