ascprocess.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334
  1. #ifndef _ASCPROCESS_H
  2. #define _ASCPROCESS_H
  3. #include "BaseVar.h"
  4. #include "struct.h"
  5. extern CRITICAL_SECTION g_csAscReadOneData;
  6. extern int test(CBaseVar *tmpVar );
  7. extern BOOL LoadAscDLL(CString strpath);
  8. extern BOOL InitAscComm(int iAddr, int iPort, int iBaudrate, int iDataBit, int iStopBit, int iParity, int iIntervals);//初始化串口
  9. extern int AscCommandSend();//用于时实采集数据的发送
  10. extern int AscResponseValue();//用于时实采集数据的响应
  11. extern int AscRequestWrData(char chDevUid[20], int iVarID, double data);//用于请求写命令操作
  12. extern int AscRequestData( SETBASEPARAM SetBasePara,
  13. int nDataLen,
  14. int nPort,
  15. int nDevAddr,
  16. char chDevUid[20],
  17. int iVarid);//用于只发送一次命令变量的请求
  18. extern int AscRequestSpecData(char chDevUid[20], int iVarID, int iSpecialFlag);//用于只发送一次读命令特殊变量的请求
  19. extern int AscSingleResponseData(char chDevUid[20], int iVarID, char chMsg[80]);//用于只响应一次命令变量的数据
  20. extern double AscSingleResponseWriteData(char chDevUid[20], int iVarID);//用于响应写命令变量的数据
  21. extern int AscSingleResponseSpecialVarData(char chDevUid[20], int iVarID, int iSpecialFlag, char chMsg[80]);//用于只响应一次命令特殊变量的数据
  22. extern void InitAscDll(COMMDEVBASE CommDevBase);//
  23. extern void UnInitAscDll();
  24. #endif