-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Serial doesn't provide inverse operation as provided by Espressif #4896
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I now can do this by directly manipulating the uart0 config register: U0C0 = BIT(UCRXI) | BIT(UCBN) | BIT(UCBN+1) | BIT(UCSBN); // Inverse RX https://github.com/esp8266/Arduino/blob/master/cores/esp8266/esp8266_peri.h |
This is not documented @ https://arduino-esp8266.readthedocs.io/en/latest/reference.html#serial ? Had to read PR to figure out usage. Found no other leads searching on Google.
|
Since you already have the idea of what is missing, do you want to provide a PR updating that methods documentation? It is in a fairly simple format based on sphinx |
In section 3.5 of the espressif interface documentation is written there is functionality to inverse the signal lines of the uart.
I need to inverse the rxd line which is supported by the esp8266.
3.5. Reverse Operation
All the input and output signals can be configured to the reverse direction internally.
#define UART_DTR_INV (BIT(24))
#define UART_RTS_INV (BIT(23))
#define UART_TXD_INV (BIT(22))
#define UART_DSR_INV (BIT(21))
#define UART_CTS_INV (BIT(20))
#define UART_RXD_INV (BIT(19))
By setting the allocation of registers, the input and output of the corresponding signal lines can be
reversed.
Interface function: void UART_SetLineInverse(uint8 uart_no, UART_LineLevelInverse
inverse_mask);
http://bienonline.magix.net/public/esp8266-faq/8E-ESP8266__Interface_UART__EN_v0.2.pdf
I searched in the esp8266 arduino sdk without any luck. For now I have ordered some 7404 ic's from aliexpress but it would be nice if this functionality can be enabled in the sdk.
The text was updated successfully, but these errors were encountered: