ArduinoBLE - BLE.advertise()

Start advertising.

Syntax

BLE.advertise()

Parameters

None

Returns

  • 1 on success,
  • 0 on failure.

Example


  // begin initialization
  if (!BLE.begin()) {
    Serial.println("starting Bluetooth® Low Energy module failed!");

    while (1);
  }

  // ...

  BLE.advertise();

  // ...