Calibrate TFT 2.8" V2 Touch Display on a Arduino Mega 2560

Hello Community,

i have a little Project with my Arduino.
Regarding the Project i have to calibrate my TFT 2.8" V2.0 Touch Display. This Touch Display is on a Arduino Mega 2560.

The Code is following

test.ino (4 KB)