Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Adds logic to expose minimal functionality for supporting SRP service registration (supports acting as client only). Also adds an example bin as well as a slight reworking of the
examples
dir to match the same style as present in theesp-ha
l crate. If accepted, this will be the first in a series of PRs working on this general area of functionality.I opted to build the openthread libs with SRP functionality and include them precompiled, even though the SRP client functionality (as exposed via the publicly accessible
Openthread
object's methods) is gated via feature flag. This has the downside of making the openthread libs bigger even though a user of theesp-openthread
crate may not want to ever use SRP. Do you have any thoughts on this @bjoernQ @jessebraham or preferences as to how this is handled? If this was a bad choice I can restructure thebuild.rs
file inesp-openthread-sys
to handle pulling in different libraries at build time, and include multiple copies of the various libs based on compile-time feature flags.Testing
Tested with a v1.3 Border Router and esp32c6, running the
srp-client-example
bin. When running, should see logs like the following showing successful service registration and add proxying as output in the otbr-agent logs:Also checked that add proxying is working; Im able to discover the service on the LAN using the service discovery app on my android phone, should also work with
avahi-browse
and/ordns-sd