| 数据搜索系统,热门电子元器件搜索 |
|
AN2641 数据表(PDF) 31 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
AN2641 数据表(HTML) 31 Page - STMicroelectronics |
|
31 / 37 page ![]() AN2641 Touchscreen Doc ID 14027 Rev 1 31/37 7.2 Linux input layer The kernel's input subsystem layer was created to unify scattered drivers that handle diverse classes of data-input devices such as keyboards, mice, and touch screens. The kernel's input subsystem layer permits the uniform handling of functionally similar input devices even when they are physically different. For example, all mice, such as PS/2, USB or Bluetooth, are treated alike. It provides an easy event interface for dispatching input reports to user applications. The driver does not have to create and manage /dev nodes and related access methods. Instead, it can simply invoke input APIs to send mouse movements, key presses, or touch events upstream to the user layer. Applications such as X Windows work seamlessly over the event interfaces exported by the input subsystem layer. The name of the touchscreen driver is "drivers/input/touchscreen/spear_ts.c" (or "drivers/input/touchscreen/spr_ts_st.c"). To integrate with the input subsystem layer, the driver fills the structure 'struct input_dev *input_dev' and register through the call input_register_device( ). The sequence of events sent to the application layer is as illustrated in Figure 19: Figure 19. Sequence of events from touchscreen driver 7.3 Calibration process Any CLCD panel touchscreen cannot return absolutely correct coordinates, rather it only returns default values which need to be adjusted to the CLCD panel dimensions. This is the purpose of a calibration tool. The calibration tool works with a simple concept, it asks the user to touch four corner points of the CLCD panel and stores these values. It then learns the offsets and scales used to later calculate the correct coordinates. Calibration may vary for different CLCD panels so before using the touchscreen, the CLCD panel has to be calibrated. Once calibration is successfully performed, the calibration data is written in a file in a particular format. It is up to the user application to use the information provided in the file to calculate correct coordinates. Figure 20 shows the calibration tool display after the calibration process is over. PRESS EVENT (1) X coordinate Y coordinate SYN PRESS EVENT (1) X coordinate Y coordinate SYN (Press events may go multiple times ) . . . RELEASE EVENT(0) X coordinate Y coordinate SYN (Release event will go only once) |
|
链接网址 |
| 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 |