Interaction.h 965 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. #include "InertialTrajProcess.h"
  2. #include "SingleFootAction.h"
  3. #define STOP_ANGLE -0.9f
  4. class Interaction {
  5. public:
  6. Interaction();
  7. void Process(uint32_t _time, int* right_pos, int* right_att, int* right_acc, int right_zupt, int right_press,
  8. int* left_pos, int* left_att, int* left_acc, int left_zupt, int left_press,
  9. int jump, int down, int rssi);
  10. int get_motion_state();
  11. private:
  12. InertialTrajProcess rotateTrajLeft;
  13. InertialTrajProcess rotateTrajRight;
  14. int same_zupt_count;
  15. int canEnter;
  16. int stopGame;
  17. int motion_state;
  18. int can_report_motion_state;
  19. int left_stop_signal_count;
  20. int right_stop_signal_count;
  21. int32_t left_last_pos[3];
  22. int32_t right_last_pos[3];
  23. int left_last_pos_tmp[3];
  24. int right_last_pos_tmp[3];
  25. int left_zupt_last;
  26. int right_zupt_last;
  27. SingleFootAction leftFootAction = NULL;
  28. SingleFootAction rightFootAction = NULL;
  29. FootActionState lastLeftState;
  30. FootActionState lastRightState;
  31. int time_interval;
  32. };