Hi @brettchien,
Thanks for a great library. I am looking to implement a direct BLE connection to Mooshimeter on OSX. Guys have build Mooshimeter-PythonAPI unfortunately it uses a BLE dongle instead of Mac native/build-in BLE. Your library seems to fill in the gap nicely. However I am struggling with how a more complex profile should look like.
I am trying to add Characteristic to a ProfileHandler but I don't understand how to do it. My approach below obviously does not seem to work.
from pyble._gatt import Characteristic
...
class MeterInfo(Characteristic):
UUID = "1BC5FFA1-0200-62AB-E411-F254E005DBD4"
name = "Meter Info"
_AUTOLOAD = True
...
class MooshimeterProfile(ProfileHandler):
UUID = "1BC5FFA0-0200-62AB-E411-F254E005DBD4"
_AUTOLOAD = True
names = {
"1BC5FFA0-0200-62AB-E411-F254E005DBD4": "Meter Service",
..
def initialize(self):
print "init"
self.addCharacteristic(MeterInfo)
pass
Any ideas who to handle more complex profiles implementations? Thanks!
Hi @brettchien,
Thanks for a great library. I am looking to implement a direct BLE connection to Mooshimeter on OSX. Guys have build Mooshimeter-PythonAPI unfortunately it uses a BLE dongle instead of Mac native/build-in BLE. Your library seems to fill in the gap nicely. However I am struggling with how a more complex profile should look like.
I am trying to add Characteristic to a ProfileHandler but I don't understand how to do it. My approach below obviously does not seem to work.
Any ideas who to handle more complex profiles implementations? Thanks!