xyf.h 1014 B

123456789101112131415161718192021222324252627282930313233
  1. #ifndef __XYF_H
  2. #define __XYF_H
  3. #include "stdint.h"
  4. #include "config.h"
  5. #include "cang.h"
  6. #define XYF_BUF_DEP 20
  7. typedef struct{
  8. uint16_t XYF_Data1[XYF_BUF_DEP]; //卸油阀开关数据
  9. uint16_t XYF_Data2[XYF_BUF_DEP]; //卸油阀卸尽数据
  10. uint16_t XYF_StateCnt1; //卸油阀开关状态计数
  11. uint16_t XYF_StateCnt2; //卸油阀卸尽状态计数
  12. uint16_t XYF_StateCnt3; //卸油阀开关状态计数
  13. uint16_t XYF_StateCnt4; //卸油阀卸尽状态计数
  14. uint16_t XYF_State1; //卸油阀开关状态
  15. uint16_t XYF_State2; //卸油阀卸尽状态
  16. uint16_t XYF_ErrorCnt; //卸油阀错误计数
  17. uint16_t XYF_Error; //卸油阀错误状态
  18. uint16_t XYF_StateKeepNum; //判断次数
  19. uint16_t XYF_ADC;
  20. uint16_t RTData_Num;
  21. }XYF_Inf;
  22. extern XYF_Inf xyf_inf[SENSOR_DEEP];
  23. extern void XYF_state(uint16_t CangNum);
  24. extern void XYF_Init(void);
  25. extern void Flash_ReadBytes(uint16_t* sorBuf,uint32_t FlashAddr,uint16_t len);
  26. extern void Flash_WriteBytes(uint16_t* sorBuf,uint32_t FlashAddr,uint16_t len);
  27. #endif