Skip to content

Receive error occurs at I2C port #1998

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Schrscat opened this issue Oct 24, 2018 · 6 comments
Closed

Receive error occurs at I2C port #1998

Schrscat opened this issue Oct 24, 2018 · 6 comments
Labels
Status: Stale Issue is stale stage (outdated/stuck)

Comments

@Schrscat
Copy link

We are using the ESP32 to receive the information from the MAX 30100. The returned value on the oscilloscope is right, which means that the value returned by the sensor is right. The value is 0x11. But received value from the esp32, showing on the PC, is not 0x11 but 0. Following is the shortest code to generate this error. This error could be a generous one. We have tried all the I2C ports, but this problem remains the same.

uint16_t readRegister(uint8_t address)
{
    Wire.beginTransmission(MAX30100_I2C_ADDRESS);
    Wire.write(address);
    Wire.endTransmission(false);
    Serial.print("byte count: ");
    Serial.println(Wire.requestFrom(MAX30100_I2C_ADDRESS, 1));

    return Wire.read();
}

void setup(){
    Serial.begin(115200);

    delay(1000);

    Wire.begin(21,22);
    Wire.setClock(I2C_BUS_SPEED);

    Serial.println(readRegister(0xff));
}

void loop(){}

The picture on the oscilloscope is

qq 20181024220001

@lbernstone
Copy link
Contributor

Please indicate which version of code you are using. There were some issues with ReSTART in the release version. This is fixed in the repository.

@stickbreaker
Copy link
Contributor

@Schrscat same issue as #1962.

Chuck.

@Schrscat
Copy link
Author

Please indicate which version of code you are using. There were some issues with ReSTART in the release version. This is fixed in the repository.

We are using v3.2-dev-39-gaaf12390.

@Schrscat
Copy link
Author

@Schrscat same issue as #1962.

Chuck.

OK,we will try this. I would reply to you asap

@stale
Copy link

stale bot commented Aug 1, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the Status: Stale Issue is stale stage (outdated/stuck) label Aug 1, 2019
@stale
Copy link

stale bot commented Aug 15, 2019

This stale issue has been automatically closed. Thank you for your contributions.

@stale stale bot closed this as completed Aug 15, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Stale Issue is stale stage (outdated/stuck)
Projects
None yet
Development

No branches or pull requests

3 participants