You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -319,14 +327,15 @@ uint64_t measurementStartTime; //Used to calc the actual update rate. Max is ~80
319
327
uint64_t lastSDFileNameChangeTime; //Used to calculate the interval since the last SD filename change
320
328
unsignedlong measurementCount = 0; //Used to calc the actual update rate.
321
329
unsignedlong measurementTotal = 0; //The total number of recorded measurements. (Doesn't get reset when the menu is opened)
322
-
charoutputData[512 * 2]; //Factor of 512 for easier recording to SD in 512 chunks
330
+
charsdOutputData[512 * 2]; //Factor of 512 for easier recording to SD in 512 chunks
323
331
unsignedlong lastReadTime = 0; //Used to delay until user wants to record a new reading
324
332
unsignedlong lastDataLogSyncTime = 0; //Used to record to SD every half second
325
333
unsignedint totalCharactersPrinted = 0; //Limit output rate based on baud rate and number of characters to print
326
334
bool takeReading = true; //Goes true when enough time has passed between readings or we've woken from sleep
327
335
bool sleepAfterRead = false; //Used to keep the code awake for at least minimumAwakeTimeMillis
328
336
constuint64_t maxUsBeforeSleep = 2000000ULL; //Number of us between readings before sleep is activated.
329
337
const byte menuTimeout = 15; //Menus will exit/timeout after this number of seconds
338
+
constint sdCardMenuTimeout = 60; // sdCard menu will exit/timeout after this number of seconds
330
339
volatilestaticbool stopLoggingSeen = false; //Flag to indicate if we should stop logging
331
340
uint64_t qwiicPowerOnTime = 0; //Used to delay after Qwiic power on to allow sensors to power on, then answer autodetect
332
341
unsignedlong qwiicPowerOnDelayMillis; //Wait for this many milliseconds after turning on the Qwiic power before attempting to communicate with Qwiic devices
@@ -711,26 +720,26 @@ void loop() {
711
720
}
712
721
#endif
713
722
714
-
getData(outputData, sizeof(outputData)); //Query all enabled sensors for data
723
+
getData(sdOutputData, sizeof(sdOutputData)); //Query all enabled sensors for data
715
724
716
725
//Print to terminal
717
726
if (settings.enableTerminalOutput == true)
718
-
SerialPrint(outputData); //Print to terminal
727
+
SerialPrint(sdOutputData); //Print to terminal
719
728
720
729
//Output to TX pin
721
730
if ((settings.outputSerial == true) && (online.serialOutput == true))
722
-
Serial1.print(outputData); //Print to TX pin
731
+
Serial1.print(sdOutputData); //Print to TX pin
723
732
724
733
//Record to SD
725
734
if ((settings.logData == true) && (online.microSD))
0 commit comments