server/client
Dependencies: mbed NetServicesMin
tcp_error.cpp@1:6e61ee662fd3, 2012-02-23 (annotated)
- Committer:
- recotana
- Date:
- Thu Feb 23 02:38:05 2012 +0000
- Revision:
- 1:6e61ee662fd3
- Parent:
- 0:432b571e11a3
added standalone test mode
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
recotana | 0:432b571e11a3 | 1 | #include "mbed.h" |
recotana | 0:432b571e11a3 | 2 | #include "tcp_error.h" |
recotana | 0:432b571e11a3 | 3 | #include "TCPSocket.h" |
recotana | 0:432b571e11a3 | 4 | |
recotana | 0:432b571e11a3 | 5 | char tcpErrMes[8][100]={ |
recotana | 1:6e61ee662fd3 | 6 | "TCPSOCKET_SETUP TCPSocket not properly configured.\r\n", |
recotana | 1:6e61ee662fd3 | 7 | "TCPSOCKET_TIMEOUT Connection timed out.\r\n", |
recotana | 1:6e61ee662fd3 | 8 | "TCPSOCKET_IF Interface has problems, does not exist or is not initialized.\r\n", |
recotana | 1:6e61ee662fd3 | 9 | "TCPSOCKET_MEM Not enough mem.\r\n", |
recotana | 1:6e61ee662fd3 | 10 | "TCPSOCKET_INUSE Interface / Port is in use.\r\n", |
recotana | 1:6e61ee662fd3 | 11 | "TCPSOCKET_EMPTY Connections queue is empty.\r\n", |
recotana | 1:6e61ee662fd3 | 12 | "TCPSOCKET_RST Connection was reset by remote host.\r\n", |
recotana | 1:6e61ee662fd3 | 13 | "TCPSOCKET_OK Success.\r\n" |
recotana | 0:432b571e11a3 | 14 | }; |
recotana | 0:432b571e11a3 | 15 | |
recotana | 0:432b571e11a3 | 16 | void dispTcpError(TCPSocketErr err){ |
recotana | 1:6e61ee662fd3 | 17 | printf("%s\r\n",tcpErrMes[err]) ; |
recotana | 0:432b571e11a3 | 18 | } |