increase serial port rate to 115200kbps
authormegacz <adam@megacz.com>
Mon, 6 Apr 2009 18:48:04 +0000 (11:48 -0700)
committermegacz <adam@megacz.com>
Mon, 6 Apr 2009 18:48:04 +0000 (11:48 -0700)
ships/Debug.ship
src/edu/berkeley/fleet/fpga/Server.java

index 2c81785..e912f92 100644 (file)
@@ -70,7 +70,10 @@ public void service() {
   //   33.333Mhz / 38400hz * 4 = 217.013 => 215+2,1 => 215,1
   // using a 100Mhz clock,
   //   100Mhz / 38400hz * 4 = 651.039 => 215+2,3 => 215,3
-  sasc_brg sasc_brg(clk, !rst_in, 215, 3, sio_ce, sio_ce_x4);
+  // using a 100Mhz clock, 115200baud
+  //   100Mhz / 115200hz * 4 = 217.013 => 215+2,1 => 215,1
+//  sasc_brg sasc_brg(clk, !rst_in, 215, 3, sio_ce, sio_ce_x4);
+  sasc_brg sasc_brg(clk, !rst_in, 215, 1, sio_ce, sio_ce_x4);
   sasc_top sasc_top(clk, !rst_in,
                     uart_in,
                     uart_out,
index 62c4fd4..ae53589 100644 (file)
@@ -80,7 +80,8 @@ public class Server {
                     this.sp = new RXTXPort("/dev/ttyS0");
                     sp.setInputBufferSize(0);
                     sp.setOutputBufferSize(0);
-                    sp.setSerialPortParams(38400, SerialPort.DATABITS_8, SerialPort.STOPBITS_1, SerialPort.PARITY_NONE);
+                    //sp.setSerialPortParams(38400, SerialPort.DATABITS_8, SerialPort.STOPBITS_1, SerialPort.PARITY_NONE);
+                    sp.setSerialPortParams(115200, SerialPort.DATABITS_8, SerialPort.STOPBITS_1, SerialPort.PARITY_NONE);
                     //sp.setFlowControlMode(sp.FLOWCONTROL_RTSCTS_IN | sp.FLOWCONTROL_RTSCTS_OUT);
                     sp.setFlowControlMode(0);
                     try {