
AT commands
Socket commands
Digi XBee® 3 Cellular LTE-M/NB-IoT Global Smart Modem User Guide
243
Socket commands
The following AT commands are socket commands.
SI (Socket Info)
Lists either information about a given socket or lists the socket IDs of all active (open) sockets on the
modem in a human-readable format.
When the
SI
command is issued without a parameter, the XBee outputs a list of socket IDS in hex,
separated by carriage returns (<CR>). After the last socket ID has been printed the list is terminated
with an additional carriage return.
In both API and command mode the payload (output) will have the following format:
ID<CR>
ID<CR>
. . .
ID<CR>
<CR>
In the list of socket IDs, an asterisk (*) displays after the socket ID for non-Extended API Sockets
(which are sockets created implicitly when using IPv4 TX API frames). In the example below, the 0x00
socket is an IPv4 TX/RX socket, and the 0x01 and 0x02 sockets are both Extended API sockets. The
socket IDs are displayed in ascending order, from smallest socket value to the largest.
0x00*
0x01
0x02
Note
When sending AT commands for API frames it is standard to send the command as ASCII text
and the parameters for that command as binary.
When the
SI
command is issued with a socket ID, specified in hex, the response is a list of information
about the socket. The list is separated by carriage returns (<CR>) and terminated with an additional
carriage return.
In both API and command mode the payload/output will have the following format:
ID<CR>
STATE<CR>
PROTOCOL<CR>
LOCAL_PORT<CR>
REMOTE_PORT<CR>
REMOTE_ADDRESS<CR>
<CR>
Field
Description
ID
The socket ID.