set baud rate through API
This commit is contained in:
+2
-2
@@ -41,8 +41,8 @@ namespace Logger {
|
|||||||
out().print(buffer);
|
out().print(buffer);
|
||||||
}
|
}
|
||||||
|
|
||||||
void Initialize(int8_t rx, int8_t tx) {
|
void Initialize(int8_t rx, int8_t tx, int baud) {
|
||||||
Serial2.begin(115200, SERIAL_8N1, rx, tx);
|
Serial2.begin(baud, SERIAL_8N1, rx, tx);
|
||||||
Serial2.flush();
|
Serial2.flush();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
+1
-1
@@ -71,7 +71,7 @@ namespace Logger {
|
|||||||
Trace = LOG_LEVEL_TRACE
|
Trace = LOG_LEVEL_TRACE
|
||||||
};
|
};
|
||||||
|
|
||||||
void Initialize(int8_t rx, int8_t tx);
|
void Initialize(int8_t rx, int8_t tx, int baud);
|
||||||
|
|
||||||
void WritePrefix(LogLevel lvl);
|
void WritePrefix(LogLevel lvl);
|
||||||
void VPrintf(const char* fmt, va_list args);
|
void VPrintf(const char* fmt, va_list args);
|
||||||
|
|||||||
Reference in New Issue
Block a user