Ethernet library dont work on linux mint

Hi everyone!, im working on a project, but i have no idea how to use ethernet library, cause eerytime I use the library on arduino IDE on linux it doesnt works!, even the examples incluided with the IDE dont compile, but it compiles on the windows vension (under wine)

/usr/share/arduino/libraries/Ethernet/Ethernet.cpp: In member function ‘void EthernetClass::begin(uint8_t*, IPAddress, IPAddress, IPAddress, IPAddress)’:
/usr/share/arduino/libraries/Ethernet/Ethernet.cpp:65: error: request for member ‘a8’ in ‘local_ip.IPAddress::_address’, which is of non-class type ‘uint8_t [4]’
/usr/share/arduino/libraries/Ethernet/Ethernet.cpp:66: error: request for member ‘a8’ in ‘gateway.IPAddress::_address’, which is of non-class type ‘uint8_t [4]’
/usr/share/arduino/libraries/Ethernet/Ethernet.cpp:67: error: request for member ‘a8’ in ‘subnet.IPAddress::_address’, which is of non-class type ‘uint8_t [4]’

Where did you get your IDE version? If not from the Arduino website, you should download from there, not your repository. I recommend v1.05 for now, even though I have really good results from the V1.5.5 beta version. Once you download and unpack it, go to the arduino directory that was created by the unpack and run the arduino script there. That should run the version from the Arduino website.

If your sketch still gives you an error, you should post the code that creates those errors, but you might want to do that in the "Networking, Protocols and Devices" section.

I got my version from download section, i tried with arduino IDE from the mint repository on my desktop and it works already, so i need to work on my desktop and not in my notebook

If it works already, why are you posting that it doesn't?

What IDE version are you using on your desktop?

You didn't post your code. Without that, I am guessing.

I dont need to post the code cause the code is not the problem, is the IDE, i have the problem only in my notebook so im working in my desktop right now, i didnt solved my notebook problem yet

Since you didn't answer the question about the IDE, I will presume you are using IDE v1.0.5 downloaded from the Arduino website in both computers. Is that correct?

Same version in both PC´s, same linux mint 16

Hello everyone

I face the same error issue on all boards I have access to, Duemilanove and Mega2560, Teensy2, Teensy++2 and Teensy3.

request for member 'a8' in 'subnet.IPAddress::_address', which is of non-class type 'uint8_t [4]
{aka unsigned char [4]}'

The code that I tried to use is this:

//zoomkat 12-8-11
//simple button GET with iframe code
//for use with IDE 1.0
//open serial monitor to see what the arduino receives
//use the \ slash to escape the " in the html 
//address will look like when submited
//for use with W5100 based ethernet shields

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

byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED }; //physical mac address
byte ip[] = { 192, 168, 1, 102 }; // ip in lan
byte gateway[] = { 192, 168, 1, 1 }; // internet access via router
byte subnet[] = { 255, 255, 255, 0 }; //subnet mask
EthernetServer server(84); //server port

String readString; 


void setup(){

  pinMode(4, OUTPUT); //pin selected to control
  //start Ethernet
  Ethernet.begin(mac, ip, gateway, subnet);

  //enable serial data print 
  Serial.println("server LED test 1.0"); // so I can keep track of what is loaded

void loop(){
  // Create a client connection
  EthernetClient client = server.available();
  if (client) {
    while (client.connected()) {
      if (client.available()) {
        char c =;

        //read char by char HTTP request
        if (readString.length() < 100) {

          //store characters to string 
          readString += c; 

        //if HTTP request has ended
        if (c == '\n') {

          Serial.println(readString); //print to serial monitor for debuging 

          //now output HTML data header
             if(readString.indexOf('?') >=0) { //don't send new page
               client.println("HTTP/1.1 204 Zoomkat");
             else {
          client.println("HTTP/1.1 200 OK"); //send new page
          client.println("Content-Type: text/html");

          client.println("<TITLE>Arduino GET test page</TITLE>");

          client.println("<H1>Zoomkat's simple Arduino button</H1>");
          client.println("<a href=\"/?on\" target=\"inlineframe\">ON</a>"); 
          client.println("<a href=\"/?off\" target=\"inlineframe\">OFF</a>"); 

          //client.println("<IFRAME name=inlineframe src=\"res://D:/WINDOWS/dnserror.htm\" width=1 height=1\">");
          client.println("<IFRAME name=inlineframe style=\"display:none\" >");          


          //stopping client

          ///////////////////// control arduino pin
          if(readString.indexOf("on") >0)//checks for on
            digitalWrite(4, HIGH);    // set pin 4 high
            Serial.println("Led On");
          if(readString.indexOf("off") >0)//checks for off
            digitalWrite(4, LOW);    // set pin 4 low
            Serial.println("Led Off");
          //clearing string for next read


More or less funny might be that also I got another error message

request for member ‘a8’ in ‘local_ip.IPAddress::_address’, which is of non-class type ‘uint8_t [4]’

using a differend code, wich was made as an including library to Arduino:

  Web Server
 A simple web server that shows the value of the analog input pins.
 using an Arduino Wiznet Ethernet shield. 
 * 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

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

// Enter a MAC address and IP address for your controller below.
// The IP address will be dependent on your local network:
byte mac[] = { 
  0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
IPAddress ip(192,168,1,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:
   while (!Serial) {
    ; // wait for serial port to connect. Needed for Leonardo only

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

void loop() {
  // 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 =;
        // 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("Connnection: close");
          client.println("<!DOCTYPE HTML>");
                    // add a meta refresh tag, so the browser pulls again every 5 seconds:
          client.println("<meta http-equiv=\"refresh\" content=\"5\">");
          // 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(" is ");
        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
    // close the connection:
    Serial.println("client disonnected");

I currently use the 1.0.5 IDE on a Ubuntu Studio (Ubuntu 12.10 (quantal)) with latest updates.

Is there any chance for me to get help on this, please?

Thank you in advance.

-Someone who is trying hard-

Edit: What I was able to do is this:
I ignored the fact that there is no proper program using Ethernet running on my Mage2560 and put the RJ45 in network cable just to see the LEDs blink and typed the ping command into my Terminal resulting in this:

--- ping statistics ---
124 packets transmitted, 124 received, 0% packet loss, time 123000ms
rtt min/avg/max/mdev = 0.368/0.402/0.638/0.038 ms

Is that normal?

Oh, I didnt recognize that I made a mistake posting the edit in my last session. It seems not to be that clever to sit in front of my screen after certain hours.
So what I mean, is, that In my last post I said that i was able to ping my Ethernet Shield even without uploading a scetch to it.
That is definately WRONG!

What I did instead was pingig my own host PC.
So please people, stay calm. :slight_smile:
I just was too sleepy to recognize that before I posted wrong infos.

Ok, now I have tried to use the Ethernet Library on a Windows XP System and the result was that it compiled with no error messages.
Maybe ther is just a problem with Linux?

So sad that I am obviously an entertainer on this topic, at this time.