Conversation
|
Taking it futher: How would I disable the uart completely? Because uart is selected automatically? |
roberthartung
left a comment
There was a problem hiding this comment.
Looks good, just some questions / comments.
| ifneq (,$(filter uart_stdio,$(USEMODULE))) | ||
| ifneq (,$(filter uart_stdio_rx,$(USEMODULE))) | ||
| USEMODULE += isrpipe | ||
| USEMODULE += uart_stdio |
There was a problem hiding this comment.
Might be confusing why there is uart_stdio and uart_stdio_rx - is renaming uart_stdio to uart_stdio_tx useful/helpful/required? Or should we add uart_stdio_tx as a pseudo module just to make it clear but also have the opportunity to have both?
| USEMODULE += uart_stdio | ||
| endif | ||
|
|
||
| ifneq (,$(filter uart_stdio,$(USEMODULE))) |
There was a problem hiding this comment.
Should we extend this to be USEMODULE += uart_stdio_tx and USEMODULE += uart_stdio_rx? Because how would the application look like? Maybe you can add tests that show how to enable/disable tx and/or rx mode of the uart?
| #else | ||
| (void)buffer; | ||
| (void)count; | ||
| return -ENOTSUP; |
There was a problem hiding this comment.
Just wondering if this has any side effects on existing applications?
There was a problem hiding this comment.
Difficult question... Maybe returning count is the better choice...
|
I think we need a bit of documentation somewhere to explain how disables |
|
@dylad +1 ... go ahead ;) And also we should give a short overview, where uart is initialized. For stm32 it is in newlib, am I right here? But for other platforms it is in the board_init, e.g. telosb, z1 and a few others (including my platform ;)). |
|
Are we waiting for documentation here? This is probably the duty of @kaspar030 |
|
@yegorich can you comment on this PR? |
|
I've looked at various users of I wonder whether it make sense to propagate |
|
@MrKevinWeiss maybe something you would like to have a look at, too? |
|
I'm not gonna work on this in the foreseeable future. Anyone interesting in taking over? |
|
@kaspar030 I rebased your branch to a recent master, do you mind if I push it here, or do you prefer I open a new PR? |
|
Closing in favor of #11310. |
Previously, uart_stdio always set up receiving data from serial.
This led to blocking powermodes (see #7947), and also used memory for the incoming buffer, even if unused.
This PR makes the RX side of uart_stdio available as pseudomodule (uart_stdio_rx).