|
ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
|
Register layout for the GoodIX GT911 capacitive touch controller. More...
#include <stdint.h>Go to the source code of this file.
Register layout for the GoodIX GT911 capacitive touch controller.
The GT911 is a 5-point projected-capacitive touch IC commonly paired with parallel TFT panels in the 5"-10" size range. It is the touch backend for the EK-RA8D2 ereader carrier this project targets, sitting on the I2C0 bus alongside other low-speed peripherals.
Address space (16-bit register pointers):
| Offset | Name | Width | Purpose |
|---|---|---|---|
| 0x8040 | GTP_COMMAND | 8 | Command (0x00 sleep, 0x01 wake) |
| 0x8047 | CONFIG_VERSION | 8 | First byte of config block |
| 0x8140 | PRODUCT_ID (4 char) | 32 | "911"\0 ASCII id |
| 0x8144 | FIRMWARE_VERSION | 16 | Little-endian firmware revision |
| 0x8146 | X_RESOLUTION | 16 | Reported panel X resolution |
| 0x8148 | Y_RESOLUTION | 16 | Reported panel Y resolution |
| 0x814E | STATUS | 8 | bit7 buffer-ready, bits[3:0] cnt |
| 0x814F | POINT[0..4] base | 8x5 | Five 8-byte point records |
Per-point record (8 bytes, little-endian for the 16-bit fields):
| Off | Field | Notes |
|---|---|---|
| 0 | track_id | Persistent contact id, 0..15 |
| 1 | x_lsb | X coordinate low byte |
| 2 | x_msb | X coordinate high byte |
| 3 | y_lsb | Y coordinate low byte |
| 4 | y_msb | Y coordinate high byte |
| 5 | size_lsb | Contact area size low byte (pressure) |
| 6 | size_msb | Contact area size high byte |
| 7 | reserved | Always 0 |
Cross-checked against GoodIX "GT911 Programming Guide" rev 0.1 (publicly distributed reference; this project does not vendor the document).
Definition in file ra8_touch_gt911_regs.h.
| enum ra8_touch_gt911_addr_t : uint8_t |
I2C target addresses for the GT911.
The GT911 latches its 7-bit address from the INT pin level at reset: INT low yields 0x5D, INT high yields 0x14. The factory default on the EK-RA8D2 ereader carrier is 0x5D.
| Enumerator | |
|---|---|
| k_ra8_touch_gt911_addr_low | Default 7-bit target address. |
| k_ra8_touch_gt911_addr_high | Alternate 7-bit target address. |
Definition at line 66 of file ra8_touch_gt911_regs.h.
| enum ra8_touch_gt911_cmd_t : uint8_t |
Values written into k_ra8_touch_gt911_reg_command.
| Enumerator | |
|---|---|
| k_ra8_touch_gt911_cmd_clear_status | Acknowledge a touch frame. |
| k_ra8_touch_gt911_cmd_software_reset | Soft reset. |
Definition at line 90 of file ra8_touch_gt911_regs.h.
| enum ra8_touch_gt911_geometry_t : uint8_t |
Compile-time geometry constants for the controller.
Definition at line 109 of file ra8_touch_gt911_regs.h.
| enum ra8_touch_gt911_point_offset_t : uint8_t |
Byte offsets of each field inside one 8-byte point record.
Definition at line 120 of file ra8_touch_gt911_regs.h.
| enum ra8_touch_gt911_reg_t : uint16_t |
16-bit register pointers used by the driver.
Definition at line 75 of file ra8_touch_gt911_regs.h.
| enum ra8_touch_gt911_status_mask_t : uint8_t |
Bit layout of the status byte at k_ra8_touch_gt911_reg_status.
| Enumerator | |
|---|---|
| k_ra8_touch_gt911_status_count_mask | bits[3:0] active touch count. |
| k_ra8_touch_gt911_status_large_mask | bit6 large-detect. |
| k_ra8_touch_gt911_status_ready_mask | bit7 buffer-ready. |
Definition at line 99 of file ra8_touch_gt911_regs.h.