summaryrefslogtreecommitdiff
path: root/examples/device
diff options
context:
space:
mode:
authorhathach <[email protected]>2025-07-02 17:27:03 +0700
committerhathach <[email protected]>2025-07-02 17:27:03 +0700
commita64e3eb0aa661db14eb647e2f75059815741112f (patch)
treedf861940fe70ae28136ebe966b48bd1622195514 /examples/device
parent52f0427096a9e20b62dc3055a153a60e50317297 (diff)
update board_test always output to uart regardless of LOGGER option
Diffstat (limited to 'examples/device')
-rw-r--r--examples/device/board_test/src/main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/examples/device/board_test/src/main.c b/examples/device/board_test/src/main.c
index 2c6ab6288..d91a8760e 100644
--- a/examples/device/board_test/src/main.c
+++ b/examples/device/board_test/src/main.c
@@ -52,6 +52,9 @@ int main(void) {
int ch = board_getchar();
if (ch > 0) {
board_putchar(ch);
+ #ifndef LOGGER_UART
+ board_uart_write(&ch, 1);
+ #endif
}
// Blink and print every interval ms
@@ -61,7 +64,10 @@ int main(void) {
if (ch < 0) {
// skip if echoing
printf(HELLO_STR);
+
+ #ifndef LOGGER_UART
board_uart_write(HELLO_STR, strlen(HELLO_STR));
+ #endif
}
board_led_write(led_state);