Skip to content

Commit c4506ed

Browse files
committed
esp8266: Let esp8266 "os" messages go to standard (REPL) UART.
That's definitely helpful for debugging.
1 parent 402a743 commit c4506ed

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

esp8266/Makefile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,9 @@ INC += -I../lib/timeutils
2323
INC += -I$(BUILD)
2424
INC += -I$(ESP_SDK)/include
2525

26-
UART_OS = 1
26+
# UART for "os" messages. 0 is normal UART as used by MicroPython REPL,
27+
# 1 is debug UART (tx only).
28+
UART_OS = 0
2729

2830
CFLAGS_XTENSA = -fsingle-precision-constant -Wdouble-promotion \
2931
-D__ets__ -DICACHE_FLASH \

esp8266/uart.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ void ICACHE_FLASH_ATTR uart_init(UartBautRate uart0_br, UartBautRate uart1_br) {
205205
uart_config(UART1);
206206
ETS_UART_INTR_ENABLE();
207207

208-
// install uart1 putc callback
208+
// install handler for "os" messages
209209
os_install_putc1((void *)uart_os_write_char);
210210
}
211211

0 commit comments

Comments
 (0)