Description
STM32U0 (and possibly other parts) support level inversion with the following:
huartx.AdvancedInit.AdvFeatureInit = UART_ADVFEATURE_TXINVERT_INIT;
huartx.AdvancedInit.TxPinLevelInvert = UART_ADVFEATURE_TXINV_ENABLE;
Please support these through the Arduino core.
Alternative workarounds include inverting the content before sending, or using an inverting buffer, but supporting this natively would be preferable.
Additional context
This is to support SDI-12 using the single-pin mode of the USART.
Metadata
Metadata
Assignees
Type
Projects
Status
To do
Activity
fpistm commentedon Mar 4, 2025
Hi @ndoo
this issue is a duplicate of #1160 and already reference in #1418.
Feel free to contribute, for example UART Tx Rx pin swap function was added by a contributor in #2601.
ndoo commentedon Mar 5, 2025
Hi @fpistm, thanks for capturing it on the list.
For now my plan is to add the inversion in hardware as I'm also adding a level shifter to 5V, but if I find some time I will take a look at #2601.
feat(uart): support UART Tx Rx invert function
feat(uart): support UART Tx Rx invert function
feat(uart): support UART Tx Rx invert function
feat(uart): support UART Tx, Rx and data invert function
feat(uart): support UART Tx, Rx and data invert function
feat(uart): support UART Tx, Rx and data invert function
4 remaining items