Skip to content

Commit b06b0ee

Browse files
committed
[datacall/securedata等模块说明微调]
1 parent c82d22d commit b06b0ee

File tree

2 files changed

+47
-39
lines changed

2 files changed

+47
-39
lines changed

en-us/api/QuecPythonClasslib.md

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ Call this API to activating the PDP Context.
6969
| apn | string | Optional. APN name. The maximum length is 63 bytes. (The maximum length is 64 bytes in EC200U/EC200A) |
7070
| username | string | Optional. APN user name. The maximum length is 15 bytes.(The maximum length is 64 bytes in EC200U/EC200A) |
7171
| password | string | Optional. APN password. The maximum length is 15 bytes.(The maximum length is 64 bytes in EC200U/EC200A) |
72-
| authType | int | Authentication type. 0-No authentication, 1-PAP, 2-CHAP. |
72+
| authType | int | Authentication type. 0-No authentication, 1-PAP, 2-CHAP, 3-PAP AND CHAP(just for CAT-M platform).|
7373

7474
* Return Value
7575

@@ -347,7 +347,7 @@ After calling this interface, the user_apn.json will be created in the user part
347347
| apn | string | Optional. APN name. The maximum length is 63 bytes.(The maximum length is 64 bytes in EC200U/EC200A) |
348348
| username | string | Optional. APN user name. The maximum length is 15 bytes.(The maximum length is 64 bytes in EC200U/EC200A) |
349349
| password | string | Optional. APN password. The maximum length is 15 bytes.(The maximum length is 64 bytes in EC200U/EC200A) |
350-
| authType | int | Authentication type. 0-No authentication, 1-PAP, 2-CHAP. |
350+
| authType | int | Authentication type. 0-No authentication, 1-PAP, 2-CHAP, 3-PAP AND CHAP(just for CAT-M platform). |
351351
| flag | int | This parameter is optional. The default value is 0, indicating that only a user_apn.json file is created to save user APN information. If the value is 1, the user_apn.json file is created to save user APN information, and the APN information is used for PDP context activation immediately. |
352352

353353
* Return Value
@@ -705,8 +705,6 @@ Obtain Coordinate Information.
705705

706706
Function:send AT cmd.
707707

708-
Note:This module only supports 1803S/EC200U/CATM platform.
709-
710708
#### send AT cmd
711709

712710
> **atcmd.sendSync(atcmd,resp,include_str,timeout)**
@@ -11583,13 +11581,13 @@ $GNGSA,A,3,31,3
1158311581

1158411582
Module function: the module provides a bare flash area and a special read-write interface for customers to store important information, and the information will not be lost after burning the firmware (burning the firmware without this function cannot be guaranteed not to be lost). Provide a storage and read interface, not a delete interface.
1158511583

11586-
>At present, only ec600n and ec600s series projects are supported
11584+
At present, only ec600n and ec600s series projects are supported
1158711585

1158811586
##### Data storage
1158911587

11590-
SecureData.Store(index, databuf, len)
11588+
>**SecureData.Store(index, databuf, len)**
1159111589

11592-
**Parameter**
11590+
* Parameter
1159311591

1159411592
| Parameter | type | description |
1159511593
| ------ | -------- | ------------------------------------------------------------ |
@@ -11600,16 +11598,16 @@ SecureData.Store(index, databuf, len)
1160011598

1160111599
When storing, it is stored according to the shorter of databuf and Len
1160211600

11603-
**Return Value**
11601+
* Return Value
1160411602

11605-
* -1: Parameter error
11606-
* 0: normal execution
11603+
-1: Parameter error
11604+
0: normal execution
1160711605

1160811606
##### Data reading
1160911607

11610-
SecureData.Read(index,databuf,len)
11608+
>**SecureData.Read(index,databuf,len)**
1161111609

11612-
**Parameter**
11610+
* Parameter
1161311611

1161411612
| Parameter | type | description |
1161511613
| ------ | -------- | ----------------------------------------------- |
@@ -11619,13 +11617,13 @@ SecureData.Read(index,databuf,len)
1161911617

1162011618
If the stored data is not as large as the incoming len, the actual stored data length is returned
1162111619

11622-
**Return Value**
11620+
* Return Value
1162311621

11624-
* -2: The stored data does not exist and the backup data does not exist
11625-
* -1: Parameter error
11626-
* Other: length of data actually read
11622+
-2: The stored data does not exist and the backup data does not exist
11623+
-1: Parameter error
11624+
Other: length of data actually read
1162711625

11628-
**Example**
11626+
* Example
1162911627

1163011628
```python
1163111629
import SecureData
@@ -11640,7 +11638,9 @@ len = SecureData.Read(1, buf, 20)
1164011638
#Output read data
1164111639
print(buf[:len])
1164211640
```
11643-
**implementation results**
11641+
11642+
* implementation results
11643+
1164411644
```python
1164511645
>>> import SecureData
1164611646
>>> databuf = '\x31\x32\x33\x34\x35\x36\x37\x38'

zh-cn/api/QuecPythonClasslib.md

Lines changed: 29 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,6 @@ myprint()
5454

5555
模块功能:提供数据拨号相关接口。
5656

57-
注意:当前仅EC600S/EC600N/EC800N/EC200U/EC600U平台支持该功能。
58-
5957
##### 拨号
6058

6159
> **dataCall.start(profileIdx, ipType, apn, username, password, authType)**
@@ -66,12 +64,12 @@ myprint()
6664

6765
| 参数 | 参数类型 | 参数说明 |
6866
| ---------- | -------- | ------------------------------------------------------------ |
69-
| profileIdx | int | PDP索引,ASR平台范围1 - 8[volte版本默认PID最大的一路用来注册IMS,请勿重复操作],展锐平台范围1 - 7,一般设置为1,设置其他值可能需要专用apn与密码才能设置成功 |
67+
| profileIdx | int | PDP索引,ASR平台范围1 - 8[volte版本默认PID最大的一路用来注册IMS,请勿重复操作],展锐平台范围1 - 7,高通平台1-4[第二路用来注册ims,不建议修改], 一般设置为1,设置其他值可能需要专用apn与密码才能设置成功 |
7068
| ipType | int | IP类型,0-IPV4,1-IPV6,2-IPV4和IPV6 |
7169
| apn | string | apn名称,可为空,最大长度不超过63字节(EC200U/EC200A最大长度不超过64字节) |
7270
| username | string | apn用户名,可为空,最大长度不超过15字节(EC200U/EC200A最大长度不超过64字节) |
7371
| password | string | apn密码,可为空,最大长度不超过15字节(EC200U/EC200A最大长度不超过64字节) |
74-
| authType | int | 加密方式,0-不加密,1-PAP,2-CHAP |
72+
| authType | int | 加密方式,0-不加密,1-PAP,2-CHAP,3-PAP AND CHAP[仅高通平台支持] |
7573

7674
* 返回值
7775

@@ -350,7 +348,7 @@ if __name__ == '__main__':
350348
| apn | string | apn名称,可为空,最大长度不超过63字节(EC200U/EC200A最大长度不超过64字节)|
351349
| username | string | apn用户名,可为空,最大长度不超过15字节(EC200U/EC200A最大长度不超过64字节)|
352350
| password | string | apn密码,可为空,最大长度不超过15字节(EC200U/EC200A最大长度不超过64字节)|
353-
| authType | int | 加密方式,0-不加密,1-PAP,2-CHAP |
351+
| authType | int | 加密方式,0-不加密,1-PAP,2-CHAP,3-PAP AND CHAP(仅高通平台支持加密方式3) |
354352
| flag | int | 可选参数,默认为0,表示仅创建user_apn.json文件,用于保存用户apn信息;为1时,表示创建user_apn.json文件保存用户apn信息之后,还会使用该apn信息立即进行一次拨号;不管该参数是0还是1,都不会影响重启时使用用户设置的apn进行开机拨号。 |
355353

356354
* 返回值
@@ -392,7 +390,7 @@ if __name__ == '__main__':
392390

393391
* 注意
394392

395-
当前仅EC600S/EC600N/EC800N/EC200U/EC600U平台支持该功能
393+
当前仅ASR/Unisoc/ASR_1803s平台支持该功能
396394

397395
更改DNS服务器后,域名解析时,将同步使用设置的DNS服务器。
398396

@@ -732,8 +730,6 @@ if __name__ == '__main__':
732730

733731
模块功能:提供发送AT指令接口。
734732

735-
注意:目前该模块只支持1803S/EC200U/CATM平台。
736-
737733
#### 发送AT指令接口
738734

739735
> **atcmd.sendSync(atcmd,resp,include_str,timeout)**
@@ -1750,8 +1746,6 @@ def voice_callback(args):
17501746

17511747
模块功能:该模块提供短信功能相关接口。
17521748

1753-
说明:当前QuecPython底层为非volte版本,暂不支持电信发送短信。
1754-
17551749
注意:BC25PA平台不支持此模块。
17561750

17571751
##### 发送TEXT类型消息
@@ -2437,7 +2431,7 @@ sms.setCallback(cb)
24372431

24382432
| 参数 | 参数类型 | 参数说明 |
24392433
| ------- | -------- | ------------------------------------ |
2440-
| mode | int | 网络制式,0 ~ 18,详见上述网络制式表格 |
2434+
| mode | int | 网络制式,0 ~ 24,详见上述网络制式表格 |
24412435
| roaming | int | 漫游开关(0:关闭, 1:开启),可选参数,不支持的平台不填写该参数即可。 |
24422436

24432437
* 返回值
@@ -11581,10 +11575,14 @@ $GNGSA,A,3,31,3
1158111575
#### SecureData - 安全数据区
1158211576

1158311577
模块功能:模组提供一块裸flash区域及专门的读写接口供客户存贮重要信息,且信息在烧录固件后不丢失(烧录不包含此功能的固件无法保证不丢失)。提供一个存储和读取接口,不提供删除接口。
11584-
> 目前只支持EC600NEC600S系列项目
11578+
目前只支持EC600NEC600S系列项目
11579+
1158511580
##### 数据存储
11586-
SecureData.Store(index,databuf,len)
11587-
- **参数**
11581+
11582+
> **SecureData.Store(index,databuf,len)**
11583+
11584+
* 参数
11585+
1158811586
| 参数 | 类型 | 说明 |
1158911587
| :------ | :-------- | ------------------------------------------------------------ |
1159011588
| index | int | index范围为1-16<br />1 - 8 最大存储52字节数据<br />9 - 12 最大存储100字节数据<br />13 - 14 最大存储500字节数据<br />15 - 16 最大存储1000字节数据 |
@@ -11594,27 +11592,33 @@ SecureData.Store(index,databuf,len)
1159411592

1159511593
存储时按照databuf和len两者中长度较小的进行存储
1159611594

11597-
**返回值**
11595+
* 返回值
1159811596

1159911597
-1: 参数有误
11600-
1160111598
0: 执行正常
1160211599

1160311600
##### 数据读取
1160411601

11605-
SecureData.Read(index,databuf,len)
11606-
- **参数**
11602+
> **SecureData.Read(index,databuf,len)**
11603+
11604+
* 参数
11605+
1160711606
| 参数 | 类型 | 说明 |
1160811607
| :------ | :-------- | ----------------------------------------------- |
1160911608
| index | int | index范围为1-16<br />读取存储数据对应的索引号 |
1161011609
| databuf | bytearray | 存储读取到的数据 |
1161111610
| len | int | 要读取数据的长度 |
11611+
1161211612
若存储的数据没有传入的len大,则返回实际存储的数据长度
11613-
**返回值**
11613+
11614+
* 返回值
11615+
1161411616
-2: 存储数据不存在且备份数据也不存在
1161511617
-1: 参数有误
1161611618
其他 : 实际读取到的数据长度
11617-
- **示例**
11619+
11620+
* 示例
11621+
1161811622
```python
1161911623
import SecureData
1162011624
# 即将存储的数据buf
@@ -11628,7 +11632,9 @@ len = SecureData.Read(1, buf, 20)
1162811632
# 输出读到的数据
1162911633
print(buf[:len])
1163011634
```
11631-
- **执行结果**
11635+
11636+
* 执行结果
11637+
1163211638
```python
1163311639
>>> import SecureData
1163411640
>>> databuf = '\x31\x32\x33\x34\x35\x36\x37\x38'
@@ -11641,6 +11647,8 @@ bytearray(b'12345678')
1164111647
>>>
1164211648
```
1164311649

11650+
11651+
1164411652
#### nb-物联网云平台
1164511653

1164611654
模块功能:提供对接物联网云平台功能,提供连接物联网云平台。通过物联网云平台和模块设备的通信功能,目前支持中国电信lot物联网平台、中国电信AEP物联网平台和中国移动onenet物联网平台。

0 commit comments

Comments
 (0)