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

added forceReadings() for force mode #2

Closed
wants to merge 1 commit into from
Closed

added forceReadings() for force mode #2

wants to merge 1 commit into from

Conversation

drewfish
Copy link

@drewfish drewfish commented Jan 2, 2016

This adds a forceReadings() method which puts the sensor into force mode. When this happens the BME reads the sensors, stores the results in the data registers, then goes to sleep. Another call to forceReadings() is then needed to cause the sensor to read again.

Using this I saw the device go from using a steady ~400uA to a base of ~0.4uA and spiking to ~50uA. (OK, my multimeter is pretty cheap, as is my EE knowledge 😄) I was measuring 3 times a second with no filtering and 1x sampling of all three readings.

@drewfish
Copy link
Author

drewfish commented Jan 2, 2016

FWIW, this PR is mainly in case others are interested. I don't intend to use it since the delay() will cause trouble for my event loop.

@PaulRB
Copy link

PaulRB commented Mar 18, 2016

Thanks @drewfish, sounds like this would fix my issue #6. Can you please confirm? If so, I will close my issue.

@drewfish
Copy link
Author

Yeah it sounds like it might. To be sure you should try it yourself. You can hopefully find some guides on the net on how to use the github version of an arduino library (this one), and then another guide on how to "checkout a pull request" (this one).

@ripper121
Copy link

Is there a Library where this function is already implemented?

@nseidle
Copy link
Member

nseidle commented Mar 24, 2018

We've added a .setMode(MODE_FORCED) function, .isMeasuring() function, and an example demonstrating how to put the BME280 into low power mode (see example 6) in the latest lib v2.x.

Thank you for this pull request! I'm sorry we couldn't use it in the overhaul but your feedback pushed us to include this feature.

If you get the chance, please kick the tires of the new library version and let us know if you run into any problems.

@nseidle nseidle closed this Mar 24, 2018
@drewfish drewfish deleted the force branch March 24, 2018 04:49
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

Successfully merging this pull request may close these issues.

4 participants