S5PV210 Resistive Touch Screen & ADC Controller

Publisher:数字火花Latest update time:2020-02-03 Source: eefocusKeywords:S5PV210 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

1. ADC and touch screen controller structure diagram

1. S5PV210 supports 10 analog inputs, namely AIN0-AIN9. AIN0 and AIN1 are only used for analog input, and AIN2-AIN9 can support 2 resistive touch screens respectively, so this is the resistive touch screen in the previous blog.

The first interface connects the resistive touch panel sensor directly to the SoC controller. So 4 analog input pins are responsible for one resistive touch screen.


2. As can be seen from the above, the entire controller consists of multiple parts. The AD conversion and touch screen control part has two subsidiary units. One of them is the logic of reverse control of the AINn pin (arrow in the figure), which is mainly used to power and measure the xy direction in time-sharing during the process of the touch screen acquiring coordinates; the second is the interrupt generation component. For AIN1 and AIN0, when the AD conversion is completed, the INT_ADC0 and INT_ADC1 interrupt signals will be used to notify the CPU that it can read the data. For the two sets of touch screens, if the X/Y axis data conversion is completed, the INT_PEN0 and INT_PEN1 interrupt signals will be used to notify the CPU to read the coordinate information. However, the interrupt generated by the touch screen being pressed is another interrupt signal. In fact, the hardware interface of the I2C slave device will have an interrupt pin connected to an external interrupt pin in the SoC.


3. Two working modes: Normal Conversion Mode (AUTO_PST = 0, XY_PST = 0) & Separate X/Y Position Conversion Mode (AUTO_PST = 0, XY_PST = control)

(1) The AD converter has two operating modes: normal operation mode and time-sharing X/Y position conversion mode.

(2) The normal operation mode is used for ordinary AD conversion, and the time-sharing X/Y position conversion mode is used for a resistive touch screen. In normal AD conversion, the AD conversion value is placed in TSDATX, and in the time-sharing X/Y mode, the X/Y coordinates are placed in TSDATX and TSDATY respectively.

(3) For AIN0 and AIN1, there are not so many modes, they can only work in normal mode; for AIN2-AIN9, because they are multiplexed, there are only 2 modes. If we use these pins as normal AD conversion

If it is used for resistive touch screen detection, it is configured as normal mode. If it is used for resistive touch screen detection, it is configured as X/Y mode.


4. Interruption of participation

(1) In fact, both ordinary AD conversion and touch screen AD conversion can be completed without the participation of interrupts.

(2) If you do not want to interrupt the normal AD conversion, then query it. After starting a conversion, keep querying the flag bit. It is not wrong to read the conversion value until the hardware automatically sets the flag bit after the AD conversion. Of course, you can also use interrupts. The controller provides a corresponding interrupt for normal AD conversion.

(3) The touch screen can also use or not use interrupts. The SoC never knows when a person will press or release the touch screen, so the pressing/releasing of the touch screen is a purely asynchronous event for the SoC. For this situation, the SoC has only two solutions: polling and interrupts.


5. Main registers

(1)TSADCCONn register

 

Start by read means that after the AD conversion is completed, if the CPU reads the converted data from the corresponding register, the hardware will automatically start the next AD conversion.

ENABLE_START bit, if we set this bit value to 1 to start an AD conversion, this bit will be automatically set to 0

(2) TSCONn: Mainly used to control the power supply of the two panel electrodes when measuring the X-axis and Y-axis coordinates.

(3)TSDLYn: As the name suggests, it is used for delay. This register is mainly used to implement that after completing an AD conversion, the next AD conversion should not be started immediately, but a delay period is required. Specify TS0 - ADC start or interval delay register

(4) TSDATXn: The data after the AD conversion of the X axis of the touch screen is stored in this register. If we only do ordinary AD conversion, then this data is also stored in this register.

(5)TSDATYn: The data after the Y-axis AD conversion of the touch screen is placed in this register

(6)CLRINTADCn: Clear the interrupt pending flag, corresponding to INT_ADCn in the above figure

(7)CLRINTPENn: Clear the interrupt pending flag, corresponding to INT_PENn in the above figure

Keywords:S5PV210 Reference address:S5PV210 Resistive Touch Screen & ADC Controller

Previous article:I2C bus and S5PV210 I2C bus controller
Next article:Detailed explanation of S5PV210 LCD controller

Latest Microcontroller Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号