Fix for Windows NT machines with non-FTDI serial ports.
authortravisutk <travisutk@12e2690d-a6be-4b82-a7b7-67c4a43b65c8>
Mon, 7 Jun 2010 18:43:24 +0000 (18:43 +0000)
committertravisutk <travisutk@12e2690d-a6be-4b82-a7b7-67c4a43b65c8>
Mon, 7 Jun 2010 18:43:24 +0000 (18:43 +0000)
The new py2exe build should be published ASAP.

git-svn-id: https://svn.code.sf.net/p/goodfet/code/trunk@607 12e2690d-a6be-4b82-a7b7-67c4a43b65c8

client/GoodFET.py
client/goodfet.bsl

index ab6ac30..d97fb94 100755 (executable)
@@ -93,10 +93,13 @@ class GoodFET:
             from scanwin32 import winScan;
             scan=winScan();
             for order,comport,desc,hwid in sorted(scan.comports()):
-                if hwid.index('FTDI')==0:
-                    port=comport;
-                    #print "Using FTDI port %s" % port
-        
+                try:
+                    if hwid.index('FTDI')==0:
+                        port=comport;
+                        #print "Using FTDI port %s" % port
+                except:
+                    #Do nothing.
+                    a=1;
         
         self.serialport = serial.Serial(
             port,
index dc5fd87..949c431 100755 (executable)
@@ -1402,11 +1402,13 @@ def main(itest=1):
             from scanwin32 import winScan;
             scan=winScan();
             for order,comport,desc,hwid in sorted(scan.comports()):
-                if hwid.index('FTDI')==0:
-                    comPort=comport;
-                    #print "Using FTDI port %s" % port
-        
-    
+                try:
+                    if hwid.index('FTDI')==0:
+                        comPort=comport;
+                        #print "Using FTDI port %s" % port
+                except:
+                    #Do nothing.
+                    a=1;
     sys.stderr.write("MSP430 Bootstrap Loader Version: %s\n" % VERSION)
 
     try: