Linux input Subsystem (6)-input subsystem introduction and Structure diagram

Source: Internet
Author: User

Note: This series turns from: http://www.ourunix.org/post/290.html

Introduction to the input subsystem

Input devices (such as keystrokes, keyboards, touchscreens, mice, buzzers, etc.) is a typical character device, its general working mechanism is the bottom of the button, touch and other actions occur when an interrupt (or drive through Timer timer query), and then the CPU through the SPI,I2C or external memory bus read the key value, Coordinates such as data, put a buffer, character device driver manages the buffer, and the drive of the read () interface allows the user to read key values, coordinates and other data.

In Linux, the input subsystem consists of the input subsystem device driver layer, input subsystem core layer (input core), and the input Subsystem event processing layer (Handler). wherein the device driver layer provides read and write access to the hardware registers and converts the response of the underlying hardware to the user input to the standard input events, and then submits to the event processing layer through the core layer, while the core layer provides the programming interface of the device driver layer, and the programming interface of the event processing layer is provided. , and the event processing layer provides the interface of the unified access device and the event processing that the driver layer submits for our user-space applications. So this allows us to input the driver part of the device is not concerned with the operation of the device files, but to care about the operation of each hardware register and the input events submitted.

In Linux, the input subsystem exists as a module, upward, provides interface functions for the user layer, and downward, providing a uniform interface function for the driver layer program. Its construction is very flexible, just call some simple functions, you can put the function of an input device to the application. This enables the input device's events to be sent to the user-tier application through the input subsystem, which can also be used by the user-tier application to notify the driver of a function through the input subsystem.

Input subsystem structure diagram

Linux input Subsystem (6)-input subsystem introduction and Structure diagram

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.