-
Notifications
You must be signed in to change notification settings - Fork 46
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
Implement bluetooth mesh support #60
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for making the effort to implement support for mesh networks!
However, a bit more work is required before I can merge this.
The main issue is the exposure of D-Bus paths, which we treat as internals in BlueR. See how the GATT server is implemented on how to do it without exposing D-Bus paths to the user.
Also we target stable Rust, thus you must remove the use of nightly features. However, we can bump the minimum supported Rust version to the newest stable version, so GATs should be usable by now.
In general, a bit more documentation is required. Explain what the functions do from the Bluetooth side of things and how they interact.
I haven't tested your code yet. Please make the above changes and then I will have a more in-depth look and provide further comments.
Also, what would I require for testing? Would it be possible to make a Bluetooth Mesh out of some Raspberry Pis?
bluer/src/mesh/application.rs
Outdated
pub version: u16, | ||
} | ||
|
||
impl Default for Properties { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do not provide such defaults for identifiers that should be unique.
@@ -0,0 +1,168 @@ | |||
#![feature(generic_associated_types)] | |||
//! Attach and send/receive BT Mesh messages |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would this be useful as a standalone tool?
Then consider moving it to bluer-tools and properly documenting the CLI arguments.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, this is just an example for now (as it is tied to the predefined model) ... The proper tool needs more work
@@ -46,3 +46,4 @@ libc = "0.2" | |||
log = "0.4" | |||
hex = { version = "0.4" } | |||
rand = "0.8" | |||
uuid = { version = "1", features = ["v4"] } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not necessary
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for making the effort to implement support for mesh networks!
However, a bit more work is required before I can merge this.
The main issue is the exposure of D-Bus paths, which we treat as internals in BlueR. See how the GATT server is implemented on how to do it without exposing D-Bus paths to the user.
Also we target stable Rust, thus you must remove the use of nightly features. However, we can bump the minimum supported Rust version to the newest stable version, so GATs should be usable by now.
In general, a bit more documentation is required. Explain what the functions do from the Bluetooth side of things and how they interact.
I haven't tested your code yet. Please make the above changes and then I will have a more in-depth look and provide further comments.
Also, what would I require for testing? Would it be possible to make a Bluetooth Mesh out of some Raspberry Pis?
Thanks for reviewing it and the valuable feedback, I'll start addressing the particular comments in the coming days. I was expecting some work to be done before the merge. I was developing it to meet our demo needs for a while and now that it looks stable to me, it made sense to continue development within the bluer project umbrella. As for the testing, yes you can use rPi (or any other bluetooth-enabled Linux machine) to run and test everything. The descriptions in the examples should get you going
|
# This is the 1st commit message: BLE Passive Scanning # This is the commit message #2: monitor # This is the commit message bluez#3: monitor # This is the commit message bluez#4: monitor # This is the commit message bluez#5: monitor # This is the commit message bluez#6: monitor # This is the commit message bluez#7: monitor # This is the commit message bluez#8: monitor # This is the commit message bluez#9: monitor # This is the commit message bluez#10: monitor # This is the commit message bluez#11: monitor # This is the commit message bluez#12: monitor # This is the commit message bluez#13: monitor # This is the commit message bluez#14: monitor # This is the commit message bluez#15: monitor # This is the commit message bluez#16: monitor # This is the commit message bluez#17: monitor # This is the commit message bluez#18: monitor # This is the commit message bluez#19: monitor # This is the commit message bluez#20: monitor # This is the commit message bluez#21: monitor # This is the commit message bluez#22: monitor # This is the commit message bluez#23: monitor # This is the commit message bluez#24: monitor # This is the commit message bluez#25: monitor # This is the commit message bluez#26: monitor # This is the commit message bluez#27: monitor # This is the commit message bluez#28: monitor # This is the commit message bluez#29: monitor # This is the commit message bluez#30: monitor # This is the commit message bluez#31: monitor # This is the commit message bluez#32: monitor # This is the commit message bluez#33: monitor # This is the commit message bluez#34: monitor # This is the commit message bluez#35: monitor # This is the commit message bluez#36: monitor # This is the commit message bluez#37: monitor # This is the commit message bluez#38: monitor # This is the commit message bluez#39: monitor # This is the commit message bluez#40: monitor # This is the commit message bluez#41: monitor # This is the commit message bluez#42: monitor # This is the commit message bluez#43: monitor # This is the commit message bluez#44: monitor # This is the commit message bluez#45: monitor # This is the commit message bluez#46: monitor # This is the commit message bluez#47: monitor # This is the commit message bluez#48: monitor # This is the commit message bluez#49: monitor # This is the commit message bluez#50: monitor # This is the commit message bluez#51: monitor # This is the commit message bluez#52: monitor # This is the commit message bluez#53: monitor # This is the commit message bluez#54: monitor # This is the commit message bluez#55: monitor # This is the commit message bluez#56: monitor # This is the commit message bluez#57: monitor # This is the commit message bluez#58: monitor # This is the commit message bluez#59: monitor # This is the commit message bluez#60: monitor # This is the commit message bluez#61: monitor # This is the commit message bluez#62: monitor
I've revised the Pull Request to align with BlueR's API style and am preparing to merge it now. I've eliminated the dependency on the For the time being, the mesh examples have been deactivated. Could you kindly update them and submit a follow-up PR? |
@surban Thanks for picking it up ... My work priorities shifted lately and I didn't have time to commit to it. I'll try to introduce |
This is an initial implementation of the support for Bluetooth mesh API as discussed in issue #37
It supports at the moment:
Some functionalities that are not implemented yet:
Currently implemented features are quite stable and we used them to implement the gateway for the EclipseCon Hackathon. They should be a good base for the further development.
The implementation depends on the btmesh crate for representing Bluetooth mesh models. We'll release this crate shortly, so that git dependency can be removed.
Please let me know if you have any further questions about this. Any feedback is more than welcomed.