![Neoway Neo WM620 At Command Manual Download Page 67](http://html1.mh-extra.com/html/neoway/neo-wm620/neo-wm620_at-command-manual_1667901067.webp)
Neo_WM620 WCDMA Module AT Command Set
Copyright © Neoway Technology Co., Ltd
60
The buffer size is 10K for each socket when you set data receiving mode to manual
reading.
9.5 Sending TCP Data: +TCPSEND
Description
To send TCP data
The module will returns > after this command is sent. Send TCP data 50 ms to 100 ms
later.
Format
AT+TCPSEND=<n>,<length> <CR>
Parameter
<n>: Socket number, ranging from 0 to 5. A TCP connection is established on the socket.
<length>: The length of the data to be sent, ranging from
1
to
4096
, unit: byte.
Return
Value
See the Example.
Example
AT+TCPSEND=0,1
>1
OK
+TCPSEND:0,1
1-byte data is successfully sent through
socket 0.
AT+TCPSEND=0,10
>665A4E0A597D554AFF01
OK
+TCPSEND:0,10
Hexadecimal ASCII data is successfully
sent through socket 0. Select HEX when
sending data.
AT+TCPSEND=0,1
+TCPSEND: SOCKET ID OPEN FAILED
1-byte data fails to be sent via socket 0
because the connection is not established.
AT+TCPSEND=0,4097
+TCPSEND: DATA LENGTH ERROR
4097-byte data fails to be sent via socket
0 because data length exceeds the limit.
AT+TCPSEND=0,10
>
+TCPSEND:Error!TimeOut
10 seconds timed out. No data is input.
The module returns ERROR.
AT+TCPSEND=0,1
+TCPSEND:ERROR
No TCP connection is set up on socket 0,
but some connection of other type might
have been set up.
Remarks
Ensure that the TCP connection has been set up before sending TCP data.
If the command format is incorrect, the module will also returns
+TCPSEND:ERROR
.
9.6 Receiving TCP Data: +TCPRECV
Description
To receive TCP data
Format
+TCPRECV:<n>,<length>,<data><CR>
Parameter
<n>: Socket number, ranging from
0
to
5