English
Language : 

AR1000 Datasheet, PDF (27/37 Pages) Microchip Technology – Resistive Touch Screen Controller
7.16 Calibration of Touch Sensor with Controller
The reported coordinates from a touch screen controller are typically calibrated to the application’s video display.
The task is often left up to the host to perform. This controller provides a feature for it to send coordinates that
have already been calibrated, rather than the host needing to perform this task. If enabled, the feature will apply
pre-collected 4-point calibration data to the reported touch coordinates. Calibration only accounts for X and Y
directional scaling. It does not correct for angular errors due to rotation of the touch sensor on the video display.
The calibration process can be cancelled at anytime by sending a command to the controller.
Upon completion of the calibration process, the calibration data is automatically stored to the EEPROM and
“Calibrated Coordinates” is enabled
The process of “calibration” with the controller is described below.
1) Disable touch reporting by issuing <Disable Touch> command.
Send
Receive
: <0x55><0x01><0x13>
: <0x55><0x02><Response><0x13>
2) Get register group Start address by issuing <Register Start Address Request> command.
A register Start address of 0x07 is used below, for this example.
Send
Receive
: <0x55><0x01><0x22>
: <0x55><0x03><0x00><0x22><0x07>
3) Calculate the CalibrationInset register’s address by adding it’s offset value of 0x0E to the register group Start
address of 0x07.
Register Address = Register Start Address + CalibratioInset Register Offset = 0x07 + 0x0E = 0x15
4) Calculate the desired value for the CalibrationInset register.
A Calibration Inset of 12.5% is used below for this example.
CalibrationInset = 2 * Desire Calibration Inset % = 2 * 12.5 = 25 = 0x19
5) Set the Calibration Inset by writing the desired value to the CalibrationInset register.
Send
Receive
: <0x55><0x05><0x21><0x00><0x15><0x01><0x19>
: <0x55><0x02><0x00><0x21>
6) Issue the <Calibrate Mode> command.
Send
Receive
: <0x55><0x02><0x14><0x04>
: <0x55><0x02><0x00><0x14>
7) Software to display the first calibration point target in the upper left quadrant of the display and prompt the
user to touch and release the target.
Touch and
release target
8) Wait for the user to touch and release the first calibration point target. Do this by looking for a controller
response of: <0x55><0x02><0x00><0x14>
© 2009 Microchip Technology, Inc.
DS41393A-Page 23