This device uses a MAX30102 Sensor to measure the SPO2 levels with using the algorithms form MAX30102_by_RF and using initialization codes from SparkFun MAX301x Particle Sensor Library.
A huge thanks to har-in-air for providing this code and robcazzaro for finding the fix for the SPO2 error in here.
Beware of Chinese Clones of MAX30102 sensor because I found a hard time figuring why my SPO2 level are failed to measure, the cause was that the chinese MAX30102 sensors has a swapped IR LED and RED LED. Refer the Line 235 on arduino code for more information. If you are using a geniune MAX30102 sensor the sensor has the IR LED at the middle and the RED LED at right side. For more information on the above issue please visit this discussion.
If you are using the MAX30100 sensor module and if the sensor does not power on correctly it is due to some voltage regulator issue make sure you visit this video.
Install the required libraries through arduino library manager or through github repositories. Change the Board type to Wemos D1 R1
Then you are ready to upload your code.