Currently it happens (I observed this in SAMD boards) that, if lots of data is written to the uart the write call returns none.
The reason in seems to be in pystream.c (https://github.com/adafruit/circuitpython/blob/master/py/stream.c#L237)
I can handle this problem by waiting "a little" and retry, which seems to work.
Only I can not say how short "a little" can shall be.,,,,,
I think UART.out_waiting() would be helpful.
Currently it happens (I observed this in SAMD boards) that, if lots of data is written to the uart the write call returns none.
The reason in seems to be in pystream.c (https://github.com/adafruit/circuitpython/blob/master/py/stream.c#L237)
I can handle this problem by waiting "a little" and retry, which seems to work.
Only I can not say how short "a little" can shall be.,,,,,
I think UART.out_waiting() would be helpful.