17 socket listen improved - @sktl – Rainbow Electronics GM862-QUAD-PY User Manual

Page 356

Advertising
background image




AT Commands Reference Guide

80000ST10025a Rev. 5 - 09/07/08

Reproduction forbidden without Telit Communications S.p.A. written authorization - All Rights Reserved

page 356 of 434

#SKTL - Socket Listen

SELINT 2


to stop listening

AT#SKTL=0,0,1024, 255
OK

Note

The main difference between this command and #SKTD is that #SKTL
does not contact any peer, nor does any interaction with the GPRS context
status, leaving it ON or OFF according to the #GPRS setting, therefore
when the connection made with #SKTL is closed the context (and hence
the local IP address) is maintained.

3.5.7.5.17 Socket Listen Improved - @SKTL

@SKTL - Socket Listen Improved

SELINT 0 / 1

AT@SKTL
[=<mode>,
<socket type>,
<input port>,
[<closure type>]]

Execution command opens/closes the socket listening for connection
requests.

Parameters:
<mode> - socket mode
0 - closes socket listening
1 - starts socket listening
<socket type> - socket protocol type
0 - TCP
<input port> - local host input port to be listened

0..65535 - port number

<closure type> - socket closure behaviour for TCP
0 - local host closes immediately when remote host has closed (default)
255 - local host closes after an escape sequence (+++) or after an abortive

disconnect from remote.


Command returns the OK result code if successful.

Note: the command to be successful requests that:
- the GPRS context 1 is correctly set with +CGDCONT
- the authentication parameters are set (#USERID, #PASSW)
- the GPRS coverage is enough to permit a connection
- the GPRS has been activated with AT#GPRS=1


When a connection request comes on the input port, if the sender is not
filtered by the internal firewall (see command #FRWL), an unsolicited code
is reported:


+CONN FROM: <remote addr>

Where:
<remote addr> - host address of the remote machine that contacted the

device.

Advertising