mirror of
				https://github.com/espressif/esp-idf.git
				synced 2025-11-03 22:08:28 +00:00 
			
		
		
		
	ci(c2/c3): add major eco version tests(v5.1)
This commit is contained in:
		@@ -297,6 +297,23 @@ pytest_examples_esp32_wifi_ap:
 | 
				
			|||||||
    - build_pytest_examples_esp32
 | 
					    - build_pytest_examples_esp32
 | 
				
			||||||
  tags: [ esp32, wifi_ap ]
 | 
					  tags: [ esp32, wifi_ap ]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					pytest_examples_esp32c2_wifi_ap:
 | 
				
			||||||
 | 
					  extends:
 | 
				
			||||||
 | 
					    - .pytest_examples_dir_template
 | 
				
			||||||
 | 
					    - .rules:test:example_test-esp32c2-wifi
 | 
				
			||||||
 | 
					  needs:
 | 
				
			||||||
 | 
					    - build_pytest_examples_esp32c2
 | 
				
			||||||
 | 
					  tags: [ esp32c2, wifi_ap,  xtal_26mhz]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					pytest_examples_esp32c2eco4_wifi_ap:
 | 
				
			||||||
 | 
					  extends:
 | 
				
			||||||
 | 
					    - .pytest_examples_dir_template
 | 
				
			||||||
 | 
					    - .rules:test:example_test-esp32c2-wifi
 | 
				
			||||||
 | 
					  needs:
 | 
				
			||||||
 | 
					    - build_pytest_examples_esp32c2
 | 
				
			||||||
 | 
					  tags: [ esp32c2eco4, wifi_ap,  xtal_26mhz, esp32c2]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
pytest_examples_esp32c3_wifi_ap:
 | 
					pytest_examples_esp32c3_wifi_ap:
 | 
				
			||||||
  extends:
 | 
					  extends:
 | 
				
			||||||
    - .pytest_examples_dir_template
 | 
					    - .pytest_examples_dir_template
 | 
				
			||||||
@@ -305,6 +322,15 @@ pytest_examples_esp32c3_wifi_ap:
 | 
				
			|||||||
    - build_pytest_examples_esp32c3
 | 
					    - build_pytest_examples_esp32c3
 | 
				
			||||||
  tags: [ esp32c3, wifi_ap ]
 | 
					  tags: [ esp32c3, wifi_ap ]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					pytest_examples_esp32c3eco7_wifi_ap:
 | 
				
			||||||
 | 
					  extends:
 | 
				
			||||||
 | 
					    - .pytest_examples_dir_template
 | 
				
			||||||
 | 
					    - .rules:test:example_test-esp32c3-wifi
 | 
				
			||||||
 | 
					  needs:
 | 
				
			||||||
 | 
					    - build_pytest_examples_esp32c3
 | 
				
			||||||
 | 
					  tags: [ esp32c3eco7, wifi_ap , esp32c3]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
pytest_examples_esp32s3_wifi_ap:
 | 
					pytest_examples_esp32s3_wifi_ap:
 | 
				
			||||||
  extends:
 | 
					  extends:
 | 
				
			||||||
    - .pytest_examples_dir_template
 | 
					    - .pytest_examples_dir_template
 | 
				
			||||||
@@ -408,6 +434,22 @@ pytest_examples_esp32c2_wifi_two_dut:
 | 
				
			|||||||
    - build_pytest_examples_esp32c2
 | 
					    - build_pytest_examples_esp32c2
 | 
				
			||||||
  tags: [ esp32c2, wifi_two_dut, xtal_26mhz ]
 | 
					  tags: [ esp32c2, wifi_two_dut, xtal_26mhz ]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					pytest_examples_esp32c2eco4_wifi_two_dut:
 | 
				
			||||||
 | 
					  extends:
 | 
				
			||||||
 | 
					    - .pytest_examples_dir_template
 | 
				
			||||||
 | 
					    - .rules:test:example_test-esp32c2-wifi
 | 
				
			||||||
 | 
					  needs:
 | 
				
			||||||
 | 
					    - build_pytest_examples_esp32c2
 | 
				
			||||||
 | 
					  tags: [ esp32c2eco4, wifi_two_dut, xtal_26mhz, esp32c2]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					pytest_examples_esp32c3eco7_wifi_two_dut:
 | 
				
			||||||
 | 
					  extends:
 | 
				
			||||||
 | 
					    - .pytest_examples_dir_template
 | 
				
			||||||
 | 
					    - .rules:test:example_test-esp32c3-wifi
 | 
				
			||||||
 | 
					  needs:
 | 
				
			||||||
 | 
					    - build_pytest_examples_esp32c3
 | 
				
			||||||
 | 
					  tags: [ esp32c3eco7, wifi_two_dut , esp32c3]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
pytest_examples_esp32c3_flash_encryption:
 | 
					pytest_examples_esp32c3_flash_encryption:
 | 
				
			||||||
  extends:
 | 
					  extends:
 | 
				
			||||||
    - .pytest_examples_dir_template
 | 
					    - .pytest_examples_dir_template
 | 
				
			||||||
@@ -882,6 +924,22 @@ pytest_components_esp32c2_wifi_two_dut:
 | 
				
			|||||||
    - build_pytest_components_esp32c2
 | 
					    - build_pytest_components_esp32c2
 | 
				
			||||||
  tags: [ esp32c2, wifi_two_dut, xtal_26mhz ]
 | 
					  tags: [ esp32c2, wifi_two_dut, xtal_26mhz ]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					pytest_components_esp32c3eco7_wifi_two_dut:
 | 
				
			||||||
 | 
					  extends:
 | 
				
			||||||
 | 
					    - .pytest_components_dir_template
 | 
				
			||||||
 | 
					    - .rules:test:component_ut-esp32c3-wifi
 | 
				
			||||||
 | 
					  needs:
 | 
				
			||||||
 | 
					    - build_pytest_components_esp32c3
 | 
				
			||||||
 | 
					  tags: [ esp32c3eco7, wifi_two_dut , esp32c3]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					pytest_components_esp32c2eco4_wifi_two_dut:
 | 
				
			||||||
 | 
					  extends:
 | 
				
			||||||
 | 
					    - .pytest_components_dir_template
 | 
				
			||||||
 | 
					    - .rules:test:component_ut-esp32c2-wifi
 | 
				
			||||||
 | 
					  needs:
 | 
				
			||||||
 | 
					    - build_pytest_components_esp32c2
 | 
				
			||||||
 | 
					  tags: [ esp32c2eco4, wifi_two_dut, xtal_26mhz, esp32c2]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
pytest_components_esp32c3_adc:
 | 
					pytest_components_esp32c3_adc:
 | 
				
			||||||
  extends:
 | 
					  extends:
 | 
				
			||||||
    - .pytest_components_dir_template
 | 
					    - .pytest_components_dir_template
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
 | 
					# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD
 | 
				
			||||||
# SPDX-License-Identifier: Unlicense OR CC0-1.0
 | 
					# SPDX-License-Identifier: Unlicense OR CC0-1.0
 | 
				
			||||||
import pytest
 | 
					import pytest
 | 
				
			||||||
from pytest_embedded_idf.unity_tester import CaseTester
 | 
					from pytest_embedded_idf.unity_tester import CaseTester
 | 
				
			||||||
@@ -17,11 +17,38 @@ def test_wifi_connect_cases(case_tester: CaseTester) -> None:  # type: ignore
 | 
				
			|||||||
@pytest.mark.wifi_two_dut
 | 
					@pytest.mark.wifi_two_dut
 | 
				
			||||||
@pytest.mark.xtal_26mhz
 | 
					@pytest.mark.xtal_26mhz
 | 
				
			||||||
@pytest.mark.parametrize(
 | 
					@pytest.mark.parametrize(
 | 
				
			||||||
    'count, config, baud',
 | 
					    'count, config, baud, target',
 | 
				
			||||||
    [
 | 
					    [
 | 
				
			||||||
        (2, 'esp32c2_xtal26m', '74880'),
 | 
					        (2, 'esp32c2_xtal26m', '74880','esp32c2|esp32c2'),
 | 
				
			||||||
    ],
 | 
					    ],
 | 
				
			||||||
    indirect=True,
 | 
					    indirect=True,
 | 
				
			||||||
)
 | 
					)
 | 
				
			||||||
def test_wifi_connect_cases_esp32c2_xtal26m(case_tester: CaseTester) -> None:
 | 
					def test_wifi_connect_cases_esp32c2_xtal26m(case_tester: CaseTester) -> None:
 | 
				
			||||||
    case_tester.run_all_cases()
 | 
					    case_tester.run_all_cases()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					@pytest.mark.esp32c2eco4
 | 
				
			||||||
 | 
					@pytest.mark.wifi_two_dut
 | 
				
			||||||
 | 
					@pytest.mark.xtal_26mhz
 | 
				
			||||||
 | 
					@pytest.mark.parametrize(
 | 
				
			||||||
 | 
					    'count, config, baud, target',
 | 
				
			||||||
 | 
					    [
 | 
				
			||||||
 | 
					        (2, 'esp32c2eco4_xtal26m', '74880','esp32c2|esp32c2'),
 | 
				
			||||||
 | 
					    ],
 | 
				
			||||||
 | 
					    indirect=True,
 | 
				
			||||||
 | 
					)
 | 
				
			||||||
 | 
					def test_wifi_connect_cases_esp32c2eco4_xtal26m(case_tester: CaseTester) -> None:
 | 
				
			||||||
 | 
					    case_tester.run_all_cases()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					@pytest.mark.wifi_two_dut
 | 
				
			||||||
 | 
					@pytest.mark.esp32c3eco7
 | 
				
			||||||
 | 
					@pytest.mark.parametrize(
 | 
				
			||||||
 | 
					    'count, config, target',
 | 
				
			||||||
 | 
					    [
 | 
				
			||||||
 | 
					        (2, 'esp32c3eco7','esp32c3|esp32c3'),
 | 
				
			||||||
 | 
					    ],
 | 
				
			||||||
 | 
					    indirect=True,
 | 
				
			||||||
 | 
					)
 | 
				
			||||||
 | 
					def test_wifi_connect_cases_esp32c3eco7(case_tester: CaseTester) -> None:
 | 
				
			||||||
 | 
					    case_tester.run_all_cases()
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -0,0 +1,2 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c3"
 | 
				
			||||||
 | 
					CONFIG_ESP32C3_REV_MIN_101=y
 | 
				
			||||||
@@ -0,0 +1,3 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c2"
 | 
				
			||||||
 | 
					CONFIG_XTAL_FREQ_26=y
 | 
				
			||||||
 | 
					CONFIG_ESP32C2_REV_MIN_200=y
 | 
				
			||||||
@@ -139,6 +139,8 @@ ENV_MARKERS = {
 | 
				
			|||||||
    'twai_network': 'multiple runners form a TWAI network.',
 | 
					    'twai_network': 'multiple runners form a TWAI network.',
 | 
				
			||||||
    'sdio_master_slave': 'Test sdio multi board.',
 | 
					    'sdio_master_slave': 'Test sdio multi board.',
 | 
				
			||||||
    'usj_device': 'Test usb_serial_jtag and usb_serial_jtag is used as serial only (not console)',
 | 
					    'usj_device': 'Test usb_serial_jtag and usb_serial_jtag is used as serial only (not console)',
 | 
				
			||||||
 | 
					    'esp32c3eco7': 'esp32c3 major version(v1.1) chips',
 | 
				
			||||||
 | 
					    'esp32c2eco4': 'esp32c2 major version(v2.0) chips',
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -0,0 +1,6 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c2"
 | 
				
			||||||
 | 
					CONFIG_XTAL_FREQ_26=y
 | 
				
			||||||
 | 
					CONFIG_ESP32C2_REV_MIN_200=y
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					CONFIG_EXAMPLE_USE_CI_ADDRESS=y
 | 
				
			||||||
 | 
					CONFIG_EXAMPLE_PEER_ADDR="${CI_PIPELINE_ID}"
 | 
				
			||||||
							
								
								
									
										12
									
								
								examples/bluetooth/nimble/blecent/sdkconfig.ci.esp32c3eco7
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								examples/bluetooth/nimble/blecent/sdkconfig.ci.esp32c3eco7
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,12 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c3"
 | 
				
			||||||
 | 
					CONFIG_ESP32C3_REV_MIN_101=y
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					# BT config
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					CONFIG_BT_ENABLED=y
 | 
				
			||||||
 | 
					CONFIG_BTDM_CTRL_MODE_BLE_ONLY=y
 | 
				
			||||||
 | 
					CONFIG_BTDM_CTRL_MODE_BR_EDR_ONLY=n
 | 
				
			||||||
 | 
					CONFIG_BTDM_CTRL_MODE_BTDM=n
 | 
				
			||||||
 | 
					CONFIG_BT_BLUEDROID_ENABLED=n
 | 
				
			||||||
 | 
					CONFIG_BT_NIMBLE_ENABLED=y
 | 
				
			||||||
@@ -0,0 +1,8 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c2"
 | 
				
			||||||
 | 
					CONFIG_XTAL_FREQ_26=y
 | 
				
			||||||
 | 
					CONFIG_ESP32C2_REV_MIN_200=y
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					# Test Config
 | 
				
			||||||
 | 
					#
 | 
				
			||||||
 | 
					CONFIG_EXAMPLE_USE_CI_ADDRESS=y
 | 
				
			||||||
 | 
					CONFIG_EXAMPLE_CI_ADDRESS_OFFSET="${CI_PIPELINE_ID}"
 | 
				
			||||||
@@ -0,0 +1,14 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c3"
 | 
				
			||||||
 | 
					CONFIG_ESP32C3_REV_MIN_101=y
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# MODEM SLEEP Options
 | 
				
			||||||
 | 
					CONFIG_BT_CTRL_MODEM_SLEEP=y
 | 
				
			||||||
 | 
					CONFIG_BT_CTRL_MODEM_SLEEP_MODE_1=y
 | 
				
			||||||
 | 
					# Bluetooth low power clock
 | 
				
			||||||
 | 
					CONFIG_BT_CTRL_LPCLK_SEL_MAIN_XTAL=y
 | 
				
			||||||
 | 
					# Power up main XTAL during light sleep
 | 
				
			||||||
 | 
					CONFIG_BT_CTRL_MAIN_XTAL_PU_DURING_LIGHT_SLEEP=y
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Enable power down of MAC and baseband in light sleep mode
 | 
				
			||||||
 | 
					CONFIG_ESP_PHY_MAC_BB_PD=y
 | 
				
			||||||
@@ -1,6 +1,5 @@
 | 
				
			|||||||
# SPDX-FileCopyrightText: 2022-2024 Espressif Systems (Shanghai) CO LTD
 | 
					# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD
 | 
				
			||||||
# SPDX-License-Identifier: CC0-1.0
 | 
					# SPDX-License-Identifier: CC0-1.0
 | 
				
			||||||
 | 
					 | 
				
			||||||
import os.path
 | 
					import os.path
 | 
				
			||||||
from typing import Tuple
 | 
					from typing import Tuple
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -61,3 +60,63 @@ def test_power_save_conn_esp32c2_26mhz(dut: Tuple[IdfDut, IdfDut]) -> None:
 | 
				
			|||||||
    peripheral.expect('connection established; status=0', timeout=30)
 | 
					    peripheral.expect('connection established; status=0', timeout=30)
 | 
				
			||||||
    output = peripheral.expect(pexpect.TIMEOUT, timeout=30)
 | 
					    output = peripheral.expect(pexpect.TIMEOUT, timeout=30)
 | 
				
			||||||
    assert 'rst:' not in str(output) and 'boot:' not in str(output)
 | 
					    assert 'rst:' not in str(output) and 'boot:' not in str(output)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Case 2: BLE power save test for ESP32C2ECO4
 | 
				
			||||||
 | 
					@pytest.mark.wifi_two_dut
 | 
				
			||||||
 | 
					@pytest.mark.xtal_26mhz
 | 
				
			||||||
 | 
					@pytest.mark.esp32c2eco4
 | 
				
			||||||
 | 
					@pytest.mark.parametrize(
 | 
				
			||||||
 | 
					    'config, count, app_path, baud, target',
 | 
				
			||||||
 | 
					    [
 | 
				
			||||||
 | 
					        (
 | 
				
			||||||
 | 
					            'esp32c2eco4_xtal26m',
 | 
				
			||||||
 | 
					            2,
 | 
				
			||||||
 | 
					            f'{os.path.join(os.path.dirname(__file__), "power_save")}|{os.path.join(os.path.dirname(__file__), "blecent")}',
 | 
				
			||||||
 | 
					            '74880',
 | 
				
			||||||
 | 
					            'esp32c2|esp32c2',
 | 
				
			||||||
 | 
					        ),
 | 
				
			||||||
 | 
					    ],
 | 
				
			||||||
 | 
					    indirect=True,
 | 
				
			||||||
 | 
					)
 | 
				
			||||||
 | 
					def test_power_save_conn_esp32c2eco4_26mhz(dut: Tuple[IdfDut, IdfDut]) -> None:
 | 
				
			||||||
 | 
					    peripheral = dut[0]
 | 
				
			||||||
 | 
					    central = dut[1]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    peripheral.expect('NimBLE_BLE_PRPH: BLE Host Task Started', timeout=5)
 | 
				
			||||||
 | 
					    central.expect('NimBLE_BLE_CENT: BLE Host Task Started', timeout=5)
 | 
				
			||||||
 | 
					    peripheral.expect('Returned from app_main()', timeout=5)
 | 
				
			||||||
 | 
					    central.expect('Returned from app_main()', timeout=5)
 | 
				
			||||||
 | 
					    central.expect('Connection established', timeout=30)
 | 
				
			||||||
 | 
					    peripheral.expect('connection established; status=0', timeout=30)
 | 
				
			||||||
 | 
					    output = peripheral.expect(pexpect.TIMEOUT, timeout=30)
 | 
				
			||||||
 | 
					    assert 'rst:' not in str(output) and 'boot:' not in str(output)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Case 2: BLE power save test for ESP32C3ECO7
 | 
				
			||||||
 | 
					@pytest.mark.wifi_two_dut
 | 
				
			||||||
 | 
					@pytest.mark.esp32c3eco7
 | 
				
			||||||
 | 
					@pytest.mark.parametrize(
 | 
				
			||||||
 | 
					    'config, count, app_path, target',
 | 
				
			||||||
 | 
					    [
 | 
				
			||||||
 | 
					        (
 | 
				
			||||||
 | 
					            'esp32c3eco7',
 | 
				
			||||||
 | 
					            2,
 | 
				
			||||||
 | 
					            f'{os.path.join(os.path.dirname(__file__), "power_save")}|{os.path.join(os.path.dirname(__file__), "blecent")}',
 | 
				
			||||||
 | 
					            'esp32c3|esp32c3',
 | 
				
			||||||
 | 
					        ),
 | 
				
			||||||
 | 
					    ],
 | 
				
			||||||
 | 
					    indirect=True,
 | 
				
			||||||
 | 
					)
 | 
				
			||||||
 | 
					def test_power_save_conn_esp32c3eco7(dut: Tuple[IdfDut, IdfDut]) -> None:
 | 
				
			||||||
 | 
					    peripheral = dut[0]
 | 
				
			||||||
 | 
					    central = dut[1]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    peripheral.expect('NimBLE_BLE_PRPH: BLE Host Task Started', timeout=5)
 | 
				
			||||||
 | 
					    central.expect('NimBLE_BLE_CENT: BLE Host Task Started', timeout=5)
 | 
				
			||||||
 | 
					    peripheral.expect('Returned from app_main()', timeout=5)
 | 
				
			||||||
 | 
					    central.expect('Returned from app_main()', timeout=5)
 | 
				
			||||||
 | 
					    central.expect('Connection established', timeout=30)
 | 
				
			||||||
 | 
					    peripheral.expect('connection established; status=0', timeout=30)
 | 
				
			||||||
 | 
					    output = peripheral.expect(pexpect.TIMEOUT, timeout=30)
 | 
				
			||||||
 | 
					    assert 'rst:' not in str(output) and 'boot:' not in str(output)
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,6 +1,5 @@
 | 
				
			|||||||
# SPDX-FileCopyrightText: 2022-2023 Espressif Systems (Shanghai) CO LTD
 | 
					# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD
 | 
				
			||||||
# SPDX-License-Identifier: CC0-1.0
 | 
					# SPDX-License-Identifier: CC0-1.0
 | 
				
			||||||
 | 
					 | 
				
			||||||
import os.path
 | 
					import os.path
 | 
				
			||||||
from typing import Tuple
 | 
					from typing import Tuple
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -68,3 +67,65 @@ def test_wifi_getting_started_esp32c2_xtal_26mhz(dut: Tuple[IdfDut, IdfDut]) ->
 | 
				
			|||||||
    station.expect(f'{tag}: got ip:', timeout=60)
 | 
					    station.expect(f'{tag}: got ip:', timeout=60)
 | 
				
			||||||
    station.expect(f'{tag}: connected to ap SSID:{ssid} password:{password}', timeout=60)
 | 
					    station.expect(f'{tag}: connected to ap SSID:{ssid} password:{password}', timeout=60)
 | 
				
			||||||
    softap.expect('station .+ join, AID=', timeout=60)
 | 
					    softap.expect('station .+ join, AID=', timeout=60)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					@pytest.mark.wifi_two_dut
 | 
				
			||||||
 | 
					@pytest.mark.xtal_26mhz
 | 
				
			||||||
 | 
					@pytest.mark.esp32c2eco4
 | 
				
			||||||
 | 
					@pytest.mark.parametrize(
 | 
				
			||||||
 | 
					    'count, config, baud, app_path, target',
 | 
				
			||||||
 | 
					    [
 | 
				
			||||||
 | 
					        (
 | 
				
			||||||
 | 
					            2,
 | 
				
			||||||
 | 
					            'esp32c2eco4_xtal26m',
 | 
				
			||||||
 | 
					            '74880',
 | 
				
			||||||
 | 
					            f'{os.path.join(os.path.dirname(__file__), "softAP")}|{os.path.join(os.path.dirname(__file__), "station")}',
 | 
				
			||||||
 | 
					            'esp32c2|esp32c2',
 | 
				
			||||||
 | 
					        ),
 | 
				
			||||||
 | 
					    ],
 | 
				
			||||||
 | 
					    indirect=True,
 | 
				
			||||||
 | 
					)
 | 
				
			||||||
 | 
					def test_wifi_getting_started_esp32c2eco4_xtal_26mhz(dut: Tuple[IdfDut, IdfDut]) -> None:
 | 
				
			||||||
 | 
					    softap = dut[0]
 | 
				
			||||||
 | 
					    station = dut[1]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    assert station.app.sdkconfig['ESP_WIFI_SOFTAP_SUPPORT'] is False
 | 
				
			||||||
 | 
					    ssid = softap.app.sdkconfig.get('ESP_WIFI_SSID')
 | 
				
			||||||
 | 
					    password = softap.app.sdkconfig.get('ESP_WIFI_PASSWORD')
 | 
				
			||||||
 | 
					    assert station.app.sdkconfig.get('ESP_WIFI_SSID') == ssid
 | 
				
			||||||
 | 
					    assert station.app.sdkconfig.get('ESP_WIFI_PASSWORD') == password
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    tag = 'wifi station'
 | 
				
			||||||
 | 
					    station.expect(f'{tag}: got ip:', timeout=60)
 | 
				
			||||||
 | 
					    station.expect(f'{tag}: connected to ap SSID:{ssid} password:{password}', timeout=60)
 | 
				
			||||||
 | 
					    softap.expect('station .+ join, AID=', timeout=60)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					@pytest.mark.wifi_two_dut
 | 
				
			||||||
 | 
					@pytest.mark.esp32c3eco7
 | 
				
			||||||
 | 
					@pytest.mark.parametrize(
 | 
				
			||||||
 | 
					    'count, config, app_path, target',
 | 
				
			||||||
 | 
					    [
 | 
				
			||||||
 | 
					        (
 | 
				
			||||||
 | 
					            2,
 | 
				
			||||||
 | 
					            'esp32c3eco7',
 | 
				
			||||||
 | 
					            f'{os.path.join(os.path.dirname(__file__), "softAP")}|{os.path.join(os.path.dirname(__file__), "station")}',
 | 
				
			||||||
 | 
					            'esp32c3|esp32c3',
 | 
				
			||||||
 | 
					        ),
 | 
				
			||||||
 | 
					    ],
 | 
				
			||||||
 | 
					    indirect=True,
 | 
				
			||||||
 | 
					)
 | 
				
			||||||
 | 
					def test_wifi_getting_started_esp32c3eco7(dut: Tuple[IdfDut, IdfDut]) -> None:
 | 
				
			||||||
 | 
					    softap = dut[0]
 | 
				
			||||||
 | 
					    station = dut[1]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    assert station.app.sdkconfig['ESP_WIFI_SOFTAP_SUPPORT'] is False
 | 
				
			||||||
 | 
					    ssid = softap.app.sdkconfig.get('ESP_WIFI_SSID')
 | 
				
			||||||
 | 
					    password = softap.app.sdkconfig.get('ESP_WIFI_PASSWORD')
 | 
				
			||||||
 | 
					    assert station.app.sdkconfig.get('ESP_WIFI_SSID') == ssid
 | 
				
			||||||
 | 
					    assert station.app.sdkconfig.get('ESP_WIFI_PASSWORD') == password
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    tag = 'wifi station'
 | 
				
			||||||
 | 
					    station.expect(f'{tag}: got ip:', timeout=60)
 | 
				
			||||||
 | 
					    station.expect(f'{tag}: connected to ap SSID:{ssid} password:{password}', timeout=60)
 | 
				
			||||||
 | 
					    softap.expect('station .+ join, AID=', timeout=60)
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										2
									
								
								examples/wifi/getting_started/softAP/sdkconfig.ci.c3eco7
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										2
									
								
								examples/wifi/getting_started/softAP/sdkconfig.ci.c3eco7
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,2 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c3"
 | 
				
			||||||
 | 
					CONFIG_ESP32C3_REV_MIN_101=y
 | 
				
			||||||
@@ -0,0 +1,3 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c2"
 | 
				
			||||||
 | 
					CONFIG_XTAL_FREQ_26=y
 | 
				
			||||||
 | 
					CONFIG_ESP32C2_REV_MIN_200=y
 | 
				
			||||||
@@ -0,0 +1,2 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c3"
 | 
				
			||||||
 | 
					CONFIG_ESP32C3_REV_MIN_101=y
 | 
				
			||||||
@@ -0,0 +1,3 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c2"
 | 
				
			||||||
 | 
					CONFIG_XTAL_FREQ_26=y
 | 
				
			||||||
 | 
					CONFIG_ESP32C2_REV_MIN_200=y
 | 
				
			||||||
@@ -1,4 +1,4 @@
 | 
				
			|||||||
# SPDX-FileCopyrightText: 2021-2023 Espressif Systems (Shanghai) CO LTD
 | 
					# SPDX-FileCopyrightText: 2021-2025 Espressif Systems (Shanghai) CO LTD
 | 
				
			||||||
# SPDX-License-Identifier: Apache-2.0
 | 
					# SPDX-License-Identifier: Apache-2.0
 | 
				
			||||||
import logging
 | 
					import logging
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -74,3 +74,31 @@ def test_wifi_power_save_pd_top(dut: Dut) -> None:
 | 
				
			|||||||
)
 | 
					)
 | 
				
			||||||
def test_wifi_power_save_esp32c2_26mhz(dut: Dut) -> None:
 | 
					def test_wifi_power_save_esp32c2_26mhz(dut: Dut) -> None:
 | 
				
			||||||
    _run_test(dut)
 | 
					    _run_test(dut)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					@pytest.mark.esp32c2
 | 
				
			||||||
 | 
					@pytest.mark.wifi_ap
 | 
				
			||||||
 | 
					@pytest.mark.xtal_26mhz
 | 
				
			||||||
 | 
					@pytest.mark.esp32c2eco4
 | 
				
			||||||
 | 
					@pytest.mark.parametrize(
 | 
				
			||||||
 | 
					    'config, baud',
 | 
				
			||||||
 | 
					    [
 | 
				
			||||||
 | 
					        ('esp32c2eco4_xtal26m', '74880'),
 | 
				
			||||||
 | 
					    ],
 | 
				
			||||||
 | 
					    indirect=True,
 | 
				
			||||||
 | 
					)
 | 
				
			||||||
 | 
					def test_wifi_power_save_esp32c2eco4_26mhz(dut: Dut) -> None:
 | 
				
			||||||
 | 
					    _run_test(dut)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					@pytest.mark.wifi_ap
 | 
				
			||||||
 | 
					@pytest.mark.esp32c3eco7
 | 
				
			||||||
 | 
					@pytest.mark.parametrize(
 | 
				
			||||||
 | 
					    'config, target',
 | 
				
			||||||
 | 
					    [
 | 
				
			||||||
 | 
					        ('c3eco7','esp32c3')
 | 
				
			||||||
 | 
					    ],
 | 
				
			||||||
 | 
					    indirect=True,
 | 
				
			||||||
 | 
					)
 | 
				
			||||||
 | 
					def test_wifi_power_save_esp32c3eco7(dut: Dut) -> None:
 | 
				
			||||||
 | 
					    _run_test(dut)
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										3
									
								
								examples/wifi/power_save/sdkconfig.ci.c3eco7
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										3
									
								
								examples/wifi/power_save/sdkconfig.ci.c3eco7
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,3 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c3"
 | 
				
			||||||
 | 
					CONFIG_ESP32C3_REV_MIN_101=y
 | 
				
			||||||
 | 
					CONFIG_EXAMPLE_GET_AP_INFO_FROM_STDIN=y
 | 
				
			||||||
@@ -0,0 +1,4 @@
 | 
				
			|||||||
 | 
					CONFIG_IDF_TARGET="esp32c2"
 | 
				
			||||||
 | 
					CONFIG_XTAL_FREQ_26=y
 | 
				
			||||||
 | 
					CONFIG_EXAMPLE_GET_AP_INFO_FROM_STDIN=y
 | 
				
			||||||
 | 
					CONFIG_ESP32C2_REV_MIN_200=y
 | 
				
			||||||
		Reference in New Issue
	
	Block a user