mikroSDK Reference Manual
|
Go to the source code of this file.
Data Structures | |
struct | tsc2003_calibration_data_t |
Calibration data structure. More... | |
struct | tsc2003_pressure_threshold_t |
Press intensity needed to register touch event. More... | |
struct | tsc2003_cfg_t |
TSC2003 Configuration Object. More... | |
struct | tsc2003_t |
TSC2003 Context Object. More... | |
Macros | |
#define | configureData(c, pd, m) ((c<<4)|(pd<<2)|(m<<1)) |
Command byte representation: More... | |
#define | TSC2003_I2C_SLAVE_ADDR_FIXED (0x48) |
TSC2003 Touch Controller Fixed Slave Addreses. More... | |
#define | TSC2003_I2C_SLAVE_ADDR_A0 (0x1) |
TSC2003 Touch Controller Slave Address A0. More... | |
#define | TSC2003_I2C_SLAVE_ADDR_A1 (0x2) |
TSC2003 Touch Controller Slave Address A1. More... | |
#define | TSC2003_I2C_SLAVE_ADDR_0 (TSC2003_I2C_SLAVE_ADDR_FIXED) |
TSC2003 Touch Controller Slave Address 0. More... | |
#define | TSC2003_I2C_SLAVE_ADDR_1 |
TSC2003 Touch Controller Slave Address 1. More... | |
#define | TSC2003_I2C_SLAVE_ADDR_2 |
TSC2003 Touch Controller Slave Address 2. More... | |
#define | TSC2003_I2C_SLAVE_ADDR_3 |
TSC2003 Touch Controller Slave Address 3. More... | |
#define | TSC2003_I2C_SLAVE_ADDR_DEFAULT (TSC2003_I2C_SLAVE_ADDR_3) |
TSC2003 Touch Controller Default Address. More... | |
#define | TSC2003_MAP_PINS(cfg) |
This macro defines I2C pins used by the TSC2003 touch controller. More... | |
Enumerations | |
enum | tsc2003_bits_cfg |
TSC2003 Configuration. More... | |
enum | tsc2003_bits_pd |
TSC2003 Power Down Setting. More... | |
enum | tsc2003_bits_m |
TSC2003 Mode. More... | |
Functions | |
void | tsc2003_cfg_setup (tsc2003_cfg_t *cfg) |
TSC2003 configuration object setup function. More... | |
tp_err_t | tsc2003_init (tsc2003_t *ctx, tsc2003_cfg_t *cfg, tp_drv_t *drv) |
TSC2003 Initialization Function. More... | |
void | tsc2003_default_cfg (tsc2003_t *ctx) |
TSC2003 Default Configuration Function. More... | |
void | tsc2003_press_coordinates (tsc2003_t *ctx, tp_touch_item_t *touch_item) |
Copies touch information from context object to touch item object. More... | |
tp_event_t | tsc2003_press_detect (tsc2003_t *ctx) |
Press detection function. More... | |
tp_err_t | tsc2003_process (tsc2003_t *ctx) |
Function processing events. More... | |
void | tsc2003_gesture (tsc2003_t *ctx, tp_event_t *event) |
Read gesture information. More... | |
void | tsc2003_write_cmd (tsc2003_t *ctx, uint8_t reg_addr) |
Writes a generic command to the IC. More... | |
void | tsc2003_generic_read (tsc2003_t *ctx, uint8_t reg_addr, uint8_t *data_buff, uint8_t len) |
Reads a number of bytes from a register. More... | |
void | tsc2003_calibrate (tsc2003_t *ctx) |
Calibrates variables used for converting raw TSC2003 ADC values to pixel coordinates. More... | |
void | tsc2003_get_calibration_data (tsc2003_t *ctx, tsc2003_calibration_data_t *cdata) |
Utility funciton used for getting a copy of current calibration data. More... | |
void | tsc2003_set_calibration_data (tsc2003_t *ctx, const tsc2003_calibration_data_t *cdata) |
Utility funciton used for setting calibration data. More... | |
void | tsc2003_set_pressure_threshold_level (tsc2003_cfg_t *cfg, tsc2003_pressure_threshold_t pressure) |
Utility funciton used for setting threshold levels. More... | |
Variables | |
const tsc2003_calibration_data_t | TSC2003_CALIBRATION_DATA_DEFAULT |
Default calibration data specific for MikroE resistive tft boards. More... | |
#define configureData | ( | c, | |
pd, | |||
m | |||
) | ((c<<4)|(pd<<2)|(m<<1)) |
enum tsc2003_bits_cfg |
TSC2003 Configuration, higher nibble <7:4> used for operand values .
| C3 | C2 | C1 | C0 |
enum tsc2003_bits_pd |
TSC2003 Power Down Setting, bits <3:2> used for values.
| PD1 | PD2 |
enum tsc2003_bits_m |
const tsc2003_calibration_data_t TSC2003_CALIBRATION_DATA_DEFAULT |
Data useful for skipping calibration when working with MikroE hardware. Gives reasonable touch precision on any size resitive tft board.