Go Down

Topic: im working on a home automated system and the webserver is acting weird (Read 1 time) previous topic - next topic


Feb 04, 2013, 09:17 pm Last Edit: Feb 04, 2013, 09:23 pm by michael040990 Reason: 1
ok heres my code
Code: [Select]


when i connect to the it shows something like this

and chainges every time you refresh or sometimes it wont even load
sometimes it will download a file called download with the contence of
Code: [Select]


the website is located here http://turnmylightson.no-ip.org/

im using arduino uno with the wizboy ethernet sheild connected through a tl-wr702n chinese router connected as a client to my home router

no serial communication seems to be going on through the arduino ide serial console
andsome times it says it can not find the serial port

this code worked a few times before do you think there is a problem with my arduino uno that doing this?

it seems my old code works fine what went wrong with the new code?
Code: [Select]



If this is an Uno, you should leave D10-D13 alone. I see you might have something connected (or plan on it) to D10. A relay maybe?

And this is not right.
Code: [Select]
Ethernet.begin(mac, ip, gateway, subnet);
// it should be
Ethernet.begin(mac, ip, gateway, gateway, subnet);

The first gateway parameter is actually for the dns server ip, but the gateway works ok if you do not plan on using dns.


Feb 04, 2013, 10:00 pm Last Edit: Feb 04, 2013, 10:02 pm by michael040990 Reason: 1
thanks for pointing that out im trying it out now
it still crashed

and pin 11,12,13,4 will eventually go to the sd card reader
while pins 5,6,8,9 are relays and pin 3 is a ir led while pin 7 is a ir receiver
i got  

Code: [Select]
Oops! Google Chrome could not connect to turnmylightson.no-ip.org
Go to no-­ip.­org
Try reloading the page
Search on Google:

it looks like its not connecting to the webserver or not sending the header or something

if i ping it comes back

Code: [Select]
Pinging with 32 bytes of data:

Reply from bytes=32 time=4ms TTL=128
Reply from bytes=32 time=2ms TTL=128
Reply from bytes=32 time=1ms TTL=128
Reply from bytes=32 time=1ms TTL=128

Ping statistics for
   Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
   Minimum = 1ms, Maximum = 4ms, Average = 2ms

so its connecting to the arduino so it has to be something with sending the client.write commands to the server


Now I think I understand.
Do you have your public ip registered with no-ip?
Do you have your public ip interface sending port 80 requests to
Can you access the Arduino from the internet by ip address?
Does your ISP block port 80 requests to non-commercial ip addresses? Mine does.



no-ip info>Host Type:DNS Host (A)
i can not access it through either turnmylightson.no-ip.org||

i know the noip works because the other skitch i uploaded worked fine

Code: [Select]
and i tried to add
byte dns[] = {
  192, 168, 1, 1 }; // dns server

Code: [Select]
  Ethernet.begin(mac, ip, dns, gateway, subnet);

but i get the error
Code: [Select]
webserver_home_automation_with_status:35: error: 'byte dns []' redeclared as different kind of symbol
C:\Documents and Settings\Michael\My Documents\Arduino_instalation\arduino-1.0.1\libraries\Ethernet/Dhcp.h:64: error: previous declaration of '<anonymous enum> dns'

as stated before this is the origional one i had that worked fine
Code: [Select]

Go Up