Close
0%
0%

Wear your heartbeat on your sleeve

Use biometric sensing to share your excitement!

Public Chat
Similar projects worth following
Show everyone you are human, even though you work like a Robot!
Use the PPG sensor on EmotiBit to detect your heartbeats and display them on an Adafruit CharliePlex FeatherWing!

How It Works

  1. The EmotiBit firmware library communicates with the onboard PPG sensor (MAX30101) via I2C to get PPG data. The sensor has 3 different wavelengths that can easily be accessed by tweaking the stock example to provide different cardiovascular information.
    Code snippet below:
    void loop()
    {  
      emotibit.update();   
      size_t dataAvailable = emotibit.readData(EmotiBit::DataType::PPG_INFRARED, &data[0], MAX_DATA_SIZE);   
      // do something cool with your data!
    }
  2. The raw PPG data is then passed through a simple first-order lowpass (LP) IIR digital filter. This filtered signal acts as a threshold for the crossing detector (discussed next). 
  3. The crossing detector is created by comparing the raw PPG signal with the LP filtered threshold signal. 

If the raw PPG signal goes above the threshold, the CharliePlex led matrix is turned ON. Conversely, when the raw PPG signal goes below the threshold, the display is turned OFF.


Above is a screen capture showing the trigger for the led matrix as the green square wave signal. The raw PPG signal is shown in blue and the LP filtered threshold signal is represented by the red line. Note that this is also mathematically equivalent to using a high-pass filter with a zero-crossing threshold.

  • 1
    Download the EmotiBit Arduino Example

    Get the EmotiBit FeatherWing firmware and dependencies via the Arduino Library Manager or in the EmotiBit FeatherWing github repo (see the full instructions and dependency list in the EmotiBit_Docs github repo).

  • 2
    Program the Feather

    Program the Adafruit Feather with the following example: File>Examples>Emotibit FeatherWing>EmotiBit_examples>charlieplex_heartbeatOnSleeve

  • 3
    Stack it up!
    1. Stack the Feather + EmotiBit + CharliePlex wing. Note that you will need stacking headers on your adafruit feather to assemble the whole setup.
    2. Plug in the battery.

View all 5 instructions

Enjoy this project?

Share

Discussions

Deepak Khatri wrote 04/28/2021 at 21:05 point

Awesome work!

  Are you sure? yes | no

Sean Montgomery wrote 04/29/2021 at 12:42 point

Thanks @Deepak Khatri !

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates