Server IP at 0.0.0.0

When i try to assign my sainsmart ethernet adapter an ip address i get "server is at 0.0.0.0" in the serial monitor??? I have no idea what this means or do i know how to fix it. Can someone give me information on what this means and try to help me solve this issue?

Check the ICSP pins. Are they inserted firmly into the ethernet shield socket?

If you have a SD card in the shield slot, remove it.

Can someone give me information on what this means

It means that there is something wrong with your network, your hardware, or your code.

and try to help me solve this issue?

Not yet. Some hints up there, though.

I have no sd card in the SD card slot and the 4 pins are firmly placed and the ethernet port is not shorting out on top of the usb, i put a couple layers of electrical tape to make sure.... I was using Zoomkats sample code someone modified for me to use for my relay shield i believe so i dont think its an issue with the code. Could it be the mac address? Since the address is weird i cant enter it manually into my wireless gateway?

Could it be the mac address?

No.

Since the address is weird i cant enter it manually into my wireless gateway?

Does your wireless router know anything about the MAC address of your laptop or PC? No, it doesn't. It doesn't need to know anything about your Arduino's MAC address, either.

How is your Arduino assigned an IP address? Does the router know that that IP address is exclusively for the Arduino?

I was using Zoomkats sample code someone modified for me to use for my relay shield i believe so i dont think its an issue with the code.

OK. That's one of us that can see the code, and verify that it is correct. Therefore, there is one of us that can solve the problem. Good luck.

Post your code- I’ll run it and see what happens.

//zoomkat 4-05-12
//web LED 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 (or use ')
//address will look like http://10.0.0.55:84 when submited
//for use with W5100 based ethernet shields
//turns pin 6 on/off

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

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

String readString;

//////////////////////

void setup(){

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

//enable serial data print
Serial.begin(9600);
Serial.println(“servertest1”); // 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 = client.read();

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

//store characters to string
readString += c;
Serial.print(c); //print what server receives to serial monitor
}

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

///////////////
Serial.println(readString);

//now output HTML data header

client.println(“HTTP/1.1 200 OK”);
client.println(“Content-Type: text/html”);
client.println();

client.println("");
client.println("");
client.println(“Arduino GET test page”);
client.println("");
client.println("");

client.println(“

HTML form GET example

”);

client.println("<FORM ACTION=“http://10.0.0.55:84” method=get >");

client.println(“Pin 6 “on” or “off”: <INPUT TYPE=TEXT NAME=“LED” VALUE=”" SIZE=“25” MAXLENGTH=“50”>
");

client.println("<INPUT TYPE=SUBMIT NAME=“submit” VALUE=“Change Pin 5!”>");

client.println("");

client.println("
");

client.println("");
client.println("");

delay(1);
//stopping client
client.stop();

/////////////////////
if(readString.indexOf(“on”) >0)//checks for on
{
digitalWrite(6, HIGH); // set pin 6 high
Serial.println(“Relay On”);
}
if(readString.indexOf(“off”) >0)//checks for off
{
digitalWrite(6, LOW); // set pin 6 low
Serial.println(“Relay Off”);
}
//clearing string for next read
readString="";

}
}
}
}
}

That can’t be the code that’s giving you the serial output “server is at x.x.x.x” becasue there’s no line in that posted sketch to make that line appear.

However, when I do add the lines to make that happen:

//enable serial data print 
  Serial.begin(9600); 
  Serial.println("servertest1"); // so I can keep track of what is loaded
  Serial.print("Server is at ");            //<<<<<<<<<<<<<<<<<<<<< added
  Serial.print(Ethernet.localIP());   //<<<<<<<<<<<<<<<<<<<<<added
}

It does print for me:

servertest1
Server is at 10.0.0.55

EDIT… but that might have something to do with the fact that my router’s lan-side ips are of the form 10… anyway

MORE EDIT… please put your code in tags, it’s a ballache to read otherwise

This is a duplicate thread. I am responding to the thread in "Networking, Protocols, and Devices". No sense duplicating answers. http://forum.arduino.cc/index.php?topic=118452.0

Righto ST....

I'm out....

please I have a problem with a Shield for Arduino Ethernet W5100 upload it right will be displayed after the sever is at 0.0.0.0

Gamerdude2956: When i try to assign my sainsmart ethernet adapter an ip address i get "server is at 0.0.0.0" in the serial monitor??? I have no idea what this means or do i know how to fix it.

If you are using the Ethernet Shield with W5100 it means that either your LAN configuration or your code is wrong

Post your code!

Post a link to the ethernet shield you are using also. That can be helpful.

SurferTim:
Post a link to the ethernet shield you are using also. That can be helpful.

Talking to the 2014 poster, or the hijacker?

Hi aarg! The hijacker. the hijacker is also hijacking an old post in Networking also.