Skip to content

Commit d7e152e

Browse files
committed
Use log_? instead of Serial.write
1 parent b85189c commit d7e152e

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

src/OpenBikeSensorFirmware.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -554,7 +554,7 @@ void loop() {
554554
}
555555
}
556556

557-
log_i("Time elapsed in loop: %lu milliseconds\n", currentTimeMillis - startTimeMillis);
557+
log_i("Time elapsed in loop: %lu milliseconds", currentTimeMillis - startTimeMillis);
558558
// synchronize to full measureIntervals
559559
startTimeMillis = (currentTimeMillis / measureInterval) * measureInterval;
560560
}

src/utils/file.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,17 +25,17 @@
2525

2626
bool FileUtil::appendFile(fs::FS &fs, const char * path, const char * message) {
2727
bool result = false;
28-
Serial.printf("Appending to file: %s\n", path);
28+
log_i("Appending to file: %s", path);
2929

3030
File file = fs.open(path, FILE_APPEND);
3131
if (!file) {
32-
Serial.println("Failed to open file for appending");
32+
log_e("Failed to open file for appending");
3333
return false;
3434
}
3535
if (file.print(message)) {
3636
result = true;
3737
} else {
38-
Serial.println("Append failed");
38+
log_e("Append failed");
3939
}
4040
file.close();
4141
return result;

src/utils/median.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ template<typename T> class Median {
3939
}
4040
};
4141
~Median() {
42-
Serial.printf("Will free Median(%d/%d) -> 0x%lx\n", size, mid, data);
42+
log_i("Will free Median(%d/%d) -> 0x%lx", size, mid, data);
4343
delete[] data;
4444
delete[] temp;
4545
};

0 commit comments

Comments
 (0)