checkpoint
[slipway.git] / src / edu / berkeley / obits / device / atmel / FtdiChip.java
index 828c1a2..94d860f 100644 (file)
@@ -13,6 +13,7 @@ public class FtdiChip {
     public FtdiChip() {
         example.ftdi_init(context);
         example.ftdi_usb_open(context, 0x6666, 0x3133);
+        example.ftdi_usb_reset(context);
         example.ftdi_set_baudrate(context, 750 * 1000);
         example.ftdi_set_line_property(context, 8, 0, 0);
     }
@@ -95,7 +96,7 @@ public class FtdiChip {
             }
         };
 
-    private final OutputStream out = new OutputStream() {
+    private final OutputStream out = new BufferedOutputStream(new OutputStream() {
             public void write(int b) throws IOException {
                 byte[] d = new byte[1];
                 d[0] = (byte)b;
@@ -113,5 +114,5 @@ public class FtdiChip {
                     len -= result;
                 }
             }
-        };
+        });
 }