Remember to maintain security and privacy. Do not share sensitive information. Procedimento.com.br may make mistakes. Verify important information. Termo de Responsabilidade

How to Monitor Heart Rate Using Arduino

Monitoring heart rate, or "batimentos cardíacos," is a common application in health and fitness projects. Arduino, with its versatility and ease of use, can be employed to create a simple heart rate monitor using a pulse sensor. This project is an excellent way to explore bio-sensing technology and understand how heart rate monitoring works.

Examples:

To create a heart rate monitor using Arduino, you will need the following components:

  • Arduino Uno or any compatible board
  • Pulse Sensor (e.g., Pulse Sensor Amped)
  • Jumper wires
  • Breadboard
  • USB cable for programming

Step-by-Step Instructions:

  1. Connect the Pulse Sensor:

    • Connect the VCC pin of the pulse sensor to the 5V pin on the Arduino.
    • Connect the GND pin of the pulse sensor to the GND pin on the Arduino.
    • Connect the Signal pin of the pulse sensor to the A0 pin on the Arduino.
  2. Install the Pulse Sensor Library:

    • Open the Arduino IDE.
    • Go to Sketch > Include Library > Manage Libraries.
    • Search for "PulseSensor Playground" and install it.
  3. Write the Arduino Sketch:

    Here is a sample code to read the heart rate data from the pulse sensor and output it to the Serial Monitor:

    #include <PulseSensorPlayground.h>
    
    const int PulseWire = 0;       // Pulse Sensor connected to Analog Pin 0
    const int LED13 = 13;          // The on-board Arduino LED
    int Threshold = 550;           // Adjust this value to your needs
    
    PulseSensorPlayground pulseSensor;
    
    void setup() {
     Serial.begin(9600);
     pulseSensor.analogInput(PulseWire);
     pulseSensor.blinkOnPulse(LED13);
     pulseSensor.setThreshold(Threshold);
    
     if (pulseSensor.begin()) {
       Serial.println("Pulse Sensor initialized successfully.");
     }
    }
    
    void loop() {
     int myBPM = pulseSensor.getBeatsPerMinute();
    
     if (pulseSensor.sawStartOfBeat()) {
       Serial.print("BPM: ");
       Serial.println(myBPM);
     }
    
     delay(20);
    }
  4. Upload the Code:

    • Connect your Arduino board to your computer using the USB cable.
    • Select the correct board and port from the Tools menu.
    • Upload the code to the Arduino.
  5. Monitor the Heart Rate:

    • Open the Serial Monitor from the Arduino IDE (Tools > Serial Monitor).
    • Set the baud rate to 9600.
    • Place the pulse sensor on your fingertip or earlobe.
    • Observe the BPM (Beats Per Minute) readings on the Serial Monitor.

This simple setup allows you to monitor heart rate using an Arduino and a pulse sensor. The project can be expanded by adding a display to show the BPM or incorporating wireless communication to send data to a smartphone or computer.

To share Download PDF

Gostou do artigo? Deixe sua avaliação!
Sua opinião é muito importante para nós. Clique em um dos botões abaixo para nos dizer o que achou deste conteúdo.