typedef enum
{
ADC_CH0DIFF = 1,/*p18(positive),p25(negative),only works in diff*/
ADC_CH0 = 2,ADC_CH1N_P11 = 2,
ADC_CH1 = 3,ADC_CH1P_P23 = 3,ADC_CH1DIFF = 3,/*P23 and P11*/
ADC_CH2 = 4,ADC_CH2N_P24 = 4,
ADC_CH3 = 5,ADC_CH2P_P14 = 5,ADC_CH2DIFF = 5,/*P14 and P24*/
ADC_CH4 = 6,ADC_CH3N_P15 = 6,
ADC_CH9 = 7,ADC_CH3P_P20 = 7,ADC_CH3DIFF = 7,/*P20 and P15*/
ADC_CH_VOICE = 8,
ADC_CH_NUM =9,
} adc_CH_t;
int hal_adc_compare_enable(adc_CH_t ch,uint32_t flag,uint32_t th_high,uint32_t th_low)
{
int i=0;
if((ch >= ADC_CH1N_P11) && (ch <=ADC_CH3P_P20))// 差分配置相关的都是把P18屏蔽了,啥意思
{} |