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

How to read an entire characteristic (and allocate sufficient memory)? #267

Open
dmjones opened this issue Apr 25, 2024 · 0 comments
Open

Comments

@dmjones
Copy link

dmjones commented Apr 25, 2024

I want to read a device characteristic that could be split into multiple records. I have two inter-related questions:

Am I responsible for calling DeviceCharacteristic.Read() multiple times, according to the "more data" bit, or is this handled by lower-level libraries?

Assuming I have to call multiple times, can I assume the results from DeviceCharacteristic.Read() will not be larger than DeviceCharacteristic.GetMTU()?

Finally, if the lower-level libraries handle multiple reads, how do I know how much data to allocate?

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

No branches or pull requests

1 participant