Calibrating the Resistive Touch Screen 

 

 

The Graphics Library and the Demos that comes with it supports two different resistive touch screen methods. The first method uses microcontroller’s internal ADC and firmware to interpret touch signals from a resistive touch screen directly using 4 I/O pins (4-wire Resistive Touch Screen Software Driver). The second method uses a dedicated Microchip AR1020 resistive touch controller (www.microchip.com/AR1020) interfacing to the host microcontroller via an SPI bus (AR1020 Touch Controller).

 

Using any of the methods allows touch screen calibration. The calibration sequence is the same for all hardware configurations and touch screen methods (4-wire Resistive Touch Screen Software Driver or AR1020 Touch Controller).  The calibration sequence can be manually entered or the calibration data in the non-volatile memory is corrupted.

 

To manually force a calibration user should press the center of the touch screen while resetting the microcontroller or powering-up.   After approximately one second, the screen will display the start of the calibration sequence. The user should follow the instructions that appear on the screen.  The calibration sequence uses a four point calibration system. Each touch point will be sampled as indicated by the instructions. 

 

4-wire Resistive Touch Screen Driver

 

The 4-wire Resistive Touch Screen Driver (software based) is supported by all graphics demos that requires touch screen.  All hardware profile header files default to this touch screen method unless explicitly defined to other methods in the hardware profile.

 

AR1020 Touch Controller

 

On two display boards, 5.7″ VGA Truly TFT Display Board (AC164127-8) and 7.0″ WVGA Truly TFT Display Board (AC164127-9), the AR1020 touch screen controller is provided as a touch screen option.  The user can select between the internal or AR1020 touch screen controller by setting jumper bank on these display boards.  Setting the jumper bank to MCU will configure the hardware the touch controller to internal.  Setting the jumper bank to AR1020 will set the touch controller to AR1020.

 

Two demos support the AR1020 touch screen controller, Object Layer Palette and S1D13517.  The Configs directory in each demo will have a hardware profile with AR1020 in the name to designate that the AR1020 controller is being used. Select the appropriate hardware profile based on the touch option used.

                                                                 

 

Hardware Set Up

 

Resistive Touch Method

3.2″ QVGA Truly TFT Display Board (AC164127-4)

4.3″ WQVGA Powertip TFT Display Board (AC164127-6)

5.7″ VGA Truly TFT Display Board (AC164127-8)

7.0″ WVGA Truly TFT Display Board (AC164127-9)

PIC24FJ256DA210 Development Board (DM240312)

4-wire Resistive Touch Screen Driver

(see note 1)

(see note 1)

(see notes 1, 2)

(see notes 1, 2)

AR1020 Touch Controller

(see notes 3, 4)

(see notes 3, 4)

 

Graphics LCD Controller PICtail™ Plus SSD1926 Board (AC164127-5)

OR

Graphics LCD Controller PICtail™ Plus S1D13517 Board (AC164127-7)

OR

Low Cost Controllerless (LCC) Graphics PICtail™ Plus  Board (AC164144) 

 

4-wire Resistive Touch Screen Driver

(see note 2)

(see note 2)

AR1020 Touch Controller

(see notes 4, 5)

(see notes 4, 5)

Notes:

1.     When using PIC24FJ256DA210 Development Board with the 4-wire Resistive Touch Screen Software Driver make sure the jumpers are set properly:

-       JP8 – closed (PMBE1 must be enabled)

-       JP9 – set to 1-2 (use Y- signal)

-       JP10 – set to 1-2 (use X+ signal)

-       JP11 – set to 2-3 (enable PMA17 to SRAM, VGA and WVGA displays needs larger display buffers)

-       JP12 – set to 1-2 (use BKLT_PWM signal to enable control of the display backlight, if set to 1-2 backlight is always enabled)

-       Other jumpers on the board should be set depending on the needs of the application running on the board

2.     When using Display Boards with the AR1020 disabled, make sure the jumpers are set properly:

-       J1, J2, J3, J4 – set to (2-3) (use MCU signals)

-       J5 – don’t care 

3.     When using PIC24FJ256DA210 Development Board with Display Boards that enables the AR1020, make sure the jumpers are set properly:

-       JP8 – closed (PMBE1 must be enabled)

-       JP9 – set to 2-3 (use TC_CS signal)

-       JP10 – set to 2-3 (use PEN_INT signal)

-       JP11 – set to 2-3 (enable PMA17 to SRAM, VGA and WVGA displays needs larger display buffers)

-       JP12 – set to 1-2 (use BKLT_PWM signal to enable control of the display backlight, if set to 1-2 backlight is always enabled)

-       Other jumpers on the board should be set depending on the needs of the application running on the board

4.     When using Display Boards with the AR1020 enabled, make sure the jumpers are set properly:

-       J1, J2, J3, J4 – set to (1-2) (use AR1020 signals)

-       J5 – closed if the LED is used to indicate assertion of the interrupt line.

5.     When using any of the following Graphics PICtail Plus boards:

a.     Graphics LCD Controller PICtail Plus SSD1926 Board (AC164127-5)

b.     Graphics LCD Controller PICtail Plus Epson S1D13517 Board (AC164127-7)

Connect jumper JP1 to the appropriate signal that will receive the interrupt coming from the AR1020.

 

  

Legend:

Supported out of the box

Hardware compatible, will need firmware modification

Supported, see limitations

Not supported, hardware not compatible

 

Trademarks:

The Microchip name and logo, the Microchip logo, MPLAB, and PIC are registered trademarks of Microchip Technology Incorporated in the U.S.A. and other countries.

PICDEM and PICTail are trademarks of Microchip Technology Incorporated in the U.S.A. and other countries.

SD is a trademark of the SD Association in the U.S.A and other countries

Microsoft, Windows, Excel, and Windows Vista are either registered trademarks or trademarks of Microsoft Corporation in the United States and/or other countries.