|
roo_display
API Documentation for roo_display
|
Touch controller interface. More...
#include <device.h>
Public Member Functions | |
| virtual | ~TouchDevice ()=default |
| virtual void | initTouch () |
| Initialize the touch controller. | |
| virtual TouchResult | getTouch (TouchPoint *points, int max_points)=0 |
| Read the current touch state. | |
|
virtualdefault |
|
pure virtual |
Read the current touch state.
If no touch is registered, returns {.touch_points = 0} and does not modify points. If $k$ touch points are registered, writes min(k, max_points) entries to points, and returns {.touch_points = k}. In both cases, the returned timestamp is the detection time.
| points | Output buffer for touch points. |
| max_points | Capacity of points. |
Implemented in roo_display::DummyTouch, roo_display::BasicTouchDevice< max_touch_points >, roo_display::BasicTouchDevice< 1 >, roo_display::BasicTouchDevice< 2 >, and roo_display::BasicTouchDevice< 5 >.
Referenced by roo_display::TouchDisplay::getRawTouch().
Initialize the touch controller.
Reimplemented in roo_display::DummyTouch, roo_display::TouchFt6x36, roo_display::TouchGt911, roo_display::TouchXpt2046< pinCS, Spi, Gpio >, and roo_display::TouchXpt2046< pinTouchCs >.
Definition at line 433 of file device.h.
Referenced by roo_display::TouchDisplay::init().