bpmpfw uart changes

This commit is contained in:
souldbminersmwc committed 2026-08-28 14:45:37 -04:00
1 parent 6b88b43cb9
commit 4ac7f472d9
3 files changed
+17 -4

No files matched your search

+12 -1
View File
@@ -33,7 +33,7 @@
}
}
bool g_uartLoggingEnabled = true;
bool g_uartLoggingEnabled = false;
void UartPutc(char c) {
if (!g_uartLoggingEnabled) {
@@ -64,3 +64,14 @@ void UartPutHex32(u32 v) {
UartPutc(digits[(v >> i) & 0xF]);
}
}
void UartPutsForce(const char *s) {
while (*s) {
while (!(MMIO32(UartBBase + UartLsr) & UartLsrThre))
;
MMIO32(UartBBase + UartThr) = static_cast<u32>(static_cast<u8>(*s++));
}
while (!(MMIO32(UartBBase + UartLsr) & UartLsrTmty))
;
}