storing variables in single array for transmission
Dependencies: SDFileSystem dspmodified mbed
Fork of FTPGET_Merged by
Diff: merged_code.cpp
- Revision:
- 15:f2a7003fcea1
- Parent:
- 14:83b823fdcdd0
- Child:
- 16:622629b0cf3c
--- a/merged_code.cpp Mon Apr 06 12:09:20 2015 +0000 +++ b/merged_code.cpp Wed Apr 29 12:18:21 2015 +0000 @@ -633,6 +633,7 @@ //--------------------------------------------------------------------------------------------------// // FTP Connect function // //--------------------------------------------------------------------------------------------------// + bool ftp_connect() { int ftp_close_attempt=0; @@ -698,6 +699,7 @@ sprintf(ftpfilename,"%s",ftpget); // For Request of multiple file path logic refer abc.text sprintf(ftpfilepath,"%s",ftpget1); + sprintf(ftpputpathname,"%s/%02d%02d/%02d/%02d",module_name,year,month,date,hour); } else if (ftp_type==2) { @@ -789,6 +791,7 @@ } + //--------------------------------------------------------------------------------------------------// // FTP GET FUNCTION // //--------------------------------------------------------------------------------------------------// @@ -889,7 +892,7 @@ else { pc.printf("\r\n Deleting requested file\r\n"); - remove(removefile); + do_remove(removefile); pc.printf("\r\n File Deleted\r\n"); } } @@ -976,6 +979,7 @@ sampling(); store(); FTP_Fun(); + downloadFTP(); // For testing purpose if (old_hour!=100 && hour!=old_hour && hour<24) { pc.printf("\r\nhour changed"); @@ -985,7 +989,7 @@ sprintf(pathfft,"%s",timestamppath_old); ftp_put(0); } - downloadFTP(); // For FTPGET Function + //downloadFTP(); // For FTPGET Function } pc.printf("\r\n Complete Done"); old_hour=hour;