Skip to content
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

Constant Gas reading #11

Closed
ernesst opened this issue Sep 19, 2018 · 5 comments
Closed

Constant Gas reading #11

ernesst opened this issue Sep 19, 2018 · 5 comments

Comments

@ernesst
Copy link

ernesst commented Sep 19, 2018

I've acquired recently an Adafruit BME680, with a Pi Zero W.
During the first day the sensor was able to get a resistance reading for the gas, currently the reading is stuck to 45556 whatever atmosphere is. (I've tried alcohol & black marker)

I'm wondering if it's a bug or the sensor burnt.
As you can see below, the sensors jumped between stuck and reading and now it seems staying stuck.
image
The humidity and temperature reading give a relevant feedback.
I'm not recalling specific intervention from me able to act on the resistance reading.

Thanks

@ernesst
Copy link
Author

ernesst commented Sep 19, 2018

Without touching anything the reading went back then collapse for an hours

image

I'll let it run.

@caternuson
Copy link
Contributor

As a comparison check, I ran an UNO with the Arduino lib. I logged data for ~1 hour, breathing on it at the beginning and end to generate a response. Plot of millis() vs. gas_resistance:
bme680_uno
There's a general warming up trend, but it otherwise responded to breath.

I also did a similar check with an Itsy Bitsy M4 and CP 3.1.1. I seemed to have gotten the same odd behavior. Plot of time.monotonic() vs. gas:
bme68_itsy
It initially responded, but then the reading froze. Other readings, like temperature and humidity were still responding.

@kattni
Copy link
Contributor

kattni commented Apr 16, 2020

@caternuson Can you test this again? I believe it may have been resolved by #18 based on reference to #12.

@caternuson
Copy link
Contributor

@kattni Yep, appears to be fixed. Or at least could not repeat the same behavior as above. Here's latest test result for plot of gas:

image

import time
import board
import digitalio
import adafruit_bme680

bme = adafruit_bme680.Adafruit_BME680_I2C(board.I2C())

led = digitalio.DigitalInOut(board.D13)
led.direction = digitalio.Direction.OUTPUT
led.value = False

go = digitalio.DigitalInOut(board.D10)
go.direction = digitalio.Direction.INPUT

print("logging...")
with open("/data.csv", "a") as fp:
    while go.value:
        fp.write("{},{},{},{},{}\n".format(time.monotonic(),
                                           bme.temperature,
                                           bme.gas,
                                           bme.humidity,
                                           bme.pressure))
        fp.flush()
        led.value = not led.value
        time.sleep(1)
print("DONE.")

@kattni
Copy link
Contributor

kattni commented Apr 29, 2020

Resolved. Closing.

@kattni kattni closed this as completed Apr 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants