Go Down

Topic: WebServerSD.h (Read 1 time) previous topic - next topic

davideanubi

Ciao a tutti volevo provare questa libreria.... premetto io uso ide 1.0.3 arduino..... la carico e mi da una marea di errori... ma senza evidenziarli nello sketch.... qualcuno sa il perchè?????
Grazie

davideanubi

#1
Feb 23, 2013, 06:36 pm Last Edit: Feb 23, 2013, 11:29 pm by leo72 Reason: 1
dimenticavo vi posto gli errori che mi da....

Code: [Select]

In file included from sketch_feb23a.ino:4:
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:41: error: ISO C++ forbids declaration of 'Sd2Card' with no type
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:41: error: expected ';' before '*' token
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:42: error: expected `;' before 'bool'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:68: error: ISO C++ forbids declaration of 'SdVolume' with no type
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:68: error: expected ';' before '*' token
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:70: error: expected `;' before 'SdBaseFile'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:70: error: ISO C++ forbids declaration of 'SdBaseFile' with no type
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:70: error: expected ';' before '*' token
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:71: error: expected `;' before 'private'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:72: error: 'Sd2Card' does not name a type
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:73: error: 'SdVolume' does not name a type
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:74: error: 'SdBaseFile' does not name a type
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:52: error: 'SPI_FULL_SPEED' was not declared in this scope
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\SdFat/SdFat.h:53: error: 'SD_CHIP_SELECT_PIN' was not declared in this scope
In file included from sketch_feb23a.ino:6:
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:233: error: 'SdFile' has not been declared
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:226: error: conflicting return type specified for 'virtual void WebServer::write(uint8_t)'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Print.h:48: error:   overriding 'virtual size_t Print::write(uint8_t)'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:228: error: conflicting return type specified for 'virtual void WebServer::write(const uint8_t*, size_t)'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Print.h:53: error:   overriding 'virtual size_t Print::write(const uint8_t*, size_t)'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:257: error: cannot declare field 'WebServer::m_server' to be of abstract type 'Server'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Server.h:4: note:   because the following virtual functions are pure within 'Server':
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Print.h:48: note: virtual size_t Print::write(uint8_t)
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Server.h:6: note: virtual void Server::begin()
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:258: error: cannot declare field 'WebServer::m_client' to be of abstract type 'Client'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:7: note:   because the following virtual functions are pure within 'Client':
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:12: note: virtual size_t Client::write(uint8_t)
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:13: note: virtual size_t Client::write(const uint8_t*, size_t)
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:14: note: virtual int Client::available()
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:15: note: virtual int Client::read()
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:17: note: virtual int Client::peek()
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:18: note: virtual void Client::flush()
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:10: note: virtual int Client::connect(IPAddress, uint16_t)
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:11: note: virtual int Client::connect(const char*, uint16_t)
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:16: note: virtual int Client::read(uint8_t*, size_t)
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:19: note: virtual void Client::stop()
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:20: note: virtual uint8_t Client::connected()
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:21: note: virtual Client::operator bool()
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h: In constructor 'WebServer::WebServer(const char*, int)':
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:311: error: no matching function for call to 'Server::Server(int&)'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Server.h:4: note: candidates are: Server::Server(const Server&)
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Server.h:4: note:                 Server::Server()
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:311: error: no matching function for call to 'Client::Client(int)'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:7: note: candidates are: Client::Client(const Client&)
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\hardware\arduino\cores\arduino/Client.h:7: note:                 Client::Client()
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h: In member function 'virtual void WebServer::write(const char*)':
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:355: error: invalid conversion from 'const char*' to 'uint8_t'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:355: error:   initializing argument 1 of 'virtual size_t Client::write(uint8_t)'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h: In member function 'void WebServer::processConnection(char*, int*)':
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:477: error: 'class Server' has no member named 'available'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h: At global scope:
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:1004: error: variable or field 'send_file' declared void
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:1004: error: 'SdFile' was not declared in this scope
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:1004: error: 'file' was not declared in this scope
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:1004: error: expected primary-expression before 'char'
C:\Users\Davide\Desktop\arduino-1.0.3-windows\arduino-1.0.3\libraries\WebServerSD/WebServerSD.h:1004: error: expected primary-expression before 'char'


edit by mod: per favore includi il codice usando gli appositi tag

Testato

metti il link alla libreria, cosi' la possiamo rpovare.
non e' quella standard dell'ide.
- [Guida] IDE - http://goo.gl/ln6glr
- [Lib] ST7032i LCD I2C - http://goo.gl/GNojT6
- [Lib] PCF8574+HD44780 LCD I2C - http://goo.gl/r7CstH

davideanubi

   
Ok ti allego i link da scaricare.....

WebserverSD con la possibilità di cliccare le lampadine, io più che altro lo uso come status dell'impianto.
http://dl.dropbox.com/u/568105/libraries.rar
http://dl.dropbox.com/u/568105/Webserver24_pulito2.pde
http://dl.dropbox.com/u/568105/html_SD.rar

davideanubi

"http://dl.dropbox.com/u/568105/libraries.rar"
"http://dl.dropbox.com/u/568105/Webserver24_pulito2.pde"
"http://dl.dropbox.com/u/568105/html_SD.rar"

Testato

non era questa la mia richiesta,
io credo che se tu posti il link alla pagina ufficiale del programmatore che ha creato la libreria iniziamo a capire tutti di piu'.
- [Guida] IDE - http://goo.gl/ln6glr
- [Lib] ST7032i LCD I2C - http://goo.gl/GNojT6
- [Lib] PCF8574+HD44780 LCD I2C - http://goo.gl/r7CstH

davideanubi

Ciao... guarda non ne ho idea.. questi me l'aveva dati un utente... e mi aveva detto che ha lui funzionava

Testato

io ho rpovato a cercare ma non ho trovato rifwerimenti ufficiali.
ma lo sketch di esempio ufficiale WebServer, presente nell'ide, ti funziona ?
Non puoi usare quello ufficiale e modificarlo a tuo piacere ?

- [Guida] IDE - http://goo.gl/ln6glr
- [Lib] ST7032i LCD I2C - http://goo.gl/GNojT6
- [Lib] PCF8574+HD44780 LCD I2C - http://goo.gl/r7CstH

leo72

Scusa, potresti pubblicare il codice che stai usando? Quelli sembrano errori di sintassi, il compilatore ti sta avvertendo di cosa ha trovato. Potrebbe anche essere di compatibilità fra versioni differenti dell'IDE: difatti i file .pde erano quelli generati dall'IDE 002x mentre tu stai usando l'IDE 1.0.3. Hai provato a compilare il tuo programma con l'IDE 0022 o 0023?

pablos


Ciao... guarda non ne ho idea.. questi me l'aveva dati un utente... e mi aveva detto che ha lui funzionava


Probabilmente fa riferimento a me, (stiamo discutendo la stessa cosa in 2 treadh diversi) http://arduino.cc/forum/index.php/topic,150196.15.html

in un vecchio post usavo la  SdFat, ma in quegli esempi l'IDE era 0022 e funzionava, l'avevo specificato nel post i requisiti del sistema in uso.
no comment

davideanubi

Ciao a tutti....Pablos non mi riferisco a l'altra discussone che abbiamo si Tiny.... ma un ragazzo tempo fa mia aveva dato quei link sopracitati.
L'utente e Mauroz.....
Io ho provato lo sketch che mi ha rilasciato lui...."http://dl.dropbox.com/u/568105/Webserver24_pulito2.pde" che è questo qui...
Ho corretto gli errori che mi evidenziava come faccio di solito.... dopodiché continua a segnalarmi errori ma non me li evidenzia... quindi diventa un problema per me... non l'ho provato con altri IDE ma solo con 1.0.3 e sicuramente sarà quello il problema....

Testato

Pablos tu che sei più esperto in questo campo, fammi capire, oltre a webduino ed a tinywebserver esiste una terzai reria CBE si chiama WebserverSD ?
- [Guida] IDE - http://goo.gl/ln6glr
- [Lib] ST7032i LCD I2C - http://goo.gl/GNojT6
- [Lib] PCF8574+HD44780 LCD I2C - http://goo.gl/r7CstH

davideanubi

Si esiste te l'ho anche postata ed è questa "http://dl.dropbox.com/u/568105/libraries.rar" se tu la scompatti all'interno trovi la libreria WebServerSD.....

Testato

Non dico che non esiste, vovlio capire se è una modifica di un a delle due o una del tutto diversa. Cm hai provato ad usarla sulla IDE 023 ?
- [Guida] IDE - http://goo.gl/ln6glr
- [Lib] ST7032i LCD I2C - http://goo.gl/GNojT6
- [Lib] PCF8574+HD44780 LCD I2C - http://goo.gl/r7CstH

pablos

#14
Feb 24, 2013, 03:00 pm Last Edit: Feb 24, 2013, 03:03 pm by pablos Reason: 1

Si esiste te l'ho anche postata ed è questa "http://dl.dropbox.com/u/568105/libraries.rar" se tu la scompatti all'interno trovi la libreria WebServerSD.....


io non l'ho mai incontrata :)

WebServerSD.h è una modifica della webduino
Code: [Select]

#define WEBDUINO_VERSION 1004
#define WEBDUINO_VERSION_STRING "1.4"

#if WEBDUINO_SUPRESS_SERVER_HEADER
#define WEBDUINO_SERVER_HEADER ""
#else
#define WEBDUINO_SERVER_HEADER "Server: Webduino/" WEBDUINO_VERSION_STRING CRLF
#endif
no comment

Go Up