Problème avec le code de NetIO

Salut à tous.

J'ai quelques soucis avec un code que j'ai trouvé sur le web.
Il sert à faire fontionner NetIO sous Android :
https://play.google.com/store/apps/details?id=com.luvago.netio
Site web : http://netio.davideickhoff.de/
Afin d'un faire facilement une télécommande.
Mais j'ai des erreurs dans le code fournis.
Qui comme on peut le voir dans le code, est prévus pour la version 0022.
Et qui comporte une librairie externe à télécharger.

/*

 IDE Version 0022
 Arduino Uno
 Arduino Ethernet Shield with Wiznet W5100 Ethernet chip
 
 */

// include library 
#include <SPI.h>
#include <Ethernet.h>
#include <EthernetDHCP.h>    // library from http://gkaindl.com/software/arduino-ethernet/dhcp
// end include library
#define DEBUG 1
//global variable
byte mac[] = { 
  0xAA, 0xAA, 0xAA, 0xAA, 0xAA, 0xAA };    // mac address of Ethernet shield
//----- iPhone Remote -------

#define BUFSIZ 64
Server iPhoneServer(2560);      // server port number of Ethernet shield

//---------------------------

// setup
void setup(){
  Serial.begin(115200); //for debug

  if (DEBUG) Serial.println("Attempting to obtain a DHCP lease...");
  EthernetDHCP.begin(mac);

  if (DEBUG) {
    const byte* ipAddr = EthernetDHCP.ipAddress();
    const byte* gatewayAddr = EthernetDHCP.gatewayIpAddress();
    const byte* dnsAddr = EthernetDHCP.dnsIpAddress();

    Serial.println("A DHCP lease has been obtained.");

    Serial.print("My IP address is ");
    Serial.println(ip_to_str(ipAddr));

    Serial.print("Gateway IP address is ");
    Serial.println(ip_to_str(gatewayAddr));

    Serial.print("DNS IP address is ");
    Serial.println(ip_to_str(dnsAddr));
  }

  iPhoneServer.begin();           // start the server

}
// end setup

// main loop
void loop()
{
  EthernetDHCP.maintain();        // Call this once per loop().
  iPhoneInterface();

}
// end main loop

void iPhoneInterface() {

  int index = 0;
  char Remote[BUFSIZ];

  Client client = iPhoneServer.available();
  if (client) {
    if (client.connected()) {
      while (client.available()) {
        char c = client.read();
        //Serial.print(c);                      // print to the screen
        if (c != '\n' && c != '\r') {           // no linefeed or CR so keep reading
          Remote[index] = c;
          index++;
          if (index >= BUFSIZ) 
            index = BUFSIZ -1;
          continue;
        }

        Remote[index] = 0;

      }

      Serial.println(Remote);                  // print string sent from iPhone


        if (strstr(Remote, "Local")) {          // initialsend
        client.println("OK");

      }

      if (strstr(Remote, "X10")) {            // is it an X10 command
        client.println("OK");
      }

      if (strstr(Remote, "FireLights")) {     // set the slider to 0
        client.println("0");

      }

      if (strstr(Remote, "Fire lights")) {    // is it a slider value
        client.println("OK");

      }

      if (strstr(Remote, "DoorLights")) {    // set the slider to 0
        client.println("0");

      }

      if (strstr(Remote, "Door lights")) {    // is it a slider value
        client.println("OK");

      }

    } //----- End of if client.connected
  } //------- End of if client
} //--------- End of iPhoneInterface()

//---------- Just a utility function to nicely format an IP address. ------------
const char* ip_to_str(const uint8_t* ipAddr)
{
  static char buf[16];
  sprintf(buf, "%d.%d.%d.%d\0", ipAddr[0], ipAddr[1], ipAddr[2], ipAddr[3]);
  return buf;
}

Merci d'avance pour aide.

EEEeeuuuhhhh Android ou iOS ???!

B@tto:
EEEeeuuuhhhh Android ou iOS ???!

Je suis sous Android, mais le code Arduino devrais fonctionner avec les deux, puisqu'il ce contente de recevoir des commandes du smartphone.
Mais le code Arduino est ancien (version 022) alors que la version actuelle est 1.0.1.

Ah oui en effet j'avais lu trop vite, ce n'est qu'un nom d'emprunt ^^

Par contre il va falloir détailler un peu plus les erreurs que tu rencontres sinon personne ne pourra t'aider

Voilà (pour commencer) :

NetIOServer:19: error: no matching function for call to 'Server::Server(int)'

Depuis Arduino 1.0, la classe Server de la bibliothèque Ethernet a été renommée en EthernetServer.

C:\arduino-1.0.1\hardware\arduino\cores\arduino/Server.h:4: note: candidates are: Server::Server()
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Server.h:4: note:                 Server::Server(const Server&)
NetIOServer:19: error: cannot declare variable 'iPhoneServer' to be of abstract type 'Server'
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Server.h:4: note:   because the following virtual functions are pure within 'Server':
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Print.h:48: note: 	virtual size_t Print::write(uint8_t)
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Server.h:6: note: 	virtual void Server::begin()
NetIOServer.cpp: In function 'void setup()':
NetIOServer:33: error: 'EthernetDHCP' was not declared in this scope
NetIOServer.cpp: In function 'void loop()':
NetIOServer:63: error: 'EthernetDHCP' was not declared in this scope
NetIOServer.cpp: In function 'void iPhoneInterface()':
NetIOServer:76: error: 'class Server' has no member named 'available'
NetIOServer:76: error: cannot declare variable 'client' to be of abstract type 'Client'
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:7: note:   because the following virtual functions are pure within 'Client':
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:12: note: 	virtual size_t Client::write(uint8_t)
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:13: note: 	virtual size_t Client::write(const uint8_t*, size_t)
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:14: note: 	virtual int Client::available()
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:15: note: 	virtual int Client::read()
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:17: note: 	virtual int Client::peek()
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:18: note: 	virtual void Client::flush()
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:10: note: 	virtual int Client::connect(IPAddress, uint16_t)
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:11: note: 	virtual int Client::connect(const char*, uint16_t)
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:16: note: 	virtual int Client::read(uint8_t*, size_t)
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:19: note: 	virtual void Client::stop()
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:20: note: 	virtual uint8_t Client::connected()
C:\arduino-1.0.1\hardware\arduino\cores\arduino/Client.h:21: note: 	virtual Client::operator bool()

J'ai bien essayé de renomer Ethernet en EthernetServer, mais cela me fait d'autres erreurs.

Bon alors j'ai résolu le problème en trouvant cette page :
http://projects.ottech.net/index.php/arduino/5-netio-controller-app-mit-arduino
Là, le code fonctionne.
Cela permet de faire une télécommande facilement en ligne sans connaitre la programmation Android.
Voir le site plus haut.
Merci quand même à tous.