← index #2497PR #1298
Related · high · value 0.582
QUERY · ISSUE

ESP8266: WebREPL truncates pasted data

openby cpoppopened 2016-10-09updated 2023-12-07
port-esp8266

I'm running 1.8.4 and I notice that data pasted into the WebREPL is truncated.

Start up the WebREPL and trying pasting the following

"*******************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************"

The result is that only around 256 characters of what is pasted actually shows up. This is most troublesome when trying to use paste mode (CTRL-E) to bring in some existing code.

This might be related to the dupterm ringbuffer getting filled: https://github.com/micropython/micropython/blob/master/esp8266/esp_mphal.c#L39

CANDIDATE · PULL REQUEST

esp8266: Fix lost chars problem when block-xfering data (e.g., when pasting).

closedby pfalconopened 2015-05-31updated 2015-06-01

Pasting more or less sizable text into ESP8266 REPL leads to random chars
missing in the received input. Apparent cause is that using RTOS messages
to pass individual chars one by one is to slow and leads to UART FIFO
overflow. So, instead of passing chars one by one, use RTOS msg to signal
that input data is available in FIFO, and then let task handler to read
data directly from FIFO.

With this change, lost chars problem is gone, but the pasted text is
truncated after some position. At least 500 chars can be pasted reliably
(at 115200 baud), but 1K never pastes completely.

Keyboard

j / / n
next pair
k / / p
previous pair
1 / / h
show query pane
2 / / l
show candidate pane
c
copy suggested comment
r
toggle reasoning
g i
go to index
?
show this help
esc
close overlays

press ? or esc to close

copied