Ciao a tutti!
sono nuovo del forum e ho da poco acquistato Arduino uno R3 ed Ethernet Shield R3 ufficiale.
Vorrei realizzare, per la tesi di maturità indirizzo informatico, un progetto di domotica con Arduino.
Per familiarizzare con Arduino ho iniziato con piccoli programmi (far lampeggiare un led, controllo della temperatura con un trasduttore, ecc...) ed ora vorrei controllare questi programmi in remoto tramite l'ethernet shield ma mi sono trovato difronte ad un problema che non riesco a risolvere.
Ho caricato in Arduino il programma di prova per l'ethernet shield che ho trovato all'indirizzo Ethernet - Arduino Reference ma il compilatore mi da questi problemi:
sketch_dec28b.cpp:10:25: error: no matching function for call to ‘Client::Client(byte [4], int)’
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:7:30: note: candidates are: Client::Client()
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:7:30: note: Client::Client(const Client&)
sketch_dec28b.cpp:10:15: error: cannot declare variable ‘client’ to be of abstract type ‘Client’
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:7:30: note: because the following virtual functions are pure within ‘Client’:
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:12:18: note: virtual size_t Client::write(uint8_t)
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:13:18: note: virtual size_t Client::write(const uint8_t*, size_t)
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:14:15: note: virtual int Client::available()
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:15:15: note: virtual int Client::read()
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:17:15: note: virtual int Client::peek()
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:18:16: note: virtual void Client::flush()
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:10:15: note: virtual int Client::connect(IPAddress, uint16_t)
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:11:15: note: virtual int Client::connect(const char*, uint16_t)
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:16:15: note: virtual int Client::read(uint8_t*, size_t)
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:19:16: note: virtual void Client::stop()
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:20:19: note: virtual uint8_t Client::connected()
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:21:11: note: virtual Client::operator bool()
sketch_dec28b.cpp: In function ‘void setup()’:
sketch_dec28b.cpp:21:22: error: no matching function for call to ‘Client::connect()’
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:10:15: note: candidates are: virtual int Client::connect(IPAddress, uint16_t)
/home/druss/arduino-1.0/hardware/arduino/cores/arduino/Client.h:11:15: note: virtual int Client::connect(const char*, uint16_t)
Il software che ho installato è l'Arduino 1.0
Premetto che non conosco il C++ ma temo che l'errore sia dovuto ad un'errata inizializzazione dell'oggetto di classe Client:
Client client(server, 80);
qualcuno può aiutarmi a risolvere questo problema?