Mipopen, Open A Socket (Udp Or Tcp) - Motorola G24 Guide Developer's Manual

At commands
Hide thumbs Also See for G24 Guide:
Table of Contents

Advertisement

Example
AT+MIPCALL=1,"internet","User1","Pswd"//Connecting the provider 'Orange' and getting an IP
+MIPCALL: "123.145.167.230"
AT+MIPCALL=0//The terminal hangs up the link
OK

+MIPOPEN, Open a Socket (UDP or TCP)

This command causes the G24 module to initialize a new socket that waits for a connection from
a remote machine or opens a common or TCP secured with SSL connection with a remote side
(according to received parameters). Each socket allocates an accumulating buffer whose size is
1372 bytes.
Note:
Command Type
Set
Read
Test
Example
+MIPOPEN: 1 2 3 4//All sockets closed
+MIPOPEN: 1 3 4 //Socket 2 opened
December 31, 2007
MIPxxx is a complete set of GPRS commands. This set should not be used with other
GPRS commands, such as CGATT, CGACT, and so on.
The +MIPOPEN command returns a +MIPSTAT unsolicited event if it fails, for example,
if it was rejected by the remote side.
The +MIPOPEN command returns a +MIPSSL unsolicited event(s) in case of alert(s)
occurring during secure connection. See
SSL connection is not supported for listening sockets.
Syntax
AT+MIPOPEN=
<Socket ID>,
<Source Port>,
<Remote IP>,
<Remote Port>,
<Protocol>
AT+MIPOPEN?
AT+MIPOPEN=?
AT Commands Reference Manual
Chapter 3: AT Commands Reference
.
Table 3-280
Response/Action
OK
or:
+MIPOPEN: <Socket
ID>,<State>[,<Remote IP>,<Remote
Port>]
or:
+MIPSTAT: <Socket ID>,<Status>
or:
ERROR: <err>
+MIPOPEN:[<SocketID>]
for each socket that can be opened
or:
+MIPOPEN 0
if there are no free sockets.
+MIPOPEN: (list of supported
<socket ID>s),(list of supported
<source port>s),(list of
supported<"Destination IP">s),
(list of <destination port>s),(list of
supported <protocol>s)
Remarks
The Set command returns
<Remote IP> and
<Remote Port>
parameters only for
sockets opened in Listen
mode.
The Read command
returns the numbers of
the sockets that can be
opened.
3-387

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents