Boa Tarde, estou com um projeto em contrução baseado no projeot que o Fernando k postou sobre alarme e automação com esp, porem estou com problemas em rodar o código, logo que verifico o código que baixei no link do blog (https://www.fernandok.com/2018/12/esp32 ... reira.html) ele ja acusa um erro, o qual nao estou conseguindo solucionar.
Segue o erro:
Arduino: 1.8.12 (Windows 7), Placa:"Arduino Uno"
ESP32_SIM800L:24:27: error: no matching function for call to 'HardwareSerial::HardwareSerial(int)'
HardwareSerial SerialGSM(1);
^
In file included from C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/Arduino.h:233:0,
from C:\Users\Tatiana\AppData\Local\Temp\Rar$DIa0.243\ESP32_SIM800L\ESP32_SIM800L.ino:1:
C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/HardwareSerial.h:117:12: note: candidate: HardwareSerial::HardwareSerial(volatile uint8_t*, volatile uint8_t*, volatile uint8_t*, volatile uint8_t*, volatile uint8_t*, volatile uint8_t*)
inline HardwareSerial(
^~~~~~~~~~~~~~
C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/HardwareSerial.h:117:12: note: candidate expects 6 arguments, 1 provided
C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/HardwareSerial.h:93:7: note: candidate: constexpr HardwareSerial::HardwareSerial(const HardwareSerial&)
class HardwareSerial : public Stream
^~~~~~~~~~~~~~
C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/HardwareSerial.h:93:7: note: no known conversion for argument 1 from 'int' to 'const HardwareSerial&'
C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/HardwareSerial.h:93:7: note: candidate: constexpr HardwareSerial::HardwareSerial(HardwareSerial&&)
C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/HardwareSerial.h:93:7: note: no known conversion for argument 1 from 'int' to 'HardwareSerial&&'
C:\Users\Tatiana\AppData\Local\Temp\Rar$DIa0.243\ESP32_SIM800L\ESP32_SIM800L.ino: In function 'void setupGSM()':
ESP32_SIM800L:81:63: error: no matching function for call to 'HardwareSerial::begin(const int&, int, const int&, const int&, bool)'
SerialGSM.begin(BAUD_RATE, SERIAL_8N1, RX_PIN, TX_PIN, false);
^
In file included from C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/Arduino.h:233:0,
from C:\Users\Tatiana\AppData\Local\Temp\Rar$DIa0.243\ESP32_SIM800L\ESP32_SIM800L.ino:1:
C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/HardwareSerial.h:121:10: note: candidate: void HardwareSerial::begin(long unsigned int)
void begin(unsigned long baud) { begin(baud, SERIAL_8N1); }
^~~~~
C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/HardwareSerial.h:121:10: note: candidate expects 1 argument, 5 provided
C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/HardwareSerial.h:122:10: note: candidate: void HardwareSerial::begin(long unsigned int, uint8_t)
void begin(unsigned long, uint8_t);
^~~~~
C:\Program Files\Arduino\hardware\arduino\avr\cores\arduino/HardwareSerial.h:122:10: note: candidate expects 2 arguments, 5 provided
ESP32_SIM800L:93:5: error: 'ESP' was not declared in this scope
ESP.restart();
^~~
C:\Users\Tatiana\AppData\Local\Temp\Rar$DIa0.243\ESP32_SIM800L\ESP32_SIM800L.ino:93:5: note: suggested alternative: 'SP'
ESP.restart();
^~~
SP
ESP32_SIM800L:104:5: error: 'ESP' was not declared in this scope
ESP.restart();
^~~
C:\Users\Tatiana\AppData\Local\Temp\Rar$DIa0.243\ESP32_SIM800L\ESP32_SIM800L.ino:104:5: note: suggested alternative: 'SP'
ESP.restart();
^~~
SP
ESP32_SIM800L:115:5: error: 'ESP' was not declared in this scope
ESP.restart();
^~~
C:\Users\Tatiana\AppData\Local\Temp\Rar$DIa0.243\ESP32_SIM800L\ESP32_SIM800L.ino:115:5: note: suggested alternative: 'SP'
ESP.restart();
^~~
SP
ESP32_SIM800L:127:5: error: 'ESP' was not declared in this scope
ESP.restart();
^~~
C:\Users\Tatiana\AppData\Local\Temp\Rar$DIa0.243\ESP32_SIM800L\ESP32_SIM800L.ino:127:5: note: suggested alternative: 'SP'
ESP.restart();
^~~
SP
Foram encontradas múltiplas bibliotecas para "TinyGsmClient.h"
Usado: C:\Users\Tatiana\Documents\Arduino\libraries\TinyGSM-master
Não usado: C:\Users\Tatiana\Documents\Arduino\libraries\TinyGSM-0.10.5
exit status 1
no matching function for call to 'HardwareSerial::HardwareSerial(int)'
Este relatório teria mais informações com
"Mostrar a saida detalhada durante a compilação"
opção pode ser ativada em "Arquivo -> Preferências"
Se alguem puder me ajudar, ja tentei vários metodos porém nao consegui solucionar.
Desde já grato...
ALARME E AUTOMAÇÃO COM ESP
-
- Novato
- Mensagens: 1
- Registrado em: 25/Abr/2020, 18:32