This is a small Arduino project based on a simple heart rate sensor.
- Hardware:
- Arduino UNO (or any other)
- Heart rate sensor
- OLED display (optional)
HRS pin | Arduino pin |
---|---|
+ | +5V |
- | GND |
S | A1 |
OLED pin | Arduino pin |
---|---|
VDD | +5V |
GND | GND |
SDA | A4 |
SCK | A5 |
-
Download and install U8g2 library in Arduino IDE: Sketch (Alt + S) → Include Library → Manage Libraries.
-
Connect all components to Arduino according to the above instructions.
-
Connect Arduino via USB, compile and upload the sketch using Arduino IDE.
- Install all required Python packages with:
$ cd python-cli
$ pip install -r requirements.txt
- Put your finger on a heart rate sensor and run the script:
python getData-cli.py
- The dataset will be saved into this directory.
- Run Jupyter Notebook (or Lab) in this project directory:
$ jupyter lab
-
Open
HRV analysis.ipynb
file and setpath
variable to a dir with your dataset. You may wish to createdata
folder. In my case, it isdata/Me/
. -
Run the cells to see the results.