test
Dependencies: C027 HTTPClient UbloxUSBModem mbed
Fork of C027_HTTPClientTest by
Revision 13:bcdb607b2c76, committed 2014-03-03
- Comitter:
- vwochnik
- Date:
- Mon Mar 03 16:47:10 2014 +0000
- Parent:
- 11:ab536fc3a722
- Child:
- 17:99b8b4aa577b
- Commit message:
- fix
Changed in this revision
HTTPClient.lib | Show annotated file Show diff for this revision Revisions of this file |
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/HTTPClient.lib Wed Feb 19 16:10:01 2014 +0000 +++ b/HTTPClient.lib Mon Mar 03 16:47:10 2014 +0000 @@ -1,1 +1,1 @@ -https://mbed.org/users/vwochnik/code/HTTPClient/#967c00d70d95 +http://mbed.org/users/donatien/code/HTTPClient/#1f743885e7de
--- a/main.cpp Wed Feb 19 16:10:01 2014 +0000 +++ b/main.cpp Mon Mar 03 16:47:10 2014 +0000 @@ -23,18 +23,9 @@ return; } - //GET data - printf("Trying to fetch page...\n"); - ret = http.get("http://nocore.info:8888/", str, 128); - if (!ret) { - printf("Page fetched successfully - read %d characters\n", strlen(str)); - printf("Result: %s\n", str); - } else { - printf("Error - ret = %d - HTTP return code = %d\n", ret, http.getHTTPResponseCode()); - } - //POST data HTTPText text(str, 512); + // LONG AND SHORT REQUESTS HTTPText data("1234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890"); //HTTPText data("23123123lala"); printf("Trying to post data...\n");