BLEPeripheralServe添加notify服务,蓝牙设备订阅返回no descriptor
发布于 5 年前 作者 uchang 10438 次浏览 来自 官方Issues

1、BLEPeripheralServer添加notify服务

this.server.addService({
    service: {
        uuid: this.serviceId,
        characteristics: [{
            uuid: this.notifyId,
            properties: {
                notify: true
            },
            permission: {
                readable: true
            },
            descriptors: [{
                uuid: this.desId,
                permission: {
                    read: true
                }
            }]
        }]
    }
});

2、使用开源app连接并打开通知,显示BleException{code=102, descriptor equals null }

开源app链接为https://github.com/Jasonchenlijian/FastBle


回到顶部