throttle.h 611 B

12345678910111213141516171819202122
  1. #ifndef _THROTTLE_H__
  2. #define _THROTTLE_H__
  3. #define THRO1_5V_ERR_BIT 0x01
  4. #define THRO2_5V_ERR_BIT 0x02
  5. #define THRO1_SIG_ERR_BIT 0x04
  6. #define THRO2_SIG_ERR_BIT 0x08
  7. #define THRO_NOT_RELEASED 0x10
  8. void throttle_init(void);
  9. bool throttle_is_released(void);
  10. bool throttle_is_all_error(void);
  11. bool throttle_not_released_err(void);
  12. u8 throttle_get_errors(void);
  13. float throttle_get_signal(void);
  14. void throttle_detect(bool ready);
  15. bool throttle1_is_error(void);
  16. bool throttle2_is_error(void);
  17. float throttle_start_vol(void);
  18. float throttle_end_vol(void);
  19. float throttle_vol_range(void);
  20. #endif /* _THROTTLE_H__ */