Two Peak detection and extraction of timing information in arduino

Discussion in 'Embedded Systems and Microcontrollers' started by Goverdhan R, May 13, 2016.

  1. Goverdhan R

    Thread Starter New Member

    Mar 10, 2016
    I want to use arduino to detect peak and extract timing information. As shown in image attached i want ST,T1,DT to be detected using arduino. Detealis about signal frequency:1-2Hz, Some noise exists. So how can i detect ST,t1,DT.
    • ppg.png
      File size:
      281.8 KB
  2. Sensacell

    Well-Known Member

    Jun 19, 2012
    Feed the signal into an ADC, write some code to detect peaks an slope reversals.
    Read a timer to calculate the time values.

    You may need an analog low pass before the ADC, to filter out the noise.
    Sample it at a much higher rate to increase your timing resolution.
  3. dannyf

    Well-Known Member

    Sep 13, 2015
    first, you have to define ST, t1, DT: what are they?
  4. RichardO

    Well-Known Member

    May 4, 2013
    Your signal looks like a EKG waveform. If it is then the peak for the QRS is usually greater than the T wave peak. But, I think in some cases, the T wave can actually be greater than the QRS. Also, sometimes the T wave can be inverted from the QRS. These abnormalities could make your measurements trickier to do.

    Note also that the heart rate can be higher than 2 Hz and lower than 1 Hz. I have had my heart rate close to 180 BPM (not fun) and my resting rate has been as low as 50 BPM.
  5. Goverdhan R

    Thread Starter New Member

    Mar 10, 2016
    St, dt, t1 are defined in image i have attached earlier. This all are time intervals in milliseconds.
  6. dannyf

    Well-Known Member

    Sep 13, 2015
    unless you intend to feed images to your computer, you have define those measurements in terms of logic.
  7. hugeone

    New Member

    May 15, 2016
    IMHO arduino is not the best choice. I would actually consider faster boards with much better ADCs . Maybe ST Nucleo F446 (eight quit)
  8. NorthGuy

    Active Member

    Jun 28, 2014
    I once had a heart monitor. I used it to keep my heart rate below 145 when I jog as was recommended to improve cardiovascular system. I also used the monitor to learn calming down at rest. After some training I could lower my heart rate to 30. I would guess other people could go even lower.