This simple and inexpensive project is based around the MAX30100 sensor breakout board and utilizes a small 0.91" OLED display to report the heart rate and oxygenation level.
Both the devices used have an I2C two-wire interface and therefore keeps the wiring down to a minimum.
The WiringBoth the OLED display and the MAX30100 breakout board need need 4 wires connected to the Arduino board:
- Ground
- VCC
- SDA
- SCL
The data lines for the I2C interface will depend on the specific version of the Arduino board being used. In this case I am using A4 for SDA and A5 for SCL, as these are the hardware dedicated pins for the Uno and Nano.
DescriptionOnce the three devices (Arduino, OLED display and MAX30100 sensor board) are connected it is time to upload the code to the Arduino board. I have shared the code for my implementation at my GitHub repository, it's not the best code and a bit messy, but it works.
At start up, the display prompts the user to place their finger on the sensor. when it detects a heart beat, it updates the heart symbol on the display to show that and starts recording the readings.
In my implementation I filter any measurement that is outside of a threshold and then calculate an average for both the heart rate and the SpO2 values and finally display that on the OLED.
As long as the finger remains on the sensor and the sensor is detecting a hear beat, the display keeps showing the result. If the sensor does not detect a heart beat for 10 seconds, it restarts the process and prompts the user for another reading.
As you can see this is a really simple implementation on how to use this sensor and the purpose is more educational than anything else. With the right amount of effort a fairly robust device can be built and I hope this guide inspires someone to take this to the next level.
The VideoI recorded the following video to demonstrate the project.
Comments