Component: Touch Screen (FT6X06) (Graphical Library)

From Flowcode Help
Jump to navigationJump to search
Author Matrix Ltd
Version 2.0
Category Graphical Library


Touch Screen (FT6X06) component

Low level routines for controlling or interacting with the FT6X06 touch screen controller IC found on a lot of common capacitive touch screen products. Also compatible with FT6x36 touch screen controller IC.

Component Source Code

Please click here to download the component source project: FC_Comp_Source_TouchScreen_FT6X36.fcfx

Please click here to view the component source code (Beta): FC_Comp_Source_TouchScreen_FT6X36.fcfx

Detailed description

No detailed description exists yet for this component

Examples

An example of how to sample read a capacitive touch display overlay using the component.

FC6 Icon.png FT6X06 Demo

Macro reference

Initialise

Fc9-comp-macro.png Initialise
Activates the SPI peripheral and claims control over the I/O pins. 
Fc9-void-icon.png - VOID Return


ReadCoord

Fc9-comp-macro.png ReadCoord
Reads a coordinate returned from the Sample Sensor macro. Coordinate is scaled to the X/Y Pixel bounds specified. 
Fc9-u8-icon.png - BYTE Coordinate
0 = X, 1 = Y, 2 = Pressure 
Fc9-u8-icon.png - BYTE Index
Touch Index Range: 0 - 1 
Fc9-u16-icon.png - UINT Return


SampleSensor

Fc9-comp-macro.png SampleSensor
Reads the touch controller and returns true if there is currently a touch in progress. The touch coordinates can be read using the ReadCoord macro. Return 0 = No Touch, 1 = Single touch detected, 2 = Two touch points detected 
Fc9-u8-icon.png - BYTE Return


Property reference

Fc9-prop-icon.png Properties
Fc9-type-16-icon.png LinkTo
 
Fc9-conn-icon.png Bus Settings
Fc9-type-16-icon.png Channel
Channel selection 
Fc9-type-16-icon.png Baud Select
Baud rate option selector 
Fc9-type-14-icon.png Baud Rate
Baud rate to be used 
Fc9-type-7-icon.png Stop Delay
On older microcontroller devices there is a potential for the I2C hardware channel to lock up if there is not a 10ms delay between an I2C stop event and the next I2C start event. Most modern microcontrollers will not have a problem so this property can be disabled to speed up the I2C communications.  
Fc9-conn-icon.png Connections
Fc9-type-5-icon.png SDA
Pin used for SDA (data signal) 
Fc9-type-5-icon.png SCL
Pin used for SCL (clock signal) 
Fc9-conn-icon.png Configuration
Fc9-type-16-icon.png Analogue Mode
 
Fc9-type-21-icon.png X Pixel
 
Fc9-type-21-icon.png Y Pixel
 
Fc9-type-7-icon.png Flip X
 
Fc9-type-7-icon.png Flip Y
 
Fc9-conn-icon.png Simulation
Fc9-type-10-icon.png Label
Label used to identify the component on the panel. 
Fc9-type-7-icon.png Enable Interrupt
 
Fc9-type-22-icon.png Interrupt Macro
Macro called when the simulated display fires an interrupt. 
Fc9-type-7-icon.png Simulate Comms
Allows the I2C communications to be simulated and piped through an API to real world hardware.