Janely Santiago / Mbed 2 deprecated serial_e2

Dependencies:   mbed

Files at this revision

API Documentation at this revision

Comitter:
janely
Date:
Sun Apr 12 07:22:41 2020 +0000
Parent:
25:c9dced8fd392
Commit message:
Ejjercicio 3 P4

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/main.cpp	Sun Apr 12 06:59:51 2020 +0000
+++ b/main.cpp	Sun Apr 12 07:22:41 2020 +0000
@@ -2,6 +2,8 @@
 #include <mbed.h>
 #include<iostream>
 #define letra_a 97 
+#define letra_b 98 
+#define letra_c 99 
 
 using namespace std;
 Serial com1(USBTX,USBRX);
@@ -17,10 +19,17 @@
        
         if (letra == letra_a) 
         {
-            com1.printf("\nBuen dia");
+            com1.printf("\nHola");
         }
        
-       
+        if (letra == letra_b) 
+        {
+            com1.printf("\nQue tengas buen dia");
+        }
+         if (letra == letra_c) 
+        {
+            com1.printf("\nHasta luego");
+        }
     }