Documentation ¶
Index ¶
- Constants
- type Gesture
- type TouchPoint
- type TouchScreen
- func (t *TouchScreen) GetCTPMVendorId() (byte, error)
- func (t *TouchScreen) GetGestureType() (Gesture, error)
- func (t *TouchScreen) GetTouches() (TouchPoint, error)
- func (t *TouchScreen) GetTouchesCount() (int, error)
- func (t *TouchScreen) GetVendorID() (byte, error)
- func (t *TouchScreen) Init(tt Touchscreen_Type) error
- func (t *TouchScreen) SetThreshold() error
- type Touchscreen_Type
Constants ¶
View Source
const ( MOVE_UP = 0x10 MOVE_LEFT = 0x14 MOVE_DOWN = 0x18 MOVE_RIGHT = 0x1c ZOOM_IN = 0x48 ZOOM_OUT = 0x49 NO_GESTURE = 0x00 GESTURE_UNKNOWN = 0xff )
View Source
const ( FT62XX = 1 + iota FT5X06 )
View Source
const FT5X06_ADDR = 0x38
View Source
const FT5X06_GESTURE_ADDR = 0x01
View Source
const FT5X06_REG_CHIP_VENDID = 0xA3
View Source
const FT5X06_REG_CTPMVENDID = 0xA8
View Source
const FT5X06_THRESHOLD_ADDR = 0x80
View Source
const FT5X06_TOUCH_COUNT_REG = 0x02
View Source
const FT5X06_TOUCH_VAL_REG = 0x03
View Source
const FT62XX_ADDR = 0x38
View Source
const FT62XX_GESTURE_ADDR = 0x01
View Source
const FT62XX_REG_CHIP_VENDID = 0xA3
View Source
const FT62XX_REG_CTPMVENDID = 0xA8
View Source
const FT62XX_THRESHOLD_ADDR = 0x80
View Source
const FT62XX_TOUCH_COUNT_REG = 0x02
View Source
const FT62XX_TOUCH_VAL_REG = 0x03
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TouchPoint ¶
type TouchScreen ¶
type TouchScreen struct { Device *i2c.Device Touched bool LastScreenChange time.Time Debug bool TType Touchscreen_Type }
func (*TouchScreen) GetCTPMVendorId ¶
func (t *TouchScreen) GetCTPMVendorId() (byte, error)
func (*TouchScreen) GetGestureType ¶
func (t *TouchScreen) GetGestureType() (Gesture, error)
func (*TouchScreen) GetTouches ¶
func (t *TouchScreen) GetTouches() (TouchPoint, error)
Get the touch point of the first touch NOTE: Only supports one touch at the moment
func (*TouchScreen) GetTouchesCount ¶
func (t *TouchScreen) GetTouchesCount() (int, error)
Get the numer of touches the device currently has or 0 if we've already sent this one
func (*TouchScreen) GetVendorID ¶
func (t *TouchScreen) GetVendorID() (byte, error)
func (*TouchScreen) Init ¶
func (t *TouchScreen) Init(tt Touchscreen_Type) error
func (*TouchScreen) SetThreshold ¶
func (t *TouchScreen) SetThreshold() error
type Touchscreen_Type ¶
type Touchscreen_Type int
Click to show internal directories.
Click to hide internal directories.