WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide...

236
WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 1 2019-10-24 WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 – 2019-10-24

Transcript of WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide...

Page 1: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

80613ST10964A Rev. 5.0 1 2019-10-24

WL865E4-P Legacy CommandReference Guide

80613ST10964A Rev. 5.0 – 2019-10-24

Page 2: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

80613ST10964A Rev. 5.0 2 2019-10-24

APPLICABILITY TABLE

PRODUCT

WL865E4-P

Software Release

36.07.001

Page 3: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

80613ST10964A Rev. 5.0 3 2019-10-24

SPECIFICATIONS ARE SUBJECT TO CHANGE WITHOUT NOTICE

NOTICEWhile reasonable efforts have been made to assure the accuracy of this document, Telit assumes no liabilityresulting from any inaccuracies or omissions in this document, or from use of the information obtained herein. Theinformation in this document has been carefully checked and is believed to be reliable. However, no responsibilityis assumed for inaccuracies or omissions. Telit reserves the right to make changes to any products described hereinand reserves the right to revise this document and to make changes from time to time in content hereof with noobligation to notify any person of revisions or changes. Telit does not assume any liability arising out of theapplication or use of any product, software, or circuit described herein; neither does it convey license under itspatent rights or the rights of others.

It is possible that this publication may contain references to, or information about Telit products (machines andprograms), programming, or services that are not announced in your country. Such references or information mustnot be construed to mean that Telit intends to announce such Telit products, programming, or services in yourcountry.

COPYRIGHTSThis instruction manual and the Telit products described in this instruction manual may be, include or describecopyrighted Telit material, such as computer programs stored in semiconductor memories or other media. Laws inthe Italy and other countries preserve for Telit and its licensors certain exclusive rights for copyrighted material,including the exclusive right to copy, reproduce in any form, distribute and make derivative works of thecopyrighted material. Accordingly, any copyrighted material of Telit and its licensors contained herein or in theTelit products described in this instruction manual may not be copied, reproduced, distributed, merged or modifiedin any manner without the express written permission of Telit. Furthermore, the purchase of Telit products shall notbe deemed to grant either directly or by implication, estoppel, or otherwise, any license under the copyrights,patents or patent applications of Telit, as arises by operation of law in the sale of a product.

COMPUTER SOFTWARE COPYRIGHTSThe Telit and 3rd Party supplied Software (SW) products described in this instruction manual may includecopyrighted Telit and other 3rd Party supplied computer programs stored in semiconductor memories or othermedia. Laws in the Italy and other countries preserve for Telit and other 3rd Party supplied SW certain exclusiverights for copyrighted computer programs, including the exclusive right to copy or reproduce in any form thecopyrighted computer program. Accordingly, any copyrighted Telit or other 3rd Party supplied SW computerprograms contained in the Telit products described in this instruction manual may not be copied (reverseengineered) or reproduced in any manner without the express written permission of Telit or the 3rd Party SWsupplier. Furthermore, the purchase of Telit products shall not be deemed to grant either directly or by implication,estoppel, or otherwise, any license under the copyrights, patents or patent applications of Telit or other 3rd Partysupplied SW, except for the normal non-exclusive, royalty free license to use that arises by operation of law in thesale of a product.

Page 4: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

80613ST10964A Rev. 5.0 4 2019-10-24

USAGE AND DISCLOSURE RESTRICTIONS

I. License AgreementsThe software described in this document is the property of Telit and its licensors. It is furnished by express licenseagreement only and may be used only in accordance with the terms of such an agreement.

II. Copyrighted MaterialsSoftware and documentation are copyrighted materials. Making unauthorized copies is prohibited by law. No partof the software or documentation may be reproduced, transmitted, transcribed, stored in a retrieval system, ortranslated into any language or computer language, in any form or by any means, without prior written permissionof Telit.

III. High Risk MaterialsComponents, units, or third-party products used in the product described herein are NOT fault-tolerant and are NOTdesigned, manufactured, or intended for use as on-line control equipment in the following hazardous environmentsrequiring fail-safe controls: the operation of Nuclear Facilities, Aircraft Navigation or Aircraft CommunicationSystems, Air Traffic Control, Life Support, or Weapons Systems (High Risk Activities”). Telit and its supplier(s)specifically disclaim any expressed or implied warranty of fitness for such High Risk Activities.

IV. TrademarksTELIT and the Stylized T Logo are registered in Trademark Office. All other product or service names are theproperty of their respective owners.

V. Third Party RightsThe software may include Third Party Right software. In this case you agree to comply with all terms and conditionsimposed on you in respect of such separate software. In addition to Third Party Terms, the disclaimer of warrantyand limitation of liability provisions in this License shall apply to the Third Party Right software.

TELIT HEREBY DISCLAIMS ANY AND ALL WARRANTIES EXPRESS OR IMPLIED FROM ANY THIRDPARTIES REGARDING ANY SEPARATE FILES, ANY THIRD PARTY MATERIALS INCLUDED IN THESOFTWARE, ANY THIRD PARTY MATERIALS FROM WHICH THE SOFTWARE IS DERIVED(COLLECTIVELY “OTHER CODE”), AND THE USE OF ANY OR ALL THE OTHER CODE INCONNECTION WITH THE SOFTWARE, INCLUDING (WITHOUT LIMITATION) ANY WARRANTIES OFSATISFACTORY QUALITY OR FITNESS FOR A PARTICULAR PURPOSE.

NO THIRD PARTY LICENSORS OF OTHER CODE SHALL HAVE ANY LIABILITY FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING WITHOUT LIMITATION LOST PROFITS), HOWEVER CAUSED AND WHETHER MADE UNDER CONTRACT, TORT OR OTHER LEGAL THEORY, ARISING IN ANY WAY OUT OF THE USE OR DISTRIBUTION OF THE OTHER CODE OR THE EXERCISE OF ANY RIGHTS GRANTED UNDER EITHER OR BOTH THIS LICENSE AND THE LEGAL TERMS APPLICABLE TO ANY SEPARATE FILES, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES

Page 5: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Contents

Applicability Table .........................................................................................................................2 Notice ...........................................................................................................................................3 Copyrights ....................................................................................................................................3 Computer Software Copyrights ....................................................................................................3

I. ............................................................................................................ License Agreements 4 II. .........................................................................................................Copyrighted Materials 4 III. ............................................................................................................High Risk Materials 4 IV.........................................................................................................................Trademarks 4 V................................................................................................................ Third Party Rights 4

1 Introduction .................................................................................................................................. 101.1 Scope ....................................................................................................................................101.2 Audience ................................................................................................................................101.3 Contact Information, Support .................................................................................................101.4 Text Convention ....................................................................................................................111.5 Related Documents ...............................................................................................................11

1.5.1 Related Documents and Download ..............................................................................111.5.2 Related Documents requiring a Non Disclosure Agreement ........................................12

2 Overview ...................................................................................................................................... 132.1 AT Commands .......................................................................................................................13

2.1.1 AT Command Definitions .............................................................................................132.1.2 AT Command Syntax ...................................................................................................15

3 Getting Started .............................................................................................................................. 163.1 System Overview ...................................................................................................................163.2 Legacy Command Mode .......................................................................................................16

4 Architecture ................................................................................................................................... 174.1 Working Principle ...................................................................................................................174.2 System Initialization ...............................................................................................................184.3 Data Handling ........................................................................................................................19

4.3.1 Bulk Data Tx and Rx ....................................................................................................214.3.2 Hardware Flow Control ................................................................................................22

4.4 Serial Data Handling ..............................................................................................................234.5 Wireless Network Management .............................................................................................23

4.5.1 Scanning ......................................................................................................................234.5.2 Association ...................................................................................................................234.5.3 SSID and Passphrase ..................................................................................................24

5 Host Interaction ............................................................................................................................. 255.1 Interface .................................................................................................................................25

5.1.1 Software Flow Control ..................................................................................................255.1.2 Hardware Flow Control ................................................................................................255.1.3 Interface Verification ....................................................................................................26

6 General Operations ...................................................................................................................... 276.1 Version ..................................................................................................................................276.2 System Settings .....................................................................................................................28

6.2.1 Get Current Command Mode Status ............................................................................28

80613ST10964A Rev. 5.0 5 2019-10-24

Page 6: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6.2.2 Enable Legacy Command Mode ..................................................................................296.3 Time Setting ..........................................................................................................................30

6.3.1 Set System Time ..........................................................................................................306.3.1.1 Manual Setting .....................................................................................................306.3.1.2 Dynamic Setting ...................................................................................................31

6.3.2 Get System Time .........................................................................................................336.4 Profile Setting ........................................................................................................................35

6.4.1 Get Profile ....................................................................................................................356.4.2 Save Profile ..................................................................................................................376.4.3 Load Profile ..................................................................................................................386.4.4 Select Default Profile ....................................................................................................396.4.5 Define Profile ................................................................................................................406.4.6 Restore Profile .............................................................................................................416.4.7 Identification Information ..............................................................................................41

6.5 Reset .....................................................................................................................................436.6 MAC .......................................................................................................................................43

6.6.1 Get MAC Address ........................................................................................................43

7 Wireless ........................................................................................................................................ 457.1 Wireless Generic ...................................................................................................................45

7.1.1 Regulatory Domain ......................................................................................................457.1.1.1 Set Regulatory Domain ........................................................................................457.1.1.2 Get Regulatory Domain .......................................................................................46

7.1.2 Operation Mode ...........................................................................................................467.1.3 PHY Mode ....................................................................................................................49

7.1.3.1 Set PHY Mode .....................................................................................................497.1.3.2 Get PHY Mode ....................................................................................................50

7.1.4 Transmit Data Rate ......................................................................................................507.1.4.1 Set Transmit Rate ................................................................................................50

7.2 Station/AP Mode ...................................................................................................................537.2.1 Scan Time Settings ......................................................................................................53

7.2.1.1 Set Scan Time .....................................................................................................537.2.1.2 Get Scan Time .....................................................................................................54

7.2.2 Security Configuration ..................................................................................................547.2.2.1 Security Setting ....................................................................................................547.2.2.2 WPA-PSK and WPA2-PSK Passphrase ..............................................................567.2.2.3 WPA-PSK and WPA2-PSK Key Calculation .......................................................577.2.2.4 WPA-PSK and WPA2-PSK Key ..........................................................................59

7.2.3 Scanning ......................................................................................................................617.2.4 Association ...................................................................................................................627.2.5 Disassociation ..............................................................................................................657.2.6 Advanced Commands ..................................................................................................66

7.2.6.1 Get Client Information ..........................................................................................667.3 Concurrent Mode (STA Plus AP) ...........................................................................................67

7.3.1 Enable/Disable Concurrent Mode ................................................................................687.3.2 Set the Interface Number .............................................................................................697.3.3 Indicating Interface .......................................................................................................717.3.4 Example Usage of Concurrent Mode ...........................................................................72

8 Network ......................................................................................................................................... 758.1 DHCP Client ..........................................................................................................................758.2 DHCP Server .........................................................................................................................778.3 DHCP Server Configuration ..................................................................................................798.4 DNS Server ...........................................................................................................................80

80613ST10964A Rev. 5.0 6 2019-10-24

Page 7: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

8.5 DNS Address .........................................................................................................................818.6 IP Address .............................................................................................................................81

9 Data Transfer ................................................................................................................................ 849.1 Data Transfer Configuration ..................................................................................................84

9.1.1 Data Transfer in Bulk Mode .........................................................................................849.1.2 Connection Status ........................................................................................................859.1.3 Closing a Connection ...................................................................................................869.1.4 Closing All Connections ...............................................................................................879.1.5 Socket Options Configuration ......................................................................................88

9.2 Security Configuration ...........................................................................................................949.2.1 Certificate Addition .......................................................................................................949.2.2 Certificate Deletion .......................................................................................................979.2.3 EAP-Configuration .......................................................................................................989.2.4 EAP Certificate Upload ..............................................................................................1009.2.5 Secured (DTLS/SSL) .................................................................................................102

9.2.5.1 Configure SSL ...................................................................................................1029.2.5.2 Open SSL ..........................................................................................................1059.2.5.3 Close SSL ..........................................................................................................106

9.3 Network Connection Management (NCM) ...........................................................................1079.3.1 NCM Start/Stop ..........................................................................................................1079.3.2 Configure NCM ..........................................................................................................1119.3.3 NCM Status Get .........................................................................................................1139.3.4 Enable NCM AP Configuration ...................................................................................116

9.3.4.1 Examples for NCM Commands .........................................................................1179.4 HTTP ...................................................................................................................................119

9.4.1 HTTP(S) Client ...........................................................................................................1199.4.1.1 Configure HTTP Client .......................................................................................1199.4.1.2 Clear HTTP Client Configuration .......................................................................1229.4.1.3 Open HTTP Client Connection ..........................................................................1249.4.1.4 Configure Receive Response Headers/Status Line ..........................................1259.4.1.5 Exchange/Send Data with HTTP Client .............................................................1289.4.1.6 Close HTTP Client .............................................................................................130

9.4.2 HTTP(S) Server .........................................................................................................1309.4.2.1 HTTP Server Redirection ...................................................................................1309.4.2.2 Start/Stop Web Server .......................................................................................1329.4.2.3 Web Server Status .............................................................................................133

9.5 Auto Mode ...........................................................................................................................1349.5.1 Enable Auto Connection ............................................................................................1349.5.2 Wireless Parameters ..................................................................................................1359.5.3 Network Parameters ..................................................................................................136

9.6 UDP/TCP .............................................................................................................................1389.6.1 Basic ..........................................................................................................................138

9.6.1.1 Create TCP Clients ............................................................................................1389.6.1.2 Create UDP Client .............................................................................................1419.6.1.3 Start TCP Server ...............................................................................................1429.6.1.4 Start UDP Server ...............................................................................................145

9.6.2 Data Handling ............................................................................................................1469.6.2.1 Normal Data Handling .......................................................................................1469.6.2.2 Bulk Data Handling ............................................................................................155

9.7 GSLink .................................................................................................................................1579.7.1 GSLink with HTTP .....................................................................................................1579.7.2 Receive Request ........................................................................................................1589.7.3 Enable XML Parser ....................................................................................................159

80613ST10964A Rev. 5.0 7 2019-10-24

Page 8: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.7.4 Send XML Data ..........................................................................................................1599.7.5 Receive XML Data .....................................................................................................1629.7.6 Send Raw HTTP Data ................................................................................................1639.7.7 Receive Raw HTTP Data ...........................................................................................1659.7.8 Enable JSON Data .....................................................................................................1659.7.9 Send JSON Data ........................................................................................................1669.7.10 Receive JSON Data .................................................................................................1689.7.11 URI Registration (Modification) ................................................................................1709.7.12 Receive CGI Arguments ..........................................................................................1729.7.13 Receive Request Line ..............................................................................................1739.7.14 Receive HTTP Headers ...........................................................................................174

10 Advanced Services ................................................................................................................... 17510.1 Network .............................................................................................................................175

10.1.1 Ping ..........................................................................................................................17510.1.2 Service Discovery Using mDNS ...............................................................................177

10.1.2.1 mDNS Module Initialization ..............................................................................17710.1.2.2 mDNS Status ...................................................................................................17810.1.2.3 mDNS Host Name Registration .......................................................................17810.1.2.4 mDNS Services Registration ...........................................................................17910.1.2.5 mDNS Services De-registration .......................................................................18210.1.2.6 mDNS Service Discover ..................................................................................18310.1.2.7 mDNS Module De-Initialization ........................................................................18610.1.2.8 Example for mDNS Commands .......................................................................186

10.1.3 DNS Lookup (Client) ................................................................................................18810.2 Application Features ..........................................................................................................190

10.2.1 Firmware Update ......................................................................................................19010.2.1.1 Over the Air Firmware Upgrade Using Module Flash ......................................190

10.2.2 Provisioning ..............................................................................................................19310.2.2.1 Web Provisioning .............................................................................................193

11 Power Management - Radio and System ................................................................................. 20211.1 Radio Receiver Setting ......................................................................................................202

11.1.1 Active Radio Receive ...............................................................................................20211.1.2 Standard Power Save Radio Receive based on DTIM/Listen Interval .....................203

11.1.2.1 IEEE PS Poll Listen Interval ............................................................................20311.1.3 Custom Power Save Radio Receive ........................................................................206

12 Production and Debug .............................................................................................................. 20812.1 Debug ................................................................................................................................208

12.1.1 Log Level ..................................................................................................................20812.1.2 Echo .........................................................................................................................20912.1.3 Verbose ....................................................................................................................21012.1.4 RSSI .........................................................................................................................21112.1.5 WLAN Status ............................................................................................................21112.1.6 Network Status .........................................................................................................212

13 Appendix A - AT Commands Summary ................................................................................... 21513.1 Host Interaction .................................................................................................................21513.2 General Operations ...........................................................................................................21613.3 Wireless .............................................................................................................................21713.4 Network .............................................................................................................................22013.5 Data Transfer .....................................................................................................................22113.6 Advance Services ..............................................................................................................22513.7 Power Management - Radio and System ..........................................................................228

80613ST10964A Rev. 5.0 8 2019-10-24

Page 9: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

13.8 Production and Debug .......................................................................................................22913.9 Default Return Messages ..................................................................................................23013.10 Escape Sequence Commands ........................................................................................231

14 Glossary and Acronyms ........................................................................................................... 233

15 Document History .................................................................................................................... 234

80613ST10964A Rev. 5.0 9 2019-10-24

Page 10: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

1 Introduction

• Scope, page 10

• Audience, page 10

• Contact Information, Support, page 10

• Text Convention, page 11

• Related Documents, page 11

1.1 ScopeThis document is aimed in providing a detailed specification and a comprehensive listing as a reference for the whole set of AT command supported by the WL865E4-P module in legacy command mode.

1.2 AudienceThis document is intended for Telit customers, who are integrators, about to implement their applications using our WL865E4-P modules.

To use this document effectively, you should be already familiar with Telit modules and their ease of controlling by means of AT Commands.

1.3 Contact Information, SupportFor general contact, technical support services, technical questions, and report documentation errors contact Telit Technical Support at:

[email protected]

For detailed information about where you can buy the Telit modules or for recommendations on accessories and components visit:

https://www.telit.com

Our aim is to make this guide as helpful as possible. Keep us informed of your comments and suggestions for improvements.

Telit appreciates feedback from the users of our information.

80613ST10964A Rev. 5.0 10 2019-10-24

Page 11: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

1.4 Text ConventionTable 1, page 11, shows the symbol conventions used in this manual for notification and important instructions.

All dates are in ISO 8601 format, i.e. YYYY-MM-DD

1.5 Related DocumentsTo access the latest software downloads, product documentation, and support tools, visit https://www.telit.com/m2m-iot-products/wifi-bluetooth-modules.

1.5.1 Related Documents and Download– Data sheets

– Product User Guides

– EVK User Guides

– Software User Guides

– Application Notes

– TelitView installation and documentation

Table 1 Symbol Conventions

Icon Type Description

NoteProvides helpful suggestions needed in understanding a feature or references to material not available in the manual.

Alert Alerts you of potential damage to a program, device, or system or the loss of data or service.

Caution Cautions you about a situation that could result in minor or moderate bodily injury if not avoided.

Warning Warns you of a potential situation that could result in death or serious bodily injury if not avoided.

Electro-Static Discharge (ESD)

Notifies you to take proper grounding precautions before handling a product.

DangerIndicates information MUST be followed or catastrophic equipment failure or bodily injury may occur

80613ST10964A Rev. 5.0 11 2019-10-24

Page 12: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

1.5.2 Related Documents requiring a Non Disclosure Agreement– Authorized Software User Guides

– Product firmware

80613ST10964A Rev. 5.0 12 2019-10-24

Page 13: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

2 Overview

This chapter provides the guidelines for using the AT command line interface to design, configure, and provision WL865E4-P module in a Wireless network using serial commands.

• AT Commands, page 13

2.1 AT CommandsThe Telit wireless module family can be controlled via the serial interface using the standard AT commands.

2.1.1 AT Command DefinitionsThis document uses the following syntactical definitions:

– Special text fonts represent particular commands, keywords, variables, or window sessions

– Color text indicates cross-reference hyper links to supplemental information

– Command notation indicates commands, subcommands, or command elements

Table 2, page 13, describes the text conventions used in this manual for software procedures that are explained using the AT command line interface.

Table 2 Document Text Conventions

Convention Type Description [ ]Square brackets

Enclose optional parameters. Choose none; or select one or more an unlimited number of times each. Do not enter brackets as part of any command.

[parm1|parm2|parm3]

?Question mark

Used with the square brackets to limit the immediately following token to one occurrence.

<CR>Carriage return

Each command is terminated by a carriage return.

<LF>Line feed

Each command is terminated by a line feed.

80613ST10964A Rev. 5.0 13 2019-10-24

Page 14: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

<CR> <LF>Carriage returnLine feed

Each response is started with a carriage return and line feed with some exceptions.

< >Angle brackets

Enclose a numeric range, endpoints inclusive. Do not enter angle brackets as part of any command.

<SSID>

=Equal sign

Separates the variable from explanatory text. Is entered as part of the command.

PROCESSID = <CID>

.dot (period)

Allows the repetition of the element that immediately follows it multiple times. Do not enter as part of the command.

.AA:NN can be expanded to 1:01 1:02 1:03.

A.B.C.DIP address

IPv4-style address.

10.0.11.123

LINEEnd-to-line input token

Indicates user input of any string, including spaces. No other parameters may be entered after input for this token.

string of words

WORDSingle token

Indicates user input of any contiguous string (excluding spaces).

singlewordnospaces

Table 2 Document Text Conventions

Convention Type Description

80613ST10964A Rev. 5.0 14 2019-10-24

Page 15: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

2.1.2 AT Command SyntaxTable 3, page 15, describes the syntax rules followed by Telit implementation used in this document for software procedures that are explained using the AT command line interface.

Table 3 AT Command Syntax

Convention Type Descriptioncommand syntaxmonospaced font

This monospaced font represents command strings entered on a command line and sample source code.

AT XXXX

Proportional fontdescription

Gives specific details about a parameter.

<Data> DATA

UPPERCASEVariable parameter

Indicates user input. Enter a value according to the descriptions that follow. Each uppercased token expands into one or more other token.

lowercaseKeyword parameter

Indicates keywords. Enter values exactly as shown in the command description.

80613ST10964A Rev. 5.0 15 2019-10-24

Page 16: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

80613ST10964A Rev. 5.0 16 2019-10-24

3 Getting Started

This chapter describes how to get started.

• System Overview, page 16

• Legacy Command Mode, page 16

3.1 System OverviewThe Serial-to-Wireless stack is used to provide Wireless capability to any device having a serial interface. This approach offloads WLAN, TCP/IP stack and network management overhead to the Wireless chip, allowing a small embedded host (for example an MCU) to communicate with other hosts on the network using a Wireless link. The host processor can use serial commands to configure the Serial-to-Wireless Application and to create wireless and network connections.

3.2 Legacy Command ModeCommands provided in this document works only in legacy mode.

Page 17: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

4 Architecture

This chapter describes the system architecture of Serial-to-Wireless Application.

• Working Principle, page 17

• System Initialization, page 18

• Data Handling, page 19

• Serial Data Handling, page 23

• Wireless Network Management, page 23

4.1 Working PrincipleFigure 1, page 17, representation shows the communication between WL865E4-P Module and the Host:

Figure 1 Communication between the Module and the Host

80613ST10964A Rev. 5.0 17 2019-10-24

Page 18: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

4.2 System InitializationDuring the initialization process, the module SW tries to fetch the configuration file (also called as profile) from the file system. If the profile file is not found, it sets the default values (factory default values) to profile and creates the file in the file system.

In the profile, configuration related to wireless network, UDP/TCP/DNS/mDNS are kept. If the auto connection mode is set, then the module will attempt to join the wireless network and will try to open connection based on the UDP/TCP configuration. It configures the services and fetches based on the mDNS configuration.

Figure 2 Operating Modes in Serial-to-Wireless Application

NOTE: The default UART baud rate is 115200 instead of 921600, using 8 bit characters with no parity bits and one stop bit.

80613ST10964A Rev. 5.0 18 2019-10-24

Page 19: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

4.3 Data HandlingIn Data Processing Mode, data transfers are managed using various escape sequences. Each escape sequence starts with the ASCII character 27 (0x1B); this is equivalent to the ESC key. The encoding of data and related commands are described in the following pages. This encoding is used for both transmitted and received data.

The process of sending a data packet is depicted in Figure 3, page 20. The sequence ESC S or ESC U is sent to initiate the data transfer. This sequence is followed by a single-digit CID; if the CID is valid, the subsequent characters are assembled into a data stream, terminated by ESC E, ESC C, ESC S or ESC U. With a terminating sequence, the data is sent via the requested network connection and the system either returns to command processing or to further data processing.

Escape <ESC> sequences like ESC H, ESC S, ESC u and ESC U support only ASCII data handling while ESC Z, ESC Y and ESC y supports all types of data (ASCII, Binary etc.) handling.

80613ST10964A Rev. 5.0 19 2019-10-24

Page 20: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Figure 3 Data Processing Flow

80613ST10964A Rev. 5.0 20 2019-10-24

Page 21: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

4.3.1 Bulk Data Tx and RxIn Bulk Data Mode, data transfers are managed using escape sequences (ESC Z, ESC Y and ESC y). Each escape sequence starts with the Escape <ESC> key (ASCII character 27 (0x1B)). Encoding is used for both transmitted and received data. Enable bulk data by using command “AT+BDATA=”. For more details, see Bulk Data Handling, page 155

Table 4 Data Handling Responses at Completion

Operation Escape Sequence

Description

Send and Return to Command Mode Sequence

<ESC>C This sequence causes transmission of the data received on the serial interface on a TCP server/client or UDP client connection. After, the currently selected connection is closed and the interface returns to Command mode. Any buffered data is sent before the connection is closed.This can be issued from the serial host once the data transmissions start on a socket using <ESC>S<CID> sequence.

Success Indication <ESC>O OK: When serial host sends data to any socket, the network validates whether it is an active CID. This sequence is sent to the serial host through UART or SPI-NON DMA interface by the Serial-to-WiFi Application upon successful validation of active CID.Note: Sending <ESC> O has been intentionally removed in SPI DMA and SDIO interface to increase throughput.

Failure Indication <ESC>F FAILURE: This sequence is sent to the serial host by the Serial-to-WiFi Application through all interfaces (UART, SPI-NON DMA, SPI-DMA) when serial host sends data to any invalid socket.

NOTE: The contents of < > are either a byte or byte stream, except for <ESC>; literals outside brackets are ASCII characters.

80613ST10964A Rev. 5.0 21 2019-10-24

Page 22: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

4.3.2 Hardware Flow ControlThe Hardware Flow Control is a handshake mechanism between the Serial host and S2W Application on UART interface, using two additional CTS and RTS connections. This feature prevents the UART hardware FIFO overflow on S2W Application due to high speed data transmission from/to the S2W Application. If hardware flow control is enabled, an RTS/CTS handshake will occur between the serial host and the WL865E4-P node. This is a hardware feature and available only for UART interface.

The S2W Application uses both CTS and RTS signals as “low” to indicate the readiness to send or receive data from serial host.

80613ST10964A Rev. 5.0 22 2019-10-24

Page 23: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

4.4 Serial Data HandlingThe Serial Data Handler receives and transmits data to and from the hardware serial controller. Data read from the serial port is passed to:

– The command processor in command mode

– The Tx data handler in data mode

– The auto connection mode processor for data transfer in auto connection mode

Then Data is transferred on the serial port from:

– The command processor in order to output responses to commands

– The Tx data handler in order to output incoming packets

– The Rx data handler in order to output incoming packets

– The auto connection handler in order to output incoming data

– The connection manager in order to output status indications

– The wireless connection manager in order to output status indications

When configured in Auto Connection Mode, the WL865E4-P node enters directly into Data Processing Mode after the completing the connection without sending any status information to the Host.

4.5 Wireless Network Management

4.5.1 ScanningThe Serial-to-WiFi interface can instruct the WiFi radio to scan for access points with a specified SSID and/or channel for a specified scan time. Scanning can be performed to find networks with a specific SSID, networks operating on a specific radio channel or a combination of these constraints.

4.5.2 AssociationThe Serial-to-WiFi interface performs all the actions required to join an infrastructure IP network:

– Scan for a specific AP (AT+WS) – see Scanning, page 23

– Authenticate the specified network using the configured authentication mode (AT+WAUTH) – see Advanced Commands, page 66 for more information

– Associate to the AP (AT+WA) – see Association, page 23

– Perform security negotiation if required

– Change state to Wireless Connected

80613ST10964A Rev. 5.0 23 2019-10-24

Page 24: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

– Initialize the networking stack using the configured static IP address or via DHCP (AT+NDHCP) – see DHCP Client, page 75

4.5.3 SSID and PassphraseThe following rules apply:

1. The S2W Application accepts the following ASCII characters for SSID and Passphrase (see Table 5, page 24).

Note: 1. SP = space.

2. The SSID or Passphrase parameter may be captured within or without double quotation marks (“SSID”).

3. The quotation mark (“) may not be used as the first character of the SSID or Passphrase.

4. If comma (,) is a part of the SSID, then SSID parameter needs to be framed with double quotation marks (“SS,ID”) (see Table 6, page 24).

Table 5 SSID and Passphrase Characters

Category Accepted CharactersNumerical 0-9Alphabets a-z and A-ZSpecial Characters 1SP ! # $ % & ' ( ) * + , - . / : ; < = > ? @ [ \ ] ^ _ ` { | } ~ ”

Table 6 Expected and Input SSID

Expected SSID Input SSID RemarksTEST TEST Valid (satisfies rule 2)TEST “TEST” Valid (satisfies rule 2)TE”ST TE”ST Valid (satisfies rule 3)TE”ST “TE”ST” Invalid (breaks rule 3)TE,ST “TE,ST” Valid (satisfies rule 4)TE,ST TES,T Invalid (breaks rule 4)TE,S”T “TE,S”T” Invalid (breaks rule 3 and 4)

80613ST10964A Rev. 5.0 24 2019-10-24

Page 25: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

5 Host Interaction

This chapter describes how a communication interface is established between Host and WL865E4-P module.

• Interface, page 25

5.1 InterfaceThe embedded host uses one of the interfaces (UART/SPI/SDIO) to connect to the Serial-to-WiFi Application.

5.1.1 Software Flow ControlThis command is used to disable software flow control for the UART interface.

Command Syntax AT&Kn

Parameter Description

Table 7, page 25 describes the Software Flow Control parameters.

Synchronous Response

Table 8, page 25 describes the synchronous responses and remarks for the Software Flow Control command.

5.1.2 Hardware Flow ControlThis command is used to enable/disable hardware flow control for the UART interface.

Command Syntax AT&Rn

Table 7 Software Flow Control Parameters

Parameter Optional/Mandatory Value Descriptionn Mandatory 0 (default) Software flow control is disabled.

Table 8 Software Flow Control Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameter is not valid.(other than 0 or 1)

80613ST10964A Rev. 5.0 25 2019-10-24

Page 26: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Parameter Description

Table 9, page 26 describes the Hardware Flow Control parameters.

Synchronous Response

Table 10, page 26 describes the synchronous responses and remarks for the Hardware Flow Control command.

5.1.3 Interface VerificationThe command AT can be issued to verify that the interface is operating correctly or not.

Command Syntax AT

Synchronous Response

Table 11, page 26 describes the synchronous responses and remarks for the Interface Verification command.

Table 9 Hardware Flow Control Parameters

Parameter Optional/Mandatory Value Description

n Mandatory0 (default) Hardware flow control is disabled.1 Hardware flow control is enabled.

Table 10 Hardware Flow Control Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameter is not valid.(other than 0 or 1)

Table 11 Interface Verification Synchronous Responses

Responses RemarksOK Success

No responseFailureInterface not operating correctly.

80613ST10964A Rev. 5.0 26 2019-10-24

Page 27: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6 General Operations

This chapter describes the commands for generic operations as required by Serial-to-Wireless Application.

• Version, page 27

• System Settings, page 28

• Time Setting, page 30

• Profile Setting, page 35

• Reset, page 43

• MAC, page 43

6.1 VersionThis command is used to return version information.

Command Syntax AT+VER=?

Response– Serial-to-WiFi version

– Telit Embedded Platform Software version

– WLAN firmware version

Example 1 AT+VER=?S2W APP VERSION=7.0.0S2W GEPS VERSION=7.0.0S2W WLAN VERSION=7.0.0OK

The command to get more details of the S2W version.

AT+VER=??

ResponseThis command returns more information along with the above response of the S2W binary followed by the standard command response to the serial host.

– Serial-to-WiFi version

– Telit Embedded Platform Software version

– WLAN firmware version

80613ST10964A Rev. 5.0 27 2019-10-24

Page 28: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

– Serial-to-WiFi binary type as specified in SDK builder

– Serial-to-WiFi Release type which can be GA or Beta

– Build time

– Build date

– WLAN firmware extension version

– Application firmware extension version

– WLAN feature bitmap

– GEPS firmware extension version

– Module flash ID with storage capacity

Example 2 AT+VER=??S2W APP VERSION=7.0.0S2W GEPS VERSION=7.0.0S2W WLAN VERSION=7.0.0S2W BIN TYPE=DEFAULTS2W RELEASE TYPE=BETABUILD TIME=14:59:27BUILD DATE=Sep 18 2019WLAN EXT VERSION=2.0.1.9999S2W APP EXT VERSION=46WLAN FEAT BMAP=0000000000000237GEPS EXT VERSION=1FLASH ID=001628c2:MICRONIX-4MBOK

6.2 System Settings

6.2.1 Get Current Command Mode StatusThis command is used to get the status of the current command mode in which the module is operating.

Command Syntax AT+YLC=?

Synchronous Response

Table 12, page 29 describes the synchronous responses and remarks for getting the command mode status.

80613ST10964A Rev. 5.0 28 2019-10-24

Page 29: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+YLC?+YLC=0OK

6.2.2 Enable Legacy Command ModeThis command is used to reset the module and enable Legacy Command mode.

Command Syntax AT+YLC=n

NOTE: By default, the command mode is set to New AT command mode.

Parameter Description

Table 13, page 29 describes the parameter required to enable the legacy command mode.

Synchronous Response

Table 14, page 29 describes the synchronous responses and remarks for the legacy command mode.

Table 12 Get Current Command Mode Status

Responses Remarks

+YLC:<mode>OK

It specifies the current command mode.Success

ERROR:INVALID INPUT If parameters are not valid.(Other than 0 and 1)

Table 13 Legacy Command Mode

Parameter Optional/Mandatory Value Description

n Mandatory0 (default)

Legacy command mode is disabled and the module switches to New AT Command Mode.

1 Legacy command mode is enabled. Note: Once this command is issued, the system resets and starts with the configured command mode.

Table 14 Enable Legacy Command Mode

Responses Remarks

OK SuccessERROR:INVALID INPUT If parameters are not valid.

(Other than 0 and 1)

80613ST10964A Rev. 5.0 29 2019-10-24

Page 30: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6.3 Time Setting

6.3.1 Set System Time

6.3.1.1 Manual SettingThis command is used to set the Telit node’s system time to the time specified as in the parameters and then returns the standard command response. Telit node expects either one of the time parameters.

Command Syntax AT+SETTIME=[<dd/mm/yyyy>,<HH:MM:SS>][,System time in milliseconds since epoch (1970)]

Parameter Description

Table 15, page 30 describes the Set System Time parameters.

Synchronous Response

Table 16, page 30 describes the synchronous responses and remarks for the Set System Time command.

Example -1 AT+SETTIME=02/06/2016,15:00:00OK

Example -2 AT+SETTIME=,1493788674000OKAT+GETTIME=?3/5/2017,5:17:58,1493788678792OK

NOTE: This command does not take care of the day light savings. The reference will be with respect to UTC/GMT.

Table 15 Set System Time Parameters

Parameter Optional/Mandatory Descriptiondd/mm/yyyy Mandatory It specifies the date in dd/mm/yyyy format.HH:MM:SS Mandatory It specifies the time in HH:MM:SS format.System time in milliseconds since epoch (1970)

Optional It specifies the system time in milliseconds since epoch (1970).

Table 16 Set System Time Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT For invalid input

80613ST10964A Rev. 5.0 30 2019-10-24

Page 31: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6.3.1.2 Dynamic SettingThis command is used to set the Telit node system time using the SNTP.

Command Syntax AT+NTIMESYNC= <Enable>,<Server IP>,<Timeout>,<Periodic>,[<frequency>]

Parameter Description

Table 17, page 31 describes the Set System Time Using SNTP parameters.

Synchronous Response

Table 18, page 32 describes the synchronous responses and remarks for the Set System Time Using SNTP command.

NOTE: The time set by this command can be verified using the AT+GETTIME=? command.

Table 17 System Time Using SNTP Parameters

Parameter Optional/Mandatory Value Description

Enable Mandatory 0,1• 0 - stops the time sync• 1 - starts the time sync using SNTP

Server IP Mandatory N/A SNTP server IP

Timeout Mandatory N/A The time to wait for the server response (in seconds).

Periodic Mandatory 0,1

The time sync to be done one time orperiodically.• 0 - one time• 1 - periodic

Frequency Mandatory > 30 secondsIf the periodic flag is set, the time differencebetween each time sync (in seconds).

NOTE: 1> Only IP address is accepted here and no DNS names are allowed. In case of DNS name, first resolve the DNS name using AT+DNSLOOKUP command and then use IP address in this command. 2> In case of Periodic Time Sync, make sure that “Frequency” parameter value is greater than "TimeOut" parameter value.

80613ST10964A Rev. 5.0 31 2019-10-24

Page 32: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example 1 AT+NTIMESYNC=1,80.241.0.72,10,1,60

Example 2 Short Time Sync

Serial2WiFi APP

AT+NDHCP=1OKAT+WWPA=0384124610OKAT+WA=GSDemo IP SubNet Gateway 192.168.1.8:255.255.255.0:192.168.1.1OKAT+DNSLOOKUP=2.asia.pool.ntp.orgIP:103.16.182.23OK

AT+GETTIME=?1/1/1970,0:0:42,42300

OK

AT+NTIMESYNC=1,103.16.182.23,10,0OK

AT+GETTIME=?2/6/2016,9:48:28,1464860908560

OK

Example 3 Periodic Time Sync

AT+NDHCP=1OKAT+WWPA=0384124610OKAT+WA=GSDemo IP SubNet Gateway 192.168.1.8:255.255.255.0:192.168.1.1OK

Table 18 Set System Time Using SNTP Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT For invalid input

SNTP Busy If previous time synchronization is not completed.

80613ST10964A Rev. 5.0 32 2019-10-24

Page 33: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AT+DNSLOOKUP=2.asia.pool.ntp.orgIP:103.16.182.23OK

AT+GETTIME=?1/1/1970,0:0:42,42300

OK

AT+NTIMESYNC=1,103.16.182.23,10,1,60OK

AT+GETTIME=?2/6/2016,9:48:28,1464860908560

OK

6.3.2 Get System TimeThis command is used to receive the current system time in milliseconds since epoch (1970) followed by the standard command response to the serial interface.

Command Syntax AT+GETTIME=?

Synchronous Response

Table 19, page 33 describes the synchronous responses and remarks for the Get System Time command.

Example 1 AT+GETTIME=?2/6/2016,15:0:7,1464879607040

OK

Example 2 Serial2WiFi APPAT+TCERTADD=SSL_comodo,0,1500,1OKOKAT+CERTINFOGET=SSL_comodoERROR: INVALID INPUTAT+CERTINFOGET=SSL_comodocert->not_before: 1263859200cert->not_after: 2147471999valid from: Tue, 19 Jan 2010 00:00:00 GMT

Table 19 Get System Time Synchronous Responses

Responses Remarks

<dd/mm/yyyy>,<HH:MM:SS>SuccessDisplays date and time in the provided format.

ERROR:INVALID INPUT For invalid input

80613ST10964A Rev. 5.0 33 2019-10-24

Page 34: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

valid till: Fri, 13 Dec 1901 17:31:43 GMTOK

80613ST10964A Rev. 5.0 34 2019-10-24

Page 35: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6.4 Profile SettingTelit node supports different operating modes with various settings pre-configured to work with the system. A pre-defined set of variables can be stored in a profile. Telit node currently supports storing two different profiles (profile0 and profile1).

The following AT commands are sequentially executed for setting a profile:

– AT&V - To view the current profile

– AT&W - To write to profile settings

– ATZn - To load a profile

– AT&Y - To reboot with particular profile

– AT&F - To factory Reset

6.4.1 Get ProfileThis command is used to get the information of current profiles (Profile 0 and Profile 1) and their saved parameter values in ASCII format. The details of profile parameters are described in Save Profile, page 37.

Command Syntax AT&V

Synchronous Response

Table 20, page 36 describes the synchronous responses and remarks for the Get profile command.

80613ST10964A Rev. 5.0 35 2019-10-24

Page 36: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 20 Get Profile Synchronous Responses

Responses RemarksACTIVE PROFILEC0 &Y0 E1 V1 B=9600,8,N,1 &K0 &R0+NDHCP=0 +NSET=192.168.1.99,255.255.255.0,192.168.1.1+DNS1=0.0.0.0, +DNS2=0.0.0.0+WM=0 +WAUTO=0,"GSDemoKit",,6+WRETRY=5 +WP=0 +WRXPS=1 +WRXACTIVE=0+NAUTO=0,1,192.168.1.1,8+WAUTH=0 +WWPA="Serial2Wifi"+PSK-valid=0 +SSID=+WWEP1=1234567890 +WWEP2=S0=01000 S1=00500 S2=00500 S3=00003 S4=00010 S5=00150 S6=00050 S7=00020 S8=01400+BDATA=0+WSEC=0+ASYNCMSG=0 STORED PROFILE 1

Success

The number of profiles depends upon the default configuration of the module.

STORED PROFILE 1E1 V1 B=9600,8,N,1 &K0 &R0+NDHCP=0 +NSET=192.168.1.99,255.255.255.0,192.168.1.1+DNS1=0.0.0.0, +DNS2=0.0.0.0+WM=0 +WAUTO=0,"GSDemoKit",,6+WRETRY=5 +WP=0 +WRXPS=1 +WRXACTIVE=0+NAUTO=0,1,192.168.1.1,8+WAUTH=0 +WWPA="Serial2Wifi"+PSK-valid=0 +SSID=+WWEP1=1234567890 +WWEP2=+WWEP3= +WWEP4=S0=01000 S1=00500 S2=00500 S3=00003 S4=00010 S5=00150 S6=00050 S7=00020 S8=01400+BDATA=0+WSEC=0+ASYNCMSG=0 STORED PROFILE 1

E1 V1 B=9600,8,N,1 &K0 &R0+NDHCP=0 +NSET=192.168.1.99,255.255.255.0,192.168.1.1+DNS1=0.0.0.0, +DNS2=0.0.0.0+WM=0 +WAUTO=0,"GSDemoKit",,6+WRETRY=5 +WP=0 +WRXPS=1 +WRXACTIVE=0+NAUTO=0,1,192.168.1.1,8+WAUTH=0 +WWPA="Serial2Wifi"+PSK-valid=0 +SSID=+WWEP1=1234567890 +WWEP2=+WWEP3= +WWEP4=S0=01000 S1=00500 S2=00500 S3=00003 S4=00010 S5=00150 S6=00050 S7=00020 S8=01400+BDATA=0+WSEC=0+ASYNCMSG=0OK

Success

80613ST10964A Rev. 5.0 36 2019-10-24

Page 37: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6.4.2 Save Profile

This command is used to save the current profile. Upon deployment of this command, the current configuration settings are stored in non-volatile memory under the specified profile, (profile 0, or profile 1). In order to ensure that these parameters are restored after power cycling the Telit node, the command AT&Y must also be issued, using the same profile number selected here.

Command Syntax AT&Wn

Parameter Description

Table 21, page 37 describes the Save Profile parameters.

Synchronous Response

Table 22, page 37 describes the synchronous responses and remarks for the Save Profile command.

Table 21 Save Profile Parameters

Parameter Optional/Mandatory Value Description

n Mandatory0 For profile 01 For profile 1Saves the profile specified by n (0 or 1).

Table 22 Save Profile Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameters are not valid.(n value is other than 0 or 1)

NOTE: Telit node supports two profiles.

80613ST10964A Rev. 5.0 37 2019-10-24

Page 38: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6.4.3 Load ProfileThis command is used to load a profile. Upon deployment of this command, the currently configured settings are overwritten by those stored in non-volatile memory under the specified profile.

Command Syntax ATZn

Parameter Description

Table 23, page 38 describes the Load Profile parameters.

Synchronous Response

Table 24, page 38 describes the synchronous responses and remarks for the Load Profile command.

Table 23 Load Profile Parameters

Parameter Optional/Mandatory Value Description

n Mandatory0 For profile 01 For profile 1Load the profile specified by n (0 or 1).

Table 24 Load Profile Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameters are not valid.(n value is other than 0 or 1)

80613ST10964A Rev. 5.0 38 2019-10-24

Page 39: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6.4.4 Select Default ProfileThis command is used to select the default profile. The settings from the profile that are chosen as the default profile are loaded from non-volatile memory when the device is started.

Command Syntax AT&Yn

Parameter Description

Table 25, page 39 describes the Select Default Profile parameters.

Synchronous Response

Table 26, page 39 describes the synchronous responses and remarks for the Select Default Profile command.

Example AT&Y0OK

Table 25 Select Default Profile Parameters

Parameter Optional/Mandatory Value Description

n Mandatory0 For profile 01 For profile 1Set default profile to the value n (0 or 1).

Table 26 Select Default Profile Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameters are not valid.(n value is other than 0 or 1)

80613ST10964A Rev. 5.0 39 2019-10-24

Page 40: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6.4.5 Define ProfileThe configuration parameter values that define the behavior of the Telit node are grouped into Profiles. These profiles are stored in non-volatile memory when not in use. The default configuration supports single Profile. The contents of a profile are listed in Table 27, page 40.

Table 27 Define Profile Parameters

Parameter Values ReferenceGeneral Wireless Parameter802.11 Operating Mode STA, Limited AP Operation Mode, page 46Transmit Power Configuration N/A802.11 Transmit Retry Count N/APower Save Mode Enabled, Disabled Custom Power Save Radio Receive, page 206802.11 Radio Mode Enabled, Disabled Active Radio Receive, page 202Auto Connect Mode, Wireless Interface Settings802.11 Operating Mode STA

Wireless Parameters, page 135Operating Channel 4,10,11,12,13,14,26,27SSID Parameter Any valid SSIDAuto Connect Mode, Network Interface SettingsMode Server, Client

DHCP Client, page 75Protocol TCP, UDPServer Port Number Any valid portServer IP Address Any valid IP addressHost Name Valid Domain nameWireless Interface Security ConfigurationAuthentication Mode Open, Shared Advanced Commands, page 66PSK Valid Valid, Invalid

WPA-PSK and WPA2-PSK Key Calculation, page 57PSK-SSID Any valid SSID, used for

PSK key computationWEP Key Configuration Advanced Commands, page 66WPA Pass Phrase WPA-PSK and WPA2-PSK Passphrase, page 56TCP/IP ConfigurationDHCP Mode Enabled, Disabled DHCP Client, page 75IP Address Valid IP address

IP Address, page 81Net Mask Address Valid maskDefault Gateway Address Valid IP addressDNS1 Valid DNS1 IP address

DNS Address, page 81DNS2 Valid DNS2 IP addressUART Configuration

80613ST10964A Rev. 5.0 40 2019-10-24

Page 41: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6.4.6 Restore ProfileThis command is used to restore current profile to factory default values. The factory default values are stored in RAM, and will be lost after each power cycle.

Upon deployment of this command, the current configuration variables are reset to the factory defaults. These defaults are defined by macro values in the configuration header. Issuing this command resets essentially all configuration variables.

Command Syntax AT&F

Synchronous Response

Table 28, page 41 describes the synchronous responses and remarks for the Restore Profile command.

6.4.7 Identification InformationThis command is used to return various identification information of Telit node.

Command Syntax ATIn

Parameter Description

Echo Mode Enabled, Disabled Echo, page 209Verbose Mode Enabled, Disabled Verbose, page 210Hardware Flow Control Mode Enabled, Disabled Hardware Flow Control, page 22

Table 27 Define Profile Parameters (Continued)

Parameter Values Reference

Table 28 Restore Profile Synchronous Responses

Responses RemarksOK Success

NOTE: The following sequence of AT Commands is used for complete Factory restore: AT&Y0 AT&F AT&W0 AT&Y1 AT&F AT&W1 AT+RESET=1

80613ST10964A Rev. 5.0 41 2019-10-24

Page 42: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 29, page 42 describes the Identification Information parameters.

Synchronous Response

Table 30, page 42 describes the synchronous responses and remarks for the Identification Information command.

Table 29 Identification Information Parameters

Parameter Optional/Mandatory Value Description

n Mandatory

0 OEM identification1 Hardware version2 Software version

n is the information ID to obtain. These responses are provided as ASCII strings in addition to the standard command response.

Table 30 Identification Information Synchronous Responses

Responses RemarksTelit OK SuccessATI1:GSxxxxOK

Displays the hardware version

ATI2:x.x.xOK

The software version will change whenever a new feature is added.

ERROR:INVALID INPUTIf parameters are not valid.(n value is other than 0-2)

80613ST10964A Rev. 5.0 42 2019-10-24

Page 43: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

6.5 ResetThis command is used to reset the Telit node. When this command is used without parameter (AT+RESET), it forcefully resets the module core and comes out with a fresh boot message “APP Reset-APP SW Reset”.

Command Syntax AT+RESET

Command Syntax AT+RESET=n

Parameter Description

Table 31, page 43 describes the Reset parameters.

6.6 MACAll new WL865E4-P modules will have “00:21:7E:xx:xx:xx” as MAC address with Telit Organizational Unique Identifier (OUI).

6.6.1 Get MAC AddressThis command is used to output the current MAC address of the wireless interface to the serial port.

NOTE: This command without parameter (AT+RESET) is obsolete and it is retained for backward compatibility.

NOTE: It is recommended to use this command with parameter (AT+RESET=1).

Table 31 Reset Parameters

Parameter Optional/Mandatory Value Description

n OptionalValue range: 1Format: Decimal

1:Resets the whole system including the RTC domain.

80613ST10964A Rev. 5.0 43 2019-10-24

Page 44: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Command Syntax AT+NMAC=?

Synchronous Response

Table 32, page 44 describes the synchronous responses and remarks for the Get MAC Address command.

Example 1 To get the current MAC address for the Telit node in STA mode, execute the following sequence of commands:

AT+WM=0OK

AT+NMAC=?00:1d:c9:d0:70:ccOK

Example 2 To get the current MAC address for the Telit node in AP mode, execute the following sequence of commands:

AT+WM=2OK

AT+NMAC=?00:1d:c9:d0:70:ccOK

NOTE: 1.) The Telit node is stored with two MAC addresses. One when it is in STA mode and the other when it is in AP mode. The MAC address printed on the Telit node is for STA mode. STA MAC address + 1 is the MAC address for AP mode. 2.) To get the current MAC address for the Telit node in STA mode, execute the command AT+WM=0 followed by the AT+NMAC=? command. 3.) To get the current MAC address for the Telit node in AP mode, execute the command AT+WM=2 followed by the AT+NMAC=? command.

Table 32 Get MAC Address Synchronous Responses

Responses RemarksOK Success

80613ST10964A Rev. 5.0 44 2019-10-24

Page 45: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

7 Wireless

This chapter describes commands for configurations and operations related to WLAN layer.

• Wireless Generic, page 45

• Station/AP Mode, page 53

• Concurrent Mode (STA Plus AP), page 67

7.1 Wireless Generic

7.1.1 Regulatory Domain

7.1.1.1 Set Regulatory DomainThis command is used to configure the Telit node’s parameters to the requested regulatory domain.

Command Syntax AT+WREGDOMAIN=<Regulartory Domain>

Parameter Description

Table 33, page 45 describes the Set Regulatory Domain parameters.

Synchronous Response

Table 33 Set Regulatory Domain Parameters

Parameter Optional/Mandatory

Value Regulatory Domain

Supported Channels

Desired Power Level

Regulatory Domain Mandatory

Internal PA (0 as default)

Internal PA (2 as default)

0 (default) FCC 1 to 11 0-7 2-151 ETSI 1 to 13 0-7 4-152 TELEC 1 to 14 0-7 2-15The Regulatory domain set is required only once since it is being updated in the Flash.

80613ST10964A Rev. 5.0 45 2019-10-24

Page 46: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 34, page 46 describes the synchronous responses and remarks for the Set Regulatory Domain command.

7.1.1.2 Get Regulatory DomainThis command is used to output the current regulatory domain of the wireless interface to the serial port.

Command Syntax AT+WREGDOMAIN=?

Synchronous Response

Table 35, page 46 describes the synchronous responses and remarks for the Get Regulatory Domain command.

Example AT+WREGDOMAIN=?REG_DOMAIN=FCCOK

Where possible values of REG_DOMAIN are: FCC, ETSI, TELEC

7.1.2 Operation ModeThis command is used to set the wireless mode and related parameters.

Command Syntax AT+WM=<wireless mode>[,<beacon interval in LAP mode>,<broadcast ssid in LAP mode>,<no. of stations allowed in LAP mode>,<DTIM period in LAP mode>,<inactivity timeout in LAP mode>,<reserved>,<rate adaptation-device type>,<rate adaptation-minimum application throughput>]<CR>

Table 34 Set Regulatory Domain Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameters are not valid.(If Register domain value is other than 0-3)

Table 35 Get Regulatory Domain Synchronous Responses

Responses RemarksREG_DOMAIN=FCCOK

Success

80613ST10964A Rev. 5.0 46 2019-10-24

Page 47: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Parameter Description

Table 36, page 47 describes the parameters in Wireless Mode.

NOTE: Do not issue AT+WA command when Telit node is in WiFi direct (P2P) mode. To issue AT+WA command, switch the Telit node to either Station mode or Limited-AP mode using AT+WM command.

Table 36 Mode Parameters

Parameter Optional/Mandatory Value Description

wireless mode Mandatory

0: WiFi station mode1: Reserved2: WiFi limited AP mode3: WiFi direct mode(P2P) (Not Supported)4: Reserved6: Provisioning AP mode (Not Supported)Default value- 0

It specifies the wireless mode to be set.Note: When this parameter is set to 3, do not issue AT+WA command. To issue AT+WA command, set this parameter to either 0 (Station mode) or 2 (Limited-AP mode).

beacon interval in LAP mode Optional

100 to 1000Unit: millisecondsDefault value: 100ms

Time between two successive beacon frames transmitted by the Limited AP mode.

broadcast SSID in LAP mode Optional

0, 10: Enable1: DisableDefault value: 0

0- Beacon frames will contain SSID information.1- Beacon frames will not contain SSID information (stealth mode).It specifies whether to broadcast SSID in the beacon frames or not (only applicable in limited AP mode).Note: If WPS Registrar functionality is required, do not disable SSID broadcast.

No. of stations allowed to associate in LAP mode

Not Supported N/A Reserved for future use.

80613ST10964A Rev. 5.0 47 2019-10-24

Page 48: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 37, page 49 describes the synchronous responses and remarks for the Wireless Mode command.

DTIM period in LAP mode Optional

Minimum value: 1Maximum value: 255Default value: 3

It specifies the DTIM period in AP mode. Value to be as minimum as possible. Unit is in beacon intervals.For more information, refer 802.11 specification.Note: Recommended to configure this value as small as possible.

inactivity time-out in LAP mode Optional

Minimum value: 60Maximum value: 65000Default value: 60 Unit: seconds

This value specifies the inactivity time out per STA, after which LAP send a NULL/QoS-NULL frame expecting the STA to MAC level acknowledge it.When there is no activity from a connected node, the module waits for 60 seconds and sends a probe to the inactive node. If there is no response, then it disconnects itself from the inactive node.Note: WL865E4-P does not send dis-association frame to STA.

reserved Optional N/A N/Arate adaptation-device type

Not Supported N/A Reserved for future use.

rate adaptation-minimum application throughput

Not Supported N/A Reserved for future use.

Note: 1.) Minimum throughput is dependent on TCP/UDP.2.) Rate adaptation-device type and rate adaptation-minimum application throughput parameter is to be provided, since both go in pair3.) These parameters are only a guidance to WLAN. The system tries to achieve it but it may not be always achievable due to various circumstances such as Wireless environments, application use case, and so on.

Table 36 Mode Parameters (Continued)

Parameter Optional/Mandatory Value Description

80613ST10964A Rev. 5.0 48 2019-10-24

Page 49: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Su

Fa

Example 1 Configure device in STA mode

AT+WM=0

Configure device in Limited-AP mode (default configuration)AT+WM=2

Example 2 Configure device in Limited-AP mode, with following configuration:

AT+WM=2, , ,16,1, , ,1,5Number of stations allowed to associate in Limited-AP mode = 16DTIM period in LAP mode=1Device type = Line poweredMinimum application throughput = 5mbpsConfigure the device in LAP mode with 10 seconds as inactivityAT+WM,,,,,10

7.1.3 PHY Mode

7.1.3.1 Set PHY Mode

This command is used to configure 802.11.

Command Syntax AT+WPHYMODE=<PHY mode>

Parameter Description

Table 38, page 49 describes the parameters required to set the PHY mode.

Table 37 Mode Synchronous Responses

Events Verbose mode Non Verbose mode Remarksccess <CR><LF>OK<CR><LF> <CR><LF>OK<CR><LF> All parameters are valid

ilure <CR><LF>ERROR:<SP>INVALID<SP>INPUT<CR><LF> <CR><LF>2<CR><LF> Parameters are invalid or in

incorrect format.

Table 38 Set PHY Mode Parameters

Parameter Optional/Mandatory Value Description

PHY mode Mandatory

0 802.11b only1 802.11g only2 802.11b/g only (Not Supported)3 802.11b/g/n (Not Supported)6 802.11g/n only

80613ST10964A Rev. 5.0 49 2019-10-24

Page 50: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 39, page 50 describes the synchronous responses and remarks to set the PHY mode command.

7.1.3.2 Get PHY Mode

This command is used to get the PHY mode.

Command Syntax AT+WPHYMODE=?

Synchronous Response

Table 40, page 50 describes the synchronous responses and remarks for getting the PHY Mode command.

Example AT+WPHYMODE=?2OK

7.1.4 Transmit Data Rate

7.1.4.1 Set Transmit Rate

This command is used to set the transmit rate.

Table 39 Set PHY mode Synchronous Responses

Responses RemarksOK SuccessERROR:NOT SUPPORTED If parameters are not valid

Table 40 Get PHY Mode Synchronous Responses

Responses RemarksMode ValueOK

Success

Note: Where mode is: 0,1,6

NOTE: This command is used for testing and debug purposes only. It is not fully functional and it is not tested for higher rates.

80613ST10964A Rev. 5.0 50 2019-10-24

Page 51: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Command Syntax AT+WRATE=<Transmit rate of data frame>[,<Transmit rate of management frame>,<Transmit rate of control frame>]

Command Note To set the transmission rate to 11Mbps, give the value as 22.

The transmission rate must be set prior to association. Once association is successful, the changed values will be reflected.

Example AT+WRATE=22

Parameter Description

Table 41, page 52 describes the parameters required to set the transmit rate.

80613ST10964A Rev. 5.0 51 2019-10-24

Page 52: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 42, page 53 describes the synchronous responses and remarks for the setting the Transmit Rate command.

Table 41 Set Transmit Rate Parameters

Parameter Optional/Mandatory Value Corresponding Transmission

Rate

Description

Transmit rate of data frame Mandatory

2 1 MBPS

This parameter specifies the transmission rate for data frames.If only this parameter is provided in the command, then the same value is copied for the remaining parameters Transmit rate of management frame and Transmit rate of control frame.

4 2 MBPS11 5.5 MBPS12 6 MBPS13 6.5 MBPS18 9 MBPS22 11 MBPS24 12 MBPS36 18 MBPS39 19.5 MBPS48 24 MBPS52 26 MBPS72 36 MBPS78 39 MBPS96 48 MBPS104 52 MBPS108 54 MBPS117 58.5 MBPS130 65 MBPS

Transmit rate of management frame

Not SupportedN/A

Reserved for future use.

Transmit rate of control frame Not Supported Reserved for future use.

80613ST10964A Rev. 5.0 52 2019-10-24

Page 53: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+WRATE=2OK

7.2 Station/AP Mode

7.2.1 Scan Time Settings

7.2.1.1 Set Scan TimeThis command is used to set the minimum and maximum scan time per channel. The maximum scan time should always be greater than or equal to the minimum scan time. This command also modifies the scan time configured with the ATS5 command.

Command Syntax AT+WST=<Minimum scan time><Reserved><Max scan time><CR>

Parameter Description

Table 43, page 53 describes the Set Scan Time parameters.

Synchronous Response

Table 44, page 54 describes the synchronous responses and remarks for the Set Scan Time command.

Table 42 Set Transmit Rate Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameters are not valid(if value is other than above specified value)

NOTE: This is the recommended method to set scan time per channel and obsoletes all other methods to configure scan time including ATS5 command.

Table 43 Set Scan Time Parameters

Parameter Optional/Mandatory Value (milliseconds) Description

Minimum scan time Mandatory5-1200Default time = 200Unit-milliseconds

Minimum amount of time, radio receiver needs to be kept on per channel while scanning.

reserved Not Supported N/A Reserved for future use. Maximum scan time Not Supported N/A Reserved for future use.

80613ST10964A Rev. 5.0 53 2019-10-24

Page 54: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+WST=150,150OK

7.2.1.2 Get Scan TimeThis command is used to display minimum and maximum scan time in milliseconds.

Command Syntax AT+WST=?

Synchronous Response

Table 45, page 54 describes the synchronous responses and remarks for the Get Scan Time command.

Example AT+WST=?MinScanTime=150MaxScanTime=150

7.2.2 Security Configuration

7.2.2.1 Security SettingThis command is used to configure the Telit node with different security configuration.

Command Syntax AT+WSEC=n

Parameter Description

Table 46, page 55 describes the Security Configuration parameters.

Table 44 Set Scan Time Synchronous Responses

Events Verbose Mode Non Verbose Mode RemarksSuccess <CR><>LF>OK<CR><LF> <CR><LF>0<CR><LF> Parameters are valid

Failure <CR><LF>ERROR:<SP>INVALID<SP>INPUT<CR><LF> <CR><LF>2<CR><LF> Parameters invalid

Table 45 Get Scan Time Synchronous Responses

Responses Remarks

MinScanTime=150MaxScanTime=150OK

SuccessDisplays “MinScanTime” and “MaxScanTime” which is configured using AT+WST command.By default it displays the default values that is 150ms (milliseconds) for min and max scan time.

80613ST10964A Rev. 5.0 54 2019-10-24

Page 55: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 47, page 56 describes the synchronous responses and remarks for the Security Configuration command.

Table 46 Security Configuration Parameters

Parameter Optional/Mandatory Value Mode Description

n Mandatory

0 (default) Auto security (All)

The Serial to Wireless Application supports either one of the Values. This strict security compliance is not applicable for WPS feature.

1 Open security

2 WEP security (Not Supported)

4 WPA-PSK security (TKIP only)

8 WPA2-PSK security (AES only)

16WPA Enterprise (Not Supported)

32WPA2 Enterprise (Not Supported)

64 WPA2-AES+TKIP security (Not Supported)

Note: 1> In AP mode, only Open and WPA-AES as security mechanism is supported.2> Enterprise security is supported in Station mode and not supported in limited AP mode.3> Concurrent mode AP configuration settings varies from normal Limited AP mode configuration.4> Telit module is unsuccessful to associate to an AP (WPA personal) when configured with AES for both Multicast and Unicast (as the Group Key Handshake timeout is (0x0010))Security: WEP-64 Open/Shared,WEP-128 Open/Shared,WPA-Personal (TKIP),WPA2-Personal (AES),WPA2-Personal (AES+TKIP),WPA Enterprise (TKIP),WPA2-Enterprise (AES),WPA2-Enterprise (AES+TKIP).6>Only TKIP is supported in WPA

80613ST10964A Rev. 5.0 55 2019-10-24

Page 56: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example - Telit node is configured with WEP shared security

AT+WAUTH=2OK

AT+WSEC=2OK

AT+WWEP1=0987654321OK

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

7.2.2.2 WPA-PSK and WPA2-PSK PassphraseThis command is used to set the WPA-PSK and WPA2-PSK passphrase. Upon receiving the command, the PSK passphrase is reset to the value provided.

Command Syntax AT+WWPA=<passphrase>

Parameter Description

Table 48, page 56 describes the WPA-PSK and WPA2-PSK Passphrase parameters.

Table 47 Security Configuration Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameters are not valid.(n value is other than above mentioned value)

NOTE: It is recommended to use AT+WPAPSK command instead of the following command. See WPA-PSK and WPA2-PSK Key Calculation, page 57.

Table 48 WPA-PSK and WPA2-PSK Passphrase Parameters

Parameter Optional/Mandatory Value Description

passphrase Mandatory 8-63

The passphrase is a string containing between 8 and 63 ASCII characters, used as a seed to create the WPA pre-shared key (PSK).If the comma (,) is a part of the passphrase, the passphrase parameter is to be framed in double quotation marks (“passphrase”). See SSID and Passphrase, page 24 for details.

80613ST10964A Rev. 5.0 56 2019-10-24

Page 57: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 49, page 57 describes the synchronous responses and remarks for the WPA-PSK and WPA2-PSK Passphrase command.

Example AT+WWPA=test12345OK

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

7.2.2.3 WPA-PSK and WPA2-PSK Key CalculationThis command is used to compute and store the value of the WPA/WPA2 PSK, derived from the SSID and Passphrase values. Computation of the PSK from the passphrase is complex and consumes substantial amounts of time and energy. To avoid recalculating this quantity every time the WL865E4-P node associates, the WL865E4-P node provides the capability to compute the PSK once and store the resulting value. The key value is stored in the SRAM copy of the current profile; the profile needs to be saved in flash memory for this value to persist during a transition to Standby.

Command Syntax AT+WPAPSK=<SSID>,<passphrase>

Parameter Description

Table 50, page 57 describes the WPA-PSK and WPA2-PSK Key Calculation parameters.

Synchronous Response

Table 51, page 58 describes the synchronous responses and remarks for the WPA-PSK and WPA2-PSK Calculation command.

Table 49 WPA-PSK and WPA2-PSK Passphrase Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT Invalid passphrase

Table 50 WPA-PSK and WPA2-PSK Key Calculation Parameters

Parameter Optional/Mandatory Value Description

SSID Mandatory 1-32 The SSID is a string of between 1 and 32 ASCII characters. See SSID and Passphrase, page 24.

PASSPHRASE Mandatory 8-63

The passphrase is a string containing between 8 and 63 ASCII characters used as a seed to create the WPA pre-shared key (PSK). See SSID and Passphrase, page 24.

80613ST10964A Rev. 5.0 57 2019-10-24

Page 58: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+WPAPSK=TelitDemo,test12345Computing PSK from SSID and PassPhrase...OK

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

AT&W0OKAT+PSSTBY=1000

Out of StandBy-Timer

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

Table 51 WPA-PSK and WPA2-PSK Calculation Synchronous Responses

Responses Remarks

Computing PSK from SSID and PassphraseOK

SuccessThe WL865E4-P node immediately responds with this message along with standard OK response (0 in non-verbose). The current profile parameters PSK Valid, PSK-SSID, and WPA Passphrase are updated and can be queried with AT&V. The next time the WL865E4-P node associates to the given SSID, the PSK value is used without being recalculated.After the PSK has been computed, the command AT&W (to save the relevant profile) and AT&Y (to ensure that the profile containing the new PSK is the default profile) should be issued. The PSK will then be available when the WL865E4-P node awakens from Standby mode. See Select Default Profile, page 39 for profile management.

ERROR:INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 58 2019-10-24

Page 59: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

7.2.2.4 WPA-PSK and WPA2-PSK KeyThis command is used to configure the WPA/WPA2 PSK key directly. It directly sets the pre-shared key as provided. The argument is a 32-byte key, formatted as an ASCII hexadecimal number; any other length or format is considered invalid.

Command Syntax AT+WPSK=<PSK>

Parameter Description

Table 52, page 59 describes the WPA-PSK and WPA2-PSK Key parameters.

Synchronous Response

Table 53, page 59 describes the synchronous responses and remarks for the WPA-PSK and WPA2-PSK Key command.

Example AT+WPSK=0001020304050607080900010203040506070809000102030405060708090001OK

AT&W0OK

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

NOTE: This command should be used along with the AT+WM command.

Table 52 WPA-PSK and WPA2-PSK Key Parameters

Parameter Optional/Mandatory Value Description

PSK Mandatory 32 byte keyPSK is a 32 byte key, formated as an ASCII hexadecimal number, and other length or format is considered invalid.

Table 53 WPA-PSK and WPA2-PSK Key Synchronous Responses

Responses Remarks

OK

SuccessAfter the PSK has been entered, the commands AT&W (to save the relevant profile) and AT&Y (to ensure that the profile containing the new PSK is the default profile) should be issued. The PSK will then be available when the Telit node awakens from Standby.

ERROR:INVALID INPUT Invalid PSK (if PSK is not 32 bytes)

80613ST10964A Rev. 5.0 59 2019-10-24

Page 60: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AT+PSSTBY=1000Out of StandBy-Timer

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

80613ST10964A Rev. 5.0 60 2019-10-24

Page 61: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

7.2.3 ScanningThis command is used to scan for networks with the specified parameters and displays the results. Scanning can be performed to find networks with specific SSID or in a particular operating channel, or a combination of these parameters. Scanning for a specific SSID employs active scanning, in which probe requests are transmitted with the SSID fields being filled appropriately.

Command Syntax AT+WS[=<SSID>[,<BSSID>][,<Channel>][,<Scan Time]]

Parameter Description

Table 54, page 61 describes the Scanning parameters.

Synchronous Response

Table 55, page 62 describes the synchronous responses and remarks for the Scanning command.

Table 54 Scanning Parameters

Parameter Optional/Mandatory Value Description

SSID Optional N/A

A string containing ASCII characters between 1 and 32 (see SSID and Passphrase, page 24).When SSID is specified, the Telit node only scans the configured SSID.

BSSID Not Supported N/A Reserved for future use.

Channel Optional 1-165

If channel is specified, then the node scans only that particular channel, else it scans all valid channels based on configured reg domain.Note: Maximum Scan per channel is 20.

Scan Time Optional5-1200 (milliseconds)150 (default)

It specifies the default scan time that the node uses. The default scan time can be overridden by issuing AT+WST command (see Set Scan Time, page 53).Configuring scan time using this parameter is obsolete.The recommended method to set scan time per channel is by using AT+WST command (see Set Scan Time, page 53).

80613ST10964A Rev. 5.0 61 2019-10-24

Page 62: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example Use Case 1 - for Infrastructure NetworkAT+WS=TelitDemo,,11BSSID SSID Channel Type RSSI Securityc8:d7:19:75:74:fb, TelitDemo ,11, INFRA, -39, NONENo.Of AP Found:1OK

Example Use Case 2 - for Ad-Hoc NetworkAT+WS=TelitAdHocBSSID SSID Channel Type RSSI Security62:67:20:01:f1:07, TelitAdHoc ,11, ADHOC, -30, NONENo.Of AP Found:1OK

7.2.4 AssociationThis command is used to create or join an infrastructure network (limited access point mode), and to create or join to an ad-hoc network.

Command Syntax AT+WA=<SSID>[,[<BSSID>][,<Channel>],[RSSI Flag],[WPS Registrar],[Unscheduled automatic power save delivery configuration]]

Command Note • The WPS registrar is supported only with WPA/WPA2 security. It is not supported in open security.

• When WPA registrar is required, setting strict security using AT+WSEC (See Scanning, page 61) command is mandatory before issuing the AT+WA command.

Usage The following is the behavior of the command in different modes:

1. In STA mode, i.e., AT+WM=0 (see Operation Mode, page 46). The node will attempt to associate with the requested network. If the requested network is not available, an error message will display.

Table 55 Scanning Synchronous Responses

Responses Remarks<CR><LF><7 SP><BSSID><14 SP><SSID><21 SP><Channel><2 SP><TYPE><2 SP><RSSI><SP><Security><CR><LF><SP> <CR><LF><No.Of><SP><AP><SP><Found:><CR><LF><CR><LF>OK<CR><LF>OK

SuccessType is INFRA for infrastructure network andADHOC for ad-hoc networks.

80613ST10964A Rev. 5.0 62 2019-10-24

Page 63: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

2. In ad-hoc mode, i.e., AT+WM=1 (see Operation Mode, page 46). The node will attempt to associate with the requested network. If the network with the desired SSID or channel or both is not found, then a new ad-hoc network is created. However, if BSSID is specified in the request, and the applicable BSSID is not found, the node will report an error and will not create a network.

3. In AP mode, i.e., AT+WM=2 (see Operation Mode, page 46), The node creates an infrastructure (Limited AP) network with the specified SSID. Issue AT+WSEC=n (refer Scanning, page 61 for values) to create Limited AP with security as specified in Table 46, page 55.

Parameter Description

Table 56, page 64 describes the associate with a Network or create an Ad-hoc or Infrastructure (AP) Network parameter.

NOTE: Do not issue AT+WA command when Telit node is in Wireless direct (P2P) mode. To issue AT+WA command, switch the Telit node to either Station mode or Limited-AP mode using AT+WM command.

80613ST10964A Rev. 5.0 63 2019-10-24

Page 64: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 57, page 65 describes the synchronous responses and remarks for associating with a network or creating an AP network.

Table 56 Associate with Network or Create an Ad Hoc or AP Network Parameters

Parameter Optional/Mandatory Value Description

SSID Mandatory 1-32 charactersThe SSID is a string containing between 1 and 32 ASCII characters. See SSID and Passphrase, page 24 for SSID format details.

BSSID Not Supported

MAC is the 17 characters colon-delimited hexadecimal number (xx:xx:xx:xx:xx:xx)

BSSID of the Access point.In STA mode, upon this configuration the module will associate if both SSID and BSSID matches. Where as, if BSSID is not provided, module will try matching the SSID.In Limited AP mode, this shall be the same as the modules MAC address.In Ad-hoc mode, it is the BSSID of the network element to which the module will join (or it is the BSSIC of the network creator).

Channel Optional

Depends on the value of AT+WREGDOMAIN (see Regulatory Domain, page 45)

In STA mode, the module will search for required SSID in that particular channel only. However, if the channel is not specified it will scan all configured networks, starting from channel number 1 to maximum allowed channels, and associate them to the first network which matches the SSID or BSSID if provided.In Limited AP mode, the module will create an access point in that particular channel. However, if the channel is not provided the module will create an access point in the channel number 1.In Ad-hoc mode, the module will create ad-hoc network in the specified channel. However if not specified it will create an Ad-hoc network in channel number 1.

RSSI Flag Not Supported N/A Reserved for future use.WPS Registrar Not Supported N/A Reserved for future use.

Unscheduled automatic power save delivery (UAPSD) configuration

Not Supported N/A Reserved for future use.

80613ST10964A Rev. 5.0 64 2019-10-24

Page 65: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+WA=TelitDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

7.2.5 DisassociationThis command is used to disassociate the current infrastructure / ad-hoc network or stop the limited AP created by the node. It is also used to disconnect P2P mode.

Command Syntax AT+WD

Synchronous Response

Table 58, page 65 describes the synchronous responses and remarks for the Disassociation command.

Asynchronous Response

Table 59, page 65 describes the asynchronous responses and remarks for the Disassociation command.

Example AT+WDOK

Table 57 Associate with Network or Create an Ad Hoc or AP Network Synchronous Responses

Responses RemarksIP SubNet Gateway IPaddress: SubNetaddress: Gateway address SuccessERROR:INVALID INPUT If parameters are not valid.

ERRORReissue the AT+LOGLVL command to get more details about the kind of error. Response changes based on LOGLVL.

ERROR:IP CONFIG FAIL If DHCP fails in infrastructure mode.

Table 58 Disassociation Synchronous Responses

Responses RemarksOK Success

Table 59 Disassociation Asynchronous Responses

Responses RemarksDisassociation Event AP resets or connection to the AP is lost.

80613ST10964A Rev. 5.0 65 2019-10-24

Page 66: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

7.2.6 Advanced Commands

7.2.6.1 Get Client InformationThis command is used to get information about the clients associated to the module when it acts as a limited AP.

Command Syntax AT+APCLIENTINFO=?

Synchronous Response

Table 60, page 66 describes the synchronous responses and remarks for the Get Clients Information command.

Example 1 AT+APCLIENTINFO=?No.OfStationsConnected=1

No MacAddr IP1 60:67:20:3f:10:30 192.168.44.12OK

Example 2 - Client assigned with the IP statically

AT+APCLIENTINFO=?No.OfStationsConnected=1NO MacAddr IP1 60:67:20:3f:10:e0 ****OK

Table 60 Get Clients Information Synchronous Responses

Responses Remarks

No. of Stations Connected=<NoOfClients><MacAddr> IP <no> OK

SuccessLimited AP mode:MAC address and the IP of each of the client associated to the Limited AP. The IP address will be the one assigned to the client using DHCP.

No.Of Stations Connected=0OK

No clients are connected.

ERROR If mode is not set (AT+WM) to limited AP before issuing this command.

NOTE: In case the Telit node has not issued the IP to the client, (client did not request for IP/client assigned with the IP statically), “****” is displayed.

80613ST10964A Rev. 5.0 66 2019-10-24

Page 67: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

7.3 Concurrent Mode (STA Plus AP)Concurrent Mode provides the ability to run Telit node both as STA as well as Limited-AP using Time Division method on a single radio.

In this mode, the Telit node will function as Limited-AP for 80% of beacon time and as STA for remaining 20% of beacon time. It has the ability to switch between the two without loss of context. The application views it as two interfaces available at the same time.The potential to switch rapidly in the hardware allows this to be done efficiently using a single radio.

In concurrent mode, the application creates two interfaces one for STA and another for Limited-AP. Interface 0 must be initialized for STA interface and interface 1 must be for Limited-AP

NOTE: 1.) Presently mDNS is the exclusive Multicast protocol that works in concurrent mode, as Multicast ping is not supported in concurrent mode. 2.) Use AT+WEBSERVER command to stop a webserver as it is not stopped after disassociation or after issuing AT+WD on any interface command. 3) The concurrent mode STA is recommended to operate in power save mode. 4) In concurrent mode, AT+NCLOSEALL command closes all the CIDs on the current operating interface (selected via NIF=0 or NIF=1). To close CIDs of the other concurrent mode interface, it is required to switch to specific interface and use this AT command. 5) When concurrent mode is enabled using AT+NIFCMODE command and concurrent mode is again enabled multiple times using the same command, the response displayed in TeraTerm VT is “OK” though it is only enabled the first time. 6) It is recommended that the users building a binary that supports PS Poll feature (using SDK Builder) do not enable Concurrent mode and WFD binary at the same time. This is done to avoid increase in boot time due to larger binary size which results in beacon miss.

80613ST10964A Rev. 5.0 67 2019-10-24

Page 68: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

7.3.1 Enable/Disable Concurrent ModeThis command is used to enable/disable concurrent mode and to specify the percentage of time spent in each mode.

Command Syntax AT+NIFCMODE=<mode type>[,<%time in STA interface>,<Enable STA reliability mode>]

Parameter Description

Table 61, page 68 describes the Enable/Disable Concurrent Mode parameters.

Table 61 Enable/Disable Concurrent Mode Parameters

Parameter Optional/Mandatory Value Description

mode type Mandatory

0, 10: Disable1: EnableDefault value: 0

Enables or disables Concurrent mode.

% time in STA interfaceOptional

120% - Station20%, 30% are configurable values.Default value: 20%

When concurrent mode is enabled, Telit node will operate as STA for 20% or 30% of Beacon time.

Enable STA reliability mode Optional

0, 10 - Disable1 - EnableDefault value: 0

Enables STA interface reliability mode.This parameter is enabled to improve the data transfer reliability in STA interface. This feature is useful in crowded environments and when STA is connected to an AP that delays sending data. Note:This parameter should be used in combination with following features to improve receive performance in Concurrent STA:• Disable UAPSD for STA interface.

(See AT+WA command in Association, page 62)

• Set Concurrent AP DTIM (DTIM period in LAP mode parameter) to 1 (See AT+WM command in Operation Mode, page 46)

80613ST10964A Rev. 5.0 68 2019-10-24

Page 69: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 62, page 69 describes the synchronous responses and remarks for Enable/Disable Concurrent Mode command.

7.3.2 Set the Interface NumberThis command is used to set the interface. All the commands which follow this command (till the next invocation of this command) are assumed to be for the set interface.

Command Syntax AT+NIF=<Interface Number 0/1 or ?>

Parameter Description

Table 63, page 70 describes the Set Interface Number parameters.

NOTE: 1.) In concurrent mode, Limited-AP mode supports 16 stations, open and WPA2-AES security. 2.) In general limited AP mode supports,16 stations & all claimed security as per release notes. 3.) It is recommended to keep the Beacon Interval of the AP Interface as 100ms. 4.) Issue AT+APCONF=0 for station interface in NCM concurrent mode, when the STA interface is brought up through NCM after the AP interface. 5.) It is recommended to use different port numbers for L4/TCP server sockets in concurrent mode.

Table 62 Enable/Disable Concurrent Mode Synchronous Responses

Responses RemarksOK SuccessERROR Failure

ERROR:INVALID INPUTIf parameters values are not valid.(Other than 0 and 1)

NOTE: Interface 0 must be initialized first with STA

80613ST10964A Rev. 5.0 69 2019-10-24

Page 70: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 64, page 70 describes the synchronous responses and remarks for Set Interface Number command.

Example AT+NIF=<Interface number>\r\nOK\r\n

Table 63 Set Interface Number Parameters

Parameter Optional/Mandatory Value Description

Interface Number Mandatory 0 (default), 1 &?

If interface number is specified.0 - Client interface (default)1 - AP interface? - Queries which interface is in use.

Table 64 Set Interface Number Synchronous Responses

Responses RemarksOK SuccessERROR Failure

ERROR:INVALID INPUTIf parameters are not valid.(Other than 0 and 1)

0 or 1 Returns the active interface number.

80613ST10964A Rev. 5.0 70 2019-10-24

Page 71: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

7.3.3 Indicating InterfaceASYNC messages in concurrent mode are followed by an interface number. This is only valid for messages which do not contain CID.

Command Note This message is only sent in case AT+NIFCMODE=1. When concurrent mode is started the escape sequence is:

<ESC><R>:<IF NO>:<len>:<data> Else <ESC><R>:<len>:<data>Disassociation Event <Interface Number>

Example AT+WA=CM_STA_SSIDIP SubNet Gateway192.168.0.100:255.255.225.0:192.168.0.1OkDissassociation Event 0

80613ST10964A Rev. 5.0 71 2019-10-24

Page 72: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

7.3.4 Example Usage of Concurrent Mode

Example 1 The items below outline an example use case for concurrent mode. Interface 0 is the normal client and Interface 1 is the Limited AP.

• Enable Concurrent ModeAT+NIFCMODE=1

• Configuring Client InterfaceAT+NIF=0AT+WM=0AT+NDHCP=1AT+WA=...AT+mDNS=...

• Configuring the AP InterfaceAT+NIF=1AT+WM=2AT+NSET=.....AT+DHCPSRVR=1,...AT+WA=...

• Start the web server and advertise the services for the APAT+WEBSER=...AT+mDNS=....

• Switch to ClientAT+NIF=0

• Start a client connection to the server (connectivity through the infrastructure)AT+NCTCP=...

• Send data to the server<Esc Z><CID><Len><Data......>

• Received data from the server<Esc Z><CID><Len><Data......>

• Disconnect from APDisconection Indication <Interface Number>\r\n

• Smart Phone Connected to AP and sending data through <Esc N>1\r\n<Esc K)....

80613ST10964A Rev. 5.0 72 2019-10-24

Page 73: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example 2 The following is an example for NCM in concurrent Mode.

SerialIP2WiFiAPP

AT+NIFCMODE=1,20

OK

AT+NIF=0OK

AT+WM=0OK

AT+WRXACTIVE=0OK

AT+WRXPS=1OK

AT+NDHCP=1OK

AT+WWPA=123456789OK

AT+WAUTO=0,GainSpan,,1OK

AT+NCMAUTO=0,1,0OK

IP SubNet Gateway192.168.71.93:255.255.225.0:192.168.71.1NWCONN-SUCCESSAT&w0OK

AT+NIF=1OK

AT+WM=2OK

AT=APCONF=1OK

AT+NAUTO=1,1,,8001OK

80613ST10964A Rev. 5.0 73 2019-10-24

Page 74: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AT+NSET=192.168.58.1,255.255.255.0,192.168.58.1OK

AT+WAUTO=2,NCM_AP,,1OK

AT+NCMAUTO=1,1,1OK

IP SubNet Gateway192.168.58.1:255.255.225.0:192.168.58.1NWCONN-SUCCESSAT&w0OK

80613ST10964A Rev. 5.0 74 2019-10-24

Page 75: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

8 Network

This chapter describes commands for configurations and operations related to Network layer.s

• DHCP Client, page 75

• DHCP Server, page 77

• DHCP Server Configuration, page 79

• DNS Server, page 80

• DNS Address, page 81

• IP Address, page 81

8.1 DHCP ClientThis command is used to enable or disable DHCP client support for IPv4 network.

Command Syntax AT+NDHCP=n[,<hostname>,<radio mode>,<lease period>,<retry interval>]

Parameter Description

Table 65, page 75 describes the DHCP Client parameters.

Synchronous Response

Table 65 DHCP Client Parameters

Parameter Optional/Mandatory Value Description

n Mandatory0 (default) Disable1 Enable

hostname Optional

Value: String of 1 to 15 charactersDefault value: Telit<Last 6 digits of MAC ID>

hostname is a string with a maximum character length of 15. This will be displayed by Access Points as the hostname in the DHCP Clients table.

radio mode Not Supported N/A Reserved for future use.lease period Not Supported N/A Reserved for future use.retry interval Not Supported N/A Reserved for future use.

80613ST10964A Rev. 5.0 75 2019-10-24

Page 76: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 66, page 76 describes the synchronous responses and remarks for the DHCP Client command.

Asynchronous Response

Table 67, page 76 describes the asynchronous responses and remarks for the DHCP Client command.

Example 1 - If the node is not associated when the command is received

AT+NDHCP=1OK

Example 2 - If the node is associated when the command is received

AT+WA=TelitDemoIP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1

Table 66 DHCP Client Synchronous Responses

Responses Remarks

OKSuccessIf the Telit node is not associated when the command is received, future associations will attempt to employ DHCP.

IP SubNet Gateway<IPaddress> <SubNet address> <Gateway address>

SuccessIf the interface is associated with a network, enabling DHCP will cause an attempt to obtain an IP address using DHCP from that network. Therefore issuing this command with n=1 will cause the Telit node to attempt to refresh an existing DHCP address.

IP CONFIG FAIL

If the DHCP renewal failed then the Telit node closes all the sockets opened and sends an error message ERROR: IP CONFIG FAIL to the serial interface. The host can re-issue the network configuration command to redo the DHCP procedure again.

Table 67 DHCP Client Asynchronous Responses

Responses Remarks815ERROR: IP CONFIG FAILWhere:Subtype - 8Length - 15 (ASCII equivalent decimal is 21 characters, i.e., length of the actual message).Actual message - ERROR: IP CONFIG FAILThe type of message. Length is 1 byte. For asynchronous message, it is 0x41 (ASCII value A).

IP configuration has failed. This message comes asynchronously when there is a DHCP renew fails.For asynchronous message format.

Note: <ESC> and Type is not displayed because its Tera Term issue.

80613ST10964A Rev. 5.0 76 2019-10-24

Page 77: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

OK

AT+NDHCP=1IP SubNet Gateway192.168.44.145:255.255.255.0:192.168.44.1OK

8.2 DHCP ServerThis command is used to start/stop the DHCP server. Prior to starting the server, the Telit node should be configured with a valid static IP address (using commands described in DNS Address, page 81, both Device IPv4 address and Gateway IPv4 address should be same) and created or configure to create a limited AP network.

This DHCP server can support maximum 32 client connections with server IP as the statically configured IP address and client IP address starts from the next IP address of the configured static IP address.

Command Syntax AT+DHCPSRVR=<Start/Stop DHCPv4 Server>[,<Enable/Disable DNS IP Advertising>,<Enable/Disable Gateway IP Advertising><CR>]

Parameter Description

Table 68, page 77 describes the DHCP Server parameters.

Synchronous Response

Table 69, page 78 describes the synchronous responses and remarks for the DHCP Server command.

Table 68 DHCP Server Parameters

Parameter Optional/Mandatory Value Description

Start/Stop DHCPv4 Server Mandatory

0 Stops the DHCPv4 server (Not Supported)1 Starts the DHCPv4 ServerNote: 1.) Returns ERROR (failure), if the server is already started and start is issued.2.) Returns ERROR (failure), if server is already stopped and stop is issued.

Enable/Disable DNS IP advertising Not Supported N/A Reserved for future use.

Enable/Disable Gateway IP advertising Not Supported N/A Reserved for future use

80613ST10964A Rev. 5.0 77 2019-10-24

Page 78: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

EventSuccessFailure ge 77

Failure

Example 1 Starting the DHCP sever with defualt settingsAT+WM=2OkAT+NSET=192.168.8.1,255.255.255.0,192.168.8.1OkAT+DHCPSRVRCFG=192.168.8.2.64OKAT+DHCPSRVR=1OK

AT+WA=DHCPSRVR-test, ,6Ok

Example 2 Starting DHCP server with DNS and gateway advertising disabledAT+WM=2OkAT+NSET=192.168.8.1,255.255.255.0,192.168.8.1OkAT+DHCPSRVRCFG=192.168.8.2.64OKAT+DHCPSRVR=1,1,1OK

AT+WA=DHCPSRVR-test, ,6Ok

Table 69 DHCP Server Synchronous Responses

s Verbose Mode Non Verbose Mode Remarks<CR><LF>OK<CR><LF> <CR><LF>0<CR><LF> Parameters are valid<CR><LF>ERROR<CR><LF><CR><LF>1<CR><LF> Refer Start/Stop DHCPv4 Server note Table 68, pa<CR><LF>ERROR<SP>INVALID<SP>INPUT<CR><LF> <CR><LF>2<CR><LF> Parameters are valid.

80613ST10964A Rev. 5.0 78 2019-10-24

Page 79: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Su

Fa

8.3 DHCP Server Configuration

This command is used to configure the DHCP server. It should be issued prior to the DHCP server start command.

Command Syntax AT+DHCPSRVRCFG=<DHCP-Client’s Starting IP address>,<Max DHCP-Client’s supported><CR>

Parameter Description

Table 70, page 79 describes the DHCP Server Configuration parameters.

Synchronous Response

Table 71, page 79 describes the synchronous responses and remarks for the DHCP Server Configuration command.

Example Configuring the starting address and restrict DHCP pool to 10 clients.

AT+DHCPSRVRCFG=192.168.8.2,10

OK

Table 70 DHCP Server Configuration Parameters

Parameter Optional/Mandatory Value Description

DHCP-Client’s starting IP address Mandatory N/A

The first IP address assigned by the DHCP server when the client requests an IP. Format should be: xxx.xxx.xxx.xxx

max DHCP-client’s supported Mandatory

1 to 64(64-default value)

The number of clients supported by the DHCP server.

NOTE: 1.) If this command is not issued, the DHCP-client starting IP address is the subsequent device IP address configured through AT+NSET. 2.) LAP only supports 16 STA when secured through WPA/2-PSK security.

Table 71 DHCP Server Configuration Synchronous Responses

Events Verbose Mode Non Verbose Mode Remarksccess <CR><LF>OK<CR><LF> <CR><LF>0<CR><LF> Parameters are valid.

ilure <CR><LF>ERROR:<SP>INVALID<SP>INPUT<CR><LF> <CR><LF>2<CR><LF> Parameters are invalid

80613ST10964A Rev. 5.0 79 2019-10-24

Page 80: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

8.4 DNS ServerThis command is used start/stop the DNS server. Prior to start the server, the DHCP server should be started and created or configure to create a limited AP network. This DNS server use the same DHCP server IP address as its IP address (see mDNS Module Initialization, page 177).

Command Syntax AT+DNS=<Start/stop><url>

Table 72, page 80 describes the DNS Server parameters.

Synchronous Response

Table 73, page 80 describes the synchronous responses and remarks for the DNS Server command.

Example Use Case - Configure the node as a limited AP, start the DNS server

Serial2WiFiAPPAT+NSET=192.168.7.1,255.255.255.0,192.168.7.1OK

AT+DHCPSRVR=1OK

AT+WM=2OK

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.7.1:255.255.255.0:192.168.7.1OK

AT+DNS=1

Table 72 DNS Server Parameters

Parameter Optional/Mandatory Value Description

Start/Stop Mandatory0 Stops the server1 Starts the server

url Not Supported N/A Reserved for future use.

Table 73 DNS Server Synchronous Responses

Responses Remarks

OK

SuccessThe node is statically configured with IP address, and configured to create a limited AP. The client IP address starts from the next IP address of the configured IP address.

ERROR:INVALID INPUTIf the parameters are not valid.(other than 0/1)

80613ST10964A Rev. 5.0 80 2019-10-24

Page 81: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

OK

AT+WEBPROV=admin,adminOK

8.5 DNS AddressThis command is used to set the IP address of the DNS server to be used by the node. The second DNS2 IP is optional but should not be the same as DNS1 IP address.

Command Syntax AT+DNSSET=<DNS1 IP>,[<DNS2 IP>]

Command Note This command must be issued before associating to a network. This static configuration of DNS set will take effect only in the case of static IP address on the Telit node.

Parameter Description

Table 74, page 81 describes the Static Configuration of DNS (Client) parameters.

Synchronous Response

Table 75, page 81 describes the synchronous responses and remarks for the Static Configuration of DNS (Client) command.

8.6 IP AddressThis command is used to set network parameters statically. Upon deployment of this command, any previously specified network parameters are overridden, and the node is

Table 74 Static Configuration of DNS (Client) Parameters

Parameter Optional/Mandatory Value DescriptionDNS1 IP Mandatory N/A DNS1 IP is the IP address of the DNS server.

DNS2 IP Optional N/A DNS2 IP should not be the same as DNS1 IP address.

Table 75 Static Configuration of DNS (Client) Synchronous Responses

Responses Remarks

OKSuccessTo take effect, this command should be given before associating to the network.

ERRORFailureIf the parameters are not valid.

80613ST10964A Rev. 5.0 81 2019-10-24

Page 82: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

SucceSucce

Failur

configured to use the newly specified network parameters for the current association, if associated, and for any future association. The use of DHCP is disabled if the network parameters are configured statically. The DNS address can be set using AT+DNSSET (see DNS Address, page 81).

Command Syntax AT+NSET=<Device IPv4 Address>,<IPv4 Subnet Mask>,<Gateway IPv4 Address><CR>

Parameter Description

Table 76, page 82 describes the Static Configuration of Network Parameters.

Synchronous Response

Table 77, page 82 describes the synchronous responses and remarks for the Static Configuration of Network Parameters command.

Example Use Case 1 - If the node is not associated when the command is received

AT+NSET=192.168.44.12,255.255.255.0,192.168.44.12OKAT+WA=GainSpanIP SubNet Gateway192.168.44.12:255.255.255.0:192.168.44.12OK

Example Use Case 2 - If the node is associated when the command is received

AT+WA=TelitDemoIP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

Table 76 Static Configuration of Network Parameters

Parameter Optional/Mandatory Value Description

device IPv4 Address Mandatory 192.168.1.99 (default value)

IP address of the source in the form xxx.xxx.xxx.xxx

IPv4 Subnet Mask Mandatory 255.255.255.0 (default value) Net mask is in the form of xxx.xxx.xxx.xxx

Gateway IPv4 Address Mandatory 192.168.1.1 (default value)

Gateway of the address (node: Src Adr and Gateway should be same in the case of Limited AP or P2P mode)

Note: IPv4 address is represented in dot decimal notation each of the four decimal numbers range from 0 to 255.

Table 77 Static Configuration of Network Parameters Synchronous Responses

Events Verbose Mode Non Verbose Mode Remarksss in unassociated state <CR><LF>OK<CR><LF> <CR><LF>0<CR><LF> VALID Parameterss in associated state <CR><LF>OK<CR><LF> <CR><LF>0<CR><LF> Command not to be used

e <CR><LF>ERROR<SP><INVALID><SP>INPUT<CR><LF> <CR><LF>2<CR><LF> INVALID Parameter

80613ST10964A Rev. 5.0 82 2019-10-24

Page 83: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AT+NSET=192.168.44.12,255.255.255.0,192.168.44.12IP SubNet Gateway192.168.44.12:255.255.255.0:192.168.44.12

NOTE: 1.) This command is recommended to be issued before creating the limited AP or before associating STA to the network. 2.) AT+NDHCP = 0 command is issued before configuring the network parameters for both limited AP and STA.

80613ST10964A Rev. 5.0 83 2019-10-24

Page 84: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9 Data Transfer

This chapter describes commands for configurations and operations related to Transport and Application layers.

• Data Transfer Configuration, page 84

• Security Configuration, page 94

• Network Connection Management (NCM), page 107

• HTTP, page 119

• Auto Mode, page 134

• UDP/TCP, page 138

• GSLink, page 157

9.1 Data Transfer Configuration

9.1.1 Data Transfer in Bulk ModeThis command is used to enable or disable the bulk mode data transfer.

Command Syntax AT+BDATA=n

Parameter Description

Table 78, page 84 describes the Enable/Disable Bulk Mode Data Transfer parameters.

Table 78 Enable/Disable Bulk Mode Data Transfer Parameters

Parameter Optional/Mandatory Value Description

n MandatoryValue range: 0, 1Default value: 0

It specifies whether data transfer in bulk mode is enabled or not.• 0: Disable data transfer in bulk mode• 1: Enable data transfer in bulk mode

80613ST10964A Rev. 5.0 84 2019-10-24

Page 85: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.1.2 Connection StatusThis command is used to return the current CID configuration for all existing CIDs.

Command Syntax AT+CID=?

Usage This command returns the current CID configuration for all existing CIDs:

1. CID number (in decimal format)

2. CID type

3. Mode

4. Local port

5. Remote port

6. Remote IP address

Synchronous Response

Table 79, page 85 describes the synchronous responses and remarks for the Output Connections command.

Example

AT+CID=?

CID TYPE MODE LOCAL PORT REMOTE PORT REMOTE IP0 UDP SERVER 1009 0 0.0.0.01 UDP CLIENT 46445 9001 192.168.23.1005 TCP CLIENT 62771 9007 192.168.23.1006 TCP SERVER 4000 0 0.0.0.03 TCP-SSL CLIENT 44499 443 192.168.2.73OK

Table 79 Output Connections Synchronous Responses

Responses Remarks<CID> <TYPE> <MODE> <LOCALPORT> <REMOTE PORT> <REMOTE IP>OK

If valid CIDs are present

No valid CIDs If no valid CIDs are present.

80613ST10964A Rev. 5.0 85 2019-10-24

Page 86: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.1.3 Closing a ConnectionThis command is used to close the connection associated with the specified CID, if it is currently open. On completion of this command the CID is free for use in future connections.

Command Syntax AT+NCLOSE=<CID>

Parameter Description

Table 80, page 86 describes the Closing a Connection parameters.

Synchronous Response

Table 81, page 86 describes the synchronous responses and remarks for Closing a Connection command.

Example Use Case WL865E4-P node is configured with the TCP client connection and closed the connection using “nclose.”

AT+NDHCP=1OK

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.23.101:255.255.255.0,192.168.23.1OK

AT+NCUDP=192.168.23.100,8005CONNECT 8OK

AT+NCLOSE=8OK

Table 80 Closing a Connection Parameters

Parameter Optional/Mandatory Value DescriptionCID Mandatory 16 (maximum) CID is the allocated connection identifier.

Table 81 Closing a Connection Synchronous Responses

Responses Remarks

OK Connection with the given CID is closed, and this CID can be used for future connection.

INVALID CID If any invalid CID is provided.

80613ST10964A Rev. 5.0 86 2019-10-24

Page 87: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.1.4 Closing All ConnectionsThis command is used to close all open connections.

Command Syntax AT+NCLOSEALL

Synchronous Response

Table 82, page 87 describes the synchronous responses and remarks for Closing All Connections command.

Example AT+NCLOSEALLOK

NOTE: In concurrent mode, AT+NCLOSEALL command closes all the CIDs on the current operating interface (selected via NIF=0 or NIF=1). To close CIDs of the other concurrent mode interface, it is required to switch to specific interface and use this AT command.

Table 82 Closing All Connections Synchronous Responses

Responses RemarksOK All open connections are closed.

80613ST10964A Rev. 5.0 87 2019-10-24

Page 88: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

C

T

T

P

9.1.5 Socket Options ConfigurationThis command is used to configure a socket which is identified by a CID.

Command Syntax AT+NXSETSOCKOPT=<CID>,<Type>,<Parameter>,<Value>,<Length>,<IP_DSCP(25)>

Parameter Description

Table 83, page 88 describes the Socket Options Configuration parameters.

Table 83 Socket Options Configuration Parameters

Parameter Optional/Mandatory Value Type/Name Description

ID Mandatory16 (maximum) connection identifiers are allowed.

N/ACID is the socket identifier received after opening a connection.

ype Mandatory

1 SOL_SOCKET It specifies the category type for Socket.

2 IPPROTO_IP It specifies the category type for IP

3 IP_PROTOTCP It specifies the category type for TCP.

ype Mandatory65535 Socket N/A1 IP N/A6 TCP N/A

arameter Mandatory

10 TCP_MAXRT

It specifies the maximumretransmission timeout. When this parameter is set, Maximum Retransmission Timeout is calculated for the giventimeout.

4001 TCP_KEEPALIVE

It allows to enable or disable sending keep alivepackets after the predefined time.

8 SO_KEEPALIVE

It allows to enable or disable sending keep alivepackets after the predefined time.

4005 TCP_KEEPALIVE_CNT

It allows to set the maximum number of keepalive probes without any response from the remotebefore TCP gives up and aborts the connection.

80613ST10964A Rev. 5.0 88 2019-10-24

Page 89: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

P

N•••

arameter Mandatory

29 TCP_MAXRT It specifies the maximumretransmission timeout inseconds.

9 TCP_KEEPALIVE

It allows to enable or disable sending keep alivepackets after the predefined time of 30 seconds.

2A TCP_MAX_REXMITIt specifies the maximumnumber of retransmissioncount.

2B TCP_REX_TIMER_RATE

It is used to set the retransmission timer rate.

8 SO_RCVBUFIt sets the receive buffer size for TCP packets. Themaximum limit is 64KB.

2Emax queue depth:20(default)

TCP_MAX_TX_Q_DEPTH

It specifies the TCP transmission queue depthin terms of number of packets.

Note: 1.) It gives max no of packets queued until ACK is received.2.)For bidirectional data transfer 6-7 packets is set to avoid all the packets queued on the transmission path and due to the non availability of packets thereception packets are dropped.3.)For single socket only transmission is done.

2F TCP_REX_TIMER_RATE_IN_NW_TICKS

It specifies the transmission rate in termsof network ticks.

25 IP_DSCP

It specifies the type of field under the IP header DSCP (Differentiated Service Code Point)

ote: The following NXSETSOCKOPTs are not supported in network stack.SO_SENDBUFSO_RESUSEPORTEnabling or disabling Nagle algorithm. It is disabled by default in the network stack.

Table 83 Socket Options Configuration Parameters (Continued)

Parameter Optional/Mandatory Value Type/Name Description

80613ST10964A Rev. 5.0 89 2019-10-24

Page 90: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

V

V

.

L

I

alue Mandatory N/A N/A

• For retransmission timeout, the value is time to be set in terms of seconds.

• For retransmission count,the value is a number.

• For Keepalive, the value to be set is 0 or 1. 1 is to enable Keepalive and 0 isto disable Keepalive.

• For buffer, the value is thesize of the buffer to be setin bytes.

alue Mandatory

• Default value for retransmission timeout - 75 seconds

• Default value for retransmission count - 12

• Default value for retransmission timer rate - 1 second

• Default value for Keepalive - 0 (disable)

Note: When Keepalive is enabled, the default value for Keepalive timeout is 30 seconds.• Default value for buffer

size is 8k bytes

N/A

• For retransmission timeout, the value is time to be set in terms of seconds.

• For retransmission count,the value is a number. Once the number of retransmissions for a packet reaches this value,the socket is automatically closed by the network stack.

• For retransmission timer rate, the value is time to be set in terms of seconds

• For Keepalive, the value to be set is 0 or 1. 1 is to enable Keepalive and 0 isto disable Keepalive.

• For buffer, the value is thesize of buffer to be set in bytes.

ength Mandatory N/A N/A

It specifies the length of the value in bytes.4 - Integer2 - Short1 - Char

P_DSCP(25) Not Supported N/A N/A Reserved for future use.

Table 83 Socket Options Configuration Parameters (Continued)

Parameter Optional/Mandatory Value Type/Name Description

80613ST10964A Rev. 5.0 90 2019-10-24

Page 91: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 84, page 91 describes the synchronous responses and remarks for Socket Options Configuration command.

Example Use Case 1 Set the TCP retransmission timeout to 20 seconds.

AT+SETSOCKOPT=0,6,29,20,4

Where:

CID - 0

Type - 6 (TCP)

Parameter - 29 (TCP_MAXRT)

Value - 20

Length - 4 bytes (Integer)

Example Use Case 2 Enabling TCP_KEEPALIVE option at TCP level with timeout as 600 seconds.

AT+SETSOCKOPT=9,6,4001,600,4

Where:

CID - 0

Type - 6 (TCP)

Parameter - 4001 (TCP_KEEPALIVE)

Value - 600

Length - 4 bytes (Integer)

Example Use Case 3 Enable SO_KEEPALIVE option at base socket level. Without enabling this TCP_KEEPALIVE will not work.

AT+SETSOCKOPT=0,65535,8,1,4

Where:

Table 84 Socket Options Configuration Synchronous Responses

Responses RemarksOK SuccessERROR: SOCKET FAILURE 0 If parameters are not valid.

NOTE: ‘TCP Keep alive’ value is kept as 2 hours (7200 seconds) by default as per the RFC-1122. The lowest value that is allowed to be configured externally is 10 minutes (600 seconds).

80613ST10964A Rev. 5.0 91 2019-10-24

Page 92: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

CID - 0

Type - 65535 (Socket)

Parameter - 8 (SO_KEEPALIVE)

Value - 1

Length - 4 bytes (Integer)

Command Note The default keepalive count is 8 so the minimum keepalive timeout is 8*75=600 seconds. To reduce the keepalive timeout further, set the keepalive count first to an appropriate value and set the keepalive timeout.

Example Use Case 1 Enable TCP_KEEPALIVE

Telit node and TCP server running on a Host are both connected to an Access Point. Open a TCP client on Telit node and check whether the TCP connection between the client and server is idle. If connection is idle, then TCP client (Telit node) sends TCP_KEEPALIVE packets every 30 seconds which is the default Keepalive timeout.

To enable TCP_KEEPALIVE, use the following command:

AT+NXSETSOCKOPT=1,1,9,0,4

Where:

CID - 1

Type - 1 (SOL_SOCKET)

Parameter - 9 (TCP_KEEPALIVE)

Value - 1 (TCP_KEEPALIVE is enabled)

Length - 4 bytes (Integer)

Example Use Case 2 Set the maximum TCP retransmission time (TCP_MAXRT) to 100 seconds.

The maximum retransmission time is set to 25 seconds by default in Serial-to-Wireless application with a retransmission interval of 2 seconds.

To configure the retransmission time to 100 seconds, use the following command:

AT+NXSETSOCKOPT=1,3,29,100,4

Where:

CID - 1

Type - 3 (IP_PROTOTCP)

Parameter - 29 (TCP_MAXRT)

NOTE: TCP_KEEPALIVE timeout can only be enabled or disabled, with a timeout of 30 seconds.

80613ST10964A Rev. 5.0 92 2019-10-24

Page 93: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Value - 100 (TCP_MAXRT is set to 100 seconds)

Length - 4 bytes (Integer)

Example Use Case 3 Set the maximum TCP retransmission count (TCP_MAX_REXMIT) to 40.

The maximum retransmission count is set to 12 by default in Serial-to-Wireless application with a retransmission interval of 2 seconds.

To configure the retransmission count to 40, use the following command:

AT+NXSETSOCKOPT=1,3,2A,40,4

Where:

CID - 1

Type - 3 (IP_PROTOTCP)

Parameter - 2A (TCP_MAX_REXMIT)

Value - 40 (TCP_MAX_REXMIT is set to 40)

Length - 4 bytes (Integer)

Example Use Case 4 Set the retransmission timer rate (TCP_REX_TIMER_RATE) to 1 second.

To configure the retransmission timer rate to 1 second, use the following command:

AT+NXSETSOCKOPT=1,3,2B,1,4

Where:

CID - 1

Type - 3 (IP_PROTOTCP)

Parameter - 2B (TCP_REX_TIMER_RATE)

Value - 1 (TCP_REX_TIMER_RATE is set to 1 second)

Length - 4 bytes (Integer)

Example Use Case 5 Set the receive buffer size (SO_RCVBUF) to 4k.

To configure the buffer size to 4k, use the following command:

AT+NXSETSOCKOPT=0,1,8,4096,4

Where:

CID - 0

Type - 1 (SOL_SOCKET)

Parameter - 8 (SO_RCVBUF)

Value - 4096 (SO_RCVBUF is set to 4k)

Length - 4 bytes (Integer)

80613ST10964A Rev. 5.0 93 2019-10-24

Page 94: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example Use Case 6 Setting the priority of the data as voice for the connection identifier.

AT+NXSETSOCKOPT=0,2,25,224,4

Setting the priority of the data as video for the connection identifier.

AT+NXSETSOCKOPT=0,2,25,160,4

Where:

CID - 0

Type - 2 (IPPROTO_IP)

Parameter - 25 (IP_DSCP)

Length - 4 bytes (Integer)

9.2 Security Configuration

9.2.1 Certificate AdditionThis command is used to add the certificate for SSL/HTTPS and EAP connections that allows only one copy of the certificate either in Flash/RAM. Its is used for any SSL based connection except EAP.

Command Syntax AT+TCERTADD=<Name>,<Format>,<Size>,<Location><CR>

After receiving OK, execute the following Escape sequence and perform the remaining steps in Tera Term as mentioned below:

<ESC>W<certificate of the above size>

From the Tera Term VT, perform the following:

1. Select File > Send file

2. Select the check box Binary under Option

3. Open the folder which contains the certificates

4. Wait for the response as OK. Returns OK when the size is equal to the size mentioned in the command and does not Returns OK if the uploading certificate file size is less then the size mentioned in the command. when the size of the file is greater than the size mentioned in the command- returns OK and the additional bytes will be echoed back to the host.

Parameter Description

NOTE: 1).It is mandatory not to insert any space before the “CertificateName” as the command would fail. 2).The command is used for loading SSL certificate and is not used for loading EAP.

80613ST10964A Rev. 5.0 94 2019-10-24

Page 95: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 85, page 95 describes the Certificate Addition parameters.Table 85 Certificate Addition Parameters

Parameter Optional/Mandatory Value Description

Name Mandatory

Name of a certificate should be prefixed with SSL_.Note: Certificates are also uploaded or deleted over the air through the interface provided in sslcert.html. The naming convention mentioned above shall apply there as well.

This parameter specifies the name of the certificate to be added.The reserved EAP certificates are:• TLS_CA - Certificate of the CA

from where the radius server got certified from.

• TLS_CLIENT - Client certificate also know as public key of the Telit device.

• TLS_KEY - Private key for the Telit device.

Note: ‘Do not name a certificate as SSL_CA’, ‘SSL_SERVER’ or ‘SSL_KEY’ as they are reserved for HTTPS server certificates (root certificate is used to validate the clients, server certificate and server key respectively).

Format Mandatory0: DER format1: PEM format

It specifies the format of the certificate to be added.• DER Format: Supports all certificates

and PKCS8 unencrypted keys.• PEM Format: Supports all certificates

and PKCS1, PKCS8 unencrypted keys and EC keys.

Size Mandatory N/A

Note: Size of the certificate to be added.When a certificate of x size has to be stored, WL865E4-P module adds a header with 32 bytes of certificate name + 2 bytes of file length along with the certificate. Total certificate file size = Certificate size of x bytes + Header of 34 bytes Example: If certificate size is 2020, then WL865E4-P module adds a header of 34 bytes.Total certificate file size = 2054Therefore, the certificate file occupies two blocks of 2KB.

Location MandatoryLocation to store the certificates0 Flash1 RAM

Note: There is a carriage return after the <Location> parameter.

80613ST10964A Rev. 5.0 95 2019-10-24

Page 96: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 86, page 96 describes the synchronous responses and remarks for the Certificate Addition command.

Example Name:CAFormat:0(Binary)Size:868 bytesLocation:0(Flash)AT+SETTIME=30/07/2015,15:00:00OK

AT+NDHCP=1OK

AT+WA=TelitDemoIP SubNet Gateway192.168.44.148:255.255.255.0:192.168.44.1OKAT+TCERTADD=ca,0,868,0OK

<ESC>W

From the Tera Term VT, perform the following:

1. Select File > Send file

2. Select the check box Binary under Option

3. Open the folder which contains the certificate ca which is of 868 bytes.

OK

Example when the verbose mode is disabled adding certificate using AT+TCERADDATV00AT+TCERTADD=SSL_CA,0,654,10

OK

Table 86 Certificate Addition Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT Invalid parameters

80613ST10964A Rev. 5.0 96 2019-10-24

Page 97: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.2.2 Certificate DeletionThis command is used to delete the SSL/HTTPS/EAP-TLS certificate that is stored in Flash/RAM.

Command Syntax AT+TCERTDEL=<certificate name>

Parameter Description

Table 87, page 97 describes the Certificate Deletion parameters.

Synchronous Response

Table 88, page 97 describes the synchronous responses and remarks for the Certificate Deletion command.

Example 1 AT+TCERTDEL=TLS_CAOK

NOTE: when verbose mode is disabled and adding certificate using AT+ TCERTADD command, the second response after loading the certificate (ESC+W) will be OK.

Table 87 Certificate Deletion Parameters

Parameter Optional/Mandatory Value Description

certificate name Mandatory N/A

Name of the certificate to delete from Flash/RAM. In case of EAP-TLS certificate names are:

• TLS_CA - Certificate of the CA from where the radius server got certified from.

• TLS_CLIENT - Client certificate also know as public key of the Telit device.

• TLS_KEY - Private key for the Telit device.

Table 88 Certificate Deletion Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT Invalid parameterERROR Could not delete as the file does not exist.

80613ST10964A Rev. 5.0 97 2019-10-24

Page 98: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.2.3 EAP-ConfigurationThis command is used to load EAP certificates (only for Enterprise Security).

Command Syntax AT+WEAPCONF=<Outer Authentication>,<Inner Authentication>,<user name>,<password>[,<Common name and organizational unit>,<Enable/Disable Anonymous ID>, <Enable/Disable PRF 1.2>,<Use CA Certificate>]

The command syntax changes based on the outer or inner authentication parameter.

Parameter Description

Table 89, page 98 describes the EAP Configuration parameters.

Table 89 EAP Configuration Parameters

Parameter Optional/Mandatory Value Description

Outer Authentication Mandatory

The valid outer authentication values are:43 EAP-FAST (not supported)13 EAP-TLS21 EAP-TTLS25 EAP-PEAP

255Enables common name and organizational unit verification in incoming server certificate. (not supported)

254 Enables anonymous ID in EAP response identity. (not supported)

Note: The combination for Outer and Inner authentication parameters is provided in Table 90, page 99.

Inner Authentication Mandatory

The valid inner authentication values are:26 EAP-MSCHAP6 EAP-GTC (not supported)253 EAP-PAP (not supported)Note: The combination for Outer and Inner authentication parameters is provided in Table 90, page 99.

user name

MandatoryNote: This parameter is not applicable for EAP-TLS.

N/A The user name is an ASCII string with a maximum length of 32 ASCII characters.

password

MandatoryNote: This parameter is not applicable for EAP-TLS.

N/A The password is an ASCII string with a maximum length of 32 ASCII characters.

80613ST10964A Rev. 5.0 98 2019-10-24

Page 99: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

The following table lists the combination of Outer and Inner authentication parameters.

Synchronous Response

Table 91, page 100 describes the synchronous responses and remarks for the EAP-Configuration command.

Common name andOrganizational Unit

Not Supported values of incoming certificate

This parameter provides the common name and organizational unit passed as a string before EAP association. This is later verified with the incoming server certificate.

Enable/Disable Anonymous ID Not Supported

0- Disable (default)1- Enable

This parameter specifies whether Anonymous ID is part of EAP response identity or not.• 0- Disable anonymous ID in EAP response

identity• 1- Enable anonymous ID in EAP response

identity

Enable/Disable PRF 1.2. Not Supported

0- Disable (default)1- Enable

PRF is the pseudo random function with version 1.2 that is enabled or disabled while associating with EAP.This parameter specifies whether PRF 1.2 is part of EAP response identity or not.• 0- Disable PRF 1.2 in EAP response identity• 1- Enable PRF 1.2 in EAP response identity

Note: To enable PRF with version 1.2 during EAP configuration, issue command “AT+WEAPCONF=253,1”.If the version of the PRF is less then the version1.2, issue command “AT+WEAPCONF=253.1” to enable it.

Use CA Certificate Not Supported0- Disable (default)1- Enable

This parameter specifies whether the CA certificate loaded in GS node is used to validate the incoming Server certificate.• 0 - Do not use CA certificate• 1 - Use CA certificate

Table 89 EAP Configuration Parameters

Parameter Optional/Mandatory Value Description

Table 90 Combination of Outer and Inner Authentication

Outer Authentication Inner Authentication Combination of Outer and Inner

AuthenticationEAP-TTLS EAP-MSCHAP EAP-TTLS-MSCHAPEAP-PEAP V0 EAP-MSCHAP EAP-PEAP V0-MSCHAP

80613ST10964A Rev. 5.0 99 2019-10-24

Page 100: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example 1- PEAP without certificates

AT+WEAPCONF = 25,26,gsn,GainSpanDemo123OK

AT+WA=GainSpanDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

AT+NDHCP=1IP SubNet Gateway192.168.23.103:255.255.255.0:192.168.23.1OK

9.2.4 EAP Certificate UploadThis command is used to enable the Telit node to receive the EAP certificates used for various authentication like EAP -TLS, EAP-PEAP, and so on.

Command Syntax AT+WEAP=<Type>,<Format>,<Size>,<Location><CR><ESC>W <data of size above>

Parameter Description

Table 92, page 100 describes the EAP Certificate Upload parameters.

Table 91 EAP-Configuration Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT Invalid parameters

Table 92 EAP Certificate Upload Parameters

Parameter Optional/Mandatory Value Description

Type Mandatory

Type of the certificate

0 Certification of CA where the radius server is certified from.

1 Client certification also known as public keys of Telit device.

2 Private key of the Telit device.

Format MandatoryFormat of the certificate0 DER format (Binary)1 PEM format (Binary)

80613ST10964A Rev. 5.0 100 2019-10-24

Page 101: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 93, page 101 describes the synchronous responses and remarks for the EAP command.

Example - Adding a der formatted CA certificate in flash

Type:0(Client CA)Format:0(Binary)NumberofBytes:3026

AT+WEAP=0,0,3026,0OK<ESC>W<Certificate of 3026bytes>OK

From the Tera Term VT, perform the following:

1. Select File > Send file

2. Select the check box Binary under Option

3. Open the folder which contains the ClientCA certificate

4. Select ClientCA (this has 3026 bytes of data)

Size Mandatory Note: Size of the certificate to be transferred. Size of the certificate in bytes is in the decimal format.

Location Mandatory

Location to store the certificates

0 Flash, stored in file system in WL865E4-P module.

1RAMNote: RAM will be lost when the power is cycled.

Note: There is a carriage return after <location>.

Table 92 EAP Certificate Upload Parameters

Parameter Optional/Mandatory Value Description

Table 93 EAP Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT Invalid parameters

80613ST10964A Rev. 5.0 101 2019-10-24

Page 102: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.2.5 Secured (DTLS/SSL)

9.2.5.1 Configure SSL

This command is used to configure the SSL parameters.

It supports to configure:

• Domain name check and configure the size of SSL buffer in bytes which is used to store the alternate names (domain names) provided in the incoming server certificate.

• Close an existing SSL connection and configure the timeout value to close the SSL connection.

Command Syntax AT+SSLCONF=<Configuration ID>,<Configuration value>

Parameter Description

Table 94, page 102 describes the SSL configuration parameters.

Table 94 Configuring SSL Parameters

Parameter Optional/Mandatory Value Description

Configuration ID Mandatory

Value Range: 1 to 9Format: Decimal.

1: Domain name check, when this parameter is set to 1, Telit module performs the domain name check. (Not Supported)2:SSL close timeout check, when this parameter is set to 2, Telit module supports to close an existing SSL connection after a timeout (Not Supported)3: Enables signature algorithm extension (Not Supported)4: Enables max fragment length extension (Not Supported)5: Disable SSL re- negotiation extension (Not Supported)6: Sets TLS version.7: Enables ECC ciphers (Not Supported)8: Enables SNI extension (Not Supported)9: Selective display of any ciphers.

80613ST10964A Rev. 5.0 102 2019-10-24

Page 103: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 95, page 104 describes the synchronous responses and remarks for Closing SSL Connection command.

Configuration value MandatoryValue Range: N/AFormat: N/A

When Configuration ID is 1: Buffer size in bytes(50-2000) is specified to store the alternate names (domain names) provided in the incoming server certificate. Note: Maximum buffer size can be more than 2000 bytes

since this depends on the memory availability inTelit Node. Timeout value is 1 to 60 seconds

When Configuration ID is 2: This is the Timeout value in seconds required to close an existing SSL connectionWhen Configuration ID is 3,the configuration value is:0 - to disables signature algorithm extension1 - to enables signature algorithm extensionWhen Configuration ID is 4,the configuration value is:0 - to disables max fragment length extension1 - to enables max fragment length extensionWhen Configuration ID is 5,the configuration value is:0 - to enable SSL De-negotiation extension1 - to disable SSL De- negotiation extensionWhen Configuration ID is 6, the configuration value is:0 - set version to TLS is 1.01 - set version to TLS is 1.12 - set version to TLS is 1.2The default version is 1.2When Configuration ID is 7, the configuration value is:0 - to disables ECC ciphers (not supported)1 - to enables ECC ciphers (not supported)When Configuration ID is 8, the configuration value is the “server name” string added to SSL extension.When Configuration ID is 9, the configuration value is 32bit cipher, where each bit takes binary value of either 0 or 1. Note: Configuration ID’s 1,2,3,4,5,7,8, are currently not

supported.

Table 94 Configuring SSL Parameters (Continued)

Parameter Optional/Mandatory Value Description

80613ST10964A Rev. 5.0 103 2019-10-24

Page 104: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example 1 Enabling domain name check in SSL client and to allocate 100 Bytes for storing domain names.

AT+SSLCONF=1,100

Example 2 Configuring SSL client terminate connection, if the SSL server is not responding for more than 20 seconds.

AT+SSLCONF=2,20

Example 3 Configure SSL Client to send Signature Algorithm Extensions in Client Hello Frame.AT+SSLCONF=3,1

Example 4 Configure SSL Client to send maximum supported fragment Length extension in Client Hello Frame.

AT+SSLCONF=4,1

Example 6 Configure SSL client to for disabling SSL re-negotiation.AT+SSLCONF=5,1

Example 7 Configure SSL client use only TLS1.0 VersionAT+SSLCONF=6,0

Example 8 Configure SSL client use only TLS1.1 Version or lessAT+SSLCONF=6,1

Example 9 Configure SSL client use only TLS1.2 Version or lessAT+SSLCONF=6,2

Example 10 Configure SSL client to support elliptic-curve Diffie–Hellman and Elliptic Curve Digital Signature Algorithm.

AT+SSLCONF=7,1

Example 11 Configure SSL Client to set Server Name Indication (SNI) as “client5.google.com”.AT+SSLCONF=8,client5.google.com

Example 12 Configure SSL Client to selectively display the cipher suite.AT+SSLCONF=7,1 /*Enable the Cipher suiteAT+SSLCONF=9,7f8 /*Selectively displays the ECC Cipher

from (3 to 10)AT+SSLCONF=9,E0 /* Selective display of ECC cipher-6,7 and 8AT+SSLCONF=9,2AA /*Selective display if alternate ECC cipher

Table 95 Configuring SSL Synchronous Responses

Responses RemarksOK SuccessERROR: INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 104 2019-10-24

Page 105: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.2.5.2 Open SSL

This command is used to open an SSL connection over the TCP connection identified by a CID. For SSL connection, Telit node uses the certificate stored in memory that is identified by a certificate name. Prior to issuing this command, a valid TCP connection identified by CID needs to exist.

Client certificate name and client key name are required for SSL client authentication.

Command Syntax AT+SSLOPEN=<CID>,[<certificate name>, <client certificate name>,<client key name>]

Parameter Description

Table 96, page 105 describes the SSL Connection Open parameters.

Synchronous Response

Table 97, page 106 describes the synchronous responses and remarks for SSL Connection Open command.

NOTE: a> ECC ciphers is included only if the AT command to enable ECC is issued(AT+SSLCONF=7,1). b> If AT command AT+SSLCONF=7,1 is issued without a specified bitmap, then all the supporting ECC ciphers with bit position (7-10)gets added by default. c> If AT command AT+SSLCONF=7,1 is not issued, then SSL will not include any of the ECC ciphers irrespective of whether the bitmap contains any ECC cipher or not.

NOTE: a> Certificates and Key must be in PEM format. b> If the size of Server key is more than 2k, then Telit node as SSL Client will not connect to the SSL Server.

Table 96 SSL Connection Open Parameters

Parameter Optional/Mandatory Value Description

CID Mandatory

Value range: 0 to FFormat: Hexadecimal

It specifies the socket identifier allocated to a socket on Telit node.

certificate name Optional N/A Name of the SSL certificate.client certificate name Optional N/A Name of the SSL client certificate.client key name Optional N/A Name of the SSL client key.

80613ST10964A Rev. 5.0 105 2019-10-24

Page 106: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+NDHCP=1OKAT+WA=TelitDemo,,11IP SubNet Gateway192.168.23.101:255.255.255.0:192.168.23.1OKAT+SETTIME=11/30/2013,11:03:00OKAT+NCTCP=192.168.2.73,443CONNECT 0OKAT+SSLOPEN=0OK

9.2.5.3 Close SSL

This command is used to close the existing SSL connection over the TCP connection identified by CID.

Command Syntax AT+SSLCLOSE=<CID>

Parameter Description

Table 98, page 106 describes the Closing SSL Connection parameters.

Synchronous Response

Table 99, page 107 describes the synchronous responses and remarks for Closing SSL Connection command.

Table 97 SSL Connection Open Synchronous Responses

Responses RemarksOK Success

Table 98 Closing SSL Connection Parameters

Parameter Optional/Mandatory Value Description

CID Mandatory

Value range: 0 to FFormat: Hexadecimal

It specifies the socket identifier allocated to a socket on Telit node.

80613ST10964A Rev. 5.0 106 2019-10-24

Page 107: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+NDHCP=1OK

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.23.101:255.255.255.0:192.168.23.1OK

AT+SETTIME=11/30/2013,11:03:00OK

AT+NCTCP=192.168.2.73,443CONNECT 0OK

AT+SSLOPEN=0OK

AT+SSLCLOSE=0OK

9.3 Network Connection Management (NCM)The Telit node supports network connection manager which manages WLAN (L2), IP/Network (L3), and Transport layer (L4) level connections. The parameters for L2, L3 and L4 layers can be configured using commands specified in HTTP(S) Server, page 130 and Network Parameters, page 136. The security parameters can be configured using the commands specified in HTTP, page 119.

9.3.1 NCM Start/StopThis command is used to start/stop the network connection manager.

Table 99 Closing SSL Connection Synchronous Responses

Responses RemarksOK Success

ERROR: INVALID CID Displays error message for invalid connection identifier.

NOTE: SSL renegotiation is not supported after SSL restore.

80613ST10964A Rev. 5.0 107 2019-10-24

Page 108: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Command Syntax AT+NCMAUTO=<Mode>,<Start/Stop>[,Level],[<Nvds store flag>]

Usage If the NCM Start/Stop is stored in persistent storage, then the Telit node will take the appropriate action for successive boots.

This command starts the NCM by connecting to the AP (if the mode configured as station) or create a limited AP (if the mode configured as limited AP) with the pre-configured parameters. Once it connects to any of the L2, L3, and L4, disconnection triggers the NCM and it starts do the L2, L3, and L4 re-connection.

Once the connection is established the Telit node returns the following message to the serial interface.

For L2+L3:IP address“NWCONN-SUCCESS”For L2+L3+L4:IP address “NWCONN-SUCCESS”“CONNECT <cid>”

For limited AP, the first two parameters are only valid and it outputs the same message for L2+L3 to the serial interface.

Parameter Description

Table 100, page 108 describes the NCM Start/Stop parameters.

NOTE: When a node is configured or started using NCM, use AT+NCMAUTO=0,0,0 to stop the NCM or dis associate from the current network.

NOTE: If the DHCP renewal success with a new IP address then the Telit node closes the sockets that are open (L4) and sends a message “IP CONFIG-NEW IP” with the new IP information to the serial interface and it retains the L4 connection if the NCM is started with L4 support.

Table 100 NCM Start/Stop Parameters

Parameter Optional/Mandatory Value Description

Mode Mandatory0 For station mode1 For limited AP mode

Start/Stop Mandatory0 For stop the NCM1 For start the NCM

80613ST10964A Rev. 5.0 108 2019-10-24

Page 109: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 101, page 109 describes the synchronous responses and remarks for NCM Start/Stop command.

Example 1 To stop NCM, when AT+NCMAUTO=0,0,0 is issued, Serial to Wireless responds OK for Synchronous. Proceed with executing AT+NCMAUTO=? to get the NCM status. NCM is stopped only if the NCM state is “NCM NOT STARTED”.

AT+APCONF=1

OK

AT+WM=2

OK

AT+NSET=192.168.51.1,255.255.255.0,192.168.51.1

OK

AT+WAUTO=2,GS_LAP,,11

OK

AT+NCMAUTO=1,1,0

OK

IP SubNet Gateway

192.168.51.1:255.255.255.0:192.168.51.1

Level Mandatory0 For L2+L3 connection

1 For L2+L3+L4 connection (Not Supported)

NVDS Store Flag Not Supported N/A Reserved for future use

Table 100 NCM Start/Stop Parameters (Continued)

Parameter Optional/Mandatory Value Description

Table 101 NCM Start/Stop Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 109 2019-10-24

Page 110: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

NWCONN-SUCCESS

AT+NCMAUTO=0,0,0

OK

AT+NCMAUTO=?

NCM NOT STARTED //*This NCM state ensures that NCM is stopped.*//

OK

AT+NCMAUTO=0,0,0

ERROR //*ERROR indicates that NCM is not initialized.*//

NOTE: When NCM stop command is issued, make sure that the NCM state is NCM NOT STARTED and proceed with further operations.

80613ST10964A Rev. 5.0 110 2019-10-24

Page 111: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.3.2 Configure NCMThis command is used to configure the NCM parameters for its state machine. This is the ID corresponding to the NCM configuration parameters. The L4 configuration parameters (L4 retry count and period) can be configured using ATS6/7 command.

Command Syntax AT+NCMAUTOCONF=<Conf Id>,<Value>

Parameter Description

Table 102, page 111 describes the NCM Configuration parameters.

Table 102 NCM Configuration Parameters Parameter Optional/Mandatory Conf Id Value Description

Conf Id, Value

Not Supported 0 1 to 65535 (default is 1000 milliseconds)

CPU Wait Period (1 to 6)not supported

Not Supported 1 1 to 65535 (default 1000 milliseconds) Power Save Periods (not supported)

Not Supported 2 1 to 65535 (default 1000 milliseconds)

Know Channel Scan Period (not supported)

Not Supported 3 1 to 65535 (default 1000 milliseconds)

Specific Channels Scan Period (not supported)

Mandatory 4 1 to 65535 (default 1000 milliseconds) All Channel Scan period

Not Supported 5 1 to 65535 (default 1000 milliseconds)

Layer 3 Connect PeriodThis specifies the Serial-to-Wireless level delay between each connection request.When a connection does not go through for a connection request, the network stack retries as per the configuration.

Not Supported 6

Can be configured using the command ATS 6/7.

NCM Layer 4 Retry Period This specifies the Serial-to-Wireless level delay between each connection request.When a connection does not go through for a connection request, the network stack retries as per the configuration.

Not Supported 7

NCM Layer 4 Retry Count This specifies the Serial-to-Wireless level retry count.When a connection does not go through for a connection request, the network stack retries as per the configuration.

80613ST10964A Rev. 5.0 111 2019-10-24

Page 112: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Conf Id, Value Not Supported 8 1 to 65535 (default 10)

Known channel scan retry count (not supported)

Conf Id, Value Not Supported 9 1 to 65535 (default 10)

Specific channels scan retry count (not supported)

Conf Id, Value Mandatory 10 1 to 65535 (default 10) All Channel scan retry count

Conf Id, Value Mandatory 11 1 to 65535 (default 100)

Layer 3 Connect retry count.This specifies the Serial to Wireless level retry count.When a connection does not go through for a connection request, the network stack retries as per the configuration.

Conf Id, Value Optional 120, 1 (default 0)0 - enable1 - disable

It specifies whether to broadcast SSID in beacon frames or not.

Conf Id, Value Optional 13 1 to 65535 (default 3)It specifies the DTIM period in AP mode.

Conf Id, Value Optional 14 1 to 65535 (default 3600)

It specifies the time-out interval when there is no activity from the connected nodes.

Conf Id, Value Not Supported 25

Radio mode 1,2,31 - Active mode2 - PS poll mode (default)3 - IEEE PS poll mode

It specifies the radio mode during DHCP process (not supported).

Conf Id, Value Mandatory 26 0xffffffff (default)It specifies the lease period to be requested in DHCP discover message in seconds.

Conf Id, Value Mandatory 27 2 seconds default It specifies the time interval between successive DHCP retries.

Table 102 NCM Configuration Parameters (Continued)Parameter Optional/Mandatory Conf Id Value Description

80613ST10964A Rev. 5.0 112 2019-10-24

Page 113: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 103, page 113 describes the synchronous responses and remarks for NCM Configuration command.

Example AT+NCMAUTOCONF=26,0xFFFFFFFFERROR: INVALID INPUT

AT+NCMAUTOCONF=26,10OK

9.3.3 NCM Status GetThis command is used to get the status or the profile information of network connection manager.

Command Syntax AT+NCMAUTO=?/??

Parameter Description

Conf Id, Value Not Supported 28

0, 10 - Disable power optimized scan (default)1 - Enable power optimized scan

It specifies whether power optimized scan is enabled or not based on the following configuration values:• 1: When this parameter is set to 1,

power optimized scan is enabled and Telit node associates with AP of the first found SSID or BSSID. SSIDs or BSSIDs are configured using AT+WAUTO command.

• 0: When this parameter is set to 0, power optimized scan is disabled and Telit node associates with AP that has best RSSI in the corresponding regulatory domain.

(not supported)

Table 102 NCM Configuration Parameters (Continued)Parameter Optional/Mandatory Conf Id Value Description

NOTE: The L4 configuration parameters (L4 retry count and period) can be configured using ATS6/7 command.

Table 103 NCM Configuration Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 113 2019-10-24

Page 114: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 104, page 114 describes the NCM Status Get parameters.

Table 105, page 114 lists the NCM State and their values.

Example AT+NCMAUTO=0,0,0,0OKAT+NCMAUTO=? //NCM NOT STARTED

AT+NCMAUTO=?NCM STARTED:6 //NCM is scanning some specific channel

Table 104 NCM Status Get Parameters

Parameter Optional/Mandatory Value Description

? Mandatory N/A This parameter is used to get the status of network connection manager

?? Optional N/AThis parameter is used to get the profile information of network connection manager

Table 105 NCM State Description

NCM State DescriptionFollowing NCM state occurs when NCM is not initialized in the module.NCM NOT STARTED NCM is not initializedFollowing NCM states occur when NCM is initialized in the module.NCM STARTED:0 NCM is not initializedNCM STARTED:1 NCM is initialized and ready

NCM STARTED:2NCM has initiated L2 disconnect with WLAN and waits for indication to disconnect from WLAN. NCM initiates disconnect when Sync Loss is detected

NCM STARTED:3

NCM has disconnected L2. This occurs:• At start• When NCM triggers disassociation and WLAN confirms it• When WLAN indicates disassociation

NCM STARTED:4 Scanning known AP with previously scanned MAC frame

NCM STARTED:5 Scanning known channelNCM STARTED:6 Scanning specific channelsNCM STARTED:7 Scanning All channelsNCM STARTED:8 L2 connected and L3 is not connected yetNCM STARTED:9 Both L2 and L3 are connectedNCM STARTED:10 NCM is waiting or in idle state

80613ST10964A Rev. 5.0 114 2019-10-24

Page 115: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AT+NCMAUTO=?NCM STARTED:9 // L2 and L3 both are success

80613ST10964A Rev. 5.0 115 2019-10-24

Page 116: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.3.4 Enable NCM AP Configuration This command is used to enable the NCM AP configuration. These commands are used for both station and limited AP mode. To distinguish the parameters for limited AP mode, the Telit node provides a command.

Command Syntax AT+APCONF=<n>

Parameter Description

Table 106, page 116 describes the NCM AP Configuration Enable parameters.

By default, the adapter use parameters stored at the factory default section (see Select Default Profile, page 39) to start the limited AP with NCMAUTO command.

If the adapter does not find the factory default (see Select Default Profile, page 39) with a valid parameter it uses the following values described below.

Table 107, page 116 describes the Telit node value settings.

Table 106 NCM AP Configuration Enable Parameters

Parameter Optional/Mandatory Value Description

n MandatoryValue range: 0, 1Default value: 0

It specifies whether NCM AP configuration is enabled or not.0: For Station mode1: For Limited-AP mode

Table 107 Telit node Value Settings for NCM AP Configuration Enable

Parameter DescriptionSSID GainSpanProvChannel 1Security 0 (open)WEP Key 1234567890WEP Key Index 1WEP Key Length 5WPA Passphrase TelitDemo123Beacon Interval 100DHCP Server Enable TRUE (1)DNS Server Enable TRUE (1)IP Address 192.168.240.1Subnet Mask 255.255.255.0Gateway 192.168.240.1DHCP Start IP Address 192.168.240.2

80613ST10964A Rev. 5.0 116 2019-10-24

Page 117: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 108, page 117 describes the synchronous responses and remarks for NCM AP Configuration Enable command.

Example AT+APCONF=1

9.3.4.1 Examples for NCM Commands

This section provides examples for NCM in Limited-AP and STA modes.

Example for Limited-AP Mode

AT+APCONF=1OK

AT+WM=2OK

AT+WAUTO=2,GainSpan,,1OK

AT+NSET=192.168.51.1,255.255.255.0:192.168.51.1OK

AT+NCMAUTO=1,1,0OK

IP SubNet Gateway192.168.51.1:255.255.225.0:192.168.51.1NWCONN-SUCCESS

AT&w0OK

AT+RESET=1APP Reset-APP SW Reset

DNS Name config.gainspanUser Name adminPwd admin

Table 107 Telit node Value Settings for NCM AP Configuration Enable (Continued)

Parameter Description

Table 108 NCM AP Configuration Enable Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameters are not valid.(Other than 0 and 1)

80613ST10964A Rev. 5.0 117 2019-10-24

Page 118: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

IP SubNet Gateway192.168.51.1:255.255.255.0:192.168.51.1NWCONN-SUCCESS

Example for STA Mode

AT+WAUTO=0,GainSpanOK

AT+NAUTO=0,1,192.168.67.54,9000OK

AT+NCMAUTO=0,1,1OK

IP SubNet Gateway192.168.67.53:255.255.225.0:192.168.67.1NWCONN-SUCCESS

CONNECT 0AT&W0OK

80613ST10964A Rev. 5.0 118 2019-10-24

Page 119: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.4 HTTP

9.4.1 HTTP(S) Client

9.4.1.1 Configure HTTP Client

This command is used to configure the HTTP parameters.

Command Syntax AT+HTTPCONF=<Param name>,<Param Value>

Parameter Description

Table 109, page 119 describes the HTTP client configuration parameters.

Table 109 HTTP Client Configuration Parameters

Parameter Optional/Mandatory Description

Param name Mandatory

Param name is the HTTP header.Custom header starts from 255 onwards and any standard header should start before this.The HTTP header is one of the following.HTTP_HEADER_AUTHORIZATION (2)HTTP_HEADER_CONNECTION (3)HTTP_HEADER_CONTENT_ENCODING (4)HTTP_HEADER_CONTENT_LENGTH (5)HTTP_HEADER_CONTENT_RANGE (6)HTTP_HEADER_CONTENT_TYPE (7)HTTP_HEADER_DATE (8)HTTP_HEADER_EXPIRES (9)HTTP_HEADER_FROM (10)HTTP_HEADER_HOST (11)HTTP_HEADER_IF_MODIFIED_SINCE (12)HTTP_HEADER_LAST_MODIFIED (13)HTTP_HEADER_LOCATION (14)HTTP_HEADER_PRAGMA (15)HTTP_HEADER_RANGE (16)HTTP_HEADRER_REFERER (17)

80613ST10964A Rev. 5.0 119 2019-10-24

Page 120: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 110, page 120 describes the synchronous responses and remarks for HTTP Client Configuration command.

Example 1 The WL865E4-P node (HTTP client) is configured with HTTP header parameters and the HTTP connection is opened with the HTTP server.

Param name Mandatory

HTTP_HEADER_SERVER (18)HTTP_HEADER_TRANSFER_ENCODING (19)HTTP_HEADER_USER_AGENT (20)HTTP_HEADER_WWW_AUTHENTICATE (21)HTTP_REQUEST_URL (23)HTTP_CFG_PARAM_CLOSE_TIMEOUT(27)HTTP_CFG_PARAM_HEADER_COOKIE(247)HTTP_CFG_PARAM_HEADER_COOKIE2(248)HTTP_CFG_PARAM_HEADER_SET_COOKIE(249)Note: 1.)Customer header starts from 255. Note: 2) The maximum total HTTP headers that Telit node can process is limited

to 1024Bytes.Note: 3) Setting of HTTP_HEADER_HOST (11) should match the

host name provided during http open command.Note: 4) Setting of HTTP_HEADER_CONF(5) must match the data length pro-

vided during http post request.Note: 5) The header HTTP_HEADER_CONNECTION (3) is set to “keep-alive”

by default. Setting of this header is ignored. Note: 6) The header HTTP_HEADER_CONTENT_LENGTH(5) is not support-

ed.

Param Value Mandatory It is the string that depends on the above parameter.When param is 11 (HTTP_HEADER_HOST), then the value string will be 192.168.2.73 (Host address)When param is 27 (HTTPC_CFG_PARAM_CLOSE_TIMEOUT), then the value specifies a timeout value to close an existing HTTP connection. Value range: 1-60 secondsMinimum value: 10 milliseconds

Table 109 HTTP Client Configuration Parameters (Continued)

Parameter Optional/Mandatory Description

Table 110 HTTP Client Configuration Synchronous Responses

Responses Remarks

OKSuccessSuccessful HTTP connection

ERROR: INVALID INPUTFailureIf parameters are not valid.

80613ST10964A Rev. 5.0 120 2019-10-24

Page 121: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

where some of the HTTP headers are configured. The HTTP headers configured are: HTTP_HEADER_CONNECTION (3)HTTP_HEADER_EXPIRES (11)HTTP_HEADER_USER_AGENT (20)Customer Header (258)

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.23.101:255.255.255.0:192.168.23.1OK

AT+HTTPCONF=3,KEEP-ALIVEOK

AT+HTTPCONF=11,192.168.2.73OK

AT+HTTPCONF=23,192.168.2.73:443OK

AT+HTTPCONF=2,Basic dGVzzdDp0ZXN0MTIz=test:test123OK

AT+HTTPCONF=255,SSID:TelitDemoOK

AT+HTTPCONF=256,Temperature:28OK

AT+HTTPCONF=257,Light:35OK

AT+HTTPCONF=258,Voltage:3.3OK

AT+HTTPOPEN=192.168.2.73,800OK

Example 2 To configure HTTP close timeout, execute the following command:

AT+HTTPCONF=27,100

Where,27: S2W_HTTPC_CFG_PARAM_CLOSE_TIMEOUT(27)100: Timeout value for HTTP close

On successful execution, OK is displayed.

Example 3 To configure HTTP close timeout, execute the following command:

80613ST10964A Rev. 5.0 121 2019-10-24

Page 122: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AT+HTTPCONF=27,0ERROR:INVALID INPUT

An error is displayed as zero is an invalid input value for timeout. The minimum timeout value supported is 10 milliseconds.

Example 4 To configure HTTP range header, execute the following command:

AT+HTTPCONF=16,Bytes=0-100OK

This command displays files up to the specified bytes.

9.4.1.2 Clear HTTP Client Configuration

This command is used to remove an HTTP client configuration.

Command Syntax AT+HTTPCONFDEL=<Param>

Parameter Description

Table 111, page 123 describes the HTTP Client Configuration Removal parameters.

80613ST10964A Rev. 5.0 122 2019-10-24

Page 123: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 112, page 123 describes the synchronous responses and remarks for HTTP Client Configuration Removal command.

Table 111 HTTP Client Configuration Removal Parameters

Parameter Optional/Mandatory Description

Param Mandatory Telit node removes the HTTP configuration specified by the param. param is the HTTP header and is one of the following.

HTTP_HEADER_AUTHORIZATION (2)HTTP_HEADER_CONNECTION (3)HTTP_HEADER_CONTENT_ENCODING (4)HTTP_HEADER_CONTENT_LENGTH (5)HTTP_HEADER_CONTENT_RANGE (6)HTTP_HEADER_CONTENT_TYPE (7)HTTP_HEADER_DATE (8)HTTP_HEADER_EXPIRES (9)HTTP_HEADER_FROM (10)HTTP_HEADER_HOST (11)HTTP_HEADER_IF_MODIFIED_SINCE (12)HTTP_HEADER_LAST_MODIFIED (13)HTTP_HEADER_LOCATION (14)HTTP_HEADER_PRAGMA (15)HTTP_HEADER_RANGE (16)HTTP_HEADER_REFERER (17)HTTP_HEADER_SERVER (18)HTTP_HEADER_TRANSFER_ENCODING (19)HTTP_HEADER_USER_AGENT (20)HTTP_HEADER_WWW_AUTHENTICATE (21)HTTP_REQUEST_URL (23)HTTP_CFG_PARAM_CLOSE_TIMEOUT(27)HTTP_CFG_PARAM_HEADER_COOKIE(247)HTTP_CFG_PARAM_HEADER_COOKIE2(248)HTTP_CFG_PARAM_HEADER_SET_COOKIE(249)

Table 112 HTTP Client Configuration Removal Synchronous Responses

Responses RemarksOK Success

ERROR Trying to delete a header parameter which is not configured.

ERROR: INVALID INPUT Invalid parameter

80613ST10964A Rev. 5.0 123 2019-10-24

Page 124: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.4.1.3 Open HTTP Client Connection

This command is used to open an HTTP client connection on the Telit node to the server specified by the host name or IP address.

Command Syntax AT+HTTPOPEN=<hostname/IP address>[,<Port Number>,<SSLFlag>,<CertificateName>,<Proxy>,<Connection Timeout>,<ClientCertificateName>,<ClientKeyName>]

Parameter Description

Table 113, page 124 describes the HTTP Client Connection Open parameters.

NOTE: It is mandatory not to insert any space before the “CertificateName” as the command would fail.

Table 113 HTTP Client Connection Open Parameters

Parameter Optional/Mandatory Value Description

Hostname/IP address Mandatory N/A

The host is either the Fully Qualified Domain name (FQDN) of the server or the IP address of the server to which the HTTP client will open the connection (e.g., www.telit.com or 74.208.130.221)

Port Number Optional N/A

Port number of the server to which the HTTP client will open the connection. The client can specify the port when the server is running on a non-standard port. Default is the standard port - 80 for HTTP and 443 for HTTPs.

SSLFlag Optional0 (default) SSL Disabled1 SSL Enabled

CertificateName Optional N/A

The name of the CA Certificate to be used for Server Certificate Authentication in case SSL is enabled. The CA Certificate must be provisioned before this.It uses the certificate configuration on the Telit node identified by the certificate name.

Proxy Optional N/AThis flag is used only during HTTPS connection through proxy 1 - The HTTPS connection is through proxy server.

ConnectionTimeout Not Supported N/A Reserved for future use.

80613ST10964A Rev. 5.0 124 2019-10-24

Page 125: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 114, page 125 describes the synchronous responses and remarks for HTTP Client Connection Open command.

Example http client connection (validating server against date of validity of server certificate) with serverhaving IP address 192.168.2.73

AT+HTTPOPEN=192.168.2.731OK

9.4.1.4 Configure Receive Response Headers/Status Line

This command configures the reception HTTP response headers and response status line coming from HTTP server.

Command Syntax AT+HTTPRECVCONF=<CID>,<send status line>,<send http response headers>

Parameter Description

Table 115, page 126 describes the Configuration to Receive Response Headers/Request Line parameters.

ClientCertificateName Optional N/AThe client certificate name is required for SSL client authentication and must be provisioned before using this parameter.

ClienKeyName Optional N/AThe client key name is required for SSL client authentication and must be provisioned before using this parameter.

Note: Certificates and Key must be in PEM format (To add certificate to the Telit node use the AT+TCERTADD command (see Certificate Addition, page 94).

Table 113 HTTP Client Connection Open Parameters (Continued)

Parameter Optional/Mandatory Value Description

Table 114 HTTP Client Connection Open Synchronous Responses

Responses Remarks<CID> OK Success

ERROR

FailureIf parameters are not valid or if the command is issued before associating to the network.

80613ST10964A Rev. 5.0 125 2019-10-24

Page 126: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 115 Configuration to Receive Response Headers/Request Line Parameters

Parameter Optional/Mandatory Value Description

CID MandatoryValue range: 0 to FFormat: Hexadecimal

It specifies the socket identifier allocated to a socket on Telit node.

send status line Mandatory

0, 10: Do not receive response status line1: Receive response status lineDefault value:1

When MCU wants to receive response status line, set this parameter to 1

send http response headers Mandatory

Hexadecimal value of the response header’s bit position. Table 116, page 126 lists various response headers.

It specifies the bitmap for registering individual HTTP headers. MCU can register for various headers by setting the specific bit position in this parameter as specified in Table 116, page 126.Example: Configure the parameter to support GSN_HTTP_HEADER_CONNECTION (1) and GSN_HTTP_HEADER_CONTENT_ENCODING (2)• Calculate the binary value of the

response header’s bit position which is 110

• Convert the binary value to hexadecimal value which is 6

The command will be as follows:AT+HTTPRECVCONF=0,1,6

Table 116 Send HTTP Response Headers

Header Name/ValueGSN_HTTP_HEADER_ALLOW(1)GSN_HTTP_HEADER_AUTHORIZATION (2) GSN_HTTP_HEADER_CONNECTION (3) GSN_HTTP_HEADER_CONTENT_ENCODING (4)GSN_HTTP_HEADER_CONTENT_LENGTH (5)GSN_HTTP_HEADER_CONTENT_RANGE (6) GSN_HTTP_HEADER_CONTENT_TYPE (7) GSN_HTTP_HEADER_COOKIE(8)GSN_HTTP_HEADER_COOKIE2(9)

80613ST10964A Rev. 5.0 126 2019-10-24

Page 127: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Note: 1. GSN_HTTP_HEADER_CUSTOM can be used to register for response headers apart from mentioned values. In case multiple custom headers coming in HTTP request, all the custom headers will be passed to the MCU.

Synchronous Response

Table 117, page 127 describes the synchronous responses and remarks for Configuration to Receive Headers/Status Line command.

GSN_HTTP_HEADER_DATE (10) GSN_HTTP_HEADER_EXPIRES (11) GSN_HTTP_HEADER_FROM (12) GSN_HTTP_HEADER_HOST (13) GSN_HTTP_HEADER_IF_MODIFIED_SINCE (14) GSN_HTTP_HEADER_LAST_MODIFIED (15)GSN_HTTP_HEADER_LOCATION (16) GSN_HTTP_HEADER_PRAGMA (17) GSN_HTTP_HEADER_RANGE (18) GSN_HTTP_HEADER_REFERER (19) GSN_HTTP_HEADER_SERVER (20) GSN_HTTP_HEADER_SET_COOKIE(21)GSN_HTTP_HEADER_TRANSFER_ENCODING (22) GSN_HTTP_HEADER_USER_AGENT (23) GSN_HTTP_HEADER_WWW_AUTNENTICATE(24)GSN_HTTP_HEADER_CUSTOM(32)

Table 116 Send HTTP Response Headers (Continued)

Header Name/Value

Table 117 Configuration to Receive Response Headers/Status Line Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUT If parameters are not valid and if Telit Link is not enabled in the binary.

80613ST10964A Rev. 5.0 127 2019-10-24

Page 128: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.4.1.5 Exchange/Send Data with HTTP Client

This command is used to Get/Post HTTP data on the HTTP client. The content can be transferred using the escape sequence mentioned previously.

Command Syntax AT+HTTPSEND=<CID>,<Type>,<Timeout>,<Page>,<Size of data>,[<Send response status line>,<Send response headers count>]

MCU sends data using the following Escape <ESC> sequence:ESC<H><CID><Data of above size>

Parameter Description

Table 118, page 128 describes the HTTP Client Get/Post parameters.

Table 118 HTTP Client Get/Post Parameters

Parameter Optional/Mandatory Value Description

CID MandatoryValue range: 0 to FFormat: Hexadecimal

It specifies the socket identifier allocated to a socket on Telit node.

Type MandatoryValue range: 1 to 7Format: Decimal

GSN_HTTP_METHOD_GET (1)GSN_HTTP_METHOD_HEAD (2)GSN_HTTP_METHOD_POST (3)GSN_HTTP_METHOD_PUT (4)GSN_HTTP_METHOD_DELETE (5)GSN_HTTP_METHOD_GETRESP (6)GSN_HTTP_METHOD_POSTRESP (7) (not supported)

Timeout MandatoryFormat: DecimalUnit: Seconds

Timeout value is in seconds

Page Mandatory Format: String The page/script being accessed (e.g., /index.html)

80613ST10964A Rev. 5.0 128 2019-10-24

Page 129: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

If HTTP connection is opened by enabling SSL encryption, this command encrypts data based on the encrypt key in SSL connection structure (before data is sent through Network layer) for a specific CID. The encrypted data is then sent through the Network layer.

Receive is implicit in AT+HTTPSEND based on HTTPS Server's response to the sent data. Received data is asynchronous and should be handled accordingly.

The response from server is sent to the host in one or more chunks with maximum size of 2048 bytes. Each chunk is of the format:

<ESC>H<1Byte-CID><4 bytes–Length of the data><data>

The data part of first chunk of the response will have the status line at the beginning. The status line contains the status code and the status phrase. This will be in the format:

<status code><space><status phrase>\r\n

After the last chunk, OK/ERROR is sent to the host.

Synchronous Response

Table 119, page 129 describes the synchronous responses and remarks for HTTP Client Get/Post command.

Size of data MandatoryFormat: StringMaximum value: 1460 bytes

Actual content size. Optional in case of GET.Note: It is recommended to use when sending data from

MCU as part for GSN_HTTP_METHOD_GETRESPor GSN_HTTP_METHOD_POSTRESP

Send response status line Optional

Value range: 0, 1Format: Decimal

When MCU wants to send custom response status line, set this parameter to 1.• 0: Do not send custom response status line• 1: Send custom response status line

Send response headers count Optional

Value range: 0 or Number of different custom headers which are required to be sent

When MCU wants to send custom response headers, set this parameter to number of different custom headers which are required to be sent.Set this argument to 0, if no custom headers are to be sent.

Table 118 HTTP Client Get/Post Parameters (Continued)

Parameter Optional/Mandatory Value Description

Table 119 HTTP Client Get/Post Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 129 2019-10-24

Page 130: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.4.1.6 Close HTTP Client

This command is used to close the HTTP client connection identified by the CID.

Command Syntax AT+HTTPCLOSE=<CID>

Parameter Description

Table 120, page 130 describes the Close HTTP client command parameters.

Synchronous Response

Table 121, page 130 describes the synchronous responses and remarks for the Store HTTP client configuration command.

9.4.2 HTTP(S) Server

9.4.2.1 HTTP Server Redirection

This command is used to add the redirection URL on the Telit node.

Command Syntax AT+NURIREDIR=<URL>

Parameter Description

Table 122, page 130 describes the HTTPD Redirection parameters.

Table 120 Close HTTP Client Parameters

Parameter Optional/Mandatory Value Description

CID MandatoryValue range: 0 to FFormat: Hexadecimal

It specifies the socket identifier allocated to a socket on WL865E4-P node.

Table 121 Close HTTP Client Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

Table 122 HTTPD Redirection Parameters

Parameter Optional/Mandatory Value Description

URL Mandatory Max URL length is 64 bytes

URL is the address of the redirection page.

80613ST10964A Rev. 5.0 130 2019-10-24

Page 131: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example - In limited AP mode

AT+WM=2OK

AT+NSET=192.168.12.1,255.255.255.0,192.168.12.1OKAT+WA=GAINSPANDEMO,,6OkAT+DHSCPSRVR=1OKAT+DNS=1

AT+WEBPROV=,,OKAT+NURIREDIR=/tls.htmlOK

80613ST10964A Rev. 5.0 131 2019-10-24

Page 132: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.4.2.2 Start/Stop Web Server

This command is used to start/stop the web server.

Command Syntax AT+WEBSERVER=n,<user name>,<password>,[1=SSL enable/0=SSL disable],[idle timeout],[Response timeout]

Parameter Description

Table 123, page 132 describes the Start/Stop Webserver parameters.

Table 123 Start/Stop Webserver Parameters

Parameter Optional/Mandatory Value Description

n MandatoryValue range: 0,1Default value: 0

It specifies whether webserver is started or stopped.• 0: Stop• 1: Start

user name Mandatory

Any valid string with maximum length of 16 characters.Default value: admin

It specifies the username of the webserver. If default username from the SDK Builder needs to be used, then issue DEFAULT. If username is not provided in the SDK Builder, then use “admin”.If this parameter is left blank, then authentication is disabled.

password Mandatory

Any valid string with maximum length of 16 characters.Default value: admin

It specifies the password for the webserver. If default password from the factory default area needs to be used, then issue DEFAULT. If password is not provided in the factory default area, use “admin”.

SSL Enable/Disable Optional Value range: 0,1

It specifies whether SSL is enabled or not.• 0: Disable• 1: Enable

Idle timeout (seconds) Optional 120 seconds (default)

It specifies the time-frame Telit node waits for HTTP data. If no data is transferred within the idle time, then HTTP connection is removed by the client or Telit node itself.

Response Timeout (milliseconds) Optional

Maximum value - 100000 milliseconds (100 seconds)

Response timeout restricts MCU (host) to respond within a specified time.Note: Response timeout should be less than 120 seconds

80613ST10964A Rev. 5.0 132 2019-10-24

Page 133: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 124, page 133 describes the synchronous responses and remarks for Start/Stop Webserver command.

Example To configure Telit node with idle timeout as 5 seconds and response timeout as 2 seconds, execute the following command:

AT+WEBSERVER=1,admin,admin,0,5,2000OK

9.4.2.3 Web Server Status

This command is used to output the current status (started or stopped) of the web server and displays the registered URIs.

Command Syntax AT+WEBSERVER=?

Synchronous Response

Table 125, page 133 describes the synchronous responses and remarks for the Web server status command.

Table 124 Start/Stop Webserver Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

NOTE: The max timeout that can be configured for HTTP Server is 90seconds since the main task sys qual is set to 90seconds.

Table 125 Webserver Status Synchronous Responses

Responses Remarks<CR><LF>Webserver<SP>Started<SP>URI:/gainspan/profile/mcu<CR><LF>OK<CR><LF>

Success When Web server is started.

<CR><LF>Webserver<SP>Stopped<CR><LF>OK<CR><LF>

Success When Web server is stopped.

<CR><LF>ERROR:<SP>INVALID INPUT<CR><LF>

FailureIf parameter is not valid.

<CR><LF>ERROR<CR><LF> FailureWhen double question mark (??) is issued.

80613ST10964A Rev. 5.0 133 2019-10-24

Page 134: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.5 Auto Mode

9.5.1 Enable Auto ConnectionThis command is used to store configuration settings in non-volatile memory and modify according to the parameter value in the command; the resulting change (if any) takes effect on the next reboot, or the next issuance of an ATA command.

Command Syntax ATCn

Parameter Description

Table 126, page 134 describes the Enable Auto Connection parameters.

Synchronous Response

Table 127, page 134 describes the synchronous responses and remarks for Enable Auto Connection command.

NOTE: Telit node supports 8 connections when established.

Table 126 Enable Auto Connection Parameters

Parameter Optional/Mandatory Value Description

n Mandatory0, 10: Disable1: Enable

n is 0 to disable auto connection or 1 to enable auto connection.

Table 127 Enable Auto Connection Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 134 2019-10-24

Page 135: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.5.2 Wireless ParametersThis command is used to set the auto connection wireless parameters for the current profile. All other parameters required to configure the wireless connection are taken from the current Profile.

Command Syntax AT+WAUTO=<mode>,<SSID>,[<BSSID>],[channel]

Parameter Description

Table 128, page 135 describes the Wireless parameters.

Synchronous Response

Table 129, page 135 describes the synchronous responses and remarks for Wireless Parameters command.

Table 128 Wireless Parameters

Parameter Optional/Mandatory Value Type Description

mode MandatoryValue range: 0, 21

STAAd-hocLimited-AP mode

It specifies if Telit node can be configured as an STA mode or Ad-hoc mode or Limited-AP mode.• 0: STA• 1: Limited-AP

SSID (Service Set Identifier) Mandatory

Any valid SSID (see SSID and Passphrase, page 24) for SSID format)

N/A

It specifies the SSID of the AP or Limited-AP or Ad-hoc Network to connect to.SSID is the unique name given to the network. Telit node (STA) connects to the desired network or creates a network (Limited-AP) using SSID.

BSSID (Basic Service Set Identifier)

Not SupportedAny valid BSSID (17 character of the form xx:xx:xx:xx:xx:xx)

N/AIt specifies the BSSID of the AP or Ad-hoc Network to connect to.

channel Optional 1-14 N/A

It specifies the channel number which is the communication channel or radio channel used to communicate with the peer.

Table 129 Wireless Parameters Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 135 2019-10-24

Page 136: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.5.3 Network ParametersThis command is used to set the network parameters for auto connection operation for the current profile.

Command Syntax AT+NAUTO=<Type>,<Protocol>,<Destination IP/Host name>,<Destination Port>,[Source Port]

Parameter Description

Table 130, page 136 describes the Network parameters.

Table 130 Network Parameters

Parameter Optional/Mandatory Value Description

Type Mandatory Value range: 0, 1

It specifies whether the type is client or server.• 0: Client• 1: ServerNote: It is recommended to use UDP/TCP server type while using auto connection in Limited-AP mode.

Protocol Mandatory Value range: 0, 1

It specifies the protocol used is UDP or TCP.• 0: UDP• 1: TCPNote: It is recommended to use TCP.

Destination IP/Host name Optional

Any valid IP address as per the IP address classes in xxx.xxx.xxx.xxx format.Host name is any valid domain name with max length of 32 ASCII character.

It specifies the IP address or the host name (domain name) of the remote system (optional if the Telit node is acting as a server). The Telit node accepts either the destination IP or host name. The maximum length of the host name can be 32 ASCII characters.

Destination Port Optional

Value range: 1 to 65535 (port number 0 is reserved and can’t be used)Format: 16-bit unsigned integer

It specifies the port number to be connected to on the remote system.

80613ST10964A Rev. 5.0 136 2019-10-24

Page 137: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 131, page 137 describes the synchronous responses and remarks for Network Parameters command.

Asynchronous Response

Table 132, page 137 describes the asynchronous responses and remarks for Network Parameters command.

Source Port Optional

Value range: 1 to 65535 (port number 0 is reserved and can’t be used)Format: 16-bit unsigned integer

It specifies the source port to bind. It is valid only in case of UDP client. This parameter is an optional one for UDP client and not valid for any other protocol.

Table 130 Network Parameters (Continued)

Parameter Optional/Mandatory Value Description

Table 131 Network Parameters Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

Table 132 Network Parameters Asynchronous Responses

Responses Remarks

N/A

In case of AT+WAUTO Asynchronous messages are expected only in layer 4 level.When Telit node is TCP/UDP server, then CONNECT and DISCONNECT are asynchronous responses.When Telit node is TCP/UDP client, then only DISCONNECT will be the asynchronous message.

N/A

TCP/IP connection successful. <CID> = the new CID in hexadecimal format.TCP/IP connection with the given CID is closed.This response is sent to the host when a connection is closed by the remote device.

80613ST10964A Rev. 5.0 137 2019-10-24

Page 138: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example

AT+ASYNCMSGFMT=1OK

AT+WAUTO=0,TelitDemoOK

AT+NDHCP=1OK

AT+NAUTO=1,1,,3000OK

AT&W0OK

ATC1OK

ATAIP SubNet Gateway192.168.17.2:255.255.255.0:192.168.17.1OK

9.6 UDP/TCP

9.6.1 Basic

9.6.1.1 Create TCP Clients

This command is used to create a TCP client connection for a remote server with IPv4 address.

NOTE: 1> For New auto mode, use AT+NCMAUTO=0,0,0 to stop or send deauth. 2> For Legacy auto mode, there is no command to stop or send deauth. Issue +++ or GPIO8 high to come out of the data processing mode, configure the settings, and issue ATA to trigger fresh auto connection.

80613ST10964A Rev. 5.0 138 2019-10-24

Page 139: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Command Syntax AT+NCTCP=<Dest-Address>,<Port>

Parameter Description

Table 133, page 139 describes the TCP Clients for IPv4 parameters.

Synchronous Response

Table 134, page 139 describes the synchronous responses and remarks for Create TCP Clients (IPv4) command.

Asynchronous Response

Table 135, page 140 describes the asynchronous responses and remarks for Create TCP Clients (IPv4) command.

NOTE: 1.) If the receiving TCP is unable to consume data and the host keeps transmitting TCP data, then there is a possibility that the receiver may reach zero window. As the host keeps transmitting TCP data, the data is accumulated in Telit network stack. In such cases, processing the next TCP data send (from host) would be blocked causing the serial interface to be blocked. This condition will be cleared when the receiver updates its window or the TCP timeout happens for the data that is stored in Telit network stack. 2.) In Concurrent mode, TCP servers with same port number can be created on both interfaces (0 and 1)

Table 133 TCP Clients for IPv4 Parameters

Parameter Optional/Mandatory Value Description

Dest-Address Mandatory N/A Dest-Address is the destination (server) IP address.

Port Mandatory N/A Port is the destination (server) port.

Table 134 TCP Clients for IPv4 Synchronous Responses

Responses RemarksCONNECT <CID>OK

Success connection with CID number.

ERROR Upon connection failure or invalid parameter.

ERROR:NO CIDTelit node supports only 16 clients, it will not create the next connection (i.e., 17th connection) when all 16 connections (CIDs) are being active.

80613ST10964A Rev. 5.0 139 2019-10-24

Page 140: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example Use Case WL865E4-P node is configured as a TCP client with:

TCP Server IP: 192.168.23.100TCP Server port: 3009

AT+WA=TelitDemoIP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

AT+NDHCP=1IP SubNet Gateway192.168.17.3:255.255.255.0:192.168.17.1OK

AT+NCTCP=192.168.23.100,3009CONNECT 0OK

Example Use Case When AT+NCTCP is executed before L2/L3:

Serial2WiFiAPPAT+NCTCP=192.168.12.1,1234DISASSOCIATEDOK

AT+WSTATUSNOT ASSOCIATEDOK

AT+NSTAT=?MAC=00:1d:c9:1b:93:b0WSTATE=NOT CONNECTED MODE=NONEBSSID=00:00:00:00:00:00 SSID=””CHANNEL=NONE SECURITY=NONERSSI=0IP addr=0.0.0 SubNet=0.0.0.0 Gateway=0.0.0.0DNS1=0.0.0.0 DNS2=0.0.0.0Rx Count=0 Tx Count=0OK

Table 135 TCP Clients for IPv4 Asynchronous Responses

Responses Remarks

DISCONNECT <CID>TCP connection with the given CID is closed. This response is sent to the host when a connection is closed by the remote server.

ERROR: SOCKET FAILURE <CID> Upon connection failure.

80613ST10964A Rev. 5.0 140 2019-10-24

Page 141: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AT+CID=?No Valid CidsOK

9.6.1.2 Create UDP Client

This command is used to create a UDP client connection for a remote sever with IPv4 address. Upon deployment of this command, the interface opens a UDP socket capable of sending data to the specified destination address and port.

Command Syntax AT+NCUDP=<Dest-Address>,<Port>[<,Src-Port>]

Parameter Description

Table 136, page 141 describes the UDP Clients IPv4 parameters.

Synchronous Response

Table 137, page 142 describes the synchronous responses and remarks for the UDP Clients IPv4 command.

NOTE: Telit node receives UDP packets of size less than or equal to 1500 bytes.

Table 136 UDP Clients IPv4 Parameters

Parameter Optional/Mandatory Value Description

Dest-Address Mandatory N/A Dest-Address is the destination (server) IP address.

Dest-Port Mandatory N/APort is the destination (server) port.Note: The port range 0xBAC0(47808) to 0xBACF (47823)

may not be used for destination port.

Src-Port Optional N/APort is the source (client) port. If a source port is provided, the socket will bind to the specified port.

80613ST10964A Rev. 5.0 141 2019-10-24

Page 142: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example Use Case WL865E4-P node is configured as a UDP client with:

Server IP: 192.168.23.100Server port: 9003

AT+WA=TelitDemoIP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

AT+NDHCP=1IP SubNet Gateway192.168.23.101:255.255.255.0:192.168.23.1OK

AT+NCUDP=192.168.23.100,9003CONNECT 0OK

9.6.1.3 Start TCP Server

This command is used to start the TCP server connection with IPv4 address.

Command Syntax AT+NSTCP=<Port>, [<Max client connection>, <TCP window size>

Parameter Description

Table 138, page 143 describes the Start TCP Server command parameters.

Table 137 UDP Clients IPv4 Synchronous Responses

Responses RemarksCONNECT <CID>OK

Successful connection

ERROR: SOCKET FAILURE <CID> When the active Src-Port and the active Dest-Port number is being used for establishing a new connections with the TCP Server.

ERROR: NO CID Telit node support only 16 CIDs, it will not create the next connection (i.e., 17th connection) when all 16 CIDs are being active.

NOTE: If the receiving TCP is unable to consume data and the host keeps transmitting TCP data, then there is a possibility that the receiver may reach zero window. As the host keeps transmitting TCP data, the data is accumulated in Telit network stack. In such cases, processing the next TCP data send (from host) would be blocked causing the serial interface to be blocked. This condition will be cleared when the receiver updates its window or the TCP timeout happens for the data that is stored in Telit network stack.

80613ST10964A Rev. 5.0 142 2019-10-24

Page 143: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Po

M

TC

Synchronous Response

Table 139, page 143 describes the synchronous responses and remarks for the TCP Server command.

Asynchronous Response

Table 140, page 144 describes the asynchronous responses and remarks for the TCP Sever command.

Table 138 TCP Server Parameters

Parameter Optional/Mandatory Value Description

rt Mandatory N/A The interface opens a socket on the specified port and listens for connections.

ax client connection OptionalValue range: 0-9, a-fFormat: IntegerDefault value: 15

It specifies the maximum client connectionwith the server.The total number of network sockets is 16including server socket.

P window size Optional

Value range: 1024 to 8192Format: IntegerDefault value: 8192

It specifies the size of the TCP window server.

Table 139 TCP Server Synchronous Responses

Responses RemarksCONNECT <CID>OKExample: CONNECT 0

SuccessTCP connection successful. <CID> = the new CID in hexadecimal format.

DISCONNECT <CID>Example: DISCONNECT 1

Client disconnects the connection from Telit node (TCP server).

ERROR:NO CID

Telit node supports 16 CIDs, when 16 connections are established and tries to connect for 17th connection, then an error message will be displayed for insufficient memory.

ERROR:SOCKET FAILURE <CID>Example: ERROR: SOCKET FAILURE 0

When the same port is used for creating TCP sever, then Telit node displays an error message for the duplicate port.

80613ST10964A Rev. 5.0 143 2019-10-24

Page 144: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example Use Case WL865E4-P node is configured as a TCP server with

Port: 8005AT+NDHCP=1OK

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.23.101:255.255.255.0:192.168.23.1OK

AT+NSTCP=8005CONNECT 0

Example Use Case When AT+NSTCP is executed before L2/L3:

Serial2WiFiAPPAT+NCTCP=192.168.12.1,1234DISASSOCIATEDOK

AT+NSTCP=3456DISASSOCIATED

AT+NSTCP=8888DISASSOCIATED

AT+WSTATUSNOT ASSOCIATEDOK

Table 140 TCP Server Asynchronous Responses

Responses RemarksCONNECT <SERVER_ID> <CLIENT_ID> <CLIENT IP> <CLIENT_PORT>Example: CONNECT 0 1 192.168.17.2 50569Where,0 - server_cid1 - client_cid192.168.23.100 - client_ip50569 - client_port

SuccessSuccessful connection establishment of TCP client (Hercules) to Telit node (TCP server).

DISCONNECT <CID>Example: DISCONNECT 3

TCP connection with the given CID is closed. This response is sent to the host when a connection is closed by the remote device (TCP client).

80613ST10964A Rev. 5.0 144 2019-10-24

Page 145: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AT+NSTAT=?MAC=00:1d:c9:1b:93:b0WSTATE=NOT CONNECTED MODE=NONEBSSID=00:00:00:00:00:00 SSID=””CHANNEL=NONE SECURITY=NONERSSI=0IP addr=0.0.0 SubNet=0.0.0.0 Gateway=0.0.0.0DNS1=0.0.0.0 DNS2=0.0.0.0Rx Count=0 Tx Count=0OK

AT+NSTCP=1234DISASSOCIATED

AT+CID=?No Valid CidsOK

9.6.1.4 Start UDP Server

This command is used to start a UDP server connection with IPv4 address.

Command Syntax AT+NSUDP=<Port>

Parameter Description

Table 141, page 145 describes the UDP Server parameters.

Synchronous Response

Table 142, page 146 describes the synchronous responses and remarks for the UDP Server command.

NOTE: Telit node receives UDP packets of size less than or equal to 1500 bytes.

Table 141 UDP Server Parameters

Parameter Optional/Mandatory Value Description

Port Mandatory N/AServer port (The port range 0xBAC0 (47808) to 0xBACF (47823) may not be used).

80613ST10964A Rev. 5.0 145 2019-10-24

Page 146: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example Use Case WL865E4-P node is configured as a UDP server with port 1009.

AT+NDHCP=1OK

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.23.101:255.255.255.0:192.168.23.1OK

AT+NSUDP=1009CONNECT 0OK

9.6.2 Data Handling

9.6.2.1 Normal Data Handling

This section provides details about the Data Handling Escape Sequences used in WL865E4-P node.

The following sections are covered:

• UART Interface, page 146

• SPI Interface, page 151

9.6.2.1.1 UART Interface

Table 143, page 147 describes the Data Handling using ESC key sequences on the UART interface.

Table 142 UDP Server Synchronous Responses

Responses RemarksCONNECT <CID>OKExample: CONNECT 0

SuccessUDP connection successful. CID is the new socket identifier allocated to the socket on Telit node.

ERROR:SOCKET FAILURE <CID>Example: ERROR: SOCKET FAILURE 0

When the same port is used for creating UDP server, then Telit node displays an error message for the duplicate port.

ERROR:NO CIDTelit node supports 16 CIDs, when 16 connections are established and tries to connect for 17th connection, then an error message will be displayed.

80613ST10964A Rev. 5.0 146 2019-10-24

Page 147: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

NOTE: 1). Use flow control when data sent is greater than 2048 bytes. 2).Binary data transfer is not supported in Normal mode. 3).Software flow control is not supported in binary data transfer.

Table 143 Data Handling Using ESC Sequences on UART Interface Flow Control Data Mode (Data

Type)Connection

TypeDescription and Escape <ESC> Command

Sequence

HW Normal (ASCII Text)TCP clientTCP server

This escape sequence selects the specified Connection ID as the current connection. This switches the connection to be used without exiting from the Data mode of operation. Use this sequence to send data from a TCP server, TCP client or UDP client (must be done before data can be received by that client).

Module send and receive sequence:

<ESC>S<CID><data><ESC>EExample: to send user data (e.g., Hello) on CID 1, the format will be:

<ESC>S1Hello<Esc>E

HW Normal (ASCII Text) UDP client

If UDP client is configured with unicast destination server IP address.

Module send and receive sequence:

<ESC>S<CID><data><ESC>E

If UDP client is configured with broadcast destination server IP address (i.e., 255.255.255.255), then:Module expects to receive the following data sequence from Host:

<ESC>S<CID><data><ESC>E

Module sends the following data sequence to Host:

<ESC>U<CID><IPAddress><space><port><hortizontal tab><data><ESC>E

80613ST10964A Rev. 5.0 147 2019-10-24

Page 148: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

HW Normal (ASCII Text) UDP server

This escape sequence is used when sending and receiving UDP data on a UDP server connection. When this command is used, the remote address and remote port is transmitted.

Module expects to receive the following data sequence from Host:

<ESC>U<CID><IPAddress>:<port>:<data><ESC>E

Module sends the following data sequence to Host:

<ESC>U<CID><IPAddress><space><port><horizontaltab><data><ESC>E

Example: when Module sends data (e.g., Hello) on CID 0, the format will be:

<ESC>U0192.168.0.101<space>1001<horizontaltab>Hello<ESC>E

HW Normal (Binary) N/ABinary data transfer with software or hardware flow control are not supported with ESC sequence.

HW Bulk (ASCII Text or text Binary)

TCP clientTCP server

To improve data transfer speed, you can use this bulk data transfer. This sequence is used to send and receive data on TCP client, TCP server, or UDP client connection.

Module send and receive sequence:

<ESC>Z<CID><data length><data>

Example: to send a 5 byte user data (e.g., Hello) on CID 1, the format will be:

<ESC>Z10005Hello

Table 143 Data Handling Using ESC Sequences on UART Interface (Continued)Flow Control Data Mode (Data

Type)Connection

TypeDescription and Escape <ESC> Command

Sequence

80613ST10964A Rev. 5.0 148 2019-10-24

Page 149: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

HW Bulk (ASCII Text or Binary) UDP client

If UDP client is configured with a unicast destination server IP address, then

Module send and receive sequence:

<ESC>Z<CID><data length><data>

If UDP client is configured with a broadcast destination server IP address (i.e., 255.255.255.255), then:

Module expects to receive the following data sequence from Host:

<ESC>Z<CID><data length><data>

Module sends the following data sequence to Host:

<ESC>y<CID><IPAddress><space><port><horizontaltab><data length><data>

Table 143 Data Handling Using ESC Sequences on UART Interface (Continued)Flow Control Data Mode (Data

Type)Connection

TypeDescription and Escape <ESC> Command

Sequence

80613ST10964A Rev. 5.0 149 2019-10-24

Page 150: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

HW Bulk (ASCII Text or Binary) UDP server

This escape sequence is used when sending and receiving UDP bulk data on a UDP server connection. When this command is used, the remote address and remote port is transmitted.

Module expects to receive the following data sequence from Host:

<ESC>Y<CID><IPAddress:<port>:<data length><data>

Module sends the following data sequence to Host:

<ESC>y<CID><IPAddress><space><client local port><space><data length><data>

Example: when receiving a 5 byte user data (e.g., Hello) on CID 1, the format will be:

<ESC>Y1192.168.0.101<1001><horizontaltab>0005Hello

HW Bulk (ASCII or Binary)TCP clientTCP serverUDP client

To improve data transfer speed, one can use this bulk data transfer. This sequence is used to send and receive data on TCP client, TCP server, or UDP client connection.

Module send and receive sequence:

<ESC>Z<CID><data length)<data>

Example: to send a 5 byte user data (e.g., Hello) on CID 1, the format will be:

<ESC>Z10005Hello

SW Bulk (Binary) N/A Binary data transfer with software flow control not supported.

Table 143 Data Handling Using ESC Sequences on UART Interface (Continued)Flow Control Data Mode (Data

Type)Connection

TypeDescription and Escape <ESC> Command

Sequence

80613ST10964A Rev. 5.0 150 2019-10-24

Page 151: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.6.2.1.2 SPI Interface

Table 144, page 151 describes Data Handling using the ESC Sequences on the SPI Interface.

SW Normal (Binary) UDP

This escape sequence is used when sending and receiving UDP data on a UDP server connection. The remote address and remote port is transmitted in binary encoding with the MSB transmitted first.

<ESC>u CID<remote address><remote port>

The following example shows the header to transmit a UDP packet using binary addressing taking up 9 bytes (d denoting decimal value):

<ESC>u4<192d><168d><1d><1d><0d><52d><data><ESC>E

Table 143 Data Handling Using ESC Sequences on UART Interface (Continued)Flow Control Data Mode (Data

Type)Connection

TypeDescription and Escape <ESC> Command

Sequence

Table 144 Data Handling Using ESC Sequences on the SPI Interface Data Mode (Data Type) Connection Type Description and Escape <ESC> Command

Sequence

Normal (ASCII Text)TCP clientTCP server

1. Data transfer is transparent due to byte stuffing at SPI driver level.

2. Byte stuffing must be incorporated in Host controller as per the Adapter guide.

Module send and receive sequence:

<ESC>S<CID><data><ESC>E

or Auto mode.

80613ST10964A Rev. 5.0 151 2019-10-24

Page 152: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Normal (ASCII Text) UDP client

If UDP client is configured with an unicast destination server IP address, then:Module send and receive sequence:

<ESC>S<CID><data><ESC>E

If UDP client is configured with a broadcast destination server IP (i.e., 255.255.255.255), then:Module expects to receive the following data sequence from MCU:

<ESC>S<CID><data>ESC>E

Module sends the following data sequence to MCU:

<ESC>u<CID><IP Address><space><port><horizontal tab><ESC>E

Normal (ASCII Text) UDP server

This escape sequence is used when sending and receiving UDP data on a UDP server connection. When this command is used, the remote address and remote port is transmitted.Module expects to receive the following data sequence from Host:

<ESC>u<CID><IPAddress>:<port>:<data><ESC>E

Module sends the following data sequence to Host:

<ESC>u<CID><IPAddress><space><port><horizontal tab><data><ESC>E

Example: when receiving user data (e.g., Hello) on CID o, the format will be:

<ESC>u0192.168.0.101<space>1001<hortizontal tab>Hello<Esc>E

Normal (Binary) N/A Binary data transfer with software flow control is not supported with ESC sequence.

Normal (ASCII Text or Binary) N/A Hardware flow control is not supported.

Table 144 Data Handling Using ESC Sequences on the SPI Interface (Continued)Data Mode (Data Type) Connection Type Description and Escape <ESC> Command

Sequence

80613ST10964A Rev. 5.0 152 2019-10-24

Page 153: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Bulk (ASCII Text or Binary)

TCP clientTCP server

1. Data transfer is transparent due to byte stuffing at SPI driver level.

2. Byte stuffing must be incorporated in Host controller as per the Adapter guide.

Module send and receive sequence:

<ESC>Z<CID><data length><data>

Example: to send a 5 byte user data (e.g., Hello) on CID 1, the format will be:

<ESC>Z10005Hello

Bulk (ASCII Text or Binary) UDP client

If UDP client is configured with a unicast destination server IP address, then:Module sends and receives the following data sequence:

<ESC>Z<CID><data length><data>

If UDP client is configured with a broadcast destination server IP address (i.e., 255.255.255.255), then:Module expects to receive the following data sequence from Host:

<ESC>Z<CID><data length><data>

Module sends the following data sequence to Host:

<ESC>y<CID><IP Address><space><port><horizontal tab><data length><data>

Table 144 Data Handling Using ESC Sequences on the SPI Interface (Continued)Data Mode (Data Type) Connection Type Description and Escape <ESC> Command

Sequence

80613ST10964A Rev. 5.0 153 2019-10-24

Page 154: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Esccol)

<ESC<ESC<ESC<ESC<ESC<ESC<ESCNote: Re

<ESC

Table 145, page 154, describes the responses and remarks the SPI Byte Protocol & SPI Block Protocol for Non Bulk and Bulk Mode.

Bulk (ASCII Text or Binary) UDP server

This escape sequence is used when sending and receiving UDP bulk data on a UDP server connection. When this command is used, the remote address and remote port is transmitted.Module receives from Host the following data sequence:

<ESC>y<CID><IP Address>:<port>:<data length><data>

Module sends the following data sequence to Host:

<ESC>y<CID><IP Address><space><port><horizontal tab><data length><data>

Example: when receiving a 5 byte user data (e.g., Hello) on CID 1, the format will be:

<ESC>y0192.168.0.101<space>1001<horizontal tab>0005Hello

Table 144 Data Handling Using ESC Sequences on the SPI Interface (Continued)Data Mode (Data Type) Connection Type Description and Escape <ESC> Command

Sequence

Table 145 Response for SPI Byte Protocol & SPI Block Protocol

ape Sequence Events ResponseUART SDIO SPI (Byte Protocol) SPI (Block Proto

Non Bulk Mode (Data transfer supports ASCII data handling)>S<CID> Valid CID <ESC>O <ESC>O No response>S<CID> Invalid CID <ESC>F <ESC>F <ESC>F>U<CID> Valid CID <ESC>O <ESC>O No response>U<CID> Invalid CID <ESC>F <ESC>F <ESC>F>E End of Data <ESC>O <ESC>O <ESC>O>S<CID><Data><ESC>E - Use this sequence to send data from a TCP Server, TCP Client and UDP Client.>U<CID><IP Address>:<Port><Data><ESC>E - Use this sequence to send data from UDP Server.fer the responses returned by the S2W for valid CID, invalid CID and end of data events.

Bulk Mode (Data transfer supports both ASCII and binary handling)>Z<CID> Valid CID <ESC>O <ESC>O No response

80613ST10964A Rev. 5.0 154 2019-10-24

Page 155: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

<ESC<ESC<ESC<ESC lient and U<ESC UDP ServerNote: Re

Esc

9.6.2.2 Bulk Data Handling

In Bulk Data Mode, data transfers are managed using escape sequences (ESC Z, ESC Y and ESC y). Each escape sequence (see Table 146, page 156) starts with the Escape <ESC> key (ASCII character 27 (0x1B)). Encoding is used for both transmitted and received data. Enable bulk data by using command “AT+BDATA=” (1 is enable and 0 is disable).

The format of a bulk data frame for TCP client, TCP server, or UDP client is:

<ESC>Z<CID><Data Length xxxx 4 ascii char><data>

The contents of < > are a byte or byte stream.

– CID is connection identifier (UDP, TCP, etc.; as derived when TCP socket is created by issuing the command: AT+NCTCP, for example.)

– Data Length is 4 ASCII character represents decimal value i.e. 1400 byte (0x31 0x34 0x30 0x30).

– The Data Length range should be 1 to 1400 bytes when sending to Telit module from Host and it will be 1 to 1500 bytes when Host is receiving from Telit module

User Data size must match the specified Data Length. Ignore all command or Escape <ESC> sequence in between data pay load. User should send the specified length of data to the WL865E4-P node irrespective of any asynchronous events happened on the WL865E4-P node so that the WL865E4-P node can start receiving next commands.

For example, if CID value is 3, then:

To send a 5 byte user data (e.g. DE) for a TCP client connection, the format will be:

<ESC>Z30005DE

>Z<CID> Invalid CID <ESC>F <ESC>F <ESC>F>Y<CID> Valid CID <ESC>O <ESC>O No response>Y<CID> Invalid CID <ESC>F <ESC>F <ESC>F>Z<CID><Data Length XXXX(4 ASCII character)><Data> - Use this sequence to send data from a TCP Server, TCP CDP Client.>Y<CID><IP Address>:<Port><Data length XXXX(4 ASCII character)><Data> - Use this sequence to send data from.fer the responses returned by the S2W for valid CID and invalid CID.

Table 145 Response for SPI Byte Protocol & SPI Block Protocol (Continued)

ape Sequence Events Response

NOTE: This is the recommended data handling method.

80613ST10964A Rev. 5.0 155 2019-10-24

Page 156: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

To send a 512 byte user data for a TCP client connection, the format will be:

<ESC>Z30512<512 bytes of user data>

To send data on UDP server, the bulk data frame format is:

<ESC>Y<CID><Ip address>:<port>:<Data Length xxxx 4 decimal digits><data>

When receiving data on UDP server, the format of a bulk data frame is:

<ESC>y<CID><IP address><space><port><horizontal tab><Data Length xxxx 4 decimal digits><data>

Table 146 Escape Sequences

Operation Escape Sequence DescriptionBulk Data transfer on TCP Server/Client and UDP Client connection

<ESC>Z<CID>Data Len 4 digit ascii<Data>

To improve data transfer speed, one can use this bulk data transfer. This escape sequence is used to send and receive data on a TCP Client/Server and UDP client connection.

Example: <ESC>Z40005Hello - where 4 is the CID, 0005 is the 5 byte data length and Hello is the data to be sent.Bulk Data Send on UDP server connection

<ESC>Y<CID> remote address: remote port:Data Len 4 digit ascii<Data>

This escape sequence is used when sending UDP data on a UDP server connection. When this command is used, the remote address and remote port is transmitted in ASCII text encoding and terminated with a “:” character.

Example: <ESC>Y4192.168.1.52:000Hellop where 4 is the CID, 0005 is the 5 byte data length and Hello is the data to be sent.Bulk Data Receive on UDP Server Connection

<ESC>y<CID> remoteaddress<space>remote port<horizontal tab>Data length in 4 digit ascii<Data>

This escape sequence is used when receiving UDP data on a UDP server connection. When this sequence is used, the remote address and remote port is transmitted in ASCII text encoding and separated by a space ( ) character.

Example: <ESC>y4192.168.1.1<space>53<horizontal tab>0005Hello where 4 is the CID, 0005 is the 5 byte data length and Hello is the data received.

NOTE: a> The contents of < > are either a byte or byte stream, except for <ESC>; literals outside brackets are ASCII characters. b> WL865E4-P node sends success or failure responses as mentioned in Table 4, page 21 when MCU transmits bulk data.

80613ST10964A Rev. 5.0 156 2019-10-24

Page 157: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.7 GSLinkGSLink is mainly used to offload MCU from parsing XML, JSON and raw data in HTTP transactions. Telit node can be a HTTP server or client. While using, Telit node acts as an interface between MCU and the other node that runs HTTP server or client.

Telit node supports to send and receive HTTP data in XML, raw HTTP, and JSON formats. Data can be sent and received,

• as part of an HTTP message (raw HTTP method) which contains complete data

• as XML data where each element can be sent and received individually

• and as JSON data where each element can be sent and received independently

When acting as an HTTP Server, Telit node only performs HTTP_GET_RESPONSE or HTTP_POST_RESPONSE. When acting as an HTTP Client, it performs HTTP_GET, HTTP_HEAD, HTTP_POST, HTTP_PUT, or HTTP_DELETE. As Telit node is aware of the type of communication used by HTTP server, it chooses and initiates appropriate format (raw HTTP/XML/JSON) of communication.

9.7.1 GSLink with HTTP When using HTTP with GSLink, the host must do the following:

• Configure the HTTP client or server parameters

• If HTTP client, open HTTP connection.

• If HTTP server, wait for HTTP client connection.

• Use the respective CID as part of HTTP, XML, or JSON send

NOTE: 1).Telit web-server supports only one client using. 2).No other HTTP Request is supported while POST is in progress. 3).Data size must be greater then zero for GET response in raw mode.

80613ST10964A Rev. 5.0 157 2019-10-24

Page 158: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.7.2 Receive RequestWhen web client sends a request (GET/POST) to web server (Telit node), the Telit node passes the request to MCU using the following Escape <ESC> sequence.

Asynchronous Data <ESC>K<CID><Len><Type><URI>

Asynchronous Data Parameter Description

Table 147, page 158 describes the HTTP Request (GET/POST) parameters.

Example <ESC>K000221/gainspan/profile/mcu

Table 147 HTTP Request (GET/POST) Parameters

Parameter Optional/Mandatory Value Description

ESCK Mandatory N/A This escape sequence is sent once the URL is fetched by the remote HTTP client.

CID Mandatory

Value range: 0 to FFormat: Hexadecimal

It specifies the socket identifier allocated to a socket on Telit node.

Len Mandatory Format: Decimal

It specifies the length of the string including <type>, <URI> which is of 4 ASCII characters represented in decimal value.

Type Mandatory

Value range: 1 or 3Format: Decimal

It specifies the type used.• 1: GET REQUEST• 3: POST REQUEST

URI Mandatory Format: String It specifies the URL fetched by the Remote HTTP client.

NOTE: 1.) Multiple parsers (XML and JSON) cannot be enabled together. AT command returns an error when multiple parsers are enabled. 2.) When the request is sent to the host, a response to the request is mandatory from the host irrespective of the connection status. Once the response from the host is sent, the server takes care of connection closure.

80613ST10964A Rev. 5.0 158 2019-10-24

Page 159: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.7.3 Enable XML ParserThis command is used to enable or disable XML parser on HTTP data sent and received by the Telit node.

Command Syntax AT+XMLPARSE=n

Parameter Description

Table 148, page 159 describes the Enable XML Parser parameters.

Synchronous Response

Table 149, page 159 describes the synchronous responses and remarks for Enabling or disabling XML Parser on HTTP Data command.

9.7.4 Send XML DataThis section provides commands used to send XML elements one by one using <ESC>G sequence when Telit node acts as HTTP server.

Command Syntax AT+XMLSEND=<CID>,<Type>,<Timeout>,<Page URI>,<Root tag name>[,<N>],<Send response status line>, <Send response headers count>

MCU sends XML data using the following ESC sequence:

<ESC>G<CID>[Opcode]<Len><Tag name>:<Value>

Refer Table 152, page 162 for parametric description of <ESC>G sequence

ESC G is to sent N times, one for each tag.

Table 148 Enable or Disable XML Parser Parameters

Parameter Optional/Mandatory Value Description

n Mandatory Value range: 0,1

It specifies whether XML parser is enabled or disabled.• 0: Disable• 1: Enable

Table 149 Enable or Disable XML Parser Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameters are not valid.(n value is other than 0 or 1)

80613ST10964A Rev. 5.0 159 2019-10-24

Page 160: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

“Len” is the length of the string including <tag name>:<value> The value of the tag length is 256.

Usage Usage of Opcode:

• 9900 - 9990: Future Use

• 9992: MIME type

• 9999: Future Use

• 9998: Start of Element with sub-elements

• 9997: End of Element with sub-elements

• 9996: Attribute

• 0000: End of Data

Parameter Description

Table 150, page 160 describes the Send XML Data parameters.

NOTE: MCU should send complete data as mentioned in AT+XMLSEND or AT+HTTPSEND commands.

Table 150 Send XML Data Parameters

Parameter Optional/Mandatory Value Description

CID MandatoryValue range: 0 to FFormat: Hexadecimal

It specifies the socket identifier allocated to a socket on Telit node.

Type MandatoryValue range: 1,3,6,7Format: Decimal

It specifies the type used for the following:• For HTTP Client: 1(GET), 3(POST)• For HTTP Server: 6 (GETRESP), 7

(POSTRESP)

Timeout Mandatory Format: Decimal Timeout is the HTTP timeout for the get/post.

Page URI MandatoryFormat: StringDefault Value: Registered URI with the server

It specifies the URI to be used for communication.Note: In case of HTTP Server, register the URI with the

server using AT+URIRECV

Root tag name Mandatory Format: String It specifies the Root tag of XML data.

80613ST10964A Rev. 5.0 160 2019-10-24

Page 161: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 151, page 161 describes the synchronous responses and remarks for sending XML Parser on HTTP Data command.

Example AT+XMLPARSE=1OKAT+WEBSERVER=1,admin,adminOKAT+URIRECV=sys/test,,1,1,FFFFFFFFOK......AT+XMLSEND=1,6,100,/sys/test,test,1,1,7OK

MCU sends XML data using the following ESC sequence:<ESC><G>100009STATUS:OK

Where,

– <ESC>G: Escape format to send XML data.

– 1: CID

– 0009: Length

N Optional Format: Decimal N is the number of elements in the XML string.

Send response status line Optional Value range: 0,1

When MCU wants to send custom response status line, set this parameter to 1.• 0: Do not send custom response status line• 1: Send custom response status line

Send response headers count Optional

Value range: 0 or Number of different custom headers which are required to be sent

When MCU wants to send custom response headers, set this parameter to number of different custom headers which are required to be sent.Set this argument to 0, if no custom headers are to be sent.

Table 150 Send XML Data Parameters (Continued)

Parameter Optional/Mandatory Value Description

Table 151 Send XML Data Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 161 2019-10-24

Page 162: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

– STATUS:OK: XML data in <tag>:<value> format.

9.7.5 Receive XML DataTelit node sends XML data using the following Escape <ESC> sequence

Asynchronous Data <ESC>G[Opcode]<Len><Tag name>:<Value>

Asynchronous Data Parameter Description

Table 152, page 162 describes the Receive XML data (ESC G) parameters.

Example Following example demonstrate the message exchange between the Web clients, GS-Link Feature and Host MCU for HTTP POST request.

When the Web client does the HTTP POST of the following XML data on URL: "/gainspan/profile/tls"

<conf> <network> <ip>192.168.240.1</ip> <port>9100</port> </network> <serial> <comport>10</comport> <baudrate>115200</baudrate> </serial></conf>

Table 152 Receive XML Data (ESC G) Parameters

Parameter Optional/Mandatory Value Description

ESC G N/A N/A This is sent repeatedly for each tag for the XML data.

Opcode N/A

Value range: 9998, 9997, 9996, 0000Format: Decimal

It specifies the type of data sent to MCU.• 9998: Start of Element with sub elements• 9997: End of Element with sub elements• 9996: Attribute• 0000: End of Data

Len N/A

Value range: 0000-9999Format: Decimal

Len is the length of the XML data sent by Telit node to MCU including <tag name>:<value> in 4 bytes ASCII decimal value.

Tag name N/A Format: N/A It specifies name of the XML tag being sent as part of HTTP data.

Value N/A Format: N/A It specifies the value corresponding to the Tag name.

80613ST10964A Rev. 5.0 162 2019-10-24

Page 163: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

The GSLink Feature will pass the following content to Host:

• Sequence of Characters received by HOST MCU for URL:<ESC>K000223/gainspan/profile/tls

• Sequence of Characters received by HOST MCU for Data:<ESC>G99980007network<ESC>G0016ip:192.168.240.1<ESC>G0009port:9100<ESC>G9997

<ESC>G99980006serial<ESC>G0010comport:10<ESC>G0015baudrate:115200<ESC>G9997<ESC>G0000

9.7.6 Send Raw HTTP Data

This command is used to send raw HTTP data using <ESC>H sequence when Telit node acts as HTTP server.

Command Syntax AT+HTTPSEND=<CID>,<Type>,<Timeout>,<Page>,<Size of data>,[<Send response status line>,<Send response headers count>]

MCU sends raw HTTP data using the following Escape <ESC> sequence:

<ESC>H<CID><Data of above size>

Parameter Description

Table 153, page 164 describes the Send Raw HTTP Data parameters.

NOTE: Information provided in this section is a subset of information in section Exchange/Send Data with HTTP Client, page 128, and it is only relevant for GSLink.

80613ST10964A Rev. 5.0 163 2019-10-24

Page 164: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 154, page 164 describes the synchronous responses and remarks for sending Raw HTTP Data command.

Table 153 Send Raw HTTP Data Parameters

Parameter Optional/Mandatory Value Description

CID MandatoryValue range: 0 to FFormat: Hexadecimal

It specifies the socket identifier allocated to a socket on Telit node.

Type MandatoryValue range: 6 or 7Format: Decimal

GSN_HTTP_METHOD_GETRESP (6)GSN_HTTP_METHOD_POSTRESP (7)

Timeout MandatoryFormat: DecimalUnit: Seconds

Timeout value is in seconds

Page Mandatory Format: String The page/script being accessed (e.g., /index.html)

Size of data Optional Format: StringActual size of the contentNote: It is recommended to use when sending data from

MCU as part for GSN_HTTP_METHOD_GET-RESP or GSN_HTTP_METHOD_POSTRESP

Send response status line Optional

Value range: 0,1Format: Decimal

When MCU wants to send custom response status line, set this parameter to 1.• 0: Do not send custom response status line• 1: Send custom response status line

Send response headers count Optional

Value range: 0 or Number of different custom headers which are required to be sent

When MCU wants to send custom response headers, set this parameter to number of different custom headers which are required to be sent.Set this argument to 0, if no custom headers are to be sent.

Table 154 Send Raw HTTP Data Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 164 2019-10-24

Page 165: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.7.7 Receive Raw HTTP DataMCU receives raw HTTP data using the following Escape <ESC> sequence:

Asynchronous Data <ESC>H<CID><Length of data><data>

Asynchronous Data Parameter Description

Table 155, page 165 describes the Receive Raw HTTP Data (ESC H) parameters.

9.7.8 Enable JSON DataThis command is used to enable or disable JSON parser on HTTP data sent and received by Telit node.

Command Syntax AT+JSONPARSE=n

Parameter Description

Table 156, page 165 describes the enable or disable JSON Parser on HTTP Data parameters.

Table 155 Receive Raw HTTP Data (ESC H) Parameters

Parameter Optional/Mandatory Value Description

ESCH N/A Format: String This is sent repeatedly for each tag for the raw HTTP data.

CID N/A

Value range: 0 to F (1 byte)Format: Hexadecimal

It specifies the socket identifier allocated to a socket on Telit node.

Length of data N/A Format: ASCII decimal

‘Length of data’ is the length of the raw HTTP data sent by Telit node to MCU, in 4 bytes ASCII decimal value.

data N/A Format: String Actual content

NOTE: Once the JSON parser is enabled, use AT+URIRECV command to change the content type to JSON. See URI Registration (Modification), page 170

Table 156 Enable or Disable JSON Parser on HTTP Data Parameters

Parameter Optional/Mandatory Value Description

n MandatoryValue range: 0, 1Format: Decimal

If n is 0, JSON parser is disabled. If n is 1, JSON parser is enabled.• 0: Disable• 1: Enable

80613ST10964A Rev. 5.0 165 2019-10-24

Page 166: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 157, page 166 describes the synchronous responses and remarks for enabling or disabling JSON Parser on HTTP Data command.

9.7.9 Send JSON DataThis section provides commands used to send JSON elements one by one using <ESC>G sequence when Telit node acts as HTTP server.

Command Syntax AT+JSONSEND=<CID>,<Type>,<Timeout>,<URI>,<Root object>

MCU sends JSON data using the following Escape <ESC> sequence:

<ESC>G<CID>[Opcode]<Length><Tag name>:<Value>

Refer Table 152, page 162 for parametric description of <ESC>G sequence

JSON supports following opcodes:

• 9987: Start of JSON array

• 9988: Start of JSON array element

• 9989: Reserved

• 9990: Reserved

• 9991: HTTP request line

• 9992: HTTP header

• 9993: CGI parameters

• 9994: HTTP response Line

• 9995: Reserved

• 9996: XML attribute / JSON literal attribute

• For JSON parser this will be used to represent non string values, which includes number, Boolean, null.

• 9997: end of inner most parent element

To indicate end of XML complex element/JSON object/array/array element

• 9998: start of element w/sub-elements

Table 157 Enable or Disable JSON Parser on HTTP Data Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameters are not valid.(n value is other than 0 or 1)

80613ST10964A Rev. 5.0 166 2019-10-24

Page 167: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

To indicate start of XML complex element /JSON object

• 0000: End of XML/JSON data

Parameter Description

Table 158, page 167 describes the Send JSON Data parameters.

Synchronous Response

Table 159, page 167 describes the synchronous responses and remarks for Send JSON Data command.

Example AT+JSONPARSE=1

OK

AT+WEBSERVER=1,admin,admin

OK

AT+URIRECV=sys/test,,1,1,FFFFFFFF

OK

...

...

AT+JSONSEND=1,6,100,/sys/test,test,,1,7

Table 158 Send JSON Data Parameters

Parameter Optional/Mandatory Value Description

CID MandatoryValue range: 0 to FFormat: Hexadecimal

It specifies the socket identifier allocated to a socket on Telit node.

Type MandatoryValue range: 1,3,6,7Format: Decimal

It specifies the HTTP type used for thefollowing:• For HTTP Client: 1(GET), 3(POST)• For HTTP Server: 6 (GETRESP), 7(POSTRESP)

Timeout Mandatory Format: Decimal Timeout value is in seconds

URI MandatoryFormat: StringDefault value: Registered URI with the server

It specifies the URI to be used for communication.Note: In case of HTTP Server, register the URI with the

server using AT+URIRECV.

Root object Mandatory Format: String It specifies the root object of JSON.

Table 159 Send JSON Data Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 167 2019-10-24

Page 168: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

OK

<ESC><G>00009STATUS:OK /* refer Table 152, page 162*//

9.7.10 Receive JSON DataMCU receives JSON data using the following Escape <ESC> sequence

Asynchronous Data <ESC>G<CID>[Opcode]<Len><Object name>:<Value>

Asynchronous Data Parameter Description

Table 152, page 162 describes the Receive JSON data (ESC G) parameters.

Table 160 Receive JSON Data (ESC G) Parameters

Parameter Optional/Mandatory Value Description

ESC G N/A N/A This is sent repeatedly for each object of the JSON data.

CID N/A

Value range: 0 to FFormat: Decimal

It specifies the socket identifier allocated to a socket on Telit node.

80613ST10964A Rev. 5.0 168 2019-10-24

Page 169: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Opcode N/A

Value range: 9998, 9997, 9996, 0000Format: Decimal

It specifies the type of data sent to MCU.

• 9987: Start of JSON array

• 9988: Start of JSON array element

• 9991: HTTP request line

• 9992: HTTP header

• 9993: CGI parameters

• 9994: HTTP response Line

• 9995: Reserved

• 9996: XML attribute / JSON literal attribute

• For JSON parser this will be used to represent non string values, which includes number, Boolean, null.

• 9997: end of inner most parent element

To indicate end of XML complex element/JSON object/array/array element

• 9998: start of element w/sub-elements

To indicate start of XML complex element /JSON object

• 0000: End of XML/JSON data•

Len N/A

Value range: 0000-9999Format: Decimal

Len is the length of the JSON data sent by Telit node to MCU including <Object name>:<value> in 4 bytes ASCII decimal value.

Object name N/A Format: N/A It specifies name of the JSON tag being sent as part of HTTP data.

Value N/A Format: N/A It specifies the value corresponding to the object name.

Table 160 Receive JSON Data (ESC G) Parameters (Continued)

Parameter Optional/Mandatory Value Description

80613ST10964A Rev. 5.0 169 2019-10-24

Page 170: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.7.11 URI Registration (Modification)This command is used to register a new URI or modify the default URI. MCU registers to receive CGI arguments, request line, and HTTPD headers through this command.

Command Syntax AT+URIRECV=<URI>[,Content Type,<Send CGI arguments>,<Send request line>,<Send HTTPD Headers>]]

MCU receives CGI arguments, Request line, or HTTPD headers through different ESC sequences along with various Reserved length values.

Parameter Description

Table 161, page 170 describes the URI Modification parameters.

Table 161 URI Modification Parameters

Parameter Optional/Mandatory

Value Description

URI (Uniform Resource Identifier) Mandatory

• /gainspan/profile/mcu (default)

• /gainspan/system (reserved)

URI is a string used to identify a web resource.Note: Maximum length of URI is 64 characters including the null terminating character (‘\0’).

Content Type OptionalValue range: 0 to 4Format: Decimal

Content type for the URI.• 0: application/xml (default)• 1: application/json• 2: application/html• 3: Img/gif• 4: application/octet-stream

Send CGI arguments OptionalValue range: 0, 1Format: DecimalDefault value: 0

• 0: Do not forward CGI arguments to MCU.

• 1: Forward all CGI arguments to MCU.

Send request line OptionalValue range: 0, 1Format: DecimalDefault value: 0

• 0: Do not forward request line to MCU.• 1: Forward request line to MCU.

Send HTTPD Headers OptionalValue range: 1 to FFFFFFFFFormat: Hexadecimal

This parameter specifies the Bitmap value of a specific HTTP header. MCU can enable various headers by setting respective bit positions in this parameter as specified in the Table 162, page 171.Example: If this parameter is set as FFFFFFFF, then all the headers listed in Table 162, page 171 are enabled.

80613ST10964A Rev. 5.0 170 2019-10-24

Page 171: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Note: 1. GSN_HTTP_HEADER_CUSTOM can be used to register for request header apart from mentioned values. In case multiple custom headers coming in HTTP request, all the custom headers will be passed to the MCU.

Synchronous Response

Table 163, page 172 describes the synchronous responses and remarks for URI Modification command.

Table 162 Send HTTPD Headers

Header Name/ValueGSN_HTTP_HEADER_ALLOW(1)GSN_HTTP_HEADER_AUTHORIZATION (2) GSN_HTTP_HEADER_CONNECTION (3) GSN_HTTP_HEADER_CONTENT_ENCODING (4)GSN_HTTP_HEADER_CONTENT_LENGTH (5)GSN_HTTP_HEADER_CONTENT_RANGE (6) GSN_HTTP_HEADER_CONTENT_TYPE (7) GSN_HTTP_HEADER_COOKIE(8)GSN_HTTP_HEADER_COOKIE2(9)GSN_HTTP_HEADER_DATE (10) GSN_HTTP_HEADER_EXPIRES (11) GSN_HTTP_HEADER_FROM (12) GSN_HTTP_HEADER_HOST (13) GSN_HTTP_HEADER_IF_MODIFIED_SINCE (14) GSN_HTTP_HEADER_LAST_MODIFIED (15)GSN_HTTP_HEADER_LOCATION (16) GSN_HTTP_HEADER_PRAGMA (17) GSN_HTTP_HEADER_RANGE (18) GSN_HTTP_HEADER_REFERER (19) GSN_HTTP_HEADER_SERVER (20) GSN_HTTP_HEADER_SET_COOKIE (21)GSN_HTTP_HEADER_TRANSFER_ENCODING (22) GSN_HTTP_HEADER_USER_AGENT (23) GSN_HTTP_HEADER_WWW_AUTHENTICATE (24)GSN_HTTP_HEADER_CUSTOM(32)

80613ST10964A Rev. 5.0 171 2019-10-24

Page 172: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+HTTPRECVCONF=0,1,ffffffff

9.7.12 Receive CGI ArgumentsMCU registers to receive CGI arguments using AT+URIRECV and receives CGI arguments using the following ESC sequence.

Asynchronous Data <Esc>G<CID><Reserved length value><Argument length><Argument><’=’><Argument value><CR><LF>

End of CGI arguments list is indicated by:<Esc>G<CID><Reserved length value><0><CR><F>

Asynchronous Data Parameter Description

Table 164, page 172 describes the Receive CGI arguments (ESC G) parameters.

Table 163 URI Modification Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT If parameters are not valid.

Table 164 Receive CGI Arguments (ESC G) Parameters

Parameter Optional/Mandatory DescriptionESC G Mandatory This is sent repeatedly for each CGI argument.

CID Mandatory It specifies the socket identifier allocated to a socket on Telit node.

Reserved length value Mandatory Reserved for future use. Value 9993 is used to specify that CGI argument is sent to MCU.

Argument length Mandatory The total number of characters in the Argument.

Argument Mandatory The CGI argument sent to MCU. CGI argument is sent one by one through the same escape sequence.

Argument value Mandatory The character string including the <‘=’> delimiter.

80613ST10964A Rev. 5.0 172 2019-10-24

Page 173: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.7.13 Receive Request LineMCU registers to receive Request line using AT+URIRECV and receives Request line using the following ESC sequence:

Asynchronous Data <Esc>G<CID><Reserved length value)><Length><Method><’:’><Request URI><CR><LF>

Asynchronous Data Parameter Description

Table 165, page 173 describes the Receive request line (ESC G) parameters.

Table 165 Receive Request Line (ESC G) Parameters

Parameter Optional/Mandatory DescriptionESC G Mandatory This is sent repeatedly for each CGI argument.

CID Mandatory It specifies the socket identifier allocated to a socket on Telit node.

Reserved length value Mandatory Reserved for future use. Value 9993 is used to specify that Request line is sent to MCU.

Length Mandatory Number of bytes in Request URI including Method.

Method Mandatory

Specifies one of the following methods:• GSN_HTTP_METHOD_GET (1)• GSN_HTTP_METHOD_HEAD (2)• GSN_HTTP_METHOD_POST (3)• GSN_HTTP_METHOD_PUT (5)• GSN_HTTP_METHOD_DELETE (6)

Request URI Mandatory Request URI string with size equal to <Length - 1> bytes.

80613ST10964A Rev. 5.0 173 2019-10-24

Page 174: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

9.7.14 Receive HTTP HeadersMCU registers to receive HTTP headers using AT+URIRECV and receives HTTP headers using the following ESC sequence:

Asynchronous Data <Esc>G<CID><Reserved length value><Header length><Header type><’:’><Header value><CR><LF>

End of HTTP Headers list is indicated by:<Esc>G<CID><Reserved length value><0><CR><F>

Asynchronous Data Parameter Description

Table 166, page 174 describes the Receive HTTP Headers (ESC G) parameters.

Table 166 Receive HTTP Headers (ESC G) Parameters

Parameter Optional/Mandatory DescriptionESC G Mandatory This is sent repeatedly for each CGI argument.

CID Mandatory It specifies the socket identifier allocated to a socket on Telit node.

Reserved length value Mandatory Reserved for future use. Value 9992 is used to specify that HTTP header is sent to MCU.

Header length MandatoryTotal number of characters in Header type and Header value character strings including the <‘=’> delimiter.

Header type Mandatory Type of the header.Header value Mandatory Value of the header.

80613ST10964A Rev. 5.0 174 2019-10-24

Page 175: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

10 Advanced Services

This chapter describes the commands for configurations and operations related to advanced services of Network and WL865E4-P supported Application features.

• Network, page 175

• Application Features, page 190

10.1 Network

10.1.1 PingThis command is used to send the device a ping to the remote machine specified by the IPV4 address.

Command Syntax AT+PING=<IP address/host name>,[[<Counts>],[<timeout>],[<fixed pattern Len>],[<TOS>],[<TTL>],[<customised PAYLOAD>]]<CR>

Parameter Description

Table 167, page 175 describes the Ping parameters.

Table 167 Ping Parameters

Parameter Optional/Mandatory Value DescriptionIP Address/ host name Mandatory N/A The IP address of the server to which the

command is directed.

Counts Optional 0 (default)This indicates the number of ping requests to send. In this case, ping will continue until terminated.

Timeout Not Supported N/A Reserved for future use.

Fixed Pattern Len Optional 56 (default)

Length is configured to send packet size >56 by enabling “Variable Packet size” from the builder. If Len is not provided, default 56 bytes of G is sent.If Len is provided, then up to 56 bytes of G is sent. The ping packet is 0 to 1024. The packet length and pattern is fixed for the Telit node.

TOS Not Supported N/A Reserved for future use.

80613ST10964A Rev. 5.0 175 2019-10-24

Page 176: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example 1 Pinging to the server with its IP addressAT+NDHCP=1OKAT+WA=TelitDemoIP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OKAT+DNSLOOKUP=www.telit.comIP:23:23.181.241OKAT+PING=23.23.181.241Pinging for 23.23.181.241 with 56bytes of dataOK2Pinging to the server with its host nameAT+NDHCP=1OKAT+WA=TelitDemoIP SubNet Gateway192.168.10.3:255.255.255.0:192.168.10.1OKAT+DNSLOOKUP=www.telit.comIP:23.23.181.241OKAT+PING=www.telit.comPinging for 23.23.181.241 with 56 bytes of data

OK

Note: Packet length is fixed in Telit node.If both Length and Payload are configured in the AT+PING command then Payload will have highest precedence.TTL Not Supported N/A Reserved for future use.Customized Payload Not Supported N/A Reserved for future use.Note: To terminate a ping sequence, issue the <ESC>C

Table 167 Ping Parameters

Parameter Optional/Mandatory Value Description

80613ST10964A Rev. 5.0 176 2019-10-24

Page 177: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

10.1.2 Service Discovery Using mDNS

10.1.2.1 mDNS Module Initialization

This command is used to start the mDNS procedure of the node with IPv4 network.

Command Syntax AT+MDNSSTART

Synchronous Response

Table 168, page 177 describes the synchronous responses and remarks for the mDNS Module Initialization command.

Example AT+MDNSSTARTOK

Table 168 mDNS Module Initialization Synchronous Responses

Responses Remarks

OKSuccessPrior to issuing of this command the node should be associated to the network.

ERRORFailureIf the node is not associated before issuing this command.

80613ST10964A Rev. 5.0 177 2019-10-24

Page 178: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

10.1.2.2 mDNS Status

This command is used to output the current status (started or stopped) of the mDNS.

Command Syntax AT+MDNSSTART=?

Synchronous Response

Table 169, page 178 describes the synchronous responses and remarks for the mDNS status command.

10.1.2.3 mDNS Host Name Registration

This command is used to register or give a unique name to each of the nodes for mDNS.

Command Syntax AT+MDNSHNREG=[<Host name>],<Domain name>

Parameter Description

Table 170, page 178 describes the mDNS Host Name Registration parameters.

Synchronous Response

Table 171, page 179 describes the synchronous responses and remarks for the mDNS Host Name Registration command.

Table 169 mDNS Status Synchronous Responses

Responses RemarksMDNS StartedOKMDNS StoppedOK

Success

ERROR: INVALID INPUT If parameter is not valid.

Table 170 mDNS Host Name Registration Parameters

Parameter Optional/Mandatory Value Description

Host name Optional N/A

Host name is optional. If host name is not given, factory default name concatenated with last 3 bytes of the MAC address shall be taken.Maximum host name length supported is 32 bytes.

Example: If the factory default name is WL865E4-P and the MAC address of the node is 00-1d-c9-d0-70-cc, then the host will be WL865E4-P_d070cc.Domain name Mandatory N/A The domain name is always “local.”

80613ST10964A Rev. 5.0 178 2019-10-24

Page 179: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+MDNSHNREG=Provisioning,localOK

10.1.2.4 mDNS Services Registration

This command is used to register the services to the mDNS.

Command Syntax AT+MDNSSRVREG=<ServiceInstanceName>,[<ServiceSubType>],<ServiceType>,<Protocol>,<Domain>,<port>,<Default Key>[,<key 1=val 1>,<key 2=val,..<key n=val>]

Parameter Description

Table 172, page 179 describes the mDNS Services Registration parameters.

Table 171 mDNS Name Registration Synchronous Responses

Responses Remarks

OKRegistration Success!! for RR: <Host name>

SuccessPrior to issue this command, the node should be associated to the network.

ERRORFailureIf the node is not started in mDNS module, before issuing this command.

Table 172 mDNS Services Registration Parameters

Parameter Optional/Mandatory

Value Description

ServiceInstanceName Mandatory N/A This parameter specifies the name of the service. It can take up to 256 characters.

ServiceSubType Mandatory N/A This parameter specifies the name of the service subtype if any.

ServiceType Mandatory N/A This parameter specifies the type of service, such as HTTP, FTP, and so on.

Protocol Mandatory N/A This parameter specifies the protocol used (TCP, UDP).

Domain Mandatory N/A This parameter specifies the name of the domain and it should be “local”.

Port Mandatory N/A This parameter specifies the port number used for communication (80 for HTTP).

80613ST10964A Rev. 5.0 179 2019-10-24

Page 180: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 173, page 180 describes the synchronous responses and remarks for the mDNS Services Registration command.

DefaultKey Mandatory

0, 1, 2Maximum length: 128 bytes

This parameter specifies the default service registered by Telit node. Use one of the following values:• 0: No services are registered by Telit node by

default. User can add services by adding “key=value” pair in Telit node’s Service registry which is detected in mDNS response of User’s application.

Note: If the user needs to develop their own Application, then set the Defaultkey =0 and provide applicable “key = value” pairs (one or more) in Telit node’s service registry.

DefaultKey (Contd.) Mandatory

0, 1, 2Maximum length: 128 bytes

• 1: Telit node is registered with Provisioning service by default and sends this service’s name (telit.html) to mobile application during mDNS discovery. Here the “key=value” pair registered in Telit node’s service registry is Provisioning=telit.html.

• 2: Telit node is registered with Over The Air Firmware Upgrade service by default and sends this service’s name (telit.html) to mobile application during mDNS discovery. Here the “key=value” pair registered in Telit node’s service registry is OTAFU=telit.html

<key1=value1>,<key2=value2>, ...<keyn=valuen> Optional NA

These parameters specify respective “key=value” pairs to be added in Telit node’s service registry. These parameters are used only when DefaultKey parameter is set to 0.

Table 172 mDNS Services Registration Parameters (Continued)

Parameter Optional/Mandatory

Value Description

Table 173 mDNS Services Registration Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUT

FailureCommand AT+MDNSSRVREG is issued. Before issuing AT+MDNSSTART (i.e, the node is not started with an MDNS module)

80613ST10964A Rev. 5.0 180 2019-10-24

Page 181: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Asynchronous Response

Table 174, page 181 describes the Asynchronous responses and remarks for the mDNS Services Registration command.

Example Use Case WL865E4-P node is configured with mDNS module with user specific “key=value” pairs.

Here - Default key is set to 0 (Number 0 indicates no service is registered with Telit node by default)

AT+MDNSSRVREG=prov,,_http,_tcp,local,80,0,SSID=TelitDemo,Channel=6//*Here, Key1=value1 parameter is SSID=TelitDemo and Key2=value2 parameter is Channel=6*//OK

Example Use Case Asynchronous response in TelitAT+MDNSSRVREG=GAINSPAN,,_http,_tcp,local,80,1,path=/telit.htmlOKRegistration Failed!! for RR:GAINSPAN

Table 174 mDNS Services Registration Asynchronous Responses

Responses RemarksOKRegistration Success!! for RR:<ServiceInstanceName>

SuccessPrior to issuing this command, the node should be started with a mDNS module.

OKRegistration Failed!! for RR:<ServiceInstanceName>

FailurePrior to issuing this command, the node should be started with a mDNS module.

80613ST10964A Rev. 5.0 181 2019-10-24

Page 182: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

10.1.2.5 mDNS Services De-registration

This command is used to de-register the services which are registered through AT+MDNSSRVDERREG.

Command Syntax AT+MDNSSRVDEREG=<ServiceInstanceName>,[<ServiceSubType>],<ServiceType>,<Protocol>,<Domain>

Parameter Description

Table 175, page 182 describes the mDNS Services De-Registration parameters.

Synchronous Response

Table 176, page 182 describes the synchronous responses and remarks for the mDNS Services De-Registration command.

Table 175 mDNS Services De-Registration Parameters

Parameter Optional/Mandatory Value Description

ServiceInstanceName Mandatory N/A ServiceInstanceName is the name of the service. It can take up to 256 characters.

ServiceSubType Mandatory N/A ServiceSubType is the name of the service subtype if any.

ServiceType Mandatory N/A ServiceType is the type of service, for example HTTP, FTP, etc.

Protocol Mandatory N/A Protocol is the protocol used (TCP, UDP).Domain Mandatory N/A Name of the domain. It should be “local”

Table 176 mDNS Services De-Registration Synchronous Responses

Responses Remarks

OK

SuccessPrior to issuing this command, the node should be registered with the mDNS service through AT+MDNSSRVREG.

ERROR:INVALID INPUTFailureInvalid parameters.

80613ST10964A Rev. 5.0 182 2019-10-24

Page 183: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+MDNSSRVDEREG=Prov,,_http,_tcp,localOK

10.1.2.6 mDNS Service Discover

This command is used to discover the mDNS services.

Command Syntax AT+MDNSSD=[<Servicesubtype>],<Servicetype>,<Protocol>,<Domain>

Parameter Description

Table 177, page 183 describes the mDNS Service Discover parameters.

Synchronous Response

Table 178, page 184 describes the synchronous responses and remarks for the mDNS Service Discover command.

Table 177 mDNS Service Discover Parameters

Parameter Optional/Mandatory Value Description

ServiceSubType Optional N/A ServiceSubType is the name of the service subtype if any.

ServiceType Optional N/A ServiceType is the type of service, for example HTTP, FTP, etc.

Protocol Mandatory N/A Protocol is the protocol used (TCP, UDP).Domain Mandatory N/A Name of the domain. It should be “local”

80613ST10964A Rev. 5.0 183 2019-10-24

Page 184: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Asynchronous Response

Table 179, page 184 describes the asynchronous responses and remarks for the mDNS Service Discover command.

Example 1 FAILURE:AT+MDNSSD=,_http,_tcp,localOKService Discovery FailedSUCCESS:AT+MDNSSD=,_http,_tcp,localOK

The service discovered in the above example is 2, there parameter indication is as below:Service instance name - 2

Table 178 mDNS Service Discover Synchronous Responses

Responses RemarksOKA Service Discovered: <No of service discovered>

Service Instance name= ProvService app protocol= _httpService protocol= _tcpService domain= localService IP address= <IP Address Port> = <Port>

Service Text Info= path=/<xxxx.html>

SuccessNote: Prior to issuing this command, the node should start the mDNS module and should register the services.

ERROR:INVALID INPUTFailureBefore issuing this command, the node has not started with the mDNS module.

Table 179 mDNS Service Discover Asynchronous Responses

Responses RemarksOK Success

OKService Discovery Failed

FailurePrior to issuing this command, the node should start the mDNS module and should register the services.

80613ST10964A Rev. 5.0 184 2019-10-24

Page 185: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Service application protocol =_httpService protocol =_tcpService domain =localservice IP address =192.168.136.133 Port =80

Example 2 AT+WM=0OKAT+WWPA=B9740249070OKAT+NDHCP=1OKAT+WA=GainSpan_Home IP SubNet Gateway 192.168.1.103:255.255.255.0:192.168.1.1OKAT+MDNSSTARTOKAT+MDNSSD=,_http,_tcp,localOK

A Service Discovered: 2

Service Instance name = ProvService app protocol = _httpService protocol = _tcpService domain = localService IP address = 192.168.1.101 Port = 80

Service Text Info = path=/concurrent.html

80613ST10964A Rev. 5.0 185 2019-10-24

Page 186: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

10.1.2.7 mDNS Module De-Initialization

This command is used to stop the mDNS module.

Command Syntax AT+MDNSSTOP

Synchronous Response

Table 180, page 186 describes the synchronous responses and remarks for the mDNS Module De-Initialization command.

Example AT+MDNSSTOPOK

10.1.2.8 Example for mDNS Commands

The following use case covers all the mDNS commands:AT+WA=TelitDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

AT+NDHCP=1IP SubNet Gateway192.168.23.101:255.255.255.0:192.168.23.1OK

AT+WEBPROV=admin,adminOK

AT+MDNSSTARTOK

AT+MDNSHNREG=Prov,localOK

Registration Success!for RR:Prov

Table 180 mDNS Module De-Initialization Synchronous Responses

Responses Remarks

OKSuccessPrior to issuing this command, the node should start the mDNS module.

ERRORFailureExecuting the command second time or more then once.

80613ST10964A Rev. 5.0 186 2019-10-24

Page 187: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AT+MDNSSRVREG=Provisioning,,_http,_tcp,local,80,0,path=/telit.htmlOK

Registration Success!!for RR: Provisioning

AT+MDNSHNDEREG=Prov,localOK

AT+MDNSSRVDEREG=Provision,,_http,_tcp,localOK

AT+MDNSSTOPOK

80613ST10964A Rev. 5.0 187 2019-10-24

Page 188: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

10.1.3 DNS Lookup (Client)This command is used to receive an IP address from a host name. Upon deployment of this command, the node queries the DNS server to obtain the IP address corresponding to the host name provided in URL, and returns the address if found or ERROR if the URL does not exist.

Command Syntax AT+DNSLOOKUP=<URL>,[<Retry count>,<Retry timeout>]

Command Note If the server does not respond or is not reachable, then the application retries for the specified number of times provided by the optional parameters <Retry count> and <Retry timeout> in the command. The retry count is addition to the first attempt.

Example AT+DNSLOOKUP=www.telit.com,2,5

Parameter Description

Table 181, page 188 describes the DNS Lookup (Client) parameters.

Table 181 DNS Lookup (Client) Parameters

Parameter Optional/Mandatory Value DescriptionURL Mandatory N/A URL is the host name to be identified.

Retry count Optional

1-10 range It is the number of times node retries to query the URL.This excludes the initial attempt of query.This is applicable for primary and secondary DNS.If value is not given or 0 is provided, then the default value is used.

3 (default)

Retry timeout Not Supported N/A Reserved for future use.Note: The value of Retry count * Retry timeout should be less than 90 seconds.

80613ST10964A Rev. 5.0 188 2019-10-24

Page 189: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 182, page 189 describes the synchronous responses and remarks for the DNS Lookup (Client) command.

The node returns 0 for OK, and 1 for ERROR if a valid command was issued, but DNS lookup failed (if verbose mode is disabled).

Example AT+NDHCP=1OK

AT+WA=telitDemo,,1ERROR

AT+WA=telitDemo,,11IP SubNet Gateway192.168.44.110:255.255.255.0:192.168.44.1OK

AT+DNCLOOKUP=www.telit.comIP:23.23.181.241OK

Table 182 DNS Lookup (Client) Synchronous Responses

Responses Remarks

IP:<ip address>OK

SuccessPrior to issuing this command the node should be associated to the network.

ERROR

FailureIf the node is not associated before issuing this command (Valid command is executed but DNS lookup fails).

ERROR:INVALID INPUTFailureIf valid command is not executed.

80613ST10964A Rev. 5.0 189 2019-10-24

Page 190: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

10.2 Application Features

10.2.1 Firmware UpdateFirmware upgrade module is used to upgrade/update the device firmware to its latest version. The firmware is present in two locations in the module: One in the current location and the other in the trial location.

When a firmware update occurs, by default the new firmware is written in the trial location. This firmware can be moved from the trial location to the current location by issuing either the firmware accept or firmware rollback command. Refer to section FWUP Rollback, page 192 & FWUP Accept, page 192 for details.

10.2.1.1 Over the Air Firmware Upgrade Using Module Flash

The following set of commands are used for performing an over the air firmware upgrade using pull method. This module uses the HTTP client to download the binaries form an HTTP server. AT+HTTPCONF command is used to configure any header(s) that need to be present in the HTTP GET request.

10.2.1.1.1 FWUP Configuration

This command is used to upgrade firmware via the wireless interface.

Command Syntax AT+SOTAFWUPCONF=<param>,<value>

Parameter Description

Table 183, page 190 gives the valid <param> and the description of the respective <value>.<value> is in string format.

NOTE: A new firmware upgrade cannot take place until the firmware present in trial location is either accepted or rejected.

Table 183 FWUP Configuration Parameter Values

Parameters Value0 Server IP address1 Server Port2 Proxy present (0 - Not Present / 1 - Present) (Not Supported)

3Proxy server IP (required only if Param 2 is equal to 1) (Not Supported)

80613ST10964A Rev. 5.0 190 2019-10-24

Page 191: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 184, page 191 describes the synchronous responses and remarks for the FWUP Configuration command.

4Proxy server Port (required only if Param 2 is equal to 1) (Not Supported)

5 SSL enabled (0 - Not Enabled / 1- Enabled)

6CA certification name (if it is already been added using the AT+TCERTADD command) (Not Supported)

7 E4-P module binary request URL8 Info URL (Not Supported)9 Server host name10 E4-P module signature binary request URL (Not Supported)

11

Values: 0 or 10: Disables domain name check on incoming certificate from server.1: Enables domain name check on incoming certificate from server.Note: • AT+SSLCONF (See Configure SSL, page 102) command should be

configured before enabling domain name check using this parameter.

12 Client certificate name (Not Supported)13 Client key certificate (Not Supported)

NOTE: In case of HTTP/S through Proxy, the request URL should be absolute path and not the relative path.

Table 183 FWUP Configuration Parameter Values

Parameters Value

Table 184 FWUP Configuration Synchronous Responses

Responses RemarksOK SuccessERROR:INVALID INPUT For invalid input

80613ST10964A Rev. 5.0 191 2019-10-24

Page 192: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

10.2.1.1.2 FWUP Start

This command is used to start upgrading the Firmware.

Command Syntax AT+SOTAFWUPSTART

Usage This command uses the header configured using AT+HTTPCONF command and other required parameters configured using the AT+SOTAFWUPCONF command, starts the http connection, downloads the new images, and starts updating the firmware.

Synchronous Response

Table 184, page 191 describes the synchronous responses and remarks for the FWUP Start command.

10.2.1.1.3 FWUP Accept

This command is used to accept the new firmware received through firmware upgrade module.

Command Syntax AT+SOTAFWUPACCEPT

Command Response On successful execution, this command validates the new firmware and prints the Serial to WiFi banner. On failure, it returns error.

Table 187, page 193 describes the synchronous responses and remarks for FWUP accept command.

10.2.1.1.4 FWUP Rollback

This command is used to rollback to the previous firmware version.

Command Syntax AT+SOTAFWUPROLLBACK

Command Response On successful execution, this command resets the system and prints the Serial to WiFi banner. On failure, it returns error.

Table 185 FWUP Start Synchronous Responses

Responses Remarks

APP Reset External Flash FW-UPSUCCESS

Success

ERROR For invalid input

Table 186 FWUP Rollback Synchronous Responses

Responses RemarksSerial2WiFi App Success

ERROR If the rollback to the previous firmware version fails.

80613ST10964A Rev. 5.0 192 2019-10-24

Page 193: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 187, page 193 describes the synchronous responses and remarks for FWUP rollback command.

10.2.2 ProvisioningTelit provisioning solution allows a device to be provisioned in limited AP and station mode.

It is completely secure where,

– Credentials are not seen over air

– Credentials including certificate key is encrypted and stored in flash.

Various provisioning methods supported are:

– Web Provisioning

10.2.2.1 Web Provisioning

10.2.2.1.1 Web Provisioning Start

This command is used to support provisioning through web pages.

Command Syntax AT+WEBPROV=<user name>,<password>[,SSL Enabled,Param StoreOption,idletimeout,ncmautoconnect,format version, dual interface]

Parameter Description

Table 188, page 194 describes the Web Provisioning Server Start parameters.

Table 187 FWUP Rollback Synchronous Responses

Responses RemarksSerial2WiFi App Success

ERROR If the rollback to the previous firmware version fails.

NOTE: It is recommended to use WPA2 personal security at WiFi layer.

80613ST10964A Rev. 5.0 193 2019-10-24

Page 194: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 188 Web Provisioning Server Start Parameters

Parameter Optional/Mandatory Value Description

user name Mandatory 1-16 characters

Any valid username in the range 1-16 characters for the web provisioning. The characters in a valid username can be any of the following:• Alphabets, numbers, alpha numeric, or special characters• Combination of alphabets, numbers, alpha numeric, and

special characters• Blank space

password Mandatory 1-16 characters

Any valid password in the range 1-16 characters for the web provisioning.The characters in a valid password can be any of the following:• Alphabets, numbers, alpha numeric, or special characters• Combination of alphabets, numbers, alpha numeric, and

special characters• Blank space

SSL Enabled Not Supported N/A Reserved for future use.

SSL Enabled (Contd)

The command to load the key certificate is:

AT+TCERTADD=SERVER_KEY,0,<keylength>,0<ESC>W<data of size key length>

The command to load root certificate is:

AT+TCERTADD=SSL_CA,<format>,<size>,<location>Note: “SSL_ “is prefixed while uploading the SSL server certificate through the web provisioning page or the browser. (<IP Address>/sslcert.html).

80613ST10964A Rev. 5.0 194 2019-10-24

Page 195: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

ParamStoreOption OptionalValue range: 0 - 2Default value: 0

This option selects the provisioned parameters’ store location.• 0 - For sending the provisioned information to the serial

interface (HOST). If secured provisioning is enabled in the binary, then provisioning information sent to the Host does not display the Limited AP’s passphrase. If secured provisioning is not enabled in the binary, then provisioning information sent to the Host displays the Limited AP’s passphrase.

Note: When a binary is built through SDK Builder, Secured provisioning is enabled by default under Miscellaneous tab. To disable Secured provisioning in binary, uncheck it under Miscellaneous tab before building the binary.If secured provisioning feature is enabled in the binary and provisioning is done from Limited-AP mode to Station mode with security, then the POST request from provisioning application to DUT will have Limited AP's passphrase field as blank and the provisioning information sent to the host does not display Limited-AP's passphrase. The field 'AP-PSK_PASS_PHRASE=' is blank. If secured provisioning feature is disabled in the binary, then the POST request and provisioning information sent to the host displays Limited-AP's passphrase in the field 'AP-PSK_PASS_PHRASE=<passphrase>'

• 1 - For storing the provisioned information in the WL865E4-P node profile.

• 2 - For performing both options above.

Table 188 Web Provisioning Server Start Parameters (Continued)

Parameter Optional/Mandatory Value Description

80613ST10964A Rev. 5.0 195 2019-10-24

Page 196: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

ParamStoreOption (Contd)

The provisioned information sent to the serial host:SSID=<ssid>CHNL=channel>CONN_TYPE=0 /*Not used*/MODE=0 /*Not used*/SECURITY=<security> (1-open, 2-wep, 3-wpa/wpa2 personal, 4-wpa/wpa2 enterprise)WEP_ID=<wepID>WEP_KEY=<wepkey>PSK_PASS_PHRASE=<pskPassPhrase>DHCP_ENBL=<0/1>STATIC_IP=<static IP address>SUBNT_MASK=<subnet Mask>GATEWAY_IP=<gateway>AUTO_DNS_ENBL=<0 /1>PRIMERY_DNS_IP=<primary DNS server IP>SECNDRY_DNS_IP<secondary DNS IP>AP-SSID=<ssid>AP-CHNL=<Channel>AP-BEACON-INTRL=<interval> (100-1600)AP-SECURITY=<security> (1-open, 2-wep, 3-wpa/wpa2 personal, 4-wpa/wpa2 enterprise)AP-PSK_PASS_PHRASE=<passphrase>AP-WEP-ID=<id> (1-4)AP-WEP-KEY=<wep key>AP- STATIC_IP=<static IP address>AP -SUBNT_MASK=<subnet Mask>AP- GATEWAY_IP=<gateway>AP-DHCPSRVR-ENABLE=<0/1>AP-DHCPSRVR-STARTIP=<IP>DHCPSRVR-NO-CONN=64AP-DNSSRVR-ENABLE=1AP-DNS-DOMAIN-NAME=<dns name>NEW_USER_NAME=<new User Name>NEW_PASS=<new Password>

Table 188 Web Provisioning Server Start Parameters (Continued)

Parameter Optional/Mandatory Value Description

80613ST10964A Rev. 5.0 196 2019-10-24

Page 197: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 189, page 197 describes the synchronous responses and remarks for Web Provisioning Start command.

ParamStoreOption (Contd)

The following fields are printed when format version is set to 1:WEP_AUTH_MODE=<Mode Value (1,2)> Where 1- open, 2- shared)

AP-WEP_AUTH_MODE=<Mode Value (0)> Where 0 - open

idletimeout Not Supported N/A Reserved for future use.

ncmautoconnect Optional0, 10 (default)

0 - Do not start the NCM1 - Start the NCM after storing the parameters

format version Not Supported N/A Reserved for future use.dual interface Not Supported N/A Reserved for future use.

Table 188 Web Provisioning Server Start Parameters (Continued)

Parameter Optional/Mandatory Value Description

Table 189 Web Provisioning Start Synchronous Responses

Responses RemarksOK SuccessERROR: INVALID INPUT If parameters are not valid.

80613ST10964A Rev. 5.0 197 2019-10-24

Page 198: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example 1 AT+NSET=192.168.17.111,255.255.255.0,192.168.17.1OK

AT+WM=2OK

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.17.111:255.255.255.0:192.168.17.1OK

AT+DHCPSRVR=1OK

AT+WEBPROV=admin,admin,,1,,1OK

Prior to issuing this command the WL865E4-P node should be in limited AP network with a valid IP address. Upon reception of this command the WL865E4-P node starts a web server.

Once the WL865E4-P node returns the success response (“OK”), the user can open provisioning webpage on the PC or browser and also access provisioning applications on android and IOS devices with the IP address of the WL865E4-P node and the HTTP client application (e.g. Internet Explorer).

If the WL865E4-P node is configured as limited AP, the DHCP and DNS server should be started prior to issuing this command. Once the WL865E4-P node returns the success response (“OK”), the user can open a web page on the PC or smart phone that is connected to the limited AP.

User can configure both L2 and L3 level information on the provisioning application (browser, android and IOS devices). Submit button stores all the configured information in the WL865E4-P node and logout/boot button presents all provisioned information to the serial host and resets the WL865E4-P node.

80613ST10964A Rev. 5.0 198 2019-10-24

Page 199: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example 2 AT+NDHCP=1OK

AT+WA=AE_GAINSPANIP SubNet Gateway192.168.75.1:255.255.255.0:192.168.75.1OK

AT+WEBPROV=ADMIN,ADMINOK

Example 3 To demonstrate web provisioning along with reset message, execute the following sequence of commands:

AT+NSET=192.168.2.1,255.255.255.0,192.168.2.1OK

AT+WM=2OK

AT+WA=WIFIAPTEST

IP SubNet Gateway192.168.2.1:255.255.255.0:192.168.2.1OK

AT+DHCPSRVR=1OK

Start web server for provisioning.AT+WEBPROV=admin,admin,,2,,1

Provision the node (http:// 192.168.2.1/telit.html) to connect with standard access point in CLIENT mode.

SSID=GSDemoKitCHNL=6CONN_TYPE=0MODE=0SECURITY=1DHCP_ENBL=1AP-SSID=CUMULUSAP-CHNL=6AP-BEACON-INTRL=100AP-SECURITY=3AP-PSK_PASS_PHRASE=12345678AP-STATIC_IP=192.168.8.1AP-SUBNT_MASK=255.255.255.0AP-GATEWAY_IP=192.168.8.1AP-DHCPSRVR-ENABLE=1

80613ST10964A Rev. 5.0 199 2019-10-24

Page 200: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AP-AP-DHCPSRVR-STARTIP=192.168.8.2AP-DHCPSRVR-NO-CONN=8AP-DNSSRVR-ENABLE=1AP-DNS-DOMAIN-NAME=paymentexpress.com

APP Reset-APP SW Reset

IP SubNet Gateway192.168.66.101:255.255.255.0:192.168.66.1NWCONN-SUCCESS

Connected to provisioned network without any user intervention.

10.2.2.1.2 Web Provisioning Stop

This command is used to stop Web provisioning. This command is typically done at the manufacturing line in the factory. This command can be done only once. There is no command to delete the Logo.

Command Syntax AT+WEBPROVSTOP

Synchronous Response

Table 190, page 200 describes the synchronous responses and remarks for Web Provisioning Stop command.

10.2.2.1.3 Web Provisioning Status

This command is used to output the current status (started or stopped) of the web provisioning and display the URIs registered.

Command Syntax AT+WEBPROV=?

URIs registered by default are as follows:

• URI:sys/cfg/net

• URI:sys/fw/ver

• URI:sys/prov/ap_list

• URI:sys/api/ver

• URI:sys/cap

Table 190 Web Provisioning Stop Synchronous Responses

Responses RemarksOK Success

ERRORIf command is issued without starting web provisioning using AT+WEBPROV command.

80613ST10964A Rev. 5.0 200 2019-10-24

Page 201: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

• URI:sys/cfg/httpd

• URI:sys/cfg/id

• URI:sys/prov/otafu

Synchronous Response

Table 191, page 201 describes the synchronous responses and remarks for the Web Provisioning status command.

Table 191 Web Provisioning Status Synchronous Responses

Responses RemarksWebprov StartedURI:sys/cfg/netURI:sys/fw/verURI:sys/prov/ap_listURI:sys/api/verURI:sys/capURI:sys/cfg/httpdURI:sys/cfg/idURI:sys/prov/otafuOKWebprov StoppedOK

Success

ERROR: INVALID INPUT If parameter is not valid.

80613ST10964A Rev. 5.0 201 2019-10-24

Page 202: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

11 Power Management - Radio and System

This chapter describes the commands for configurations and operations related to power management for radio and system.

• Radio Receiver Setting, page 202

11.1 Radio Receiver Setting

11.1.1 Active Radio ReceiveThis command is used to enable/disable the 802.11 radio receiver. This minimizes latency and ensures that packets are received at the cost of increased power consumption. The Power Save mode (see Custom Power Save Radio Receive, page 206) can be enabled but will not save power, since the receiver is left on.

Command Syntax AT+WRXACTIVE=n

Parameter Description

Table 192, page 202 describes the Enable/Disable 802.11 Radio parameters.

Synchronous Response

Table 193, page 202 describes the synchronous responses and remarks for the Enable/Disable 802.11 Radio command.

Table 192 Enable/Disable 802.11 Radio Parameters

Parameter Optional/Mandatory Value Description

n Mandatory0 (default) 802.11 radio receiver is OFF1 802.11 radio receiver is always ON

Table 193 Enable/Disable 802.11 Radio Synchronous Responses

Responses RemarksOK Success

ERROR: INVALID INPUTInvalid parameter(If n value is other than 0 or 1)

NOTE: The number of times radio is enabled using AT+WRXACTIVE, that many times has to be disabled.

80613ST10964A Rev. 5.0 202 2019-10-24

Page 203: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example AT+WRXACTIVE=1OK

AT+WRXACTIVE=1OK

AT+WRXACTIVE=0OK

AT+WRXACTIVE=0OK

Example Use Case 1 Radio receiver is always on, Power Save mode is enabled but will not save power since the receiver is left on.

AT+WRXACTIVE=1OK

AT+WRXPS=1OK

Example Use Case 2 The receiver is switched off. The node will not receive any packets at this time.AT+WRXACTIVE=0OK

AT+WRXPS=0OK

11.1.2 Standard Power Save Radio Receive based on DTIM/Listen Interval

11.1.2.1 IEEE PS Poll Listen Interval

This command is issued once to configure the mode (DTIM based wakeup, Listen interval based wake up or Custom wake up) and then to enable the configuration (in commands issued when configured for listen interval based wakeup). Configuration is to be issued only once and then enable/disable can be done at run time to control radio.

Command Syntax AT+WIEEEPSPOLL=<enable>[,listenInterval][,wakeupType][,wakeupInterval][,BeaconWaitTimeout][,DataRxType][,ActiveToOffTimeout][,SwitchToActivePeriod]

Command Note The radio of the STA for Telit node can be controlled using three AT commands;

• AT+WRXACTIVE,

• AT+WRXPS

• AT+WIEEEPSPOLL.

80613ST10964A Rev. 5.0 203 2019-10-24

Page 204: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Parameter Description

Table 194, page 204 describes the IEEE PS Poll Listen Interval parameters.

Example - AT+WRXACTIVE

If AT+WRXACTIVE = 1, then the radio is always ON. No power save is done in this case. Regardless of what the parameters for the other two commands are, the radio will receive all the packets. Rest of the commands are “Don’t Care.”

Example - AT+WRXPS

If AT+WRXPS = 1, Regardless of what the parameters for AT+WIEEEPSPOLL are, the STA will wake up for every beacon. AT+WIEEEPSPOLL is a “Don’t Care” in this case.

If AT+WRXPS = 0, the STA will not wake up for every beacon. Based on the AT+WIEEEPSPOLL, the wake will be decided as explained further.

Example - AT+WIEEEPSPOLL

This command can be used for three purposes:

– To configure the Power Save behavior

NOTE: 1).NCM with PS-Poll is does not support web provisioning (web page related) features.

Table 194 IEEE PS Poll Listen Interval Parameters

Parameter Optional/Mandatory Value Description

enable Mandatory

0 Disable IEEE PS

1 Enable IEEE PS (wakeupType tells whether DTIM or Listen interval)

2 Configure IEEE PSNote: Enable/disable is used run-time to control radio while remaining parameters will be used only for configuration when required. If configuration is not specified, last configuration will be used.listenInterval Not Supported N/A Reserved for future use.WakeupType Optional 0 DTIM based wakeupwakeupInterval Not Supported N/A Reserved for future use.BeaconWaitTimeout Not Supported N/A Reserved for future use.DataRxType Not Supported N/A Reserved for future use.

ActiveToOffTimeout Optional N/A

Time to be in active radio state if DataRxType is switched to active mode. Time is extended whenever a frame is received and radio state is turned off after timeout. A null frame is sent to AP to indicate transition to doze state.

SwitchToActivePeriod Not Supported N/A Reserved for future use.

Note: All the Optional parameters need to configured with their default values.

80613ST10964A Rev. 5.0 204 2019-10-24

Page 205: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

– To Enable the Power Save

– To Disable the Power Save

Usage - Configuration of Power Save

To configure the Power Save behavior on the STA, the first parameter of the command should be 2. The STA can be configured in 3 ways:

– Wake up for Listen Interval

– Wake up for DTIM

– Wake up for a custom number of beacons

Wake up for Listen Interval

To configure the STA to wake up for the listen interval, the command is AT+WIEEEPSPOLL=2,10,1. This means that the STA will advertise in the Association Request that the listen interval will be for every 10 beacons. Once associated, the STA will wake up for every 10 beacons.

Wake up for DTIM To configure the STA to wake up for every DTIM interval, the command is AT+WIEEEPSPOLL=2,,0. Here we did not specify the listen interval as that will be the default. In this case, the STA will advertise the default Listen Interval in the Association Request. Once associated, the STA will wake up for every DTIM interval that has been configured on the AP.

Custom Wake up To configure the STA to wake up at a custom interval, the command is AT+WIEEEPSPOLL=2,,2,5. Here also, we did not specify the listen interval, that will be the default. The STA will advertise the default Listen Interval in the Association Request. Once associated, the STA will wake up for every 5 beacons.

Difference between Listen Interval based Wake up Versus Custom Wake up

At the outset, both of these options do the same thing - to wake the STA based on the number of beacons given.

Either of these options can be used to wake the STA. However, the use case is as follows:

Example Use Case Whenever the STA is needed to wake up at some configured interval, the Custom Wake up option should be used. While configuring the custom wake up parameters, the listen interval should not be entered; the default listen interval will be used in the association request. Usually, in the association request, the STA will advertise the listen interval as a large value (e.g., 10 beacons). The configuration of the custom wake up interval will be less than the listen interval (e.g., 5 beacons). In this case, the STA bluffs to the AP while associating telling that it will wake up for every 10 beacons. But, in reality, it will wake up for every 5 beacons. This is just to ensure that the AP shouldn’t drop the buffered frames in case the PS Poll request from the STA does not reach the AP.

Enable Power Save To enable the power save on the STA, the command is AT+WIEEEPSPOLL=1. Whenever AT+WIEEEPSPOLL is given as 1, the STA will take the last power save configuration into effect. So, the user should first configure the behavior and then enable the power save.

Disable Power Save To disable the power save on the STA, the command is AT+WIEEEPSPOLL=0. When this command is executed, the radio is fully off. Order of Precedence between commands - WRXACTIVE > WRXPS > WIEEEPSPOLL.

80613ST10964A Rev. 5.0 205 2019-10-24

Page 206: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Command Note If the power save behavior is changed after the association is done, the new changes will take into effect only for the next association.

11.1.3 Custom Power Save Radio ReceiveThis command is used to enter Power Save Mode. Once enabled, radio will be switched off (after informing AP) when ever possible (e.g., in between beacons intervals, when there is no data transmission). Since module inform AP about its inactivity, AP shall buffer all the incoming unicast traffic during this time.

Command Syntax AT+WRXPS=n

Parameter Description

Table 195, page 206 describes the Enable/Disable 802.11 Power Save Mode parameters.

Synchronous Response

Table 196, page 206 describes the synchronous responses and remarks for the Enable/Disable 802.11 Power Save Mode command.

Example AT+WRXACTIVE=0OK

AT+WRXPS=1OK

Prior to issuing this command the radio should be off (AT+WRXACTIVE=0), otherwise there is no effect of power save, if radio receiver is on.

In this case the node will inform the Access Point that it will go to sleep, and the Access Point will buffer any packets addresses to that node. The node will awaken to listen to periodic beacons from the Access Point that contains a Traffic Indication Map (TIM) that

NOTE: Refer to the AT+WIEEEPSPOLL command for 802.11 power save mode.

Table 195 Enable/Disable 802.11 Power Save Mode Parameters

Parameter Optional/Mandatory Value Description

n Mandatory0 Power Save mode is disabled1 (default) Power Save mode is enabled

Table 196 Enable/Disable 802.11 Power Save Mode Synchronous Responses

Responses RemarksOK Success

ERROR:INVALID INPUTIf parameters are not valid(If n value is other than 0 or 1)

80613ST10964A Rev. 5.0 206 2019-10-24

Page 207: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

will inform the Station if packets are waiting for it. Buffered packets can be retrieved at that time, using PSPoll commands sent by the node. In this fashion, power consumed by the radio is reduced (although the benefit obtained depends on traffic load and beacon timing), at the cost of some latency. The latency encountered depends in part on the timing of beacons, set by the Access Point configuration. Many Access Points default to 100msec between beacons; in most cases this parameter can be adjusted.

80613ST10964A Rev. 5.0 207 2019-10-24

Page 208: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

12 Production and Debug

This chapter describes commands for configurations and operations used in Production and helpful in debugging.

• Debug, page 208

12.1 Debug

12.1.1 Log LevelThis command is used to configure the debug level so that the response of a command will include more information (error reason) in case of an error.

Command Syntax AT+LOGLVL=<level>

Command Note This command can also be used for domain check as well. However, th

Parameter Description

Table 197, page 208 describes the Error Code parameters.

Synchronous Response

NOTE: The log prints are not compatible with the GS2K log prints.

Table 197 Error Code Parameters

Parameter Optional/Mandatory Value Description

level Mandatory

0 (Default) No error code or warning message along with the command response.

1 Error code or warning message along with the command response.

2

It gives additional information with Error code or warning message along with the command response.If the domain name feature is enabled the node displays buffer content which contains alternate names (domain names) provided in the incoming server certificate.

80613ST10964A Rev. 5.0 208 2019-10-24

Page 209: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 198, page 209 describes the synchronous responses and remarks for the Error Code command.

Example - AT+LOGLVL=1OKAT+WA=GSDEMOSSID NOT FOUNDERROR

12.1.2 Echo

This command is used to enable or disable the echo back to host (MCU).

Command Syntax ATEn

Parameter Description

Table 199, page 209 describes the Echo parameters.

Table 198 Error Code Synchronous Responses

Responses RemarksOK SuccessERROR Failure

NOTE: This command is applicable for all the AT Commands, but not to their Responses.

Table 199 Echo Parameters

Parameter Value Description

n

0 Disabled

1 (default)EnabledIf echo is enabled, every character received from host (MCU) is transmitted back to host.

Note: When Echo command is enabled, ensure that:• Host sends either “\r” or “\n” after any AT Command, as all the commands are passed after

receiving either “\r” or “\n” only.• Host should not send any “\r” or “\n” after sending data (bulk data or any data) using ESC

sequence.Example: Send only AT+CID=?\rDo not send AT+CID=?\r\n

80613ST10964A Rev. 5.0 209 2019-10-24

Page 210: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Synchronous Response

Table 200, page 210 describes the synchronous responses and remarks for the Echo command.

12.1.3 VerboseThis command is used to enable or disable verbose mode for synchronous and asynchronous responses.

Command Syntax ATVn

Parameter Description

Table 201, page 210 describes the Verbose parameters.

Synchronous Response

Table 202, page 210 describes the synchronous responses and remarks for the Verbose command.

Table 200 Echo Synchronous Responses

Synchronous Responses RemarksOK SuccessERROR: INVALID INPUT If parameters are not valid.

Table 201 Verbose Parameters

Parameter Value Description

n

0

Verbose response is disabled, the status response is in the form of numerical codes.For more information about the numerical codes when Verbose is disabled.

1 (default)EnabledVerbose responses are enabled. The status response is in the form of ASCII strings.

Table 202 Verbose Synchronous Responses

Responses RemarksOK Success

ERROR: INVALID INPUTIf parameters are not valid.(n other than 0 or 1)

80613ST10964A Rev. 5.0 210 2019-10-24

Page 211: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

12.1.4 RSSIThis command is used to get information regarding the received signal strength of the incoming packets in dBm. All incoming management and data frames are considered.

Command Syntax AT+WRSSI=?

Synchronous Response

Table 203, page 211 describes the synchronous responses and remarks for the Get RSSI command.

Example AT+WRSSI=?-33OK

12.1.5 WLAN StatusThis command is used to retrieve information about the current wireless status.

Command Syntax AT+WSTATUS

Synchronous Response

Table 204, page 211 describes the synchronous responses and remarks for the alternate Status command.

Table 203 Get RSSI Synchronous Responses

Responses RemarksRSSIOK

Success

Table 204 Alternate Status Synchronous Responses

Responses Remarks

MODE:<mode> CHANNEL:<channel> SSID:<ssid>BSSID:<bssid> SECURITY:<security>OK

SuccessThe Telit node reports the current network configuration to the serial host:• Mode• Channel• SSID• BSSID• Security

NOT ASSOCIATEDOK

If module is not associated with an access point.

80613ST10964A Rev. 5.0 211 2019-10-24

Page 212: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example 1 - Not associated state

AT+WSTATUSNOT ASSOCIATEDOK

Example 2 - Associated state

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

AT+WSTATUSMODE:0CHANNEL:11 SSID:”TelitDemo”BSSID:98:fc:11:4a:b8:56SECURITY:NONEOK

12.1.6 Network StatusThis command is used to retrieve information about the current network status.

Command Syntax AT+NSTAT=?

Synchronous Response

Table 205, page 213 describes the synchronous responses and remarks for the Status command.

80613ST10964A Rev. 5.0 212 2019-10-24

Page 213: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Alternate Command AT+WSTATUS

This alternate command is used to retrieve information about the current wireless status.

Synchronous Response

Table 204, page 211 describes the synchronous responses and remarks for the alternate Status command.

Table 205 Status Synchronous Responses

Responses Remarks

MAC=00:1d:c9:d0:70:ccWSTATE=CONNECTED MODE=APBSSID=c8:d7:19:75:74:fbSSID="TelitDemo" CHANNEL=11 SECURITY=NONERSSI=-32IP addr=192.168.1.99 SubNet=255.255.255.0 Gateway=192.168.1.1DNS1=0.0.0.0 DNS2=0.0.0.0Rx Count=22 Tx Count=75090OK

• Success• Upon deployment of this command, the

WL865E4-P node reports the current network configuration to the serial host:

• MAC address• WLAN state: CONNECTED or NOT

CONNECTED• Mode: STA, LAP, NONE• BSSID: In case of STA mode, it specifies the MAC address of the connected AP.In case of LAP mode, it specifies the MAC address of the module itself.• SSID:In case of STA mode, it specifies the SSID of the connected AP.In case of LAP mode, it specifies the SSID of the module itself.• Channel: 1 to 11• Security: NONE, WPA2-PERSONAL,

WPA-PERSONAL, WPA2-ENTERPRISE (only for Station mode)

• RSSI: It is the Received signal strength indication. The range will be in db.

• Network configuration: IP Address, Subnet mask, Gateway address, DNS1 address, DNS2 address

• RX count: Packets received by WLAN• TX count: Packets transferred by WLAN

80613ST10964A Rev. 5.0 213 2019-10-24

Page 214: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Example 1 - Not associated state

AT+WSTATUSNOT ASSOCIATEDOK

Example 2 - Associated state

AT+WA=TelitDemo,,11IP SubNet Gateway192.168.1.99:255.255.255.0:192.168.1.1OK

AT+WSTATUSMODE:0CHANNEL:11 SSID:”TelitDemo”BSSID:98:fc:11:4a:b8:56SECURITY:NONEOK

Table 206 Alternate Status Synchronous Responses

Responses Remarks

MODE:<mode> CHANNEL:<channel> SSID:<ssid>BSSID:<bssid> SECURITY:<security>OK

SuccessThe WL865E4-P node reports the current network configuration to the serial host:• Mode• Channel• SSID• BSSID• Security

NOT ASSOCIATEDOK

If module is not associated with an access point.

80613ST10964A Rev. 5.0 214 2019-10-24

Page 215: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

13 Appendix A - AT Commands Summary

This appendix provides a list of supported Serial-to-WiFi Adapter commands.

The following sections are covered in this appendix:

• Host Interaction, page 215

• General Operations, page 216

• Wireless, page 217

• Network, page 220

• Data Transfer, page 221

• Power Management - Radio and System, page 228

• Production and Debug, page 229

• Default Return Messages, page 230

• Escape Sequence Commands, page 231

13.1 Host InteractionTable 207, page 215 lists the Host Interaction AT commands.

Table 207 Host Interaction AT Supported Commands

Command Parameters Response / Effect

AT&Knn=0n=1

Enable or disable software flow control for the UART interface.

AT&Rnn=0 (disable)n=1 (enable)

IF 1, hardware flow control is enabled

AT None “OK”AT? None No Longer Supported

80613ST10964A Rev. 5.0 215 2019-10-24

Page 216: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

13.2 General OperationsTable 208, page 216 lists the General Operation interface AT commands.

Table 208 General Operations AT Supported Commands

Command Parameters Response / Effect

AT+VER ? Returns the current adapter firmware versions.

AT+VER ?? Gives more details of the S2W version.

AT+SETTIME<dd/mm/yyy><HH:MM:SS>

Sets the adapter system time.

AT+GETTIME ?

Provides the current system time followed by the standard command response to the serial interface.

The time format comes on the serial interface as follows:=<dd/mm/yyyy>,<HH:MM:SS>,System time in milliseconds since epoch (1970).

AT&V None Current and saved profile parameter values as ASCII.

AT&Wn (see Note 1)n=0 (profile 0)n=1 (profile 1)

Save profile specified by n.

ATZnn=0 (profile 0)n=1 (profile 1)

Load profile specified by n.

AT&Yn (see Note 1)n=0 (profile 0)n=1 (profile 1)

Set default profile to the value n.

AT&F None Restore profile to factory default values.

ATIn n=value

Various Adapter ID information:• 0=OEM ID• 1=Hardware Version• 2=Software Version

AT+CIDCONF <CID>,<n>,<Configuration ID>,<Configuration value>

It enables or disables Nagle timer on a CID.

AT+NMAC ? Returns the current adapter MAC address.

80613ST10964A Rev. 5.0 216 2019-10-24

Page 217: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

13.3 WirelessTable 209, page 217 lists the Wireless AT commands.

Table 209 Wireless AT Supported Commands

Command Parameters Response / Effect

AT+WREGDOMAIN <Regulatory Domain>

• FCC-supported channel range is 1 to 11.

• ETSI-supported channel range is 1 to 13.

• TELEC-supported channel range is 1 to 14.

AT+WREDOMAIN ? Outputs the configured regulatory domain in the Serial-to-WiFi adapter.

AT+WM

n[, beacon interval, disable braodcast ssid, pre scan] n[,<beacon interval in AP mode>,<broadcast ssid in AP mode>,<no. of stations allowed in AP mode>,<dtim period in AP mode>,<inactivity timeout in AP mode>,<group key renewal interval in AP mode>,<Device type>,<Minimum application throughput>]

0 - station mode2 - limited AP3 - P2P5 - ISOTX

Set 802.11 Station operating mode.

If n is 3, the mode is set to P2P.

AT+WRATE

value <Transmit rate of data frame>[,<Transmit rate of management frame>,<Transmit rate of control frame>]

Sets the transmit rate

AT+WRATE ? Obtain the current transmit rate (in ASCII format) of the data frame.

AT+WSEC

• 0 - Auto security (All)• 1 - Open security• 2 - WEP security• 4 - WPA-PSK security• 8 - WPA2-PSK security• 16 - WPA Enterprise• 32 - WPA2 Enterprise

The S2W adapter supports either one of the values with default security configuration as “Auto.” This strict security compliance is not applicable for the WPS feature.

80613ST10964A Rev. 5.0 217 2019-10-24

Page 218: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

AT+WS [<SSID[,<BSSID>][,<Channel>][,<ScanTime]]

Network scan, returns list of found networks in the format:

<SSID>,<BSSID>,<Channel>,<RSSI>,<Mode>,<Security>

SSID may be a string of up to 32 ASCII characters in length.

AT+WPHYMODE

phymodNote: Where phymode is one of the following: 0,1,2,3,6• 0 - 802.11b only• 1 - 802.11g only• 2 - 802.11b/g only (not supported)• 3 - 802.11b/g/n (not supported)• 6 - 802.11n only

Configure 802.11 modes.

AT+WPHYMODE

phymod• 1 - 802.11b only• 2 - 802.11b/g/n (not supported)• 3 - 802.11g only (not supported)

Configure 802.11 modes.

AT+WPHYMODE ?

Will return one of these values:• 1=802.11b only• 2=802.11b/g/n• 3=802.11g only

AT+WPHYMODE n

Will return one of these values:• 0 - 802.11b only• 1 - 802.11g only• 2 - 802.11b/g only• 3 - 802.11b/g/n • 6 - 802.11n only

AT+WA

<SSID>,[,[<BSSID>][,<Ch>],[Rssi Flag],[WPS Registrar],[Unscheduled automatic power save delivery configuration]]

Associate to specified SSID, BSSID, and channel. RSSI is an optional parameter with values:• 1 - associate to the AP specified by

SSID with highest RSSI value.• 0 - associate to the AP specified by

SSID without considering RSSI value. This is the default settings.

AT+WD None Disassociate from the current network.

Table 209 Wireless AT Supported Commands (Continued)

Command Parameters Response / Effect

80613ST10964A Rev. 5.0 218 2019-10-24

Page 219: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Note 1: The AT+WWEPn command specifies the Key to be used for Key number n of the WEP security to connect to an AP. APs can use 1 of 4 WEP keys (key 1 through 4).

AT+WST <Min >,<Reserved><Max scan time><CR>

Min is the minimum per channel.Max scan time is the maximum scan time per channel. The Max scan time should always be greater than or equal to Min scan time. Both parameters are in milliseconds.This command also modifies the configured with the ATS5 command.

AT+WST ? Displays minimum and maximum in milliseconds.

AT+WPHYMODE

phymodNote: Where phymode is one of the following: 0,1,2,3,6• 0 - 802.11b only• 1 - 802.11g only• 2 - 802.11b/g only (default)• 3 - 802.11b/g/n • 6 - 802.11n only

Configure 802.11 modes.

AT+WPHYMODE

phymod• 1 - 802.11b only• 2 - 802.11b/g/n • 3 - 802.11g only

Configure 802.11 modes.

AT+WPHYMODE ?

Will return one of these values:• 1=802.11b only• 2=802.11b/g/n• 3=802.11g only

AT+WWEPn (see Note 1 below) n=1 to 4, <key> WEP key n is set to the value in <key>.

AT+WWPA <passphrase> WPA passphrase set to the value in <passphrase>.

AT+WPAPSK <SSID>,<passphrase> Computes and stores the WPA2 PSK value.

AT+WPSK <PSK> Sets the WPA2 pre-shared key to the <PSK>.

AT+APCLIENTINFO ?Get the information about the clients associated to the adapter when it acts as a limited AP.

Table 209 Wireless AT Supported Commands (Continued)

Command Parameters Response / Effect

80613ST10964A Rev. 5.0 219 2019-10-24

Page 220: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

For example,

If setting Key 1, the command would be:

AT+WWEP1=<key>

If setting Key 2, the command would be:

AT+WWEP2=<key>

13.4 NetworkTable 210, page 220 lists the Network AT commands.

Table 210 Network AT Supported Commands

Command Parameters Response / Effect

AT+L2CONFIG <Protocol>,<Enable/Disable> Configures the parameter bit wise.

AT+L2CONFIG ? Gives the configured current network interface filter.

AT+NDHCP n[,<hostname>,<radio mode>,<lease period>,<retry interval>]

Enable or disable DHCP client support for IPV4 parameters.

AT+NSET <Src Address>,<Net-mask>,<Gateway> Static network parameters overrides previous values.

AT+DHCPSRVR <Start/Stop[,<Dns Option Disable>,<Gateway Option Disable>]

Prior to start the server, the adapter should be configured with a valid static IP address.

Start/Stop: 1 is for starting the server and 0 is for stopping the server.

Dns Option Disable: 1 is for disabling and 0 is for enabling with enable as default setting.

Gateway Option Disable: 1 is for disabling and 0 is for enabling with enable as default setting.

AT+DHCPSRVRCFG

AT+DNSn,<url>n=0 (disable)n=1 (enable)

URL is the DNS name associated to the DNS IP address.

AT+DNSSET <DNS1 IP>,<DNS2 IP>] Sets the DNS server addresses to be used.

80613ST10964A Rev. 5.0 220 2019-10-24

Page 221: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

13.5 Data TransferTable 211, page 221 lists the Data Transfer AT commands.

Table 211 Data Transfer AT Supported Commands

Command Parameters Response / Effect

AT+BDATA• 1 - Enable• 0 - Disable

Enables or disables bulk data.

AT+CID ? Returns the current CID configuration.

AT+NCLOSE <CID> Close connection identified by CID.

AT+NCLOSEALL None Closes all open connections.

AT+NXSETSOCKOPT <Cid>,<Type>,<Parameter>,<Value>,<Length>

Configures a socket which is identified by a CID.

AT+TCERTADD<Name>,<Format>,<Size>,<Location><CR><ESC>W<data of size above>

Configures the certificate for SSL/HTTPS and EAP/TLS

AT+TCERTDEL <certificate name> Deletes a certificate from memory.

AT+NCMAUTO <Mode>,<Start/Stop>[,Level],[<Nvds storeflag>]

Start/Stop the network connection manager

AT+NCMAUTOCONF <Conf Id>,<Value> Configures the NCM parameters for its state machine

AT+NCMAUTO?/?? Gives the status or the profile

information of network connection manager.

AT+APCONFEnable: 1 is for limited AP mode and 0 is for station mode, with default value as 0.

NCMAP parameters can be configured using the auto connect.

AT+NCMAUTOCONF <Param ID>,<Param Value>

80613ST10964A Rev. 5.0 221 2019-10-24

Page 222: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 212, page 222 lists the Auto Mode AT commands.

Table 212 Auto Mode AT Supported Commands

Command Parameters Response / Effect

AT+WAUTO <mode>,<SSID>,<BSSID>,[channel]

Sets WiFi parameters to be used for Auto Connect.

AT+NAUTO <Type>,<Protocol>,<Destination IP>,<Destination Port>

Sets network parameters to be used for Auto Connect.

ATCnn=0 (disable)n=1 (enable)

IF 1, Auto Connect is enabled on next reboot or AT.

Table 213 Data Transfer AT Supported Commands

Command Parameters Response / Effect

AT+NCTCP <Dest-Address>,<Port>Attempts TCP client connection to Destination; CONNECT<CID> if successful.

AT+NCUDP <Dest-Address>,<Port>[<,Src.Port>]

Open UDP client socket to Destination; CONNECT<CID> if successful. The port range 0xBAC0 to 0XBACF may not be used.

AT+NSTCP<Port>, [max client connection],<TCP window size>

Start a TCP server on Port; CONNECT<CID> if successful.

AT+NSUDP <Port>

UDP server on Port; CONNECT<CID> if successful. The port range 0xBAC0 to 0xBACF may not be used.

AT+SSLCONF <enum>,<value>

Configures size of the SSL buffer and specify the number of DNS entries that can be copied into SSL certificate’s buffer.

AT+SSLOPEN<cid>,[<certificate name>,<client certificate name>,<client key name>]

Opens an SSL connection.

AT+SSLCLOSE <CID> Closes an SSL connection.

80613ST10964A Rev. 5.0 222 2019-10-24

Page 223: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 214, page 223 lists the HTTP AT commands.

Table 214 HTTP AT Supported Commands

Command Parameters Response / EffectAT+HTTPCONF <Param>,<Value> Configures an HTTP client

AT+HTTPCONFDEL <Param>The adapter removes the HTTP configuration specified by the param.

AT+HTTPOPEN

<host>,<Port Number>,[<SSL Flag>,<Certificate Name>,<Proxy>,<Connection Timeout>,<ClientCertificateName>,<ClientKeyName>]

Opens an HTTP client connection. This command opens an HTTP client on the adapter and connects the server specified by the host name or IP address.

AT+HTTPRECVCONF <cid>,<send status line>,<send HTTP response headers>

Configures for receiving HTTP response headers and response status line coming from HTTP server.

AT+HTTPSEND

<cid>,<Type>,<Timeout>,<Page>,<Size of data>,[<Send response status line>,<Send response headers count>]

GET/POST HTTP data on the HTTP client connection.

AT+HTTPCLOSE <CID> Closes the HTTP client connection.

80613ST10964A Rev. 5.0 223 2019-10-24

Page 224: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 215, page 224 lists the GSLink XML Parser AT commands.

Table 215 GSLink XML Parser AT Supported Commands

Command Parameters Response / Effect

AT+XMLPARSE n:Enable/Disable XML parsingThis command enables/disables xml parsing.

AT+XMLSEND

<CID>,<Type>,<Timeout>,<PageURI>,<Roottagname>[,<N>],<Send response status line>,<Send response headers count> <ESC>G<CID><len><tagname>:<value>

XML Data Send

AT+URIRECV

<URI>[,content Type,<Send CGI arguments>,<Send request line>,<Send HTTPD Headers>]

Modify the default adapter URI to the new one.

80613ST10964A Rev. 5.0 224 2019-10-24

Page 225: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

13.6 Advance ServicesTable 216, page 225 lists the Advance Services AT commands.

Table 216 Advance Services AT Supported Commands

Command Parameters Response / Effect

AT+PING<IP>,[[Counts],[<Interval>],[<Len>],[<TOS>],[<TTL>],[PAYLOAD>]]

Pings the IP address provided. Counts=0 will ping until <ESC>C is issued.

AT+MDNSSTART N/A Starts the mDNS module of the adapter.

AT+MDNSSTART ? Returns the current status of mDNS.

AT+mDNSHNREG [<Hostname>],<Domain name>

Registers the host name for the mDNS.

AT+MDNSSRVREG

<ServiceInstanceName>,[<ServiceSubType>],<ServiceType>,<Protocol>,<Domain,<port>,<Default Key=Val,<key 1=val 1>,<key 2=val 2>...

De-register sthe mDNC services.

AT+MDNSSRVDEREG<ServiceInstanceName>,[<ServiceSubType>],<ServiceType>,<Protocol>,<Domain>

De-registers the mDNS services.

AT+MDNSSD [<Service subtype>],<Service type>,<Protocol>,<Domain> Discovers the mDNC service.

AT+MDNSSTOP

AT+DNSLOOKUP

<URL>,[<Retry count>,[<Retry timeout>,<Clear cache entry>]]

Queries DNS server for address of hostname URL.

80613ST10964A Rev. 5.0 225 2019-10-24

Page 226: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 217, page 226 lists the Firmware Update AT commands.

Table 217 Firmware Update AT Supported Commands

Command Parameters Response / Effect

AT+SOTAFWUPCONF <param>,<value>

• 0 - Server IP• 1 - Server Port• 2 - Proxy Preset (0|1) (Not Supported)• 3 - Server IP if proxy preset=1 (Not

Supported)• 4 - Server Port if proxy preset=1 (Not

Supported)• 5 - SSL Enable (0|1)• 6 - CA Cert Name (Not Supported)• 7 - E4-P module Binary Request URL• 8 - Info URL (Not Supported)• 9 - Server host name• 10 - E4-P module signature binary

request URL (Not Supported)• 11 - Enables or disables domain name

check on incoming certificate from server.

• 12 - Client certificate name (Not Supported)

• 13 - Client key certificate (Not Supported)

Note: In case of HTTP/S through Proxy, the request URL should be Absolute path and not the Relative path.

AT+SOTAFWUPSTART <value>

Using the header configured using AT++HTTPCONF command, it starts the HTTP connection, downloads the new images, and starts updating the firmware.

AT+SOTAFWUPACCEPT N/A Validate the new firmware and prints the Serial to WiFi banner.

AT+SOTAFWUPROLLBACK N/A It is used to rollback to the previous firmware version.

80613ST10964A Rev. 5.0 226 2019-10-24

Page 227: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

Table 218, page 227 lists the Provisioning AT commands.

Table 218 Provisioning AT Supported Commands

Command Parameters Response / Effect

AT+WEBPROV

<user name>,<passwd>[,SSL Enabled,Param StoreOption,idletimeout,ncmautoconnect,dual interface, format version]

Through provisioning application (web pages, IOS and android).

AT+WEBPROV ?It gives the current status (started or stopped) of the web provisioning and display the URIs registered

AT+WEBPROVSTOP N/A Stops the web provisioning.

80613ST10964A Rev. 5.0 227 2019-10-24

Page 228: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

13.7 Power Management - Radio and SystemTable 219, page 228 lists the Power Management - Radio & Systems AT commands.

Table 219 Power Management - Radio & System AT Supported Commands

Command Parameters Response/ Effect

AT+WRXACTIVEn=0 (disable)n=1 (enable)

IF 1, 802.11 radio is enabled.

AT+WIEEEPSPOLL

<n>[,listen beacon interval][,WakeupType][,Wakeup Interval][,Beacon Wait timeout][,DataRxType][,ActiveToOffTimeout][,SwitchToActivePeriod]

n=0, to disablen=1 to enable

If it is enabled then the second parameter listen beacon interval is valid beacons intervals at which the WLAN wakes up for listening to the beacon. Although it’s a 16-bit value, the maximum recommended is 10-bit value.On execution of this command, the adapter will set the listen interval for n beacons.For WL865E4-P modules, the listen beacon interval is the listen interval that will be advertised in the association request. The valid values are:DTIM-0LISTEN INTERVAL-1CUSTOM-2Wake Up Interval -This is valid only if Wake Up type is Listen Interval and CUSTOM(2).

AT+WRXPSn=0 (disable)n=1 (enable)

IF 1, Power Save mode is enabled.

80613ST10964A Rev. 5.0 228 2019-10-24

Page 229: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

13.8 Production and DebugTable 220, page 229 lists the Debug AT commands.

Table 220 Debug AT Support Commands

Command Parameters Response / Effect

ATEnn=0 (disable)n=1 (enable

IF 1, echo all input

ATVnn=0 (disable)n=1 (enable)

IF 1, responses are ASCII, else numerical codes

AT+WRSSI ? Current RSSI as ASCII

AT+WSTATUS NoneAdapter reports the current network configuration to the serial host

AT+NSTAT ? Current wireless and network configuration.

80613ST10964A Rev. 5.0 229 2019-10-24

Page 230: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

13.9 Default Return MessagesTable 221, page 230 lists the Default Return Messages.

Table 221 Default Return Messages

Status Message (Verbose Enabled) Message (Verbose Disabled)Valid Input OK 0Invalid Input ERROR: Invalid Input 2

NOTE: Other commands can return different ERROR messages.

80613ST10964A Rev. 5.0 230 2019-10-24

Page 231: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

13.10 Escape Sequence CommandsTable 222, page 231 lists the available Escape Sequence commands.

Table 222 Escape Sequence Commands

Escape Sequence Description<ESC>S CID This escape sequence selects the specified Connection ID as the

current connection. This switches the connection to be used without exiting from the Data mode of operation. Use this sequence to send data from a UDP client (must be done before data can be received by that client).

Example: <ESC>S10123456789<Esc>E (where 1 is the UDP client CID and 012...9 is the data to be sent)<ESC>U CIDremote address:remote port:

This escape sequence is used when sending and receiving UDP data on a UDP server connection. The remote address and remote port is transmitted in ASCII text encoding and terminated with a ':' character.

Example: <ESC>U4192.168.1.1:52:<data><Esc>E<ESC>u CID<remote address><remote port>

This escape sequence is used when sending and receiving UDP data on a UDP server connection. The remote address and remote port is transmitted in binary encoding with the MSB transmitted first.The following example shows the header to transmit a UDP packet using binary addressing taking up 9 bytes (d denoting decimal value):

<ESC>u4<192d><168d><1d><1d><0d><52d><data><ESC>E

<ESC>E End-of-Data sequence, indicating end of a transmit frame, and start of transmission. The data received is sent on the network, and the interface returns to Command mode.

<ESC><F><fd><file data> Write the file into the File system. AT+FWRITE will return OK/ERROR.

<ESC>K<CID><Length><type><URI>

This is sent once the URL is fetched by the Remote HTTP client.

<ESC>G<CID><Length><tag name>:<value>

This is sent repeatedly for each tag for the XML data.

<ESC>C This sequence causes transmission of the data received, after which the currently selected connection is closed, and the interface returns to Command Mode. Any buffered data is sent before the connection is closed.

<ESC>xxx If an unknown character “xxx” is detected after an <ESC> character the <ESC> and the <xxx> characters are ignored.

<ESC>R:<Length>:<Dst.Addr><Src.Addr><EtherType><RawPayload>

This sequence is used to transmit or receive a raw Ethernet frame.

80613ST10964A Rev. 5.0 231 2019-10-24

Page 232: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

<ESC>Z<CID><DataLength xxxx 4 ascii char><data>

Each escape sequence starts with the ASCII character 27 (0x1B), the equivalent to the ESC key. The contents of < > are a byte or byte stream.• CID is connection id (udp, tcp, etc)• Data Length is 4 ASCII character represents decimal value i.e. 1400

byte (0x31 0x34 0x30 0x30).• Data size must match with specified length. Ignore all command or

Esc sequence in between data pay load.<ESC>Y<CID>remote address:remote port:<DataLen 4 digit ascii><Data>

This escape sequence is used when sending UDP data on a UDP server connection. When this command is used, the remote address and remote port is transmitted in ASCII text encoding and terminated with a “:” character.

Example: <ESC>Y4192.168.1.1:52:<DataLen><data><ESC>y<CID><remote address><DataLen 4 digit ascii><Data>

This escape sequence is used when receiving UDP data on a UDP server connection. When this sequence is used, the remote address and remote port is transmitted in ASCII text encoding and separated be a space ( ) character.

Example: <ESC>y192.168.1.152<DataLen><Data><ESC>M<Chunk size in bytes><:><Image of mentioned chunk size>

This escape sequence is used to digital data or firmware from Host MCU to Telit node.

<ESC>N<CID><Data of above Length>

This escape sequence is used to send MCU application message MQTT data from client to the server.

<ESC><N><CID><StartOfFrame><CurrentLength><Total Length Of Frame><TopicName><Space><DataOfLength Equal to CurrentLength>

This escape sequence is used to receive MQTT data sent by Telit node.

<ESC>i<CID><Data of above Length>

This escape sequence is used to send the WebSocket client data to server connected.

<ESC>W <data of size mentioned in AT+WEAP>

This escape sequence is used to enable the Telit node and receive the EAP certificates.

Table 222 Escape Sequence Commands (Continued)

Escape Sequence Description

NOTE: The contents of < > are a byte stream, except for <ESC>; literals outside brackets are ASCII.

80613ST10964A Rev. 5.0 232 2019-10-24

Page 233: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

80613ST10964A Rev. 5.0 233 2019-10-24

14 Glossary and Acronyms

BSSID Basic Service Set Identifier

BLE Bluetooth Low Energy

CID Caller Identification

DNS Domain Name System

DHCP Dynamic Host Configuration Protocol

EAP Extensible Authentication Protocol

GPIO General Purpose Input Output

HTTP Hyper Text Transfer Protocol

HTTPS Hypertext Transfer Protocol Secure

I/O Input Output

MDNS Multicast Domain Name System

NCM Network Configuration Manager

NVDS Non Volatile Data Storage

RTC Real Time Clock

SPI Serial Peripheral Interface

SSID Service Set Identifier

SSL Secured Sockets Layer

TCP Transmission Control Protocol

TLS Transport Layer Security

UART Universal Asynchronous Receiver Transmitter

UDP User Datagram Protocol

WEP Wired Equivalent Privacy

WLAN Wireless Local Area Network

WPA Wi-Fi Protected Access

Page 234: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

15 Document History

Revision Date Changes

0.0 August 2019 First Issue

1.0 September 2019 Updated system initialization procedures under section System Initialization, page 18Removed Unsolicited data mode and software flow control details from section Data Handling, page 19Removed not supported parameter value for enabling Software flow control under section Software Flow Control, page 25Updated examples under section Version, page 27Removed not supported value range for reset parameters under section Reset, page 43Removed AT+CIDCONF and AT+L2CONFIG commandsCorrected asynchronous response for disassociation under section Disassociation, page 65Removed examples for HTTP/S connections under section HTTP, page 119Updated Appendix A - AT Commands Summary, page 215 with the list of supported AT commands.Updated list of supported parameters for AT+NCMAUTOCONF command.Removed not supported reference table for Telit nodes’s behavior based on RSSI flag and channel under section Association, page 62Removed list of not supported ECC Ciphers selective display under section EAP-Configuration, page 98Updated synchronous response remarks related to hardware version under section Identification Information, page 41Updated Table 143, page 147Removed AT+MDNSANNOUNCE command from mDNS command examplesUpdated list of supported parameters for firmware upgrade under section Firmware Update, page 190Updated List of Acronyms

80613ST10964A Rev. 5.0 234 2019-10-24

Page 235: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements

WL865E4-P Legacy Command Reference Guide

2.0 October 2019 Updated SNTP parameter information.

3.0 October 2019 Added AT+LOGLVL command to configure the debug levelAdded AT+NIFCMODE and AT+NIF command to support concurrent modeAdded AT+WEAPCONF command to configure EAP.

4.0 October 2019 Updated AT+TCERTADD command parameters with DER format details.

5.0 October 2019 Updated AT+WEAPCONF command parameters to add EAP-TLS feature.Added AT+WEAP command to enable certificate upload.

Revision Date Changes

80613ST10964A Rev. 5.0 235 2019-10-24

Page 236: WL865E4-P Legacy Command Reference Guide€¦ · WL865E4-P Legacy Command Reference Guide 80613ST10964A Rev. 5.0 4 2019-10-24 USAGE AND DISCLOSURE RESTRICTIONS I. License Agreements