微波EDA网,见证研发工程师的成长!
首页 > 研发问答 > 手机设计讨论 > MTK手机平台交流 > mt2523Which key event powerkey support? How to configure powerkey map...

mt2523Which key event powerkey support? How to configure powerkey map...

时间:10-02 整理:3721RD 点击:
powerkey support key event like normal keypad.
typedef enum {
HAL_KEYPAD_KEY_RELEASE = 0, /**< A key is released. */
HAL_KEYPAD_KEY_PRESS = 1, /**< A key is pressed. */
HAL_KEYPAD_KEY_LONG_PRESS = 2, /**< A key is long pressed. */
HAL_KEYPAD_KEY_REPEAT = 3, /**< A key is repeat pressed. */
HAL_KEYPAD_KEY_PMU_LONG_PRESS = 4 /**< PMU hardware powerkey is long pressed. */
} hal_keypad_key_state_t;
Except the normal key event, powerkey has theHAL_KEYPAD_KEY_PMU_LONG_PRESS event for PMU longpress.
Powerkey no need to configure GPIO.
If you want mapping key name as other name, like "STAR", you can choose name as follow.
If you don't want to change any more, the fault name is "POWER".

For example:
Ifyou choose the name "STAR", when the powerkey detected event, you will get the key
data value with the mapping name "STAR" via API.


You can get more name data indriver\chip\MT2523\inc\hal_keypad_table.h

Copyright © 2017-2020 微波EDA网 版权所有

网站地图

Top