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.

22 lines
495 B

1 year ago
1 year ago
1 year ago
  1. #pragma once
  2. #include <stdbool.h>
  3. #include <stdint.h>
  4. #include "board/board.h"
  5. typedef enum {
  6. kButton_mainButton,
  7. } ButtonIndex_t;
  8. typedef enum {
  9. kButtonAction_push = 1,
  10. kButtonAction_release = 0,
  11. } ButtonAction_t;
  12. typedef void (*board_button_cb_t)(ButtonIndex_t pin_no, ButtonAction_t button_action);
  13. void BoardButton_Init(board_button_cb_t cb); // main�г�ʼ��һ��
  14. void BoardButton_load();
  15. void BoardButton_unload();
  16. void BoardButton_enable_sense(); // �͹���˯��ǰ���ø÷���