aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ginput/touch/MAX11802/max11802.h
diff options
context:
space:
mode:
authorJoel Bodenmann <joel@unormal.org>2014-11-09 21:55:15 +0100
committerJoel Bodenmann <joel@unormal.org>2014-11-09 21:55:15 +0100
commitf65b1896733e3f8cfa2e0f074585e5c5d7657331 (patch)
tree001f473d186f4c7178f2b56620fa1b216cae44f3 /drivers/ginput/touch/MAX11802/max11802.h
parentbaebbad6237f657762523624016cd7d6d5926999 (diff)
downloaduGFX-f65b1896733e3f8cfa2e0f074585e5c5d7657331.tar.gz
uGFX-f65b1896733e3f8cfa2e0f074585e5c5d7657331.tar.bz2
uGFX-f65b1896733e3f8cfa2e0f074585e5c5d7657331.zip
Added MAX11802 driver - NOT WORKING YET - read_xyz() not ported yet
Diffstat (limited to 'drivers/ginput/touch/MAX11802/max11802.h')
-rw-r--r--drivers/ginput/touch/MAX11802/max11802.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/drivers/ginput/touch/MAX11802/max11802.h b/drivers/ginput/touch/MAX11802/max11802.h
new file mode 100644
index 00000000..2266bfa1
--- /dev/null
+++ b/drivers/ginput/touch/MAX11802/max11802.h
@@ -0,0 +1,31 @@
+/*
+ * This file is subject to the terms of the GFX License. If a copy of
+ * the license was not distributed with this file, you can obtain one at:
+ *
+ * http://ugfx.org/license.html
+ */
+
+#ifndef _MAX11802_H
+#define _MAX11802_H
+
+#define MAX11802_CMD_XPOSITION ((0x52 << 1) | 1)
+#define MAX11802_CMD_YPOSITION ((0x54 << 1) | 1)
+#define MAX11802_CMD_ZPOSITION ((0x56 << 1) | 1)
+
+// LSB of register addresses specifies read (1) or write (0)
+#define MAX11802_CMD_MEASUREXY (0x70 << 1)
+#define MAX11802_CMD_MEASUREXYZ (0x72 << 1)
+#define MAX11802_CMD_GEN_WR (0x01 << 1) // General config register
+#define MAX11802_CMD_RES_WR (0x02 << 1)
+#define MAX11802_CMD_AVG_WR (0x03 << 1)
+#define MAX11802_CMD_SAMPLE_WR (0x04 << 1)
+#define MAX11802_CMD_TIMING_WR (0x05 << 1)
+#define MAX11802_CMD_DELAY_WR (0x06 << 1)
+#define MAX11802_CMD_TDPULL_WR (0x07 << 1)
+#define MAX11802_CMD_MDTIM_WR (0x08 << 1)
+#define MAX11802_CMD_APCONF_WR (0x09 << 1)
+#define MAX11802_CMD_MODE_WR (0x0B << 1)
+#define MAX11802_CMD_MODE_RD ((0x0B << 1) | 1)
+#define MAX11802_CMD_GSR_RD ((0x00 << 1) | 1) // General status register - read-only
+
+#endif /* _MAX11802_H */