From 45776dc0cc07fbdd18ff63185f8f8a19b85c3a75 Mon Sep 17 00:00:00 2001 From: Armando Date: Thu, 8 Sep 2022 19:21:24 +0800 Subject: [PATCH] esp_adc: add esp32c2 adc high/low test threshold and expected val --- .../test_apps/legacy_adc_driver/main/test_legacy_adc.c | 8 ++++---- components/esp_adc/test_apps/adc/main/test_common_adc.h | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/components/driver/test_apps/legacy_adc_driver/main/test_legacy_adc.c b/components/driver/test_apps/legacy_adc_driver/main/test_legacy_adc.c index 41dc6fffc8..c76a0a8e53 100644 --- a/components/driver/test_apps/legacy_adc_driver/main/test_legacy_adc.c +++ b/components/driver/test_apps/legacy_adc_driver/main/test_legacy_adc.c @@ -47,11 +47,11 @@ #define ADC_TEST_HIGH_THRESH 0 #elif CONFIG_IDF_TARGET_ESP32C2 -#define ADC_TEST_LOW_VAL 2147 -#define ADC_TEST_LOW_THRESH 100 +#define ADC_TEST_LOW_VAL 0 +#define ADC_TEST_LOW_THRESH 15 -#define ADC_TEST_HIGH_VAL 4095 -#define ADC_TEST_HIGH_THRESH 0 +#define ADC_TEST_HIGH_VAL 3400 +#define ADC_TEST_HIGH_THRESH 200 #endif diff --git a/components/esp_adc/test_apps/adc/main/test_common_adc.h b/components/esp_adc/test_apps/adc/main/test_common_adc.h index c72f528386..1deb93c68b 100644 --- a/components/esp_adc/test_apps/adc/main/test_common_adc.h +++ b/components/esp_adc/test_apps/adc/main/test_common_adc.h @@ -65,11 +65,11 @@ extern "C" { #define ADC_TEST_HIGH_THRESH 0 #elif CONFIG_IDF_TARGET_ESP32C2 -#define ADC_TEST_LOW_VAL 2147 -#define ADC_TEST_LOW_THRESH 100 +#define ADC_TEST_LOW_VAL 0 +#define ADC_TEST_LOW_THRESH 15 -#define ADC_TEST_HIGH_VAL 4095 -#define ADC_TEST_HIGH_THRESH 0 +#define ADC_TEST_HIGH_VAL 3400 +#define ADC_TEST_HIGH_THRESH 200 #endif