Skip to content

Conversation

arkhipenko
Copy link

This small change allows dynamically changing advertising data without a stop/start cycle.
I found it useful for changing the manufacturing data (for instance) frequently without affecting device's ability to be connected to or discovered.
refreshAdvertisingData() should be called after methods that alter the data, e.g. setManufacturerData(..)

@h2zero
Copy link
Owner

h2zero commented Nov 4, 2024

@arkhipenko Thank you for this, its a great idea. One thing that is missing is setting the scan response data to compliment this.

@arkhipenko
Copy link
Author

Not quite sure what you mean by this, but maybe....
I came across this need because advertising data is a great way to communicate out without the need to be connected. Like presenting a sensor data or something along those lines. How does scan response come into play here?

@mhaberler
Copy link

I wasnt aware the response to an active scan might be different than the content of a periodic advertisement - good point

very much looking forward this capability!

@arkhipenko
Copy link
Author

Ok, I read up on it and figured what this is about. I just didn't need the scan response, so didn't think about it. Yes, that capability would be a great compliment to adv. data.
Thanks.
I learn every day!

@h2zero
Copy link
Owner

h2zero commented Nov 24, 2024

@arkhipenko I will be adding this after #756 is merged. I will make a couple edits to account for this event, just wanted to let you know.

@h2zero h2zero force-pushed the v1.4.2-adv-data-refresh branch from 104cf06 to 13165a5 Compare November 29, 2024 22:47
@h2zero h2zero force-pushed the v1.4.2-adv-data-refresh branch from 13165a5 to d87e4bf Compare November 29, 2024 22:57
@h2zero h2zero merged commit 6b1ecd4 into h2zero:master Nov 30, 2024
31 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants