You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

41 lines
835 B

2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
  1. #pragma once
  2. #include "sdk/hal/zhal.hpp"
  3. namespace iflytop {
  4. namespace zcr {
  5. typedef struct {
  6. uint16_t packetindex;
  7. uint16_t cmdid;
  8. uint8_t subcmdid;
  9. uint8_t packetType;
  10. uint8_t data[];
  11. } Cmdheader_t;
  12. typedef enum {
  13. kpt_cmd = 0,
  14. kpt_ack = 1,
  15. kpt_error_ack = 2,
  16. kpt_status_report = 3,
  17. } PacketType_t;
  18. typedef enum {
  19. kcmd_ping = 0,
  20. kcmd_read_io = 1,
  21. kcmd_set_io = 2,
  22. kcmd_readadc_raw = 3,
  23. kcmd_m211887_operation = 1000, // 维萨拉压力传感器
  24. kcmd_read_presure_sensor = 1001,
  25. kcmd_triple_warning_light_ctl = 1002,
  26. kcmd_high_power_electrical_ctl = 1003,
  27. kcmd_peristaltic_pump_ctl = 1004,
  28. kcmd_read_huacheng_pressure_sensor = 1005,
  29. } CmdID_t;
  30. } // namespace zcr
  31. } // namespace iflytop
  32. /**
  33. * @brief
  34. */