TFT_eSPI Touch_Controller_Demo compilation error

Upgrading to TFT_eSPI from version 2.3.4 to 2.3.61 resulted in the following error when compiling the TFT_eSPi > 480x320 > Touch_Controller_demo example sketch

/Users/hans/Dropbox/• ARDLAB/98. ESP32/••• PROJECT ESP32 TOUCH KIT/SKETCHES/GETEST EN WERKT/Touch_Controller_Demo/Touch_Controller_Demo.ino: In function 'void setup()':
Touch_Controller_Demo:46:9: error: 'class TFT_eSPI' has no member named 'setTouch'
tft.setTouch(calibrationData);
^
Touch_Controller_Demo:49:9: error: 'class TFT_eSPI' has no member named 'calibrateTouch'
tft.calibrateTouch(calibrationData, TFT_WHITE, TFT_RED, 15);
^
/Users/hans/Dropbox/• ARDLAB/98. ESP32/••• PROJECT ESP32 TOUCH KIT/SKETCHES/GETEST EN WERKT/Touch_Controller_Demo/Touch_Controller_Demo.ino: In function 'void loop()':
Touch_Controller_Demo:66:11: error: 'class TFT_eSPI' has no member named 'getTouch'
if (tft.getTouch(&x, &y)) {
^
exit status 1
'class TFT_eSPI' has no member named 'setTouch'

Downgrading to version 2.3.4 resolves the problem.

Great library, congrats to Bodmer.

Typically the error is caused by the TFT_TOUCH pin not being defined. Note that loading a new version of the library will over-write old setup files. Also do not copy an old "User_Setup_Select.h" into the new library as new features are added and this can cause problems. Post an issue on Github if the problem persists.

Hi Bodmer, problem solved as per your instructions.
I completely forgot that I had to set it up this way.
TFT_eSPI rocks!

This topic was automatically closed after 120 days. New replies are no longer allowed.