aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--halext/drivers/touchpad/touchpadXPT2046/touchpad_lld.c2
-rw-r--r--halext/drivers/touchpad/touchpadXPT2046/touchpad_lld_config.h2
-rw-r--r--halext/include/touchpad.h3
-rw-r--r--halext/include/touchpad_lld.h4
4 files changed, 6 insertions, 5 deletions
diff --git a/halext/drivers/touchpad/touchpadXPT2046/touchpad_lld.c b/halext/drivers/touchpad/touchpadXPT2046/touchpad_lld.c
index 4d02be69..f85a68d9 100644
--- a/halext/drivers/touchpad/touchpadXPT2046/touchpad_lld.c
+++ b/halext/drivers/touchpad/touchpadXPT2046/touchpad_lld.c
@@ -134,7 +134,7 @@ uint16_t tp_lld_read_y(void) {
}
/* ---- Optional Routines ---- */
-#if TOUCHPAD_PRESSURE || defined(__DOXYGEN__)
+#if TOUCHPAD_HAS_PRESSURE || defined(__DOXYGEN__)
/*
* @brief Reads out the Z direction / pressure.
*
diff --git a/halext/drivers/touchpad/touchpadXPT2046/touchpad_lld_config.h b/halext/drivers/touchpad/touchpadXPT2046/touchpad_lld_config.h
index 52493836..17f33dd4 100644
--- a/halext/drivers/touchpad/touchpadXPT2046/touchpad_lld_config.h
+++ b/halext/drivers/touchpad/touchpadXPT2046/touchpad_lld_config.h
@@ -35,7 +35,7 @@
/* Driver hardware support. */
/*===========================================================================*/
-#define TOUCHPAD_PRESSURE TRUE
+#define TOUCHPAD_HAS_PRESSURE TRUE
#endif /* HAL_USE_TOUCHPAD */
diff --git a/halext/include/touchpad.h b/halext/include/touchpad.h
index 21e71a97..4f9dce1a 100644
--- a/halext/include/touchpad.h
+++ b/halext/include/touchpad.h
@@ -73,8 +73,9 @@ extern "C" {
void tpInit(TOUCHPADDriver *tp);
uint16_t tpReadX(void);
uint16_t tpReadY(void);
+void tpCalibrate(void);
-#if TOUCHPAD_PRESSURE
+#if TOUCHPAD_HAS_PRESSURE
uint16_t tpReadZ(void);
#endif
diff --git a/halext/include/touchpad_lld.h b/halext/include/touchpad_lld.h
index ab2e54d6..7b33f366 100644
--- a/halext/include/touchpad_lld.h
+++ b/halext/include/touchpad_lld.h
@@ -41,8 +41,8 @@
/* Error checks. */
/*===========================================================================*/
-#ifndef TOUCHPAD_PRESSURE
- #define TOUCHPAD_PRESSURE FALSE
+#ifndef TOUCHPAD_HAS_PRESSURE
+ #define TOUCHPAD_HAS_PRESSURE FALSE
#endif
/*===========================================================================*/