PulseSensor_Heart-Rate-Variabilty
PulseSensor_Heart-Rate-Variabilty copied to clipboard
Download data
Hi,
I am currently working on a project which needs HRV, IBI and other data. I came across this repository which has good resource required for my project. I just wanted to know if it is possible to update the data acquired from the graph to a CSV file every 5 seconds or so, so that it can be used later for processing.
Thank you Srivathsa
Please contact the authors of the Pulse Sensor. I'm no longer working on this project.
On Thu, May 6, 2021 at 12:00 PM Srivathsa-Bharadwaj < @.***> wrote:
Hi,
I am currently working on a project which needs HRV, IBI and other data. I came across this repository which has good resource required for my project. I just wanted to know if it is possible to update the data acquired from the graph to a CSV file every 5 seconds or so, so that it can be used later for processing.
Thank you Srivathsa
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/WorldFamousElectronics/PulseSensor_Heart-Rate-Variabilty/issues/9, or unsubscribe https://github.com/notifications/unsubscribe-auth/AI627KUOYJTFDLFFFGMWSCDTMLDMDANCNFSM44HO4MVA .
-- George Rod 954-294-0700
@Srivathsa-Bharadwaj This is a great feature add to the PulseSensor Playground Library. Right now, the code sends a raw sample at about 50Hz. I say about because that is timed with a 20mS delay() function.
The Pulse Sensor code, however samples at 500Hz, (2mS sample rate) and I think there are a couple of ways to go about getting every sample if you need it without missing any.
First you have to have a sample stamp of some kind. An easy one is just a counter that can verify if any datapoints are lost. Then, Either one would send out every sample, along with IBI value when a beat happened. The values have to be parsable, but that could happen with our scheme of adding an ASCII coded prefix to the value or a different protocol. Or, one could make a buffer of samples to send intermittent to the sample rate. That would take some benchmarking to see how much time is available for sending buffers. At first glance, 500Kbaud rate can fit a decent amount of data in 2mS, so buffering has enough headroom if the receiver can't handle a fire hose of data.
For saving data in a .csv file, you can try PulseSensor_Visualizer_Record_Playback, which would be a good starting point to saving a file. This has not been tested with high frequency data, I don't think, so that would be a fun test to run. First make sure it works as is.