Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
7 years, 7 months ago.
TCPSocket_Example does not work
I tried the the example here https://developer.mbed.org/teams/mbed_example/code/TCPSocket_Example/ with the mbed LPC1768 and the mbed Application Board and the following was returned to the terminal:
Ethernet socket example
IP address is: 192.168.1.21
sent 45 [GET / HTTP/1.1]
recv 64 [HTTP/1.1 301 Moved Permanently]
Done
Could we have a working example please.
Question relating to:
1 Answer
7 years, 7 months ago.
HI Peter, that example works fine and the output you show is the expected output.
The program does a GET request to developer.mbed.org, then receives a 301 - Moved permanently response (because we now serve developer.mbed.org over HTTPS). Both of these lines are printed and then the program ends.
We should update the URL in that example though, because query'ing mbed.org over HTTP does not work anymore :-). But the response is correct.
Thanks Jan, that makes sense. Got the example to work with HTTP pages. Is there an example for HTTPS pages?
posted by 18 Feb 2017Thanks again Jan. I tried the example here: https://developer.mbed.org/teams/sandbox/code/http-example/ with the mbed LPC1768 and the mbed Application Board and the following was returned to the terminal:
[EasyConnect] Using Ethernet
[EasyConnect] Connected to Network successfully
[EasyConnect] IP address 192.168.1.7
[EasyConnect] MAC address 00:02:f7:f0:44:c7
Operator new out of memory
I also got the "Lights of Death" indicating a run-time error then noticed the LPC1768 32kB RAM is insufficient for this app, which needs 43.9kB...
posted by 19 Feb 2017