Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(BLE mesh) Get Node from Name (IDFGH-3435) #5397

Closed
JacekDob opened this issue Jun 4, 2020 · 7 comments
Closed

(BLE mesh) Get Node from Name (IDFGH-3435) #5397

JacekDob opened this issue Jun 4, 2020 · 7 comments
Labels
Type: Feature Request Feature request for IDF

Comments

@JacekDob
Copy link

JacekDob commented Jun 4, 2020

Please add function similar to esp_ble_mesh_provisioner_get_node_index which based on name returns esp_ble_mesh_node_t (like in esp_ble_mesh_provisioner_get_node_with_uuid or esp_ble_mesh_provisioner_get_node_with_addr).

Currently having node name is not possible to relate it to node (esp_ble_mesh_node_t).
Currently it is possible when using esp_ble_mesh_provisioner_get_node_index to get node index, but there is not function to use this node index.

@JacekDob JacekDob added the Type: Feature Request Feature request for IDF label Jun 4, 2020
@github-actions github-actions bot changed the title (BLE mesh) Get Node from Name (BLE mesh) Get Node from Name (IDFGH-3435) Jun 4, 2020
@Alvin1Zhang
Copy link
Collaborator

@JacekDob Thanks for reporting this feature request.

@JacekDob
Copy link
Author

JacekDob commented Jun 5, 2020

Thank you for that.

Please also add possibility to iterate through provisioned nodes.

Currently I see only possibility to get number of provisioned nodes (esp_ble_mesh_provisioner_get_prov_node_count), but there is no access to that/not possible to iterate.

@Campou
Copy link

Campou commented Jun 8, 2020

Hi @JacekDob

Thanks for the feedback. I have submitted a MR for this internally, and since the code is just in review, please have a try with this patch get_node_with_name.zip

Thanks.

@JacekDob
Copy link
Author

JacekDob commented Jun 9, 2020

Thank you,

how to apply it?

I am cloning then newest version and trying to apply and I get:

$ git clone --recursive https://github.com/espressif/esp-idf.git
$ cd esp-idf
$ git apply 0001-ble_mesh-Get-node-info-with-pre-configured-node-name.patch
error: patch failed: components/bt/esp_ble_mesh/mesh_core/provisioner_main.c:622
error: components/bt/esp_ble_mesh/mesh_core/provisioner_main.c: patch does not apply

Also tried:

$ cat 0001-ble_mesh-Get-node-info-with-pre-configured-node-name.patch \| git am
error: patch failed: components/bt/esp_ble_mesh/mesh_core/provisioner_main.c:622
error: components/bt/esp_ble_mesh/mesh_core/provisioner_main.c: patch does not apply
hint: Use 'git am --show-current-patch' to see the failed patch
Applying: ble_mesh: Get node info with pre-configured node name
Patch failed at 0001 ble_mesh: Get node info with pre-configured node name
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
--

@Campou
Copy link

Campou commented Jun 12, 2020

Hi @JacekDob

I generated the patch file based on the latest internal idf, but since the esp-idf in Github has not been synced for more than 20 days, this causes failing to apply the patch.

Please apply this one 0001-ble_mesh-get-node-info-with-preset-node-name.patch.tar.gz

Thanks.

@JacekDob
Copy link
Author

Thank you, tested, everything works fine.

projectgus pushed a commit that referenced this issue Jun 29, 2020
Also add a function to get the entry of the nodes table.

Closes #5397
@Alvin1Zhang
Copy link
Collaborator

Thanks for reporting, the fix has been available at 00148cd, feel free to reopen. Thanks.

espressif-bot pushed a commit that referenced this issue Jul 10, 2020
Also add a function to get the entry of the nodes table.

Closes #5397
espressif-bot pushed a commit that referenced this issue Jul 18, 2020
Also add a function to get the entry of the nodes table.

Closes #5397
projectgus pushed a commit that referenced this issue Jul 22, 2020
Also add a function to get the entry of the nodes table.

Closes #5397
espressif-bot pushed a commit that referenced this issue Sep 10, 2020
Also add a function to get the entry of the nodes table.

Closes #5397
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Feature Request Feature request for IDF
Projects
None yet
Development

No branches or pull requests

3 participants