Browse Source

Merge branch 'dev_x6500' into bfgminer

Luke Dashjr 13 years ago
parent
commit
1871e2d36c
2 changed files with 7 additions and 4 deletions
  1. 3 1
      ft232r.c
  2. 4 3
      miner.c

+ 3 - 1
ft232r.c

@@ -77,8 +77,10 @@ void ft232r_scan()
 			applog(LOG_ERR, "ft232r_scan: Error getting device descriptor: %s", libusb_error_name(err));
 			applog(LOG_ERR, "ft232r_scan: Error getting device descriptor: %s", libusb_error_name(err));
 			continue;
 			continue;
 		}
 		}
-		if (!(desc.idVendor == FT232R_IDVENDOR && desc.idProduct == FT232R_IDPRODUCT))
+		if (!(desc.idVendor == FT232R_IDVENDOR && desc.idProduct == FT232R_IDPRODUCT)) {
+			applog(LOG_DEBUG, "ft232r_scan: Found %04x:%04x - not a ft232r", desc.idVendor, desc.idProduct);
 			continue;
 			continue;
+		}
 
 
 		err = libusb_open(list[i], &handle);
 		err = libusb_open(list[i], &handle);
 		if (unlikely(err)) {
 		if (unlikely(err)) {

+ 4 - 3
miner.c

@@ -7364,9 +7364,6 @@ int main(int argc, char *argv[])
 #ifdef HAVE_LIBUSB
 #ifdef HAVE_LIBUSB
         libusb_init(NULL);
         libusb_init(NULL);
 #endif
 #endif
-#ifdef USE_X6500
-	ft232r_scan();
-#endif
 
 
 	mutex_init(&hash_lock);
 	mutex_init(&hash_lock);
 	mutex_init(&qd_lock);
 	mutex_init(&qd_lock);
@@ -7484,6 +7481,10 @@ int main(int argc, char *argv[])
 		successful_connect = true;
 		successful_connect = true;
 	}
 	}
 
 
+#ifdef USE_X6500
+	ft232r_scan();
+#endif
+
 #ifdef HAVE_CURSES
 #ifdef HAVE_CURSES
 	if (opt_realquiet || devices_enabled == -1)
 	if (opt_realquiet || devices_enabled == -1)
 		use_curses = false;
 		use_curses = false;