message.h 901 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. #ifndef __MESSAGE_HPP__
  2. #define __MESSAGE_HPP__
  3. #include <stdint.h>
  4. #include <time.h>
  5. struct zistream;
  6. // 分站传上来的卡定位数据,包括tof,tdoa
  7. struct message_locinfo
  8. {
  9. uint64_t m_time_stamp;
  10. uint32_t m_site_id;
  11. time_t m_site_time;
  12. uint32_t m_card_type;
  13. uint32_t m_card_id;
  14. uint64_t m_tof;
  15. uint16_t m_card_ct;
  16. uint8_t m_batty_status;
  17. uint8_t m_callinfo;//0x80-呼救,0x01-一般呼叫,0x02-紧急呼叫
  18. uint8_t m_rav;
  19. uint8_t m_acc;
  20. uint8_t m_ant_id;
  21. uint16_t m_sync_ct;
  22. uint16_t m_rssi;
  23. void zero_this();
  24. void load(zistream&is,bool tdoa);
  25. };
  26. //tdoa分站同步数据
  27. struct message_tdoasync
  28. {
  29. uint32_t m_local_site_id;
  30. uint32_t m_parent_site_id;
  31. uint16_t m_local_ant_id;
  32. uint16_t m_parent_ant_id;
  33. uint16_t m_sync_ct;
  34. uint16_t m_local_level;
  35. uint64_t m_recv_time;
  36. uint64_t m_send_time;
  37. void zero_this();
  38. void load(zistream&is);
  39. };
  40. #endif