This is Webservice SDK for mbed. LPCXpresso1769/LPC1768/FRDM-K64F/LPC4088
Dependents: MbedFileServer_1768MiniDK2 RedWireBridge IssueDebug_gcc MiMicRemoteMCU-for-Mbed ... more
TcpSocket Class Reference
Tcp Socket Class. More...
#include <TcpSocket.h>
Public Member Functions | |
NyLPC_TiTcpSocket_t * | refBaseInstance () |
wrapped base LPC class. | |
bool | connect (const IpAddr &i_addr, unsigned short i_port) |
int | precv (const void *&i_rx) |
This function return recieved data and size. | |
bool | canRecv () |
true if precv has data. | |
void | pseek (unsigned short i_rx_seek) |
This function seek rx pointer to next. |
Detailed Description
Tcp Socket Class.
The class is used by Net constructor.
Definition at line 15 of file TcpSocket.h.
Member Function Documentation
bool canRecv | ( | ) |
true if precv has data.
This can avoid the block of precv.
Definition at line 41 of file TcpSocket.cpp.
bool connect | ( | const IpAddr & | i_addr, |
unsigned short | i_port | ||
) |
- Parameters:
-
i_host_addr must be IPv4 address format.
Definition at line 23 of file TcpSocket.cpp.
int precv | ( | const void *& | i_rx ) |
This function return recieved data and size.
The function sets the head of the readable buffer which can always be read. A position is not changed until pseek was called.
- Parameters:
-
i_rx address of variable which accepts received data pointer. n<-1 Error n==0 Timeout (connection still established) n>0 Success. readable data size in i_rx.
Definition at line 46 of file TcpSocket.cpp.
void pseek | ( | unsigned short | i_rx_seek ) |
This function seek rx pointer to next.
- Parameters:
-
i_rx_size seek size. Must be returned value which is small or equal by the precv.
Definition at line 54 of file TcpSocket.cpp.
NyLPC_TiTcpSocket_t* refBaseInstance | ( | ) |
wrapped base LPC class.
Definition at line 21 of file TcpSocket.h.
Generated on Tue Jul 12 2022 15:46:18 by 1.7.2