更新按键驱动

This commit is contained in:
LokLiang
2025-02-18 17:41:45 +08:00
parent f455349861
commit 141a9970d8
14 changed files with 649 additions and 466 deletions

23
app/button/button.h Normal file
View File

@@ -0,0 +1,23 @@
/**
* @file button.h
* @author LokLiang
* @brief 按键接口,是结合 board_config 并对 multi_button 模块的封装
* @version 0.1
* @date 2024-04-23
*
* @copyright Copyright (c) 2024
*
*/
#pragma once
#include "multi_button.h"
#include "config/board_config.h"
button_hdl_t *btn_attach(const cfg_board_pin_io_t *pin,
button_callback_fn cb,
uint8_t event_mask);
void btn_delete(button_hdl_t *handler);
press_event_t btn_get_event(button_hdl_t *handle);