This is while using movehub on macOS using BGAPI. I understand that you only support linux for now. Please feel free to close this issue if it is not relevant
Only pygatt.GATTToolBackend has the variable _con. However, the adapter can also be of the instance pygatt.BGAPIBackend. Using BGAPIBackend does not have _con variable. Hence the code breaks at this point
Current bad fix I introduced in is_connected() to get other stuff running:
def is_connected(self):
# not sure about this - GATToolBacked returns True if the
# process is running so if we power off the Move Hub it
# keeps returning True
if (type(self.adapter) == pygatt.backends.bgapi.bgapi.BGAPIBackend):
return True
else:
return self.adapter._con.isalive()
This is while using movehub on macOS using BGAPI. I understand that you only support linux for now. Please feel free to close this issue if it is not relevant
https://github.com/JorgePe/pyb00st/blob/bf15272481d0541461923820f98983d9f10ebcc9/pyb00st/movehub.py#L143
Only
pygatt.GATTToolBackend
has the variable_con
. However, the adapter can also be of the instancepygatt.BGAPIBackend
. Using BGAPIBackend does not have_con
variable. Hence the code breaks at this pointCurrent bad fix I introduced in
is_connected()
to get other stuff running:Tested on python3 with pygatt-3.2.0 on macOS