Skip to content

CurieBLE: BLEPeripheral::connected() always returns false #444

Closed
@sandeepmistry

Description

@sandeepmistry

Observed while debugging: #377 (comment)

#include <CurieBLE.h>

BLEPeripheral blePeripheral;

void setup() {
  Serial.begin(9600);
  while(!Serial);

  blePeripheral.setLocalName("test");

  blePeripheral.begin();
}

void loop() {
  if (blePeripheral.connected()) {
    Serial.println("connected");

    while (blePeripheral.connected());

    Serial.println("disconnected");
  }

}

if i connect from a central, "connected" is never printed.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions