Page 1 of 1

esp32 console 显示丢失第一个字符

Posted: Thu Dec 02, 2021 7:22 am
by chenyananee
idf:v4.4

console初始化
```

void console_init()
{
esp_console_repl_t *repl = NULL;
esp_console_repl_config_t repl_config = ESP_CONSOLE_REPL_CONFIG_DEFAULT();
esp_console_dev_uart_config_t uart_config = ESP_CONSOLE_DEV_UART_CONFIG_DEFAULT();
/* Prompt to be printed before each line.
* This can be customized, made dynamic, etc.
*/
repl_config.prompt = prompt;
repl_config.max_cmdline_length = CONSOLE_MAX_COMMAND_LINE_LENGTH;

ESP_ERROR_CHECK(esp_console_new_repl_uart(&uart_config, &repl_config, &repl));
ESP_ERROR_CHECK(esp_console_start_repl(repl));
}


```
问题:
比如键入help时 显示的为 xxx>elp
h会丢失 但是功能正常