ohpoc.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. #ifndef __OHPOC_H__
  2. #define __OHPOC_H__
  3. #include "stdbool.h"
  4. #include "board.h"
  5. #define OHPOC_APP_NAME "T555"
  6. //#define OHPOC_APP_NAME "RTL-TEST"
  7. #define OHPOC_VERSION "03031" //外部OCPU 应用维护
  8. #define OHPOC_MODLE "N58" //作为OPEN时,此值用于FOTA升级标识使用
  9. #define OHPOC_CUST OHPOC_APP_NAME //作为OPEN时,此值用于FOTA升级标识使用
  10. #define CUSTOMER_CODE 0
  11. //can not be modify
  12. #define OHPOC_EVENT_BASE (5000+100)
  13. //user event define
  14. #define OHPOC_EVENT_KEY_NOR (OHPOC_EVENT_BASE+1)
  15. #define OHPOC_EVENT_KEY_MAT (OHPOC_EVENT_BASE+2)
  16. #define OHPOC_EVENT_MAIN (OHPOC_EVENT_BASE+3)
  17. #define OHPOC_EVENT_HTTP (OHPOC_EVENT_BASE+4)
  18. #define OHPOC_EVENT_LEARN (OHPOC_EVENT_BASE+5)
  19. typedef void(*OHPOC_MSG_Callback)(unsigned char *msg, int len);
  20. bool ohpocInit(OHPOC_MSG_Callback msgCallback,const char *oversion, const char *omodle, const char *ocust);
  21. void ohpoc_msg_send(unsigned char *msg, unsigned short len);
  22. //其它可用接口
  23. typedef struct{
  24. unsigned short year;
  25. unsigned char month;
  26. unsigned char day;
  27. unsigned char hour;
  28. unsigned char min;
  29. unsigned char sec;
  30. }MY_CLOCK;
  31. char *ohpocGetICCID(void);
  32. char *ohpocGetIMEI(void);
  33. void ohpocGetClock(MY_CLOCK *myclock);
  34. #endif