File tree Expand file tree Collapse file tree 2 files changed +17
-1
lines changed Expand file tree Collapse file tree 2 files changed +17
-1
lines changed Original file line number Diff line number Diff line change 75
75
// LOG_LEVEL_WARNING, LOG_LEVEL_NOTICE, LOG_LEVEL_VERBOSE
76
76
#define LOG_LEVEL LOG_LEVEL_VERBOSE
77
77
78
+ // Enable if you're having issues with the app outputting garbage characters on startup, delay in ms
79
+ // #define SERIAL_INTERFACE_INIT_DELAY 4000
80
+
78
81
// if not defined, then no memory debugging is emitted
79
82
// #define MEMORY_DEBUG_INTERVAL 5000
80
83
Original file line number Diff line number Diff line change @@ -46,11 +46,24 @@ void addWidgets() {
46
46
void setup () {
47
47
// Initialize global resources
48
48
initializeGlobalResources ();
49
+
50
+ #ifdef SERIAL_INTERFACE_INIT_DELAY
51
+ // Add a delay to allow the serial interface to initialize
52
+ delay (SERIAL_INTERFACE_INIT_DELAY);
53
+ #endif
54
+
49
55
Serial.begin (115200 );
56
+
57
+ // Clear the serial buffer of any garbage
58
+ while (Serial.available () > 0 ) {
59
+ Serial.read ();
60
+ }
61
+
50
62
Log.begin (LOG_LEVEL, &Serial);
51
- Log.noticeln (" Starting up..." );
63
+ Log.noticeln (" 🚀 Starting up..." );
52
64
Log.noticeln (" PCB Version: %s" , PCB_VERSION);
53
65
66
+
54
67
wifiManager = new OrbsWiFiManager ();
55
68
config = new ConfigManager (*wifiManager);
56
69
sm = new ScreenManager (tft);
You can’t perform that action at this time.
0 commit comments