From e1f81b04e8086432d010a8aa6919300bb6826a20 Mon Sep 17 00:00:00 2001 From: adam Date: Wed, 20 Sep 2006 09:50:21 +0100 Subject: [PATCH] checkpoint --- src/com/ftdi/usb/FtdiUart.java | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/src/com/ftdi/usb/FtdiUart.java b/src/com/ftdi/usb/FtdiUart.java index 026ac9e..51007f5 100644 --- a/src/com/ftdi/usb/FtdiUart.java +++ b/src/com/ftdi/usb/FtdiUart.java @@ -3,7 +3,6 @@ import java.io.*; public class FtdiUart { - protected int bits = 0; protected SWIGTYPE_p_ftdi_context context = example.new_ftdi_context(); public OutputStream getOutputStream() { return out; } @@ -31,19 +30,11 @@ public class FtdiUart { } catch (Exception e) { throw new RuntimeException(e); } } - protected static int mask = - (1<<0) | - (1<<1)// | - //(1<<2) | - //(1<<3) - ; - public synchronized void purge() { example.ftdi_usb_purge_buffers(context); } - public synchronized void uart(int mask, int bits) { - example.ftdi_set_bitmode(context, (short)((mask << 4) | bits), (short)0x20); - //example.ftdi_setflowctrl(context, (1 << 8)); + public synchronized void uart(int cbus_mask, int cbus_bits) { + example.ftdi_set_bitmode(context, (short)((cbus_mask << 4) | cbus_bits), (short)0x20); } public synchronized void dbangmode(int dmask) { example.ftdi_set_bitmode(context, (short)dmask, (short)0x01); -- 1.7.10.4