diff --git a/components/esp_modem/examples/modem_console/main/Kconfig.projbuild b/components/esp_modem/examples/modem_console/main/Kconfig.projbuild index 3eb51e488aa..5b53daa1534 100644 --- a/components/esp_modem/examples/modem_console/main/Kconfig.projbuild +++ b/components/esp_modem/examples/modem_console/main/Kconfig.projbuild @@ -10,7 +10,7 @@ menu "Example Configuration" Connect to modem via UART. config EXAMPLE_SERIAL_CONFIG_USB bool "USB" - depends on IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3 + depends on IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3 || IDF_TARGET_ESP32P4 help Connect to modem via USB (CDC-ACM class). For IDF version >= 4.4. endchoice @@ -36,6 +36,11 @@ menu "Example Configuration" bool "BG96" help Quectel BG96 is a series of LTE Cat M1/Cat NB1/EGPRS module. + config EXAMPLE_MODEM_DEVICE_EC20 + depends on EXAMPLE_SERIAL_CONFIG_USB + bool "EC20" + help + Quectel EC20 is a series of LTE Cat M4 module. config EXAMPLE_MODEM_DEVICE_SIM7000 depends on EXAMPLE_SERIAL_CONFIG_UART bool "SIM7000" diff --git a/components/esp_modem/examples/modem_console/main/idf_component.yml b/components/esp_modem/examples/modem_console/main/idf_component.yml index 80382c4a3b8..0c242b0d79f 100644 --- a/components/esp_modem/examples/modem_console/main/idf_component.yml +++ b/components/esp_modem/examples/modem_console/main/idf_component.yml @@ -6,7 +6,7 @@ dependencies: version: "^1.0.0" override_path: "../../../" espressif/esp_modem_usb_dte: - version: "^1.1.0" + version: "^1.2.0" rules: - if: "idf_version >=4.4" - - if: "target in [esp32s2, esp32s3]" + - if: "target in [esp32s2, esp32s3, esp32p4]" diff --git a/components/esp_modem/examples/modem_console/main/modem_console_main.cpp b/components/esp_modem/examples/modem_console/main/modem_console_main.cpp index b703d99137f..62c98e6ddb0 100644 --- a/components/esp_modem/examples/modem_console/main/modem_console_main.cpp +++ b/components/esp_modem/examples/modem_console/main/modem_console_main.cpp @@ -160,6 +160,9 @@ extern "C" void app_main(void) #if CONFIG_EXAMPLE_MODEM_DEVICE_BG96 == 1 ESP_LOGI(TAG, "Initializing esp_modem for the BG96 module..."); struct esp_modem_usb_term_config usb_config = ESP_MODEM_BG96_USB_CONFIG(); +#elif CONFIG_EXAMPLE_MODEM_DEVICE_EC20 == 1 + ESP_LOGI(TAG, "Initializing esp_modem for the EC20 module..."); + struct esp_modem_usb_term_config usb_config = ESP_MODEM_EC20_USB_CONFIG(); #elif CONFIG_EXAMPLE_MODEM_DEVICE_SIM7600 == 1 ESP_LOGI(TAG, "Initializing esp_modem for the SIM7600 module..."); struct esp_modem_usb_term_config usb_config = ESP_MODEM_SIM7600_USB_CONFIG(); diff --git a/components/esp_modem/examples/modem_console/sdkconfig.ci.usb_p4 b/components/esp_modem/examples/modem_console/sdkconfig.ci.usb_p4 new file mode 100644 index 00000000000..49e9148fdb5 --- /dev/null +++ b/components/esp_modem/examples/modem_console/sdkconfig.ci.usb_p4 @@ -0,0 +1,2 @@ +CONFIG_IDF_TARGET="esp32p4" +CONFIG_EXAMPLE_SERIAL_CONFIG_USB=y diff --git a/components/esp_modem/examples/pppos_client/main/Kconfig.projbuild b/components/esp_modem/examples/pppos_client/main/Kconfig.projbuild index f66827b67da..8d5a575ec36 100644 --- a/components/esp_modem/examples/pppos_client/main/Kconfig.projbuild +++ b/components/esp_modem/examples/pppos_client/main/Kconfig.projbuild @@ -9,7 +9,7 @@ menu "Example Configuration" Connect to modem via UART. config EXAMPLE_SERIAL_CONFIG_USB bool "USB" - depends on IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3 + depends on IDF_TARGET_ESP32S2 || IDF_TARGET_ESP32S3 || IDF_TARGET_ESP32P4 help Connect to modem via USB (CDC-ACM class). For IDF version >= 4.4. endchoice @@ -29,6 +29,11 @@ menu "Example Configuration" bool "BG96" help Quectel BG96 is a series of LTE Cat M1/Cat NB1/EGPRS module. + config EXAMPLE_MODEM_DEVICE_EC20 + depends on EXAMPLE_SERIAL_CONFIG_USB + bool "EC20" + help + Quectel EC20 is a series of LTE Cat M4 module. config EXAMPLE_MODEM_DEVICE_SIM7000 depends on EXAMPLE_SERIAL_CONFIG_UART bool "SIM7000" diff --git a/components/esp_modem/examples/pppos_client/main/idf_component.yml b/components/esp_modem/examples/pppos_client/main/idf_component.yml index 80382c4a3b8..0c242b0d79f 100644 --- a/components/esp_modem/examples/pppos_client/main/idf_component.yml +++ b/components/esp_modem/examples/pppos_client/main/idf_component.yml @@ -6,7 +6,7 @@ dependencies: version: "^1.0.0" override_path: "../../../" espressif/esp_modem_usb_dte: - version: "^1.1.0" + version: "^1.2.0" rules: - if: "idf_version >=4.4" - - if: "target in [esp32s2, esp32s3]" + - if: "target in [esp32s2, esp32s3, esp32p4]" diff --git a/components/esp_modem/examples/pppos_client/main/pppos_client_main.c b/components/esp_modem/examples/pppos_client/main/pppos_client_main.c index 89553702adb..5a60ad63970 100644 --- a/components/esp_modem/examples/pppos_client/main/pppos_client_main.c +++ b/components/esp_modem/examples/pppos_client/main/pppos_client_main.c @@ -219,6 +219,9 @@ void app_main(void) ESP_LOGI(TAG, "Initializing esp_modem for the BG96 module..."); struct esp_modem_usb_term_config usb_config = ESP_MODEM_BG96_USB_CONFIG(); esp_modem_dce_device_t usb_dev_type = ESP_MODEM_DCE_BG96; +#elif CONFIG_EXAMPLE_MODEM_DEVICE_EC20 == 1 + ESP_LOGI(TAG, "Initializing esp_modem for the EC20 module..."); + struct esp_modem_usb_term_config usb_config = ESP_MODEM_EC20_USB_CONFIG(); #elif CONFIG_EXAMPLE_MODEM_DEVICE_SIM7600 == 1 ESP_LOGI(TAG, "Initializing esp_modem for the SIM7600 module..."); struct esp_modem_usb_term_config usb_config = ESP_MODEM_SIM7600_USB_CONFIG(); diff --git a/components/esp_modem/examples/pppos_client/sdkconfig.ci.usb_p4 b/components/esp_modem/examples/pppos_client/sdkconfig.ci.usb_p4 new file mode 100644 index 00000000000..49e9148fdb5 --- /dev/null +++ b/components/esp_modem/examples/pppos_client/sdkconfig.ci.usb_p4 @@ -0,0 +1,2 @@ +CONFIG_IDF_TARGET="esp32p4" +CONFIG_EXAMPLE_SERIAL_CONFIG_USB=y