Disable touch interrupts by default to prevent accumulation

This commit is contained in:
Andrew D'Angelo 2024-05-01 17:25:29 -05:00
parent 1f11502ec2
commit 8a9548305f
3 changed files with 4 additions and 4 deletions

View File

@ -382,9 +382,9 @@ See [`REG_CFG`](#0x02-reg_id_cfg) for additional settings.
* `3` `CF2_AUTO_OFF` When [driver state unloaded](#0x2d-reg_id_driver_state) set to unloaded, wait for `REG_ID_SHUTDOWN_GRACE` seconds, then enter deep sleep
* `2` `CF2_USB_MOUSE_ON` Send trackpad events over USB
* `1` `CF2_USB_KEYB_ON` Send keyboard events over USB
* `0` `CF2_TOUCH_INT` Generate interrupt for trackpad event
* `0` `CF2_TOUCH_INT` Generate interrupt for trackpad event. Should only be enabled when ready to accept touch input, otherwise touch events will accumulate and be sent all at once when interrupts are activated
Default value: `CF2_TOUCH_INT | CF2_AUTO_OFF`
Default value: `0` (cleared)
#### `0x15` `REG_ID_TOX`

View File

@ -1,6 +1,6 @@
#pragma once
#define VERSION_MAJOR 3
#define VERSION_MINOR 6
#define VERSION_MINOR 7
#define KEY_FIFO_SIZE 31 // number of keys in the public FIFO

View File

@ -400,7 +400,7 @@ void reg_init(void)
reg_set_value(REG_ID_HLD, 100); // 10ms units
reg_set_value(REG_ID_ADR, 0x1F);
reg_set_value(REG_ID_IND, 1); // ms
reg_set_value(REG_ID_CF2, CF2_TOUCH_INT);
reg_set_value(REG_ID_CF2, 0);
reg_set_value(REG_ID_DRIVER_STATE, 0); // Driver not yet loaded
reg_set_value(REG_ID_SHUTDOWN_GRACE, 30);