/******************************************************************************
�� �� ����Fuel.h
����������ȼ�����ݴ���
��    �ߣ�����
��    ����V1.0
��    �ڣ�2016.11.3
******************************************************************************/
#ifndef  _FUEL_H_
#define _FUEL_H_

//EXTERN INT8U AFCInitSts;
EXTERN AFC_PARA FuelPARA;
EXTERN FuelStruct FuelInit;
EXTERN FuelStruct FuelInit_Data;
EXTERN FuelStruct FuelInit_DataBackup;
EXTERN AFC_INIT FuelAFCInit;
EXTERN uint16_t    DataFuelConsOf100msUL;


#define Fuel_Short_Cricuit_Res 0
#define Fuel_Open_Res 5000

typedef struct           
{
  INT8U	   Sensor_State;
  INT8U        Step_Get;
  INT16U 	   Res_Dis;
  INT8U   	   Seg_Get;
  INT8U   	   Seg_Val;
  INT16U      Res_Get; 
  INT16U      Capacity_Get;
  INT16U	   Capacity_Val;
  INT8U 	   Precent_Get; 
  INT8U 	   Precent_Val;
  INT16U 	   Flag;
  INT8U 	   Res_Valid;
  INT16U 	   AFC_Get;
}_Fuel_Data_Struct;

EXTERN _Fuel_Data_Struct FuelData;

//EXTERN INT8U Fuel_Sensor_State;//ȼ�ʹ�����״̬



extern  volatile uint16_t AnalogFuelSensorRes;       //ȼ�ʹ�������ֵ,��λ��0.1 Ohm
//extern unsigned char sFuelInitOver ;

void Fuel_KL15_Change_Config_Init(void);	
void Fuel_Change_Config(void);	
void Fuel_KL30_Read_Config_Init(void);	

void SET_YB_InitData(void);
void GET_Data_For_YB(void); //10ms����
void GET_Data_To_DSP(void); //100ms����

void PowerDN_Time_Add(void) ;
unsigned char FuelSensorState(unsigned int vFuelR);





#endif