colony.h 903 B

12345678910111213141516171819202122232425262728293031323334
  1. #ifndef __COLONY_H_
  2. #define __COLONY_H_
  3. #define COLONY_SER_SOCKET 2
  4. #define COLONY_SER_PORT 25060
  5. extern unsigned char colonyCtl;
  6. extern unsigned char CCID[21];
  7. typedef struct{
  8. unsigned char colonyCtl:1;//打开域名集群连接
  9. unsigned char domainGetOk:1;//域名解析成功
  10. unsigned char targetConnectOk:1;//targetIp连接成功
  11. char targetIp[16];//域名解析出来的目标IP
  12. char targetTryTime;//连接targetIp的次数
  13. char targetDataSendTime;//发起数据包次数
  14. char pocIp[16];
  15. char gpsIp[16];
  16. unsigned char domainSendTick;
  17. }__attribute__ ((packed)) COLONY_TYPEDEF;
  18. void ConolyInit(void);
  19. short ModemGetCCID(void);
  20. void Colony_RecvHandle(char *data, unsigned short len);
  21. void ColonyTick(void);
  22. void ColonyDomainGet(char *pMsg);
  23. void ColonyParaReset(void);
  24. void ColonyFeature(char status);
  25. void ColonyTcpStatus(STATUE ipStatus);
  26. char *getICCID(void);
  27. void GetDomainIp(char *pMsg,char type);
  28. void AtQuery();
  29. #endif