Hi
Here's what I would like to do: I have a bluetooth device with an nrf51822, with which I gather some sensor data, with a period of say 1 minute. I would like to store the last samples in a buffer, and I would use some circular buffer with a size of 1000 samples, so at any time I would have between 1 and 1000 samples in my buffer. What I would like to do is transfer those samples to a smartphone or a tablet when the smartphone or tablet is within reach. I already can do this using single values. But the question is now: how to transfer a buffer: I don't think I can define a characteristic with (variable) length of maximum 1000 bytes. So I think my smartphone app just needs a notification when it is in reach with a message that new samples are available, and then have a mechanism where the smartphone can download the buffer content, by consecutive reads of e.g. a readable characteristic of say 32 bits.
Is there some example somewhere which does a similar thing? Can anyone make a suggestion on what would be the best way of doing this, with minimal amount of transfers needed? Maybe should add to it that my bluetooth peripheral is battery operated.