Tricycle.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. #pragma once
  2. #ifndef __tricycle_h__
  3. #define __tricycle_h__
  4. #include "pub.h"
  5. class Tricycle {
  6. public:
  7. Tricycle();
  8. //void Process(int* right_pos, int* right_att, int right_zupt, int* left_pos, int* left_att, int left_zupt, int jump, int down, int rssi);
  9. void Process(int* right_pos, int* right_att, int* right_acc, int right_zupt, int right_press,
  10. int* left_pos, int* left_att, int* left_acc, int left_zupt, int left_press,
  11. int jump, int down, int rssi);
  12. void getResult(int* matrix);
  13. float calHeadingOffset(float init_heading, float cur_heading);
  14. private:
  15. int result[4];
  16. int left_result;
  17. int right_result;
  18. int left_zupt_count;
  19. int right_zupt_count;
  20. float left_foot_init_heading;
  21. float right_foot_init_heading;
  22. int left_trigger_time;
  23. int right_trigger_time;
  24. int last_left_zupt;
  25. int last_right_zupt;
  26. int last_left_pos[3];
  27. int last_right_pos[3];
  28. int left_jump_status;
  29. int right_jump_status;
  30. int has_init;
  31. int left_pos_offset;
  32. int right_pos_offset;
  33. int last_jump;
  34. int prop_status;
  35. };
  36. #endif