Danke noch mal für die Hilfe 
aktueller Stand: Habe die Keypad.h lib jetzt doch zum laufen bekommen. weiß nicht was voher falsch war aber hat auf ein mal funktioniert 
#include <Keypad.h>
const byte n_rows = 4;
const byte n_cols = 4;
char keys[n_rows][n_cols] = {
{'1','2','3','A'},
{'4','5','6','B'},
{'7','8','9','C'},
{'*','0','#','D'}
};
byte colPins[n_rows] = {D3, D2, D1, D0};
byte rowPins[n_cols] = {D7, D6, D5, D4};
Keypad myKeypad = Keypad( makeKeymap(keys), rowPins, colPins, n_rows, n_cols);
void setup(){
Serial.begin(115200);
}
void loop(){
char myKey = myKeypad.getKey();
if (myKey != NULL){
Serial.print("Key pressed: ");
Serial.println(myKey);
}
}
so jetzt aber zum nächsten Problem ... : den Wert von myKey würde ich gerne an meine Datenbank senden.
#include <ESP8266WiFi.h>
const char* ssid = "xxxxxxxxxxxxx";
const char* password = "xxxxxxxxxxxx";
const char* host = "xxxxxxxx"; //Web Server
void setup() {
//Serial Start
Serial.begin(115200);
delay(10);
// We start by connecting to a WiFi network
Serial.println();
Serial.println();
Serial.print("Connecting to ");
Serial.println(ssid);
WiFi.begin(ssid, password);
while (WiFi.status() != WL_CONNECTED) {
delay(500);
Serial.print(".");
}
Serial.println("");
Serial.println("WiFi connected");
Serial.println("IP address: ");
Serial.println(WiFi.localIP());
}
void loop() {
delay(100);
Serial.print("connecting to ");
Serial.println(host);
// Use WiFiClient class to create TCP connections
WiFiClient client;
const int httpPort = 80;
if (!client.connect(host, httpPort)) {
Serial.println("connection failed");
return;
}
// We now create a URI for the request
String url = "/CaptainEingabe.php?wert=";
url +=5;
Serial.print("Requesting URL: ");
Serial.println(url);
// This will send the request to the server
client.print(String("GET ") + url + " HTTP/1.1\r\n" +
"Host: " + host + "\r\n" +
"Connection: close\r\n\r\n");
Serial.println("Werte an WebServer uebergeben");
// Read all the lines of the reply from server and print them to Serial
while(client.available()){
String line = client.readStringUntil('\r');
//Serial.print(line);
}
Serial.println();
Serial.println("closing connection");
delay(1000);
}
unabhängig von einander funktioniert das einwandfrei.
Sobald ich aber die Keypad.h über ESP8266WiFi.h kopiere :
#include <Keypad.h>
#include <ESP8266WiFi.h>
bekomme ich diese Fehlermeldung:
In file included from sketch\xxx.ino.cpp:1:0:
C:\xxxxxx: error: expected identifier before numeric constant
#define HIGH 0x1
^
C:\Users\xxxxDocuments\Arduino\libraries\Keypad\src/Keypad.h:56:16: note: in expansion of macro 'HIGH'
#define CLOSED HIGH
^
C:\Users\xxxxAppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.4.0\libraries\ESP8266WiFi\src/include/wl_definitions.h:73:3: note: in expansion of macro 'CLOSED'
CLOSED = 0,
^
C:\Users\xxxx\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.4.0\cores\esp8266/Arduino.h:42:14: error: expected '}' before numeric constant
#define HIGH 0x1
^
C:\Users\xxxx\Documents\Arduino\libraries\Keypad\src/Keypad.h:56:16: note: in expansion of macro 'HIGH'
#define CLOSED HIGH
^
C:\Users\xxxx\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.4.0\libraries\ESP8266WiFi\src/include/wl_definitions.h:73:3: note: in expansion of macro 'CLOSED'
CLOSED = 0,
^
C:\Users\xxxxx\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.4.0\cores\esp8266/Arduino.h:42:14: error: expected unqualified-id before numeric constant
#define HIGH 0x1
^
C:\Users\xxxx\Documents\Arduino\libraries\Keypad\src/Keypad.h:56:16: note: in expansion of macro 'HIGH'
#define CLOSED HIGH
^
C:\Users\xxxx\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.4.0\libraries\ESP8266WiFi\src/include/wl_definitions.h:73:3: note: in expansion of macro 'CLOSED'
CLOSED = 0,
^
In file included from C:\Users\xxx\Documents\Arduino\darts1\darts1.ino:9:0:
C:\Users\xxxx\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\2.4.0\libraries\ESP8266WiFi\src/ESP8266WiFi.h:29:1: error: expected declaration before '}' token
}
^
exit status 1
Fehler beim Kompilieren für das Board WeMos D1 R2 & mini.
Jemand ne Ahnung was man da machen könnte ?^^