← index #16611Issue #17297
Off-topic · high · value 0.860
QUERY · ISSUE

[feature request] being able to change UART(0) speed without recompiling.

openby 0wwafaopened 2025-01-19updated 2025-02-27
enhancementport-esp32

Description

As a followup to https://github.com/micropython/micropython/issues/6862

I propose to find a way to change URAT(0) speed globally or momentarily.

Globally: a simple entry in a configuration file would be nice.

Programmatically:

something like:

micropython. repl_stop()

Then:
uart = machine.UART(0,921600)

uart.write("Hello 921600 World!")

micropython. repl_restart()

Code Size

Probably small.

Implementation

I hope the MicroPython maintainers or community will implement this feature

Code of Conduct

Yes, I agree

CANDIDATE · ISSUE

In the machine library and/or the pyb library, add a non-blocking UART transmit polling function

openby etherbratopened 2025-05-13updated 2025-05-14
enhancement

Description

STM32 UART.c inlines (via UART.h) the testing of the UART tx available bit and does not make the result publically available. This by definition eliminates the simplest way to implement cooperative multitasking, viz. spinning around a collection of non-blocking functions. Ironically, the machine library includes a POLL_HOOK function which is used by asyncio - however running up the asyncio learning curve is a high price to pay for a simple requirement. Given that the rx_any function has been provided for a non-blocking UART receive, it seems a bizarre oversight not to have provided the equivalent function for UART transmit.

Code Size

No response

Implementation

I hope the MicroPython maintainers or community will implement this feature

Code of Conduct

Yes, I agree

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