Genuino101 - BLE disconnect event


101 is working as peripheral device (CurieBLE).

blePeripheral.setEventHandler(BLEConnected, bleConnectHandler);
blePeripheral.setEventHandler(BLEDisconnected, bleDisconnectHandler);

Only bleConnectHandler is triggered. When I turn off Bluetooth on Android device nothing happened.

void bleDisconnectHandler(BLECentral& central) {
  // central disconnected event handler
  Serial.print(F("Disconnected event, central: "));

What am I doing wrong?

Nobody can help me? :wink:

@hustler79 I'm not experience this issue on my Nexus 7 device use the "nRF Master Control Panel" app.

I'm using the CallbackLED.ino example sketch.

What app are you using? Which OS version are you using?

I have Motorola Moto G2 with Android 6.

I am using the same sketch as you but without any other app. It is a very simple sketch. Only two things: connect and disconnect event.

What I done:
I turned on only Bluetooth and I scanned if there are any (BL/BLE) devices. At this point it seems every thing is ok. But If I turn off Bluetooth nothing happened.
After that I have to restart Genuino.

Maybe it’s a wrong way what I am trying to do.

I suggest you try it with an app, I suspect your phone is trying to pair with the Genuino, and this is not currently supported.

Try this nRF Master Control Panel

Ok, I will try.
I create my own app to scan for ble devices.
I think this could fix my problem :slight_smile:

Is there only one BLE lib which supports Genuino?