Rev 146 | Rev 171 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 146 | Rev 159 | ||
---|---|---|---|
Line 436... | Line 436... | ||
436 | logmodule = 0; |
436 | logmodule = 0; |
437 | break; |
437 | break; |
438 | } |
438 | } |
439 | } |
439 | } |
440 | else // a logging error has occured |
440 | else // a logging error has occured |
441 | { |
- | |
442 | if(Fat16_IsValid()) // wait for reinizialization of fat16 from outside |
441 | { // try to reinitialize sd-card when motors are not running |
- | 442 | if(!(FC.MKFlags & MKFLAG_MOTOR_RUN)) |
|
443 | { |
443 | { |
- | 444 | if(Fat16_IsValid()) // wait for reinizialization of fat16 from outside |
|
- | 445 | { |
|
444 | Logging_Init(); // initialize the logs |
446 | Logging_Init(); // initialize the logs |
445 | logstate = LOGFILE_IDLE; |
447 | logstate = LOGFILE_IDLE; |
446 | logtimer = SetDelay(10); // try next log in 10 mili sec |
448 | logtimer = SetDelay(10); // try next log in 10 mili sec |
447 | } |
449 | } |
448 | else |
450 | else |
449 | { // retry in 5 seconds |
451 | { // retry in 5 seconds |
450 | logtimer = SetDelay(5000); // try again in 5 sec |
452 | logtimer = SetDelay(5000); // try again in 5 sec |
451 | } |
453 | } |
- | 454 | } // EOF motors are not running |
|
452 | } //EOF logfile error |
455 | } //EOF logfile error |
453 | } // EOF CheckDelay |
456 | } // EOF CheckDelay |
454 | }// EOF Card in Slot |
457 | }// EOF Card in Slot |
455 | } |
458 | } |