0

Got this module from Aliexpress enter image description here

W5500 Ethernet Network Modules For Arduino TCP/IP 51/STM32 SPI Interface 3.3V 5V I/O MCU

... and trying to hook this up to my proto Aduino Micro as thus:

Micro -> W5500 module

5V (J6.6) ->  5V   (I noted that it has a linear regulator to 3V3 on the W5500 board)

IO11 (J5.16) -> RST ... (I connected it to Pin 11 so that I can do a manual reset, to see if it made a difference, it didn't)

IO10 (J5.15-> SCS

SCLK (J6.1) -> SCLK

MISO (J6.2)-> MISO

MOSI (J5.1)-> MOSI

GND (J6.4)-> GND

I then used a modified version of WebServer to test the functioning of the module:

/*
  Web Server

 A simple web server that shows the value of the analog input pins.
 using an Arduino Wiznet Ethernet shield.

 Circuit:
 * Ethernet shield attached to pins 10, 11, 12, 13
 * Analog inputs attached to pins A0 through A5 (optional)

 created 18 Dec 2009
 by David A. Mellis
 modified 9 Apr 2012
 by Tom Igoe
 modified 02 Sept 2015
 by Arturo Guadalupi

 */

#include <SPI.h>
#include <Ethernet.h>

int counter = 0;
const int W5500_RESET_PIN = 11;     // the number of the pushbutton pin

// Enter a MAC address and IP address for your controller below.
// The IP address will be dependent on your local network:
byte mac[] = {
  0xDE, 0xED, 0xBE, 0xEF, 0xFE, 0xED
};
IPAddress ip(192, 168, 2, 177);

// Initialize the Ethernet server library
// with the IP address and port you want to use
// (port 80 is default for HTTP):
EthernetServer server(80);

void setup() {
  // Open serial communications and wait for port to open:
  Serial.begin(9600);
  while (!Serial) {
    ; // wait for serial port to connect. Needed for native USB port only
  }

  // Reset the W5500 module
  pinMode(W5500_RESET_PIN, OUTPUT);
  digitalWrite(W5500_RESET_PIN, HIGH);
  digitalWrite(W5500_RESET_PIN, LOW);
  delay(100);
  digitalWrite(W5500_RESET_PIN, HIGH);
  delay(100);

  // start the Ethernet connection and the server:
  Ethernet.begin(mac, ip);
  server.begin();
  Serial.print("server is at ");
  Serial.println(Ethernet.localIP());
}


void loop() {

  if (counter > 0) counter--;
  else
  {
    Serial.print("server is at ");
    Serial.println(Ethernet.localIP());
    counter = 10000;
  }

  // listen for incoming clients
  EthernetClient client = server.available();
  if (client) {
    Serial.println("new client");
    // an http request ends with a blank line
    boolean currentLineIsBlank = true;
    while (client.connected()) {
      if (client.available()) {
        char c = client.read();
        Serial.write(c);
        // if you've gotten to the end of the line (received a newline
        // character) and the line is blank, the http request has ended,
        // so you can send a reply
        if (c == '\n' && currentLineIsBlank) {
          // send a standard http response header
          client.println("HTTP/1.1 200 OK");
          client.println("Content-Type: text/html");
          client.println("Connection: close");  // the connection will be closed after completion of the response
          client.println("Refresh: 5");  // refresh the page automatically every 5 sec
          client.println();
          client.println("<!DOCTYPE HTML>");
          client.println("<html>");
          // output the value of each analog input pin
          for (int analogChannel = 0; analogChannel < 6; analogChannel++) {
            int sensorReading = analogRead(analogChannel);
            client.print("analog input ");
            client.print(analogChannel);
            client.print(" is ");
            client.print(sensorReading);
            client.println("<br />");
          }
          client.println("</html>");
          break;
        }
        if (c == '\n') {
          // you're starting a new line
          currentLineIsBlank = true;
        } else if (c != '\r') {
          // you've gotten a character on the current line
          currentLineIsBlank = false;
        }
      }
    }
    // give the web browser time to receive the data
    delay(1);
    // close the connection:
    client.stop();
    Serial.println("client disconnected");
  }
}

The code runs ok, and as you can see I'm printing out debug comms and monitoring using TeraTerm on the USB virtual port. However I'm seeing this output:

server is at 222.237.190.239

server is at 222.237.190.239

server is at 222.237.190.239

server is at 222.237.190.239

server is at 222.237.190.239

server is at 222.237.190.239

So ... the IP address didn't take, and needless to say that the webpage didn't show up when I typed in the IP address 192.168.2.177.

I've tried two identical W5500 modules so far and the problem persists for both in a consistent way. I've looked on the scope and I can see the SCLKs shooting across in 4 lots of clock bursts per each SCS low going pulse, with both the MISO and MOSI lines showing what appears to be "data" ... :)

The W5500 module itself has a power LED which is lit, the 5V is correctly regulating down to 3V3 and the 3V3 pin of the W5500 chipset IC appears to be connected. Both the LEDs on the ethernet balun appears to be turned on and blinking some of the times.

So ... erm ... help? ... what am I doing wrong? What else should I check?

2017-10-08 Update: Tried Ethernet2 library update from github adafruit ethernet2 libary.

But getting compiling errors now: Arduino: 1.6.12 (Windows 7), Board: "Arduino/Genuino Micro"

C:\Program Files (x86)\Arduino\arduino-builder -dump-prefs -logger=machine -hardware C:\Program Files (x86)\Arduino\hardware -tools C:\Program Files (x86)\Arduino\tools-builder -tools C:\Program Files (x86)\Arduino\hardware\tools\avr -built-in-libraries C:\Program Files (x86)\Arduino\libraries -libraries C:\Users\Hemon\Documents\Arduino\libraries -fqbn=arduino:avr:micro -vid-pid=0X2341_0X8037 -ide-version=10612 -build-path C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983 -warnings=none -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.avrdude.path=C:\Program Files (x86)\Arduino\hardware\tools\avr -prefs=runtime.tools.avr-gcc.path=C:\Program Files (x86)\Arduino\hardware\tools\avr -verbose Z:\Quantum Sensing Limited\Consulting Work\Arduino\WebServer\WebServer.ino
C:\Program Files (x86)\Arduino\arduino-builder -compile -logger=machine -hardware C:\Program Files (x86)\Arduino\hardware -tools C:\Program Files (x86)\Arduino\tools-builder -tools C:\Program Files (x86)\Arduino\hardware\tools\avr -built-in-libraries C:\Program Files (x86)\Arduino\libraries -libraries C:\Users\Hemon\Documents\Arduino\libraries -fqbn=arduino:avr:micro -vid-pid=0X2341_0X8037 -ide-version=10612 -build-path C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983 -warnings=none -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.avrdude.path=C:\Program Files (x86)\Arduino\hardware\tools\avr -prefs=runtime.tools.avr-gcc.path=C:\Program Files (x86)\Arduino\hardware\tools\avr -verbose Z:\Quantum Sensing Limited\Consulting Work\Arduino\WebServer\WebServer.ino
Using board 'micro' from platform in folder: C:\Program Files (x86)\Arduino\hardware\arduino\avr
Using core 'arduino' from platform in folder: C:\Program Files (x86)\Arduino\hardware\arduino\avr
WARNING: Category 'Device' in library ParPrinter is not valid. Setting to 'Uncategorized'
WARNING: Category 'Device' in library Radar is not valid. Setting to 'Uncategorized'
Detecting libraries used...
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\sketch\WebServer.ino.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\sketch\WebServer.ino.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\sketch\WebServer.ino.cpp" -o "nul"
Using cached library dependencies for file: C:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src\SPI.cpp
Using cached library dependencies for file: C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Dhcp.cpp
Using cached library dependencies for file: C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Dns.cpp
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet2.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\EthernetClient.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\EthernetServer.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\EthernetUdp.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\EthernetUdp2.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Twitter.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\utility\socket.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\utility\w5100.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\utility\w5200.cpp" -o "nul"
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\utility\w5500.cpp" -o "nul"
Generating function prototypes...
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics  -flto -w -x c++ -E -CC -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\sketch\WebServer.ino.cpp" -o "C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\preproc\ctags_target_for_gcc_minus_e.cpp"
"C:\Program Files (x86)\Arduino\tools-builder\ctags\5.8-arduino10/ctags" -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives "C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\preproc\ctags_target_for_gcc_minus_e.cpp"
Compiling sketch...
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -flto -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\sketch\WebServer.ino.cpp" -o "C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\sketch\WebServer.ino.cpp.o"
Compiling libraries...
Compiling library "SPI"
Using previously compiled file: C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\libraries\SPI\SPI.cpp.o
Compiling library "Ethernet"
Using previously compiled file: C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\libraries\Ethernet\Dhcp.cpp.o
Using previously compiled file: C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\libraries\Ethernet\Dns.cpp.o
"C:\Program Files (x86)\Arduino\hardware\tools\avr/bin/avr-g++" -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -MMD -flto -mmcu=atmega32u4 -DF_CPU=16000000L -DARDUINO=10612 -DARDUINO_AVR_MICRO -DARDUINO_ARCH_AVR  -DUSB_VID=0x2341 -DUSB_PID=0x8037 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="Arduino Micro"' "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\cores\arduino" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\variants\micro" "-IC:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI\src" "-IC:\Program Files (x86)\Arduino\libraries\Ethernet\src" "C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp" -o "C:\Users\Hemon\AppData\Local\Temp\arduino_build_838983\libraries\Ethernet\Ethernet.cpp.o"
C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp: In member function 'int EthernetClass::begin()':

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp:26:3: error: 'W5500' was not declared in this scope

   W5500.init();

   ^

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp:37:5: error: 'W5100' was not declared in this scope

     W5100.setIPAddress(_dhcp->getLocalIp().raw_address());

     ^

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp: In member function 'void EthernetClass::begin(IPAddress, IPAddress, IPAddress, IPAddress)':

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp:72:3: error: 'W5100' was not declared in this scope

   W5100.init();

   ^

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp: In member function 'int EthernetClass::maintain()':

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp:158:9: error: 'W5100' was not declared in this scope

         W5100.setIPAddress(_dhcp->getLocalIp().raw_address());

         ^

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp: In member function 'IPAddress EthernetClass::localIP()':

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp:174:3: error: 'W5100' was not declared in this scope

   W5100.getIPAddress(ret.raw_address());

   ^

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp: In member function 'IPAddress EthernetClass::subnetMask()':

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp:181:3: error: 'W5100' was not declared in this scope

   W5100.getSubnetMask(ret.raw_address());

   ^

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp: In member function 'IPAddress EthernetClass::gatewayIP()':

C:\Program Files (x86)\Arduino\libraries\Ethernet\src\Ethernet.cpp:188:3: error: 'W5100' was not declared in this scope

   W5100.getGatewayIp(ret.raw_address());

   ^

Using library SPI at version 1.0 in folder: C:\Program Files (x86)\Arduino\hardware\arduino\avr\libraries\SPI 
Using library Ethernet at version 1.0.4 in folder: C:\Program Files (x86)\Arduino\libraries\Ethernet 
exit status 1
Error compiling for board Arduino/Genuino Micro.
Invalid version found: 0.1.03
Invalid version found: 0.1.04
Invalid version found: 0.1.06
Invalid version found: 0.1.04
Invalid version found: 0.1.07
Invalid version found: 0.1.02
Invalid version found: 0.1.09
Invalid version found: 0.1.00
Invalid version found: 0.1.05
Invalid version found: 0.1.01
Invalid version found: 0.1.06
Invalid version found: 0.1.01
Invalid version found: 0.1.04
Invalid version found: 0.1.07
Invalid version found: 0.1.04
Invalid version found: 0.1.03
Invalid version found: 0.1.03
Invalid version found: 1.2.03
Invalid version found: 0.1.03
Invalid version found: 0.1.08
Invalid version found: 0.1.04
Invalid version found: 0.1.05
Invalid version found: 0.1.05
Invalid version found: 0.1.00
Invalid version found: 0.1.00
Invalid version found: 0.1.00
Invalid version found: 0.1.00
Invalid version found: 0.1.00
Invalid version found: 0.1.01
Invalid version found: 0.1.09
Invalid version found: 0.1.03
Invalid version found: 0.1.00
Invalid version found: 0.1.00
Invalid version found: 0.1.06
Invalid version found: 0.1.03
Invalid version found: 0.1.04
Invalid version found: 0.1.06
Invalid version found: 0.1.04
Invalid version found: 0.1.07
Invalid version found: 0.1.02
Invalid version found: 0.1.09
Invalid version found: 0.1.00
Invalid version found: 0.1.05
Invalid version found: 0.1.01
Invalid version found: 0.1.06
Invalid version found: 0.1.01
Invalid version found: 0.1.04
Invalid version found: 0.1.07
Invalid version found: 0.1.04
Invalid version found: 0.1.03
Invalid version found: 0.1.03
Invalid version found: 1.2.03
Invalid version found: 0.1.03
Invalid version found: 0.1.08
Invalid version found: 0.1.04
Invalid version found: 0.1.05
Invalid version found: 0.1.05
Invalid version found: 0.1.00
Invalid version found: 0.1.00
Invalid version found: 0.1.00
Invalid version found: 0.1.00
Invalid version found: 0.1.00
Invalid version found: 0.1.01
Invalid version found: 0.1.09
Invalid version found: 0.1.03
Invalid version found: 0.1.00
Invalid version found: 0.1.00
Invalid version found: 0.1.06

Any ideas?

5
  • BTW ... I was following this instructable, instructables.com/id/Arduino-Nano-with-WIZ550io-Easy-Internet ... and I did update the wiznet library as it suggests.
    – QSL
    Commented Oct 7, 2017 at 10:37
  • The sharp eyed observers would notice that 222.237.190.239 is 0xDEEDBEEF ... which is part of the Mac. So I'm rather confused here.
    – QSL
    Commented Oct 7, 2017 at 10:40
  • original Arduino shield with W5500 needs the Ethernet2 library. try it
    – Juraj
    Commented Oct 7, 2017 at 15:51
  • Thanks Juraj ... but i'm getting compiling errors now, I've updated the original post above.
    – QSL
    Commented Oct 8, 2017 at 10:31
  • Note that even the stock WebServer example in Ethernet2 folder doesn't compile correctly. I've restarted Arduino IDE with no luck.
    – QSL
    Commented Oct 8, 2017 at 10:36

4 Answers 4

1

Solved it ... needed to create a new Ethernet2 folder and copy the Ethernet2 library files into it, and now it works great! The Ethernet2 library is a stand alone and different library to the Ethernet one.

0
1

For the W5500 chip use the Ethernet2 library. It can be can be found and installed in Library Manager in Arduino IDE.

UPDATE 2018: The Arduino Ethernet library version 2.00 now supports W5200 and W5500.

-1

beside any other coding and library issues: IP Groups are seperated by DOT not comma! If lucky, the interpreter ist Syntax-tollerant. Your Observation for the IP xx.xx.xx.139 could be the indication of the software trying to solve the issue semi-effectively.

-1

Change the MISO & MOSI Signal between Micro & W5500 module, now it works with both Etherenet2 & Ethernet Libs. btw Ethernet2 is better see ram.

1
  • 1
    2 years ago when the Question was asked Erhernet library didn't support W5500. and why should OP change the MISO & MOSI and how?
    – Juraj
    Commented Oct 14, 2019 at 4:53

Not the answer you're looking for? Browse other questions tagged or ask your own question.