使用repl功能,每次打开串口都会重启一下

tommy.guo
Posts: 24
Joined: Mon Feb 14, 2022 8:09 am

使用repl功能,每次打开串口都会重启一下

Postby tommy.guo » Tue Jul 05, 2022 5:29 pm

使用USB Serial/JTAG Controller作为console的输出,配置USB Serial/JTAG Controller为repl的端口,每次使用串口助手打开串口,都会看到设备打印一次启动信息,没找到在哪里重启的。求助大佬们! :roll:

tommy.guo
Posts: 24
Joined: Mon Feb 14, 2022 8:09 am

Re: 使用repl功能,每次打开串口都会重启一下

Postby tommy.guo » Sat Jul 09, 2022 8:00 am

配置代码如下

Code: Select all

esp_console_repl_t *repl = NULL;
    esp_console_repl_config_t repl_config = ESP_CONSOLE_REPL_CONFIG_DEFAULT();
    esp_console_dev_usb_serial_jtag_config_t jtag_config = ESP_CONSOLE_DEV_USB_SERIAL_JTAG_CONFIG_DEFAULT();
    repl_config.prompt = "My Terminal >";

    ESP_LOGW(TAG,"return code :%x",esp_console_new_repl_usb_serial_jtag(&jtag_config, &repl_config, &repl));
    // register_uart_console_cmd();
    ESP_ERROR_CHECK(esp_console_start_repl(repl));

Who is online

Users browsing this forum: No registered users and 38 guests