Michał Biolik / Mbed 2 deprecated SD_TUT

Dependencies:   EthernetInterface SDFileSystem mbed-rtos mbed

Revision:
1:58d2021e301d
Child:
2:e699312248f3
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/file_manager.hpp	Mon Dec 05 01:07:30 2016 +0000
@@ -0,0 +1,31 @@
+#include "mbed.h"
+#include <string>
+
+class file_manager
+{
+private:
+    FILE *fp;
+    string current_path;
+    string path_sisk;
+    string path_agh;
+    string path_krk;
+
+    void print_files(void);
+    void get_string(void);
+    bool open_file(char option);
+    bool close_file(void);
+public:
+    file_manager(void) :
+        current_path(this->path_sisk)
+    {
+        path_sisk = "/sisk.txt";
+        path_agh = "/agh.txt";
+        path_krk = "/krakow.txt";    
+    }
+
+    void get_path(void);
+    void set_path(void);
+    void write_to_file(void);
+    void append_to_file(void);
+    void read_file(void);
+};