aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c
diff options
context:
space:
mode:
authorShlomo Hecht <shlomo@twine-s.com>2018-11-25 21:55:23 +0000
committerShlomo Hecht <shlomo@twine-s.com>2018-11-25 21:55:23 +0000
commit55df821e937afba3a3284ee17d9428b1c20be310 (patch)
tree86ef22ce26297a150e42e6dbd48fb484b679051c /Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c
parent4fc8e8b16a1eda84e5a9b753f966843712f0b219 (diff)
downloadTango-55df821e937afba3a3284ee17d9428b1c20be310.tar.gz
Tango-55df821e937afba3a3284ee17d9428b1c20be310.zip
Updated FileSystem.c
Diffstat (limited to 'Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c')
-rw-r--r--Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c
index 94699205b..e2a84a0ec 100644
--- a/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c
+++ b/Software/Embedded_SW/Embedded/Common/SWUpdate/FileSystem.c
@@ -41,6 +41,17 @@ int FileReceivedLength = 0;
static char g_cCwdBuf[50] = "/";
uint32_t WrittenBytes = 0;
+
+ErrorCode getErrorCode(FRESULT Fresult)
+{
+ switch (Fresult)
+ {
+ case FR_OK:
+ retrun ERROR_CODE_NONE;
+ default:
+ return ERROR_CODE__FILE_LENGTH_OUT_OF_RANGE;
+ }
+}
bool isDirectory(FileAttribute FileAtt)
{
if (FileAtt&&FILE_ATTRIBUTE__Directory)