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:
@@ -153,6 +153,7 @@ public:
|
||||
static inline int16_t get() { sdpos = file.curPosition(); return (int16_t)file.read(); }
|
||||
static inline int16_t read(void* buf, uint16_t nbyte) { return file.isOpen() ? file.read(buf, nbyte) : -1; }
|
||||
static inline int16_t write(void* buf, uint16_t nbyte) { return file.isOpen() ? file.write(buf, nbyte) : -1; }
|
||||
static inline long GetLastSDpos() { return sdpos; };
|
||||
|
||||
static Sd2Card& getSd2Card() { return sd2card; }
|
||||
|
||||
|
Reference in New Issue
Block a user