server/client

Dependencies:   mbed NetServicesMin

tcp_error.cpp

Committer:
recotana
Date:
2012-02-19
Revision:
0:432b571e11a3
Child:
1:6e61ee662fd3

File content as of revision 0:432b571e11a3:

#include "mbed.h"
#include "tcp_error.h"
#include "TCPSocket.h"

char tcpErrMes[8][100]={
    "TCPSOCKET_SETUP TCPSocket not properly configured.\n",
    "TCPSOCKET_TIMEOUT Connection timed out.\n",
    "TCPSOCKET_IF Interface has problems, does not exist or is not initialized.\n",
    "TCPSOCKET_MEM Not enough mem.\n",
    "TCPSOCKET_INUSE Interface / Port is in use.\n",
    "TCPSOCKET_EMPTY Connections queue is empty.\n",
    "TCPSOCKET_RST Connection was reset by remote host.\n",
    "TCPSOCKET_OK Success.\n"
};

void dispTcpError(TCPSocketErr err){
     printf("%s\n",tcpErrMes[err]) ;
}