| 数据搜索系统,热门电子元器件搜索 |
|
STMPE812 数据表(PDF) 37 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
STMPE812 数据表(HTML) 37 Page - STMicroelectronics |
|
37 / 51 page ![]() STMPE812 Touchscreen controller Doc ID 17732 Rev 3 37/51 11.4 Programming model Below are steps to configure the Touchscreen controller in 3 different acquisition modes. A. Autonomous touchscreen controller, 100 Hz, lowest power possible 1. Initialize the touchscreen controller (choose ACQ_Mode ‘00’ - data acquisition timed by internal timer) 2. Initialize Interrupt (With TSC_Data enabled, normal interrupt mode) 3. Wait for Interrupt 4. On interrupt: Read interrupt status (this clears the set bits too) 5. If data is available, read data. Note: If one set of data is available in buffer, and not accessed by the I2C host, yet the sampling timer is up for the next data, the STMPE812 samples the next data as scheduled. If old data is still NOT accessed when new data is ready to be written to the buffer, it is over- written. If old data is IN PROGRESS of being accessed, new data is DISCARDED. If I2C host accessed PART OF the data, and moved on to read ANY OTHER REGISTER LOCATION, the existing data is CONSIDERED READ, and new data ready to be written into buffer B. Non-autonomous touchscreen controller style-interrupt, 100Hz, lowest power possible: 1. Initialize TSC (Choose ACQ_Mode ‘01’ - Data acquisition triggered by a write to “ACQ” bit) 2. Initialize Interrupt (With TSC_Data, TSC_Touch enabled, PEN_DOWN interrupt mode) 3. Wait for Interrupt 4. On Interrupt: Read Interrupt Status (this clears the set bits too) 5. If PEN_DOWN, start SYSTEM_TIMER (10 ms typically) 6. On TIMEOUT, write ACQ bit to start acquisition 7. Poll interrupt status register or ACQ bit to check for acquisition status 8. ON issuing ACQ, 812 may assume that data in buffer is already accessed by I2C host, and reset the relevant pointers. C. Host-controlled sampling rate (lowest bus utilization) 1. Initialize TSC (choose ACQ_Mode ‘10’ - Data acquisition using host-controlled sampling rate control) 2. Initialize interrupt (with TSC_Data, TSC_Touch enabled, PEN_DOWN interrupt mode) 3. Wait for Interrupt 4. On interrupt: Read Interrupt Status (this clears the set bits too) 5. If PEN_DOWN, start SYSTEM_TIMER (10 ms typically) 6. On TIMEOUT, read data Obsolete Product(s) - Obsolete Product(s) |
|
链接网址 |
| ALLDATASHEET是否为您带来帮助? [ DONATE ] |
关于 Alldatasheet | 广告服务 | 联系我们 | 隐私政策 | 数据表链接 | 链接交换 | 制造商名单 All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |