main: move startup strings to flash

This commit is contained in:
Torrie Fischer 2023-12-20 12:11:49 +01:00
parent 6df7e938cb
commit 924673ada3

View File

@ -83,24 +83,24 @@ MainLoop* runner = &SafeMode::safeModeApp;
void setup() {
// Turn on,
Platform::preSetup();
Log.notice(u8"🐛 Booting Renderbug!");
Log.notice(u8"🐞 I am built for %d LEDs on pin %d", HardwareConfig::MAX_LED_NUM, RENDERBUG_LED_PIN);
Log.notice(u8"📡 Platform %s version %s", Platform::name(), Platform::version());
Log.notice(F(u8"\n\n\n🐛 Booting Renderbug!"));
Log.notice(F(u8"🐞 I am built for %d LEDs on pin %d"), HardwareConfig::MAX_LED_NUM, RENDERBUG_LED_PIN);
Log.notice(F(u8"📡 Platform %s version %s"), Platform::name(), Platform::version());
Log.notice(u8"Setting timezone to +2 (CEST)");
Log.notice(F(u8"Setting timezone to +2 (CEST)"));
Platform::setTimezone(+1);
Log.trace(u8"Setting up platform...");
Log.trace(F(u8"Setting up platform..."));
Platform::setup();
Platform::bootSplash();
Log.notice(u8"💡 Starting FastLED on %d LEDs...", HardwareConfig::MAX_LED_NUM);
Log.notice(F(u8"💡 Starting FastLED on %d LEDs..."), HardwareConfig::MAX_LED_NUM);
Platform::addLEDs(leds, HardwareConfig::MAX_LED_NUM);
// Tune in,
if (Platform::bootopts.isSafeMode) {
Log.warning(u8"⚠️ Starting Figment in safe mode!!!");
Log.warning(F(u8"⚠️ Starting Figment in safe mode!!!"));
runner = &SafeMode::safeModeApp;
for(auto task : runner->scheduler.tasks) {
task->state = Task::Running;
@ -108,10 +108,10 @@ void setup() {
FastLED.showColor(CRGB(255, 0, 0));
FastLED.show();
} else {
Log.notice(u8"🌌 Starting Figment...");
Log.notice(F(u8"🌌 Starting Figment..."));
if (Platform::bootopts.isSetup) {
Log.warning(u8"🔧 Booting up into setup profile!!!");
Log.warning(F(u8"🔧 Booting up into setup profile!!!"));
Static<ConfigService>::instance()->overrideProfile("setup");
}
@ -124,8 +124,8 @@ void setup() {
Serial.flush();
runner->start();
Log.notice(u8"💽 %l bytes of free RAM", Platform::freeRam());
Log.notice(u8"🚀 Setup complete! Ready to rock and roll.");
Log.notice(F(u8"💽 %l bytes of free RAM"), Platform::freeRam());
Log.notice(F(u8"🚀 Setup complete! Ready to rock and roll."));
Serial.flush();
}