Open tobyloki opened 2 years ago
Hi @tobyloki , thanks for reporting the issue. Will check this.
@khushbushah2302 Hi. Have you found a solution to this problem?
Hi @tobyloki , I am working on this issue.
@khushbushah2302 After investigating further, I've found that the source of the problem is provisionManager.getEspDevice().sendDataToCustomEndPoint
. It seems to work fine on the first invocation. But when I call it a second time, it gives me the error. Could you verify if this is true on your end?
final String data = "asdf";
provisionManager.getEspDevice().sendDataToCustomEndPoint("custom-data", data.getBytes(), new ResponseListener() {
...
});
Hi @tobyloki , In provisionManager.getEspDevice().sendDataToCustomEndPoint
, first argument is device endpoint name.
You have sent "custom-data" instead of endpoint. Have you used actual endpoint value or data in first argument ?
App will try to find BLE Characteristic whose descriptor value is this endpoint ("custom-data" in your case).
App will give error if it is unable to find Characteristic with the given descriptor value.
We are using this same API in ESP RainMaker project.
@khushbushah2302 In my ESP32's code, I had configured the endpoint as "custom-data". So I think what I've done should be correct.
wifi_prov_mgr_endpoint_create("custom-data");
/* Start provisioning service */
ESP_ERROR_CHECK(wifi_prov_mgr_start_provisioning(security, pop, service_name, service_key));
/* The handler for the optional endpoint created above.
* This call must be made after starting the provisioning, and only if the endpoint
* has already been created above.
*/
wifi_prov_mgr_endpoint_register("custom-data", custom_prov_data_handler, NULL);
@tobyloki You still have the issue or you got it resolved? I have the same issue now.
@tobyloki You still have the issue? I have the same issue now.
@tobyloki You still have the issue? I have the same issue now.
One fix is to switch to security0.
@tobyloki You still have the issue? I have the same issue now.
One fix is to switch to security0.
Already built the firmware and ios app using security1. So want to keep using security1. Is there any way to fix this in security1?
I am also facing issues related to Security1 but it looks like the Espressif team is not interested in working on the provisioning library... @KhushbuShah25 "I am working on this issue." still are you working? How long it will take...
Same issue here with security 2. Any clue? Thanks
My BLE provisioning flow is as follows:
provisionManager.getEspDevice().sendDataToCustomEndPoint
and get back some data from the device.Here's my test case:
I am using
implementation 'com.github.espressif:esp-idf-provisioning-android:lib-2.0.9'
in my applications gradle file.Why does this error occur and how can I fix it? I also tried rescanning for BLE networks again, and it then returned 0 devices. I'm not sure why it returned 1 device on the first scan and then 0 on the second.