ytdhcamshm.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. #ifndef YTDHCAMSHM_H
  2. #define YTDHCAMSHM_H
  3. #include <stdio.h>
  4. #include <stdbool.h>
  5. #include <sys/types.h>
  6. #include <sys/shm.h>
  7. #include <sys/ipc.h>
  8. #include <stdlib.h>
  9. #define SHM_PATH "/"
  10. #define SHM_PORT 8812
  11. typedef struct {
  12. unsigned char Enabled;
  13. unsigned long Idx;
  14. unsigned long ParentId;
  15. char CompanyCode[40];
  16. }CompanyInfo;//10240
  17. typedef struct {
  18. unsigned char Enabled;
  19. char CompanyCode[40];
  20. char CellPhone[20];
  21. unsigned long Idx;
  22. unsigned long long InfoChecked;
  23. }UserInfo;//102400
  24. typedef struct {
  25. unsigned char Enabled;
  26. unsigned char RegistStatus;
  27. unsigned char LoginStatus;
  28. unsigned char keepThread;
  29. char Device_Code[40];
  30. char Device_Name[200];
  31. char Device_Info[500];
  32. char Device_Type[100];
  33. char Company_Code[40];
  34. char LoginName[50];
  35. char Password[50];
  36. char Ip[50];
  37. unsigned short Port;
  38. unsigned long Push_Param[4];
  39. long LoginHandle;
  40. long SubscribeHandle;
  41. unsigned int lastCommTime;
  42. char UnUsed[256];
  43. }DeviceInfo;//102400
  44. typedef struct {
  45. CompanyInfo companyInfo[10240];
  46. UserInfo userInfo[102400];
  47. DeviceInfo deviceInfo[102400];
  48. }SysConfShm;
  49. #endif // YTDHCAMSHM_H