I have been very successful in working the examples from book ...internet of things ... but when i deviate or do the extra credit things get confusing.
so if I modify a client program such as simplePutRequst with a different URI like http://localhost:8080 i get these socket errors like 00054 and 0006. If put the ip address of my laptop plus the :8080/testHello it works too.
My test web server on the development laptop I run and debug Netduino code is Apache and it works. What woks means is if the browser points to http://localhost/ I get the It Works! from there default htm file. I can ping the local host or 127.0.0.1.
HOWEVER, if I use http://localhost:8080/ it don't respond or rather I get can not display page.
My NetDuino is sending voltage values up to Pachube, a real web server. I want to stay in my own back yard to develop in a test environment.
What does one have to check/configure on a local web server to get the NetDuino to communicate like on the real web servers?
More than happy to share data of this problem for assistance. thanks for your time. This Netduino stuff is really cool.
micfiz
simple put to localhost confusing
Started by micfiz, Nov 15 2011 06:31 PM
2 replies to this topic
#1
Posted 15 November 2011 - 06:31 PM
#2
Posted 15 November 2011 - 07:28 PM
Perhaps there is some confusion about "localhost". It refers to the current computer, so if you use localhost on your PC, it refers to the PC. If however you use localhost in your Netduino program it would refer to the Netduino, not the PC.
If you want to have the Netduino talk to the PC use the ip address of the PC, not localhost.
- Arron Chapman likes this
#3
Posted 26 November 2011 - 02:27 PM
You have to remember that a web server will only answer requests on the port that you configure it for. If you only have the server configured to listen on the default port which is port 80 then your request will fail on port 8080.
To get the web server to respond on port 8080 you need to configure the web server to listen on other ports. If you double check the Apache docs, they should show you how to configure the web server to listen on additional ports.
Otherwise, just don't try the request on port 8080.
Brewing Award Winning Beer with a Netduino!
http://diybrewery.com
http://diybrewery.com
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users