This is a quick example of a simple HTTP client program using the network-socket API that is provided as a part of mbed-os. The program brings up an underlying network interface, and uses it to perform an HTTP transaction over a TCPSocket.
mbed-os.lib@56:02a6401ec508, 2018-08-15 (annotated)
- Committer:
- mbed_official
- Date:
- Wed Aug 15 11:15:04 2018 +0100
- Revision:
- 56:02a6401ec508
- Parent:
- 55:70c9ae73c998
- Child:
- 57:524f671184a6
Improve error handling.
* socket.connect() was not causing program to stop, in case of error
* socket.send() was printing "Error! socket.connect()..." in case of error
* rename labels to upper case for readability
.
Commit copied from https://github.com/ARMmbed/mbed-os-example-sockets
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
mbed_official | 55:70c9ae73c998 | 1 | https://github.com/ARMmbed/mbed-os/#f8b140f8d7cb226e41486c5df66ac4f3ce699219 |