Alarm Clock

Dependencies:   TextLCD mbed

Fork of SmartRise_MBED by Austin Sloop

Revision:
2:261fce57a100
Parent:
1:989eb818d3a3
Child:
3:51b248042aa0
--- a/main.cpp	Sun Jan 24 01:53:04 2016 +0000
+++ b/main.cpp	Sun Jan 24 02:03:50 2016 +0000
@@ -7,13 +7,15 @@
 TextLCD lcd(p27,p28,p23,p24,p25,p26);
 
 int main() {
-
+    int Ahr,Amin; 
     while(1) {
         time_t seconds = time(NULL);
         
+        Ahr=11;Amin=30;
         char buffer[32];
-        strftime(buffer, 32, "%a%m/%d %I:%M%p \n", localtime(&seconds));       //day, #month/#day Hr:min (AP)M
-        lcd.printf("%s", buffer);
+        strftime(buffer, 32, "%a%m/%d %I:%M%p", localtime(&seconds));       //day, #month/#day Hr:min (AP)M
+        wait(0.1);
+        lcd.printf("%s     Alarm:%I:%I", buffer, Ahr, Amin);
 
         wait(1);
     }