This document introduces the usage of HT32 MCU Touch Key Library
This document describes the HT32 touch key library developed by Best Solution for Holtek HT32 microcontrollers. It explains how to obtain the library and firmware, set up a Keil project, configure the library via the Configuration Wizard, and use the provided API functions for touch key detection, sensitivity adjustment, and power-saving sleep modes.
The guide includes a resource usage table for supported HT32F542xx devices, details the library files and initialization functions, and documents get/set/state functions such as TKL_Get_Standby, TKL_Set_KeyThreshold, and TKL_Is_AnyKeyPress. Three sleep modes (Sleep, Deep Sleep1, Deep Sleep2) are available when PowerSave is enabled.
The library can be obtained from Best Solution's FAE or website (http://www.bestsolution.com.tw/EN/) or from the Holtek website (https://www.holtek.com).
Three sleep modes are available: USE_SLEEP_MODE (Sleep Mode), USE_DEEP_SLEEP1_MODE (Deep Sleep1 Mode), and USE_DEEP_SLEEP2_MODE (Deep Sleep2 Mode).
Firmware library version v022 or above is required.