mini_program_gizwits_sdk 3.3.2 → 3.3.25-kuka

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -3,6 +3,13 @@
3
3
  # 机智云小程序 SDK
4
4
 
5
5
 
6
+ ## 🔴 破坏性更新
7
+
8
+ - 3.2.4(含)开始蓝牙广播包过滤增加了 `['ABF8', 'ABF0', 'F0AB', 'F8AB']` 四个过滤字段,为了兼容部分低端手机不过滤,长时间挂机会假死的问题。
9
+ - 乐鑫_0ESP32C3_0403000G 和 博流_00BL602L_0403000B 之后的版本都支持这个特性。
10
+ - 如果您使用的是更早期的固件,请联系我们。
11
+
12
+
6
13
  ## ⚠️ 重要
7
14
 
8
15
  使用小程序 sdk 前,请在微信开发者后台-开发管理-开发设置-服务器域名添加以下请求地址。
@@ -21,17 +28,6 @@ wss://wxstage.gizwits.com
21
28
  wss://wxm2m.gizwits.com
22
29
  ```
23
30
 
24
- - 关于services
25
-
26
- 为了搜索效率,sdk会根据`services `过滤蓝牙设备。默认 ['ABF8', 'ABF0', 'F0AB', 'F8AB']。
27
- 如果有特殊情况,不想用`services `过滤设备,可以
28
-
29
- ```js
30
- sdk.scanBleDevice(3000, [])
31
- sdk.startAutoScan([])
32
- ```
33
-
34
-
35
31
  ## 🔧 安装
36
32
 
37
33
  ```bash
@@ -86,9 +82,9 @@ export default class Index extends Component {
86
82
  ## 📋 日志
87
83
  sdk.setLogLevel("debug")
88
84
 
89
- ## 📖 API
85
+ ## 📖 BLE API
90
86
 
91
- 小程序相关 API。
87
+ 小程序 BLE 相关 API。
92
88
 
93
89
  ### sdk.initBle()
94
90
 
@@ -136,14 +132,10 @@ sdk.setLogLevel("debug")
136
132
  | mac | string | 待绑定设备 mac |
137
133
  | productKey | string | 待绑定设备所属产品 |
138
134
 
139
- ### sdk.subscribe(device:[IDevice](#IDevice),connectType:[TConnectType](#TConnectType))
135
+ ### sdk.subscribe(device:[IDevice](#IDevice) )
140
136
 
141
137
  订阅目标设备,订阅成功后可控制设备。返回值中可以拿到订阅结果。
142
138
 
143
- ### sdk.getDeviceStatus(device:[IDevice](#IDevice), attrNames?: string[])
144
-
145
- 查询目标设备当前状态,attrNames 不传则查询所有数据
146
-
147
139
  ### sdk.write(device:[IDevice](#IDevice),cmd:{[key]:value})
148
140
 
149
141
  向目标设备发送指令。 其中`key`为数据点名称,value 为数据点的值。
@@ -211,15 +203,6 @@ interface IDevice {
211
203
  isOnline: boolean; // 代表大循环在线
212
204
  isLanOnline: boolean; // 代表小循环在线
213
205
  isBleOnline: boolean; // 代表蓝牙在线
214
- bleWorkStatus?: number; // 蓝牙设备状态 0 默认状态 1 配网状态
215
- connectType: TConnectType; // 当前连接类型
216
- }
217
- ```
218
-
219
- - <a id="TConnectType">TConnectType</a>
220
-
221
- ```ts
222
- type TConnectType = 'BLE' | 'BLE_BROADCAST' | 'LAN' | 'WAN' | 'NONE';
223
206
  }
224
207
  ```
225
208
 
@@ -245,7 +228,7 @@ interface IError {
245
228
 
246
229
  销毁事件监听。
247
230
 
248
- # 配网相关
231
+ # 机智云小程序 wifi SDK
249
232
 
250
233
  ## 使用方法
251
234