This is one of the demo programs for the MAX30003WING. The program outputs the raw data serially to graphically reproduce the QRS complex. A serial plotter is needed to graph the data.

Dependencies:   MAX30003 max32630fthr

Fork of MAX30003_Demo_Plot by John Greene

Files at this revision

API Documentation at this revision

Comitter:
johnGreeneMaxim
Date:
Thu Dec 14 21:42:36 2017 +0000
Parent:
6:86ac850c718d
Commit message:
Added a debug LED to turn on when FIFO overflow happens ;

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r 86ac850c718d -r cf0855a0450a main.cpp
--- a/main.cpp	Tue Aug 29 20:27:26 2017 +0000
+++ b/main.cpp	Thu Dec 14 21:42:36 2017 +0000
@@ -64,8 +64,6 @@
     pc.baud(115200);                    // Baud rate = 115200
     
     DigitalOut rLed(LED1, LED_OFF);      // Debug LEDs
-    DigitalOut gLed(LED2, LED_OFF);
-    DigitalOut bLed(LED3, LED_OFF);
     
     InterruptIn ecgFIFO_int(P5_4);          // Config P5_4 as int. in for the
     ecgFIFO_int.fall(&ecgFIFO_callback);    // ecg FIFO almost full interrupt
@@ -108,6 +106,7 @@
                 // Check if FIFO has overflowed
                 if( ETAG[readECGSamples - 1] == FIFO_OVF_MASK ){                  
                     ecgAFE.writeRegister( MAX30003::FIFO_RST , 0); // Reset FIFO
+                    rLed = 1;//notifies the user that an over flow occured
                 }
                 
                 // Print results