feat(console): Move IO initialization outside of the console component

- Move the linux repl chip and deprecate chip related functions
- Update location of driver specific default config
- Add missing comments on the newly added functions in the affected components.
This commit is contained in:
Guillaume Souchere
2026-03-11 09:03:34 +01:00
parent 727c638645
commit 5fac0b7386
26 changed files with 921 additions and 713 deletions

View File

@@ -102,21 +102,6 @@ void app_main(void)
#endif
register_nvs();
#if defined(CONFIG_ESP_CONSOLE_UART_DEFAULT) || defined(CONFIG_ESP_CONSOLE_UART_CUSTOM)
esp_console_dev_uart_config_t hw_config = ESP_CONSOLE_DEV_UART_CONFIG_DEFAULT();
ESP_ERROR_CHECK(esp_console_new_repl_uart(&hw_config, &repl_config, &repl));
#elif defined(CONFIG_ESP_CONSOLE_USB_CDC)
esp_console_dev_usb_cdc_config_t hw_config = ESP_CONSOLE_DEV_CDC_CONFIG_DEFAULT();
ESP_ERROR_CHECK(esp_console_new_repl_usb_cdc(&hw_config, &repl_config, &repl));
#elif defined(CONFIG_ESP_CONSOLE_USB_SERIAL_JTAG)
esp_console_dev_usb_serial_jtag_config_t hw_config = ESP_CONSOLE_DEV_USB_SERIAL_JTAG_CONFIG_DEFAULT();
ESP_ERROR_CHECK(esp_console_new_repl_usb_serial_jtag(&hw_config, &repl_config, &repl));
#else
#error Unsupported console type
#endif
ESP_ERROR_CHECK(esp_console_new_repl_stdio(&repl_config, &repl));
ESP_ERROR_CHECK(esp_console_start_repl(repl));
}