SERIAL BRIDGE

Dependencies:   mbed

Revision:
0:0669f963d466
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Wed Jun 15 18:47:42 2016 +0000
@@ -0,0 +1,25 @@
+
+#include "mbed.h"
+Serial device(PC_10,PC_11);   
+Serial pc(USBTX,USBRX);     
+
+int main() 
+{   
+    device.baud(9600);      
+    pc.baud(9600);
+    
+    while(1) 
+    {
+      
+      if(device.readable())        
+      {
+         pc.putc(device.getc());   
+      }
+     
+      if(pc.readable())          
+      {
+        device.putc(pc.getc());    
+      }
+      
+    }
+}