Page 2 of 2

Re: UART answer in 2ms

Posted: Wed Sep 11, 2019 7:51 pm
by Roberthh
Looking into the code a little bit further, the are two timeout parameters:
a) timeout=xxx Unit ms. Timeout to wait for a character to arrive. That is important for uart read calls.
b) timeout_char=xx Unit chars. Timeout for the ISR between characters. It seems that no character is signaled to be received until this timeout expired. The default set by the driver seems to be 8. The smallest reasonable value is 1. The Micropython API sets it to at least 2.
These parameters are documented for the pyb.uart() class, and implementing timeout_char for the ESP32 seems to be done only halfway. There parameter of the API is accepted, but no setting in the underlying RTOS layers. There might have been a good reason for that.

Re: UART answer in 2ms

Posted: Thu Sep 12, 2019 12:41 am
by Wander
Yes!!! It works!! :D
Thank you!