Closed huntc closed 3 years ago
Best solution would be a PR which adds delay as a function parameter everywhere it is needed similar to what is already happening in soft_reset https://github.com/marcelbuesing/bme680/blob/e10fa1a35ade1771f276357dc7949654b92dfd99/src/lib.rs#L403-L407 and remove delay from the bme680 struct.
I think the following functions would need to be updated:
Thanks @caemor I think that sounds like a good idea.
Best solution would be a PR which adds delay as a function parameter everywhere it is needed similar to what is already happening in soft_reset
and remove delay from the bme680 struct.
Sounds like a plan. I think it could be passed as a &mut also, right? I can take a look in several hours from now.
Exactly
The PR is in: https://github.com/marcelbuesing/bme680/pull/35
Thanks again for this library. Is it possible to get a review of my PR?
Thanks for providing this library.
I'm trying to use the library in the context of an embedded-hal. When initing your library I must provide a delayer:
The problem with the above is that, because your library now owns the delayer, I'm no longer able to use it elsewhere.
Do you have any thoughts on what I might do in this situation?