From 77dd1c4b568435a56048f0627e94add5a1b178f5 Mon Sep 17 00:00:00 2001 From: schneider Date: Thu, 22 Dec 2011 03:02:45 +0100 Subject: [PATCH] removed fs errors from exports and filetransfer, saves 260 bytes --- firmware/basic/basic.c | 4 ++++ firmware/basic/basic.h | 1 + firmware/funk/filetransfer.c | 3 ++- firmware/l0dable/EXPORTS | 4 ++-- firmware/l0dable/recvcard.c | 3 ++- 5 files changed, 11 insertions(+), 4 deletions(-) diff --git a/firmware/basic/basic.c b/firmware/basic/basic.c index bcc0d75..51c1950 100644 --- a/firmware/basic/basic.c +++ b/firmware/basic/basic.c @@ -105,3 +105,7 @@ void PIOINT3_IRQHandler(void) { } } +void notimplemented(void) +{ + while(1); +} diff --git a/firmware/basic/basic.h b/firmware/basic/basic.h index 2c84047..4025232 100644 --- a/firmware/basic/basic.h +++ b/firmware/basic/basic.h @@ -213,6 +213,7 @@ const char* IntToStr(int num, unsigned int mxlen, char flag); #define WFI delayms(SYSTICKSPEED) #endif +void notimplemented(void); #endif diff --git a/firmware/funk/filetransfer.c b/firmware/funk/filetransfer.c index 375d4cd..0809322 100644 --- a/firmware/funk/filetransfer.c +++ b/firmware/funk/filetransfer.c @@ -90,7 +90,8 @@ int filetransfer_receive(uint8_t *mac, uint32_t const k[4]) res = f_open(&file, (const char*)metadata, FA_OPEN_ALWAYS|FA_WRITE); //lcdPrintln("file opened"); lcdRefresh(); - if( res ) {lcdPrintln("res"); lcdPrint(f_get_rc_string(res)); lcdRefresh(); while(1);} + //if( res ) {lcdPrintln("res"); lcdPrint(f_get_rc_string(res)); lcdRefresh(); while(1);} + if( res ){ lcdPrintln("file error"); lcdRefresh(); while(1);} if( res ) return res; diff --git a/firmware/l0dable/EXPORTS b/firmware/l0dable/EXPORTS index 4706950..8b65dc9 100644 --- a/firmware/l0dable/EXPORTS +++ b/firmware/l0dable/EXPORTS @@ -38,7 +38,8 @@ ECIES_encyptkeygen bitstr_parse_export #fs f_close -f_get_rc_string +#f_get_rc_string +notimplemented f_lseek f_open f_read @@ -126,4 +127,3 @@ timer32Callback0 lcdRead lcdInit lcdSetCrsr - diff --git a/firmware/l0dable/recvcard.c b/firmware/l0dable/recvcard.c index 8e77e21..08e0162 100644 --- a/firmware/l0dable/recvcard.c +++ b/firmware/l0dable/recvcard.c @@ -251,7 +251,8 @@ int filetransfer_receive(uint8_t *mac, uint32_t const k[4]) res = f_open(&file, (const char*)metadata, FA_OPEN_ALWAYS|FA_WRITE); //lcdPrintln("file opened"); lcdRefresh(); - if( res ) {lcdPrintln("res"); lcdPrint(f_get_rc_string(res)); lcdRefresh(); while(1);} + //if( res ) {lcdPrintln("res"); lcdPrint(f_get_rc_string(res)); lcdRefresh(); while(1);} + if( res ){ lcdPrintln("file error"); lcdRefresh(); while(1);} if( res ) return res;