Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't inherit or use Extended Advertising #862

Open
AlistairMRoss opened this issue Jan 15, 2025 · 1 comment
Open

Can't inherit or use Extended Advertising #862

AlistairMRoss opened this issue Jan 15, 2025 · 1 comment

Comments

@AlistairMRoss
Copy link

From Example

class AdvertisingCallbacks : public NimBLEExtAdvertisingCallbacks {
void onStopped(NimBLEExtAdvertising* pAdv, int reason, uint8_t instId) override {
/* Check the reason advertising stopped, don't sleep if client is connecting */
Serial.printf("Advertising instance %u stopped\n", instId);
switch (reason) {
case 0:
Serial.printf("Client connecting\n");
return;
case BLE_HS_ETIMEOUT:
Serial.printf("Time expired - sleeping for %" PRIu32 " seconds\n", sleepSeconds);
break;
default:
break;
}

Error: NimBLEExtAdvertisingCallbacks - not a class or struct name
onStopped - member function declared with 'override' does not override a base class member

@h2zero
Copy link
Owner

h2zero commented Jan 15, 2025

Looks like you have not enabled extended advertising.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants