mirror of
https://github.com/espressif/esp-protocols.git
synced 2025-07-18 13:02:21 +02:00
vfs: support vfs uart set line endings with specified uart number
* Original commit: espressif/esp-idf@8e00522cd7
This commit is contained in:
committed by
suren-gabrielyan-espressif
parent
078abd8161
commit
ad67a23097
@ -22,8 +22,8 @@ esp_err_t example_configure_stdin_stdout(void)
|
|||||||
256, 0, 0, NULL, 0) );
|
256, 0, 0, NULL, 0) );
|
||||||
/* Tell VFS to use UART driver */
|
/* Tell VFS to use UART driver */
|
||||||
esp_vfs_dev_uart_use_driver(CONFIG_ESP_CONSOLE_UART_NUM);
|
esp_vfs_dev_uart_use_driver(CONFIG_ESP_CONSOLE_UART_NUM);
|
||||||
esp_vfs_dev_uart_set_rx_line_endings(ESP_LINE_ENDINGS_CR);
|
esp_vfs_dev_uart_port_set_rx_line_endings(CONFIG_ESP_CONSOLE_UART_NUM, ESP_LINE_ENDINGS_CR);
|
||||||
/* Move the caret to the beginning of the next line on '\n' */
|
/* Move the caret to the beginning of the next line on '\n' */
|
||||||
esp_vfs_dev_uart_set_tx_line_endings(ESP_LINE_ENDINGS_CRLF);
|
esp_vfs_dev_uart_port_set_tx_line_endings(CONFIG_ESP_CONSOLE_UART_NUM, ESP_LINE_ENDINGS_CRLF);
|
||||||
return ESP_OK;
|
return ESP_OK;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user