lidar_struct.h 786 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. #ifndef LIDAR_STRUCT_H_
  2. #define LIDAR_STRUCT_H_
  3. #include <stdint.h>
  4. #include <vector>
  5. #define READ_DOWN 0x00
  6. #define WRITE_DOWN 0x01
  7. #define METHOD_DOWN 0x02
  8. #define READ_UP 0x10
  9. #define WRITE_UP 0x11
  10. #define METHOD_UP 0x12
  11. #define LOGIN 1
  12. #define GET_STATE 11
  13. #define GET_FW_VER 12
  14. #define GET_NAME 14
  15. #define GET_SN 24
  16. #define SET_CONFIG 25
  17. #define SET_ANGLE 27
  18. #define GET_ANGLE 28
  19. #define GET_DATA 49
  20. #define SCAN_DATA 50
  21. #define GET_RANGE 93
  22. #define RETRY_NUM 10
  23. const uint8_t login_psw[4] = {0x20, 0x21, 0x05, 0x18};
  24. namespace free_optics {
  25. struct ScanData
  26. {
  27. std::vector<uint16_t> ranges_data;
  28. std::vector<uint16_t> intensities_data;
  29. };
  30. }
  31. #endif