Skip to content

Commit

Permalink
Ignore Bluetooth serial ports
Browse files Browse the repository at this point in the history
  • Loading branch information
ppannuto committed Jan 16, 2017
1 parent 3ea1b02 commit 3a31748
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tockloader/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,9 @@ def open (self, port):
else:
# Just find any port and use the first one
ports = list(serial.tools.list_ports.comports())
# Mac's will report Bluetooth devices with serial, which is
# almost certainly never what you want, so drop these
ports = [p for p in ports if 'Bluetooth-Incoming-Port' not in p[0]]
if len(ports) == 0:
print('No serial ports found. Is the board connected?')
return False
Expand Down

0 comments on commit 3a31748

Please sign in to comment.