Kojo / Mbed 2 deprecated IF-SmartClock

Dependencies:   AlarmClock DigitalClock EthernetInterface FourDigitLED HTTPClient NTPClient SDFileSystem TrainStat WeatherInfo XML_aide mbed-rtos mbed picojson wolfSSL

Files at this revision

API Documentation at this revision

Comitter:
takashikojo
Date:
Sat Jun 27 06:20:59 2015 +0000
Parent:
2:bcc1a40ffa04
Child:
4:8a2d1544d6e0
Commit message:
Added yahoo Train

Changed in this revision

TrainStat.lib Show annotated file Show diff for this revision Revisions of this file
XMLaide.lib Show annotated file Show diff for this revision Revisions of this file
main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/TrainStat.lib	Fri Jun 26 09:35:53 2015 +0000
+++ b/TrainStat.lib	Sat Jun 27 06:20:59 2015 +0000
@@ -1,1 +1,1 @@
-TrainStat#a59f55690685
+TrainStat#26a0a9220f01
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/XMLaide.lib	Sat Jun 27 06:20:59 2015 +0000
@@ -0,0 +1,1 @@
+XMLaide#369a19fba8a4
--- a/main.cpp	Fri Jun 26 09:35:53 2015 +0000
+++ b/main.cpp	Sat Jun 27 06:20:59 2015 +0000
@@ -11,7 +11,7 @@
     /* Alarm, Hour, Min, Tone */D13, D14, D15, PTC11
 )  ;
 
-TrainStat trainstat ;
+TrainStat trainstat(YAHOO_TRAIN) ;
 
 static void ntp(char *site)
 {
@@ -29,20 +29,19 @@
 
 void clock_main(void const *av)
 {
-    ntp("ntp.jst.mfeed.ad.jp") ;
+
     alarmclock.start() ; 
     while(1){        
         alarmclock.poll() ;
         Thread::wait(100);
     } 
 }
-
+ 
 void net_main(void const *av)
 {
     bool sw ;
 
     trainstat.setLine("千代田線") ;
-    wait(2.0) ;
     while(1) {
         sw = !sw ;
         if(!trainstat.getStat())
@@ -65,7 +64,8 @@
         if(ret == 0)break ;
         Thread::wait(10);
     }
-    
+    ntp("ntp.jst.mfeed.ad.jp") ;
+
     #define NET_STACK   16000
     Thread t_clock(clock_main, NULL, osPriorityNormal);
     Thread t_net  (net_main,   NULL, osPriorityNormal, NET_STACK  );