cordova-plugin-bluetoothle
cordova-plugin-bluetoothle copied to clipboard
Subscribe Error: Service not Found
Hi,
Im trying to communicate with a custom equipment without success. My needs is for running my app in Android 4.4 (API 19), so, I'm using old 2.4.0 version.
I can connect, discover services, disconnect. My problem is when subscribe to a characteristic: "Service not found"
Here is the discover results:
{
"address":"XX:XX:XX:XX:XX:XX",
"status":"discovered",
"services":[{
"characteristics":[{
"descriptors":[],
"characteristicUuid":"2a00",
"properties":{"read":true}
},{
"descriptors":[],
"characteristicUuid":"2a01",
"properties":{"read":true}
},{
"descriptors":[],
"characteristicUuid":"2a02",
"properties":{"write":true, "read":true}
},{
"descriptors":[],
"characteristicUuid":"2a03",
"properties":{"write":true, "read":true}
},{
"descriptors":[],
"characteristicUuid":"2a04",
"properties":{"read":true}
}],
"serviceUuid":"1800"
},{
"characteristics":[{
"descriptors":[{"descriptorUuid":"2902"}],
"characteristicUuid":"2a05",
"properties":{"indicate":true}
}],
"serviceUuid":"1801"
},{
"characteristics":[{
"descriptors":[{"descriptorUuid":"2902"},{"descriptorUuid":"2901"}],
"characteristicUuid":"ffe1",
"properties":{
"writeWithoutResponse":true,
"read":true,
"notify":true
}
}],
"serviceUuid":"ffe0"
}],
"name":"PeripheralName"
}
And error occurr with:
bluetoothle.subscribe(resolve, reject, {
address: 'XX:XX:XX:XX:XX:XX',
service: 'ffe0',
characteristic: 'ffe1',
})
{"message":"Service not found","error":"service","address":"XX:XX:XX:XX:XX:XX","name":"PeripheralName"}
Did I miss something?
Thanks
When I subscribe neither the success nor failure functions fire
Hi, how are you? I have the same problem, were you able to solve that?
you must discover to update data used by the library.. until you do, you cannot read/write, or connect really