EasyManua.ls Logo

Quectel BG96 TCP/IP User Manual

Quectel BG96 TCP/IP
53 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #15 background imageLoading...
Page #15 background image
LPWA Module Series
BG96 TCP/IP Application Note
BG96_TCP/IP_Application_Note 14 / 52
Parameter
2.2.4. AT+QIOPEN Open a Socket Service
The Write Command opens a socket service. The service type can be specified by <service_type>. The
data access mode (buffer access mode, direct push mode and transparent access mode) can be
specified by <access_mode>. URC +QIOPEN indicates whether the socket service has been opened
successfully.
1. If <service_type> is "TCP LISTENER", the module works as a TCP server. After accepting a new
TCP connection, the module will automatically specify a <connectID> and report URC +QIURC:
"incoming",<connectID>,<serverID>,<remoteIP>,<remote_port>. The range of <connectID> is
011. The type of this new incoming connection is "TCP INCOMING" and the <access_mode> of
"TCP INCOMING" is as same as the <access_mode> of "TCP LISTENER".
2. If <service_type> is "UDP SERVICE", UDP data can be sent to or received from the remote IP via
<local_port>.
Send data: execute AT+QISEND=<connectID>,<send_length>,<remoteIP>,<remote_port>.
Receive data in direct push mode: the module reports URC +QIURC: "recv",<connectI
D>,<currentrecvlength>,<remoteIP>,<remote_port><CR><LF><data>.
Receive data in buffer access mode: the module reports URC +QIURC: "recv",<connectID>,
and then the data can be retrieved via AT+QIRD=<connectID>.
3. It is suggested to wait for 150 seconds for +QIOPEN: <connectID>,<err> to be outputted. If the URC
cannot be received in 150 seconds, AT+QICLOSE should be used to close the socket.
<contextID> Integer type. Context ID. Range: 116.
AT+QIOPEN Open a Socket Service
Test Command
AT+QIOPEN=?
Response
+QIOPEN: (range of supported <contextID>s),(range of
supported <connectID>s),"TCP/UDP/TCP LISTENER/UDP
SERVICE",<IP_address>/<domain_name>,(range of
supported <remote_port>s),(range of supported
<local_port>s),(range of supported <access_mode>s)
OK
Write Command
AT+QIOPEN=<contextID>,<connectID
>,<service_type>,<IP_address>/<dom
ain_name>,<remote_port>[,<local_po
rt>[,<access_mode>]]
Response
If <access_mode>=2 and the socket service is opened
successfully:
CONNECT

Table of Contents

Question and Answer IconNeed help?

Do you have a question about the Quectel BG96 TCP/IP and is the answer not in the manual?

Quectel BG96 TCP/IP Specifications

General IconGeneral
Module TypeLTE Cat M1/Cat NB1/EGPRS
Form FactorLGA
Frequencies GSM850/900/1800/1900MHz
SIM Interface1.8V/3V
Operating Temperature-40°C to +85°C
Storage Temperature-45°C to +90°C
Network TechnologyLTE Cat M1, LTE Cat NB1, EGPRS
LTE CategoryCat M1/Cat NB1
Frequencies LTE FDDB1/B3/B5/B8/B12/B13/B18/B19/B20/B26/B28
Frequencies LTE TDDB39/B40/B41
LTE Max Data Rate (LTE Cat M1)375 kbps
LTE Max Data Rate (LTE Cat NB1)32 kbps (DL), 70 kbps (UL)
EGPRS Data Rate296 kbps (DL), 236.8 kbps (UL)
Data Rate (LTE Cat M1)375 kbps
Data Rate (LTE Cat NB1)32Kbps (DL)/70Kbps (UL)
InterfacesUART
GNSSGPS, GLONASS, BeiDou, QZSS
ProtocolsTCP/IP, UDP, HTTP, MQTT
CertificationsCE, FCC, IC, RCM

Summary

Introduction to Quectel BG96 TCP/IP

Process of Using TCP/IP AT Commands

Explains the sequence of AT commands for TCP/IP operations and context management.

Description of Data Access Modes

Details the three data access modes (Buffer, Direct Push, Transparent) supported by the module.

TCP/IP AT Commands Reference

AT Command Syntax

Defines syntax rules, parameters, and response formats for AT commands.

Description of TCP/IP AT Commands

Provides detailed descriptions, parameters, and usage for all TCP/IP AT commands.

Description of URCs

Explains Unsolicited Result Codes (URCs) for asynchronous TCP/IP events.

Examples of TCP/IP Usage

Configure and Activate a Context

Demonstrates the steps to configure and activate a network context.

TCP Client Works in Buffer Access Mode under IPv4

Illustrates setting up and using a TCP client in buffer mode with IPv4.

TCP Client Works in Buffer Access Mode under IPv6

Demonstrates TCP client operations in buffer mode with IPv6.

TCP Client Works in Transparent Access Mode

Shows how to use a TCP client in transparent access mode for data transfer.

TCP Client Works in Direct Push Mode

Explains TCP client operations in direct push mode for data transfer.

TCP Server Works in Buffer Access Mode under IPv4

Details setting up and using a TCP server in buffer mode with IPv4.

TCP Server Works in Buffer Access Mode under IPv6

Illustrates TCP server operations in buffer mode with IPv6.

UDP Service under IPv4

Demonstrates UDP service setup and operations with IPv4.

UDP Service under IPv6

Explains UDP service setup and operations with IPv6.

Ping a Remote Server

Shows how to use the ping command to test network reachability.

Synchronize Local Time

Demonstrates synchronizing the module's time with an NTP server.

Get Last Error Code

Explains how to retrieve the last error code for troubleshooting.

Summary of Error Codes

Appendix A Reference

Related product manuals