From 72def895431ad7a08e635b11f3da738e2b2c4618 Mon Sep 17 00:00:00 2001
From: wujiazhi <1147861305@qq.com>
Date: Thu, 13 Jun 2024 11:31:04 +0800
Subject: [PATCH] add lower model test

---
 HARDWARE/ADC/ADC.h |   57 ++++++++++++++++++++++++++++-----------------------------
 1 files changed, 28 insertions(+), 29 deletions(-)

diff --git a/HARDWARE/ADC/ADC.h b/HARDWARE/ADC/ADC.h
index 43e99ce..fce3fb9 100644
--- a/HARDWARE/ADC/ADC.h
+++ b/HARDWARE/ADC/ADC.h
@@ -1,37 +1,36 @@
+#ifndef _ADC_H_
+#define _ADC_H_
 
-/******************************************************************************
- * Copyright (C) 2014-2015 HangZhou SiZhu Co.,LTD.
- *
- *-----------------------------------------------------------------------------
- * File: 			    adc.h
- * Description:		head file of adc.c ,use arm inner adc1 to sample given voltage 
- * Author:			  Lishoujian (867693272@qq.com)
- * Date:			    Jan 9, 2015
- *****************************************************************************/
+#include "define_all.h"
 
-/* ----------------------- Platform includes --------------------------------*/
-#ifndef __ADC_H
-#define __ADC_H	
-#include "sys.h"
+// �ڲ��ۼ�
+// #define const_adc_Slope 	(*((uint16_t *)(0x1FFFFA84)))	//ADCб�ʣ���1000��ʹ��
+// #define const_adc_Offset 	(*((int16_t *)(0x1FFFFA86)))	//ADC�ؾ࣬��100��ʹ�ã���λmV
 
-#define		AD_LENGTH		500
+// �ⲿ�ۼ�
+#define const_adc_Slope (*((uint16_t *)(0x1FFFFA88))) // ADCб�ʣ���1000��ʹ��
+#define const_adc_Offset (*((int16_t *)(0x1FFFFA8A))) // ADC�ؾ࣬��100��ʹ�ã���λmV
 
+// �ڲ��ۼ�  �¶�
+#define const_T_30 *(uint16_t *)0x1FFFFA92 // 0X640  30����ֵ
 
-#define		ADC_dianchi_PIN_NUM				       GPIO_Pin_3
-#define		ADC_dianchi_PIN_GROUP				     GPIOC
+// �ⲿ�ۼ�  �¶�
+#define const_T_30_14BIT *(uint16_t *)0x1FFFFB54 // 0X�ⲿ�ۼ� 16383��14bit��  30����ֵ
 
-typedef struct ad_data_get
-{
-	u16	  *ad_get_address_p;
-	u32		ad_buffer_cnt;
-	u8		ad_ch;
+// ADC_IN4
+#define LIT_ADC_PORT GPIOD
+#define LIT_ADC_PIN GPIO_Pin_1
 
-}ad_data_s;
+// ADC_IN8
+#define ALK_ADC_PORT GPIOB
+#define ALK_ADC_PIN GPIO_Pin_3
 
-double Temp_GetBFiltedData(ad_data_s * data_p);
-void  Adc_set(u8 tem_flag);
-uint16 Get_vol_Average(u8 channel,u8 tem_flag);
-extern volatile u16								ad_data[1000];
-u16 Get_val(u8 ch);                                        
-#endif 
-
+void ADC_LithIO_Init(void);
+void ADC_AlkaIO_Init(void);
+void ADC_IN5_Init(void);
+void ADC_IN10_Init(void);
+void ADC_IN8_Init(void);
+void ADC_Temp_Init(void);
+uint32_t Get_AdcValue(void);
+float Get_AdcTempValue(void);
+#endif

--
Gitblit v1.9.3