maarten-pennings / CCS811

Arduino library for the CCS811 gas sensor for monitoring indoor air quality.
MIT License
169 stars 47 forks source link

My CCS811 from CJMCU does not works after flashing comleted. #70

Closed ajaybnl closed 3 years ago

ajaybnl commented 3 years ago

My CCS811 from CJMCU does not works after flashing completed.

Before flashing it was working good. After i flashed it, It does not works with the library.

Its says I2c Error every time, i have scanned i2c bus with scanner sketch, the sensor shows the address 0x5A.

Please help me. i have tried to reflash it with the flasher example, but it never flashes or connects.

ajaybnl commented 3 years ago

I removed everything except these lines :

Wire.begin();

// Enable CCS811 ccs811.set_i2cdelay(50); // Needed for ESP8266 because it doesn't handle I2C clock stretch correctly

delay(5000); //Serial.println(""); bool ok= ccs811.flash(image_data, sizeof(image_data));

And the module re-flashed and working again. Something in the flash sketch stopped flashing.

maarten-pennings commented 3 years ago

Sounds like you're good now. Glad to hear you solved the problem, regards, Maarten