Data Sheet
!
5. TCP/IP-Related AT Commands
Parameters
• <linkID>: ID of network connection (0~4), used for multiple connections.
• <type>: string parameter indicating the connection type: "TCP", "UDP"or "SSL".
• <remoteIP>: string parameter indicating the remote IP address.
• <remoteport>: remote port number.
• [<UDPlocalport>]: optional; UDP port of ESP8266.
• [<UDPmode>]: optional. In the UDP transparent transmission, the value of this parameter has to be 0.
‣ 0: the destination peer entity of UDP will not change; this is the default setting.
‣ 1: the destination peer entity of UDP can change once.
‣ 2: the destination peer entity of UDP is allowed to change.
⚠ Notice:
To use <UDPmode> , <UDPlocalport> must be set first.
Example
AT+CIPSTART="UDP","192.168.101.110",1000,1002,2
For more information please see: ESP8266 AT Command Examples.
Establish SSL Connection
Set
Command
AT+CIPSTART=[<linkID>,]<type>,<remoteIP>,<remoteport>[,<TCPkeepalive>]
Response
OK
or
ERROR
If the TCP connection is already established, the response is:
ALREADYCONNECT
Parameters
• <linkID>: ID of network connection (0~4), used for multiple connections.
• <type>: string parameter indicating the connection type: "TCP", "UDP"or "SSL".
• <remoteIP>: string parameter indicating the remote IP address.
• <remoteport>: the remote port number.
• [<TCPkeepalive>]: detection time interval when TCP is kept alive; this function is disabled by
default.
‣ 0: disable the TCP keep-alive function.
‣ 1~7200: detection time interval, unit: second (s).
Notes
•
ESP8266 can only set one SSL connection at most.
•
SSL connection does not support UART-Wi-Fi passthrough mode (transparent transmission).
•
SSL connection needs a large amount of memory; otherwise, it may cause system reboot. The
command AT+CIPSSLSIZE=<size> can be used to enlarge the SSL buffer size.
Example
AT+CIPSTART="SSL","iot.espressif.cn",8443
Espressif
! /!44 58
2017.05