GDP group 24 node core

Dependencies:   EthernetInterface SDFileSystem mbed-rtos mbed snail MbedJSONValue

Revision:
19:70c911d35e67
Parent:
0:fcab3b154e49
Child:
23:b57a47c7862a
--- a/sdcard.cpp	Tue Jan 13 23:38:55 2015 +0000
+++ b/sdcard.cpp	Tue Jan 13 23:40:29 2015 +0000
@@ -3,11 +3,7 @@
 #include <map>
 
 sdcard::sdcard(): sd(p5, p6, p7, p8, "sd")
-{
-    typeLookup[0x00] = "soil_con";
-    typeLookup[0x01] = "soil_temp";
-    typeLookup[0x02] = "amb_temp";
-    
+{   
     //first write sometimes fails, let's ensure the first write isn't real data
     FILE *fp = fopen("/sd/boot", "w");
     fprintf(fp, "boot");
@@ -21,9 +17,7 @@
     string sd_location ="";
     char time_s[64];
  
-    string l_type = typeLookup[data.type];
- 
-    sd_location = sd_name + l_type;
+    sd_location = sd_name + data.type;
     mkdir(sd_location.c_str(), 0777);
     
     sprintf(time_s, "%d", time);