28 lines
546 B
C
28 lines
546 B
C
/*
|
|
* adc.h
|
|
*
|
|
* Created on: 2022年3月22日
|
|
* Author: User
|
|
*/
|
|
|
|
#ifndef _ADC_H_
|
|
#define _ADC_H_
|
|
|
|
#define Temp1_CHANNEL 0x0D //通道13
|
|
#define Temp2_CHANNEL 0x0C //通道12
|
|
|
|
typedef struct
|
|
{
|
|
uint16_t volatile Temp1_Result; //温度1转换结果
|
|
uint16_t volatile Temp2_Result; //温度2adc转换结果
|
|
uint16_t volatile Display_Temp1_Value;
|
|
uint16_t volatile Display_Temp2_Value;
|
|
void (*Init)(void); //初始化
|
|
void (*Get_ADCData)(void); //转换ad的值变成温度
|
|
} ADC_t;
|
|
|
|
extern ADC_t ADC;
|
|
|
|
|
|
#endif
|