LM8400 National Semiconductor, LM8400 Datasheet - Page 18

no-image

LM8400

Manufacturer Part Number
LM8400
Description
Four Wire Resistive Touchscreen Controller with Brownout
Manufacturer
National Semiconductor
Datasheet
www.national.com
9.0 Calibration
9.2 Calibration Procedures with Coordinates Checking
Enabled
To do TS calibration with coordinates checking enabled, first
ensure the Calibration Coordinates Checking is enabled on
the device. This can be accomplished by sending a com-
mand byte of $B1 (Read Parameters command) and check-
ing the 5th bit of the 12th reply byte is set. Alternatively, if the
device is set to Calibration Coordinates Checking enabled
as default, this step can be skipped.
The TS driver sends the command byte to do calibration
($BD). The TS driver should wait for the reply bytes and
ensure it is the same command bytes it sent. The device
waits for a touch to be detected on the panel. Once a touch
is detected, the device checks it against the predetermined
calibration values as noted on Table 4, Table 5 , and Table 6.
If the detected touch is within the predefined value (
the raw A/D value), the device will send a command of $C4
to the TS driver and store the calibration point in the internal
flash. The TS driver can now send a command byte to do the
next calibration point. If the detected touch is not within the
predefined value, the device will send a reply byte of $C8 to
the TS driver. Upon receiving this reply byte, the TS driver
can resend the calibration command for the same calibration
point, go the next calibration point, or abort the calibration
process.
Once all the calibration points are done, the device does a
self-test. If the self-test was not successful, the device will
send a reply byte of $CC to the TS driver. At this point, the
TS driver should either notify the user to redo the calibration
(Continued)
±
127 of
18
point or automatically redo the calibration again. If the self-
test was successful, the device will send a reply byte of $CB
to the TS driver.
9.3 Calibration Procedures with Coordinates Checking
Disabled
To do TS calibration with coordinates checking disabled, first
ensure the Calibration Coordinates Checking is disabled on
the device. This can be accomplished by sending a com-
mand byte of $B1 (Read Parameters command) and check-
ing the 5th bit of the 12th reply byte is not set. Alternatively,
if the device is set to Calibration Coordinates Checking
disabled as default, this step can be skipped.
The TS driver sends the command byte to do calibration
($BD). The TS driver should wait for the reply bytes and
ensure it is the same command bytes it sent. The device
waits for a touch to be detected on the panel. Once a touch
is detected, the device save the values into the internal flash
and send a reply byte of $C4 to the TS driver. The TS driver
can now send a command byte to do the next calibration
point. Since the Calibration Checking is disabled, the TS
driver should ensure the calibration point is within the range
of the calibration cross.
Once all the calibration points are done, the device does a
self-test. If the self-test was not successful, the device will
send a reply byte of $CC to the TS driver. At this point, the
TS driver should either notify the user to redo the calibration
point or automatically redo the calibration again. If the self-
test was successful, the device will send a reply byte of $CB
to the TS driver.

Related parts for LM8400