adc_i2s: solve the i2s_adc issue when using wifi

This commit is contained in:
Cao Sen Miao
2020-12-09 20:13:09 +08:00
parent c923c99f09
commit 12a0f93f87
9 changed files with 238 additions and 47 deletions

View File

@@ -163,7 +163,7 @@ static int hall_sensor_get_value(void) //hall sensor without LNA
{
int hall_value;
adc_power_on();
adc_power_acquire();
ADC_ENTER_CRITICAL();
/* disable other peripherals. */
@@ -175,6 +175,7 @@ static int hall_sensor_get_value(void) //hall sensor without LNA
adc_hal_hall_disable();
ADC_EXIT_CRITICAL();
adc_power_release();
return hall_value;
}