disabled debug output from saveConfig

This commit is contained in:
schneider 2011-12-18 04:17:21 +01:00
parent 5a4fde88fc
commit 64cb749c89
1 changed files with 10 additions and 1 deletions

View File

@ -56,12 +56,15 @@ int saveConfig(void){
UINT writebytes; UINT writebytes;
UINT allwrite=0; UINT allwrite=0;
int res; int res;
#if DEBUG
lcdClear(); lcdClear();
#endif
res=f_open(&file, CONFFILE, FA_OPEN_ALWAYS|FA_WRITE); res=f_open(&file, CONFFILE, FA_OPEN_ALWAYS|FA_WRITE);
#if DEBUG
lcdPrint("create:"); lcdPrint("create:");
lcdPrintln(f_get_rc_string(res)); lcdPrintln(f_get_rc_string(res));
#endif
if(res){ if(res){
return 1; return 1;
}; };
@ -70,20 +73,26 @@ int saveConfig(void){
res = f_write(&file, &the_config[i].value, sizeof(uint8_t), &writebytes); res = f_write(&file, &the_config[i].value, sizeof(uint8_t), &writebytes);
allwrite+=writebytes; allwrite+=writebytes;
if(res){ if(res){
#if DEBUG
lcdPrint("write:"); lcdPrint("write:");
lcdPrintln(f_get_rc_string(res)); lcdPrintln(f_get_rc_string(res));
#endif
return 1; return 1;
}; };
}; };
#if DEBUG
lcdPrint("write:"); lcdPrint("write:");
lcdPrintln(f_get_rc_string(res)); lcdPrintln(f_get_rc_string(res));
lcdPrint(" ("); lcdPrint(" (");
lcdPrintInt(allwrite); lcdPrintInt(allwrite);
lcdPrintln("b)"); lcdPrintln("b)");
#endif
res=f_close(&file); res=f_close(&file);
#if DEBUG
lcdPrint("close:"); lcdPrint("close:");
lcdPrintln(f_get_rc_string(res)); lcdPrintln(f_get_rc_string(res));
#endif
if(res){ if(res){
return 1; return 1;
}; };