fix sync bitbang read-timing
authorGerd v. Egidy <gerd.von.egidy@intra2net.com>
Sun, 6 Dec 2009 20:03:03 +0000 (21:03 +0100)
committerGerd v. Egidy <gerd.von.egidy@intra2net.com>
Sun, 6 Dec 2009 20:03:03 +0000 (21:03 +0100)
examples/baud_test.c

index 029164a..4a7d4d5 100644 (file)
@@ -167,6 +167,10 @@ int main(int argc, char **argv)
 
     start=get_prec_time();
 
+    // don't wait for more data to arrive, take what we get and keep on sending
+    // yes, we really would like to have libusb 1.0+ with async read/write...
+    ftdic.usb_read_timeout=1;
+
     i=0;
     while(i < datasize)
     {