![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
nucleo f767zi onenet edp test
Dependencies: cJSON_lib Common_lib EdpKit_lib
Diff: main.cpp
- Revision:
- 12:2e7466eba9a3
- Parent:
- 5:3e952c60d705
- Child:
- 13:ed9e4aa00044
diff -r 6e78628ae57b -r 2e7466eba9a3 main.cpp --- a/main.cpp Mon Feb 27 17:30:06 2017 +0000 +++ b/main.cpp Wed Mar 08 20:30:07 2017 +0000 @@ -19,12 +19,12 @@ socket.open(&net); socket.connect("developer.mbed.org", 80); - // Send a simple http request + // Send an HTTP request char sbuffer[] = "GET / HTTP/1.1\r\nHost: developer.mbed.org\r\n\r\n"; int scount = socket.send(sbuffer, sizeof sbuffer); printf("sent %d [%.*s]\n", scount, strstr(sbuffer, "\r\n")-sbuffer, sbuffer); - // Recieve a simple http response and print out the response line + // Receive an http response and print out the response line char rbuffer[64]; int rcount = socket.recv(rbuffer, sizeof rbuffer); printf("recv %d [%.*s]\n", rcount, strstr(rbuffer, "\r\n")-rbuffer, rbuffer);