Add basic presence check for cirque trackpad. (#22546)
This commit is contained in:
parent
ce81801480
commit
86f073a8ea
@ -177,12 +177,13 @@ This supports the Cirque Pinnacle 1CA027 Touch Controller, which is used in the
|
|||||||
|
|
||||||
#### Common settings
|
#### Common settings
|
||||||
|
|
||||||
| Setting | Description | Default |
|
| Setting | Description | Default |
|
||||||
| -------------------------------- | ---------------------------------------------------------- | ------------------------------------------- |
|
| ------------------------------------ | ---------------------------------------------------------- | ------------------------------------------- |
|
||||||
| `CIRQUE_PINNACLE_DIAMETER_MM` | (Optional) Diameter of the trackpad sensor in millimeters. | `40` |
|
| `CIRQUE_PINNACLE_DIAMETER_MM` | (Optional) Diameter of the trackpad sensor in millimeters. | `40` |
|
||||||
| `CIRQUE_PINNACLE_ATTENUATION` | (Optional) Sets the attenuation of the sensor data. | `EXTREG__TRACK_ADCCONFIG__ADC_ATTENUATE_4X` |
|
| `CIRQUE_PINNACLE_ATTENUATION` | (Optional) Sets the attenuation of the sensor data. | `EXTREG__TRACK_ADCCONFIG__ADC_ATTENUATE_4X` |
|
||||||
| `CIRQUE_PINNACLE_CURVED_OVERLAY` | (Optional) Applies settings tuned for curved overlay. | _not defined_ |
|
| `CIRQUE_PINNACLE_CURVED_OVERLAY` | (Optional) Applies settings tuned for curved overlay. | _not defined_ |
|
||||||
| `CIRQUE_PINNACLE_POSITION_MODE` | (Optional) Mode of operation. | _not defined_ |
|
| `CIRQUE_PINNACLE_POSITION_MODE` | (Optional) Mode of operation. | _not defined_ |
|
||||||
|
| `CIRQUE_PINNACLE_SKIP_SENSOR_CHECK` | (Optional) Skips sensor presence check | _not defined_ |
|
||||||
|
|
||||||
**`CIRQUE_PINNACLE_ATTENUATION`** is a measure of how much data is suppressed in regards to sensitivity. The higher the attenuation, the less sensitive the touchpad will be.
|
**`CIRQUE_PINNACLE_ATTENUATION`** is a measure of how much data is suppressed in regards to sensitivity. The higher the attenuation, the less sensitive the touchpad will be.
|
||||||
|
|
||||||
|
@ -216,6 +216,13 @@ void cirque_pinnacle_cursor_smoothing(bool enable) {
|
|||||||
RAP_Write(HOSTREG__FEEDCONFIG3, feedconfig3);
|
RAP_Write(HOSTREG__FEEDCONFIG3, feedconfig3);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Check sensor is connected
|
||||||
|
bool cirque_pinnacle_connected(void) {
|
||||||
|
uint8_t zidle = 0;
|
||||||
|
RAP_ReadBytes(HOSTREG__ZIDLE, &zidle, 1);
|
||||||
|
return zidle == HOSTREG__ZIDLE_DEFVAL;
|
||||||
|
}
|
||||||
|
|
||||||
/* Pinnacle-based TM040040/TM035035/TM023023 Functions */
|
/* Pinnacle-based TM040040/TM035035/TM023023 Functions */
|
||||||
void cirque_pinnacle_init(void) {
|
void cirque_pinnacle_init(void) {
|
||||||
#if defined(POINTING_DEVICE_DRIVER_cirque_pinnacle_spi)
|
#if defined(POINTING_DEVICE_DRIVER_cirque_pinnacle_spi)
|
||||||
@ -274,6 +281,10 @@ void cirque_pinnacle_init(void) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
cirque_pinnacle_enable_feed(true);
|
cirque_pinnacle_enable_feed(true);
|
||||||
|
|
||||||
|
#ifndef CIRQUE_PINNACLE_SKIP_SENSOR_CHECK
|
||||||
|
touchpad_init = cirque_pinnacle_connected();
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
pinnacle_data_t cirque_pinnacle_read_data(void) {
|
pinnacle_data_t cirque_pinnacle_read_data(void) {
|
||||||
|
Loading…
Reference in New Issue
Block a user