merge upstream/master: logging pragma, screenshot retrieval, nbsp fix
Merge 3 upstream commits into mod/master: - feat: Allow screenshot retrieval from device (#820) - feat: Add central logging pragma (#843) - fix: Account for nbsp character as non-breaking space (#757) Conflict resolution: - src/main.cpp: kept mod's HalPowerManager + upstream's Logging/screenshot - SleepActivity.cpp: kept mod's letterbox fill rework, applied LOG_* pattern Additional changes for logging compatibility: - Converted remaining Serial.printf calls in mod files to LOG_* macros (HalPowerManager, BookSettings, BookmarkStore, GfxRenderer) - Added ENABLE_SERIAL_LOG and LOG_LEVEL=2 to [env:mod] build flags Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
#include "CrossPointSettings.h"
|
||||
|
||||
#include <HalStorage.h>
|
||||
#include <HardwareSerial.h>
|
||||
#include <Logging.h>
|
||||
#include <Serialization.h>
|
||||
|
||||
#include <cstring>
|
||||
@@ -122,7 +122,7 @@ bool CrossPointSettings::saveToFile() const {
|
||||
// New fields added at end for backward compatibility
|
||||
outputFile.close();
|
||||
|
||||
Serial.printf("[%lu] [CPS] Settings saved to file\n", millis());
|
||||
LOG_DBG("CPS", "Settings saved to file");
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -135,7 +135,7 @@ bool CrossPointSettings::loadFromFile() {
|
||||
uint8_t version;
|
||||
serialization::readPod(inputFile, version);
|
||||
if (version != SETTINGS_FILE_VERSION) {
|
||||
Serial.printf("[%lu] [CPS] Deserialization failed: Unknown version %u\n", millis(), version);
|
||||
LOG_ERR("CPS", "Deserialization failed: Unknown version %u", version);
|
||||
inputFile.close();
|
||||
return false;
|
||||
}
|
||||
@@ -238,7 +238,7 @@ bool CrossPointSettings::loadFromFile() {
|
||||
}
|
||||
|
||||
inputFile.close();
|
||||
Serial.printf("[%lu] [CPS] Settings loaded from file\n", millis());
|
||||
LOG_DBG("CPS", "Settings loaded from file");
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user