Datasheet

Run sudo nano /etc/X11/xorg.conf.d/99-calibration.conf and copy the
or whatever you got, into there. You can quit X if you want by typing fg to bring that command into the foreground, and
then Control-C to quit.
Depending on the 'rotation' of the screen, when you do this calibration, you may need to comment out the SwapAxes
part with a # and/or swap the numbers around so looks like:
Option "Calibration" "119 3736 3850 174"
to
Option "Calibration" "3736 119 174 3850"
Your touchscreen is now super calibrated, hurrah!
Section "InputClass"
Identifier "calibration"
MatchProduct "stmpe-ts"
Option "Calibration" "172 3763 3769 164"
Option "SwapAxes" "1"
EndSection
© Adafruit Industries
https://learn.adafruit.com/adafruit-pitft-28-inch-resistive-touchscreen-display-raspberry-
pi
Page 34 of 70