Step 1: Sensor assembly
The sensor unit consists of an infrared light-emitting-diode (IR LED) and a photo diode, placed side by side, and the fingertip is placed over the sensor assembly, as shown below. The IR LED transmits an infrared light into the fingertip, a part of which is reflected back from the blood inside the finger arteries. The photo diode senses the portion of the light that is reflected back. The intensity of reflected light depends upon the blood volume inside the fingertip. So, every time the heart beats the amount of reflected infrared light changes, which can be detected by the photo diode. With a high gain amplifier, this little alteration in the amplitude of the reflected light can be converted into a pulse.
Step 2: Signal conditioning circuit
The reflected IR signal detected by the photo diode is fed to a signal conditioning circuit that filters the unwanted signals and boost the desired pulse signal. The circuit diagram above shows the IR LED (D1) and the photo diode (D2) along with the signal conditioning circuit made of two stage operational amplifiers configured as active low pass filters. The cut-off frequencies of both the filters are set to about 2.5 Hz, and so it can measure the pulse rate up to 2.5*60 = 150 bpm. The gain of each filter is about 100, which gives the total 2-stage amplification of 10000. This is good enough to convert the weak pulsating signal into a TTL pulse.
Note that at the input of each OpAmp filter stage, there is a 1 uF capacitor to block any DC component in the signal. At the output is connected a LED that will blink with heart beat. The cathode of LED gets the ground path through the collector of BC547 transistor. In order to save the battery life, the transistor is turned on for 15 seconds by PIC16F628A microcontroller while the measurement is going on. The number of pulses counted within this interval is multiplied by 4 to get actual beats per minutes (bpm).
For more detail: Microcontroller measures heart rate through fingertip