Announcement

Collapse
No announcement yet.

MAX630100 Not working on 4Duino 24

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Xrayman
    replied
    I found the problem , it was how says Noel the module needs two 4kOm pullup resistors so it work
    Thanks to tonton81 and Noel

    Best regards to all of you !!!!!!

    Leave a comment:


  • Noel
    replied
    Xrayman,

    According to the MAX30100 datasheet on page 23, it needs pull up resistors:

    The MAX30100 transmits data on SDA in sync with the master-generated SCL pulses.
    The master acknowledges receipt of each byte of data. Each read sequence is framed by a
    START (S) or REPEATED START (Sr) condition, a not acknowledge, and a STOP (P) condition.
    SDA operates as both an input and an open-drain output. A pullup resistor, typically greater than 500Ω
    , is required on SDA. SCL operates only as an input. A pullup resistor, typically greater than 500Ω,
    is required on SCL if there are multiple masters on the bus, or if the single master has an open-drain SCL output.

    Best regards,

    Leave a comment:


  • Xrayman
    replied
    no because wire.begin its included in libraries so when cal pox.begin it will call wire.begin too
    Attached Files

    Leave a comment:


  • tonton81
    replied
    your not calling Wire.begin() ?

    Leave a comment:


  • Xrayman
    replied
    #include <Wire.h>
    #include "MAX30100_PulseOximeter.h"

    #define REPORTING_PERIOD_MS 2000

    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.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.print("% / temp:");
    Serial.print(pox.getTemperature());
    Serial.println("C");

    tsLastReport = millis();
    }
    }
    Last edited by Xrayman; 8 May 2017, 02:26 AM.

    Leave a comment:


  • tonton81
    replied
    can you post your sketch?

    Leave a comment:


  • Xrayman
    replied
    max30100 have already pullup resistors, its connected SDA to SDA and SCL to SCL. D2 and D3 same situation no activity (SDA and SCL are same pin as D2 and D3)

    Leave a comment:


  • tonton81
    replied
    you have your pullups and sda-sda and scl-scl connected?

    "
    Leonardo 2 (SDA), 3 (SCL)
    can you try these ones?

    note: those are digital, not analog pins (2,3)
    Last edited by tonton81; 8 May 2017, 12:44 AM.

    Leave a comment:


  • Xrayman
    replied
    But sensor dont even start (i mean activity via serial monitor) and i think its a bug caused by wire.h
    maybe some other library will work on 4Duino.?

    Leave a comment:


  • tonton81
    replied
    yes sorry you are correct, it's near the WIFI antenna first 2 pins labeled SDA/SCL

    Leave a comment:


  • Xrayman
    replied
    On 4Duino the analog pins 4 and 5 are not connected to sda and scl pin, but arduino uno i think have this A5,A4 connected ti I2C bus

    Leave a comment:


  • tonton81
    replied
    the 4Duino pinout is the same as the arduino leonardo, in fact, the processor itself is same as leonardo as well.

    Setting up the bus would be the same way, using analog pins A4 and A5, using standard 4.7K pullups

    Then the usual, including the Wire library at the header, and running it's class in setup ( Wire.begin(); )

    After that you should be okay.

    Tony

    Leave a comment:


  • Xrayman
    started a topic MAX630100 Not working on 4Duino 24

    MAX630100 Not working on 4Duino 24

    Hello !!!

    i have some problems with MAX30100 oxullo libraries implementation on 4D Workshop . The biggest problem it doesnt find I2C adress of MAX30100 (i scan it with I2C scanner). How to setup correct the I2c bus ?
    best regards to you
Working...
X