Open Tomzzia opened 1 year ago
Arduino hardware: 1.18.19 OXIMETER ARDUINO UNO VIN 5V GND GND SCL SCL SDA SDA
But in the Serial Monitor is "Initializing pulse oximeter..." and GY-MAX30100 isn't work
My code:
PulseOximeter pox; uint32_t tsLastReport = 0;
void onBeatDetected() { Serial.println("Beat!"); }
void setup()
{ Serial.begin(115200); Serial.print("Initializing pulse oximeter..");
if (!pox.begin()) { Serial.println("FAILED"); for(;;); } else { Serial.println("SUCCESS"); } pox.setIRLedCurrent(MAX30100_LED_CURR_7_6MA); pox.setOnBeatDetectedCallback(onBeatDetected);
}
void loop() {
pox.update(); if (millis() - tsLastReport > REPORTING_PERIOD_MS) { Serial.print("Heart rate:"); Serial.print(pox.getHeartRate()); Serial.print("bpm / SpO2:"); Serial.print(pox.getSpO2()); Serial.println("%"); tsLastReport = millis(); }
is their any solution to this problem?
Arduino hardware: 1.18.19 OXIMETER ARDUINO UNO VIN 5V GND GND SCL SCL SDA SDA
But in the Serial Monitor is "Initializing pulse oximeter..." and GY-MAX30100 isn't work
My code:
include
include "MAX30100_PulseOximeter.h"
define REPORTING_PERIOD_MS 1000
PulseOximeter pox; uint32_t tsLastReport = 0;
void onBeatDetected() { Serial.println("Beat!"); }
void setup()
{ Serial.begin(115200); Serial.print("Initializing pulse oximeter..");
}
void loop() {
}