press_down_detect.h 727 B

1234567891011121314151617181920212223242526272829303132333435
  1. #ifndef __press_down_detect_h__
  2. #define __press_down_detect_h__
  3. #include "main.h"
  4. extern void gpio_mt_run(uint32_t tim);
  5. #define PRESS_LEGTH 15
  6. #define DETECT_DOWN_SIZE 2
  7. #define PRESS_COUNT_MAX 15
  8. #define TIME_INTERVAL 10
  9. #if GIRL_SHOES == 1
  10. #define PRESS_INTER 150000
  11. #else
  12. #define PRESS_INTER 250000
  13. #endif
  14. //#define LEFT_PRESS_LOW 10400000
  15. //#define RIGHT_PRESS_LOW 10050000
  16. #define LEFT_PRESS_LOW 9860000
  17. #define RIGHT_PRESS_LOW 10570000
  18. //short press_jump_detect(short*, short*);
  19. short press_jump_detect(float left_acc_z, float right_acc_z);
  20. int press_down_detect_new(int index, uint16_t left_press, uint16_t right_press, float left_acc_z, float right_acc_z, float pitch_left, float pitch_right);
  21. #endif