Fix port autodececting without hwid

This commit is contained in:
Valeriy Koval
2016-04-25 20:35:57 +03:00
parent 12ef1b26bf
commit d1f4f82897

View File

@ -88,7 +88,7 @@ def AutodetectUploadPort(env):
if "VID:PID" not in item['hwid']:
continue
env.Replace(UPLOAD_PORT=item['port'])
for hwid in board_build_opts.get("hwid"):
for hwid in board_build_opts.get("hwid", []):
board_hwid = ("%s:%s" % (hwid[0], hwid[1])).replace("0x", "")
if board_hwid in item['hwid']:
break