 // This function is called continuously, after setup() completes.
 void loop() 
 {
-  updateFlexAngle();
+  listenBLE();
   delay(500);
 }
 

    Serial.println("Resistance: " + String(flexR) + " ohms");
    Serial.println("Bend: " + String(uangle) + " degrees");
    Serial.println();
    windDirChar.setValue(angle);
    oldFlexAngle = angle;
  }
}

BLEService sensingService("181A"); // BLE "Environmental Sensing"

// BLE Battery Level Characteristic
BLEUnsignedIntCharacteristic windDirChar("2A73",  // standard 16-bit characteristic UUID
    BLERead | BLENotify);     // remote clients will be able to get notifications if this characteristic changes

//###Flex sensor properties###
