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.

15 lines
335 B

2 years ago
2 years ago
2 years ago
  1. #pragma once
  2. #include "main.h"
  3. #include <stdbool.h>
  4. typedef struct
  5. {
  6. TIM_HandleTypeDef *tim_handler;
  7. uint32_t tim_channel;
  8. } encoder_t;
  9. void encoder_all_start(void);
  10. void encoder_all_stop(void);
  11. bool encoder_clear_counter(TIM_HandleTypeDef *tim_handler);
  12. void encoder_all_clear_counter(void);
  13. void encoder_read_printf(void);