virtualabs / btlejack

Bluetooth Low Energy Swiss-army knife
MIT License
1.88k stars 195 forks source link

Comports returning list of tuples on Linux Python 3.4 #15

Closed floyd-fuh closed 6 years ago

floyd-fuh commented 6 years ago

Fyi, on a Linux Mint host, pyserial on Python 3.4 when calling the comports function, it is returning a list of tuples of strings instead of a list of ListPortInfo objects.

This is kind of related to https://github.com/virtualabs/btlejack/issues/8

I fixed it by simply checking if port is of type tuple, and if yes, parse the tuple. Works fine on my Linux machine now.

virtualabs commented 6 years ago

Seems good to me, merged.