SCD40 is communicationg but the check for NACK mush have been disabled. Why?
This commit is contained in:
@@ -69,11 +69,13 @@ int8_t scd4x_read_measurement(int * co2, int *temperature, int *relative_humidit
|
||||
buffer[0] = READ_MEASUREMENT >> 8;
|
||||
buffer[1] = READ_MEASUREMENT & 0x00ff;
|
||||
result = i2c_transmit(SCD4X_I2C_ADDRESS<<1, buffer, 2);
|
||||
if (result != I2C_OK) {
|
||||
return SCD4X_ERROR;
|
||||
}
|
||||
|
||||
LL_mDelay(10); // 10 ms should be enough
|
||||
// TODO: Proc to vraci NACK? Vyresit.
|
||||
/*if (result != I2C_OK) {
|
||||
return SCD4X_ERROR;
|
||||
}*/
|
||||
|
||||
LL_mDelay(1); // 10 ms should be enough
|
||||
// read out
|
||||
result = i2c_receive(SCD4X_I2C_ADDRESS<<1, buffer, 9);
|
||||
if (result != I2C_OK)
|
||||
|
||||
Reference in New Issue
Block a user