mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 11:10:54 +03:00
change(lp_adc): Cleanup LP ADC driver and example
This commit is contained in:
@@ -33,7 +33,7 @@ static void lp_uart_init(void)
|
||||
|
||||
static void lp_core_init(void)
|
||||
{
|
||||
/* Set LP core wakeup source as the HP CPU */
|
||||
/* Set LP core wakeup source as the LP timer */
|
||||
ulp_lp_core_cfg_t cfg = {
|
||||
.wakeup_source = ULP_LP_CORE_WAKEUP_SOURCE_LP_TIMER,
|
||||
.lp_timer_sleep_duration_us = 1000000,
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "sdkconfig.h"
|
||||
#include "ulp_lp_core_print.h"
|
||||
#include "ulp_lp_core_lp_adc_shared.h"
|
||||
#include "ulp_lp_core_uart.h"
|
||||
|
||||
#define EXAMPLE_LP_ADC1_CHAN0 CONFIG_EXAMPLE_LP_ADC1_CHANNEL_0_SELECT
|
||||
#define EXAMPLE_LP_ADC1_CHAN1 CONFIG_EXAMPLE_LP_ADC1_CHANNEL_1_SELECT
|
||||
@@ -28,6 +29,7 @@ int main (void)
|
||||
lp_core_printf("lpadc1 chan1 converted value = %d mV\r\n", adc_converted_value[1]);
|
||||
|
||||
lp_core_printf("\n");
|
||||
lp_core_uart_tx_flush(LP_UART_NUM_0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user