CECS 447 Team Pair (Loc/Ivan) / Mbed 2 deprecated project2_uart

Dependencies:   mbed

Revision:
0:3467a96a77d0
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Mon Sep 28 23:03:06 2015 +0000
@@ -0,0 +1,25 @@
+#include "mbed.h"
+Serial pc(USBTX, USBRX); // tx, rx
+int main()
+{
+    char in_bound;
+    pc.baud(19200);
+    pc.printf("Welcome to the Diamond Dogs intercom!\n\r What would you like to transmit to Venom Snake?/n/r");
+    while(1) {
+        pc.printf("(:D) ");
+        
+        in_bound = pc.getc();
+        if(in_bound == '\r')
+        {
+            pc.printf("\n\r");   
+        }
+        else if (in_bound == '*')
+        {
+            pc.printf("Loc and Ivan's hometown: Garden Grove");   
+        }
+        else 
+            pc.putc(in_bound);
+        
+                    
+    }    
+ }       
\ No newline at end of file