Query if a Bluetooth® Low Energy characteristic is readable.
bleCharacteristic.canRead()
None
if (characteristic.canRead("2901")) {
Serial.println("characteristic is readable");
}
read
Perform a read request for the characteristic.
bleCharacteristic.read()
None
if (characteristic.read()) {
Serial.println("characteristic value read");
// ...
} else {
Serial.println("error reading characteristic value");
}