system
July 28, 2012, 1:42pm
1
i got bought an Ethernet Shield W5100 For Arduino 2009 UNO Mega 1280 2560 from ebay for 14bucks.....
dhcpadress printer just prints "My IP address: 192.168.2.3."
i connected it to the pc and loaded many ethernet examples but none of them work....
when i load webserver example it says "server is at 192.168.1.177"
but when i enter 192.168.1.177 into browser it doesnot load..
Repeating webclient example just prints "My IP address: 10.0.0.20" in serial nothing more after that....
what am i doing wrong here?
i connected it to the pc and ...
You need to connect the ethernet shield to a router unless you are knowledgable of how to directly connect it to a pc. The connection methods are different.
system
July 28, 2012, 3:24pm
3
i connected it to router also
if i dint it wouldnt have shown me my ip adress rite...
kiriti:
i connected it to router also
if i dint it wouldnt have shown me my ip adress rite...
These appear to be different subnets. Which do you think is the right ip address?
dhcpadress printer just prints "My IP address: 192.168.2.3."
(snip)
when i load webserver example it says "server is at 192.168.1.177"
(snip)
Repeating webclient example just prints "My IP address: 10.0.0.20" in serial nothing more after that....
system
July 28, 2012, 4:19pm
5
i dont know which is correct, how to check?? my belkin router homepage does not list arduino device in dhcp list....
and in ipv4 settings are set to get the ip address automatically in controlpanel>adaptersettings>properties>ipv4...
system
July 28, 2012, 4:25pm
6
What is the address of your router? That will tell you which network you need to be on.
system
July 28, 2012, 4:48pm
7
192.168.2.1
is my belkin router homepage address
system
July 28, 2012, 4:55pm
8
Ok. So the DHCP address seems reasonable.
In the WebServer example sketch, change
IPAddress ip(192,168,1, 177);
to
IPAddress ip(192,168,2, 177);
which will put the Arduino on to your subnet.
system
July 28, 2012, 6:08pm
9
hey thanks
changing my ip in webserver to 192.168.2.177 worked
and what about webclient repeating and all??
i used
IPAddress ip(192,168,2,20);
IPAddress myDns(192,168,2,1);
but i guess webclientrepeating is not working still...
This link has repeating client code. It downloads Google home page every 10 seconds.
This loads www.google.com every 10 seconds. Don't do that to Google too long. Besides, it is a big page and takes a while to display at 9600 baud. Change the server ip to yours. #include #include byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE,...
It uses the ip 192.168.2.2. It works for me. See if it works for you also.
system
July 29, 2012, 1:02am
11
yeah that code works for me too... failed for the first time but it passed from the next time....