-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Moving to pygatt (and back to bluepy again) and further implement bulb-functions/improve communication #20
Conversation
Another note on the changes. No longer are handles used (directly.) It seems that the handles to read from/write to are static but do appear to change with bulb versions. A UUID is used to access the characteristics (0xFFE4 for notifications/reading, 0xFFE9 for writing commands) to retrieve the necessary handles from the bulb. |
Please wait before merging. I am having some troubles due to I will explain later. |
Lot of good changes in here ! I like what you've done with the I'll start testing this during the week to assist you with this task 👍 The fact we have to be root to access the bluetooth device is very inconvenient. Haven't tried this yet but maybe I could also add a section in README to explain how to make BLE device accessible for non root (as with this link) |
And I've moved back to This can be worked around by creating 5 entries in Also, if Please test this version. I was able to get notifications using After this is merged, I'll create a pull request for homeassistant-magicblue to incorporate the new abilities of this library. |
Everything run fine with my v7 bulb, thank for this PR 😉 I'll release a new version with these changes |
Thanks! |
Following up on #17. Here is a pull request which moves
magicblue
topygatt
frombluepy
, and further implements the protocol.Unfortunately, I have (yet) seen no way to dynamically figure out the address type to use. The software does try to guess if no version is given, but your mileage may vary. Maybe we can detect it from the bulb-address? Please, let me know the versions and mac addresses of your bulb(s).
Also, scanning for bulbs is now slightly altered.
pygatt
reports all found devices at once after scanning.bluepy
uses a callback which is called during scanning. In the new method of scanning, it might look scanning has stalled. Therefore, I have shortened the scanning-time to 10 seconds.Please, feel free to provide any feedback. And, of course, do test this on your own bulb(s)! For my V10 bulbs all implemented functions work.