mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
Merge branch 'ci/re-enable_legacy_pcnt_test_on_c5' into 'master'
test(legacy_pcnt): re_enable legacy_pcnt test on c5 Closes IDF-10341 See merge request espressif/esp-idf!32060
This commit is contained in:
commit
e5587ac379
@ -54,10 +54,6 @@ components/driver/test_apps/legacy_mcpwm_driver:
|
||||
components/driver/test_apps/legacy_pcnt_driver:
|
||||
disable:
|
||||
- if: SOC_PCNT_SUPPORTED != 1
|
||||
disable_test:
|
||||
- if: IDF_TARGET == "esp32c5"
|
||||
temporary: true
|
||||
reason: target test failed # TODO [ESP32C5] IDF-10341
|
||||
depends_filepatterns:
|
||||
- components/driver/deprecated/**/*pcnt*
|
||||
|
||||
|
@ -30,16 +30,12 @@
|
||||
#define PCNT_CTRL_VCC_IO 1
|
||||
#define PCNT_CTRL_GND_IO 0
|
||||
#else
|
||||
#define PULSE_IO 12
|
||||
#define PULSE_IO 0
|
||||
#define PCNT_INPUT_IO 4
|
||||
#define PCNT_CTRL_VCC_IO 5
|
||||
#define PCNT_CTRL_GND_IO 2
|
||||
#endif
|
||||
|
||||
#define HIGHEST_LIMIT 10
|
||||
#define LOWEST_LIMIT 0
|
||||
#define MAX_THRESHOLD 5
|
||||
#define MIN_THRESHOLD 0
|
||||
#define PCNT_CTRL_HIGH_LEVEL 1
|
||||
#define PCNT_CTRL_LOW_LEVEL 0
|
||||
|
||||
@ -407,6 +403,7 @@ TEST_CASE("PCNT_basic_function_test", "[pcnt]")
|
||||
|
||||
// use LEDC to produce the pulse, then the PCNT to count it
|
||||
produce_pulse();
|
||||
vTaskDelay(10 / portTICK_PERIOD_MS); // ensure LEDC is working
|
||||
pcnt_test_io_config(PCNT_CTRL_HIGH_LEVEL);
|
||||
|
||||
// initialize first, the initial value should be 0
|
||||
|
@ -7,7 +7,7 @@ from pytest_embedded import Dut
|
||||
@pytest.mark.esp32
|
||||
@pytest.mark.esp32s2
|
||||
@pytest.mark.esp32s3
|
||||
# @pytest.mark.esp32c5 # TODO [ESP32C5] IDF-10341
|
||||
@pytest.mark.esp32c5
|
||||
@pytest.mark.esp32c6
|
||||
@pytest.mark.esp32h2
|
||||
@pytest.mark.esp32p4
|
||||
|
@ -163,6 +163,8 @@ It is recommended to remove the unused watch point by :cpp:func:`pcnt_unit_remov
|
||||
|
||||
When a watch step and a watch point are triggered at the same time (i.e. at the same absolute point), the callback function only gets called by once.
|
||||
|
||||
The step increment will be reset to 0 when the count reaches the high/low limit value. Please do not rely too much on the exact step interval.
|
||||
|
||||
.. code:: c
|
||||
|
||||
// add positive direction watch step with 100 step intervals
|
||||
|
@ -163,6 +163,8 @@ PCNT 单元可被设置为观察几个特定的数值,这些被观察的数值
|
||||
|
||||
当观察步进和观察点同时被触发时,回调函数只会被调用一次。
|
||||
|
||||
当计数达到上/下限值时,步进增量会被重置为 0,请勿过分依赖于精确的步进间隔。
|
||||
|
||||
.. code:: c
|
||||
|
||||
// add positive direction step notify with 100 step intervals
|
||||
|
Loading…
Reference in New Issue
Block a user