Hi everybody.
Sorry for my late response.
I deleted all self installed libraries from "...Documents\Arduino\libraries..." and installed the following new libraries via the library Manager:

Compiling my code looks now much better, but I got the following error messages:
In file included from C:\Users\PC Keller\Documents\Arduino\libraries\Adafruit_ImageReader_Library/Adafruit_ImageReader.h:18:0,
from C:\Users\PC Keller\Documents\Arduino\pt100_test\laufende_Version\gute_Version_1_test\gute_Version_1_test.ino:29:
C:\Users\PC Keller\Documents\Arduino\libraries\Adafruit_SPIFlash\src/Adafruit_SPIFlash.h:50:49: error: expected class-name before ',' token
class Adafruit_SPIFlash : public BaseBlockDriver, public Adafruit_SPIFlashBase {
^
In file included from C:\Users\PC Keller\Documents\Arduino\pt100_test\laufende_Version\gute_Version_1_test\gute_Version_1_test.ino:29:0:
C:\Users\PC Keller\Documents\Arduino\libraries\Adafruit_ImageReader_Library/Adafruit_ImageReader.h:97:38: error: expected ')' before '&' token
Adafruit_ImageReader(FatFileSystem &fs);
^
C:\Users\PC Keller\Documents\Arduino\libraries\Adafruit_ImageReader_Library/Adafruit_ImageReader.h:106:3: error: 'FatFileSystem' does not name a type; did you mean 'SDFileSystem'?
FatFileSystem *filesys; ///< FAT FileSystem Object
^~~~~~~~~~~~~
SDFileSystem
exit status 1
Fehler beim Kompilieren für das Board Arduino Mega or Mega 2560.
This is my code:
/**********************FARBEN**************************
ILI9341_BLACK 0x0000 ///< 0, 0, 0
ILI9341_NAVY 0x000F ///< 0, 0, 123
ILI9341_DARKGREEN 0x03E0 ///< 0, 125, 0
ILI9341_DARKCYAN 0x03EF ///< 0, 125, 123
ILI9341_MAROON 0x7800 ///< 123, 0, 0
ILI9341_PURPLE 0x780F ///< 123, 0, 123
ILI9341_OLIVE 0x7BE0 ///< 123, 125, 0
ILI9341_LIGHTGREY 0xC618 ///< 198, 195, 198
ILI9341_DARKGREY 0x7BEF ///< 123, 125, 123
ILI9341_BLUE 0x001F ///< 0, 0, 255
ILI9341_GREEN 0x07E0 ///< 0, 255, 0
ILI9341_CYAN 0x07FF ///< 0, 255, 255
ILI9341_RED 0xF800 ///< 255, 0, 0
ILI9341_MAGENTA 0xF81F ///< 255, 0, 255
ILI9341_YELLOW 0xFFE0 ///< 255, 255, 0
ILI9341_WHITE 0xFFFF ///< 255, 255, 255
ILI9341_ORANGE 0xFD20 ///< 255, 165, 0
ILI9341_GREENYELLOW 0xAFE5 ///< 173, 255, 41
ILI9341_PINK 0xFC18 ///< 255, 130, 198
*/
#include "SPI.h"
#include "Adafruit_GFX.h"
#include "Adafruit_ILI9341.h"
#include "Wire.h" // this is needed for FT6206
#include "Adafruit_FT6206.h"
#include "SD.h"
#include "Adafruit_ImageReader.h" // Image-reading functions
#define TFT_DC 9
#define TFT_CS 10
#define SD_CS 4
Adafruit_ILI9341 tft = Adafruit_ILI9341(TFT_CS, TFT_DC);
Adafruit_FT6206 ctp = Adafruit_FT6206(); // The FT6206 uses hardware I2C (SCL/SDA)
Adafruit_FT6206 ts = Adafruit_FT6206();
int ThermistorPin08 = 8; // Analogsignal Sensor Öl Vorlauf an Pin Analog_In 08
int ThermistorPin09 = 9; // Analogsignal Sensor Öl Rücklauf an Pin Analog_In 09
int ThermistorPin10 = 10; // Analogsignal Sensor Zylinder 1 an Pin Analog_In 10
int ThermistorPin11 = 11; // Analogsignal Sensor Zylinder 2 an Pin Analog_In 11
int ThermistorPin12 = 12; // Analogsignal Sensor Zylinder 3 an Pin Analog_In 12
int ThermistorPin13 = 13; // Analogsignal Sensor Zylinder 4 an Pin Analog_In 13
int Vo;
int Seitenzahl;
int Zyl_1, Zyl_2, Zyl_3, Zyl_4, Oil_in, Oil_out, Zyl_1_old, Zyl_2_old, Zyl_3_old, Zyl_4_old, Oil_in_old, Oil_out_old;
bool T_Zyl_1_Fail, T_Zyl_2_Fail, T_Zyl_3_Fail, T_Zyl_4_Fail, T_Oil_in_Fail, T_Oil_out_Fail, Global_Fail;
float R1 = 10000;
float logR2, R2, T, T_Zyl_1, T_Zyl_2, T_Zyl_3, T_Zyl_4, T_Oil_in, T_Oil_out;
float c1 = 1.009249522e-03, c2 = 2.378405444e-04, c3 = 2.019202697e-07;
void setup() {
Serial.begin(9600);
tft.begin();
ts.begin();
Seitenzahl = 0;
//*******************QUERFORMAT*********************
tft.setRotation(-1);
//*******************HINTERGRUND*********************
tft.fillScreen(ILI9341_BLACK);
//*******************ÜBERSCHRIFT*********************
tft.setCursor(60, 100);
tft.setTextColor(ILI9341_WHITE);
tft.setTextSize(4);
tft.print("VW KÄFER");
}
//****************************************************************************************
void loop()
{
while (Seitenzahl == 0)
{
SEITE_BITMAP();
}
while (Seitenzahl == 1)
{
SEITE_TEMPERATUREN();
}
while (Seitenzahl == 2)
{
SEITE_2();
}
}
//****************************************************************************************
//****************************** S E I T E 0 ***************************************
//****************************************************************************************
void SEITE_BITMAP()
{
//***************SPRUNG ZU SEITE 1*********************
if (ts.touched())
{
Seitenzahl = 1;
}
}
//****************************************************************************************
//****************************** S E I T E 1 ***************************************
//****************************************************************************************
void SEITE_TEMPERATUREN()
{
//*******************QUERFORMAT*********************
tft.setRotation(-1);
//*******************HINTERGRUND*********************
tft.fillScreen(ILI9341_BLACK);
//*******************LINIEN************************** //Linie: tft.drawLine(x1, y1, x2, y2, color);
tft.drawLine(0, 26, 320, 26, ILI9341_GREEN); // waagerechte Linien
tft.drawLine(0, 133, 320, 133, ILI9341_GREEN);
tft.drawLine(77, 26, 77, 240, ILI9341_GREEN); // senkrechte Linien
tft.drawLine(159, 26, 159, 240, ILI9341_GREEN);
tft.drawLine(241, 26, 241, 133, ILI9341_GREEN);
//*******************ÜBERSCHRIFT*********************
tft.setCursor(50, 0);
tft.setTextColor(ILI9341_BLUE);
tft.setTextSize(3);
tft.print("TEMPERATUREN");
//**************EINHEITEN & BEZEICHNUNGEN**************
tft.setCursor(3, 137); // Bezeichnung Öl Vorlauf
tft.setTextColor(ILI9341_WHITE);
tft.setTextSize(2);
tft.print("Oil");
tft.setTextSize(1);
tft.print(" ");
tft.setTextSize(2);
tft.print("in");
tft.setCursor(81, 137); // Bezeichnung Öl Rücklauf
tft.setTextColor(ILI9341_WHITE);
tft.setTextSize(2);
tft.print("Oil");
tft.setTextSize(1);
tft.print(" ");
tft.setTextSize(2);
tft.print("out");
tft.setCursor(6, 30); // Bezeichnung Zylinder 1
tft.setTextColor(ILI9341_WHITE);
tft.setTextSize(2);
tft.print("Zyl 1");
tft.setCursor(88, 30); // Bezeichnung Zylinder 2
tft.setTextColor(ILI9341_WHITE);
tft.setTextSize(2);
tft.print("Zyl 2");
tft.setCursor(170, 30); // Bezeichnung Zylinder 3
tft.setTextColor(ILI9341_WHITE);
tft.setTextSize(2);
tft.print("Zyl 3");
tft.setCursor(252, 30); // Bezeichnung Zylinder 4
tft.setTextColor(ILI9341_WHITE);
tft.setTextSize(2);
tft.print("Zyl 4");
tft.setCursor(19, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Zyl_1);
tft.setTextSize(1);
tft.print(" C");
tft.setCursor(101, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Zyl_2);
tft.setTextSize(1);
tft.print(" C");
tft.setCursor(183, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Zyl_3);
tft.setTextSize(1);
tft.print(" C");
tft.setCursor(265, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Zyl_4);
tft.setTextSize(1);
tft.print(" C");
tft.setCursor(19, 180);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Oil_in);
tft.setTextSize(1);
tft.print(" C");
tft.setCursor(101, 180);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Oil_out);
tft.setTextSize(1);
tft.print(" C");
//**************RECHTECK MIT PFEIL -- VON SEITE 1 ZU SEITE 2 BLÄTTERN**************
tft.fillRect(269, 210, 50, 30, ILI9341_WHITE);
tft.setCursor(272, 218);
tft.setTextColor(ILI9341_BLACK);
tft.setTextSize(2);
tft.print(" -> ");
while (Seitenzahl == 1)
{
// Zylinder_1
Vo = analogRead(ThermistorPin10);
R2 = R1 * (1023.0 / (float)Vo - 1.0);
logR2 = log(R2);
T = (1.0 / (c1 + c2*logR2 + c3*logR2*logR2*logR2));
T_Zyl_1 = T - 273.15;
if (T_Zyl_1 == -273.15) // Überprüfung Sensor - defekter oder nicht angeschlossener Sensor gibt "-273,15" aus
{
(T_Zyl_1_Fail = 1);
}
if (T_Zyl_1 != -273.15)
{
(T_Zyl_1_Fail = 0);
}
Zyl_1 = T_Zyl_1; // float to integer
// Zylinder_2
Vo = analogRead(ThermistorPin11);
R2 = R1 * (1023.0 / (float)Vo - 1.0);
logR2 = log(R2);
T = (1.0 / (c1 + c2*logR2 + c3*logR2*logR2*logR2));
T_Zyl_2 = T - 273.15;
if (T_Zyl_2 == -273.15) // Überprüfung Sensor - defekter oder nicht angeschlossener Sensor gibt "-273,15" aus
{
(T_Zyl_2_Fail = 1);
}
if (T_Zyl_2 != -273.15)
{
(T_Zyl_2_Fail = 0);
}
Zyl_2 = T_Zyl_2; // float to integer
// Zylinder_3
Vo = analogRead(ThermistorPin12);
R2 = R1 * (1023.0 / (float)Vo - 1.0);
logR2 = log(R2);
T = (1.0 / (c1 + c2*logR2 + c3*logR2*logR2*logR2));
T_Zyl_3 = T - 273.15;
if (T_Zyl_3 == -273.15) // Überprüfung Sensor - defekter oder nicht angeschlossener Sensor gibt "-273,15" aus
{
(T_Zyl_3_Fail = 1);
}
if (T_Zyl_3 != -273.15)
{
(T_Zyl_3_Fail = 0);
}
Zyl_3 = T_Zyl_3; // float to integer
// Zylinder_4
Vo = analogRead(ThermistorPin13);
R2 = R1 * (1023.0 / (float)Vo - 1.0);
logR2 = log(R2);
T = (1.0 / (c1 + c2*logR2 + c3*logR2*logR2*logR2));
T_Zyl_4 = T - 273.15;
if (T_Zyl_4 == -273.15) // Überprüfung Sensor - defekter oder nicht angeschlossener Sensor gibt "-273,15" aus
{
(T_Zyl_4_Fail = 1);
}
if (T_Zyl_4 != -273.15)
{
(T_Zyl_4_Fail = 0);
}
Zyl_4 = T_Zyl_4; // float to integer
// Öl Vorlauf
Vo = analogRead(ThermistorPin08);
R2 = R1 * (1023.0 / (float)Vo - 1.0);
logR2 = log(R2);
T = (1.0 / (c1 + c2*logR2 + c3*logR2*logR2*logR2));
T_Oil_in = T - 273.15;
if (T_Oil_in == -273.15) // Überprüfung Sensor - defekter oder nicht angeschlossener Sensor gibt "-273,15" aus
{
(T_Oil_in_Fail = 1);
}
if (T_Oil_in != -273.15)
{
(T_Oil_in_Fail = 0);
}
Oil_in = T_Oil_in; // float to integer
// Öl Rücklauf
Vo = analogRead(ThermistorPin09);
R2 = R1 * (1023.0 / (float)Vo - 1.0);
logR2 = log(R2);
T = (1.0 / (c1 + c2*logR2 + c3*logR2*logR2*logR2));
T_Oil_out = T - 273.15;
if (T_Oil_out == -273.15) // Überprüfung Sensor - defekter oder nicht angeschlossener Sensor gibt "-273,15" aus
{
(T_Oil_out_Fail = 1);
}
if (T_Oil_out != -273.15)
{
(T_Oil_out_Fail = 0);
}
Oil_out = T_Oil_out; // float to integer
// SAMMELSTÖRUNG
Global_Fail = T_Zyl_1_Fail or T_Zyl_2_Fail or T_Zyl_3_Fail or T_Zyl_4_Fail or T_Oil_in_Fail or T_Oil_out_Fail;
//*******************SERIELLER MONITOR**************************
Serial.print("Zylinder 1: ");
Serial.print(T_Zyl_1);
Serial.print("°C ");
Serial.print("Zylinder 2: ");
Serial.print(T_Zyl_2);
Serial.print("°C ");
Serial.print("Zylinder 3: ");
Serial.print(T_Zyl_3);
Serial.print("°C ");
Serial.print("Zylinder 4: ");
Serial.print(T_Zyl_4);
Serial.print("°C ");
Serial.print("Öl Vorlauf: ");
Serial.print(T_Oil_in);
Serial.print("°C ");
Serial.print("Öl Rücklauf: ");
Serial.print(T_Oil_out);
Serial.println("°C");
delay(500);
//*******************WERTE UND TEXTE**ZYLINDER 1***************
if (T_Zyl_1 == -273.15) // Ausfall Sensor Zylinder 1
{
tft.fillRect(0, 70, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(0, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(" -----");
}
if (Zyl_1_old != Zyl_1) // Temperatur Zylinder 1
{
tft.fillRect(0, 70, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(19, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Zyl_1);
tft.setTextSize(1);
tft.print(" C");
Zyl_1_old = Zyl_1;
}
//*******************WERTE UND TEXTE**ZYLINDER 2***************
if (T_Zyl_2 == -273.15) // Ausfall Sensor Zylinder 1
{
tft.fillRect(82, 70, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(82, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(" -----");
}
if (Zyl_2_old != Zyl_2) // Temperatur Zylinder 2
{
tft.fillRect(82, 70, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(101, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Zyl_2);
tft.setTextSize(1);
tft.print(" C");
Zyl_2_old = Zyl_2;
}
//*******************WERTE UND TEXTE**ZYLINDER 3***************
if (T_Zyl_3 == -273.15) // Ausfall Sensor Zylinder 3
{
tft.fillRect(164, 70, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(164, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(" -----");
}
if (Zyl_3_old != Zyl_3) // Temperatur Zylinder 3
{
tft.fillRect(164, 70, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(183, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Zyl_3);
tft.setTextSize(1);
tft.print(" C");
Zyl_3_old = Zyl_3;
}
//*******************WERTE UND TEXTE**ZYLINDER 4***************
if (T_Zyl_4 == -273.15) // Ausfall Sensor Zylinder 4
{
tft.fillRect(246, 70, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(246, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(" -----");
}
if (Zyl_4_old != Zyl_4) // Temperatur Zylinder 4
{
tft.fillRect(246, 70, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(265, 70);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Zyl_4);
tft.setTextSize(1);
tft.print(" C");
Zyl_4_old = Zyl_4;
}
//*******************WERTE UND TEXTE**ÖL VORLAUF***************
if (T_Oil_in == -273.15) // Ausfall Sensor Öl Vorlauf
{
tft.fillRect(0, 180, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(0, 180);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(" -----");
}
if (Oil_in_old != Oil_in) // Temperatur Öl Vorlauf
{
tft.fillRect(0, 180, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(19, 180);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Oil_in);
tft.setTextSize(1);
tft.print(" C");
Oil_in_old = Oil_in;
}
//*******************WERTE UND TEXTE**ÖL RÜCKLAUF***************
if (T_Oil_out == -273.15) // Ausfall Sensor Öl Rücklauf
{
tft.fillRect(82, 180, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(82, 180);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(" -----");
}
if (Oil_out_old != Oil_out) // Temperatur Öl Rücklauf
{
tft.fillRect(82, 180, 77, 15, ILI9341_BLACK); // Messwert mit schwarzem Rechteck überschreiben
tft.setCursor(101, 180);
tft.setTextColor(ILI9341_GREEN);
tft.setTextSize(2);
tft.print(Oil_out);
tft.setTextSize(1);
tft.print(" C");
Oil_out_old = Oil_out;
}
//*******************WERTE UND TEXTE**SAMMELSTÖRUNG***************
if (Global_Fail == 1) // Event Sammelstörung
{
tft.fillRect(229, 170, 61, 40, ILI9341_RED); // Rotes Quadrat rechts unten in der Ecke
tft.setCursor(230, 185);
tft.setTextColor(ILI9341_WHITE);
tft.setTextSize(2);
tft.print("ALARM");
}
if (Global_Fail == 0) // Event Sammelstörung
{
tft.fillRect(229, 170, 61, 40, ILI9341_BLACK); // Rotes Quadrat rechts unten in der Ecke überschreiben
}
//***************************PUSH-BEFEHL -- VON SEITE 1 ZU SEITE 2 BLÄTTERN***************************
if (ts.touched())
{
TS_Point p = ts.getPoint();
p.x = map(p.x, 0, 240, 240, 0);
p.y = map(p.y, 0, 320, 320, 0);
int x = p.x;
int y = p.y;
if( x > 210 && x < 240 && y > 0 && y < 50 && Seitenzahl == 1)
{
Seitenzahl = 2;
Serial.println("Softbutton: vor zu Seite 2");
}
}
}
}
//****************************************************************************************
//****************************** S E I T E 2 ***************************************
//****************************************************************************************
void SEITE_2()
{
//*******************QUERFORMAT*********************
tft.setRotation(-1);
//*******************HINTERGRUND*********************
tft.fillScreen(ILI9341_BLACK);
//*******************ÜBERSCHRIFT*********************
tft.setRotation(-1);
tft.setCursor(85, 0);
tft.setTextColor(ILI9341_RED);
tft.setTextSize(3);
tft.print("DREHZAHL");
tft.drawLine(0, 26, 320, 26, ILI9341_GREEN); // waagerechte Linien
//**************RECHTECK MIT PFEIL -- VON SEITE 2 ZU SEITE 1 BLÄTTERN**************
tft.fillRect(0, 210, 50, 30, ILI9341_WHITE);
tft.setCursor(3, 218);
tft.setTextColor(ILI9341_BLACK);
tft.setTextSize(2);
tft.print(" <- ");
while (Seitenzahl == 2)
{
//***************************PUSH-BEFEHL -- VON SEITE 2 ZU SEITE 1 BLÄTTERN***************************
if (ts.touched())
{
TS_Point p = ts.getPoint();
p.x = map(p.x, 0, 240, 240, 0);
p.y = map(p.y, 0, 320, 320, 0);
int x = p.x;
int y = p.y;
if( x > 210 && x < 240 && y > 270 && y < 320 && Seitenzahl == 2)
{
Seitenzahl = 1;
Serial.println("Softbutton: zurück zu Seite 1");
}
}
}
}