WM620 AT
Command Manual
Copyright © Neoway Technology Co., Ltd
111
14.5 Receiving Data from the Client: +TCPRECV(S)
Description
To receive data from the client
Format
+TCPRECV(S):<socket>,<length>,<data>
Parameter
N/A
Return Value
See the Example.
Example
+TCPRECV(S):1,10,1234567899
Socket 1 receives data from the client.
Remarks
Additional
(s)
makes this command different from the receive mode of the client
mode in format.
14.6 Sending Data to the Client: +TCPSENDS
Description
To send data to the client
Format
AT+TCPSENDS=<socket>,<length>
Parameter
<socket>: The value of
AcceptSocket
, that is, the socket of the module. See the
description of the
AT+TCPLISTEN
command.
<length>: The length of the data to be sent, value ranges from
1
to
1024
, unit: byte.
Return Value
See the Example.
Example
AT+TCPSENDS=0,10
>1234567890
OK
+TCPSENDS:0,10
10-byte data is successfully sent
through socket 0.
AT+TCPSENDS=0,10
+TCPSENDS:SOCKET ID NOT ACTIVE
No socket has been set up using socket
0.
AT+TCPSENDS=0,10
+TCPSENDS:ERROR
No TCP connection is set up on socket
0 through listening, but some
connection of other type might have
been set up.
AT+TCPSENDS=0,10
>
+TCPSENDS:Error!TimeOut
10 seconds timed out. No data is input.
The module returns ERROR.