pulse sensor library

Files at this revision

API Documentation at this revision

Comitter:
memig3
Date:
Wed Mar 25 19:06:19 2020 +0000
Parent:
0:e80a245c4d0d
Commit message:
3/25

Changed in this revision

PulseSensor.cpp Show annotated file Show diff for this revision Revisions of this file
PulseSensor.h Show annotated file Show diff for this revision Revisions of this file
--- a/PulseSensor.cpp	Sun Feb 09 15:37:19 2014 +0000
+++ b/PulseSensor.cpp	Wed Mar 25 19:06:19 2020 +0000
@@ -149,4 +149,12 @@
     {
         return false;
     }
+}
+
+int PulseSensor::get_BPM()
+{
+    if(_started)
+    {
+        return BPM;
+    }
 }
\ No newline at end of file
--- a/PulseSensor.h	Sun Feb 09 15:37:19 2014 +0000
+++ b/PulseSensor.h	Wed Mar 25 19:06:19 2020 +0000
@@ -67,6 +67,8 @@
          * @return true if reading is stopped, false if reading was already stopped.
          */
         bool stop();
+        
+        int get_BPM();
 };
 
 #endif
\ No newline at end of file