cansat_B 2019 / Mbed 2 deprecated tougou-no3

Dependencies:   mbed

Revision:
6:cf43f62b1e75
Parent:
5:9b5899b06e2e
Child:
7:a47fdb7f9bc8
--- a/main.cpp	Fri Nov 29 19:08:28 2019 +0000
+++ b/main.cpp	Mon Dec 02 07:39:27 2019 +0000
@@ -98,6 +98,22 @@
                     fclose(fp);
                 }
                 }
+                 for(int i=0;i<2;i++) {
+        
+        int received_data = xbee.getc();
+   
+     if (received_data == 82 || received_data == 114){  //Rまたはr
+        xbee.printf("_________________________________________________________________________________________________________________________________\r\n");
+         if((fp=fopen("/local/d.txt","r"))!=NULL)
+            {
+                while ((c=fgetc(fp))!=EOF){
+                xbee.printf("%c",c);                    //再送
+                
+                }
+                fclose(fp);
+            }
+        }
+    }
                
               }else{//焦電反応なしの場合
               printf("not found!\r\n");