Take anycubic's approach to implement power outage support. SD card wearing can be prevented by disabling it via POWER_OUTAGE_TEST flag.

This commit is contained in:
Knutwurst
2020-06-11 15:36:23 +02:00
parent a52dc3c7e9
commit d090049594
7 changed files with 134 additions and 32 deletions

View File

@@ -27,6 +27,15 @@
#include "../HAL/shared/eeprom_api.h"
#endif
#ifdef POWER_OUTAGE_TEST
static bool RestartFlag = false;
void OutageSave();
void OutageRead();
extern float last_position[4];
extern long last_sd_position[1];
#endif
class MarlinSettings {
public:
static uint16_t datasize();