Analog-to-Digital Converter/Brownout Detector
LH79524/LH79525 User’s Guide
2-22
Version 1.0
2.2.2.10 Control Bank Registers
The Control Bank is a set of 32 16-bit registers. The contents of the registers controls the
switches for the ADC. These registers are typically configured once at startup, dictated by
the physical system. HWCTRLBx and LWCTRLBx are used together and follow the format
of the HW and LW Registers (see Section 2.2.2.1 and Section 2.2.2.2).
HWCTRLB0 (Tag 0b0000 of the High Word Control Bank) contains 16 bits of data for the
4WX (4 wire touch screen, X direction) conversion. The remaining 14 bits of data for the
4WX conversion is in LWCTRLB0 (Tag number 0b0000 of the Low Word Control Bank).
Bits 15 and 14 of the low words are reserved and read as zero. The same logic is used
for 4WY (4 wire touch screen, Y direction).
The same logic is used for the Control Bank Registers HWCBx and LWCBx. The High
Word Registers should contain:
• The settling time
• The In+ bits
• The In- bits
• The Ref+ bits.
The Low Word Registers should contain:
• The bias control settings
• The Ref- bits.
At the end of any given conversion, a 4-digit Tag Number is stored in the FIFO along with
the corresponding 10-bit output of the ADC.
For internal access into the control bank, the data writes to the registers from the APB
data bus. Each entry is a 16-bit register, with its own address space. Table 2-22 shows
sample entries for the Control Bank. More details, and examples can be found in SHARP’s
Application Note ‘Using the Sharp ADC with Resistive Touch Screens’, available at
http://www.sharpsma.com.
Table 2-22. Sample Entries for Control Bank
TAG TYPE
TAG NAME
CONTENTS
4WX
HWCBx0
Settling Time[15:7]
In+ [6:3]
In- [2]
Ref+ [1:0]
4WY
HWCBx1
Settling Time[15:7]
In+ [6:3]
In- [2]
Ref+ [1:0]
HWCBx2...HWCBx15
4WX LWCBx0
Bias
control[13:2]
Ref-
[1:0]
4WY
LWCBx1
Bias Control[13:2]
Ref- [1:0]