Go Down

Topic: No TCP/IP link,without pressing the reset button (Read 17 times) previous topic - next topic


Same result with external power, the "FULLD" Led is blinking until I push the reset button.


I have done another test, external power and then I have cut of the power cable (pin1 VCC) from the USB cable. Same result when I connect the USB cable to my PC the link go up! It seems to be some magic talk between the board and the driver in the PC. No program is running in the PC.



Some pictures may help too :)

http://flickr.com/ is good for high-res pictures



Here comes the code, I have just changed the IP address from the example:

* Web Server
* A simple web server that shows the value of the analog input pins.

#include <Ethernet.h>

byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
byte ip[] = { 192, 168, 0, 120 };

Server server(80);

void setup()
 Ethernet.begin(mac, ip);

void loop()
 Client client = server.available();
 if (client) {
   // an http request ends with a blank line
   boolean current_line_is_blank = true;
   while (client.connected()) {
     if (client.available()) {
       char c = client.read();
       // if we've gotten to the end of the line (received a newline
       // character) and the line is blank, the http request has ended,
       // so we can send a reply
       if (c == '\n' && current_line_is_blank) {
         // send a standard http response header
         client.println("HTTP/1.1 200 OK");
         client.println("Content-Type: text/html");
         // output the value of each analog input pin
         for (int i = 0; i < 6; i++) {
           client.print("analog input ");
           client.print(" is ");
       if (c == '\n') {
         // we're starting a new line
         current_line_is_blank = true;
       } else if (c != '\r') {
         // we've gotten a character on the current line
         current_line_is_blank = false;
} :-X :-[

Go Up